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

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

Issue 9076002: Initial views touchui Gesture Recognizer support (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix win release build Created 8 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 | « ui/views/touchui/gesture_recognizer.cc ('k') | ui/views/view.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 #ifndef UI_VIEWS_VIEW_H_ 5 #ifndef UI_VIEWS_VIEW_H_
6 #define UI_VIEWS_VIEW_H_ 6 #define UI_VIEWS_VIEW_H_
7 #pragma once 7 #pragma once
8 8
9 #include <algorithm> 9 #include <algorithm>
10 #include <map> 10 #include <map>
(...skipping 564 matching lines...) Expand 10 before | Expand all | Expand 10 after
575 575
576 // This method is invoked when the mouse exits this control 576 // This method is invoked when the mouse exits this control
577 // The provided event location is always (0, 0) 577 // The provided event location is always (0, 0)
578 // Default implementation does nothing. Override as needed. 578 // Default implementation does nothing. Override as needed.
579 virtual void OnMouseExited(const MouseEvent& event); 579 virtual void OnMouseExited(const MouseEvent& event);
580 580
581 // This method is invoked for each touch event. Default implementation 581 // This method is invoked for each touch event. Default implementation
582 // does nothing. Override as needed. 582 // does nothing. Override as needed.
583 virtual ui::TouchStatus OnTouchEvent(const TouchEvent& event); 583 virtual ui::TouchStatus OnTouchEvent(const TouchEvent& event);
584 584
585 // This method is invoked for each GestureEvent recognized from GestureManager
586 // Default implementation does nothing. Override as needed.
587 virtual ui::GestureStatus OnGestureEvent(const GestureEvent& event);
588
585 // Set the MouseHandler for a drag session. 589 // Set the MouseHandler for a drag session.
586 // 590 //
587 // A drag session is a stream of mouse events starting 591 // A drag session is a stream of mouse events starting
588 // with a MousePressed event, followed by several MouseDragged 592 // with a MousePressed event, followed by several MouseDragged
589 // events and finishing with a MouseReleased event. 593 // events and finishing with a MouseReleased event.
590 // 594 //
591 // This method should be only invoked while processing a 595 // This method should be only invoked while processing a
592 // MouseDragged or MousePressed event. 596 // MouseDragged or MousePressed event.
593 // 597 //
594 // All further mouse dragged and mouse up events will be sent 598 // All further mouse dragged and mouse up events will be sent
(...skipping 655 matching lines...) Expand 10 before | Expand all | Expand 10 after
1250 // RootView invokes these. These in turn invoke the appropriate OnMouseXXX 1254 // RootView invokes these. These in turn invoke the appropriate OnMouseXXX
1251 // method. If a drag is detected, DoDrag is invoked. 1255 // method. If a drag is detected, DoDrag is invoked.
1252 bool ProcessMousePressed(const MouseEvent& event, DragInfo* drop_info); 1256 bool ProcessMousePressed(const MouseEvent& event, DragInfo* drop_info);
1253 bool ProcessMouseDragged(const MouseEvent& event, DragInfo* drop_info); 1257 bool ProcessMouseDragged(const MouseEvent& event, DragInfo* drop_info);
1254 void ProcessMouseReleased(const MouseEvent& event); 1258 void ProcessMouseReleased(const MouseEvent& event);
1255 1259
1256 // RootView will invoke this with incoming TouchEvents. Returns the 1260 // RootView will invoke this with incoming TouchEvents. Returns the
1257 // the result of OnTouchEvent. 1261 // the result of OnTouchEvent.
1258 ui::TouchStatus ProcessTouchEvent(const TouchEvent& event); 1262 ui::TouchStatus ProcessTouchEvent(const TouchEvent& event);
1259 1263
1264 // GestureManager will invoke this with incoming GestureEvents. Returns the
1265 // the result of OnGestureEvent.
1266 ui::GestureStatus ProcessGestureEvent(const GestureEvent& event);
1267
1260 // Accelerators -------------------------------------------------------------- 1268 // Accelerators --------------------------------------------------------------
1261 1269
1262 // Registers this view's keyboard accelerators that are not registered to 1270 // Registers this view's keyboard accelerators that are not registered to
1263 // FocusManager yet, if possible. 1271 // FocusManager yet, if possible.
1264 void RegisterPendingAccelerators(); 1272 void RegisterPendingAccelerators();
1265 1273
1266 // Unregisters all the keyboard accelerators associated with this view. 1274 // Unregisters all the keyboard accelerators associated with this view.
1267 // |leave_data_intact| if true does not remove data from accelerators_ array, 1275 // |leave_data_intact| if true does not remove data from accelerators_ array,
1268 // so it could be re-registered with other focus manager 1276 // so it could be re-registered with other focus manager
1269 void UnregisterAccelerators(bool leave_data_intact); 1277 void UnregisterAccelerators(bool leave_data_intact);
(...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after
1429 base::win::ScopedComPtr<NativeViewAccessibilityWin> 1437 base::win::ScopedComPtr<NativeViewAccessibilityWin>
1430 native_view_accessibility_win_; 1438 native_view_accessibility_win_;
1431 #endif 1439 #endif
1432 1440
1433 DISALLOW_COPY_AND_ASSIGN(View); 1441 DISALLOW_COPY_AND_ASSIGN(View);
1434 }; 1442 };
1435 1443
1436 } // namespace views 1444 } // namespace views
1437 1445
1438 #endif // UI_VIEWS_VIEW_H_ 1446 #endif // UI_VIEWS_VIEW_H_
OLDNEW
« no previous file with comments | « ui/views/touchui/gesture_recognizer.cc ('k') | ui/views/view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698