Merge branch 'master' into jgrpp
# Conflicts: # src/autoreplace_cmd.cpp # src/company_base.h # src/company_gui.cpp # src/cpu.cpp # src/debug.h # src/group.h # src/group_cmd.cpp # src/house.h # src/industry.h # src/newgrf_house.cpp # src/news_type.h # src/openttd.cpp # src/saveload/company_sl.cpp # src/settings_type.h # src/sl/oldloader_sl.cpp # src/story.cpp # src/table/town_land.h # src/viewport.cpp
This commit is contained in:
@@ -38,6 +38,7 @@
|
||||
#include "table/sprites.h"
|
||||
|
||||
#include <map>
|
||||
#include <numeric>
|
||||
#include "safeguards.h"
|
||||
|
||||
/**
|
||||
@@ -1666,20 +1667,20 @@ public:
|
||||
this->smallest_y = std::max(min_inf_height, min_acs_height + WidgetDimensions::scaled.vsep_wide + min_avs_height);
|
||||
|
||||
/* Filling. */
|
||||
this->fill_x = LeastCommonMultiple(this->avs->fill_x, this->acs->fill_x);
|
||||
this->fill_x = std::lcm(this->avs->fill_x, this->acs->fill_x);
|
||||
if (this->inf->fill_x > 0 && (this->fill_x == 0 || this->fill_x > this->inf->fill_x)) this->fill_x = this->inf->fill_x;
|
||||
|
||||
this->fill_y = this->avs->fill_y;
|
||||
if (this->acs->fill_y > 0 && (this->fill_y == 0 || this->fill_y > this->acs->fill_y)) this->fill_y = this->acs->fill_y;
|
||||
this->fill_y = LeastCommonMultiple(this->fill_y, this->inf->fill_y);
|
||||
this->fill_y = std::lcm(this->fill_y, this->inf->fill_y);
|
||||
|
||||
/* Resizing. */
|
||||
this->resize_x = LeastCommonMultiple(this->avs->resize_x, this->acs->resize_x);
|
||||
this->resize_x = std::lcm(this->avs->resize_x, this->acs->resize_x);
|
||||
if (this->inf->resize_x > 0 && (this->resize_x == 0 || this->resize_x > this->inf->resize_x)) this->resize_x = this->inf->resize_x;
|
||||
|
||||
this->resize_y = this->avs->resize_y;
|
||||
if (this->acs->resize_y > 0 && (this->resize_y == 0 || this->resize_y > this->acs->resize_y)) this->resize_y = this->acs->resize_y;
|
||||
this->resize_y = LeastCommonMultiple(this->resize_y, this->inf->resize_y);
|
||||
this->resize_y = std::lcm(this->resize_y, this->inf->resize_y);
|
||||
|
||||
/* Make sure the height suits the 3 column (resp. not-editable) format; the 2 column format can easily fill space between the lists */
|
||||
this->smallest_y = ComputeMaxSize(min_acs_height, this->smallest_y + this->resize_y - 1, this->resize_y);
|
||||
|
Reference in New Issue
Block a user