Title: [153019] branches/safari-537-branch

Diff

Modified: branches/safari-537-branch/Source/WebCore/ChangeLog (153018 => 153019)


--- branches/safari-537-branch/Source/WebCore/ChangeLog	2013-07-23 01:03:24 UTC (rev 153018)
+++ branches/safari-537-branch/Source/WebCore/ChangeLog	2013-07-23 01:15:33 UTC (rev 153019)
@@ -1,5 +1,22 @@
 2013-07-22  Lucas Forschler  <[email protected]>
 
+        Merge r152939
+
+    2013-07-19  Chris Fleizach  <[email protected]>
+
+            AX: VoiceOver not detecting misspelled words don't work in all cases
+            https://bugs.webkit.org/show_bug.cgi?id=118924
+
+            Reviewed by Tim Horton.
+
+            VoiceOver is now looking for a new misspelled attribute.
+
+            * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
+            (AXAttributeStringSetSpelling):
+            (AXAttributedStringAppendText):
+
+2013-07-22  Lucas Forschler  <[email protected]>
+
         Merge r152911
 
     2013-07-19  David Hyatt  <[email protected]>

Modified: branches/safari-537-branch/Source/WebCore/accessibility/mac/WebAccessibilityObjectWrapperMac.mm (153018 => 153019)


--- branches/safari-537-branch/Source/WebCore/accessibility/mac/WebAccessibilityObjectWrapperMac.mm	2013-07-23 01:03:24 UTC (rev 153018)
+++ branches/safari-537-branch/Source/WebCore/accessibility/mac/WebAccessibilityObjectWrapperMac.mm	2013-07-23 01:15:33 UTC (rev 153019)
@@ -737,6 +737,9 @@
         for (unsigned i = 0; i < size; i++) {
             const TextCheckingResult& result = results[i];
             AXAttributeStringSetNumber(attrString, NSAccessibilityMisspelledTextAttribute, trueValue, NSMakeRange(result.location + range.location, result.length));
+#if PLATFORM(MAC) && __MAC_OS_X_VERSION_MIN_REQUIRED >= 1090
+            AXAttributeStringSetNumber(attrString, NSAccessibilityMarkedMisspelledTextAttribute, trueValue, NSMakeRange(result.location + range.location, result.length));
+#endif
         }
         return;
     }
@@ -754,6 +757,9 @@
         
         NSRange spellRange = NSMakeRange(range.location + currentPosition + misspellingLocation, misspellingLength);
         AXAttributeStringSetNumber(attrString, NSAccessibilityMisspelledTextAttribute, [NSNumber numberWithBool:YES], spellRange);
+#if PLATFORM(MAC) && __MAC_OS_X_VERSION_MIN_REQUIRED >= 1090
+        AXAttributeStringSetNumber(attrString, NSAccessibilityMarkedMisspelledTextAttribute, [NSNumber numberWithBool:YES], spellRange);
+#endif
         charLength -= (misspellingLocation + misspellingLength);
         currentPosition += (misspellingLocation + misspellingLength);
     }
@@ -831,6 +837,9 @@
     
     // remove inherited attachment from prior AXAttributedStringAppendReplaced
     [attrString removeAttribute:NSAccessibilityAttachmentTextAttribute range:attrStringRange];
+#if PLATFORM(MAC) && __MAC_OS_X_VERSION_MIN_REQUIRED >= 1090
+    [attrString removeAttribute:NSAccessibilityMarkedMisspelledTextAttribute range:attrStringRange];
+#endif
     [attrString removeAttribute:NSAccessibilityMisspelledTextAttribute range:attrStringRange];
     
     // set new attributes

Modified: branches/safari-537-branch/Tools/ChangeLog (153018 => 153019)


--- branches/safari-537-branch/Tools/ChangeLog	2013-07-23 01:03:24 UTC (rev 153018)
+++ branches/safari-537-branch/Tools/ChangeLog	2013-07-23 01:15:33 UTC (rev 153019)
@@ -1,5 +1,23 @@
 2013-07-22  Lucas Forschler  <[email protected]>
 
+        Merge r152939
+
+    2013-07-19  Chris Fleizach  <[email protected]>
+
+            AX: VoiceOver not detecting misspelled words don't work in all cases
+            https://bugs.webkit.org/show_bug.cgi?id=118924
+
+            Reviewed by Tim Horton.
+
+            Make the misspelled detection dependent on both types of attributes being present.
+
+            * DumpRenderTree/mac/AccessibilityUIElementMac.mm:
+            (AccessibilityUIElement::attributedStringRangeIsMisspelled):
+            * WebKitTestRunner/InjectedBundle/mac/AccessibilityUIElementMac.mm:
+            (WTR::AccessibilityUIElement::attributedStringRangeIsMisspelled):
+
+2013-07-22  Lucas Forschler  <[email protected]>
+
         Merge r152824
 
     2013-07-17  Tim Horton  <[email protected]>

Modified: branches/safari-537-branch/Tools/DumpRenderTree/mac/AccessibilityUIElementMac.mm (153018 => 153019)


--- branches/safari-537-branch/Tools/DumpRenderTree/mac/AccessibilityUIElementMac.mm	2013-07-23 01:03:24 UTC (rev 153018)
+++ branches/safari-537-branch/Tools/DumpRenderTree/mac/AccessibilityUIElementMac.mm	2013-07-23 01:15:33 UTC (rev 153019)
@@ -905,8 +905,12 @@
         return false;
 
     NSDictionary* attrs = [string attributesAtIndex:0 effectiveRange:nil];
-    if([[attrs objectForKey:NSAccessibilityMisspelledTextAttribute] boolValue])
-        return true;    
+    BOOL misspelled = [[attrs objectForKey:NSAccessibilityMisspelledTextAttribute] boolValue];
+#if PLATFORM(MAC) && __MAC_OS_X_VERSION_MIN_REQUIRED >= 1090
+    if (misspelled)
+        misspelled = [[attrs objectForKey:NSAccessibilityMarkedMisspelledTextAttribute] boolValue];
+#endif
+    return misspelled;
     END_AX_OBJC_EXCEPTIONS
     
     return false;

Modified: branches/safari-537-branch/Tools/WebKitTestRunner/InjectedBundle/mac/AccessibilityUIElementMac.mm (153018 => 153019)


--- branches/safari-537-branch/Tools/WebKitTestRunner/InjectedBundle/mac/AccessibilityUIElementMac.mm	2013-07-23 01:03:24 UTC (rev 153018)
+++ branches/safari-537-branch/Tools/WebKitTestRunner/InjectedBundle/mac/AccessibilityUIElementMac.mm	2013-07-23 01:15:33 UTC (rev 153019)
@@ -915,8 +915,12 @@
         return false;
 
     NSDictionary* attrs = [string attributesAtIndex:0 effectiveRange:nil];
-    if([[attrs objectForKey:NSAccessibilityMisspelledTextAttribute] boolValue])
-        return true;    
+    BOOL misspelled = [[attrs objectForKey:NSAccessibilityMisspelledTextAttribute] boolValue];
+#if PLATFORM(MAC) && __MAC_OS_X_VERSION_MIN_REQUIRED >= 1090
+    if (misspelled)
+        misspelled = [[attrs objectForKey:NSAccessibilityMarkedMisspelledTextAttribute] boolValue];
+#endif
+    return misspelled;
     END_AX_OBJC_EXCEPTIONS
     
     return false;
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to