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

Side by Side Diff: chrome/views/widget/root_view.cc

Issue 92004: Fix focus rects for checkboxes and radio buttons:... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 11 years, 8 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 | « chrome/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) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 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 "chrome/views/widget/root_view.h" 5 #include "chrome/views/widget/root_view.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #if defined(OS_WIN) 9 #if defined(OS_WIN)
10 #include "base/base_drag_source.h" 10 #include "base/base_drag_source.h"
(...skipping 384 matching lines...) Expand 10 before | Expand all | Expand 10 after
395 395
396 bool RootView::OnMouseDragged(const MouseEvent& e) { 396 bool RootView::OnMouseDragged(const MouseEvent& e) {
397 UpdateCursor(e); 397 UpdateCursor(e);
398 398
399 if (mouse_pressed_handler_) { 399 if (mouse_pressed_handler_) {
400 SetMouseLocationAndFlags(e); 400 SetMouseLocationAndFlags(e);
401 401
402 gfx::Point p; 402 gfx::Point p;
403 ConvertPointToMouseHandler(e.location(), &p); 403 ConvertPointToMouseHandler(e.location(), &p);
404 MouseEvent mouse_event(e.GetType(), p.x(), p.y(), e.GetFlags()); 404 MouseEvent mouse_event(e.GetType(), p.x(), p.y(), e.GetFlags());
405 if (!mouse_pressed_handler_->ProcessMouseDragged(mouse_event, 405 return mouse_pressed_handler_->ProcessMouseDragged(mouse_event, &drag_info);
406 &drag_info)) {
407 mouse_pressed_handler_ = NULL;
408 return false;
409 } else {
410 return true;
411 }
412 } 406 }
413 return false; 407 return false;
414 } 408 }
415 409
416 void RootView::OnMouseReleased(const MouseEvent& e, bool canceled) { 410 void RootView::OnMouseReleased(const MouseEvent& e, bool canceled) {
417 UpdateCursor(e); 411 UpdateCursor(e);
418 412
419 if (mouse_pressed_handler_) { 413 if (mouse_pressed_handler_) {
420 gfx::Point p; 414 gfx::Point p;
421 ConvertPointToMouseHandler(e.location(), &p); 415 ConvertPointToMouseHandler(e.location(), &p);
(...skipping 554 matching lines...) Expand 10 before | Expand all | Expand 10 after
976 970
977 void RootView::SetAccessibleName(const std::wstring& name) { 971 void RootView::SetAccessibleName(const std::wstring& name) {
978 accessible_name_.assign(name); 972 accessible_name_.assign(name);
979 } 973 }
980 974
981 View* RootView::GetDragView() { 975 View* RootView::GetDragView() {
982 return drag_view_; 976 return drag_view_;
983 } 977 }
984 978
985 } // namespace views 979 } // namespace views
OLDNEW
« no previous file with comments | « chrome/views/view.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698