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

Side by Side Diff: ui/base/dragdrop/drag_utils_aura.cc

Issue 11787005: Get drag and drop working on Win Ash. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: sync and take out dcheck for win Created 7 years, 11 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « ash/drag_drop/drag_drop_controller_unittest.cc ('k') | ui/base/dragdrop/drag_utils_win.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "ui/base/dragdrop/drag_utils.h" 5 #include "ui/base/dragdrop/drag_utils.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "ui/base/dragdrop/os_exchange_data.h" 8 #include "ui/base/dragdrop/os_exchange_data.h"
9 #include "ui/base/dragdrop/os_exchange_data_provider_aura.h"
10 #include "ui/gfx/canvas.h" 9 #include "ui/gfx/canvas.h"
11 #include "ui/gfx/image/image_skia.h" 10 #include "ui/gfx/image/image_skia.h"
12 #include "ui/gfx/size.h" 11 #include "ui/gfx/size.h"
13 #include "ui/gfx/vector2d.h" 12 #include "ui/gfx/vector2d.h"
14 13
15 namespace drag_utils { 14 namespace drag_utils {
16 15
17 void SetDragImageOnDataObject(const gfx::ImageSkia& image, 16 void SetDragImageOnDataObject(const gfx::ImageSkia& image,
18 const gfx::Size& size, 17 const gfx::Size& size,
19 const gfx::Vector2d& cursor_offset, 18 const gfx::Vector2d& cursor_offset,
20 ui::OSExchangeData* data_object) { 19 ui::OSExchangeData* data_object) {
21 ui::OSExchangeDataProviderAura& provider( 20
22 static_cast<ui::OSExchangeDataProviderAura&>(data_object->provider())); 21 data_object->provider().SetDragImage(image, cursor_offset);
23 provider.set_drag_image(image);
24 provider.set_drag_image_offset(cursor_offset);
25 } 22 }
26 23
27 } // namespace drag_utils 24 } // namespace drag_utils
OLDNEW
« no previous file with comments | « ash/drag_drop/drag_drop_controller_unittest.cc ('k') | ui/base/dragdrop/drag_utils_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698