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

Side by Side Diff: ui/views/events/event.cc

Issue 10832282: Replace views::MouseEvent with ui::MouseEvent (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 4 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 | « ui/views/events/event.h ('k') | ui/views/events/event_aura.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/views/events/event.h" 5 #include "ui/views/events/event.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "ui/base/keycodes/keyboard_code_conversion.h" 8 #include "ui/base/keycodes/keyboard_code_conversion.h"
9 #include "ui/views/view.h" 9 #include "ui/views/view.h"
10 #include "ui/views/widget/root_view.h" 10 #include "ui/views/widget/root_view.h"
11 11
12 namespace views { 12 namespace views {
13 13
14 //////////////////////////////////////////////////////////////////////////////// 14 ////////////////////////////////////////////////////////////////////////////////
15 // MouseEvent, public:
16
17 #if !defined(USE_AURA)
18 MouseEvent::MouseEvent(const ui::NativeEvent& native_event)
19 : LocatedEvent(native_event) {
20 }
21 #endif
22
23 MouseEvent::MouseEvent(const MouseEvent& model, View* source, View* target)
24 : LocatedEvent(model, source, target) {
25 }
26
27 ////////////////////////////////////////////////////////////////////////////////
28 // MouseWheelEvent, public: 15 // MouseWheelEvent, public:
29 16
30 #if !defined(USE_AURA) 17 #if !defined(USE_AURA)
31 MouseWheelEvent::MouseWheelEvent(const ui::NativeEvent& native_event) 18 MouseWheelEvent::MouseWheelEvent(const ui::NativeEvent& native_event)
32 : MouseEvent(native_event), 19 : MouseEvent(native_event),
33 offset_(ui::GetMouseWheelOffset(native_event)) { 20 offset_(ui::GetMouseWheelOffset(native_event)) {
34 } 21 }
35 #endif 22 #endif
36 23
37 MouseWheelEvent::MouseWheelEvent(const ScrollEvent& scroll_event) 24 MouseWheelEvent::MouseWheelEvent(const ScrollEvent& scroll_event)
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
105 } 92 }
106 93
107 GestureEventForTest::GestureEventForTest(ui::EventType type, 94 GestureEventForTest::GestureEventForTest(ui::EventType type,
108 int x, 95 int x,
109 int y, 96 int y,
110 int flags) 97 int flags)
111 : GestureEvent(type, x, y, flags) { 98 : GestureEvent(type, x, y, flags) {
112 } 99 }
113 100
114 } // namespace views 101 } // namespace views
OLDNEW
« no previous file with comments | « ui/views/events/event.h ('k') | ui/views/events/event_aura.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698