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

Side by Side Diff: views/mouse_watcher.cc

Issue 8621006: Remove most obvious TOUCH_UI code (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: revert file that CQ does not like. Created 9 years 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 | « views/controls/textfield/native_textfield_views_unittest.cc ('k') | views/views.gyp » ('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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 "views/mouse_watcher.h" 5 #include "views/mouse_watcher.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/compiler_specific.h" 8 #include "base/compiler_specific.h"
9 #include "base/event_types.h" 9 #include "base/event_types.h"
10 #include "base/memory/weak_ptr.h" 10 #include "base/memory/weak_ptr.h"
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
70 break; 70 break;
71 case base::wayland::WAYLAND_POINTER_FOCUS: 71 case base::wayland::WAYLAND_POINTER_FOCUS:
72 if (!event->pointer_focus.state) 72 if (!event->pointer_focus.state)
73 HandleGlobalMouseMoveEvent(true); 73 HandleGlobalMouseMoveEvent(true);
74 break; 74 break;
75 default: 75 default:
76 break; 76 break;
77 } 77 }
78 return EVENT_CONTINUE; 78 return EVENT_CONTINUE;
79 } 79 }
80 #elif defined(TOUCH_UI) || defined(USE_AURA) 80 #elif defined(USE_AURA)
81 virtual base::EventStatus WillProcessEvent( 81 virtual base::EventStatus WillProcessEvent(
82 const base::NativeEvent& event) OVERRIDE { 82 const base::NativeEvent& event) OVERRIDE {
83 return base::EVENT_CONTINUE; 83 return base::EVENT_CONTINUE;
84 } 84 }
85 virtual void DidProcessEvent(const base::NativeEvent& event) OVERRIDE { 85 virtual void DidProcessEvent(const base::NativeEvent& event) OVERRIDE {
86 switch (ui::EventTypeFromNative(event)) { 86 switch (ui::EventTypeFromNative(event)) {
87 case ui::ET_MOUSE_MOVED: 87 case ui::ET_MOUSE_MOVED:
88 case ui::ET_MOUSE_DRAGGED: 88 case ui::ET_MOUSE_DRAGGED:
89 // DRAGGED is a special case of MOVED. See events_win.cc/events_x.cc. 89 // DRAGGED is a special case of MOVED. See events_win.cc/events_x.cc.
90 HandleGlobalMouseMoveEvent(false); 90 HandleGlobalMouseMoveEvent(false);
(...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after
202 void MouseWatcher::Stop() { 202 void MouseWatcher::Stop() {
203 observer_.reset(NULL); 203 observer_.reset(NULL);
204 } 204 }
205 205
206 void MouseWatcher::NotifyListener() { 206 void MouseWatcher::NotifyListener() {
207 observer_.reset(NULL); 207 observer_.reset(NULL);
208 listener_->MouseMovedOutOfView(); 208 listener_->MouseMovedOutOfView();
209 } 209 }
210 210
211 } // namespace views 211 } // namespace views
OLDNEW
« no previous file with comments | « views/controls/textfield/native_textfield_views_unittest.cc ('k') | views/views.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698