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

Side by Side Diff: ash/drag_drop/drag_image_view.cc

Issue 2729363002: chromeos: Move files in //ash/common to //ash, part 3 (Closed)
Patch Set: Created 3 years, 9 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
« no previous file with comments | « ash/drag_drop/drag_drop_tracker_unittest.cc ('k') | ash/extended_desktop_unittest.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 "ash/drag_drop/drag_image_view.h" 5 #include "ash/drag_drop/drag_image_view.h"
6 6
7 #include <memory> 7 #include <memory>
8 8
9 #include "ash/common/wm_window.h"
10 #include "ash/public/cpp/shell_window_ids.h" 9 #include "ash/public/cpp/shell_window_ids.h"
11 #include "ash/root_window_controller.h" 10 #include "ash/root_window_controller.h"
11 #include "ash/wm_window.h"
12 #include "skia/ext/image_operations.h" 12 #include "skia/ext/image_operations.h"
13 #include "ui/base/resource/resource_bundle.h" 13 #include "ui/base/resource/resource_bundle.h"
14 #include "ui/display/display.h" 14 #include "ui/display/display.h"
15 #include "ui/gfx/canvas.h" 15 #include "ui/gfx/canvas.h"
16 #include "ui/resources/grit/ui_resources.h" 16 #include "ui/resources/grit/ui_resources.h"
17 #include "ui/views/widget/widget.h" 17 #include "ui/views/widget/widget.h"
18 18
19 namespace ash { 19 namespace ash {
20 namespace { 20 namespace {
21 using views::Widget; 21 using views::Widget;
(...skipping 177 matching lines...) Expand 10 before | Expand all | Expand 10 after
199 // Enlarge widget if required to fit the drag hint image. 199 // Enlarge widget if required to fit the drag hint image.
200 gfx::Size widget_size = widget_->GetWindowBoundsInScreen().size(); 200 gfx::Size widget_size = widget_->GetWindowBoundsInScreen().size();
201 if (drag_hint_size.width() > widget_size.width() || 201 if (drag_hint_size.width() > widget_size.width() ||
202 drag_hint_size.height() > widget_size.height()) { 202 drag_hint_size.height() > widget_size.height()) {
203 widget_size.SetToMax(drag_hint_size); 203 widget_size.SetToMax(drag_hint_size);
204 widget_->SetSize(widget_size); 204 widget_->SetSize(widget_size);
205 } 205 }
206 } 206 }
207 207
208 } // namespace ash 208 } // namespace ash
OLDNEW
« no previous file with comments | « ash/drag_drop/drag_drop_tracker_unittest.cc ('k') | ash/extended_desktop_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698