]> jfr.im git - irc/hexchat/hexchat.git/commitdiff
win32: Fix exiting fullscreen to a maximized window
authorTingPing <redacted>
Fri, 30 May 2014 08:26:34 +0000 (04:26 -0400)
committerTingPing <redacted>
Fri, 30 May 2014 08:26:34 +0000 (04:26 -0400)
src/fe-gtk/menu.c

index f9c41da287d766a0434c8ed78ab5b7d8f0c56704..39c0ad5a25164f23db16b564a2ba8d295c8e9d98 100644 (file)
@@ -906,11 +906,14 @@ menu_fullscreen_toggle (GtkWidget *wid, gpointer ud)
                gtk_window_unfullscreen (GTK_WINDOW(parent_window));
 
 #ifdef WIN32
-               /* other window managers seem to handle this */
-               gtk_window_resize (GTK_WINDOW(parent_window),
-                                       prefs.hex_gui_win_width, prefs.hex_gui_win_height);
-               gtk_window_move (GTK_WINDOW(parent_window),
-                                       prefs.hex_gui_win_left, prefs.hex_gui_win_top);
+               if (!prefs.hex_gui_win_state) /* not maximized */
+               {
+                       /* other window managers seem to handle this */
+                       gtk_window_resize (GTK_WINDOW (parent_window),
+                               prefs.hex_gui_win_width, prefs.hex_gui_win_height);
+                       gtk_window_move (GTK_WINDOW (parent_window),
+                               prefs.hex_gui_win_left, prefs.hex_gui_win_top);
+               }
 #endif
        }
 }