diff options
author | Alberts Muktupāvels <alberts.muktupavels@gmail.com> | 2016-04-14 15:53:14 +0300 |
---|---|---|
committer | Alberts Muktupāvels <alberts.muktupavels@gmail.com> | 2016-04-14 15:53:14 +0300 |
commit | 003e470fe504593cdc235e2f75baddccbdc4dbe0 (patch) | |
tree | 5b9acb5e61a54c7c52cd702dce0d4aeb95af002d | |
parent | 73218846ca432d9335ed211c44e5113d99610a6d (diff) | |
download | metacity-003e470fe504593cdc235e2f75baddccbdc4dbe0.tar.gz |
window: use the correct frame size during unmaximize
When unmaximizing, we changed bits of window state, then called
out to code that used the frame extents *before* we cleared old
cached extents. Clear the cache up-front as soon as we change the
window state.
Based on mutter commit:
https://git.gnome.org/browse/mutter/commit/?id=8d5ab6b5b34a3dbeaba6033c31d06090579ed574
-rw-r--r-- | src/core/window.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/core/window.c b/src/core/window.c index 07ed8afa..f9dc5b63 100644 --- a/src/core/window.c +++ b/src/core/window.c @@ -2765,6 +2765,12 @@ meta_window_unmaximize (MetaWindow *window, window->maximized_vertically = window->maximized_vertically && !unmaximize_vertically; + /* recalc_window_features() will eventually clear the cached frame + * extents, but we need the correct frame extents in the code below, + * so invalidate the old frame extents manually up front. + */ + meta_window_frame_size_changed (window); + /* Unmaximize to the saved_rect position in the direction(s) * being unmaximized. */ |