Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(186)

Unified Diff: content/browser/accessibility/browser_accessibility_manager.cc

Issue 214243005: Fire accessibility focus/blur events on root web document. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: content/browser/accessibility/browser_accessibility_manager.cc
diff --git a/content/browser/accessibility/browser_accessibility_manager.cc b/content/browser/accessibility/browser_accessibility_manager.cc
index 8481b0776c42c9ee6df90e205de097b0e3a6db35..26b005c04e81f281ce5915470505e0861014b656 100644
--- a/content/browser/accessibility/browser_accessibility_manager.cc
+++ b/content/browser/accessibility/browser_accessibility_manager.cc
@@ -86,18 +86,14 @@ BrowserAccessibility* BrowserAccessibilityManager::GetFromRendererID(
return NULL;
}
-void BrowserAccessibilityManager::GotFocus(bool touch_event_context) {
David Tseng 2014/04/02 22:05:05 Was this unused?
dmazzoni 2014/04/02 22:09:55 This used to be called from render_widget_host_vie
- if (!touch_event_context)
- osk_state_ = OSK_DISALLOWED_BECAUSE_TAB_JUST_APPEARED;
-
- if (!focus_)
- return;
-
- NotifyAccessibilityEvent(ui::AX_EVENT_FOCUS, focus_);
+void BrowserAccessibilityManager::OnWindowFocused() {
+ if (focus_)
+ NotifyAccessibilityEvent(ui::AX_EVENT_FOCUS, focus_);
}
-void BrowserAccessibilityManager::WasHidden() {
- osk_state_ = OSK_DISALLOWED_BECAUSE_TAB_HIDDEN;
+void BrowserAccessibilityManager::OnWindowBlurred() {
+ if (focus_)
David Tseng 2014/04/02 22:05:05 |focus_| could be anything in the accessibility tr
dmazzoni 2014/04/02 22:09:55 The way I implemented it, all platforms will fire
+ NotifyAccessibilityEvent(ui::AX_EVENT_BLUR, focus_);
}
void BrowserAccessibilityManager::GotMouseDown() {

Powered by Google App Engine
This is Rietveld 408576698