diff options
Diffstat (limited to 'core/browser.vala')
-rw-r--r-- | core/browser.vala | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/core/browser.vala b/core/browser.vala index f65a2ebd..23dd1b6f 100644 --- a/core/browser.vala +++ b/core/browser.vala @@ -320,6 +320,11 @@ namespace Midori { if (web_context.is_ephemeral ()) { get_style_context ().add_class ("incognito"); } + + if (settings.last_window_width > 0 && settings.last_window_height > 0) { + default_width = settings.last_window_width; + default_height = settings.last_window_height; + } } void update_decoration_layout () { @@ -340,6 +345,14 @@ namespace Midori { get_size (out width, null); is_small = width < 500; + if (!(get_style_context ().has_class ("tiled") || is_maximized || is_fullscreen)) { + int height; + get_size (null, out height); + var settings = CoreSettings.get_default (); + settings.last_window_width = width; + settings.last_window_height = height; + } + return result; } |