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

Unified Diff: ui/views/widget/desktop_native_widget_helper_aura.cc

Issue 10560014: Aura desktop: Fix tab dragging within a single chrome window. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix filename so windows is excluded. Created 8 years, 6 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
« no previous file with comments | « ui/views/widget/desktop_native_widget_helper_aura.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/widget/desktop_native_widget_helper_aura.cc
diff --git a/ui/views/widget/desktop_native_widget_helper_aura.cc b/ui/views/widget/desktop_native_widget_helper_aura.cc
index efc0493821526f211803ee736af9356e855b2f8f..563d6ea6f58836bd25112946777aafcaafa6bcd8 100644
--- a/ui/views/widget/desktop_native_widget_helper_aura.cc
+++ b/ui/views/widget/desktop_native_widget_helper_aura.cc
@@ -14,6 +14,7 @@
#include "ui/aura/shared/compound_event_filter.h"
#include "ui/aura/shared/input_method_event_filter.h"
#include "ui/aura/shared/root_window_capture_client.h"
+#include "ui/aura/window_property.h"
#include "ui/views/widget/native_widget_aura.h"
#if defined(OS_WIN)
@@ -23,8 +24,13 @@
#include "ui/views/widget/x11_window_event_filter.h"
#endif
+DECLARE_WINDOW_PROPERTY_TYPE(aura::Window*);
+
namespace views {
+DEFINE_WINDOW_PROPERTY_KEY(
+ aura::Window*, kViewsWindowForRootWindow, NULL);
+
namespace {
// Client that always offsets the passed in point by the RootHost's origin.
@@ -85,6 +91,12 @@ DesktopNativeWidgetHelperAura::~DesktopNativeWidgetHelperAura() {
}
}
+// static
+aura::Window* DesktopNativeWidgetHelperAura::GetViewsWindowForRootWindow(
+ aura::RootWindow* root) {
+ return root ? root->GetProperty(kViewsWindowForRootWindow) : NULL;
+}
+
void DesktopNativeWidgetHelperAura::PreInitialize(
aura::Window* window,
const Widget::InitParams& params) {
@@ -115,6 +127,7 @@ void DesktopNativeWidgetHelperAura::PreInitialize(
// cursor's shape and visibility.
root_window_.reset(new aura::RootWindow(bounds));
+ root_window_->SetProperty(kViewsWindowForRootWindow, window);
root_window_->Init();
root_window_->set_focus_manager(new aura::FocusManager);
« no previous file with comments | « ui/views/widget/desktop_native_widget_helper_aura.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698