| OLD | NEW |
| 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/frame/opaque_browser_frame_view.h" | 5 #include "chrome/browser/views/frame/opaque_browser_frame_view.h" |
| 6 | 6 |
| 7 #include "chrome/browser/views/frame/browser_frame.h" | 7 #include "chrome/browser/views/frame/browser_frame.h" |
| 8 #include "chrome/browser/views/frame/browser_view.h" | 8 #include "chrome/browser/views/frame/browser_view.h" |
| 9 #include "chrome/browser/views/tabs/tab_strip.h" | 9 #include "chrome/browser/views/tabs/tab_strip.h" |
| 10 #include "chrome/common/gfx/chrome_canvas.h" | 10 #include "chrome/common/gfx/chrome_canvas.h" |
| (...skipping 575 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 586 views::View* parent, | 586 views::View* parent, |
| 587 views::View* child) { | 587 views::View* child) { |
| 588 if (is_add && child == this) { | 588 if (is_add && child == this) { |
| 589 // The Accessibility glue looks for the product name on these two views to | 589 // The Accessibility glue looks for the product name on these two views to |
| 590 // determine if this is in fact a Chrome window. | 590 // determine if this is in fact a Chrome window. |
| 591 GetRootView()->SetAccessibleName(l10n_util::GetString(IDS_PRODUCT_NAME)); | 591 GetRootView()->SetAccessibleName(l10n_util::GetString(IDS_PRODUCT_NAME)); |
| 592 SetAccessibleName(l10n_util::GetString(IDS_PRODUCT_NAME)); | 592 SetAccessibleName(l10n_util::GetString(IDS_PRODUCT_NAME)); |
| 593 } | 593 } |
| 594 } | 594 } |
| 595 | 595 |
| 596 bool OpaqueBrowserFrameView::GetAccessibleRole(VARIANT* role) { | 596 bool OpaqueBrowserFrameView::GetAccessibleRole(AccessibilityTypes::Role* role) { |
| 597 DCHECK(role); | 597 DCHECK(role); |
| 598 // We aren't actually the client area of the window, but we act like it as | 598 // We aren't actually the client area of the window, but we act like it as |
| 599 // far as MSAA and the UI tests are concerned. | 599 // far as accessibility and the UI tests are concerned. |
| 600 role->vt = VT_I4; | 600 *role = AccessibilityTypes::ROLE_CLIENT; |
| 601 role->lVal = ROLE_SYSTEM_CLIENT; | |
| 602 return true; | 601 return true; |
| 603 } | 602 } |
| 604 | 603 |
| 605 bool OpaqueBrowserFrameView::GetAccessibleName(std::wstring* name) { | 604 bool OpaqueBrowserFrameView::GetAccessibleName(std::wstring* name) { |
| 606 if (!accessible_name_.empty()) { | 605 if (!accessible_name_.empty()) { |
| 607 *name = accessible_name_; | 606 *name = accessible_name_; |
| 608 return true; | 607 return true; |
| 609 } | 608 } |
| 610 return false; | 609 return false; |
| 611 } | 610 } |
| (...skipping 446 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1058 } | 1057 } |
| 1059 | 1058 |
| 1060 // static | 1059 // static |
| 1061 void OpaqueBrowserFrameView::InitAppWindowResources() { | 1060 void OpaqueBrowserFrameView::InitAppWindowResources() { |
| 1062 static bool initialized = false; | 1061 static bool initialized = false; |
| 1063 if (!initialized) { | 1062 if (!initialized) { |
| 1064 title_font_ = new ChromeFont(win_util::GetWindowTitleFont()); | 1063 title_font_ = new ChromeFont(win_util::GetWindowTitleFont()); |
| 1065 initialized = true; | 1064 initialized = true; |
| 1066 } | 1065 } |
| 1067 } | 1066 } |
| OLD | NEW |