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

Side by Side Diff: ui/views/view.cc

Issue 1915363002: Rename gfx::Display/Screen to display::Display/Screen in views/wm (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: more cleanups Created 4 years, 7 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
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 #define _USE_MATH_DEFINES // For VC++ to get M_PI. This has to be first. 5 #define _USE_MATH_DEFINES // For VC++ to get M_PI. This has to be first.
6 6
7 #include "ui/views/view.h" 7 #include "ui/views/view.h"
8 8
9 #include <algorithm> 9 #include <algorithm>
10 #include <cmath> 10 #include <cmath>
(...skipping 15 matching lines...) Expand all
26 #include "ui/base/dragdrop/drag_drop_types.h" 26 #include "ui/base/dragdrop/drag_drop_types.h"
27 #include "ui/base/ime/input_method.h" 27 #include "ui/base/ime/input_method.h"
28 #include "ui/compositor/clip_recorder.h" 28 #include "ui/compositor/clip_recorder.h"
29 #include "ui/compositor/compositor.h" 29 #include "ui/compositor/compositor.h"
30 #include "ui/compositor/dip_util.h" 30 #include "ui/compositor/dip_util.h"
31 #include "ui/compositor/layer.h" 31 #include "ui/compositor/layer.h"
32 #include "ui/compositor/layer_animator.h" 32 #include "ui/compositor/layer_animator.h"
33 #include "ui/compositor/paint_context.h" 33 #include "ui/compositor/paint_context.h"
34 #include "ui/compositor/paint_recorder.h" 34 #include "ui/compositor/paint_recorder.h"
35 #include "ui/compositor/transform_recorder.h" 35 #include "ui/compositor/transform_recorder.h"
36 #include "ui/display/screen.h"
36 #include "ui/events/event_target_iterator.h" 37 #include "ui/events/event_target_iterator.h"
37 #include "ui/gfx/canvas.h" 38 #include "ui/gfx/canvas.h"
38 #include "ui/gfx/geometry/point3_f.h" 39 #include "ui/gfx/geometry/point3_f.h"
39 #include "ui/gfx/geometry/point_conversions.h" 40 #include "ui/gfx/geometry/point_conversions.h"
40 #include "ui/gfx/interpolated_transform.h" 41 #include "ui/gfx/interpolated_transform.h"
41 #include "ui/gfx/path.h" 42 #include "ui/gfx/path.h"
42 #include "ui/gfx/scoped_canvas.h" 43 #include "ui/gfx/scoped_canvas.h"
43 #include "ui/gfx/screen.h"
44 #include "ui/gfx/skia_util.h" 44 #include "ui/gfx/skia_util.h"
45 #include "ui/gfx/transform.h" 45 #include "ui/gfx/transform.h"
46 #include "ui/native_theme/native_theme.h" 46 #include "ui/native_theme/native_theme.h"
47 #include "ui/views/accessibility/native_view_accessibility.h" 47 #include "ui/views/accessibility/native_view_accessibility.h"
48 #include "ui/views/background.h" 48 #include "ui/views/background.h"
49 #include "ui/views/border.h" 49 #include "ui/views/border.h"
50 #include "ui/views/context_menu_controller.h" 50 #include "ui/views/context_menu_controller.h"
51 #include "ui/views/drag_controller.h" 51 #include "ui/views/drag_controller.h"
52 #include "ui/views/focus/view_storage.h" 52 #include "ui/views/focus/view_storage.h"
53 #include "ui/views/layout/layout_manager.h" 53 #include "ui/views/layout/layout_manager.h"
(...skipping 893 matching lines...) Expand 10 before | Expand all | Expand 10 after
947 // If we haven't yet been placed in an onscreen view hierarchy, we can't be 947 // If we haven't yet been placed in an onscreen view hierarchy, we can't be
948 // hovered. 948 // hovered.
949 if (!GetWidget()) 949 if (!GetWidget())
950 return false; 950 return false;
951 951
952 // If mouse events are disabled, then the mouse cursor is invisible and 952 // If mouse events are disabled, then the mouse cursor is invisible and
953 // is therefore not hovering over this button. 953 // is therefore not hovering over this button.
954 if (!GetWidget()->IsMouseEventsEnabled()) 954 if (!GetWidget()->IsMouseEventsEnabled())
955 return false; 955 return false;
956 956
957 gfx::Point cursor_pos(gfx::Screen::GetScreen()->GetCursorScreenPoint()); 957 gfx::Point cursor_pos(display::Screen::GetScreen()->GetCursorScreenPoint());
958 ConvertPointFromScreen(this, &cursor_pos); 958 ConvertPointFromScreen(this, &cursor_pos);
959 return HitTestPoint(cursor_pos); 959 return HitTestPoint(cursor_pos);
960 } 960 }
961 961
962 bool View::OnMousePressed(const ui::MouseEvent& event) { 962 bool View::OnMousePressed(const ui::MouseEvent& event) {
963 return false; 963 return false;
964 } 964 }
965 965
966 bool View::OnMouseDragged(const ui::MouseEvent& event) { 966 bool View::OnMouseDragged(const ui::MouseEvent& event) {
967 return false; 967 return false;
(...skipping 1456 matching lines...) Expand 10 before | Expand all | Expand 10 after
2424 // Message the RootView to do the drag and drop. That way if we're removed 2424 // Message the RootView to do the drag and drop. That way if we're removed
2425 // the RootView can detect it and avoid calling us back. 2425 // the RootView can detect it and avoid calling us back.
2426 gfx::Point widget_location(event.location()); 2426 gfx::Point widget_location(event.location());
2427 ConvertPointToWidget(this, &widget_location); 2427 ConvertPointToWidget(this, &widget_location);
2428 widget->RunShellDrag(this, data, widget_location, drag_operations, source); 2428 widget->RunShellDrag(this, data, widget_location, drag_operations, source);
2429 // WARNING: we may have been deleted. 2429 // WARNING: we may have been deleted.
2430 return true; 2430 return true;
2431 } 2431 }
2432 2432
2433 } // namespace views 2433 } // namespace views
OLDNEW
« no previous file with comments | « ui/views/touchui/touch_selection_controller_impl.cc ('k') | ui/views/widget/desktop_aura/desktop_cursor_loader_updater.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698