Uncaught Exception: SyntaxError: Invalid regular expression: \ at end of pattern
[WebKit-https.git] / Source / WebKit / mac / ChangeLog
1 2016-03-16  Beth Dakin  <bdakin@apple.com>
2
3         Provide NSSpellChecker spellChecking methods with the current insertion point
4         https://bugs.webkit.org/show_bug.cgi?id=155532
5         -and corresponding-
6         rdar://problem/24066952
7
8         Reviewed by Simon Fraser.
9
10         Extract the insertion point from the VisibleSelection that WebCore has 
11         passed. 
12         * WebCoreSupport/WebEditorClient.h:
13         (WebEditorClient::getGuessesForWord):
14         * WebCoreSupport/WebEditorClient.mm:
15         (WebEditorClient::checkTextOfParagraph):
16         (insertionPointFromCurrentSelection):
17         (WebEditorClient::getGuessesForWord):
18         (WebEditorClient::requestCheckingOfString):
19
20 2016-03-16  Chris Dumez  <cdumez@apple.com>
21
22         Unreviewed, rolling out r198235, r198240, r198241, and
23         r198252.
24
25         Causing crashes on ARM
26
27         Reverted changesets:
28
29         "Remove compile time define for SEPARATED_HEAP"
30         https://bugs.webkit.org/show_bug.cgi?id=155508
31         http://trac.webkit.org/changeset/198235
32
33         "Gardening: build fix after r198235."
34         http://trac.webkit.org/changeset/198240
35
36         "Build fix."
37         http://trac.webkit.org/changeset/198241
38
39         "Rename performJITMemcpy to something more inline with our
40         normal webkit function names"
41         https://bugs.webkit.org/show_bug.cgi?id=155525
42         http://trac.webkit.org/changeset/198252
43
44 2016-03-16  Jiewen Tan  <jiewen_tan@apple.com>
45
46         URL Parsing should signal failure for illegal IDN
47         https://bugs.webkit.org/show_bug.cgi?id=154945
48         <rdar://problem/8014795>
49
50         Reviewed by Brent Fulgham.
51
52         In this patch, we add new SPIs _webkit_URLWithUserTypedString, _webkit_decodeHostName and
53         _webkit_encodeHostName which will return nil while dealing with illegal IDN.
54
55         Old SPIs _web_URLWithUserTypedString, _web_decodeHostName and _web_encodeHostName are marked
56         deprecated as they ignore URL parsing failure.
57
58         * History/WebHistoryItem.mm:
59         (-[WebHistoryItem initFromDictionaryRepresentation:]):
60         * Misc/WebKitErrors.m:
61         (+[NSError _webKitErrorWithCode:failingURL:]):
62         * Misc/WebNSFileManagerExtras.mm:
63         (-[NSFileManager _webkit_setMetadataURL:referrer:atPath:]):
64         * Misc/WebNSPasteboardExtras.mm:
65         (-[NSPasteboard _web_bestURL]):
66         * Misc/WebNSURLExtras.h:
67         * Misc/WebNSURLExtras.mm:
68         (+[NSURL _web_URLWithUserTypedString:]):
69         (+[NSURL _webkit_URLWithUserTypedString:relativeToURL:]):
70         (+[NSURL _webkit_URLWithUserTypedString:]):
71         (-[NSString _web_decodeHostName]):
72         (-[NSString _web_encodeHostName]):
73         (-[NSString _webkit_decodeHostName]):
74         (-[NSString _webkit_encodeHostName]):
75         * Panels/WebAuthenticationPanel.m:
76         (-[WebAuthenticationPanel setUpForChallenge:]):
77         * WebCoreSupport/WebEditorClient.mm:
78         (WebEditorClient::canonicalizeURLString):
79
80 2016-03-15  Jer Noble  <jer.noble@apple.com>
81
82         [ios-sim debug] API test WebKit1.AudioSessionCategoryIOS timing out
83         https://bugs.webkit.org/show_bug.cgi?id=155275
84
85         Reviewed by Alexey Proskuryakov.
86
87         The videoPlaybackRequiresUserGesture and audioPlaybackRequiresUserGesture should both defalut to
88         NO, so that legacy clients of -[UIWebView setMediaPlaybackRequiresUserAction:] continue to work
89         as expected.
90
91         * WebView/WebPreferences.mm:
92         (+[WebPreferences initialize]):
93
94 2016-03-15  Oliver Hunt  <oliver@apple.com>
95
96         Remove compile time define for SEPARATED_HEAP
97         https://bugs.webkit.org/show_bug.cgi?id=155508
98
99         Reviewed by Mark Lam.
100
101         Remove the feature define.
102
103         * Configurations/FeatureDefines.xcconfig:
104
105 2016-03-15  Chris Dumez  <cdumez@apple.com>
106
107         Unreviewed, rolling out r198203.
108
109         Favorites view is no longer loading on iOS
110
111         Reverted changeset:
112
113         "URL Parsing should signal failure for illegal IDN"
114         https://bugs.webkit.org/show_bug.cgi?id=154945
115         http://trac.webkit.org/changeset/198203
116
117 2016-03-15  Jiewen Tan  <jiewen_tan@apple.com>
118
119         URL Parsing should signal failure for illegal IDN
120         https://bugs.webkit.org/show_bug.cgi?id=154945
121         <rdar://problem/8014795>
122
123         Reviewed by Brent Fulgham.
124
125         In this patch, we add new SPIs _webkit_URLWithUserTypedString, _webkit_decodeHostName and
126         _webkit_encodeHostName which will return nil while dealing with illegal IDN.
127
128         Old SPIs _web_URLWithUserTypedString, _web_decodeHostName and _web_encodeHostName are marked
129         deprecated as they ignore URL parsing failure.
130
131         * History/WebHistoryItem.mm:
132         (-[WebHistoryItem initFromDictionaryRepresentation:]):
133         * Misc/WebKitErrors.m:
134         (+[NSError _webKitErrorWithCode:failingURL:]):
135         * Misc/WebNSFileManagerExtras.mm:
136         (-[NSFileManager _webkit_setMetadataURL:referrer:atPath:]):
137         * Misc/WebNSPasteboardExtras.mm:
138         (-[NSPasteboard _web_bestURL]):
139         * Misc/WebNSURLExtras.h:
140         * Misc/WebNSURLExtras.mm:
141         (+[NSURL _web_URLWithUserTypedString:]):
142         (+[NSURL _webkit_URLWithUserTypedString:relativeToURL:]):
143         (+[NSURL _webkit_URLWithUserTypedString:]):
144         (-[NSString _web_decodeHostName]):
145         (-[NSString _web_encodeHostName]):
146         (-[NSString _webkit_decodeHostName]):
147         (-[NSString _webkit_encodeHostName]):
148         * Panels/WebAuthenticationPanel.m:
149         (-[WebAuthenticationPanel setUpForChallenge:]):
150         * WebCoreSupport/WebEditorClient.mm:
151         (WebEditorClient::canonicalizeURLString):
152
153 2016-03-14  Chris Dumez  <cdumez@apple.com>
154
155         Unreviewed, rolling out r197981.
156
157         Caused a massive PLT regression on Mac.
158
159         Reverted changeset:
160
161         "Font antialiasing (smoothing) changes when elements are
162         rendered into compositing layers"
163         https://bugs.webkit.org/show_bug.cgi?id=23364
164         http://trac.webkit.org/changeset/197981
165
166 2016-03-14  Sam Weinig  <sam@webkit.org>
167
168         Add a baseURL parameter to _WKUserStyleSheet
169         https://bugs.webkit.org/show_bug.cgi?id=155219
170
171         Reviewed by Tim Horton.
172
173         * WebView/WebView.mm:
174         (-[WebView _commonInitializationWithFrameName:groupName:]):
175         (-[WebView initSimpleHTMLDocumentWithStyle:frame:preferences:groupName:]):
176         (-[WebView setGroupName:]):
177         Update to account for the name change from UserContentController -> UserContentProvider.
178
179 2016-03-14  Joonghun Park  <jh718.park@samsung.com>
180
181         Purge PassRefPtr from ArrayBuffer, ArchiveResource, Pasteboard, LegacyWebArchive and DataObjectGtk
182         https://bugs.webkit.org/show_bug.cgi?id=150497
183
184         Reviewed by Darin Adler.
185
186         * DOM/WebDOMOperations.mm:
187         (-[DOMNode webArchive]):
188         (-[DOMNode webArchiveByFilteringSubframes:]):
189         * WebCoreSupport/WebPlatformStrategies.h:
190         * WebCoreSupport/WebPlatformStrategies.mm:
191         (WebPlatformStrategies::bufferForType):
192         (WebPlatformStrategies::readBufferFromPasteboard):
193         * WebView/WebArchive.mm:
194         (-[WebArchive initWithData:]):
195         * WebView/WebDataSource.mm:
196         (-[WebDataSource webArchive]):
197         (-[WebDataSource addSubresource:]):
198         * WebView/WebResource.mm:
199         (-[WebResource encodeWithCoder:]):
200         (-[WebResource data]):
201         (-[WebResource _stringValue]):
202         (-[WebResource _initWithCoreResource:]): Deleted.
203
204 2016-03-14  Oliver Hunt  <oliver@apple.com>
205
206         Temporarily disable the separated heap.
207         https://bugs.webkit.org/show_bug.cgi?id=155472
208
209         Reviewed by Geoffrey Garen.
210
211         Temporarily disable this.
212
213         * Configurations/FeatureDefines.xcconfig:
214
215 2016-03-14  Anders Carlsson  <andersca@apple.com>
216
217         Fix build.
218
219         Ignore nullability warnings, create an empty PDF selection.
220
221         * WebView/WebPDFView.mm:
222         (-[WebPDFView centerSelectionInVisibleArea:]):
223         (-[WebPDFView searchFor:direction:caseSensitive:wrap:startInSelection:]):
224         (+[WebPDFView _PDFSelectionClass]):
225         (-[WebPDFView _nextMatchFor:direction:caseSensitive:wrap:fromSelection:startInSelection:]):
226
227 2016-03-13  Joseph Pecoraro  <pecoraro@apple.com>
228
229         Remove ENABLE(ES6_TEMPLATE_LITERAL_SYNTAX) guards
230         https://bugs.webkit.org/show_bug.cgi?id=155417
231
232         Reviewed by Yusuke Suzuki.
233
234         * Configurations/FeatureDefines.xcconfig:
235
236 2016-03-13  Dean Jackson  <dino@apple.com>
237
238         <attachment> should be a runtime-enabled feature
239         https://bugs.webkit.org/show_bug.cgi?id=155413
240         <rdar://problem/25120753>
241
242         Reviewed by Sam Weinig and Anders Carlsson.
243
244         Add an internal setting on WebPreferences
245         to enable the <attachment> element support.
246
247         * WebView/WebPreferenceKeysPrivate.h:
248         * WebView/WebPreferences.mm:
249         (+[WebPreferences initialize]):
250         (-[WebPreferences attachmentElementEnabled]):
251         (-[WebPreferences setAttachmentElementEnabled:]):
252         * WebView/WebPreferencesPrivate.h:
253         * WebView/WebView.mm:
254         (-[WebView _preferencesChanged:]):
255
256 2016-03-12  Sam Weinig  <sam@webkit.org>
257
258         WebKit can easily crash below NetworkSession::dataTaskForIdentifier() with NSURLSession enabled
259         <rdar://problem/25129946>
260         https://bugs.webkit.org/show_bug.cgi?id=155401
261
262         Reviewed by Alex Christensen.
263
264         * WebCoreSupport/WebFrameNetworkingContext.mm:
265         (WebFrameNetworkingContext::ensurePrivateBrowsingSession):
266         Pass a SessionID to NetworkStorageSession::createPrivateBrowsingSession().
267
268 2016-03-12  Myles C. Maxfield  <mmaxfield@apple.com>
269
270         Delete dead SVG Font code
271         https://bugs.webkit.org/show_bug.cgi?id=154718
272
273         Reviewed by Antti Koivisto.
274
275         * Configurations/FeatureDefines.xcconfig:
276
277 2016-03-11  Yusuke Suzuki  <utatane.tea@gmail.com>
278
279         [ES6] Implement Reflect.set without receiver support
280         https://bugs.webkit.org/show_bug.cgi?id=155024
281
282         Reviewed by Geoffrey Garen.
283
284         As the same to NPJSObject, we just propagate the returned value of NetscapePluginInstanceProxy::setProperty.
285
286         * Plugins/Hosted/ProxyInstance.h:
287         * Plugins/Hosted/ProxyInstance.mm:
288         (WebKit::ProxyField::setValueToInstance):
289         (WebKit::ProxyInstance::setFieldValue):
290
291 2016-03-10  Jeremy Jones  <jeremyj@apple.com>
292
293         Set AVURLAssetUsesNoPersistentCacheKey on AVAsset to match caching policy.
294         https://bugs.webkit.org/show_bug.cgi?id=155117
295         rdar://problem/6802240
296
297         Reviewed by Simon Fraser.
298
299         Implement mediaShouldUsePersistentCache to disable media caching when NSURLCache is disabled.
300
301         * WebCoreSupport/WebChromeClient.h:
302         * WebCoreSupport/WebChromeClient.mm:
303         (WebChromeClient::mediaShouldUsePersistentCache): Added.
304
305 2016-03-10  Simon Fraser  <simon.fraser@apple.com>
306
307         Font antialiasing (smoothing) changes when elements are rendered into compositing layers
308         https://bugs.webkit.org/show_bug.cgi?id=23364
309
310         Reviewed by Tim Horton.
311
312         Allow internal clients to turn off smoothed layer text, so that WebKitTestRunner
313         can disable it.
314
315         * WebView/WebView.mm:
316         (+[WebView _setSmoothedLayerTextEnabled:]):
317         (+[WebView _smoothedLayerTextEnabled]):
318         * WebView/WebViewPrivate.h:
319
320 2016-03-10  Jer Noble  <jer.noble@apple.com>
321
322         Add WebCore, WebKit, & WebKit2 preference/setting to enable Main Content heuristic.
323         https://bugs.webkit.org/show_bug.cgi?id=155326
324         <rdar://problem/25095408>
325
326         Reviewed by Beth Dakin.
327
328         Add SPI to get and set the new preference.
329
330         * WebView/WebPreferenceKeysPrivate.h:
331         * WebView/WebPreferences.mm:
332         (-[WebPreferences overrideUserGestureRequirementForMainContent]):
333         (-[WebPreferences setOverrideUserGestureRequirementForMainContent:]):
334         * WebView/WebPreferencesPrivate.h:
335         * WebView/WebView.mm:
336         (-[WebView _preferencesChanged:]):
337
338 2016-03-07  Jer Noble  <jer.noble@apple.com>
339
340         Add separate WK and WK2 preferences for requiring user gestures for video media, distinct from user gestures for media generally
341         https://bugs.webkit.org/show_bug.cgi?id=155141
342
343         Reviewed by Beth Dakin.
344
345         Deprecate WebPreferences.mediaPlaybackRequiresUserGesture property in favor of .videoPlaybackRequiresUserGesture.
346
347         * WebView/WebPreferenceKeysPrivate.h:
348         * WebView/WebPreferences.mm:
349         (+[WebPreferences initialize]):
350         (-[WebPreferences mediaPlaybackRequiresUserGesture]):
351         (-[WebPreferences setMediaPlaybackRequiresUserGesture:]):
352         (-[WebPreferences videoPlaybackRequiresUserGesture]):
353         (-[WebPreferences setVideoPlaybackRequiresUserGesture:]):
354         * WebView/WebPreferencesPrivate.h:
355         * WebView/WebView.mm:
356         (-[WebView _preferencesChanged:]):
357
358 2016-03-10  Alexey Proskuryakov  <ap@apple.com>
359
360         Build fix for deprecated constant names.
361
362         * Carbon/CarbonWindowAdapter.mm:
363         (-[CarbonWindowAdapter initWithCarbonWindowRef:takingOwnership:disableOrdering:carbon:]):
364         (-[CarbonWindowAdapter sendSuperEvent:]):
365
366 2016-03-10  Commit Queue  <commit-queue@webkit.org>
367
368         Unreviewed, rolling out r197943.
369         https://bugs.webkit.org/show_bug.cgi?id=155317
370
371         This change broke Windows, WinCairo, GTK and EFL builds
372         (Requested by ryanhaddad on #webkit).
373
374         Reverted changeset:
375
376         "Add a baseURL parameter to _WKUserStyleSheet"
377         https://bugs.webkit.org/show_bug.cgi?id=155219
378         http://trac.webkit.org/changeset/197943
379
380 2016-03-08  Sam Weinig  <sam@webkit.org>
381
382         Add a baseURL parameter to _WKUserStyleSheet
383         https://bugs.webkit.org/show_bug.cgi?id=155219
384
385         Reviewed by Tim Horton.
386
387         * WebView/WebView.mm:
388         (-[WebView _commonInitializationWithFrameName:groupName:]):
389         (-[WebView initSimpleHTMLDocumentWithStyle:frame:preferences:groupName:]):
390         (-[WebView setGroupName:]):
391         Update to account for the name change from UserContentController -> UserContentProvider.
392
393 2016-02-22  Jer Noble  <jer.noble@apple.com>
394
395         Enable AVFoundationNSURLSessionEnabled by default
396         https://bugs.webkit.org/show_bug.cgi?id=154469
397
398         Reviewed by Sam Weinig.
399
400         * WebView/WebPreferences.mm:
401         (+[WebPreferences initialize]):
402
403 2016-03-09  Ryosuke Niwa  <rniwa@webkit.org>
404
405         Add runtime flags for shadow DOM and custom elements
406         https://bugs.webkit.org/show_bug.cgi?id=155213
407
408         Reviewed by Dean Jackson.
409
410         Set the runtime flag based on preferences. Enable shadow DOM and disable custom elements by default.
411
412         * WebView/WebPreferenceKeysPrivate.h:
413         * WebView/WebPreferences.mm:
414         (+[WebPreferences initialize]):
415         (-[WebPreferences shadowDOMEnabled]):
416         (-[WebPreferences setShadowDOMEnabled:]):
417         (-[WebPreferences customElementsEnabled]):
418         (-[WebPreferences setCustomElementsEnabled:]):
419         * WebView/WebPreferencesPrivate.h:
420         * WebView/WebView.mm:
421         (-[WebView _preferencesChanged:]):
422
423 2016-03-09  David Kilzer  <ddkilzer@apple.com>
424
425         REGRESSION (r197149): Missing availability checks when soft-linking DataDetectors.framework
426         <http://webkit.org/b/155258>
427
428         Reviewed by Andy Estes.
429
430         * WebView/WebImmediateActionController.mm:
431         (-[WebImmediateActionController _clearImmediateActionState]):
432         (-[WebImmediateActionController immediateActionRecognizerWillBeginAnimation:]):
433         (-[WebImmediateActionController _animationControllerForDataDetectedText]):
434         (-[WebImmediateActionController _animationControllerForDataDetectedLink]):
435         - Add check that returns early if DataDetectors.framework is not
436           available.
437
438 2016-03-08  Oliver Hunt  <oliver@apple.com>
439
440         Start moving to separated writable and executable mappings in the JIT
441         https://bugs.webkit.org/show_bug.cgi?id=155178
442
443         Reviewed by Fil Pizlo.
444
445         Update feature defines.
446
447         * Configurations/FeatureDefines.xcconfig:
448
449 2016-03-08  Commit Queue  <commit-queue@webkit.org>
450
451         Unreviewed, rolling out r197793 and r197799.
452         https://bugs.webkit.org/show_bug.cgi?id=155195
453
454         something weird happened while landing this and everything
455         broke (Requested by olliej on #webkit).
456
457         Reverted changesets:
458
459         "Start moving to separated writable and executable mappings in
460         the JIT"
461         https://bugs.webkit.org/show_bug.cgi?id=155178
462         http://trac.webkit.org/changeset/197793
463
464         "arm64 build fix after r197793."
465         http://trac.webkit.org/changeset/197799
466
467 2016-03-08  Oliver Hunt  <oliver@apple.com>
468
469         Start moving to separated writable and executable mappings in the JIT
470         https://bugs.webkit.org/show_bug.cgi?id=155178
471
472         Reviewed by Filip Pizlo.
473
474         Update feature defines.
475
476         * Configurations/FeatureDefines.xcconfig:
477
478 2016-03-08  Anders Carlsson  <andersca@apple.com>
479
480         Ignore deprecation warnings.
481
482         * Misc/WebNSEventExtras.m:
483         (-[NSEvent _web_isKeyEvent:]):
484         (-[NSEvent _web_isOptionTabKeyEvent]):
485         * Misc/WebNSViewExtras.m:
486         (-[NSView _web_dragShouldBeginFromMouseDown:withExpiration:xHysteresis:yHysteresis:]):
487         * Plugins/Hosted/NetscapePluginHostProxy.mm:
488         (WebKit::NetscapePluginHostProxy::beginModal):
489         * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
490         (WebKit::NetscapePluginInstanceProxy::syntheticKeyDownWithCommandModifier):
491         * Plugins/Hosted/WebHostedNetscapePluginView.mm:
492         (-[WebHostedNetscapePluginView drawRect:]):
493         * Plugins/WebNetscapePluginEventHandlerCocoa.mm:
494         (WebNetscapePluginEventHandlerCocoa::syntheticKeyDownWithCommandModifier):
495         * WebCoreSupport/PopupMenuMac.mm:
496         (PopupMenuMac::populate):
497         (PopupMenuMac::show):
498         * WebCoreSupport/WebContextMenuClient.mm:
499         (WebContextMenuClient::showContextMenu):
500         * WebCoreSupport/WebFrameLoaderClient.mm:
501         (WebFrameLoaderClient::actionDictionary):
502         * WebCoreSupport/WebInspectorClient.mm:
503         (WebInspectorFrontendClient::canAttach):
504         (-[WebInspectorWindowController window]):
505         * WebInspector/WebNodeHighlight.mm:
506         (-[WebNodeHighlight initWithTargetView:inspectorController:]):
507         * WebView/WebFrameView.mm:
508         (-[WebFrameView keyDown:keyDown:]):
509         * WebView/WebFullScreenController.mm:
510         (-[WebFullScreenController init]):
511         (createBackgroundFullscreenWindow):
512         * WebView/WebHTMLView.mm:
513         (-[WebHTMLView _postFakeMouseMovedEventForFlagsChangedEvent:]):
514         (-[WebHTMLView _setMouseDownEvent:_setMouseDownEvent:]):
515         (isQuickLookEvent):
516         (-[WebHTMLView hitTest:]):
517         (-[WebHTMLView _sendToolTipMouseExited]):
518         (-[WebHTMLView _sendToolTipMouseEntered]):
519         (mouseEventIsPartOfClickOrDrag):
520         (-[WebHTMLView _updateMouseoverWithEvent:]):
521         (-[WebHTMLView acceptsFirstResponder]):
522         (-[WebHTMLView viewDidMoveToWindow]):
523         (currentKeyboardEvent):
524         (-[WebHTMLView _handleStyleKeyEquivalent:]):
525         (-[WebHTMLView _interpretKeyEvent:savingCommands:]):
526         * WebView/WebPDFView.mm:
527         (-[WebPDFView hitTest:]):
528         (-[WebPDFView PDFViewWillClickOnLink:withURL:]):
529         (-[WebPDFView _fakeKeyEventWithFunctionKey:]):
530         * WebView/WebTextCompletionController.mm:
531         (-[WebTextCompletionController _buildUI]):
532         (-[WebTextCompletionController _placePopupWindow:]):
533         * WebView/WebView.mm:
534         (-[WebView applicationFlags:]):
535
536 2016-03-07  Brent Fulgham  <bfulgham@apple.com>
537
538         Reduce startup and shutdown cost of resource load statistics
539         https://bugs.webkit.org/show_bug.cgi?id=155120
540         <rdar://problem/25010167>
541
542         Reviewed by Andy Estes.
543
544         Remove the Resource Load Statistics stuff from WK1, now that it is up and
545         running in WK2.
546
547         * WebView/WebView.mm:
548         (-[WebView _preferencesChanged:]): Remove call to read resource load
549         statistics from disk.
550         (+[WebView _applicationWillTerminate]): Remove call to write resource load
551         statistics to disk.
552
553 2016-03-06  Andreas Kling  <akling@apple.com>
554
555         Reduce page cache capacity from 3 to 2.
556         <https://webkit.org/b/155087>
557
558         Reviewed by Antti Koivisto.
559
560         Trim WebKit1 page cache capacities consistently with WebKit2.
561
562         * WebView/WebView.mm:
563         (+[WebView _setCacheModel:]):
564
565 2016-03-05  Chris Dumez  <cdumez@apple.com>
566
567         Consolidate RuntimeApplicationChecks and RuntimeApplicationChecksIOS
568         https://bugs.webkit.org/show_bug.cgi?id=155035
569
570         Reviewed by Darin Adler.
571
572         Update runtime application checks.
573
574         * Plugins/WebPluginController.mm:
575         (initializeAudioSession):
576         * WebCoreSupport/WebFrameLoaderClient.mm:
577         * WebView/WebFrame.mm:
578         (needsMicrosoftMessengerDOMDocumentWorkaround):
579         * WebView/WebImmediateActionController.mm:
580         (-[WebImmediateActionController _updateImmediateActionItem]):
581         * WebView/WebView.mm:
582         (WebKitInitializeApplicationCachePathIfNecessary):
583         (shouldEnableLoadDeferring):
584         (shouldRestrictWindowFocus):
585         (needsOutlookQuirksScript):
586         (shouldTransformsAffectOverflow):
587         (shouldDispatchJavaScriptWindowOnErrorEvents):
588         (shouldUseLegacyBackgroundSizeShorthandBehavior):
589         (-[WebView _commonInitializationWithFrameName:groupName:]):
590         (+[WebView enableWebThread]):
591         (+[WebView registerForMemoryNotifications]):
592         (-[WebView _needsKeyboardEventDisambiguationQuirks]):
593         (needsSelfRetainWhileLoadingQuirk):
594         (-[WebView _needsPreHTML5ParserQuirks]):
595
596 2016-03-05  Yusuke Suzuki  <utatane.tea@gmail.com>
597
598         [ES6] Support Reflect.construct
599         https://bugs.webkit.org/show_bug.cgi?id=147330
600
601         Reviewed by Saam Barati.
602
603         * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
604         (WebKit::NetscapePluginInstanceProxy::invoke):
605         (WebKit::NetscapePluginInstanceProxy::invokeDefault):
606         (WebKit::NetscapePluginInstanceProxy::construct):
607
608 2016-03-04  Brent Fulgham  <bfulgham@apple.com>
609
610         Unreviewed test fix for null global WebResourceLoadStatisticsStore.
611
612         * WebView/WebView.mm:
613         (-[WebView _preferencesChanged:]):
614         (+[WebView _applicationWillTerminate]):
615
616 2016-03-04  Brent Fulgham  <bfulgham@apple.com>
617
618         [WK2] Gather resource load statistics
619         https://bugs.webkit.org/show_bug.cgi?id=154278
620         <rdar://problem/24702892>
621
622         Reviewed by Andy Estes.
623
624         Switch to maintaining a global WebCore::ResourceLoadStatisticsStore in the WebKit process,
625         and hand it off to the WebCore layer to use during data gathering. The ResourceLoadStatisticsStore
626         is now responsible for reading/writing to disk, and tracking the collection of load data.
627
628         * WebView/WebView.mm:
629         (WebKitInitializeApplicationStatisticsStoragePathIfNecessary): Initialize singleton
630         ResourceLoadStatisticsStore object for tracking state.
631         (-[WebView _preferencesChanged:]): Revise for new singleton.
632         (+[WebView _applicationWillTerminate]): Ditto.
633
634 2016-02-29  Ada Chan  <adachan@apple.com>
635
636         Adopt the new version of AVOutputDeviceMenuController's showMenuForRect method.
637         https://bugs.webkit.org/show_bug.cgi?id=154823
638
639         Reviewed by Tim Horton.
640
641         * WebCoreSupport/WebChromeClient.h:
642         * WebCoreSupport/WebChromeClient.mm:
643         (WebChromeClient::showPlaybackTargetPicker):
644         * WebView/WebMediaPlaybackTargetPicker.h:
645         * WebView/WebMediaPlaybackTargetPicker.mm:
646         (WebMediaPlaybackTargetPicker::showPlaybackTargetPicker):
647         (WebMediaPlaybackTargetPicker::customPlaybackActionSelected):
648         * WebView/WebView.mm:
649         (-[WebView _showPlaybackTargetPicker:location:hasVideo:]):
650
651 2016-03-01  Tim Horton  <timothy_horton@apple.com>
652
653         Expose MediaElement and VideoElement to the Objective-C DOM bindings
654         https://bugs.webkit.org/show_bug.cgi?id=154830
655
656         Reviewed by Sam Weinig.
657
658         * MigrateHeaders.make:
659
660 2016-02-29  Simon Fraser  <simon.fraser@apple.com>
661
662         Remove the experimental feature of antialiased font dilation
663         https://bugs.webkit.org/show_bug.cgi?id=154843
664
665         Reviewed by Zalan Bujtas.
666
667         Remove the "antialiased font dilation" code path, and related prefs.
668
669         * WebView/WebPreferenceKeysPrivate.h:
670         * WebView/WebPreferences.mm:
671         (+[WebPreferences initialize]): Deleted.
672         (-[WebPreferences setAntialiasedFontDilationEnabled:]): Deleted.
673         (-[WebPreferences antialiasedFontDilationEnabled]): Deleted.
674         * WebView/WebPreferencesPrivate.h:
675         * WebView/WebView.mm:
676         (-[WebView _preferencesChanged:]): Deleted.
677
678 2016-02-26  Dan Bernstein  <mitz@apple.com>
679
680         Build fix for when WK_OVERRIDE_FRAMEWORKS_DIR contains spaces.
681
682         * Configurations/WebKitLegacy.xcconfig: Added quotes.
683
684 2016-02-25  Ada Chan  <adachan@apple.com>
685
686         Update the definition of ENABLE_VIDEO_PRESENTATION_MODE for Mac platform
687         https://bugs.webkit.org/show_bug.cgi?id=154702
688
689         Reviewed by Dan Bernstein.
690
691         * Configurations/FeatureDefines.xcconfig:
692
693 2016-02-25  Jiewen Tan  <jiewen_tan@apple.com>
694
695         Restrict information passed with navigation action which is triggered by untrusted event
696         https://bugs.webkit.org/show_bug.cgi?id=154571
697         <rdar://problem/15967937>
698
699         Reviewed by Andy Estes.
700
701         * WebCoreSupport/WebFrameLoaderClient.mm:
702         (WebFrameLoaderClient::actionDictionary):
703
704 2016-02-25  Eric Carlson  <eric.carlson@apple.com>
705
706         [MediaStream] MediaDeviceInfo deviceId and groupId must be unique to the page's origin
707         https://bugs.webkit.org/show_bug.cgi?id=153163
708         <rdar://problem/24334526>
709
710         Reviewed by Tim Horton.
711
712         * WebCoreSupport/WebUserMediaClient.mm:
713         (WebUserMediaClient::requestUserMediaAccess):
714         (WebUserMediaClient::checkUserMediaPermission):
715         (-[WebUserMediaPolicyCheckerListener allow]):
716         (-[WebUserMediaPolicyCheckerListener deny]):
717
718 2016-02-24  Nikos Andronikos  <nikos.andronikos-webkit@cisra.canon.com.au>
719
720         [web-animations] Add AnimationTimeline, DocumentTimeline and add extensions to Document interface
721         https://bugs.webkit.org/show_bug.cgi?id=151688
722
723         Reviewed by Dean Jackson.
724
725         Enables the WEB_ANIMATIONS compiler switch.
726
727         * Configurations/FeatureDefines.xcconfig:
728
729 2016-02-23  Dan Bernstein  <mitz@apple.com>
730
731         [Xcode] Linker errors display mangled names, but no longer should
732         https://bugs.webkit.org/show_bug.cgi?id=154632
733
734         Reviewed by Sam Weinig.
735
736         * Configurations/Base.xcconfig: Stop setting LINKER_DISPLAYS_MANGLED_NAMES to YES.
737
738 2016-02-23  Gavin Barraclough  <barraclough@apple.com>
739
740         Remove HIDDEN_PAGE_DOM_TIMER_THROTTLING feature define
741         https://bugs.webkit.org/show_bug.cgi?id=112323
742
743         Reviewed by Chris Dumez.
744
745         This feature is controlled by a runtime switch, and defaults off.
746
747         * Configurations/FeatureDefines.xcconfig:
748         * WebView/WebView.mm:
749         (-[WebView _preferencesChanged:]):
750
751 2016-02-22  Commit Queue  <commit-queue@webkit.org>
752
753         Unreviewed, rolling out r196935.
754         https://bugs.webkit.org/show_bug.cgi?id=154557
755
756         This change causes timeouts and crashes in LayoutTests
757         (Requested by ryanhaddad on #webkit).
758
759         Reverted changeset:
760
761         "Enable AVFoundationNSURLSessionEnabled by default"
762         https://bugs.webkit.org/show_bug.cgi?id=154469
763         http://trac.webkit.org/changeset/196935
764
765 2016-02-22  Keith Rollin  <krollin@apple.com>
766
767         Add mechanism to disable memory pressure handling
768         https://bugs.webkit.org/show_bug.cgi?id=154254
769         <rdar://problem/24662616>
770
771         Reviewed by Chris Dumez.
772
773         Add a mechanism to disable WebKit's response to memory pressure
774         triggers. This was asked for by another group for testing purposes.
775
776         In order to disable WebKit's memory pressure handling, execute the
777         following from the command line:
778
779             defaults write com.apple.Safari WebKitSuppressMemoryPressureHandler -bool true
780
781         To revert to standard behavior, delete the key or set it to False.
782
783         This flag is used when a new sub-process is being spawned. The value
784         is read and stored in an initialization parameter block, which is then
785         sent to the new sub-process.
786
787         In actuality, only the UI, WebContent, and Network processes heed the
788         flag. The Plugin process isn't instrumented to heed this flag for
789         three reasons. First, the Plugin process installs its memory pressure
790         handler in initializeProcess, not initializePluginProcess. This is
791         contrary to when the other processes install their handlers, which is
792         in initialize<PluginType>Process, not initializeProcess. So in order
793         to accomodate the Plugin process, we'd need to modify
794         ChildProcessInitializationParameters. Doing this is awkward at best,
795         but also seems to be opposed to what's supposed to be done in
796         initializeProcess and conveyed in
797         ChildProcessInitializationParameters. And even if we did add a boolean
798         to this structure and added support for conveying it through the XPC
799         port, it would end up being a Plugin process-only boolean in a general
800         parameter block, which seems asymmetric with the other processes.
801         Second, there's no convenient Cocoa function called in the flow that
802         spawns the Plugin process, meaning that there's no convenient place to
803         call NSUserDefaults to get the flag's value. And third, the Plugin
804         process doesn't elegantly respond to the memory pressure trigger
805         anyway. It might terminate itself, but that's it. As for the Database
806         process, it doesn't seem to support responding to memory pressure at
807         all, so we don't send it a flag telling it to ignore it.
808
809         Internally, the memory pressure handler is suppressed by not calling
810         MemoryPressureHandler::install() if the flag is set. In the case of
811         the Network process, the flag is saved so that it can be checked later
812         in other places that manually kick off the memory pressure handling
813         procedure.
814
815         * WebView/WebView.mm:
816         (-[WebView _commonInitializationWithFrameName:groupName:]):
817         (WebInstallMemoryPressureHandler):
818
819 2016-02-22  Jer Noble  <jer.noble@apple.com>
820
821         Enable AVFoundationNSURLSessionEnabled by default
822         https://bugs.webkit.org/show_bug.cgi?id=154469
823
824         Reviewed by Sam Weinig.
825
826         * WebView/WebPreferences.mm:
827         (+[WebPreferences initialize]):
828
829 2016-02-15  Brent Fulgham  <bfulgham@apple.com>
830
831         [Mac] Gather some rudimentary statistics during resource load 
832         https://bugs.webkit.org/show_bug.cgi?id=153575
833         <rdar://problem/24075254>
834
835         Reviewed by Brady Eidson.
836
837         * Misc/WebKitNSStringExtras.h:
838         * Misc/WebKitNSStringExtras.mm:
839         (+[NSString _webkit_localStorageDirectoryWithBundleIdentifier:]): Added.
840         * WebView/WebPreferenceKeysPrivate.h:
841         * WebView/WebPreferences.mm:
842         (+[WebPreferences initialize]):
843         (-[WebPreferences resourceLoadStatisticsEnabled]): Added.
844         (-[WebPreferences setResourceLoadStatisticsEnabled:]): Added.
845         * WebView/WebPreferencesPrivate.h:
846         * WebView/WebView.mm:
847         (WebKitInitializeApplicationCachePathIfNecessary):
848         (WebKitInitializeApplicationStatisticsStoragePathIfNecessary): Added.
849         (-[WebView _commonInitializationWithFrameName:groupName:]): Add call to new
850         initialization method.
851         (-[WebView _preferencesChanged:]): Track changes in the user's desire to
852         monitor resource load statistics.
853         (+[WebView _applicationWillTerminate]): Write statistics to disk (if preferences
854         say to do so.)
855
856 2016-02-13  Mark Lam  <mark.lam@apple.com>
857
858         Add thread violation checks to WebView public APIs.
859         https://bugs.webkit.org/show_bug.cgi?id=154183
860
861         Reviewed by Timothy Hatcher.
862
863         Re-landing r196527 with a newly added WebCoreThreadViolationCheckRoundThree().
864         Previously was using WebCoreThreadViolationCheckRoundTwo().
865
866         * Misc/WebKitVersionChecks.h:
867         * WebView/WebFrameView.mm:
868         (-[WebFrameView initWithFrame:]):
869         * WebView/WebView.mm:
870         (-[WebView setCustomTextEncodingName:]):
871         (-[WebView stringByEvaluatingJavaScriptFromString:]):
872         (-[WebView windowScriptObject]):
873         (-[WebView setGroupName:]):
874         (-[WebView setMainFrameURL:]):
875         (-[WebView mainFrameTitle]):
876         (-[WebView mainFrameIcon]):
877         (-[WebView setDrawsBackground:]):
878         (-[WebView setShouldUpdateWhileOffscreen:]):
879
880 2016-02-12  Commit Queue  <commit-queue@webkit.org>
881
882         Unreviewed, rolling out r196527.
883         https://bugs.webkit.org/show_bug.cgi?id=154204
884
885         "Need to redo as WebCoreThreadViolationCheckRoundThree"
886         (Requested by mlam on #webkit).
887
888         Reverted changeset:
889
890         "Add thread violation checks to WebView public APIs."
891         https://bugs.webkit.org/show_bug.cgi?id=154183
892         http://trac.webkit.org/changeset/196527
893
894 2016-02-12  Mark Lam  <mark.lam@apple.com>
895
896         Add thread violation checks to WebView public APIs.
897         https://bugs.webkit.org/show_bug.cgi?id=154183
898
899         Reviewed by Geoffrey Garen.
900
901         This will help clients of the API detect the violations sooner rather than
902         having to debug mysterious crashes / failures later.
903
904         To that end, I've added thread violation checks to the following functions
905         because ...
906
907         * WebView/WebView.mm:
908         (-[WebView setCustomTextEncodingName:]):
909         - Uses the FrameLoader (which is for the main thread only).
910
911         (-[WebView stringByEvaluatingJavaScriptFromString:]):
912         - Invokes JavaScript (which is for the main thread only).
913
914         (-[WebView windowScriptObject]):
915         - Invokes ScriptController::windowScriptObject() which requires the JSLock.
916
917         (-[WebView setGroupName:]):
918         - Manipulates the PageGroup and Page (which is for the main thread only).
919
920         (-[WebView setMainFrameURL:]):
921         - Uses the FrameLoader (which is for the main thread only).
922
923         (-[WebView mainFrameTitle]):
924         - Uses the FrameLoader::documentLoader() (via [WebFrame _dataSource]) which
925           is RefPtr, and therefore not safe for other threads to access.
926
927         (-[WebView mainFrameIcon]):
928         - Uses the FrameLoader::documentLoader() (via [WebFrame _dataSource]) which
929           is RefPtr, and therefore not safe for other threads to access.
930         - Uses [WebIconDatabase sharedIconDatabase] which does a singleton
931           instantiation but is not protected by a lock.
932
933         (-[WebView setDrawsBackground:]):
934         - Potentially manipulates a RenderView (via FrameView::setBaseBackgroundColor,
935           via [WebFrame _updateBackgroundAndUpdatesWhileOffscreen]), and RenderView
936           is for main thread only use.
937
938         (-[WebView setShouldUpdateWhileOffscreen:]):
939         - Uses [WebFrame _updateBackgroundAndUpdatesWhileOffscreen].  Hence, for the
940           main thread only.
941
942 2016-02-12  Sukolsak Sakshuwong  <sukolsak@gmail.com>
943
944         Update ICU header files to version 52
945         https://bugs.webkit.org/show_bug.cgi?id=154160
946
947         Reviewed by Alex Christensen.
948
949         Update ICU header files to version 52 to allow the use of newer APIs.
950
951         * icu/unicode/localpointer.h:
952         * icu/unicode/platform.h:
953         * icu/unicode/ptypes.h:
954         * icu/unicode/putil.h:
955         * icu/unicode/uchar.h:
956         * icu/unicode/uconfig.h:
957         * icu/unicode/uidna.h:
958         * icu/unicode/uiter.h:
959         * icu/unicode/umachine.h:
960         * icu/unicode/unorm2.h:
961         * icu/unicode/urename.h:
962         * icu/unicode/uscript.h:
963         * icu/unicode/ustring.h:
964         * icu/unicode/utf.h:
965         * icu/unicode/utf16.h:
966         * icu/unicode/utf8.h:
967         * icu/unicode/utf_old.h:
968         * icu/unicode/utypes.h:
969         * icu/unicode/uvernum.h:
970         * icu/unicode/uversion.h:
971
972 2016-02-12  Beth Dakin  <bdakin@apple.com>
973
974         NSRangeIsRelativeTo should not have NS prefix
975         https://bugs.webkit.org/show_bug.cgi?id=154174
976
977         Reviewed by Tim Horton.
978
979         NSRangeIsRelativeTo -> WebRangeIsRelativeTo
980         * WebView/WebFrame.mm:
981         (-[WebFrame _convertToDOMRange:]):
982         (-[WebFrame _convertToDOMRange:rangeIsRelativeTo:]):
983         * WebView/WebFrameInternal.h:
984         * WebView/WebHTMLView.mm:
985         (-[WebHTMLView insertText:]):
986
987 2016-02-11  Beth Dakin  <bdakin@apple.com>
988
989         EditingRangeIsRelativeTo::Document and NSRangeIsRelativeTo::Document should 
990         be called EditableRoot instead
991         https://bugs.webkit.org/show_bug.cgi?id=154138
992
993         Reviewed by Alexey Proskuryakov.
994
995         EditableRoot is much more accurate than Document.
996         * WebView/WebFrame.mm:
997         (-[WebFrame _convertToDOMRange:]):
998         (-[WebFrame _convertToDOMRange:rangeIsRelativeTo:]):
999         * WebView/WebFrameInternal.h:
1000         * WebView/WebHTMLView.mm:
1001         (-[WebHTMLView insertText:]):
1002
1003 2016-02-11  Beth Dakin  <bdakin@apple.com>
1004
1005         Soft spaces are often tracked in the wrong spot
1006         https://bugs.webkit.org/show_bug.cgi?id=154127
1007         -and corresponding-
1008         rdar://problem/24493140
1009
1010         Reviewed by Sam Weinig.
1011
1012         Soft spaces are in the wrong space now for two reasons. First of all, the 
1013         NSRange we get from the accepted candidate is relative to the paragraph 
1014         start, so without this patch, soft spaces are only ever right for the first 
1015         paragraph. Secondly, if focus changes for any reason other than text 
1016         insertion, soft spaces are also wrong because they need to be re-set.
1017
1018         New version of _convertToDOMRange takes a NSRangeIsRelativeTo so that it can 
1019         handle ranges relative to both the document and the paragraph. 
1020         * WebView/WebFrame.mm:
1021         (-[WebFrame _convertToDOMRange:rangeIsRelativeTo:]):
1022         (-[WebFrame _convertNSRangeToDOMRange:]):
1023
1024         New enum NSRangeIsRelativeTo.
1025         * WebView/WebFrameInternal.h:
1026
1027         Re-set the softSpaceRange on selection changes so long as the WebCore::Editor 
1028         is not currently handling an accepted candidate.
1029         * WebView/WebHTMLView.mm:
1030         (-[WebHTMLView _selectionChanged]):
1031
1032         If needToRemoveSoftSpace is true, then the replacementRange is 
1033         relative to the paragraph.
1034         (-[WebHTMLView insertText:]):
1035
1036 2016-02-10  Mark Lam  <mark.lam@apple.com>
1037
1038         WebFrame _stringByEvaluatingJavaScriptFromString:forceUserGesture: should assert that it is being called from the "main" thread.
1039         https://bugs.webkit.org/show_bug.cgi?id=154059
1040
1041         Reviewed by Geoffrey Garen.
1042
1043         This makes it so that misbehaving clients which call it (indirectly) from another
1044         thread (not the main thread) will fail faster.  Otherwise, we get potential
1045         memory corruption that results in strange crashes elsewhere later.
1046
1047         * WebView/WebFrame.mm:
1048         (-[WebFrame _stringByEvaluatingJavaScriptFromString:forceUserGesture:]):
1049
1050 2016-02-04  Jer Noble  <jer.noble@apple.com>
1051
1052         [Mac] Adopt NSURLSession properties in AVAssetResourceLoader
1053         https://bugs.webkit.org/show_bug.cgi?id=153873
1054
1055         Reviewed by Eric Carlson.
1056
1057         Add a WebKit preference to control the WebCore isAVFoundationNSURLSessionEnabled()
1058         setting.
1059
1060         * WebView/WebPreferenceKeysPrivate.h:
1061         * WebView/WebPreferences.mm:
1062         (+[WebPreferences initialize]):
1063         (-[WebPreferences setAVFoundationNSURLSessionEnabled:]):
1064         (-[WebPreferences isAVFoundationNSURLSessionEnabled]):
1065         * WebView/WebPreferencesPrivate.h:
1066         * WebView/WebView.mm:
1067         (-[WebView _preferencesChanged:]):
1068
1069 2016-02-09  Eric Carlson  <eric.carlson@apple.com>
1070
1071         checkValidity() sometimes asserts in WebUserMediaClient::pageDestroyed
1072         https://bugs.webkit.org/show_bug.cgi?id=154029
1073         <rdar://problem/24065022>
1074
1075         Reviewed by Alex Christensen.
1076
1077         * WebCoreSupport/WebUserMediaClient.mm:
1078         (WebUserMediaClient::pageDestroyed): Copy map keys to a vector and clear the map before
1079           enumerating the vector and canceling the requests. ASSERT that the map is not modified
1080           during cleanup. Clean up the permission check map.
1081         (WebUserMediaClient::requestUserMediaAccess): Add the request to the map before calling the
1082           UI delegate in case it works synchronously (as it does in DRT).
1083         (WebUserMediaClient::checkUserMediaPermission): Ditto.
1084         (WebUserMediaClient::cancelUserMediaPermissionCheck): White-space cleanup.
1085         (-[WebUserMediaPolicyListener allow]): Ditto.
1086
1087 2016-02-08  Anders Carlsson  <andersca@apple.com>
1088
1089         Crash when trying to chain to the old -[NSView setNeedsDisplayInRect:]
1090         https://bugs.webkit.org/show_bug.cgi?id=154001
1091         rdar://problem/24519975
1092
1093         Reviewed by Dan Bernstein.
1094
1095         If our replaced -[NSView setNeedsDisplayInRect:] is called before the old IMP has been initialized,
1096         we can end up trying to call a null pointer. 
1097         
1098         Fix this by using method_exchangeImplementations instead of method_setImplementation, since the former is done
1099         atomically.
1100
1101         * WebView/WebHTMLView.mm:
1102         (-[NSView _web_setNeedsDisplayInRect:]):
1103         (+[WebHTMLViewPrivate initialize]):
1104         (setNeedsDisplayInRect): Deleted.
1105
1106 2016-02-07  Dan Bernstein  <mitz@apple.com>
1107
1108         [Cocoa] Replace __has_include guards around inclusion of Apple-internal-SDK headers with USE(APPLE_INTERNAL_SDK)
1109         https://bugs.webkit.org/show_bug.cgi?id=153963
1110
1111         Reviewed by Sam Weinig.
1112
1113         * WebView/WebPDFView.mm:
1114
1115 2016-02-06  Darin Adler  <darin@apple.com>
1116
1117         Finish auditing call sites of upper() and lower(), eliminate many, and rename the functions
1118         https://bugs.webkit.org/show_bug.cgi?id=153905
1119
1120         Reviewed by Sam Weinig.
1121
1122         * Plugins/WebBasePluginPackage.mm:
1123         (-[WebBasePluginPackage getPluginInfoFromPLists]): Use modern for loops.
1124         (-[WebBasePluginPackage supportsExtension:]): Use convertToASCIILowercase for extension assert.
1125         Also use modern for loop.
1126         (-[WebBasePluginPackage supportsMIMEType:]): Ditto.
1127         (-[WebBasePluginPackage MIMETypeForExtension:]): Ditto.
1128
1129 2016-02-03  Jessie Berlin  <jberlin@webkit.org>
1130
1131         Build fix.
1132
1133         [NSEvent context] has always returned nil. Replace uses with nullptr.
1134
1135         * WebView/WebHTMLView.mm:
1136         (-[WebHTMLView _postFakeMouseMovedEventForFlagsChangedEvent:]):
1137         (-[WebHTMLView _updateMouseoverWithFakeEvent]):
1138         (-[WebHTMLView _updateMouseoverWithEvent:]):
1139         (-[WebHTMLView _autoscroll]):
1140         (-[WebHTMLView draggedImage:endedAt:operation:]):
1141
1142 2016-02-01  Dave Hyatt  <hyatt@apple.com>
1143
1144         Add a line grid pagination SPI to WebKit.
1145         https://bugs.webkit.org/show_bug.cgi?id=153757
1146         <rdar://problem/23041598>
1147
1148         Reviewed by Anders Carlsson.
1149
1150         * WebView/WebView.mm:
1151         (-[WebView _setPaginationLineGridEnabled:]):
1152         (-[WebView _paginationLineGridEnabled]):
1153         * WebView/WebViewPrivate.h:
1154
1155 2016-02-01  Joseph Pecoraro  <pecoraro@apple.com>
1156
1157         Web Inspector: High Level Memory Overview Instrument
1158         https://bugs.webkit.org/show_bug.cgi?id=153516
1159         <rdar://problem/24356378>
1160
1161         Reviewed by Brian Burg.
1162
1163         * Configurations/FeatureDefines.xcconfig:
1164
1165 2016-01-31  Darin Adler  <darin@apple.com>
1166
1167         Cut down on calls to String::lower; mostly replace with convertToASCIILowercase
1168         https://bugs.webkit.org/show_bug.cgi?id=153732
1169
1170         Reviewed by Dean Jackson.
1171
1172         * WebView/WebHTMLRepresentation.mm:
1173         (newArrayWithStrings): Updated to use HashSet<String, ASCIICaseInsensitiveHash>
1174         and also to use a modern for loop.
1175
1176 2016-01-31  Dan Bernstein  <mitz@apple.com>
1177
1178         [Cocoa] Remove __has_include guards around use of WebKitAdditions
1179         https://bugs.webkit.org/show_bug.cgi?id=153728
1180
1181         Reviewed by Andy Estes.
1182
1183         Guard WebKitAdditions includes with #if USE(APPLE_INTERNAL_SDK) rather than with __has_include.
1184
1185         * WebKitAdditions.mm:
1186         * WebView/WebView.mm:
1187         (-[WebView _commonInitializationWithFrameName:groupName:]):
1188         (-[WebView initSimpleHTMLDocumentWithStyle:frame:preferences:groupName:]):
1189
1190 2016-01-29  Ada Chan  <adachan@apple.com>
1191
1192         Enable VIDEO_PRESENTATION_MODE only in Debug and Release builds on Mac
1193         https://bugs.webkit.org/show_bug.cgi?id=153665
1194
1195         Reviewed by Dan Bernstein.
1196
1197         * Configurations/FeatureDefines.xcconfig:
1198
1199 2016-01-28  Darin Adler  <darin@apple.com>
1200
1201         Remove equalIgnoringCase since all callers really wanted equalIgnoringASCIICase
1202         https://bugs.webkit.org/show_bug.cgi?id=153411
1203
1204         Reviewed by Ryosuke Niwa.
1205
1206         * WebCoreSupport/WebFrameLoaderClient.mm:
1207         (parameterValue): Use equalIgnoringASCIICase. No behavior change because the
1208         only name we ever search for with this is "pluginspage".
1209
1210 2016-01-27  Enrica Casucci  <enrica@apple.com>
1211
1212         Cache results of data detection in the UI process when load completes.
1213         https://bugs.webkit.org/show_bug.cgi?id=153560
1214
1215         Reviewed by Tim Horton.
1216
1217         Adding empty implementation for WK1.
1218
1219         * WebCoreSupport/WebFrameLoaderClient.h:
1220         * WebCoreSupport/WebFrameLoaderClient.mm:
1221         (WebFrameLoaderClient::dispatchDidFinishDataDetection):
1222
1223 2016-01-27  Anders Carlsson  <andersca@apple.com>
1224
1225         Add WebKitAdditions extension points to WebCore, WebKit and WebKitLegacy
1226         https://bugs.webkit.org/show_bug.cgi?id=153550
1227
1228         Reviewed by Sam Weinig.
1229
1230         * Configurations/WebKitLegacy.xcconfig:
1231         Add WKA header search paths.
1232
1233         * WebKitAdditions.mm: Added.
1234         Add addition files.
1235
1236         * WebView/WebView.mm:
1237         (-[WebView _commonInitializationWithFrameName:groupName:]):
1238         (-[WebView initSimpleHTMLDocumentWithStyle:frame:preferences:groupName:]):
1239         Add extension points.
1240
1241 2016-01-27  Chris Dumez  <cdumez@apple.com>
1242
1243         window.atob() should ignore spaces in input
1244         https://bugs.webkit.org/show_bug.cgi?id=153522
1245         <rdar://problem/24357822>
1246
1247         Reviewed by Benjamin Poulain.
1248
1249         * WebCoreSupport/WebInspectorClient.mm:
1250         (WebInspectorFrontendClient::save):
1251
1252 2016-01-27  Alexey Proskuryakov  <ap@apple.com>
1253
1254         Remove ENABLE_CURRENTSRC
1255         https://bugs.webkit.org/show_bug.cgi?id=153545
1256
1257         Reviewed by Simon Fraser.
1258
1259         * Configurations/FeatureDefines.xcconfig:
1260
1261 2016-01-25  Beth Dakin  <bdakin@apple.com>
1262
1263         Build fix.
1264
1265         * WebView/WebHTMLView.mm:
1266         (-[WebHTMLView initWithFrame:]):
1267         (-[WebHTMLView insertText:]):
1268
1269 2016-01-25  Beth Dakin  <bdakin@apple.com>
1270
1271         WK1: Handle soft spaces after accepted candidates
1272         https://bugs.webkit.org/show_bug.cgi?id=153442
1273         -and corresponding-
1274         rdar://problem/23958418
1275
1276         Reviewed by Tim Horton.
1277
1278         The space at the end of candidates is a soft space. If that space exists, 
1279         cache the range of the space in m_softSpaceRange.
1280         * WebCoreSupport/WebEditorClient.mm:
1281         (WebEditorClient::handleAcceptedCandidate):
1282
1283         New ivar in WebHTMLViewPrivate softSpaceRange keeps track to the NSRange of a 
1284         soft space if the last text that was inserted has a soft space at the end.
1285         * WebView/WebHTMLView.mm:
1286         (-[WebHTMLView initWithFrame:]):
1287         (-[WebHTMLView _setSoftSpaceRange:]):
1288
1289         When new text is inserted, find out if it is being inserted right after a 
1290         soft space. If it is, then [NSSpellChecker deletesAutospaceBeforeString] will 
1291         tell us if the space needs to be removed. If that is the case, then set the 
1292         replacementString to the soft space.
1293         (-[WebHTMLView insertText:]):
1294         * WebView/WebHTMLViewInternal.h:
1295
1296 2016-01-17  Ada Chan  <adachan@apple.com>
1297
1298         Add a mode parameter to MediaControllerInterface::supportsFullscreen() and ChromeClient::supportsVideoFullscreen().
1299         https://bugs.webkit.org/show_bug.cgi?id=153220
1300
1301         Reviewed by Eric Carlson.
1302
1303         * WebCoreSupport/WebChromeClient.h:
1304         * WebCoreSupport/WebChromeClient.mm:
1305         (WebChromeClient::supportsVideoFullscreen):
1306
1307 2016-01-22  Darin Adler  <darin@apple.com>
1308
1309         Reduce use of equalIgnoringCase to just ignore ASCII case
1310         https://bugs.webkit.org/show_bug.cgi?id=153266
1311
1312         Reviewed by Ryosuke Niwa.
1313
1314         * WebCoreSupport/WebFrameLoaderClient.mm:
1315         (WebFrameLoaderClient::createPlugin): Use equalLettersIgnoringASCIICase.
1316
1317 2016-01-21  Brent Fulgham  <bfulgham@apple.com>
1318
1319         [Mac] Tooltips do not honor some types of obscuring windows
1320         https://bugs.webkit.org/show_bug.cgi?id=153263
1321         <rdar://problem/21423972>
1322
1323         Reviewed by Simon Fraser.
1324
1325         * WebView/WebHTMLView.mm:
1326         (-[WebHTMLView _updateMouseoverWithEvent:]): When the WebView is not the key window, don't
1327         display tooltips.
1328
1329 2016-01-19  Ada Chan  <adachan@apple.com>
1330
1331         Make it possible to enable VIDEO_PRESENTATION_MODE on other Cocoa platforms.
1332         https://bugs.webkit.org/show_bug.cgi?id=153218
1333
1334         Reviewed by Eric Carlson.
1335
1336         * Configurations/FeatureDefines.xcconfig:
1337
1338 2016-01-19  Beth Dakin  <bdakin@apple.com>
1339
1340         32-bit build fix.
1341
1342         * WebView/WebView.mm:
1343         (-[WebView updateWebViewAdditions]):
1344         (-[WebView showCandidates:forString:inRect:view:completionHandler:]):
1345         * WebView/WebViewInternal.h:
1346
1347 2016-01-19  Beth Dakin  <bdakin@apple.com>
1348
1349         Move away from NSSpellChecker's showCandidates method
1350         https://bugs.webkit.org/show_bug.cgi?id=153254
1351         -and corresponding-
1352         rdar://problem/24216292
1353
1354         Reviewed by Tim Horton.
1355
1356         * WebCoreSupport/WebEditorClient.mm:
1357         (WebEditorClient::handleRequestedCandidates):
1358         * WebView/WebView.mm:
1359         (-[WebView updateWebViewAdditions]):
1360         (-[WebView showCandidates:forString:inRect:view:completionHandler:]):
1361         * WebView/WebViewInternal.h:
1362
1363 2016-01-19  Enrica Casucci  <enrica@apple.com>
1364
1365         Add support for DataDetectors in WK (iOS).
1366         https://bugs.webkit.org/show_bug.cgi?id=152989
1367         rdar://problem/22855960
1368
1369         Reviewed by Tim Horton.
1370
1371         Adding feature definition for data detection.
1372
1373         * Configurations/FeatureDefines.xcconfig:
1374
1375 2016-01-19  Commit Queue  <commit-queue@webkit.org>
1376
1377         Unreviewed, rolling out r195300.
1378         https://bugs.webkit.org/show_bug.cgi?id=153244
1379
1380         enrica wants more time to fix Windows (Requested by thorton on
1381         #webkit).
1382
1383         Reverted changeset:
1384
1385         "Add support for DataDetectors in WK (iOS)."
1386         https://bugs.webkit.org/show_bug.cgi?id=152989
1387         http://trac.webkit.org/changeset/195300
1388
1389 2016-01-19  Enrica Casucci  <enrica@apple.com>
1390
1391         Add support for DataDetectors in WK (iOS).
1392         https://bugs.webkit.org/show_bug.cgi?id=152989
1393         rdar://problem/22855960
1394
1395         Reviewed by Tim Horton.
1396
1397         Adding feature definition for data detection.
1398
1399         * Configurations/FeatureDefines.xcconfig:
1400
1401 2016-01-16  Myles C. Maxfield  <mmaxfield@apple.com>
1402
1403         Remove TextRun::allowsRoundingHacks()
1404         https://bugs.webkit.org/show_bug.cgi?id=153185
1405
1406         Reviewed by Simon Fraser.
1407
1408         * Misc/WebKitNSStringExtras.mm:
1409         (-[NSString _web_drawAtPoint:font:textColor:allowingFontSmoothing:]): Deleted.
1410         (-[NSString _web_widthWithFont:]): Deleted.
1411         * WebView/WebView.mm:
1412         (+[WebView _setAllowsRoundingHacks:]): Deleted.
1413         (+[WebView _allowsRoundingHacks]): Deleted.
1414         * WebView/WebViewPrivate.h:
1415
1416 2016-01-15  Tim Horton  <timothy_horton@apple.com>
1417
1418         Data detector yellow highlight location is vertically mirrored in WebKit1
1419         https://bugs.webkit.org/show_bug.cgi?id=152216
1420         <rdar://problem/23848003>
1421
1422         Reviewed by Beth Dakin.
1423
1424         * WebView/WebImmediateActionController.mm:
1425         (-[WebImmediateActionController _animationControllerForDataDetectedText]):
1426         (-[WebImmediateActionController _animationControllerForDataDetectedLink]):
1427         These assignments have no effect because they're operating on a copy, because
1428         TextIndicator::data() does not return a reference... so remove them.
1429
1430         * WebView/WebView.mm:
1431         (-[WebView _setTextIndicator:withLifetime:]):
1432         Convert textBoundingRectInRootViewCoordinates to WebView coordinates before
1433         converting to Window coordinates from WebView coordinates so we get flipping right.
1434
1435         (-[WebView _animationControllerForDictionaryLookupPopupInfo:]):
1436         (-[WebView _showDictionaryLookupPopup:]):
1437         Ditto for these, except in the aforementioned conversion callback.
1438
1439 2016-01-14  Brady Eidson  <beidson@apple.com>
1440
1441         Modern IDB: Support opening and deleting SQLite databases on disk.
1442         https://bugs.webkit.org/show_bug.cgi?id=153084
1443
1444         Reviewed by Alex Christensen, Sam Weinig and Andy Estes (oh my!).
1445
1446         * Storage/WebDatabaseProvider.mm: Copied from Source/WebKit/Storage/WebDatabaseProvider.cpp.
1447         (WebDatabaseProvider::indexedDatabaseDirectoryPath):
1448
1449 2016-01-14  Beth Dakin  <bdakin@apple.com>
1450
1451         WK1 and WK2 should share more candidate request code
1452         https://bugs.webkit.org/show_bug.cgi?id=153108
1453
1454         Reviewed by Simon Fraser.
1455
1456         requestCandidatesForSelection() does not need to be exposed as an 
1457         EditorClient function. WK1 can just call invoke this code from the existing 
1458         respondToChangedSelection EditorClient function, which is what WK2 does.
1459         * WebCoreSupport/WebEditorClient.h:
1460         * WebCoreSupport/WebEditorClient.mm:
1461         (WebEditorClient::respondToChangedSelection):
1462
1463         Cleanup — use some code that was moved to WebCore::Editor.
1464         (WebEditorClient::requestCandidatesForSelection):
1465         (WebEditorClient::handleRequestedCandidates):
1466         (textCheckingResultFromNSTextCheckingResult):
1467         (WebEditorClient::handleAcceptedCandidate):
1468         (candidateRangeForSelection): Deleted.
1469         (candidateWouldReplaceText): Deleted.
1470
1471 2016-01-13  Chris Dumez  <cdumez@apple.com>
1472
1473         Unreviewed, rolling out r194900.
1474
1475         Roll back in as this did not actually regress PLT
1476
1477         Reverted changeset:
1478
1479         "Unreviewed, rolling out r194826."
1480         https://bugs.webkit.org/show_bug.cgi?id=153020
1481         http://trac.webkit.org/changeset/194900
1482
1483 2016-01-12  Ryosuke Niwa  <rniwa@webkit.org>
1484
1485         Add a build flag for custom element
1486         https://bugs.webkit.org/show_bug.cgi?id=153005
1487
1488         Reviewed by Alex Christensen.
1489
1490         * Configurations/FeatureDefines.xcconfig:
1491
1492 2016-01-12  Commit Queue  <commit-queue@webkit.org>
1493
1494         Unreviewed, rolling out r194826.
1495         https://bugs.webkit.org/show_bug.cgi?id=153020
1496
1497         Appears to have regressed PLT (Requested by kling on #webkit).
1498
1499         Reverted changeset:
1500
1501         "Use NeverDestroyed instead of DEPRECATED_DEFINE_STATIC_LOCAL
1502         cont'd"
1503         https://bugs.webkit.org/show_bug.cgi?id=152902
1504         http://trac.webkit.org/changeset/194826
1505
1506 2016-01-11  Anders Carlsson  <andersca@apple.com>
1507
1508         Get rid of CFMakeCollectable, it is a no-op
1509         https://bugs.webkit.org/show_bug.cgi?id=152988
1510
1511         Reviewed by Sam Weinig.
1512
1513         * Misc/WebNSDataExtras.m:
1514         (-[NSString _web_capitalizeRFC822HeaderFieldName]):
1515         (-[NSData _webkit_parseRFC822HeaderFields]):
1516         * Plugins/WebPluginController.mm:
1517         (-[WebPluginController initWithDocumentView:]):
1518
1519 2016-01-10  Andreas Kling  <akling@apple.com>
1520
1521         Use NeverDestroyed instead of DEPRECATED_DEFINE_STATIC_LOCAL cont'd
1522         <https://webkit.org/b/152902>
1523
1524         Reviewed by Andy Estes.
1525
1526         Convert some more of the remaining clients to use NeverDestroyed.
1527
1528         * History/WebBackForwardList.mm:
1529         (backForwardLists):
1530         * History/WebHistoryItem.mm:
1531         (historyItemWrappers):
1532         * Misc/WebNSPasteboardExtras.mm:
1533         (+[NSPasteboard _web_writableTypesForURL]):
1534         (_writableTypesForImageWithoutArchive):
1535         (_writableTypesForImageWithArchive):
1536         * Plugins/Hosted/NetscapePluginHostManager.mm:
1537         (WebKit::NetscapePluginHostManager::singleton):
1538         * Plugins/Hosted/NetscapePluginHostProxy.mm:
1539         (WebKit::pluginProxyMap):
1540         * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
1541         (WebKit::globalExceptionString):
1542         * Plugins/Hosted/ProxyInstance.mm:
1543         (WebKit::proxyClass):
1544         * Plugins/WebNetscapePluginStream.mm:
1545         (streams):
1546         * Storage/WebDatabaseManager.mm:
1547         (transactionBackgroundTaskIdentifierLock):
1548         * WebCoreSupport/WebUserMediaClient.mm:
1549         (userMediaCheckMap):
1550         * WebView/WebHTMLRepresentation.mm:
1551         (regExpForLabels):
1552         * WebView/WebView.mm:
1553         (aeDescFromJSValue):
1554
1555 2016-01-09  Dan Bernstein  <mitz@apple.com>
1556
1557         [Cocoa] Allow overriding the frameworks directory independently of using a staging install path
1558         https://bugs.webkit.org/show_bug.cgi?id=152926
1559
1560         Reviewed by Tim Horton.
1561
1562         Introduce a new build setting, WK_OVERRIDE_FRAMEWORKS_DIR. When not empty, it determines
1563         where the frameworks are installed. Setting USE_STAGING_INSTALL_PATH to YES sets
1564         WK_OVERRIDE_FRAMEWORKS_DIR to $(SYSTEM_LIBRARY_DIR)/StagedFrameworks/Safari.
1565
1566         Account for the possibility of WK_OVERRIDE_FRAMEWORKS_DIR containing spaces.
1567
1568         * Configurations/WebKitLegacy.xcconfig:
1569         - Replace STAGED_FRAMEWORKS_SEARCH_PATH in FRAMEWORK_SEARCH_PATHS with
1570           WK_OVERRIDE_FRAMEWORKS_DIR and add quotes to account for spaces.
1571         - Define WEBKIT_LEGACY_FRAMEWORKS_DIR, PRODUCTION_FRAMEWORKS_DIR, and
1572           WEBCORE_PRIVATE_HEADERS_DIR based on WK_OVERRIDE_FRAMEWORKS_DIR.
1573
1574         * MigrateHeaders.make:
1575           Use a symlink under BUILT_PRODUCTS_DIR to the WebCore Private Headers. Use a
1576           BUILT_PRODUCTS_DIR-based path to the framework instead of a TARGET_BUILD_DIR-based one in
1577           order to avoid spaces.
1578         * migrate-headers.sh:
1579           Make the symlink to WEBCORE_PRIVATE_HEADERS_DIR that the makefile now uses.
1580
1581 2016-01-07  Tim Horton  <timothy_horton@apple.com>
1582
1583         Can't play inline video in a stock WK1 WebView on Mac
1584         https://bugs.webkit.org/show_bug.cgi?id=152860
1585
1586         Rubber-stamped by Jer Noble.
1587
1588         * WebView/WebPreferences.mm:
1589         (+[WebPreferences initialize]):
1590         The default for this preference is supposed to be NO on Mac. It is in
1591         Settings.in, and in WebKit2, but this one place got it wrong.
1592
1593 2016-01-06  Simon Fraser  <simon.fraser@apple.com>
1594
1595         Add a setting and preferences to enable display-list drawing. Does nothing yet.
1596         https://bugs.webkit.org/show_bug.cgi?id=152807
1597
1598         Reviewed by Zalan Bujtas.
1599         
1600         WK1 pref for display-list drawing, defaults to off.
1601
1602         * WebView/WebPreferenceKeysPrivate.h:
1603         * WebView/WebPreferences.mm:
1604         (+[WebPreferences initialize]):
1605         (-[WebPreferences displayListDrawingEnabled]):
1606         (-[WebPreferences setDisplayListDrawingEnabled:]):
1607         * WebView/WebPreferencesPrivate.h:
1608         * WebView/WebView.mm:
1609         (-[WebView initSimpleHTMLDocumentWithStyle:frame:preferences:groupName:]):
1610         (-[WebView _preferencesChanged:]):
1611
1612 2016-01-06  Simon Fraser  <simon.fraser@apple.com>
1613
1614         [iOS] Revert overflow:hidden on the body affecting viewport scale (r186786)
1615         https://bugs.webkit.org/show_bug.cgi?id=152803
1616         rdar://problem/22242515
1617
1618         Reviewed by Tim Horton.
1619
1620         * WebView/WebView.mm:
1621         (-[WebView _contentsSizeRespectingOverflow]): Keep this function which is used
1622         by UIKit, but change the implementation to just return the document size.
1623
1624 2016-01-04  Tim Horton  <timothy_horton@apple.com>
1625
1626         Turn on gesture events when building for Yosemite
1627         https://bugs.webkit.org/show_bug.cgi?id=152704
1628         rdar://problem/24042472
1629
1630         Reviewed by Anders Carlsson.
1631
1632         * Configurations/FeatureDefines.xcconfig:
1633
1634 2015-12-31  Andy Estes  <aestes@apple.com>
1635
1636         Replace WTF::move with WTFMove
1637         https://bugs.webkit.org/show_bug.cgi?id=152601
1638
1639         Reviewed by Brady Eidson.
1640
1641         * History/WebHistoryItem.mm:
1642         (-[WebHistoryItem initFromDictionaryRepresentation:]):
1643         * Plugins/Hosted/HostedNetscapePluginStream.mm:
1644         (WebKit::HostedNetscapePluginStream::willSendRequest):
1645         * Plugins/Hosted/NetscapePluginInstanceProxy.h:
1646         (WebKit::NetscapePluginInstanceProxy::setCurrentReply):
1647         * Plugins/WebNetscapePluginStream.mm:
1648         (WebNetscapePluginStream::willSendRequest):
1649         * Plugins/WebNetscapePluginView.mm:
1650         (-[WebNetscapePluginView scheduleTimerWithInterval:repeat:timerFunc:]):
1651         * WebCoreSupport/WebContextMenuClient.mm:
1652         (WebContextMenuClient::imageForCurrentSharingServicePickerItem):
1653         * WebCoreSupport/WebFrameLoaderClient.mm:
1654         (WebFrameLoaderClient::dispatchDecidePolicyForResponse):
1655         (WebFrameLoaderClient::dispatchDecidePolicyForNewWindowAction):
1656         (WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
1657         (WebFrameLoaderClient::dispatchWillSubmitForm):
1658         (WebFrameLoaderClient::createDocumentLoader):
1659         * WebCoreSupport/WebInspectorClient.mm:
1660         (WebInspectorFrontendClient::WebInspectorFrontendClient):
1661         * WebView/WebArchive.mm:
1662         (-[WebArchive initWithMainResource:subresources:subframeArchives:]):
1663         * WebView/WebFrame.mm:
1664         (-[WebFrame _documentFragmentWithNodesAsParagraphs:]):
1665         * WebView/WebHTMLView.mm:
1666         (-[WebHTMLView _applyEditingStyleToSelection:withUndoAction:]):
1667         * WebView/WebMediaPlaybackTargetPicker.mm:
1668         (WebMediaPlaybackTargetPicker::setPlaybackTarget):
1669         * WebView/WebView.mm:
1670         (-[WebView _loadBackForwardListFromOtherView:]):
1671         (+[WebView _addUserScriptToGroup:world:source:url:whitelist:blacklist:injectionTime:injectedFrames:]):
1672         (+[WebView _addUserStyleSheetToGroup:world:source:url:whitelist:blacklist:injectedFrames:]):
1673
1674 2016-01-01  Simon Fraser  <simon.fraser@apple.com>
1675
1676         Fix the iOS and EFL builds, after an over-eager commit-queue commit.
1677
1678         * History/WebHistoryItem.mm:
1679         (-[WebHistoryItem initFromDictionaryRepresentation:]):
1680
1681 2016-01-01  Simon Fraser  <simon.fraser@apple.com>
1682
1683         Fix naming in HistoryItem to refer to scrollPositions
1684         https://bugs.webkit.org/show_bug.cgi?id=152646
1685
1686         Reviewed by Zalan Bujtas.
1687
1688         HistoryItem stores a scrollPosition, so call it that.
1689
1690         * History/WebHistoryItem.mm:
1691         (-[WebHistoryItem scrollPoint]):
1692
1693 2016-01-01  Jeff Miller  <jeffm@apple.com>
1694
1695         Update user-visible copyright strings to include 2016
1696         https://bugs.webkit.org/show_bug.cgi?id=152531
1697
1698         Reviewed by Alexey Proskuryakov.
1699
1700         * Info.plist:
1701
1702 2015-12-31  David Kilzer  <ddkilzer@apple.com>
1703
1704         Stop using USE(CFNETWORK) path on iOS
1705         https://bugs.webkit.org/show_bug.cgi?id=142540
1706
1707         Step 1/2: Do everything but turn off USE(CFNETWORK) internally.
1708
1709         Original patch by Antti Koivisto <antti@apple.com> on 2015-03-10
1710         Reviewed by Daniel Bates.
1711
1712         * Misc/WebDownload.h: Add header guard to make
1713         NSURLDownloadSPI.h work when pre-declaring NSURLDownload object.
1714         * Misc/WebKitVersionChecks.h: Define
1715         WEBKIT_FIRST_VERSION_WITH_LOADING_DURING_COMMON_RUNLOOP_MODES
1716         for iOS.
1717         * WebView/WebView.mm:
1718         (-[WebView _commonInitializationWithFrameName:groupName:]): Use
1719         the correct runloop on iOS.
1720         * WebView/WebViewPrivate.h:
1721         (-[WebView(WebPendingPublic) scheduleInRunLoop:forMode:]):
1722         (-[WebView(WebPendingPublic) unscheduleFromRunLoop:forMode:]):
1723         - These are available on iOS now.
1724
1725 2015-12-31  Simon Fraser  <simon.fraser@apple.com>
1726
1727         Clarify that scrollPositionChangedViaPlatformWidget takes offsets
1728         https://bugs.webkit.org/show_bug.cgi?id=152606
1729
1730         Reviewed by Zalan Bujtas.
1731
1732         scrollPositionChangedViaPlatformWidget actually gets scroll offsets, since the
1733         values we get from AppKit are zero-based, so rename to scrollOffsetChangedViaPlatformWidget().
1734         
1735         Change ScrollableArea's setScrollPosition() and requestScrollPositionUpdate() to take
1736         ScrollPositions.
1737         
1738         Add a FIXME noting that willRevealEdge events are probably broken in RTL documents.
1739
1740         * WebView/WebHTMLView.mm:
1741         (-[WebHTMLView _frameOrBoundsChanged]):
1742
1743 2015-12-22  Andy Estes  <aestes@apple.com>
1744
1745         [CF] Replace CFNetwork-related WebKitSystemInterface calls with SPI
1746         https://bugs.webkit.org/show_bug.cgi?id=152463
1747
1748         Reviewed by Alexey Proskuryakov.
1749
1750         Replaced WebkitSystemInterface calls that wrapped CFNetwork SPI with direct calls to SPI that is now forward
1751         declared in CFNetworkSPI.h.
1752
1753         * Plugins/Hosted/HostedNetscapePluginStream.mm:
1754         (WebKit::HostedNetscapePluginStream::didReceiveResponse):
1755         * Plugins/WebNetscapePluginStream.mm:
1756         (WebNetscapePluginStream::didReceiveResponse):
1757         * WebCoreSupport/WebSystemInterface.mm:
1758         (InitWebCoreSystemInterface): Deleted.
1759         * WebView/WebPreferences.mm:
1760         (+[WebPreferences _setCurrentNetworkLoaderSessionCookieAcceptPolicy:]):
1761
1762 2015-12-20  Dan Bernstein  <mitz@apple.com>
1763
1764         Remove unused setToolbarHeight
1765         https://bugs.webkit.org/show_bug.cgi?id=152466
1766
1767         Reviewed by Darin Adler.
1768
1769         * WebCoreSupport/WebInspectorClient.h:
1770         * WebCoreSupport/WebInspectorClient.mm::
1771         (WebInspectorFrontendClient::setToolbarHeight): Deleted.
1772
1773 2015-12-19  Dan Bernstein  <mitz@apple.com>
1774
1775         [Mac] WebKit contains dead source code for OS X Mavericks and earlier
1776         https://bugs.webkit.org/show_bug.cgi?id=152462
1777
1778         Reviewed by Alexey Proskuryakov.
1779
1780         - Removed build setting definitions for OS X 10.9 and earlier, and simplified defintions
1781           that became uniform across all OS X versions as a result:
1782
1783         * Configurations/DebugRelease.xcconfig:
1784         * Configurations/FeatureDefines.xcconfig:
1785         * Configurations/Version.xcconfig:
1786         * Configurations/WebKitLegacy.xcconfig:
1787
1788         - Simplified expressions involving __MAC_OS_X_VERSION_MIN_REQUIRED and removed code that was
1789           never getting compiled:
1790
1791         * WebCoreSupport/WebInspectorClient.mm:
1792         * WebView/WebDynamicScrollBarsView.mm:
1793         * WebView/WebHTMLView.mm:
1794         * WebView/WebImmediateActionController.h:
1795         * WebView/WebImmediateActionController.mm:
1796         * WebView/WebView.mm:
1797         * WebView/WebViewData.h:
1798         * WebView/WebViewData.mm:
1799         * WebView/WebViewInternal.h:
1800
1801 2015-12-17  Tim Horton  <timothy_horton@apple.com>
1802
1803         Data detector yellow highlight location is vertically mirrored in WebKit1
1804         https://bugs.webkit.org/show_bug.cgi?id=152216
1805         <rdar://problem/23848003>
1806
1807         Reviewed by Darin Adler.
1808
1809         * WebView/WebImmediateActionController.mm:
1810         (-[WebImmediateActionController _animationControllerForDataDetectedText]):
1811         Match the conversion we do at every other WK1 TextIndicator construction.
1812
1813 2015-12-16  Youenn Fablet  <youenn.fablet@crf.canon.fr>
1814
1815         [Fetch API] Add fetch API compile time flag
1816         https://bugs.webkit.org/show_bug.cgi?id=152254
1817
1818         Reviewed by Darin Adler.
1819
1820         * Configurations/FeatureDefines.xcconfig:
1821
1822 2015-12-13  Tim Horton  <timothy_horton@apple.com>
1823
1824         Adopt CGIOSurfaceContextCreateImageReference to avoid unnecessary readback
1825         https://bugs.webkit.org/show_bug.cgi?id=150988
1826         <rdar://problem/18993594>
1827
1828         Reviewed by Darin Adler.
1829
1830         * WebCoreSupport/WebContextMenuClient.mm:
1831         (WebContextMenuClient::imageForCurrentSharingServicePickerItem):
1832         Adopt sinkIntoImage and drawConsumingImageBuffer in a few places.
1833
1834 2015-12-11  Eric Carlson  <eric.carlson@apple.com>
1835
1836         [MediaStream] Add a setting to allow the mock media capture devices to be enabled and disabled
1837         https://bugs.webkit.org/show_bug.cgi?id=152197
1838
1839         Reviewed by Dean Jackson.
1840
1841         * WebView/WebPreferenceKeysPrivate.h:
1842         * WebView/WebPreferences.mm:
1843         (+[WebPreferences initialize]):
1844         (-[WebPreferences mockCaptureDevicesEnabled]):
1845         (-[WebPreferences setMockCaptureDevicesEnabled:]):
1846         * WebView/WebPreferencesPrivate.h:
1847         * WebView/WebView.mm:
1848         (-[WebView _preferencesChanged:]):
1849
1850 2015-12-11  Beth Dakin  <bdakin@apple.com>
1851
1852         _touchEventRegions should return regions in the view's coordinates
1853         https://bugs.webkit.org/show_bug.cgi?id=152189
1854         -and corresponding-
1855         rdar://problem/23188605
1856
1857         Reviewed by Dan Bernstein.
1858
1859         The comment here was actually out of date. It claimed that touch rectangles 
1860         are in the coordinate system of the document, but we had actually changed 
1861         them to be in the view’s coordinate system in order to fix issues with 
1862         handling touch events in UIWebView. But now we are going back to having the 
1863         touch rectangles be in the document’s coordinate system, so we should fix the 
1864         rtl bugs here by converting to view coordinates before handing the rects off 
1865         to iOS WK1 clients.
1866         * WebView/WebView.mm:
1867         (-[WebView _touchEventRegions]):
1868
1869 2015-12-10  Eric Carlson  <eric.carlson@apple.com>
1870
1871         [MediaStream] Expose media capture devices persistent permissions to WebCore
1872         https://bugs.webkit.org/show_bug.cgi?id=152087
1873
1874         Reviewed by Chris Dumez.
1875
1876         Add methods and helpers for WK1 permission checker interface.
1877         * WebCoreSupport/WebUserMediaClient.h:
1878         * WebCoreSupport/WebUserMediaClient.mm:
1879         (userMediaRequestsMap):
1880         (AddRequestToRequestMap):
1881         (RemoveRequestFromRequestMap):
1882         (userMediaCheckMap):
1883         (AddPermissionCheckToMap):
1884         (RemovePermissionCheckFromMap):
1885         (WebUserMediaClient::WebUserMediaClient):
1886         (WebUserMediaClient::requestUserMediaAccess):
1887         (WebUserMediaClient::cancelUserMediaAccessRequest):
1888         (WebUserMediaClient::checkUserMediaPermission):
1889         (WebUserMediaClient::cancelUserMediaPermissionCheck):
1890         (-[WebUserMediaPolicyListener allow]):
1891         (-[WebUserMediaPolicyListener deny]):
1892         (-[WebUserMediaPolicyCheckerListener initWithUserMediaPermissionCheck:]):
1893         (-[WebUserMediaPolicyCheckerListener cancelUserMediaPermissionCheck]):
1894         (-[WebUserMediaPolicyCheckerListener allow]):
1895         (-[WebUserMediaPolicyCheckerListener deny]):
1896         (-[WebUserMediaPolicyCheckerListener denyOnlyThisRequest]):
1897         (-[WebUserMediaPolicyCheckerListener shouldClearCache]):
1898         (AddRequestToMap): Deleted.
1899         (RemoveRequestFromMap): Deleted.
1900         * WebView/WebUIDelegatePrivate.h:
1901
1902 2015-12-08  Beth Dakin  <bdakin@apple.com>
1903
1904         Follow-up to:
1905         Add support for WebViewAdditions
1906         https://bugs.webkit.org/show_bug.cgi?id=151967
1907
1908         Rubber-stamped by Dan Bernstein.
1909
1910         We should use the Web prefix for all category names.
1911         * WebView/WebView.mm:
1912         (-[WebView updateWebViewAdditions]):
1913         * WebView/WebViewInternal.h:
1914
1915 2015-12-08  Eric Carlson  <eric.carlson@apple.com>
1916
1917         [MediaStream] Rename UserMediaClient and UserMediaController methods
1918         https://bugs.webkit.org/show_bug.cgi?id=152001
1919
1920         Reviewed by Brady Eidson.
1921
1922         * WebCoreSupport/WebUserMediaClient.h:
1923         * WebCoreSupport/WebUserMediaClient.mm:
1924         (WebUserMediaClient::pageDestroyed):
1925         (WebUserMediaClient::requestUserMediaAccess):
1926         (WebUserMediaClient::cancelUserMediaAccessRequest):
1927         (-[WebUserMediaPolicyListener initWithUserMediaRequest:]):
1928         (-[WebUserMediaPolicyListener cancelUserMediaAccessRequest]):
1929         (WebUserMediaClient::requestPermission): Deleted.
1930         (WebUserMediaClient::cancelRequest): Deleted.
1931         (-[WebUserMediaPolicyListener cancelRequest]): Deleted.
1932
1933 2015-12-07  Alex Christensen  <achristensen@webkit.org>
1934
1935         Build fix after r193675.
1936
1937         * WebView/WebViewData.h:
1938
1939 2015-12-07  Alex Christensen  <achristensen@webkit.org>
1940
1941         Build fix after r193661.
1942
1943         Reviewed by Beth Dakin.
1944
1945         * WebView/WebViewData.h:
1946
1947 2015-12-07  Beth Dakin  <bdakin@apple.com>
1948
1949         Add support for WebViewAdditions
1950         https://bugs.webkit.org/show_bug.cgi?id=151967
1951
1952         Reviewed by Sam Weinig.
1953
1954         * WebCoreSupport/WebEditorClient.mm:
1955         (WebEditorClient::respondToChangedSelection):
1956         * WebView/WebView.mm:
1957         (-[WebView _commonInitializationWithFrameName:groupName:]):
1958         (-[WebView updateWebViewAdditions]):
1959         * WebView/WebViewData.h:
1960         * WebView/WebViewInternal.h:
1961
1962 2015-12-07  Beth Dakin  <bdakin@apple.com>
1963
1964         Hook up request and show for typing candidates in WK1
1965         https://bugs.webkit.org/show_bug.cgi?id=151831
1966         -and corresponding-
1967         <rdar://problem/23751214>
1968
1969         Reviewed by Enrica Casucci.
1970
1971         Add member variables to WebEditorClient. One is a WeakPtrFactory for the 
1972         asynchronous handlers, and the other caches the VisibleSelection at the time 
1973         candidates were requested so that we can make sure the candidates are still 
1974         valid once we receive them.
1975         * WebCoreSupport/WebEditorClient.h:
1976         * WebCoreSupport/WebEditorClient.mm:
1977         (WebEditorClient::WebEditorClient):
1978
1979         Call [NSSpellChecker requestCandidatesForSelectedRange] with the appropriate 
1980         parameters.
1981         (WebEditorClient::requestCandidatesForSelection):
1982
1983         Two helpers to compute information that we need for both of the handlers 
1984         below.
1985         (candidateRangeForSelection):
1986         (candidateWouldReplaceText):
1987
1988         In this handler, we just need to call [NSSpellChecker showCandidates] with 
1989         the appropriate parameters.
1990         (WebEditorClient::handleRequestedCandidates):
1991
1992         Once a candidate is accepted, it should be inserted in the right way.
1993         (WebEditorClient::handleAcceptedCandidate):
1994
1995 2015-12-03  Jer Noble  <jer.noble@apple.com>
1996
1997         Expose WebCore's InvisibleAutoplayNotPermitted setting to WebKit & WebKit2
1998         https://bugs.webkit.org/show_bug.cgi?id=151830
1999
2000         Reviewed by Anders Carlsson.
2001
2002         Add a new WebPreferences property invisibleAutoplayNotPermitted.
2003
2004         * WebView/WebPreferenceKeysPrivate.h:
2005         * WebView/WebPreferences.mm:
2006         (-[WebPreferences invisibleAutoplayNotPermitted]):
2007         (-[WebPreferences setInvisibleAutoplayNotPermitted:]):
2008         * WebView/WebPreferencesPrivate.h:
2009         * WebView/WebView.mm:
2010         (-[WebView _preferencesChanged:]):
2011
2012 2015-12-03  Anders Carlsson  <andersca@apple.com>
2013
2014         Remove Objective-C GC support
2015         https://bugs.webkit.org/show_bug.cgi?id=151819
2016         rdar://problem/23746991
2017
2018         Reviewed by Dan Bernstein.
2019
2020         * Carbon/CarbonWindowAdapter.mm:
2021         (+[CarbonWindowAdapter initialize]): Deleted.
2022         (-[CarbonWindowAdapter finalize]): Deleted.
2023         * Configurations/Base.xcconfig:
2024         * History/WebBackForwardList.mm:
2025         (+[WebBackForwardList initialize]): Deleted.
2026         (-[WebBackForwardList finalize]): Deleted.
2027         * History/WebHistory.mm:
2028         (-[WebHistoryPrivate finalize]): Deleted.
2029         (-[WebHistory finalize]): Deleted.
2030         * History/WebHistoryItem.mm:
2031         (+[WebHistoryItem initialize]): Deleted.
2032         (-[WebHistoryItem finalize]): Deleted.
2033         * Misc/WebElementDictionary.mm:
2034         (+[WebElementDictionary initialize]): Deleted.
2035         (-[WebElementDictionary finalize]): Deleted.
2036         * Plugins/Hosted/WebHostedNetscapePluginView.mm:
2037         (+[WebHostedNetscapePluginView initialize]): Deleted.
2038         * Plugins/WebBaseNetscapePluginView.mm:
2039         (-[WebBaseNetscapePluginView finalize]): Deleted.
2040         * Plugins/WebBasePluginPackage.mm:
2041         (-[WebBasePluginPackage finalize]): Deleted.
2042         * Plugins/WebNetscapePluginView.mm:
2043         (+[WebNetscapePluginView initialize]): Deleted.
2044         (-[WebNetscapePluginView finalize]): Deleted.
2045         * Plugins/WebPluginContainerCheck.mm:
2046         (-[WebPluginContainerCheck finalize]): Deleted.
2047         * WebCoreSupport/WebEditorClient.mm:
2048         (+[WebUndoStep initialize]): Deleted.
2049         (-[WebUndoStep finalize]): Deleted.
2050         * WebCoreSupport/WebFrameLoaderClient.mm:
2051         * WebCoreSupport/WebOpenPanelResultListener.mm:
2052         (-[WebOpenPanelResultListener finalize]): Deleted.
2053         * WebCoreSupport/WebSecurityOrigin.mm:
2054         (-[WebSecurityOrigin finalize]): Deleted.
2055         * WebView/WebArchive.mm:
2056         (+[WebArchivePrivate initialize]): Deleted.
2057         * WebView/WebDataSource.mm:
2058         (+[WebDataSource initialize]): Deleted.
2059         (-[WebDataSource finalize]): Deleted.
2060         * WebView/WebDynamicScrollBarsView.mm:
2061         (-[WebDynamicScrollBarsView finalize]): Deleted.
2062         * WebView/WebFrame.mm:
2063         (-[WebFramePrivate setWebFrameView:]):
2064         (-[WebFramePrivate finalize]): Deleted.
2065         (-[WebFrame finalize]): Deleted.
2066         * WebView/WebFrameView.mm:
2067         (-[WebFrameView finalize]): Deleted.
2068         * WebView/WebHTMLRepresentation.mm:
2069         (-[WebHTMLRepresentation finalize]): Deleted.
2070         * WebView/WebHTMLView.mm:
2071         (+[WebHTMLViewPrivate initialize]):
2072         (-[WebHTMLViewPrivate finalize]): Deleted.
2073         (+[WebHTMLView initialize]): Deleted.
2074         (-[WebHTMLView finalize]): Deleted.
2075         * WebView/WebResource.mm:
2076         (+[WebResourcePrivate initialize]): Deleted.
2077         (-[WebResourcePrivate finalize]): Deleted.
2078         * WebView/WebTextIterator.mm:
2079         (+[WebTextIteratorPrivate initialize]): Deleted.
2080         * WebView/WebView.mm:
2081         (-[WebView finalize]): Deleted.
2082         * WebView/WebViewData.mm:
2083         (+[WebViewPrivate initialize]): Deleted.
2084         (-[WebViewPrivate init]): Deleted.
2085         (-[WebViewPrivate finalize]): Deleted.
2086
2087 2015-12-02  Antti Koivisto  <antti@apple.com>
2088
2089         Move ResourceLoadScheduler to WebKit1
2090         https://bugs.webkit.org/show_bug.cgi?id=151743
2091
2092         Reviewed by Alex Christensen.
2093
2094         * Plugins/Hosted/HostedNetscapePluginStream.mm:
2095         (WebKit::HostedNetscapePluginStream::start):
2096         (WebKit::HostedNetscapePluginStream::stop):
2097         * Plugins/WebNetscapePluginStream.mm:
2098         (WebNetscapePluginStream::start):
2099         (WebNetscapePluginStream::stop):
2100         * WebCoreSupport/WebPlatformStrategies.h:
2101         * WebCoreSupport/WebPlatformStrategies.mm:
2102         (WebPlatformStrategies::createLoaderStrategy):
2103         (WebPlatformStrategies::createPasteboardStrategy):
2104         (WebPlatformStrategies::createPluginStrategy):
2105         (WebPlatformStrategies::createBlobRegistry):
2106         (WebPlatformStrategies::cookiesForDOM):
2107         * WebView/WebView.mm:
2108         (-[WebView _dispatchPendingLoadRequests]):
2109         (+[WebView _setLoadResourcesSerially:]):
2110         (+[WebView _HTTPPipeliningEnabled]):
2111
2112 2015-12-01  Yusuke Suzuki  <utatane.tea@gmail.com>
2113
2114         [ES6] Implement LLInt/Baseline Support for ES6 Generators and enable this feature
2115         https://bugs.webkit.org/show_bug.cgi?id=150792
2116
2117         Reviewed by Saam Barati.
2118
2119         * Configurations/FeatureDefines.xcconfig:
2120
2121 2015-12-01  Commit Queue  <commit-queue@webkit.org>
2122
2123         Unreviewed, rolling out r192914.
2124         https://bugs.webkit.org/show_bug.cgi?id=151734
2125
2126         JSC tests for this change are failing on 32 and 64-bit bots
2127         (Requested by ryanhaddad on #webkit).
2128
2129         Reverted changeset:
2130
2131         "[ES6] Implement LLInt/Baseline Support for ES6 Generators and
2132         enable this feature"
2133         https://bugs.webkit.org/show_bug.cgi?id=150792
2134         http://trac.webkit.org/changeset/192914
2135
2136 2015-12-01  Yusuke Suzuki  <utatane.tea@gmail.com>
2137
2138         [ES6] Implement LLInt/Baseline Support for ES6 Generators and enable this feature
2139         https://bugs.webkit.org/show_bug.cgi?id=150792
2140
2141         Reviewed by Saam Barati.
2142
2143         * Configurations/FeatureDefines.xcconfig:
2144
2145 2015-11-30  Katlyn Graff  <kgraff@apple.com>
2146
2147         Rename ActiveDOMObject/DOMWindow PageCacheSuspension code to support more reasons for suspension
2148         https://bugs.webkit.org/show_bug.cgi?id=151677
2149
2150         Reviewed by Ryosuke Niwa.
2151
2152         * WebView/WebFrame.mm:
2153         (-[WebFrame _cacheabilityDictionary]):
2154
2155 2015-11-30  Jiewen Tan  <jiewen_tan@apple.com>
2156
2157         Null dereference loading Blink layout test http/tests/misc/detach-during-notifyDone.html
2158         https://bugs.webkit.org/show_bug.cgi?id=149309
2159         <rdar://problem/22748363>
2160
2161         Reviewed by Brent Fulgham.
2162
2163         * WebView/WebDataSource.mm:
2164         (WebDataSourcePrivate::~WebDataSourcePrivate):
2165         Refine the assertion to treat <rdar://problem/9673866>.
2166
2167 == Rolled over to ChangeLog-2015-11-21 ==