WebKit Bugzilla
Attachment 368253 Details for
Bug 197222
: Clean up dependencies with accessibility and UIKit
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch
bug-197222-20190425113155.patch (text/plain), 11.02 KB, created by
Megan Gardner
on 2019-04-25 11:31:56 PDT
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Megan Gardner
Created:
2019-04-25 11:31:56 PDT
Size:
11.02 KB
patch
obsolete
>Subversion Revision: 244573 >diff --git a/Source/WTF/ChangeLog b/Source/WTF/ChangeLog >index 813081ee1b54f6649de080fa3274a822f6baa0ea..c829f744d8b37497077f53fc183a64930034c77f 100644 >--- a/Source/WTF/ChangeLog >+++ b/Source/WTF/ChangeLog >@@ -1,3 +1,14 @@ >+2019-04-23 Megan Gardner <megan_gardner@apple.com> >+ >+ Clean up dependencies with accessibility and UIKit >+ https://bugs.webkit.org/show_bug.cgi?id=197222 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ Define the access to items from UIKit rather than redefining them. >+ >+ * wtf/Platform.h: >+ > 2019-04-23 Alex Christensen <achristensen@webkit.org> > > Remove DeprecatedOptional >diff --git a/Source/WebCore/ChangeLog b/Source/WebCore/ChangeLog >index e89fb824fa36f95c84a23fb1488c502fc2138dca..301b069a75bc207a0dfff550a06b451ae83e7c40 100644 >--- a/Source/WebCore/ChangeLog >+++ b/Source/WebCore/ChangeLog >@@ -1,3 +1,24 @@ >+2019-04-23 Megan Gardner <megan_gardner@apple.com> >+ >+ Clean up dependencies with accessibility and UIKit >+ https://bugs.webkit.org/show_bug.cgi?id=197222 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ No tests, if the tests still work, this was moved around correctly. >+ >+ Access items from UIKit rather than redefining them. >+ Also, this method is defined as not accessible on iOS >+ via UIKit, so we need to make ours seperate since we are >+ using it for tests. >+ >+ * accessibility/ios/WebAccessibilityObjectWrapperIOS.mm: >+ (-[WebAccessibilityObjectWrapper accessibilityHeaderElementsTest]): >+ (-[WebAccessibilityObjectWrapper accessibilityTextualContext]): >+ (AXAttributeStringSetStyle): >+ (-[WebAccessibilityObjectWrapper accessibilityHeaderElements]): Deleted. >+ * platform/mac/WebNSAttributedStringExtras.mm: >+ > 2019-04-23 Andy Estes <aestes@apple.com> > > [iOS] QuickLook documents loaded from file: URLs should be allowed to perform same-document navigations >diff --git a/Source/WebCore/PAL/ChangeLog b/Source/WebCore/PAL/ChangeLog >index 4a28ff62055e8058a17a87f89a0438ef59d3cdb4..2c11b2822818c5a81d587a6276dd2235b13864d8 100644 >--- a/Source/WebCore/PAL/ChangeLog >+++ b/Source/WebCore/PAL/ChangeLog >@@ -1,3 +1,13 @@ >+2019-04-23 Megan Gardner <megan_gardner@apple.com> >+ >+ Clean up dependencies with accessibility and UIKit >+ https://bugs.webkit.org/show_bug.cgi?id=197222 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ * pal/ios/UIKitSoftLink.h: >+ * pal/ios/UIKitSoftLink.mm: >+ > 2019-04-23 Commit Queue <commit-queue@webkit.org> > > Unreviewed, rolling out r244556. >diff --git a/Source/WebKit/ChangeLog b/Source/WebKit/ChangeLog >index 054d7709e93540bb8a637e5ec5810c0d3ab7d90b..b4949406b3ff9f9d5b5b149710b0b0b12a5aa016 100644 >--- a/Source/WebKit/ChangeLog >+++ b/Source/WebKit/ChangeLog >@@ -1,3 +1,14 @@ >+2019-04-23 Megan Gardner <megan_gardner@apple.com> >+ >+ Clean up dependencies with accessibility and UIKit >+ https://bugs.webkit.org/show_bug.cgi?id=197222 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ Define the access to items from UIKit rather than redefining them. >+ >+ * Platform/spi/ios/UIKitSPI.h: >+ > 2019-04-23 John Wilander <wilander@apple.com> > > Remove Ad Click Attribution data when removing website data >diff --git a/Source/WTF/wtf/Platform.h b/Source/WTF/wtf/Platform.h >index 06147ac81e987061b17f73c7e6196facfea4fdd7..3337a0179a2583bd42c657217675a6699755539f 100644 >--- a/Source/WTF/wtf/Platform.h >+++ b/Source/WTF/wtf/Platform.h >@@ -1527,3 +1527,7 @@ > #if (PLATFORM(IOS) && __IPHONE_OS_VERSION_MIN_REQUIRED >= 130000) > #define HAVE_ROUTE_SHARING_POLICY_LONG_FORM_VIDEO 1 > #endif >+ >+#if (PLATFORM(IOS) && __IPHONE_OS_VERSION_MIN_REQUIRED < 130000) >+#define ENABLE_INTERNAL_ACCESSIBILITY_CONSTANTS 1 >+#endif >diff --git a/Source/WebCore/PAL/pal/ios/UIKitSoftLink.h b/Source/WebCore/PAL/pal/ios/UIKitSoftLink.h >index 61871af7e0a825d2cb7c74d8bed4834d22289485..11606a5d976f0f742b4a1b1fc35a82fb2342ddd6 100644 >--- a/Source/WebCore/PAL/pal/ios/UIKitSoftLink.h >+++ b/Source/WebCore/PAL/pal/ios/UIKitSoftLink.h >@@ -42,6 +42,8 @@ SOFT_LINK_CONSTANT_FOR_HEADER(PAL, UIKit, UIApplicationDidEnterBackgroundNotific > SOFT_LINK_CONSTANT_FOR_HEADER(PAL, UIKit, UIContentSizeCategoryDidChangeNotification, NSNotificationName) > SOFT_LINK_CONSTANT_FOR_HEADER(PAL, UIKit, UIFontTextStyleCallout, UIFontTextStyle) > SOFT_LINK_CONSTANT_FOR_HEADER(PAL, UIKit, UITextEffectsBeneathStatusBarWindowLevel, UIWindowLevel) >+SOFT_LINK_CONSTANT_FOR_HEADER(PAL, UIKit, UIAccessibilityTextualContextSourceCode, UIAccessibilityTextualContext) >+SOFT_LINK_CONSTANT_FOR_HEADER(PAL, UIKit, UIAccessibilityTextAttributeContext, NSAttributedStringKey) > SOFT_LINK_CLASS_FOR_HEADER(PAL, NSParagraphStyle) > SOFT_LINK_CLASS_FOR_HEADER(PAL, NSShadow) > SOFT_LINK_CLASS_FOR_HEADER(PAL, NSTextList) >diff --git a/Source/WebCore/PAL/pal/ios/UIKitSoftLink.mm b/Source/WebCore/PAL/pal/ios/UIKitSoftLink.mm >index 3493b9b7f55805b80d61fe3be723180726984318..d5c2289bb60c32b8d6d8b20222e04701c08e025c 100644 >--- a/Source/WebCore/PAL/pal/ios/UIKitSoftLink.mm >+++ b/Source/WebCore/PAL/pal/ios/UIKitSoftLink.mm >@@ -42,6 +42,8 @@ SOFT_LINK_CONSTANT_FOR_SOURCE(PAL, UIKit, UIApplicationDidEnterBackgroundNotific > SOFT_LINK_CONSTANT_FOR_SOURCE(PAL, UIKit, UIContentSizeCategoryDidChangeNotification, NSNotificationName) > SOFT_LINK_CONSTANT_FOR_SOURCE(PAL, UIKit, UIFontTextStyleCallout, UIFontTextStyle) > SOFT_LINK_CONSTANT_FOR_SOURCE(PAL, UIKit, UITextEffectsBeneathStatusBarWindowLevel, UIWindowLevel) >+SOFT_LINK_CONSTANT_FOR_SOURCE(PAL, UIKit, UIAccessibilityTextualContextSourceCode, UIAccessibilityTextualContext) >+SOFT_LINK_CONSTANT_FOR_SOURCE(PAL, UIKit, UIAccessibilityTextAttributeContext, NSAttributedStringKey) > SOFT_LINK_CLASS_FOR_SOURCE(PAL, UIKit, NSParagraphStyle) > SOFT_LINK_CLASS_FOR_SOURCE(PAL, UIKit, NSShadow) > SOFT_LINK_CLASS_FOR_SOURCE(PAL, UIKit, NSTextList) >diff --git a/Source/WebCore/PAL/pal/spi/ios/UIKitSPI.h b/Source/WebCore/PAL/pal/spi/ios/UIKitSPI.h >index 12f351a2155c96a3a62f18ffc645fbcb21bf94bb..18b95c76574788b487fca3cdcdd647b6ea391b8d 100644 >--- a/Source/WebCore/PAL/pal/spi/ios/UIKitSPI.h >+++ b/Source/WebCore/PAL/pal/spi/ios/UIKitSPI.h >@@ -147,8 +147,31 @@ NS_ASSUME_NONNULL_END > @end > #endif > >+#if ENABLE_INTERNAL_ACCESSIBILITY_CONSTANTS >+enum { >+ NSAttachmentCharacter = 0xfffc /* To denote attachments. */ >+}; >+ >+typedef NS_ENUM(NSInteger, UIAccessibilityScrollDirection) { >+ UIAccessibilityScrollDirectionRight = 1, >+ UIAccessibilityScrollDirectionLeft, >+ UIAccessibilityScrollDirectionUp, >+ UIAccessibilityScrollDirectionDown, >+ UIAccessibilityScrollDirectionNext, >+ UIAccessibilityScrollDirectionPrevious >+}; >+ >+static NSString * const UIAccessibilityTextAttributeContext = @"UIAccessibilityTextAttributeContext"; >+static NSString * const UIAccessibilityTextualContextSourceCode = @"UIAccessibilityTextualContextSourceCode"; >+ >+typedef NSString * UIAccessibilityTextualContext; >+ >+#endif >+ > #endif // USE(APPLE_INTERNAL_SDK) > >+#import <UIKit/UIAccessibilityConstants.h> >+ > #if ENABLE(FULL_KEYBOARD_ACCESS) > @interface UIColor (IPI) > + (UIColor *)keyboardFocusIndicatorColor; >diff --git a/Source/WebCore/accessibility/ios/WebAccessibilityObjectWrapperIOS.mm b/Source/WebCore/accessibility/ios/WebAccessibilityObjectWrapperIOS.mm >index 8ecfc8cab50c11b0e35fb71e8ca0f3a528eae73e..33e07f0cecc7f8d5a49f7c6e3147b98e5e2f9c3a 100644 >--- a/Source/WebCore/accessibility/ios/WebAccessibilityObjectWrapperIOS.mm >+++ b/Source/WebCore/accessibility/ios/WebAccessibilityObjectWrapperIOS.mm >@@ -61,10 +61,7 @@ > #import "VisibleUnits.h" > > #import <CoreText/CoreText.h> >- >-enum { >- NSAttachmentCharacter = 0xfffc /* To denote attachments. */ >-}; >+#import <pal/ios/UIKitSoftLink.h> > > @interface NSObject (AccessibilityPrivate) > - (void)_accessibilityUnregister; >@@ -96,15 +93,6 @@ @end > using namespace WebCore; > using namespace HTMLNames; > >-typedef NS_ENUM(NSInteger, UIAccessibilityScrollDirection) { >- UIAccessibilityScrollDirectionRight = 1, >- UIAccessibilityScrollDirectionLeft, >- UIAccessibilityScrollDirectionUp, >- UIAccessibilityScrollDirectionDown, >- UIAccessibilityScrollDirectionNext, >- UIAccessibilityScrollDirectionPrevious >-}; >- > // These are tokens accessibility uses to denote attributes. > static NSString * const UIAccessibilityTokenBlockquoteLevel = @"UIAccessibilityTokenBlockquoteLevel"; > static NSString * const UIAccessibilityTokenHeadingLevel = @"UIAccessibilityTokenHeadingLevel"; >@@ -117,9 +105,6 @@ static NSString * const UIAccessibilityTokenUnderline = @"UIAccessibilityTokenUn > static NSString * const UIAccessibilityTokenLanguage = @"UIAccessibilityTokenLanguage"; > static NSString * const UIAccessibilityTokenAttachment = @"UIAccessibilityTokenAttachment"; > >-static NSString * const UIAccessibilityTextAttributeContext = @"UIAccessibilityTextAttributeContext"; >-static NSString * const UIAccessibilityTextualContextSourceCode = @"UIAccessibilityTextualContextSourceCode"; >- > static AccessibilityObjectWrapper* AccessibilityUnignoredAncestor(AccessibilityObjectWrapper *wrapper) > { > while (wrapper && ![wrapper isAccessibilityElement]) { >@@ -1195,6 +1180,8 @@ - (id)accessibilityTitleElement > } > > // Meant to return row or column headers (or other things as the future permits). >+#pragma clang diagnostic push >+#pragma clang diagnostic ignored "-Wdeprecated-implementations" > - (NSArray *)accessibilityHeaderElements > { > if (![self _prepareAccessibilityCall]) >@@ -1246,6 +1233,7 @@ - (NSArray *)accessibilityHeaderElements > > return headers; > } >+#pragma clang diagnostic pop > > - (id)accessibilityElementForRow:(NSInteger)row andColumn:(NSInteger)column > { >@@ -1822,7 +1810,7 @@ - (NSString *)accessibilityTextualContext > return nil; > > if (m_object->node() && m_object->node()->hasTagName(codeTag)) >- return UIAccessibilityTextualContextSourceCode; >+ return PAL::get_UIKit_UIAccessibilityTextualContextSourceCode(); > > return nil; > } >@@ -2202,7 +2190,7 @@ static void AXAttributeStringSetStyle(NSMutableAttributedString* attrString, Ren > }; > > if (const AccessibilityObject* parent = AccessibilityObject::matchedParent(*axObject, true, WTFMove(matchFunc))) >- [attrString addAttribute:UIAccessibilityTextAttributeContext value:UIAccessibilityTextualContextSourceCode range:range]; >+ [attrString addAttribute:PAL::get_UIKit_UIAccessibilityTextAttributeContext() value:PAL::get_UIKit_UIAccessibilityTextualContextSourceCode() range:range]; > } > > static void AXAttributedStringAppendText(NSMutableAttributedString* attrString, Node* node, NSString *text) >diff --git a/Source/WebCore/platform/mac/WebNSAttributedStringExtras.mm b/Source/WebCore/platform/mac/WebNSAttributedStringExtras.mm >index f25fc37bf93bec8f4d67af94856d4c316de7d240..24b837ffa7d213158ab1a676a9a6e65ae70f82b9 100644 >--- a/Source/WebCore/platform/mac/WebNSAttributedStringExtras.mm >+++ b/Source/WebCore/platform/mac/WebNSAttributedStringExtras.mm >@@ -25,12 +25,7 @@ > > #import "config.h" > #import "WebNSAttributedStringExtras.h" >- >-#if PLATFORM(IOS_FAMILY) >-enum { >- NSAttachmentCharacter = 0xfffc /* To denote attachments. */ >-}; >-#endif >+#import <pal/ios/UIKitSoftLink.h> > > namespace WebCore { >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 197222
:
368093
|
368096
|
368147
|
368168
|
368173
|
368179
|
368184
|
368253
|
368255