summaryrefslogtreecommitdiffstats
path: root/ui/aura
diff options
context:
space:
mode:
authorerg@chromium.org <erg@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-06-16 02:29:15 +0000
committererg@chromium.org <erg@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-06-16 02:29:15 +0000
commit37be9eb6d97048f8f20bdad30e8756b7e03eeba5 (patch)
treea0a517bf07bb5081b96c75e729bd2fa499fb82fd /ui/aura
parent176279560e39373b5e5e6a9b95459f4aecd89165 (diff)
downloadchromium_src-37be9eb6d97048f8f20bdad30e8756b7e03eeba5.zip
chromium_src-37be9eb6d97048f8f20bdad30e8756b7e03eeba5.tar.gz
chromium_src-37be9eb6d97048f8f20bdad30e8756b7e03eeba5.tar.bz2
Aura desktop: Fix tab dragging within a single chrome window.
Tabs can now be reordered inside a single chrome window on linux_aura. Multiselection works too. Dragging out of a window doesn't work yet. Most of dock_info_aura.cc has been copied from dock_info_gtk.cc. A helper function was moved from gtk_util to x11_util (which only used pure X functions.) BUG=133059 TEST=none Review URL: https://chromiumcodereview.appspot.com/10560014 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@142568 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ui/aura')
-rw-r--r--ui/aura/root_window.cc7
-rw-r--r--ui/aura/root_window.h2
2 files changed, 9 insertions, 0 deletions
diff --git a/ui/aura/root_window.cc b/ui/aura/root_window.cc
index 6c6d6bb..d3c99d7 100644
--- a/ui/aura/root_window.cc
+++ b/ui/aura/root_window.cc
@@ -159,6 +159,13 @@ RootWindow::~RootWindow() {
layer()->GetAnimator()->RemoveObserver(this);
}
+// static
+RootWindow* RootWindow::GetForAcceleratedWidget(
+ gfx::AcceleratedWidget widget) {
+ RootWindowHost* host = RootWindowHost::GetForAcceleratedWidget(widget);
+ return host ? host->GetRootWindow() : NULL;
+}
+
void RootWindow::Init() {
compositor()->SetScaleAndSize(GetDeviceScaleFactorFromMonitor(this),
host_->GetBounds().size());
diff --git a/ui/aura/root_window.h b/ui/aura/root_window.h
index 2d13e76..4a9ac6a 100644
--- a/ui/aura/root_window.h
+++ b/ui/aura/root_window.h
@@ -84,6 +84,8 @@ class AURA_EXPORT RootWindow : public ui::CompositorDelegate,
explicit RootWindow(const gfx::Rect& initial_bounds);
virtual ~RootWindow();
+ static RootWindow* GetForAcceleratedWidget(gfx::AcceleratedWidget widget);
+
static void set_hide_host_cursor(bool hide) {
hide_host_cursor_ = hide;
}