summaryrefslogtreecommitdiffstats
path: root/views/window
diff options
context:
space:
mode:
authorctguil@chromium.org <ctguil@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-05-27 23:00:03 +0000
committerctguil@chromium.org <ctguil@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-05-27 23:00:03 +0000
commitb82a049e6ffc65c14daf1c2c8bee6390cb7fe1fa (patch)
tree21f95e3df23460ae77342f865a24178d0cadba89 /views/window
parent6f496b2703a7ccb7bba1dbb14a2b9c00f02a853e (diff)
downloadchromium_src-b82a049e6ffc65c14daf1c2c8bee6390cb7fe1fa.zip
chromium_src-b82a049e6ffc65c14daf1c2c8bee6390cb7fe1fa.tar.gz
chromium_src-b82a049e6ffc65c14daf1c2c8bee6390cb7fe1fa.tar.bz2
Initial work to fix the IAccessible tree in circumstances where there is a widget not at the root of the UI heirarchy. Also contains misc fixes for setting correct name/role for controls found in the Options dialog.
BUG=9621 TEST=none Review URL: http://codereview.chromium.org/2174002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@48444 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'views/window')
-rw-r--r--views/window/client_view.cc7
-rw-r--r--views/window/client_view.h3
-rw-r--r--views/window/non_client_view.cc5
-rw-r--r--views/window/non_client_view.h2
4 files changed, 15 insertions, 2 deletions
diff --git a/views/window/client_view.cc b/views/window/client_view.cc
index 57046c1..1594386 100644
--- a/views/window/client_view.cc
+++ b/views/window/client_view.cc
@@ -1,4 +1,4 @@
-// Copyright (c) 2006-2008 The Chromium Authors. All rights reserved.
+// Copyright (c) 2010 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
@@ -61,4 +61,9 @@ void ClientView::DidChangeBounds(const gfx::Rect& previous,
// NonClientView::Layout.
}
+bool ClientView::GetAccessibleRole(AccessibilityTypes::Role* role) {
+ *role = AccessibilityTypes::ROLE_CLIENT;
+ return true;
+}
+
} // namespace views
diff --git a/views/window/client_view.h b/views/window/client_view.h
index b56fcfd..f6088e3 100644
--- a/views/window/client_view.h
+++ b/views/window/client_view.h
@@ -1,4 +1,4 @@
-// Copyright (c) 2006-2008 The Chromium Authors. All rights reserved.
+// Copyright (c) 2010 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
@@ -62,6 +62,7 @@ class ClientView : public View {
virtual void ViewHierarchyChanged(bool is_add, View* parent, View* child);
virtual void DidChangeBounds(const gfx::Rect& previous,
const gfx::Rect& current);
+ virtual bool GetAccessibleRole(AccessibilityTypes::Role* role);
// Accessors for private data members.
Window* window() const { return window_; }
diff --git a/views/window/non_client_view.cc b/views/window/non_client_view.cc
index e2d1a5c..8fe3346 100644
--- a/views/window/non_client_view.cc
+++ b/views/window/non_client_view.cc
@@ -253,4 +253,9 @@ bool NonClientFrameView::ShouldPaintAsActive() const {
return GetWindow()->IsActive() || paint_as_active_;
}
+bool NonClientFrameView::GetAccessibleRole(AccessibilityTypes::Role* role) {
+ *role = AccessibilityTypes::ROLE_WINDOW;
+ return true;
+}
+
} // namespace views
diff --git a/views/window/non_client_view.h b/views/window/non_client_view.h
index 0e736df..4377505 100644
--- a/views/window/non_client_view.h
+++ b/views/window/non_client_view.h
@@ -70,6 +70,8 @@ class NonClientFrameView : public View {
// Overridden from View:
virtual bool HitTest(const gfx::Point& l) const;
+ virtual bool GetAccessibleRole(AccessibilityTypes::Role* role);
+
protected:
virtual void DidChangeBounds(const gfx::Rect& previous,
const gfx::Rect& current);