| Index: content/public/android/java/src/org/chromium/content/browser/webcontents/WebContentsImpl.java
|
| diff --git a/content/public/android/java/src/org/chromium/content/browser/webcontents/WebContentsImpl.java b/content/public/android/java/src/org/chromium/content/browser/webcontents/WebContentsImpl.java
|
| index a4a404a52d7c7aed0965f9c5c3ad9b853f9148b1..e655e957d5523aacd483f47825edd04e3df24471 100644
|
| --- a/content/public/android/java/src/org/chromium/content/browser/webcontents/WebContentsImpl.java
|
| +++ b/content/public/android/java/src/org/chromium/content/browser/webcontents/WebContentsImpl.java
|
| @@ -14,6 +14,7 @@ import org.chromium.content_public.browser.JavaScriptCallback;
|
| import org.chromium.content_public.browser.NavigationController;
|
| import org.chromium.content_public.browser.WebContents;
|
| import org.chromium.content_public.browser.WebContentsObserver;
|
| +import org.chromium.ui.accessibility.AXTextStyle;
|
|
|
| /**
|
| * The WebContentsImpl Java wrapper to allow communicating with the native WebContentsImpl
|
| @@ -234,9 +235,19 @@ import org.chromium.content_public.browser.WebContentsObserver;
|
| @CalledByNative
|
| private static AccessibilitySnapshotNode createAccessibilitySnapshotNode(int x,
|
| int y, int scrollX, int scrollY, int width, int height, String text,
|
| - String className) {
|
| - return new AccessibilitySnapshotNode(x, y, scrollX, scrollY, width, height, text,
|
| - className);
|
| + int color, int bgcolor, float size, int textStyle, String className) {
|
| +
|
| + AccessibilitySnapshotNode node = new AccessibilitySnapshotNode(x, y, scrollX,
|
| + scrollY, width, height, text, className);
|
| + // if size is smaller than 0, then style information does not exist.
|
| + if (size >= 0.0) {
|
| + boolean bold = (textStyle & AXTextStyle.text_style_bold) > 0;
|
| + boolean italic = (textStyle & AXTextStyle.text_style_italic) > 0;
|
| + boolean underline = (textStyle & AXTextStyle.text_style_underline) > 0;
|
| + boolean lineThrough = (textStyle & AXTextStyle.text_style_line_through) > 0;
|
| + node.setStyle(color, bgcolor, size, bold, italic, underline, lineThrough);
|
| + }
|
| + return node;
|
| }
|
|
|
| @Override
|
|
|