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

Unified Diff: chrome/browser/sessions/session_restore.cc

Issue 11085053: Improving window auto management between workspaces (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixed merge problems with trunk Created 8 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: chrome/browser/sessions/session_restore.cc
diff --git a/chrome/browser/sessions/session_restore.cc b/chrome/browser/sessions/session_restore.cc
index 40ebe2761ec79cbb6c314d589f7060f957385c24..4a134601db2a9d09c6329d0c045d42b635a51da3 100644
--- a/chrome/browser/sessions/session_restore.cc
+++ b/chrome/browser/sessions/session_restore.cc
@@ -57,6 +57,9 @@
#include "base/win/metro.h"
#endif
+#if defined(USE_ASH)
+#include "ash/wm/window_util.h"
+#endif
using content::NavigationController;
using content::RenderWidgetHost;
using content::WebContents;
@@ -1020,7 +1023,16 @@ class SessionRestoreImpl : public content::NotificationObserver {
if (browser_ == browser)
return;
+#if defined(USE_ASH)
+ // Prevent the auto window management for this window on show.
+ ash::wm::SetUserHasChangedWindowPositionOrSize(
+ browser->window()->GetNativeWindow(), true);
+#endif
browser->window()->Show();
+#if defined(USE_ASH)
+ ash::wm::SetUserHasChangedWindowPositionOrSize(
+ browser->window()->GetNativeWindow(), false);
+#endif
browser->set_is_session_restore(false);
// TODO(jcampan): http://crbug.com/8123 we should not need to set the

Powered by Google App Engine
This is Rietveld 408576698