| 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 be0c55d4a09d0890ca779f9b926b760cd42c5eb6..0f70f105a52174951b024bf5042d3434594f361f 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
|
| @@ -25,6 +25,13 @@ import org.chromium.content_public.browser.WebContentsObserver;
|
| // package whose visibility will be enforced via DEPS.
|
| /* package */ class WebContentsImpl implements WebContents {
|
|
|
| + // These values should be same as the AXTextStyle enumerations, see ax_enums.h
|
| + // TODO(sgurun) text style conversion seems to be buggy, fix it.
|
| + private static final int AX_TEXT_STYLE_BOLD = 1;
|
| + private static final int AX_TEXT_STYLE_ITALIC = 2;
|
| + private static final int AX_TEXT_STYLE_UNDERLINE = 4;
|
| + private static final int AX_TEXT_STYLE_LINE_THROUGH = 8;
|
| +
|
| private long mNativeWebContentsAndroid;
|
| private NavigationController mNavigationController;
|
|
|
| @@ -356,9 +363,14 @@ 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) {
|
| + int color, int bkgcolor, float size, int textStyle, String className) {
|
| +
|
| + boolean bold = (textStyle & AX_TEXT_STYLE_BOLD) > 0;
|
| + boolean italic = (textStyle & AX_TEXT_STYLE_ITALIC) > 0;
|
| + boolean underline = (textStyle & AX_TEXT_STYLE_UNDERLINE) > 0;
|
| + boolean strikeThrough = (textStyle & AX_TEXT_STYLE_LINE_THROUGH) > 0;
|
| return new AccessibilitySnapshotNode(x, y, scrollX, scrollY, width, height, text,
|
| - className);
|
| + color, bkgcolor, size, bold, italic, underline, strikeThrough, className);
|
| }
|
|
|
| @Override
|
|
|