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

Unified Diff: chrome/browser/ui/ash/tabs/dock_info_ash.cc

Issue 10827022: Fix coordinates in tab detach &drag code and multi window resizer. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: sync Created 8 years, 5 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 | « ash/wm/workspace/workspace_window_resizer.cc ('k') | chrome/browser/ui/views/tabs/tab_drag_controller.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/ash/tabs/dock_info_ash.cc
diff --git a/chrome/browser/ui/ash/tabs/dock_info_ash.cc b/chrome/browser/ui/ash/tabs/dock_info_ash.cc
index e5208c1e907a4b8da20eb635549612f35f444fcd..13bb0a0efbd690d54593942d28f390f3c3fef6f0 100644
--- a/chrome/browser/ui/ash/tabs/dock_info_ash.cc
+++ b/chrome/browser/ui/ash/tabs/dock_info_ash.cc
@@ -5,6 +5,7 @@
#include "chrome/browser/ui/tabs/dock_info.h"
#include "ash/shell.h"
+#include "ui/aura/client/screen_position_client.h"
#include "ui/aura/root_window.h"
#include "ui/aura/window.h"
#include "ui/compositor/layer.h"
@@ -25,9 +26,8 @@ aura::Window* GetLocalProcessWindowAtPointImpl(
if (window->layer()->type() == ui::LAYER_TEXTURED) {
gfx::Point window_point(screen_point);
- aura::Window::ConvertPointToWindow(ash::Shell::GetPrimaryRootWindow(),
- window,
- &window_point);
+ aura::client::GetScreenPositionClient(window->GetRootWindow())->
+ ConvertPointFromScreen(window, &window_point);
return gfx::Rect(window->bounds().size()).Contains(window_point) ?
window : NULL;
}
@@ -56,7 +56,7 @@ gfx::NativeView DockInfo::GetLocalProcessWindowAtPoint(
const gfx::Point& screen_point,
const std::set<gfx::NativeView>& ignore) {
return GetLocalProcessWindowAtPointImpl(
- screen_point, ignore, ash::Shell::GetPrimaryRootWindow());
+ screen_point, ignore, ash::Shell::GetRootWindowAt(screen_point));
}
bool DockInfo::GetWindowBounds(gfx::Rect* bounds) const {
« no previous file with comments | « ash/wm/workspace/workspace_window_resizer.cc ('k') | chrome/browser/ui/views/tabs/tab_drag_controller.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698