summaryrefslogtreecommitdiffstats
path: root/webkit/glue/webaccessibilitymanager_impl.h
diff options
context:
space:
mode:
authorklink@chromium.org <klink@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-05-20 00:53:06 +0000
committerklink@chromium.org <klink@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-05-20 00:53:06 +0000
commite846d0dba2bf9506a929c9e16294997e37014039 (patch)
tree5ac70d2216fd450b3d4f164a26f752504c8cb220 /webkit/glue/webaccessibilitymanager_impl.h
parentfabd89f6aa700cb0e59b04e92ce54e729cbd0c66 (diff)
downloadchromium_src-e846d0dba2bf9506a929c9e16294997e37014039.zip
chromium_src-e846d0dba2bf9506a929c9e16294997e37014039.tar.gz
chromium_src-e846d0dba2bf9506a929c9e16294997e37014039.tar.bz2
Adds propagation and handling of render-side focus events, for the benefit of assistive technologies (accessibility). Also cleans up the handling of WM_GETOBJECT in RenderWidgetHostViewWin and WidgetWin, as well as in BrowserAccessibilityManager.
Review URL: http://codereview.chromium.org/115374 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@16449 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit/glue/webaccessibilitymanager_impl.h')
-rw-r--r--webkit/glue/webaccessibilitymanager_impl.h26
1 files changed, 14 insertions, 12 deletions
diff --git a/webkit/glue/webaccessibilitymanager_impl.h b/webkit/glue/webaccessibilitymanager_impl.h
index fe28e4e..1bc0607 100644
--- a/webkit/glue/webaccessibilitymanager_impl.h
+++ b/webkit/glue/webaccessibilitymanager_impl.h
@@ -10,10 +10,6 @@
class GlueAccessibilityObject;
-namespace webkit_glue {
-typedef base::hash_map<int, GlueAccessibilityObject*> IntToAccObjMap;
-typedef base::hash_map<GlueAccessibilityObject*, int> AccObjToIntMap;
-
////////////////////////////////////////////////////////////////////////////////
//
// WebAccessibilityManagerImpl
@@ -24,21 +20,23 @@ typedef base::hash_map<GlueAccessibilityObject*, int> AccObjToIntMap;
// the requested information from the active AccessibilityObject, through the
// GlueAccessibilityObject.
////////////////////////////////////////////////////////////////////////////////
+
+namespace webkit_glue {
+
class WebAccessibilityManagerImpl : public WebAccessibilityManager {
public:
// From WebAccessibilityManager.
bool GetAccObjInfo(WebView* view, const WebAccessibility::InParams& in_params,
WebAccessibility::OutParams* out_params);
-
- // From WebAccessibilityManager.
bool ClearAccObjMap(int acc_obj_id, bool clear_all);
+ int FocusAccObj(WebCore::AccessibilityObject* acc_obj);
protected:
// Needed so WebAccessibilityManager::Create can call our constructor.
friend class WebAccessibilityManager;
WebAccessibilityManagerImpl();
- ~WebAccessibilityManagerImpl() {}
+ ~WebAccessibilityManagerImpl();
private:
// From WebAccessibilityManager.
@@ -49,17 +47,21 @@ class WebAccessibilityManagerImpl : public WebAccessibilityManager {
struct GlueAccessibilityObjectRoot;
GlueAccessibilityObjectRoot* root_;
+ typedef base::hash_map<int, GlueAccessibilityObject*> IntToGlueAccObjMap;
+ typedef base::hash_map<WebCore::AccessibilityObject*, int> AccObjToIntMap;
+
// Hashmap for cashing of elements in use by the AT, mapping id (int) to a
// GlueAccessibilityObject pointer.
- IntToAccObjMap int_to_acc_obj_map_;
+ IntToGlueAccObjMap int_to_glue_acc_obj_map_;
// Hashmap for cashing of elements in use by the AT, mapping a
- // GlueAccessibilityObject pointer to its id (int). Needed for reverse lookup,
+ // AccessibilityObject pointer to its id (int). Needed for reverse lookup,
// to ensure unnecessary duplicate entries are not created in the
- // IntToAccObjMap (above).
+ // IntToGlueAccObjMap (above) and for focus changes in WebKit.
AccObjToIntMap acc_obj_to_int_map_;
- // Unique identifier for retrieving a GlueAccessibilityObject from the page's
- // hashmaps.
+ // Unique identifier for retrieving an accessibility object from the page's
+ // hashmaps. Id is always 0 for the root of the accessibility object
+ // hierarchy (on a per-renderer process basis).
int acc_obj_id_;
DISALLOW_COPY_AND_ASSIGN(WebAccessibilityManagerImpl);