| Index: content/browser/accessibility/browser_accessibility_manager_win.cc
|
| diff --git a/content/browser/accessibility/browser_accessibility_manager_win.cc b/content/browser/accessibility/browser_accessibility_manager_win.cc
|
| index bf70c576ad676d7f3e83c67ee2bb6466a6a08740..5ee08f0fae5d589717997fbdf4d784b000b52be5 100644
|
| --- a/content/browser/accessibility/browser_accessibility_manager_win.cc
|
| +++ b/content/browser/accessibility/browser_accessibility_manager_win.cc
|
| @@ -150,13 +150,14 @@ void BrowserAccessibilityManagerWin::OnWindowFocused() {
|
|
|
| // Try to fire a focus event on the root first and then the focused node.
|
| // This will clear focus_event_on_root_needed_ if successful.
|
| - if (focus_ != tree_->root())
|
| + if (focus_ != tree_->root() && GetRoot())
|
| NotifyAccessibilityEvent(ui::AX_EVENT_FOCUS, GetRoot());
|
| BrowserAccessibilityManager::OnWindowFocused();
|
| }
|
|
|
| void BrowserAccessibilityManagerWin::UserIsReloading() {
|
| - MaybeCallNotifyWinEvent(IA2_EVENT_DOCUMENT_RELOAD, GetRoot());
|
| + if (GetRoot())
|
| + MaybeCallNotifyWinEvent(IA2_EVENT_DOCUMENT_RELOAD, GetRoot());
|
| }
|
|
|
| void BrowserAccessibilityManagerWin::NotifyAccessibilityEvent(
|
| @@ -253,6 +254,9 @@ void BrowserAccessibilityManagerWin::NotifyAccessibilityEvent(
|
| break;
|
| }
|
|
|
| + if (!node)
|
| + return;
|
| +
|
| if (event_id != EVENT_MIN) {
|
| // Pass the node's unique id in the |child_id| argument to NotifyWinEvent;
|
| // the AT client will then call get_accChild on the HWND's accessibility
|
|
|