diff options
author | varunjain@chromium.org <varunjain@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-06-19 21:25:34 +0000 |
---|---|---|
committer | varunjain@chromium.org <varunjain@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-06-19 21:25:34 +0000 |
commit | c600edba1fabe1b49f54a804ce150f18a5a3dfb2 (patch) | |
tree | a42c214f7ba508f1a8490539417c1104137c2812 /ui/views/drag_utils.h | |
parent | 539df6c7207426d0626ee1bc76cf6f9a2f3766c0 (diff) | |
download | chromium_src-c600edba1fabe1b49f54a804ce150f18a5a3dfb2.zip chromium_src-c600edba1fabe1b49f54a804ce150f18a5a3dfb2.tar.gz chromium_src-c600edba1fabe1b49f54a804ce150f18a5a3dfb2.tar.bz2 |
views: Account for device scale factor when drawing drag images for views.
BUG=128820
TEST=manual
Review URL: https://chromiumcodereview.appspot.com/10574014
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@143052 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ui/views/drag_utils.h')
-rw-r--r-- | ui/views/drag_utils.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/ui/views/drag_utils.h b/ui/views/drag_utils.h index 5339f52..b30d130 100644 --- a/ui/views/drag_utils.h +++ b/ui/views/drag_utils.h @@ -10,7 +10,9 @@ #include "ui/views/views_export.h" namespace gfx { +class Canvas; class Point; +class Size; } namespace ui { @@ -18,6 +20,7 @@ class OSExchangeData; } namespace views { +class Widget; // Starts a drag operation. This blocks until the drag operation completes. VIEWS_EXPORT void RunShellDrag(gfx::NativeView view, @@ -25,6 +28,11 @@ VIEWS_EXPORT void RunShellDrag(gfx::NativeView view, const gfx::Point& location, int operation); +// Returns a canvas that can be used to draw the drag image. Caller owns the +// returned object. |widget| is Widget hosting the view being dragged. +VIEWS_EXPORT gfx::Canvas* GetCanvasForDragImage(Widget* widget, + const gfx::Size& canvas_size); + } // namespace views #endif // UI_VIEWS_DRAG_UTILS_H_ |