WIP do not compile - split toolbar into two vertical toolbars
This commit is contained in:
+5
-1
@@ -1594,7 +1594,11 @@ static Point GetAutoPlacePosition(int width, int height)
|
||||
|
||||
/* First attempt, try top-left of the screen */
|
||||
const Window *main_toolbar = FindWindowByClass(WC_MAIN_TOOLBAR);
|
||||
if (IsGoodAutoPlace1(0, main_toolbar != NULL ? main_toolbar->height : 0, width, height, pt)) return pt;
|
||||
if (_settings_client.gui.vertical_toolbar) {
|
||||
if (IsGoodAutoPlace1(main_toolbar != NULL ? main_toolbar->width : 0, 0, width, height, pt)) return pt;
|
||||
} else {
|
||||
if (IsGoodAutoPlace1(0, main_toolbar != NULL ? main_toolbar->height : 0, width, height, pt)) return pt;
|
||||
}
|
||||
|
||||
/* Second attempt, try around all existing windows with a distance of 2 pixels.
|
||||
* The new window must be entirely on-screen, and not overlap with an existing window.
|
||||
|
||||
Reference in New Issue
Block a user