Fix broken window maximization.

git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@2008 ea778897-0a13-0410-b9d1-a72fbfd435f5
This commit is contained in:
Enrico Tröger 2007-11-02 13:03:54 +00:00
parent bceb2ce942
commit dba689edf2
2 changed files with 9 additions and 4 deletions

View File

@ -1,6 +1,7 @@
2007-11-02 Enrico Tröger <enrico.troeger@uvena.de> 2007-11-02 Enrico Tröger <enrico.troeger@uvena.de>
* src/build.c, src/makefile.win32: Add exit code detection for Windows. * src/build.c, src/makefile.win32: Add exit code detection for Windows.
* src/keyfile.c: Fix broken window maximization.
2007-11-01 Nick Treleaven <nick(dot)treleaven(at)btinternet(dot)com> 2007-11-01 Nick Treleaven <nick(dot)treleaven(at)btinternet(dot)com>

View File

@ -641,13 +641,17 @@ static void load_ui_prefs(GKeyFile *config)
ui_prefs.geometry[3] = geo[3]; ui_prefs.geometry[3] = geo[3];
ui_prefs.geometry[4] = geo[4]; ui_prefs.geometry[4] = geo[4];
// don't use insane values // don't use insane values but when main windows was maximized last time, pos might be
// negative at least on Windows for some reason
if (ui_prefs.geometry[4] != 1)
{
for (i = 0; i < 4; i++) for (i = 0; i < 4; i++)
{ {
if (ui_prefs.geometry[i] < -1) if (ui_prefs.geometry[i] < -1)
ui_prefs.geometry[i] = -1; ui_prefs.geometry[i] = -1;
} }
} }
}
hpan_position = utils_get_setting_integer(config, PACKAGE, "treeview_position", 156); hpan_position = utils_get_setting_integer(config, PACKAGE, "treeview_position", 156);
vpan_position = utils_get_setting_integer(config, PACKAGE, "msgwindow_position", (geo) ? vpan_position = utils_get_setting_integer(config, PACKAGE, "msgwindow_position", (geo) ?
(GEANY_MSGWIN_HEIGHT + geo[3] - 440) : (GEANY_MSGWIN_HEIGHT + geo[3] - 440) :