(svn r20807) -Codechange: don't clamp the width of the main toolbar to 640 pixels

This commit is contained in:
yexo
2010-09-15 21:10:14 +00:00
parent 7bb0cf9af6
commit 532003504e
3 changed files with 14 additions and 3 deletions

View File

@@ -32,6 +32,7 @@
#include "settings_type.h"
#include "newgrf_debug.h"
#include "hotkeys.h"
#include "toolbar_gui.h"
#include "table/sprites.h"
@@ -2690,7 +2691,7 @@ void RelocateAllWindows(int neww, int newh)
* in a 'backup'-desc that the window should always be centered. */
switch (w->window_class) {
case WC_MAIN_TOOLBAR:
if (neww - w->width != 0) ResizeWindow(w, min(neww, 640) - w->width, 0);
ResizeWindow(w, min(neww, *_preferred_toolbar_size) - w->width, 0);
top = w->top;
left = PositionMainToolbar(w); // changes toolbar orientation