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

Unified Diff: android_webview/java/src/org/chromium/android_webview/AwContents.java

Issue 15741009: Native Android accessibility. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Split RendererAccessibilityFocusOnly fix into separate changelist Created 7 years, 6 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: android_webview/java/src/org/chromium/android_webview/AwContents.java
diff --git a/android_webview/java/src/org/chromium/android_webview/AwContents.java b/android_webview/java/src/org/chromium/android_webview/AwContents.java
index 49fb2d0b937bd66895fe087e8f0c3702930b20eb..1a436176ce35ac0b4f16782c777942c860015613 100644
--- a/android_webview/java/src/org/chromium/android_webview/AwContents.java
+++ b/android_webview/java/src/org/chromium/android_webview/AwContents.java
@@ -26,6 +26,7 @@ import android.view.ViewGroup;
import android.view.ViewTreeObserver;
import android.view.accessibility.AccessibilityEvent;
import android.view.accessibility.AccessibilityNodeInfo;
+import android.view.accessibility.AccessibilityNodeProvider;
import android.view.inputmethod.EditorInfo;
import android.view.inputmethod.InputConnection;
import android.webkit.GeolocationPermissions;
@@ -1078,6 +1079,16 @@ public class AwContents {
}
/**
+ * @see android.view.View#dispatchHoverEvent()
+ */
+ public boolean dispatchHoverEvent(MotionEvent event) {
+ if (mContentViewCore.dispatchHoverEvent(event)) {
+ return true;
+ }
+ return super.dispatchHoverEvent(event);
benm (inactive) 2013/06/19 09:35:53 AwContents doesn't inherit from View, (doesn't hav
dmazzoni 2013/06/19 10:05:57 Ah, thanks for clarifying. Done.
+ }
+
+ /**
* @see android.view.View#onConfigurationChanged()
*/
public void onConfigurationChanged(Configuration newConfig) {
@@ -1231,6 +1242,17 @@ public class AwContents {
}
/**
+ * @see View#getAccessibilityNodeProvider()
+ */
+ public AccessibilityNodeProvider getAccessibilityNodeProvider() {
+ AccessibilityNodeProvider provider = mContentViewCore.getAccessibilityNodeProvider();
+ if (provider != null)
+ return provider;
+ else
+ return super.getAccessibilityNodeProvider();
benm (inactive) 2013/06/19 09:35:53 Same comment - should be enough to just return mCV
dmazzoni 2013/06/19 10:05:57 Done.
+ }
+
+ /**
* @see android.webkit.WebView#onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo)
*/
public void onInitializeAccessibilityNodeInfo(AccessibilityNodeInfo info) {

Powered by Google App Engine
This is Rietveld 408576698