RESOLVED FIXED 170904
[WK2] Respect a new internal setting for defaulting to character selection granularity
https://bugs.webkit.org/show_bug.cgi?id=170904
Summary [WK2] Respect a new internal setting for defaulting to character selection gr...
Wenson Hsieh
Reported 2017-04-17 09:26:39 PDT
Attachments
Patch (2.80 KB, patch)
2017-04-17 09:47 PDT, Wenson Hsieh
mitz: review+
buildbot: commit-queue-
Archive of layout-test-results from ews125 for ios-simulator-wk2 (889.34 KB, application/zip)
2017-04-17 11:27 PDT, Build Bot
no flags
Patch for landing (2.84 KB, patch)
2017-04-17 11:42 PDT, Wenson Hsieh
no flags
Wenson Hsieh
Comment 1 2017-04-17 09:47:57 PDT
Build Bot
Comment 2 2017-04-17 11:27:09 PDT
Comment on attachment 307272 [details] Patch Attachment 307272 [details] did not pass ios-sim-ews (ios-simulator-wk2): Output: http://webkit-queues.webkit.org/results/3552101 New failing tests: webrtc/multi-video.html
Build Bot
Comment 3 2017-04-17 11:27:10 PDT
Created attachment 307284 [details] Archive of layout-test-results from ews125 for ios-simulator-wk2 The attached test failures were seen while running run-webkit-tests on the ios-sim-ews. Bot: ews125 Port: ios-simulator-wk2 Platform: Mac OS X 10.11.6
mitz
Comment 4 2017-04-17 11:30:37 PDT
Comment on attachment 307272 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=307272&action=review > Source/WebKit2/UIProcess/API/Cocoa/WKWebViewConfiguration.mm:201 > + BOOL defaultToSelectionGranularityCharacter = [[NSUserDefaults standardUserDefaults] boolForKey:@"WebKitDebugDefaultSelectionGranularityCharacter"] && WebKit::linkedOnOrAfter(WebKit::SDKVersion::FirstToUseSelectionGranularityCharacterByDefault); > + _selectionGranularity = defaultToSelectionGranularityCharacter ? WKSelectionGranularityCharacter : WKSelectionGranularityDynamic; Perhaps for wider testing it would be good to make the user default affect all apps regardless of when they were built? Seems like this needs to be guarded with #if PLATFORM(IOS).
Wenson Hsieh
Comment 5 2017-04-17 11:39:52 PDT
(In reply to mitz from comment #4) > Comment on attachment 307272 [details] > Patch > > View in context: > https://bugs.webkit.org/attachment.cgi?id=307272&action=review > > > Source/WebKit2/UIProcess/API/Cocoa/WKWebViewConfiguration.mm:201 > > + BOOL defaultToSelectionGranularityCharacter = [[NSUserDefaults standardUserDefaults] boolForKey:@"WebKitDebugDefaultSelectionGranularityCharacter"] && WebKit::linkedOnOrAfter(WebKit::SDKVersion::FirstToUseSelectionGranularityCharacterByDefault); > > + _selectionGranularity = defaultToSelectionGranularityCharacter ? WKSelectionGranularityCharacter : WKSelectionGranularityDynamic; > > Perhaps for wider testing it would be good to make the user default affect > all apps regardless of when they were built? Sounds good. I think I will make this adjustment as a followup after we live with the default on for a bit and we're sure that first-party compatibility is not an issue. Perhaps we could then repurpose (and rename) this flag to force using WKSelectionGranularityCharacter, even when the application is linked on an iOS 10 SDK or earlier. > > Seems like this needs to be guarded with #if PLATFORM(IOS). Whoops, that's right -- fixed.
Wenson Hsieh
Comment 6 2017-04-17 11:42:27 PDT
Created attachment 307286 [details] Patch for landing
WebKit Commit Bot
Comment 7 2017-04-17 12:26:33 PDT
Comment on attachment 307286 [details] Patch for landing Clearing flags on attachment: 307286 Committed r215421: <http://trac.webkit.org/changeset/215421>
Note You need to log in before you can comment on or make changes to this bug.