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

Side by Side Diff: chrome/browser/views/toolbar_view.cc

Issue 93085: Removes the use of Windows-specific types for accessibility roles and states ... (Closed) Base URL: svn://chrome-svn/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/browser/views/toolbar_view.h ('k') | chrome/common/accessibility_types.h » ('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) 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/browser/views/toolbar_view.h" 5 #include "chrome/browser/views/toolbar_view.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 719 matching lines...) Expand 10 before | Expand all | Expand 10 after
730 } 730 }
731 731
732 bool BrowserToolbarView::GetAccessibleName(std::wstring* name) { 732 bool BrowserToolbarView::GetAccessibleName(std::wstring* name) {
733 if (!accessible_name_.empty()) { 733 if (!accessible_name_.empty()) {
734 (*name).assign(accessible_name_); 734 (*name).assign(accessible_name_);
735 return true; 735 return true;
736 } 736 }
737 return false; 737 return false;
738 } 738 }
739 739
740 bool BrowserToolbarView::GetAccessibleRole(VARIANT* role) { 740 bool BrowserToolbarView::GetAccessibleRole(AccessibilityTypes::Role* role) {
741 DCHECK(role); 741 DCHECK(role);
742 742
743 role->vt = VT_I4; 743 *role = AccessibilityTypes::ROLE_TOOLBAR;
744 role->lVal = ROLE_SYSTEM_TOOLBAR;
745 return true; 744 return true;
746 } 745 }
747 746
748 void BrowserToolbarView::SetAccessibleName(const std::wstring& name) { 747 void BrowserToolbarView::SetAccessibleName(const std::wstring& name) {
749 accessible_name_.assign(name); 748 accessible_name_.assign(name);
750 } 749 }
751 750
752 int BrowserToolbarView::GetNextAccessibleViewIndex(int view_index, 751 int BrowserToolbarView::GetNextAccessibleViewIndex(int view_index,
753 bool nav_left) { 752 bool nav_left) {
754 int modifier = 1; 753 int modifier = 1;
(...skipping 146 matching lines...) Expand 10 before | Expand all | Expand 10 after
901 case IDC_COPY: 900 case IDC_COPY:
902 *accel = views::Accelerator(L'C', false, true, false); 901 *accel = views::Accelerator(L'C', false, true, false);
903 return true; 902 return true;
904 case IDC_PASTE: 903 case IDC_PASTE:
905 *accel = views::Accelerator(L'V', false, true, false); 904 *accel = views::Accelerator(L'V', false, true, false);
906 return true; 905 return true;
907 } 906 }
908 // Else, we retrieve the accelerator information from the frame. 907 // Else, we retrieve the accelerator information from the frame.
909 return GetWidget()->GetAccelerator(id, accel); 908 return GetWidget()->GetAccelerator(id, accel);
910 } 909 }
OLDNEW
« no previous file with comments | « chrome/browser/views/toolbar_view.h ('k') | chrome/common/accessibility_types.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698