Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(70)

Unified Diff: ui/aura/desktop_host_linux.cc

Issue 8253001: aura: Some changes in Window and Desktop. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 9 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: ui/aura/desktop_host_linux.cc
diff --git a/ui/aura/desktop_host_linux.cc b/ui/aura/desktop_host_linux.cc
index 20112b1e46c64d570af4a30367f999eb44cc466f..768a33e27a09c5084fd503596c811e4107d5038e 100644
--- a/ui/aura/desktop_host_linux.cc
+++ b/ui/aura/desktop_host_linux.cc
@@ -98,8 +98,14 @@ base::MessagePumpDispatcher::DispatchStatus DesktopHostLinux::Dispatch(
DCHECK_EQ(xdisplay_, xev->xconfigure.display);
DCHECK_EQ(xwindow_, xev->xconfigure.window);
DCHECK_EQ(xwindow_, xev->xconfigure.event);
- desktop_->OnHostResized(gfx::Size(xev->xconfigure.width,
- xev->xconfigure.height));
+
+ // It's possible that the X window may be resized by some other means than
+ // from within aura (e.g. the X window manager can change the size). Make
+ // sure the desktop size is maintained properly.
+ gfx::Size size(xev->xconfigure.width, xev->xconfigure.height);
+ if (bounds_.size() != size)
+ bounds_.set_size(size);
+ desktop_->OnHostResized(size);
handled = true;
break;
}
« no previous file with comments | « ui/aura/desktop.cc ('k') | ui/aura/desktop_observer.h » ('j') | ui/aura/desktop_observer.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698