diff options
author | Emmanuele Bassi <ebassi@gnome.org> | 2016-08-31 16:48:25 +0100 |
---|---|---|
committer | Emmanuele Bassi <ebassi@gnome.org> | 2016-08-31 16:48:25 +0100 |
commit | 5a8a2685a167190c84b7c12ccc9bf8beb8590563 (patch) | |
tree | b2e7afd6da8568e12476eb27536341547c7e30cf /src | |
parent | 1fd768a09010de3a4d08f1b8adfd9b6caede19ac (diff) | |
download | gnome-dictionary-5a8a2685a167190c84b7c12ccc9bf8beb8590563.tar.gz |
app: Store the appropriate window size
We cannot use the window's allocation, because that will not take into
account client side decorations.
Diffstat (limited to 'src')
-rw-r--r-- | src/gdict-window.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/gdict-window.c b/src/gdict-window.c index 4e56096..8ce0121 100644 --- a/src/gdict-window.c +++ b/src/gdict-window.c @@ -1297,15 +1297,15 @@ gdict_window_size_allocate (GtkWidget *widget, { GdictWindow *window = GDICT_WINDOW (widget); + if (GTK_WIDGET_CLASS (gdict_window_parent_class)->size_allocate != NULL) + GTK_WIDGET_CLASS (gdict_window_parent_class)->size_allocate (widget, allocation); + if (!window->is_maximized) { - window->current_width = allocation->width; - window->current_height = allocation->height; + gtk_window_get_size (GTK_WINDOW (widget), + &window->current_width, + &window->current_height); } - - if (GTK_WIDGET_CLASS (gdict_window_parent_class)->size_allocate) - GTK_WIDGET_CLASS (gdict_window_parent_class)->size_allocate (widget, - allocation); } static void |