diff options
author | ctguil@chromium.org <ctguil@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-03-22 22:34:54 +0000 |
---|---|---|
committer | ctguil@chromium.org <ctguil@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-03-22 22:34:54 +0000 |
commit | 8c157cf900b7ae30185b4905ac51c39dfc2c90ad (patch) | |
tree | a6cd5f97dd8af8cd9e38a6275119834d6801dbc7 /views | |
parent | 02aae3fac31e8ac28c5ee8c4b70e70dcef599dd0 (diff) | |
download | chromium_src-8c157cf900b7ae30185b4905ac51c39dfc2c90ad.zip chromium_src-8c157cf900b7ae30185b4905ac51c39dfc2c90ad.tar.gz chromium_src-8c157cf900b7ae30185b4905ac51c39dfc2c90ad.tar.bz2 |
views: [accessibility] Add accessible name for the Close button in generic Window.
BUG=9614
TEST=open AccExplorer, open a dialog window, point it to the Close button in the top-right corner, see if it shows Close as the accessible name.
Patch from Thiago Farina <thiago.farina@gmail.com>
Review URL: http://codereview.chromium.org/1155005
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@42270 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'views')
-rw-r--r-- | views/window/custom_frame_view.cc | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/views/window/custom_frame_view.cc b/views/window/custom_frame_view.cc index e45b998..d3d256f 100644 --- a/views/window/custom_frame_view.cc +++ b/views/window/custom_frame_view.cc @@ -6,6 +6,7 @@ #include "app/gfx/canvas.h" #include "app/gfx/font.h" +#include "app/l10n_util.h" #include "app/resource_bundle.h" #include "app/theme_provider.h" #if defined(OS_WIN) @@ -14,6 +15,7 @@ #endif #include "gfx/path.h" #include "grit/app_resources.h" +#include "grit/app_strings.h" #include "views/window/client_view.h" #if defined(OS_LINUX) #include "views/window/hit_test.h" @@ -72,6 +74,8 @@ CustomFrameView::CustomFrameView(Window* frame) ResourceBundle& rb = ResourceBundle::GetSharedInstance(); + close_button_->SetAccessibleName(l10n_util::GetString(IDS_APP_ACCNAME_CLOSE)); + // Close button images will be set in LayoutWindowControls(). AddChildView(close_button_); @@ -569,7 +573,7 @@ void CustomFrameView::InitClass() { #if defined(OS_WIN) title_font_ = new gfx::Font(win_util::GetWindowTitleFont()); #elif defined(OS_LINUX) - // TODO: need to resolve what font this is. + // TODO(ben): need to resolve what font this is. title_font_ = new gfx::Font(); #endif initialized = true; |