mirror of
https://gitlab.gnome.org/GNOME/gitg
synced 2024-11-04 23:34:39 +00:00
Fix window growing each start
As described in bug 771290, the window got slightly larger each time gitg was run. This was due to the way we accidentally mixed APIs when saving/restoring the window size. To fix this, use GtkWindow methods when saving the window size. This is consistent with our prior use of GtkWindow methods to set the window size on startup. https://bugzilla.gnome.org/show_bug.cgi?id=771290
This commit is contained in:
parent
4ce63eeb37
commit
ec8d97d5c4
1 changed files with 3 additions and 1 deletions
|
@ -603,7 +603,9 @@ public class Window : Gtk.ApplicationWindow, GitgExt.Application, Initable
|
|||
{
|
||||
if (this.get_realized() && !(Gdk.WindowState.MAXIMIZED in get_window().get_state()))
|
||||
{
|
||||
d_state_settings.set("size", "(ii)", event.width, event.height);
|
||||
int width, height;
|
||||
get_size(out width, out height);
|
||||
d_state_settings.set("size", "(ii)", width, height);
|
||||
}
|
||||
|
||||
return base.configure_event(event);
|
||||
|
|
Loading…
Reference in a new issue