More NVDA browse mode fixes
The previous change (https://codereview.chromium.org/332893004/) wasn't quite right. To avoid errors, we need to only fire focus and load events when the web view itself has focus, not say when the location bar has focus. And because there are transient periods when we can't fire events, we need to keep track of whether we need to fire a focus event with a flag and fire it later.
BUG=368549
NOTRY=true
Review URL: https://codereview.chromium.org/344573003
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@278303 0039d316-1c4b-4281-b951-d872f2087c98
diff --git a/content/browser/accessibility/browser_accessibility_manager_win.h b/content/browser/accessibility/browser_accessibility_manager_win.h
index 90914db..26c82b7 100644
--- a/content/browser/accessibility/browser_accessibility_manager_win.h
+++ b/content/browser/accessibility/browser_accessibility_manager_win.h
@@ -51,7 +51,6 @@
// BrowserAccessibilityManager methods
virtual void OnWindowFocused() OVERRIDE;
- virtual void OnWindowBlurred() OVERRIDE;
virtual void NotifyAccessibilityEvent(
ui::AXEvent event_type, BrowserAccessibility* node) OVERRIDE;
@@ -93,6 +92,10 @@
// Owned by its parent; OnAccessibleHwndDeleted gets called upon deletion.
LegacyRenderWidgetHostHWND* accessible_hwnd_;
+ // Set to true if we need to fire a focus event on the root as soon as
+ // possible.
+ bool focus_event_on_root_needed_;
+
DISALLOW_COPY_AND_ASSIGN(BrowserAccessibilityManagerWin);
};