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

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

Issue 2348143003: MacViews: Implement Force Touch/Mac dictionary lookup for Textfields. (Closed)
Patch Set: Address review. Created 4 years, 3 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
« ui/views/cocoa/bridged_content_view.mm ('K') | « ui/views/view.h ('k') | no next file » | 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 #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 903 matching lines...) Expand 10 before | Expand all | Expand 10 after
914 914
915 gfx::Point point_in_child_coords(point); 915 gfx::Point point_in_child_coords(point);
916 ConvertPointToTarget(this, child, &point_in_child_coords); 916 ConvertPointToTarget(this, child, &point_in_child_coords);
917 View* handler = child->GetTooltipHandlerForPoint(point_in_child_coords); 917 View* handler = child->GetTooltipHandlerForPoint(point_in_child_coords);
918 if (handler) 918 if (handler)
919 return handler; 919 return handler;
920 } 920 }
921 return this; 921 return this;
922 } 922 }
923 923
924 gfx::RenderText* View::GetRenderText() {
925 return nullptr;
926 }
927
924 gfx::NativeCursor View::GetCursor(const ui::MouseEvent& event) { 928 gfx::NativeCursor View::GetCursor(const ui::MouseEvent& event) {
925 #if defined(OS_WIN) 929 #if defined(OS_WIN)
926 static ui::Cursor arrow; 930 static ui::Cursor arrow;
927 if (!arrow.platform()) 931 if (!arrow.platform())
928 arrow.SetPlatformCursor(LoadCursor(NULL, IDC_ARROW)); 932 arrow.SetPlatformCursor(LoadCursor(NULL, IDC_ARROW));
929 return arrow; 933 return arrow;
930 #else 934 #else
931 return gfx::kNullCursor; 935 return gfx::kNullCursor;
932 #endif 936 #endif
933 } 937 }
(...skipping 1484 matching lines...) Expand 10 before | Expand all | Expand 10 after
2418 // Message the RootView to do the drag and drop. That way if we're removed 2422 // Message the RootView to do the drag and drop. That way if we're removed
2419 // the RootView can detect it and avoid calling us back. 2423 // the RootView can detect it and avoid calling us back.
2420 gfx::Point widget_location(event.location()); 2424 gfx::Point widget_location(event.location());
2421 ConvertPointToWidget(this, &widget_location); 2425 ConvertPointToWidget(this, &widget_location);
2422 widget->RunShellDrag(this, data, widget_location, drag_operations, source); 2426 widget->RunShellDrag(this, data, widget_location, drag_operations, source);
2423 // WARNING: we may have been deleted. 2427 // WARNING: we may have been deleted.
2424 return true; 2428 return true;
2425 } 2429 }
2426 2430
2427 } // namespace views 2431 } // namespace views
OLDNEW
« ui/views/cocoa/bridged_content_view.mm ('K') | « ui/views/view.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698