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

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

Issue 135863002: Reland Merge NativeTextfieldViews into views::Textfield. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Handle Ctrl-Shift-Delete and Backspace on Linux, like on ChromeOS. Created 6 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/touch_selection_controller_impl_unittest.cc ('k') | ui/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) 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 1313 matching lines...) Expand 10 before | Expand all | Expand 10 after
1324 return native_view_accessibility_->GetNativeObject(); 1324 return native_view_accessibility_->GetNativeObject();
1325 return NULL; 1325 return NULL;
1326 } 1326 }
1327 1327
1328 void View::NotifyAccessibilityEvent( 1328 void View::NotifyAccessibilityEvent(
1329 ui::AccessibilityTypes::Event event_type, 1329 ui::AccessibilityTypes::Event event_type,
1330 bool send_native_event) { 1330 bool send_native_event) {
1331 if (ViewsDelegate::views_delegate) 1331 if (ViewsDelegate::views_delegate)
1332 ViewsDelegate::views_delegate->NotifyAccessibilityEvent(this, event_type); 1332 ViewsDelegate::views_delegate->NotifyAccessibilityEvent(this, event_type);
1333 1333
1334 if (send_native_event) { 1334 if (send_native_event && GetWidget()) {
1335 if (!native_view_accessibility_) 1335 if (!native_view_accessibility_)
1336 native_view_accessibility_ = NativeViewAccessibility::Create(this); 1336 native_view_accessibility_ = NativeViewAccessibility::Create(this);
1337 if (native_view_accessibility_) 1337 if (native_view_accessibility_)
1338 native_view_accessibility_->NotifyAccessibilityEvent(event_type); 1338 native_view_accessibility_->NotifyAccessibilityEvent(event_type);
1339 } 1339 }
1340 } 1340 }
1341 1341
1342 // Scrolling ------------------------------------------------------------------- 1342 // Scrolling -------------------------------------------------------------------
1343 1343
1344 void View::ScrollRectToVisible(const gfx::Rect& rect) { 1344 void View::ScrollRectToVisible(const gfx::Rect& rect) {
(...skipping 1042 matching lines...) Expand 10 before | Expand all | Expand 10 after
2387 // Message the RootView to do the drag and drop. That way if we're removed 2387 // Message the RootView to do the drag and drop. That way if we're removed
2388 // the RootView can detect it and avoid calling us back. 2388 // the RootView can detect it and avoid calling us back.
2389 gfx::Point widget_location(event.location()); 2389 gfx::Point widget_location(event.location());
2390 ConvertPointToWidget(this, &widget_location); 2390 ConvertPointToWidget(this, &widget_location);
2391 widget->RunShellDrag(this, data, widget_location, drag_operations, source); 2391 widget->RunShellDrag(this, data, widget_location, drag_operations, source);
2392 // WARNING: we may have been deleted. 2392 // WARNING: we may have been deleted.
2393 return true; 2393 return true;
2394 } 2394 }
2395 2395
2396 } // namespace views 2396 } // namespace views
OLDNEW
« no previous file with comments | « ui/views/touchui/touch_selection_controller_impl_unittest.cc ('k') | ui/views/views.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698