LoadWebLocalizedStrings method should be moved in correct file
[WebKit-https.git] / Source / WebKit / mac / ChangeLog
1 2017-01-25  Aakash Jain  <aakash_jain@apple.com>
2
3         LoadWebLocalizedStrings method should be moved in correct file
4         https://bugs.webkit.org/show_bug.cgi?id=167393
5
6         Reviewed by Alexey Proskuryakov.
7
8         * Misc/WebLocalizableStrings.h: Deleted LoadWebLocalizedStrings method.
9         * Misc/WebLocalizableStrings.mm:
10         (LoadWebLocalizedStringsTimerCallback): Deleted, moved to WebUIKitSupport.mm
11         (LoadWebLocalizedStrings): Deleted, moved to WebUIKitSupport.mm
12
13 2017-01-24  Zalan Bujtas  <zalan@apple.com>
14
15         Add simple line layout toggle to MiniBrowser
16         https://bugs.webkit.org/show_bug.cgi?id=167405
17
18         Reviewed by Andreas Kling.
19
20         * WebView/WebPreferenceKeysPrivate.h:
21         * WebView/WebPreferences.mm:
22         (+[WebPreferences initialize]):
23         (-[WebPreferences simpleLineLayoutEnabled]):
24         (-[WebPreferences setSimpleLineLayoutEnabled:]):
25         * WebView/WebPreferencesPrivate.h:
26         * WebView/WebView.mm:
27         (-[WebView _preferencesChanged:]):
28
29 2017-01-24  Joseph Pecoraro  <pecoraro@apple.com>
30
31         Fold USER_TIMING into WEB_TIMING and make it a RuntimeEnabledFeature
32         https://bugs.webkit.org/show_bug.cgi?id=167394
33
34         Reviewed by Ryosuke Niwa.
35
36         * Configurations/FeatureDefines.xcconfig:
37
38 2017-01-23  Chris Dumez  <cdumez@apple.com>
39
40         REGRESSION (r211033): ASSERTION FAILED: m_ptr in com.apple.WebCore: WTF::RefPtr<WebCore::Element>::operator* const + 70
41         https://bugs.webkit.org/show_bug.cgi?id=167308
42         <rdar://problem/30144964>
43
44         Unreviewed, do a partial revert of r211033 to fix assertion.
45
46         * WebCoreSupport/WebChromeClient.h:
47         * WebCoreSupport/WebChromeClient.mm:
48         (WebChromeClient::exitFullScreenForElement):
49
50 2017-01-23  Joseph Pecoraro  <pecoraro@apple.com>
51
52         Remove allowWindowOpenWithoutUserGesture setting
53         https://bugs.webkit.org/show_bug.cgi?id=167301
54
55         Reviewed by Darin Adler.
56
57         * WebView/WebView.mm:
58         (-[WebView _preferencesChanged:]):
59         Use the equivalent existing setting.
60
61 2017-01-20  Darin Adler  <darin@apple.com>
62
63         Remove PassRefPtr from "page" directory of WebCore, also deploy references
64         https://bugs.webkit.org/show_bug.cgi?id=167224
65
66         Reviewed by Chris Dumez.
67
68         * WebCoreSupport/WebApplicationCacheQuotaManager.mm:
69         (-[WebApplicationCacheQuotaManager quota]): Pass reference.
70
71         * WebCoreSupport/WebChromeClient.h: Updated for changes to ChromeClient.
72         * WebCoreSupport/WebChromeClient.mm:
73         (WebChromeClient::focusedElementChanged): Ditto.
74         (WebChromeClient::createWindow): Ditto.
75         (WebChromeClient::runBeforeUnloadConfirmPanel): Ditto.
76         (WebChromeClient::runJavaScriptAlert): Ditto.
77         (WebChromeClient::runJavaScriptConfirm): Ditto.
78         (WebChromeClient::runJavaScriptPrompt): Ditto.
79         (WebChromeClient::contentsSizeChanged): Ditto.
80         (WebChromeClient::unavailablePluginButtonClicked): Ditto.
81         (WebChromeClient::print): Ditto.
82         (WebChromeClient::exceededDatabaseQuota): Ditto.
83         (WebChromeClient::reachedApplicationCacheOriginQuota): Ditto.
84         (WebChromeClient::createColorChooser): Ditto.
85         (WebChromeClient::elementDidFocus): Ditto.
86         (WebChromeClient::elementDidBlur): Ditto.
87         (WebChromeClient::createPopupMenu): Ditto.
88         (WebChromeClient::createSearchPopupMenu): Ditto.
89         (WebChromeClient::attachRootGraphicsLayer): Ditto.
90         (WebChromeClient::attachViewOverlayGraphicsLayer): Ditto.
91         (WebChromeClient::supportsFullScreenForElement): Ditto.
92         (WebChromeClient::enterFullScreenForElement): Ditto.
93         (WebChromeClient::exitFullScreenForElement): Ditto.
94
95         * WebView/WebFrame.mm:
96         (+[WebFrame _createFrameWithPage:frameName:frameView:ownerElement:]):
97         Updated for change to the appendChild function.
98
99 2017-01-21  Simon Fraser  <simon.fraser@apple.com>
100
101         Remove -[WebFrame sendOrientationChangeEvent:] which is unused
102         https://bugs.webkit.org/show_bug.cgi?id=167276
103
104         Reviewed by Alex Christensen.
105         
106         It was usurped by -deviceOrientationChanged in 2014.
107
108         * WebView/WebFrame.mm:
109         (-[WebFrame sendOrientationChangeEvent:]): Deleted.
110         * WebView/WebFramePrivate.h:
111
112 2017-01-21  Simon Fraser  <simon.fraser@apple.com>
113
114         Remove -[WebView _contentsSizeRespectingOverflow] which is no longer needed
115         https://bugs.webkit.org/show_bug.cgi?id=167271
116
117         Reviewed by Alex Christensen.
118         
119         -_contentsSizeRespectingOverflow was added to try to make viewport sizing on iOS respect
120         overflow:hidden on the body (webkit.org/b/146924) but that was reverted (webkit.org/b/152803),
121
122         * WebView/WebView.mm:
123         (-[WebView _contentsSizeRespectingOverflow]): Deleted.
124         * WebView/WebViewPrivate.h:
125
126 2017-01-20  Joseph Pecoraro  <pecoraro@apple.com>
127
128         Remove never changing IndexedDB RuntimeEnabledFeature
129         https://bugs.webkit.org/show_bug.cgi?id=167278
130
131         Reviewed by Darin Adler.
132
133         * WebView/WebView.mm:
134         (-[WebView _preferencesChanged:]):
135
136 2017-01-20  Joseph Pecoraro  <pecoraro@apple.com>
137
138         Cleanup RuntimeEnabledFeatures
139         https://bugs.webkit.org/show_bug.cgi?id=167228
140
141         Reviewed by Simon Fraser.
142
143         * WebView/WebView.mm:
144         (-[WebView _preferencesChanged:]):
145
146 2017-01-20  Joseph Pecoraro  <pecoraro@apple.com>
147
148         Remove outdated ENABLE(CSP_NEXT) build flag
149         https://bugs.webkit.org/show_bug.cgi?id=167252
150
151         Reviewed by Brent Fulgham.
152
153         * Configurations/FeatureDefines.xcconfig:
154
155 2017-01-20  Antoine Quint  <graouts@apple.com>
156
157         [Modern Media Controls] Turn modern media controls on by default
158         https://bugs.webkit.org/show_bug.cgi?id=165668
159
160         Reviewed by Dean Jackson.
161
162         Enabled modern media controls by default in WK1.
163
164         * WebView/WebPreferences.mm:
165         (+[WebPreferences initialize]):
166
167 2017-01-19  Chris Dumez  <cdumez@apple.com>
168
169         iterable<> should be enabled on WK1
170         https://bugs.webkit.org/show_bug.cgi?id=167221
171         <rdar://problem/30108531>
172
173         Reviewed by Youenn Fablet.
174
175         * WebView/WebPreferenceKeysPrivate.h:
176         * WebView/WebPreferences.mm:
177         (-[WebPreferences setCustomElementsEnabled:]):
178         (-[WebPreferences DOMIteratorEnabled]): Deleted.
179         (-[WebPreferences setDOMIteratorEnabled:]): Deleted.
180         * WebView/WebPreferencesPrivate.h:
181         * WebView/WebView.mm:
182         (-[WebView _preferencesChanged:]):
183
184 2017-01-19  Chris Dumez  <cdumez@apple.com>
185
186         Make sure HTML validation bubble gets dismissed when its associated element's frame gets detached
187         https://bugs.webkit.org/show_bug.cgi?id=167215
188         <rdar://problem/29885052>
189
190         Reviewed by Andreas Kling.
191
192         Make sure HTML validation bubble gets dismissed when its associated
193         element's frame gets detached and that we do not crash.
194
195         * WebCoreSupport/WebValidationMessageClient.h:
196         * WebCoreSupport/WebValidationMessageClient.mm:
197         (WebValidationMessageClient::documentDetached):
198
199 2017-01-19  Myles C. Maxfield  <mmaxfield@apple.com>
200
201         [Cocoa] Variation fonts are erroneously disabled on iOS
202         https://bugs.webkit.org/show_bug.cgi?id=167172
203
204         Reviewed by Simon Fraser.
205
206         OpenSource builders don't seem to understand sdk=embedded*.
207
208         * Configurations/FeatureDefines.xcconfig:
209
210 2017-01-19  Andreas Kling  <akling@apple.com>
211
212         ScriptExecutionContext::topOrigin() should return a reference.
213         <https://webkit.org/b/167190>
214
215         Reviewed by Sam Weinig.
216
217         * Misc/WebCache.mm:
218         (+[WebCache addImageToCache:forURL:forFrame:]):
219         (+[WebCache removeImageFromCacheForURL:forFrame:]):
220
221 2017-01-18  Ryan Haddad  <ryanhaddad@apple.com>
222
223         Unreviewed fix for the macOS build.
224
225         * Carbon/CarbonWindowAdapter.mm:
226         (-[CarbonWindowAdapter initWithCarbonWindowRef:takingOwnership:disableOrdering:carbon:]):
227
228 2017-01-18  Ryan Haddad  <ryanhaddad@apple.com>
229
230         Unreviewed, rolling out r210848.
231
232         This change introduced media-related LayoutTest failures and
233         crashes on macOS.
234
235         Reverted changeset:
236
237         "[Modern Media Controls] Turn modern media controls on by
238         default"
239         https://bugs.webkit.org/show_bug.cgi?id=165668
240         http://trac.webkit.org/changeset/210848
241
242 2017-01-18  Andreas Kling  <akling@apple.com>
243
244         Document::securityOrigin() should return a reference.
245         <https://webkit.org/b/167124>
246
247         Reviewed by Sam Weinig.
248
249         * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
250         (WebKit::NetscapePluginInstanceProxy::loadRequest):
251         * Plugins/WebNetscapePluginStream.mm:
252         (WebNetscapePluginStream::WebNetscapePluginStream):
253         * Plugins/WebNetscapePluginView.mm:
254         (-[WebNetscapePluginView loadRequest:inTarget:withNotifyData:sendNotification:]):
255         * Plugins/WebPluginContainerCheck.mm:
256         (-[WebPluginContainerCheck _isForbiddenFileLoad]):
257         * WebCoreSupport/WebChromeClient.mm:
258         (WebChromeClient::exceededDatabaseQuota):
259         * WebCoreSupport/WebFrameLoaderClient.h:
260         * WebCoreSupport/WebFrameLoaderClient.mm:
261         (WebFrameLoaderClient::didRunInsecureContent):
262         * WebCoreSupport/WebGeolocationClient.mm:
263         (WebGeolocationClient::requestPermission):
264         (-[WebGeolocationProviderInitializationListener initializationAllowedWebView:]):
265         * WebView/WebFrame.mm:
266         (-[WebFrame _allowsFollowingLink:]):
267
268 2017-01-18  Antoine Quint  <graouts@apple.com>
269
270         [Modern Media Controls] Turn modern media controls on by default
271         https://bugs.webkit.org/show_bug.cgi?id=165668
272
273         Reviewed by Dean Jackson.
274
275         Enabled modern media controls by default in WK1. 
276
277         * WebView/WebPreferences.mm:
278         (+[WebPreferences initialize]):
279
280 2017-01-15  Darin Adler  <darin@apple.com>
281
282         Remove PassRefPtr from "loader" directory of WebCore
283         https://bugs.webkit.org/show_bug.cgi?id=167055
284
285         Reviewed by Alex Christensen.
286
287         * WebCoreSupport/WebChromeClient.h: Updated for changes to ChromeClient.
288         Also made class final and most functions private and final.
289         * WebCoreSupport/WebChromeClient.mm:
290         (WebChromeClient::runOpenPanel): Updated to take references.
291
292         * WebCoreSupport/WebEditorClient.h: Updated for changes to EditorClient.
293         * WebCoreSupport/WebEditorClient.mm:
294         (-[WebUndoStep initWithUndoStep:]): Take reference instead of PassRefPtr.
295         (+[WebUndoStep stepWithUndoStep:]): Ditto.
296         (-[WebUndoStep step]): Return reference instead of pointer.
297         (-[WebEditorUndoTarget undoEditing:]): Updated for the above.
298         (-[WebEditorUndoTarget redoEditing:]): Ditto.
299         (WebEditorClient::registerUndoOrRedoStep): Take reference instead of
300         PassRefPtr.
301         (WebEditorClient::registerUndoStep): Ditto.
302         (WebEditorClient::registerRedoStep): Ditto.
303
304         * WebCoreSupport/WebFrameLoaderClient.h: Updated for changes to
305         FrameLoaderClient, marked functions final instead of override.
306         * WebCoreSupport/WebFrameLoaderClient.mm:
307         (WebFrameLoaderClient::dispatchDecidePolicyForNewWindowAction): Take
308         pointer instead of PassRefPtr.
309         (WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction): Ditto.
310         (makeFormFieldValuesDictionary): Take a reference.
311         (WebFrameLoaderClient::dispatchWillSendSubmitEvent): Take Ref&& instead
312         of PassRefPtr.
313         (WebFrameLoaderClient::dispatchWillSubmitForm): Take a reference instead
314         of PassRefPtr.
315         (WebFrameLoaderClient::actionDictionary): Take a pointer instead of PassRePtr.
316         (WebFrameLoaderClient::createFrame): Take a reference instead of a pointer.
317         (WebFrameLoaderClient::createPlugin): Ditto.
318         (WebFrameLoaderClient::createJavaAppletWidget): Ditto.
319         (WebFrameLoaderClient::createNetworkingContext): Ditto.
320         (WebFrameLoaderClient::didCreateQuickLookHandle): Pass a reference.
321
322         * WebCoreSupport/WebFrameNetworkingContext.h: Use Ref instead of PassRefPtr.
323         * WebCoreSupport/WebFrameNetworkingContext.mm: Tweak style a bit.
324
325         * WebCoreSupport/WebOpenPanelResultListener.h: Take a reference instead of
326         PassRefPtr. Use RefPtr for class field.
327         * WebCoreSupport/WebOpenPanelResultListener.mm:
328         (-[WebOpenPanelResultListener dealloc]): Deleted. Compiler will now do it
329         correctly without us declaring anything explicitly.
330         (-[WebOpenPanelResultListener cancel]): Get rid of hand-written deref code,
331         and let RefPtr do the work.
332         (-[WebOpenPanelResultListener chooseFilename:]): Ditto.
333         (-[WebOpenPanelResultListener chooseFilenames:]): Ditto.
334         (-[WebOpenPanelResultListener chooseFilenames:displayString:iconImage:]):
335         Rewrote to use a modern Objective-C for loop, reserveInitialCapacity,
336         and uncheckedAppend.
337
338         * WebView/WebArchive.mm:
339         (-[WebArchive initWithMainResource:subresources:subframeArchives:]):
340         Updated for changes to LegacyWebArchive.
341         (-[WebArchive mainResource]): Ditto.
342         (-[WebArchive subresources]): Ditto.
343         (-[WebArchive subframeArchives]): Ditto.
344
345         * WebView/WebDataSource.mm:
346         (-[WebDataSource _addSubframeArchives:]): Use a modern Objective-C for loop
347         instead of NSEnumerator.
348         (-[WebDataSource _fileWrapperForURL:]): Use auto.
349         (-[WebDataSource _documentFragmentWithArchive:]): Pass a reference.
350         (-[WebDataSource mainResource]): Ditto.
351         (-[WebDataSource subresources]): Ditto.
352         (-[WebDataSource subresourceForURL:]): Ditto.
353         (-[WebDataSource addSubresource:]): Ditto.
354
355         * WebView/WebResource.mm:
356         (-[WebResourcePrivate initWithCoreResource:]): Take Ref&& instead of PassRefPtr.
357         (-[WebResourcePrivate dealloc]): Remove explicit deref since RefPtr will now take
358         care of it
359         (-[WebResource initWithCoder:]): Pass a reference.
360         (-[WebResource encodeWithCoder:]): Updated since coreResource is now RefPtr.
361         (-[WebResource _initWithCoreResource:]): Take Ref&& instead of PassRefPtr.
362         (-[WebResource _coreResource]): Return reference rather than pointer.
363         (-[WebResource _initWithData:URL:MIMEType:textEncodingName:frameName:response:copyData:]):
364         Added code to handle the null case and pass a reference rather than a pointer.
365         * WebView/WebResourceInternal.h: Updated for the above.
366
367 2017-01-17  Michael Catanzaro  <mcatanzaro@igalia.com>
368
369         Unreviewed, rolling out r210834
370         https://bugs.webkit.org/show_bug.cgi?id=165668
371
372         It introduced dozens of test timeouts.
373
374         Reverted changeset:
375         "[Modern Media Controls] Turn modern media controls on by default"
376         https://bugs.webkit.org/show_bug.cgi?id=165668
377         http://trac.webkit.org/changeset/210834
378
379 2017-01-17  Antoine Quint  <graouts@apple.com>
380
381         [Modern Media Controls] Turn modern media controls on by default
382         https://bugs.webkit.org/show_bug.cgi?id=165668
383
384         Reviewed by Dean Jackson.
385
386         Enabled modern media controls by default in WK1. 
387
388         * WebView/WebPreferences.mm:
389         (+[WebPreferences initialize]):
390
391 2017-01-17  Joseph Pecoraro  <pecoraro@apple.com>
392
393         ENABLE(USER_TIMING) Not Defined for Apple Windows or OS X Ports
394         https://bugs.webkit.org/show_bug.cgi?id=116551
395         <rdar://problem/13949830>
396
397         Reviewed by Alex Christensen.
398
399         * Configurations/FeatureDefines.xcconfig:
400
401 2017-01-17  Joseph Pecoraro  <pecoraro@apple.com>
402
403         Crash when closing tab with debugger paused
404         https://bugs.webkit.org/show_bug.cgi?id=161746
405         <rdar://problem/15607819>
406
407         Reviewed by Brian Burg and Brent Fulgham.
408
409         * WebView/WebView.mm:
410         (WebKit::DeferredPageDestructor::createDeferredPageDestructor):
411         (WebKit::DeferredPageDestructor::DeferredPageDestructor):
412         (WebKit::DeferredPageDestructor::tryDestruction):
413         (-[WebView _close]):
414         Defer destruction of the Page if we are in a nested runloop.
415
416 2017-01-16  Joseph Pecoraro  <pecoraro@apple.com>
417
418         Remove the REQUEST_ANIMATION_FRAME flag
419         https://bugs.webkit.org/show_bug.cgi?id=156980
420         <rdar://problem/25906849>
421
422         Reviewed by Simon Fraser.
423
424         * Configurations/FeatureDefines.xcconfig:
425
426 2017-01-16  Andy Estes  <aestes@apple.com>
427
428         [QuickLook] Do some cleanup in QuickLookHandle
429         https://bugs.webkit.org/show_bug.cgi?id=166864
430
431         Reviewed by Darin Adler.
432
433         * WebCoreSupport/WebFrameLoaderClient.mm:
434         (WebFrameLoaderClient::didCreateQuickLookHandle): Changed to pass a
435         Ref<QuickLookHandleClient>&& to QuickLookHandle::setClient().
436
437 2017-01-15  Tim Horton  <timothy_horton@apple.com>
438
439         De-duplicate more (nearly) identical code in Editor(Mac|IOS).mm
440         https://bugs.webkit.org/show_bug.cgi?id=167063
441
442         Reviewed by Dan Bernstein.
443
444         * WebView/WebHTMLView.mm:
445         (-[WebHTMLView _selectionStartFontAttributesAsRTF]):
446         (-[WebHTMLView _updateFontPanel]):
447         * WebView/WebView.mm:
448         (-[WebView typingAttributes]):
449         Adjust to fontAttributesForSelectionStart returning a RetainPtr.
450
451 2017-01-13  Joseph Pecoraro  <pecoraro@apple.com>
452
453         Remove ENABLE(DETAILS_ELEMENT) guards
454         https://bugs.webkit.org/show_bug.cgi?id=167042
455
456         Reviewed by Alex Christensen.
457
458         * Configurations/FeatureDefines.xcconfig:
459
460 2017-01-11  Darin Adler  <darin@apple.com>
461
462         Remove PassRefPtr from more of "platform"
463         https://bugs.webkit.org/show_bug.cgi?id=166809
464
465         Reviewed by Sam Weinig.
466
467         * WebCoreSupport/WebFrameLoaderClient.mm:
468         (NetscapePluginWidget::handleEvent): Pass a reference.
469         * WebView/WebView.mm:
470         (-[WebView _addScrollerDashboardRegionsForFrameView:dashboardRegions:]):
471         Updated since the children set now contains Ref instead of RefPtr.
472
473 2017-01-13  Sam Weinig  <sam@webkit.org>
474
475         [WebIDL] Remove custom bindings for DeviceMotionEvent and DeviceOrientationEvent
476         https://bugs.webkit.org/show_bug.cgi?id=167006
477
478         Reviewed by Geoffrey Garen.
479
480         * WebView/WebDeviceOrientation.mm:
481         (convert):
482         (-[WebDeviceOrientation initWithCanProvideAlpha:alpha:canProvideBeta:beta:canProvideGamma:gamma:]):
483         Update for new use of std::optional.
484
485 2017-01-12  Joseph Pecoraro  <pecoraro@apple.com>
486
487         Remove unnecessary includes of Page.h
488         https://bugs.webkit.org/show_bug.cgi?id=166996
489
490         Reviewed by Yusuke Suzuki.
491
492         * DOM/DOMHTML.mm:
493         * History/WebBackForwardList.mm:
494         * Plugins/WebPluginController.mm:
495         * WebCoreSupport/WebNotificationClient.mm:
496         * WebCoreSupport/WebPlatformStrategies.mm:
497         * WebCoreSupport/WebUserMediaClient.mm:
498         * WebView/WebFullScreenController.mm:
499
500 2017-01-12  Chris Dumez  <cdumez@apple.com>
501
502         Add KEYBOARD_KEY_ATTRIBUTE / KEYBOARD_CODE_ATTRIBUTE to FeatureDefines.xcconfig
503         https://bugs.webkit.org/show_bug.cgi?id=166995
504
505         Reviewed by Jer Noble.
506
507         Add KEYBOARD_KEY_ATTRIBUTE / KEYBOARD_CODE_ATTRIBUTE to FeatureDefines.xcconfig
508         as some people are having trouble building without it.
509
510         * Configurations/FeatureDefines.xcconfig:
511
512 2017-01-12  Chris Dumez  <cdumez@apple.com>
513
514         HTML form validation popover sometimes does not go away
515         https://bugs.webkit.org/show_bug.cgi?id=166990
516         <rdar://problem/29985957>
517
518         Reviewed by Tim Horton.
519
520         Update code using ValidationBubble now that it is RefCounted.
521
522         * WebView/WebView.mm:
523         (-[WebView showFormValidationMessage:withAnchorRect:]):
524
525 2017-01-10  Ryosuke Niwa  <rniwa@webkit.org>
526
527         Remove pointerLockElement from DOMDocumentPrivate.h
528         https://bugs.webkit.org/show_bug.cgi?id=166882
529
530         Reviewed by Simon Fraser.
531
532         Removed pointerLockElement declaration that was supposed to be removed in r209637.
533
534         * DOM/DOMDocumentPrivate.h:
535
536 2017-01-06  Darin Adler  <darin@apple.com>
537
538         Remove PassRefPtr use from "inspector", "platform/sql", and "platform/text"
539         https://bugs.webkit.org/show_bug.cgi?id=166797
540
541         Reviewed by Alex Christensen.
542
543         * WebCoreSupport/WebEditorClient.h: Updated to take a reference.
544         * WebCoreSupport/WebEditorClient.mm:
545         (WebEditorClient::requestCheckingOfString): Take a reference
546         instead of a PassRefPtr.
547
548 2017-01-05  Chris Dumez  <cdumez@apple.com>
549
550         Turn preferLowPowerWebGLRendering setting on by default
551         https://bugs.webkit.org/show_bug.cgi?id=166737
552         <rdar://problem/29870033>
553
554         Reviewed by Dean Jackson.
555
556         Temporarily turn preferLowPowerWebGLRendering setting on by default until
557         we deal better with WebGL content in background tabs.
558
559         * WebView/WebPreferences.mm:
560         (+[WebPreferences initialize]):
561
562 2017-01-05  Enrica Casucci  <enrica@apple.com>
563
564         Support File Promise during drag for macOS.
565         https://bugs.webkit.org/show_bug.cgi?id=165204
566         rdar://problem/19595567
567
568         Reviewed by Tim Horton.
569
570         Adds support for dropping a File Promise in a WebView.
571         The implementation uses new File Promise API available in Sierra.
572
573         * Misc/WebNSPasteboardExtras.mm:
574         (+[NSPasteboard _web_dragTypesForURL]):
575         * WebView/WebView.mm:
576         (-[WebView performDragOperation:]):
577
578 2017-01-05  Andreas Kling  <akling@apple.com>
579
580         Remove ChromeClient::needTouchEvents().
581         <https://webkit.org/b/166723>
582
583         Rubber-stamped by Antti Koivisto.
584
585         * WebCoreSupport/WebChromeClient.h:
586
587 2017-01-04  Darin Adler  <darin@apple.com>
588
589         Remove PassRefPtr use from the "html" directory, other improvements
590         https://bugs.webkit.org/show_bug.cgi?id=166635
591
592         Reviewed by Alex Christensen.
593
594         * WebCoreSupport/WebChromeClient.h:
595         * WebCoreSupport/WebChromeClient.mm:
596         (WebChromeClient::loadIconForFiles): Take a reference instead of a pointer.
597
598 2017-01-04  Ryan Haddad  <ryanhaddad@apple.com>
599
600         Unreviewed, rolling out r210287.
601
602         This change caused editing test failures on macOS.
603
604         Reverted changeset:
605
606         "Support File Promise during drag for macOS."
607         https://bugs.webkit.org/show_bug.cgi?id=165204
608         http://trac.webkit.org/changeset/210287
609
610 2017-01-04  Enrica Casucci  <enrica@apple.com>
611
612         Support File Promise during drag for macOS.
613         https://bugs.webkit.org/show_bug.cgi?id=165204
614         rdar://problem/19595567
615
616         Reviewed by Tim Horton.
617
618         Adds support for dropping a File Promise in a WebView.
619         The implementation uses new File Promise API available in Sierra.
620
621         * Misc/WebNSPasteboardExtras.mm:
622         (+[NSPasteboard _web_dragTypesForURL]):
623         * WebView/WebView.mm:
624         (-[WebView performDragOperation:]):
625
626 2017-01-04  Tim Horton  <timothy_horton@apple.com>
627
628         Provide a setting for clients to always prefer low-power WebGL
629         https://bugs.webkit.org/show_bug.cgi?id=166675
630         <rdar://problem/29834093>
631
632         Reviewed by Dan Bernstein.
633
634         * WebView/WebPreferenceKeysPrivate.h:
635         * WebView/WebPreferences.mm:
636         (+[WebPreferences initialize]):
637         (-[WebPreferences preferLowPowerWebGLRendering]):
638         (-[WebPreferences setPreferLowPowerWebGLRendering:]):
639         * WebView/WebPreferencesPrivate.h:
640         * WebView/WebView.mm:
641         (-[WebView _preferencesChanged:]):
642         Expose a new private preferLowPowerWebGLRendering WebKit1 preference.
643
644 2017-01-03  Tim Horton  <timothy_horton@apple.com>
645
646         NSSpellChecker's recordResponse isn't called for unseen automatic corrections
647         https://bugs.webkit.org/show_bug.cgi?id=166450
648         <rdar://problem/29447824>
649
650         Reviewed by Darin Adler.
651
652         * WebCoreSupport/CorrectionPanel.h:
653         * WebCoreSupport/CorrectionPanel.mm:
654         (CorrectionPanel::recordAutocorrectionResponse):
655         (CorrectionPanel::handleAcceptedReplacement):
656         * WebCoreSupport/WebAlternativeTextClient.mm:
657         (toCorrectionResponse):
658         (WebAlternativeTextClient::recordAutocorrectionResponse):
659         Funnel all calls to recordResponse:toCorrection:forWord:language:inSpellDocumentWithTag:
660         through recordAutocorrectionResponse, for debugging's sake.
661         Drop the NSView parameter because we don't need it, just the tag.
662         Convert the new AutocorrectionResponseType value to its corresponding
663         NSCorrectionResponse value.
664
665 2017-01-01  Jeff Miller  <jeffm@apple.com>
666
667         Update user-visible copyright strings to include 2017
668         https://bugs.webkit.org/show_bug.cgi?id=166278
669
670         Reviewed by Dan Bernstein.
671
672         * Info.plist:
673
674 2016-12-30  Darin Adler  <darin@apple.com>
675
676         Remove PassRefPtr use from the "dom" directory, related cleanup
677         https://bugs.webkit.org/show_bug.cgi?id=166569
678
679         Reviewed by Alex Christensen.
680
681         * WebCoreSupport/WebFrameLoaderClient.mm:
682         (WebFrameLoaderClient::dispatchDidReceiveTitle): Updated to use struct.
683         (WebFrameLoaderClient::updateGlobalHistory): Ditto.
684         (WebFrameLoaderClient::setTitle): Ditto.
685         (WebFrameLoaderClient::transitionToCommittedForNewPage): Ditto.
686         * WebView/WebFrame.mm:
687         (-[WebFrame _dispatchDidReceiveTitle:]): Use aggregate-style syntax for StringWithDirection.
688         Not needed now, but useful later if we ever can get rid of the explicit constructors.
689         (-[WebFrame loadArchive:]): Pass a reference to loadArchive.
690         * WebView/WebHTMLRepresentation.mm:
691         (-[WebHTMLRepresentation title]): Updated to use struct.
692
693 2016-12-25  Yusuke Suzuki  <utatane.tea@gmail.com>
694
695         Propagate the source origin as much as possible
696         https://bugs.webkit.org/show_bug.cgi?id=166348
697
698         Reviewed by Darin Adler.
699
700         * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
701         (WebKit::NetscapePluginInstanceProxy::evaluate):
702
703 2016-12-23  Andy Estes  <aestes@apple.com>
704
705         [iOS] DumpRenderTree triggers an assertion failure when calling +[WebPreferences _switchNetworkLoaderToNewTestingSession]
706         https://bugs.webkit.org/show_bug.cgi?id=166471
707
708         Reviewed by Andreas Kling.
709
710         When DumpRenderTree starts up, it calls
711         +[WebPreferences _switchNetworkLoaderToNewTestingSession] from the main thread. In Debug
712         builds, this triggers the ASSERT(isMainThread()) in
713         NetworkStorageSession::defaultNetworkStorageSession() because the Web thread has already
714         started, we are on the main thread, and we are not holding the Web thread lock. This is
715         causing all layout tests to crash in the iOS WK1 Debug configuration.
716
717         * WebView/WebPreferences.mm: (+[WebPreferences _switchNetworkLoaderToNewTestingSession]):
718         Take the Web thread lock before calling NetworkStorageSession::switchToNewTestingSession().
719
720 2016-12-22  Andy Estes  <aestes@apple.com>
721
722         Make WebCore::EditorInsertAction an enum class
723         https://bugs.webkit.org/show_bug.cgi?id=166424
724
725         Reviewed by Brent Fulgham.
726
727         * WebCoreSupport/WebEditorClient.mm:
728         (kit):
729
730 2016-12-21  Beth Dakin  <bdakin@apple.com>
731
732         Holding down on candidates in the TouchBar should show panel on screen
733         https://bugs.webkit.org/show_bug.cgi?id=166367
734         -and corresponding-
735         <rdar://problem/28479236>
736
737         Reviewed by Tim Horton.
738
739         Stray whitespace.
740         * WebCoreSupport/WebEditorClient.mm:
741         (WebEditorClient::handleRequestedCandidates):
742
743         Call the version of setCandidates: that takes a rect. We need to keep the helper 
744         function in WK1 (unlike WK2) since we also use it for testing.
745         * WebView/WebView.mm:
746         (-[WebView showCandidates:forString:inRect:forSelectedRange:view:completionHandler:]):
747
748 2016-12-20  Dean Jackson  <dino@apple.com>
749
750         Remove INDIE_UI
751         https://bugs.webkit.org/show_bug.cgi?id=165881
752         <rdar://problem/29672532>
753
754         Reviewed by Simon Fraser.
755
756         The Indie UI work has been discontinued.
757
758         * Configurations/FeatureDefines.xcconfig:
759
760 2016-12-19  Yusuke Suzuki  <utatane.tea@gmail.com>
761
762         [ES6] Enable ES6 Modules
763         https://bugs.webkit.org/show_bug.cgi?id=165849
764
765         Reviewed by Geoffrey Garen.
766
767         * WebView/WebPreferenceKeysPrivate.h:
768         * WebView/WebPreferences.mm:
769         (+[WebPreferences initialize]):
770         (-[WebPreferences es6ModulesEnabled]): Deleted.
771         (-[WebPreferences setES6ModulesEnabled:]): Deleted.
772         * WebView/WebPreferencesPrivate.h:
773         * WebView/WebView.mm:
774         (-[WebView _preferencesChanged:]):
775
776 2016-12-16  Dave Hyatt  <hyatt@apple.com>
777
778         [CSS Values] Make separate wrapper classes for the deprecated CSS Values OM
779         https://bugs.webkit.org/show_bug.cgi?id=165968
780
781         Reviewed by Andreas Kling.
782
783         * DOM/DOMCSS.mm:
784         (kitClass):
785         * DOM/DOMCSSPrimitiveValue.mm:
786         (-[DOMCSSPrimitiveValue getCounterValue]):
787         (-[DOMCSSPrimitiveValue getRectValue]):
788         (kit):
789         * DOM/DOMCSSPrimitiveValueInternal.h:
790         * DOM/DOMCSSStyleDeclaration.mm:
791         * DOM/DOMCSSValue.mm:
792         (kit):
793         * DOM/DOMCSSValueInternal.h:
794         * DOM/DOMCSSValueList.mm:
795         * DOM/DOMCounter.mm:
796         (kit):
797         * DOM/DOMCounterInternal.h:
798         * DOM/DOMRGBColor.mm:
799         (kit):
800         * DOM/DOMRGBColorInternal.h:
801         * DOM/DOMRect.mm:
802         (kit):
803         * DOM/DOMRectInternal.h:
804         * DOM/DOMUtility.mm:
805         (createDOMWrapper):
806
807 2016-12-16  Chris Dumez  <cdumez@apple.com>
808
809         HTML form validation bubble should be dismissed on navigation
810         https://bugs.webkit.org/show_bug.cgi?id=165960
811         <rdar://problem/29668086>
812
813         Reviewed by Simon Fraser.
814
815         Dismiss HTML form validation bubble on top-level navigation on Mac WK1.
816
817         * WebView/WebView.mm:
818         (-[WebView _didStartProvisionalLoadForFrame:]):
819
820 2016-12-15  Darin Adler  <darin@apple.com>
821
822         Use asString instead of toWTFString, toString, or getString when we already checked isString
823         https://bugs.webkit.org/show_bug.cgi?id=165895
824
825         Reviewed by Yusuke Suzuki.
826
827         * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
828         (WebKit::NetscapePluginInstanceProxy::addValueToArray): Use asString/value instead of
829         toWTFString.
830         * WebView/WebView.mm:
831         (aeDescFromJSValue): Use asString/value instead of getString.
832
833 2016-12-15  Chris Dumez  <cdumez@apple.com>
834
835         Make sure HTML validation bubble's state is updated after layout
836         https://bugs.webkit.org/show_bug.cgi?id=165922
837         <rdar://problem/29694730>
838
839         Reviewed by Simon Fraser.
840
841         Make sure HTML validation bubble's state is updated after layout.
842         In particular, if the validation bubble's associated element has
843         moved or is no longer visible, we now hide the bubble.
844
845         * WebCoreSupport/WebValidationMessageClient.h:
846         * WebCoreSupport/WebValidationMessageClient.mm:
847         (WebValidationMessageClient::showValidationMessage):
848         (WebValidationMessageClient::hideValidationMessage):
849         (WebValidationMessageClient::updateValidationBubbleStateIfNeeded):
850
851 2016-12-15  Chris Dumez  <cdumez@apple.com>
852
853         Move charCode / keyCode / which attributes from UIEvent to KeyboardEvent
854         https://bugs.webkit.org/show_bug.cgi?id=165904
855
856         Reviewed by Sam Weinig.
857
858         Update ObjC bindings so they keep building.
859
860         * DOM/DOMUIEvent.mm:
861         (-[DOMUIEvent keyCode]):
862         (-[DOMUIEvent charCode]):
863
864 2016-12-15  Andreas Kling  <akling@apple.com>
865
866         Always clear RenderLayer backing stores when going into page cache.
867         <https://webkit.org/b/165901>
868
869         Reviewed by Simon Fraser.
870
871         * WebView/WebView.mm:
872         (+[WebView _setCacheModel:]):
873
874 2016-12-12  Alex Christensen  <achristensen@webkit.org>
875
876         Remove unused workaround for Silverlight
877         https://bugs.webkit.org/show_bug.cgi?id=165773
878
879         Reviewed by Dean Jackson.
880
881         * Plugins/WebNetscapePluginView.mm:
882         (-[WebNetscapePluginView _workaroundSilverlightFullscreenBug:]): Deleted.
883         This code was introduced in January 2010.  Microsoft fixed their bug shortly thereafter.
884         Allowing 6 years for users to update Silverlight is more than enough.
885         Safari doesn't even use WebKit1 for this any more.
886         I need this to be removed because this is the only non-WebGL code that needs to link against
887         the OpenGL framework, and I'm changing how that is done to link only through ANGLE instead.
888
889 2016-12-12  Chris Dumez  <cdumez@apple.com>
890
891         Document.visibilityState should use an IDL string enumeration
892         https://bugs.webkit.org/show_bug.cgi?id=165774
893
894         Reviewed by Daniel Bates.
895
896         * DOM/DOMDocument.mm:
897         (-[DOMDocument visibilityState]):
898         * WebView/WebView.mm:
899         (kit):
900
901 2016-12-12  Jer Noble  <jer.noble@apple.com>
902
903         Remove implementation of legacy Mozilla-based Fullscreen API.
904         https://bugs.webkit.org/show_bug.cgi?id=165689
905         <rdar://problem/29603053>
906
907         Reviewed by Eric Carlson.
908
909         * DOM/DOMElement.mm:
910         (-[DOMElement webkitRequestFullScreen:]):
911
912 2016-12-10  Filip Pizlo  <fpizlo@apple.com>
913
914         The DOM should have an advancing wavefront opaque root barrier
915         https://bugs.webkit.org/show_bug.cgi?id=165712
916
917         Reviewed by Yusuke Suzuki.
918         
919         Propagate the JSDOMWindowBase::commonVM() -> commonVM() change.
920
921         * Misc/WebCoreStatistics.mm:
922         (+[WebCoreStatistics javaScriptObjectsCount]):
923         (+[WebCoreStatistics javaScriptGlobalObjectsCount]):
924         (+[WebCoreStatistics javaScriptProtectedObjectsCount]):
925         (+[WebCoreStatistics javaScriptProtectedGlobalObjectsCount]):
926         (+[WebCoreStatistics javaScriptProtectedObjectTypeCounts]):
927         (+[WebCoreStatistics javaScriptObjectTypeCounts]):
928         (+[WebCoreStatistics shouldPrintExceptions]):
929         (+[WebCoreStatistics setShouldPrintExceptions:]):
930         (+[WebCoreStatistics memoryStatistics]):
931         (+[WebCoreStatistics javaScriptReferencedObjectsCount]):
932         * Plugins/Hosted/NetscapePluginHostProxy.mm:
933         (identifierFromIdentifierRep):
934         * Plugins/Hosted/ProxyInstance.mm:
935         (WebKit::ProxyInstance::getPropertyNames):
936         * Plugins/WebNetscapePluginStream.mm:
937         (WebNetscapePluginStream::wantsAllStreams):
938         * Plugins/WebNetscapePluginView.mm:
939         (-[WebNetscapePluginView sendEvent:isDrawRect:]):
940         (-[WebNetscapePluginView privateBrowsingModeDidChange]):
941         (-[WebNetscapePluginView setWindowIfNecessary]):
942         (-[WebNetscapePluginView createPluginScriptableObject]):
943         (-[WebNetscapePluginView getFormValue:]):
944         (-[WebNetscapePluginView evaluateJavaScriptPluginRequest:]):
945         (-[WebNetscapePluginView webFrame:didFinishLoadWithReason:]):
946         (-[WebNetscapePluginView loadPluginRequest:]):
947         (-[WebNetscapePluginView _printedPluginBitmap]):
948         * Plugins/WebPluginController.mm:
949         (-[WebPluginController plugInViewWithArguments:fromPluginPackage:]):
950         (-[WebPluginController stopOnePlugin:]):
951         (-[WebPluginController stopOnePluginForPageCache:]):
952         (-[WebPluginController destroyOnePlugin:]):
953         (-[WebPluginController startAllPlugins]):
954         (-[WebPluginController addPlugin:]):
955
956 2016-12-09  Dave Hyatt  <hyatt@apple.com>
957
958         [CSS Parser] Remove the old CSS Parser
959         https://bugs.webkit.org/show_bug.cgi?id=165645
960
961         Reviewed by Daniel Bates.
962
963         * DOM/DOMCSS.mm:
964         (kitClass):
965         * DOM/DOMCSSRule.h:
966
967 2016-12-09  Eric Carlson  <eric.carlson@apple.com>
968
969         Annotate MediaStream and WebRTC idl with EnabledAtRuntime flag
970         https://bugs.webkit.org/show_bug.cgi?id=165251
971
972         Reviewed by Dean Jackson.
973
974         Based on a patch by Dr Alex Gouaillard <agouaillard@gmail.com>
975
976         * WebView/WebPreferenceKeysPrivate.h: Add MediaStream and PeerConnection preferences.
977         * WebView/WebPreferences.mm:
978         (+[WebPreferences initialize]):
979         (-[WebPreferences mediaStreamEnabled]):
980         (-[WebPreferences setMediaStreamEnabled:]):
981         (-[WebPreferences peerConnectionEnabled]):
982         (-[WebPreferences setPeerConnectionEnabled:]):
983         * WebView/WebPreferencesPrivate.h:
984         * WebView/WebView.mm:
985         (-[WebView _preferencesChanged:]):
986
987 2016-12-09  Ryosuke Niwa  <rniwa@webkit.org>
988
989         Don’t expose pointer lock in WebKit1 Objective-C API
990         https://bugs.webkit.org/show_bug.cgi?id=165692
991
992         Reviewed by Simon Fraser.
993
994         * DOM/DOMDocument.mm:
995         (-[DOMDocument pointerLockElement]): Deleted.
996         (-[DOMDocument exitPointerLock]): Deleted.
997         * DOM/DOMElement.mm:
998         (-[DOMElement requestPointerLock]): Deleted.
999         * DOM/DOMMouseEvent.mm:
1000         (-[DOMMouseEvent movementX]): Deleted.
1001         (-[DOMMouseEvent movementY]): Deleted.
1002
1003 2016-12-09  Ryosuke Niwa  <rniwa@webkit.org>
1004
1005         document.webkitFullscreenElement leaks elements inside a shadow tree
1006         https://bugs.webkit.org/show_bug.cgi?id=158471
1007
1008         Reviewed by Chris Dumez.
1009
1010         Use the API for bindings to avoid exposing nodes inside a shadow tree.
1011
1012         * DOM/DOMDocument.mm:
1013         (-[DOMDocument webkitCurrentFullScreenElement]):
1014         (-[DOMDocument webkitFullscreenElement]):
1015
1016 2016-12-09  Beth Dakin  <bdakin@apple.com>
1017
1018         Password fields should not show the emoji button in TouchBar
1019         https://bugs.webkit.org/show_bug.cgi?id=165673
1020         -and corresponding-
1021         rdar://problem/29235739
1022
1023         Reviewed by Wenson Hsieh.
1024
1025         This patch adds a new ivar for the password touch bar and password 
1026         candidateListTouchBarItem. Since this TouchBar will actually have a different set 
1027         of identifiers than the plain text TouchBar, it should just have its own variable.
1028
1029         The candidate list should be the only item for passwords.
1030         * WebView/WebView.mm:
1031         (-[WebView _passwordTextTouchBarDefaultItemIdentifiers]):
1032
1033         Account for _passwordTextTouchBar.
1034         (-[WebView didChangeAutomaticTextCompletion:]):
1035         (-[WebView setUpTextTouchBar:]):
1036         (-[WebView textTouchBar]):
1037
1038         The empty candidates array is not needed. We can just set @[ ] as the candidates 
1039         for the _passwordTextCandidateListTouchBarItem. Safe guards already exist in the 
1040         other parts of the code to prevent us from requesting or setting other candidates 
1041         when in a password field. 
1042         (-[WebView updateTextTouchBar]):
1043
1044         Account for _passwordTextTouchBar.
1045         (-[WebView candidateList]):
1046         * WebView/WebViewData.h:
1047
1048 2016-12-08  Filip Pizlo  <fpizlo@apple.com>
1049
1050         Enable SharedArrayBuffer, remove the flag
1051         https://bugs.webkit.org/show_bug.cgi?id=165614
1052
1053         Rubber stamped by Geoffrey Garen.
1054
1055         * WebView/WebPreferencesPrivate.h:
1056
1057 2016-12-07  Dean Jackson  <dino@apple.com>
1058
1059         Remove runtime toggle for pointer-lock
1060         https://bugs.webkit.org/show_bug.cgi?id=165577
1061         <rdar://problems/29566996>
1062
1063         Reviewed by Jon Lee.
1064
1065         Remove any runtime calls to check if pointer-lock is enabled. It's
1066         either compiled in or out.
1067
1068         * WebView/WebPreferenceKeysPrivate.h:
1069         * WebView/WebPreferences.mm:
1070         (-[WebPreferences pointerLockEnabled]): Deleted.
1071         (-[WebPreferences setPointerLockEnabled:]): Deleted.
1072         * WebView/WebPreferencesPrivate.h:
1073         * WebView/WebView.mm:
1074         (-[WebView _preferencesChanged:]):
1075
1076 2016-12-06  Alexey Proskuryakov  <ap@apple.com>
1077
1078         Correct SDKROOT values in xcconfig files
1079         https://bugs.webkit.org/show_bug.cgi?id=165487
1080         rdar://problem/29539209
1081
1082         Reviewed by Dan Bernstein.
1083
1084         Fix suggested by Dan Bernstein.
1085
1086         * Configurations/DebugRelease.xcconfig:
1087
1088 2016-12-05  Simon Fraser  <simon.fraser@apple.com>
1089
1090         Improve the behavior of scroll-into-view when the target is inside position:fixed
1091         https://bugs.webkit.org/show_bug.cgi?id=165354
1092
1093         Reviewed by Zalan Bujtas.
1094
1095         Plumb through 'insideFixed'. We don't get compute it, so behavior from
1096         these call sites won't change.
1097
1098         * WebView/WebFrame.mm:
1099         (-[WebFrame _scrollDOMRangeToVisible:]):
1100         (-[WebFrame _scrollDOMRangeToVisible:withInset:]):
1101
1102 2016-12-06  Simon Fraser  <simon.fraser@apple.com>
1103
1104         Enable visual viewports by default on Mac, and iOS Wk2
1105         https://bugs.webkit.org/show_bug.cgi?id=165452
1106
1107         Reviewed by Zalan Bujtas.
1108
1109         Turn visual viewports on by default for WK1 on Mac.
1110
1111         * WebView/WebPreferences.mm:
1112         (+[WebPreferences initialize]):
1113
1114 2016-12-05  Dean Jackson  <dino@apple.com>
1115
1116         pointer lock needs to be feature detectable
1117         https://bugs.webkit.org/show_bug.cgi?id=165426
1118         <rdar://problem/29486715>
1119
1120         Reviewed by Antoine Quint.
1121
1122         Set the RuntimeEnabledFeature as preferences
1123         change.
1124
1125         * WebView/WebView.mm:
1126         (-[WebView _preferencesChanged:]):
1127
1128 2016-12-05  Ryan Haddad  <ryanhaddad@apple.com>
1129
1130         Unreviewed, rolling out r209299.
1131
1132         This change appears to have caused LayoutTest failures on
1133         Sierra WK1.
1134
1135         Reverted changeset:
1136
1137         "Improve the behavior of scroll-into-view when the target is
1138         inside position:fixed"
1139         https://bugs.webkit.org/show_bug.cgi?id=165354
1140         http://trac.webkit.org/changeset/209299
1141
1142 2016-12-02  Simon Fraser  <simon.fraser@apple.com>
1143
1144         Improve the behavior of scroll-into-view when the target is inside position:fixed
1145         https://bugs.webkit.org/show_bug.cgi?id=165354
1146
1147         Reviewed by Zalan Bujtas.
1148
1149         Plumb through 'insideFixed'. We don't get compute it, so behavior from
1150         these call sites won't change.
1151
1152         * WebView/WebFrame.mm:
1153         (-[WebFrame _scrollDOMRangeToVisible:]):
1154         (-[WebFrame _scrollDOMRangeToVisible:withInset:]):
1155
1156 2016-12-02  Andy Estes  <aestes@apple.com>
1157
1158         [Cocoa] Adopt the PRODUCT_BUNDLE_IDENTIFIER build setting
1159         https://bugs.webkit.org/show_bug.cgi?id=164492
1160
1161         Reviewed by Dan Bernstein.
1162
1163         * Configurations/WebKitLegacy.xcconfig: Set PRODUCT_BUNDLE_IDENTIFIER to
1164         com.apple.$(PRODUCT_NAME:rfc1034identifier).
1165         * Info.plist: Changed CFBundleIdentifier's value from com.apple.${PRODUCT_NAME} to
1166         ${PRODUCT_BUNDLE_IDENTIFIER}.
1167
1168 2016-12-02  Chris Dumez  <cdumez@apple.com>
1169
1170         Regression(r209252): HTML interactive validation should not be enabled on iOS WK1 yet
1171         https://bugs.webkit.org/show_bug.cgi?id=165328
1172
1173         Reviewed by Simon Fraser.
1174
1175         Only enable HTML interactive form validation on Mac WK1, not iOS WK1.
1176
1177         * WebView/WebViewData.mm:
1178         (-[WebViewPrivate init]):
1179
1180 2016-12-02  Chris Dumez  <cdumez@apple.com>
1181
1182         [Mac][WK1] Implement new HTML interactive form validation user interface
1183         https://bugs.webkit.org/show_bug.cgi?id=164483
1184
1185         Reviewed by Simon Fraser.
1186
1187         Implement new HTML interactive form validation user interface on Mac
1188         WK1 and enable it by default.
1189
1190         * WebCoreSupport/WebValidationMessageClient.h: Added.
1191         * WebCoreSupport/WebValidationMessageClient.mm: Added.
1192         (WebValidationMessageClient::WebValidationMessageClient):
1193         (WebValidationMessageClient::~WebValidationMessageClient):
1194         (WebValidationMessageClient::showValidationMessage):
1195         (WebValidationMessageClient::hideValidationMessage):
1196         (WebValidationMessageClient::isValidationMessageVisible):
1197         * WebView/WebHTMLView.mm:
1198         (-[WebHTMLView _frameOrBoundsChanged]):
1199         * WebView/WebView.mm:
1200         (-[WebView _commonInitializationWithFrameName:groupName:]):
1201         (-[WebView _willStartScrollingOrZooming]):
1202         (-[WebView _contentsOfUserInterfaceItem:]):
1203         (-[WebView _scaleWebView:atOrigin:]):
1204         (-[WebView _didScrollDocumentInFrameView:]):
1205         (-[WebView _setZoomMultiplier:isTextOnly:]):
1206         (-[WebView showFormValidationMessage:withAnchorRect:]):
1207         (-[WebView hideFormValidationMessage]):
1208         * WebView/WebViewData.h:
1209         * WebView/WebViewData.mm:
1210         (-[WebViewPrivate init]):
1211         * WebView/WebViewInternal.h:
1212         * WebView/WebViewPrivate.h:
1213
1214 2016-12-01  Jiewen Tan  <jiewen_tan@apple.com>
1215
1216         Add a runtime flag for SubtleCrypto
1217         https://bugs.webkit.org/show_bug.cgi?id=164982
1218
1219         Reviewed by Brent Fulgham.
1220
1221         * WebView/WebPreferenceKeysPrivate.h:
1222         * WebView/WebPreferences.mm:
1223         (+[WebPreferences initialize]):
1224         (-[WebPreferences subtleCryptoEnabled]):
1225         (-[WebPreferences setSubtleCryptoEnabled:]):
1226         * WebView/WebPreferencesPrivate.h:
1227         * WebView/WebView.mm:
1228         (-[WebView _preferencesChanged:]):
1229
1230 2016-11-30  Said Abou-Hallawa  <sabouhallawa@apple.com>
1231
1232         Add separate settings and preferences to enable/disable async decoding for large images and animated images
1233         https://bugs.webkit.org/show_bug.cgi?id=165177
1234
1235         Reviewed by Simon Fraser.
1236         
1237         Hook up the async image decoding settings for WebKit1.
1238
1239         * WebView/WebPreferenceKeysPrivate.h:
1240         * WebView/WebPreferences.mm:
1241         (+[WebPreferences initialize]):
1242         (-[WebPreferences largeImageAsyncDecodingEnabled]):
1243         (-[WebPreferences setLargeImageAsyncDecodingEnabled:]):
1244         (-[WebPreferences animatedImageAsyncDecodingEnabled]):
1245         (-[WebPreferences setAnimatedImageAsyncDecodingEnabled:]):
1246         (-[WebPreferences asyncImageDecodingEnabled]): Deleted.
1247         (-[WebPreferences setAsyncImageDecodingEnabled:]): Deleted.
1248         * WebView/WebPreferencesPrivate.h:
1249         * WebView/WebView.mm:
1250         (-[WebView _preferencesChanged:]):
1251
1252 2016-11-29  Andy Estes  <aestes@apple.com>
1253
1254         [Cocoa] Enable two clang warnings recommended by Xcode
1255         https://bugs.webkit.org/show_bug.cgi?id=164498
1256
1257         Reviewed by Mark Lam.
1258
1259         * Configurations/Base.xcconfig: Enabled CLANG_WARN_INFINITE_RECURSION and CLANG_WARN_SUSPICIOUS_MOVE.
1260
1261 2016-11-26  Yusuke Suzuki  <utatane.tea@gmail.com>
1262
1263         [WTF] Import std::optional reference implementation as WTF::Optional
1264         https://bugs.webkit.org/show_bug.cgi?id=164199
1265
1266         Reviewed by Saam Barati and Sam Weinig.
1267
1268         Use WTF::Optional::value_or.
1269
1270         * DOM/DOMHTMLOptionsCollection.mm:
1271         (-[DOMHTMLOptionsCollection add:index:]):
1272         * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
1273         (WebKit::NetscapePluginInstanceProxy::evaluate):
1274         * Plugins/WebNetscapePluginView.mm:
1275         (-[WebNetscapePluginView sendEvent:isDrawRect:]):
1276         * WebCoreSupport/WebFrameLoaderClient.h:
1277         * WebCoreSupport/WebFrameLoaderClient.mm:
1278         (WebFrameLoaderClient::dispatchDidCommitLoad):
1279         * WebCoreSupport/WebPaymentCoordinatorClient.h:
1280         * WebCoreSupport/WebPaymentCoordinatorClient.mm:
1281         (WebPaymentCoordinatorClient::completeShippingMethodSelection):
1282         (WebPaymentCoordinatorClient::completeShippingContactSelection):
1283         (WebPaymentCoordinatorClient::completePaymentMethodSelection):
1284         * WebCoreSupport/WebSecurityOrigin.mm:
1285         (-[WebSecurityOrigin port]):
1286         * WebView/WebHTMLView.mm:
1287         (toAction):
1288         (toTag):
1289
1290 2016-11-26  Sam Weinig  <sam@webkit.org>
1291
1292         Convert IntersectionObserver over to using RuntimeEnabledFeatures so it can be properly excluded from script
1293         https://bugs.webkit.org/show_bug.cgi?id=164965
1294
1295         Reviewed by Simon Fraser.
1296
1297         * WebView/WebPreferenceKeysPrivate.h:
1298         * WebView/WebPreferences.mm:
1299         (-[WebPreferences intersectionObserverEnabled]):
1300         (-[WebPreferences setIntersectionObserverEnabled:]):
1301         * WebView/WebPreferencesPrivate.h:
1302         * WebView/WebView.mm:
1303         (-[WebView _preferencesChanged:]):
1304         Add a preference, defaulting to off, for enabling IntersectionObserver.
1305
1306 2016-11-22  Dan Bernstein  <mitz@apple.com>
1307
1308         [Mac] In Legacy WebKit, pressing an arrow key in editable content doesn’t hide the mouse cursor
1309         https://bugs.webkit.org/show_bug.cgi?id=165036
1310         <rdar://problem/5708580>
1311
1312         Reviewed by Alexey Proskuryakov.
1313
1314         * WebView/WebHTMLView.mm:
1315         (-[WebHTMLView performKeyEquivalent:]): Hide the cursor if WebCore handled the event,
1316           similarly to what we do in -keyDown: and to what WKWebView does with all key events.
1317
1318 2016-11-21  Alex Christensen  <achristensen@webkit.org>
1319
1320         Fix Sierra CMake build after r208452
1321         https://bugs.webkit.org/show_bug.cgi?id=164437
1322
1323         * WebView/WebView.mm:
1324         (-[WebView updateMediaTouchBar]):
1325         I haven't enabled VIDEO_PRESENTATION_MODE in the CMake build yet.
1326         It's needed for playbackSessionInterface to exist.
1327
1328 2016-11-18  Enrica Casucci  <enrica@apple.com>
1329
1330         Refactor drag and drop for WebKit2 to encode DragData message exchange.
1331         https://bugs.webkit.org/show_bug.cgi?id=164945
1332
1333         Reviewed by Tim Horton.
1334
1335         * WebCoreSupport/WebDragClient.h:
1336         * WebCoreSupport/WebDragClient.mm:
1337         (WebDragClient::actionMaskForDrag):
1338         (WebDragClient::willPerformDragDestinationAction):
1339
1340 2016-11-18  Jeremy Jones  <jeremyj@apple.com>
1341
1342         Add runtime flag to enable pointer lock. Enable pointer lock feature for mac.
1343         https://bugs.webkit.org/show_bug.cgi?id=163801
1344
1345         Reviewed by Simon Fraser.
1346
1347         Plumb through PointerLockEnabled setting.
1348
1349         * Configurations/FeatureDefines.xcconfig:
1350         * WebCoreSupport/WebChromeClient.mm:
1351         (WebChromeClient::requestPointerUnlock):
1352         * WebView/WebPreferenceKeysPrivate.h:
1353         * WebView/WebPreferences.mm:
1354         (-[WebPreferences pointerLockEnabled]):
1355         (-[WebPreferences setPointerLockEnabled:]):
1356         * WebView/WebPreferencesPrivate.h:
1357         * WebView/WebView.mm:
1358         (-[WebView _preferencesChanged:]):
1359
1360 2016-11-17  Dan Bernstein  <mitz@apple.com>
1361
1362         Try to fix some non-macOS builds.
1363
1364         * WebView/WebView.mm:
1365
1366 2016-11-16  Dave Hyatt  <hyatt@apple.com>
1367
1368         [CSS Parser] Add @supports, @keyframe and media query parsing options
1369         https://bugs.webkit.org/show_bug.cgi?id=164821
1370
1371         Reviewed by Sam Weinig and Zalan Bujtas.
1372
1373         Fix up the create call now that fallback descriptor syntax is gone.
1374
1375         * DOM/DOM.mm:
1376         (-[DOMHTMLLinkElement _mediaQueryMatches]):
1377
1378 2016-11-17  Saam Barati  <sbarati@apple.com>
1379
1380         Remove async/await compile time flag and enable tests
1381         https://bugs.webkit.org/show_bug.cgi?id=164828
1382         <rdar://problem/28639334>
1383
1384         Reviewed by Yusuke Suzuki.
1385
1386         * Configurations/FeatureDefines.xcconfig:
1387
1388 2016-11-17  Yusuke Suzuki  <utatane.tea@gmail.com>
1389
1390         [JSC] WTF::TemporaryChange with WTF::SetForScope
1391         https://bugs.webkit.org/show_bug.cgi?id=164761
1392
1393         Reviewed by Saam Barati.
1394
1395         * WebView/WebView.mm:
1396         (-[WebView updateTextTouchBar]):
1397
1398 2016-11-16  Yusuke Suzuki  <utatane.tea@gmail.com>
1399
1400         [ES6][WebCore] Change ES6_MODULES compile time flag to runtime flag
1401         https://bugs.webkit.org/show_bug.cgi?id=164827
1402
1403         Reviewed by Ryosuke Niwa.
1404
1405         * Configurations/FeatureDefines.xcconfig:
1406         * WebView/WebPreferenceKeysPrivate.h:
1407         * WebView/WebPreferences.mm:
1408         (+[WebPreferences initialize]):
1409         (-[WebPreferences es6ModulesEnabled]):
1410         (-[WebPreferences setES6ModulesEnabled:]):
1411         * WebView/WebPreferencesPrivate.h:
1412         * WebView/WebView.mm:
1413         (-[WebView _preferencesChanged:]):
1414
1415 2016-11-14  Alex Christensen  <achristensen@webkit.org>
1416
1417         Move SecurityOrigin::createFromDatabaseIdentifier to SecurityOriginData
1418         https://bugs.webkit.org/show_bug.cgi?id=164720
1419
1420         Reviewed by Brady Eidson.
1421
1422         * Storage/WebDatabaseManager.mm:
1423         (-[WebDatabaseManager origins]):
1424         (-[WebDatabaseManager databasesWithOrigin:]):
1425         (-[WebDatabaseManager deleteOrigin:]):
1426         (-[WebDatabaseManager deleteDatabase:withOrigin:]):
1427         * Storage/WebDatabaseManagerClient.h:
1428         * Storage/WebDatabaseManagerClient.mm:
1429         (DidModifyOriginData::dispatchToMainThread):
1430         (DidModifyOriginData::DidModifyOriginData):
1431         (WebDatabaseManagerClient::dispatchDidModifyOrigin):
1432         (WebDatabaseManagerClient::dispatchDidModifyDatabase):
1433         * Storage/WebDatabaseQuotaManager.mm:
1434         (-[WebDatabaseQuotaManager usage]):
1435         (-[WebDatabaseQuotaManager quota]):
1436         (-[WebDatabaseQuotaManager setQuota:]):
1437         * Storage/WebStorageManager.mm:
1438         (-[WebStorageManager origins]):
1439         (-[WebStorageManager deleteOrigin:]):
1440         * Storage/WebStorageTrackerClient.h:
1441         * Storage/WebStorageTrackerClient.mm:
1442         (WebStorageTrackerClient::dispatchDidModifyOrigin):
1443         * WebCoreSupport/WebSecurityOrigin.mm:
1444         (-[WebSecurityOrigin usage]):
1445         (-[WebSecurityOrigin quota]):
1446         (-[WebSecurityOrigin setQuota:]):
1447
1448 2016-11-13  Darin Adler  <darin@apple.com>
1449
1450         Fix exception handling in SQL database code, streamline and update code
1451         https://bugs.webkit.org/show_bug.cgi?id=164685
1452
1453         Reviewed by Sam Weinig.
1454
1455         * Storage/WebDatabaseManager.mm:
1456         (-[WebDatabaseManager origins]): Updated to use DatabaseTracker and pass
1457         a reference.
1458         (-[WebDatabaseManager databasesWithOrigin:]): Ditto.
1459         (-[WebDatabaseManager detailsForDatabase:withOrigin:]): Pass reference,
1460         but continue to use DatabaseManager.
1461         (-[WebDatabaseManager deleteOrigin:]): Use DatabaseTracker and pass a
1462         reference.
1463         (-[WebDatabaseManager deleteDatabase:withOrigin:]): Ditto.
1464
1465         * Storage/WebDatabaseManagerClient.h: Updated to take references.
1466         * Storage/WebDatabaseManagerClient.mm:
1467         (WebDatabaseManagerClient::WebDatabaseManagerClient): Initialize data
1468         members in the class definition.
1469         (DidModifyOriginData::dispatchToMainThread): Take references.
1470         (DidModifyOriginData::DidModifyOriginData): Ditto.
1471         (WebDatabaseManagerClient::dispatchDidModifyOrigin): Ditto.
1472         (WebDatabaseManagerClient::dispatchDidModifyDatabase): Ditto.
1473         (WebDatabaseManagerClient::dispatchDidAddNewOrigin): Ditto. Also use
1474         DatabaseTracker::singleton instead of tracker.
1475
1476         * Storage/WebDatabaseQuotaManager.mm:
1477         (-[WebDatabaseQuotaManager initWithOrigin:]): Reject nil pointer argument.
1478         (-[WebDatabaseQuotaManager usage]): Use reference instead of pointer.
1479         (-[WebDatabaseQuotaManager quota]): Ditto.
1480         (-[WebDatabaseQuotaManager setQuota:]): Ditto.
1481         * WebCoreSupport/WebSecurityOrigin.mm:
1482         (-[WebSecurityOrigin initWithURL:]): Tweaked code a bit.
1483         (-[WebSecurityOrigin usage]): Use DatabaseTracker and pass a reference.
1484         (-[WebSecurityOrigin quota]): Ditto.
1485         (-[WebSecurityOrigin setQuota:]): Ditto.
1486         * WebView/WebFrame.mm:
1487         (-[WebFrame _cacheabilityDictionary]): Pass a reference.
1488
1489 2016-11-12  Darin Adler  <darin@apple.com>
1490
1491         Remove a few assorted uses of ExceptionCode
1492         https://bugs.webkit.org/show_bug.cgi?id=164683
1493
1494         Reviewed by Chris Dumez.
1495
1496         * DOM/DOMDOMImplementation.mm:
1497         (-[DOMImplementation createDocumentType:publicId:systemId:]):
1498         Use raiseOnDOMError instead of much longer hand written equivalent.
1499         (-[DOMImplementation createDocument:qualifiedName:doctype:]): Ditto.
1500
1501         * DOM/DOMDocument.mm:
1502         (-[DOMDocument createEntityReference:]): Use raiseNotSupportedErrorException
1503         so we are not using a specific exception code.
1504
1505         * DOM/DOMHTMLOptionsCollection.mm:
1506         (-[DOMHTMLOptionsCollection add:index:]): Use raiseOnDOMError instead of
1507         much longer hand written equivalent.
1508         * DOM/DOMHTMLSelectElement.mm:
1509         (-[DOMHTMLSelectElement add:before:]): Ditto. Also removed unneeded return
1510         statement after calling a "no return" function.
1511
1512         * DOM/ExceptionHandlers.h: Removed overloads of raiseDOMException and
1513         raiseOnDOMError functions that take ExceptionCode; keep the ones that take
1514         Exception and ExceptionOr. Renamed the other overload of raiseDOMException
1515         to raiseDOMErrorException; it is only used as the non-inline implementation
1516         part of the inline raiseOnDOMError function.
1517         * DOM/ExceptionHandlers.mm:
1518         (raiseDOMErrorException): Renamed. Made the ExceptionCode overload be local
1519         to this source file instead of in the header.
1520         (raiseTypeErrorException): Updated for name change.
1521         (raiseNotSupportedErrorException): Added.
1522
1523 2016-11-11  Ryosuke Niwa  <rniwa@webkit.org>
1524
1525         Hovering over a slotted Text node clears hover state
1526         https://bugs.webkit.org/show_bug.cgi?id=164002
1527         <rdar://problem/29040471>
1528
1529         Reviewed by Simon Fraser.
1530
1531         * WebView/WebImmediateActionController.mm:
1532         (-[WebImmediateActionController performHitTestAtPoint:]):
1533
1534 2016-11-11  Wenson Hsieh  <wenson_hsieh@apple.com>
1535
1536         [WK2] autocorrect and autocapitalize attributes do not work in contenteditable elements
1537         https://bugs.webkit.org/show_bug.cgi?id=164538
1538         <rdar://problem/8418711>
1539
1540         Reviewed by Ryosuke Niwa.
1541
1542         Account for renaming HTMLElement::autocorrect to HTMLElement::shouldAutocorrect, as well as moving
1543         WebAutocapitalizeType to WebKit from WebCore. Additionally, moves the -autocorrect and -autocapitalize SPIs out
1544         of HTML(Input|Form|TextArea)ElementPrivate.h and into HTMLElementPrivate.h. This also means removing redundant
1545         code for interfacing with the unwrapped HTMLElement's autocorrect and autocapitalize attributes.
1546
1547         * DOM/DOMHTML.mm:
1548         (webAutocapitalizeType):
1549         (-[DOMHTMLInputElement _autocapitalizeType]):
1550         (-[DOMHTMLTextAreaElement _autocapitalizeType]):
1551         * DOM/DOMHTMLElement.mm:
1552         (-[DOMHTMLElement autocorrect]):
1553         (-[DOMHTMLElement setAutocorrect:]):
1554         (-[DOMHTMLElement autocapitalize]):
1555         (-[DOMHTMLElement setAutocapitalize:]):
1556         * DOM/DOMHTMLElementPrivate.h: Copied from Source/WebCore/html/Autocapitalize.h.
1557         * DOM/DOMHTMLFormElement.mm:
1558         (-[DOMHTMLFormElement autocorrect]): Deleted.
1559         (-[DOMHTMLFormElement setAutocorrect:]): Deleted.
1560         (-[DOMHTMLFormElement autocapitalize]): Deleted.
1561         (-[DOMHTMLFormElement setAutocapitalize:]): Deleted.
1562         * DOM/DOMHTMLInputElement.mm:
1563         (-[DOMHTMLInputElement autocorrect]): Deleted.
1564         (-[DOMHTMLInputElement setAutocorrect:]): Deleted.
1565         (-[DOMHTMLInputElement autocapitalize]): Deleted.
1566         (-[DOMHTMLInputElement setAutocapitalize:]): Deleted.
1567         * DOM/DOMHTMLInputElementPrivate.h:
1568         * DOM/DOMHTMLTextAreaElement.mm:
1569         (-[DOMHTMLTextAreaElement autocorrect]): Deleted.
1570         (-[DOMHTMLTextAreaElement setAutocorrect:]): Deleted.
1571         (-[DOMHTMLTextAreaElement autocapitalize]): Deleted.
1572         (-[DOMHTMLTextAreaElement setAutocapitalize:]): Deleted.
1573         * DOM/DOMHTMLTextAreaElementPrivate.h:
1574
1575         We need to import DOMHTMLElementPrivate.h here to avoid breaking UIKit. We should follow this up with a UIKit
1576         change to import DOMHTMLElementPrivate.h directly.
1577
1578         * DOM/DOMPrivate.h:
1579         * DOM/WebAutocapitalizeTypes.h: Copied from Tools/WebKitTestRunner/ios/UIKitSPI.h.
1580         * MigrateHeaders.make:
1581
1582 2016-11-11  Beth Dakin  <bdakin@apple.com>
1583
1584         Move to modern TouchBar methods
1585         https://bugs.webkit.org/show_bug.cgi?id=164655
1586         -and corresponding-
1587         rdar://problem/29226911
1588
1589         Reviewed by Wenson Hsieh.
1590
1591         customizationDefaultItemIdentifiers -> defaultItemIdentifiers
1592         itemIdentifiers -> defaultItemIdentifiers
1593         defaultItems -> templateItems
1594
1595         * WebView/WebView.mm:
1596         (-[WebView _plainTextTouchBarDefaultItemIdentifiers]):
1597         (-[WebView _richTextTouchBarDefaultItemIdentifiers]):
1598         (-[WebView setUpTextTouchBar:]):
1599         (-[WebView updateTextTouchBar]):
1600         (-[WebView _plainTextTouchBarCustomizationDefaultItemIdentifiers]): Deleted.
1601         (-[WebView _richTextTouchBarCustomizationDefaultItemIdentifiers]): Deleted.
1602
1603 2016-11-11  Darin Adler  <darin@apple.com>
1604
1605         Move Node from ExceptionCode to ExceptionOr
1606         https://bugs.webkit.org/show_bug.cgi?id=164515
1607
1608         Reviewed by Sam Weinig.
1609
1610         * DOM/DOMHTMLSelectElement.mm:
1611         (-[DOMHTMLSelectElement remove:]): Call remove instead of removeByIndex
1612         now that it was renamed.
1613         * DOM/DOMNode.mm:
1614         (-[DOMNode setNodeValue:]): Updated exception handling.
1615         (-[DOMNode setPrefix:]): Ditto.
1616         (-[DOMNode setTextContent:]): Ditto.
1617         (-[DOMNode insertBefore:refChild:]): Ditto.
1618         (-[DOMNode replaceChild:oldChild:]): Ditto.
1619         (-[DOMNode removeChild:]): Ditto.
1620         (-[DOMNode appendChild:]): Ditto.
1621         (-[DOMNode cloneNode:]): Ditto.
1622
1623 2016-11-11  Beth Dakin  <bdakin@apple.com>
1624
1625         Get touch bar code building for open source builds
1626         https://bugs.webkit.org/show_bug.cgi?id=164610
1627
1628         Reviewed by Wenson Hsieh.
1629
1630         * WebKitPrefix.h:
1631
1632 2016-11-10  Alex Christensen  <achristensen@webkit.org>
1633
1634         Fix assertion after r208534.
1635         https://bugs.webkit.org/show_bug.cgi?id=160497
1636
1637         * WebView/WebView.mm:
1638         (-[WebView _commonInitializationWithFrameName:groupName:]):
1639         (WebInstallMemoryPressureHandler):
1640         WebInstallMemoryPressureHandler can be called before [WebView initWithFrame:frameName:groupName:]
1641         When this happens, we should use the same std::once_flag to make sure we install the MemoryPressureHandler::singleton
1642         only once, otherwise we get an assertion !m_installed in MemoryPressureHandler::setLowMemoryHandler.
1643
1644 2016-11-10  Alex Christensen  <achristensen@webkit.org>
1645
1646         Move SecurityOrigin::databaseIdentifier() to SecurityOriginData
1647         https://bugs.webkit.org/show_bug.cgi?id=164573
1648
1649         Reviewed by Brady Eidson.
1650
1651         * WebCoreSupport/WebSecurityOrigin.mm:
1652         (-[WebSecurityOrigin databaseIdentifier]):
1653
1654 2016-10-14  Carlos Garcia Campos  <cgarcia@igalia.com>
1655
1656         MemoryPressureHandler shouldn't know how to release WebCore memory
1657         https://bugs.webkit.org/show_bug.cgi?id=160497
1658
1659         Reviewed by Michael Catanzaro.
1660
1661         Set the low memory handler before installing the memory pressure handler.
1662
1663         * WebView/WebView.mm:
1664         (-[WebView _commonInitializationWithFrameName:groupName:]):
1665
1666 2016-11-09  Ryosuke Niwa  <rniwa@webkit.org>
1667
1668         WebHTMLView's _attributeStringFromDOMRange should use HTMLConverter instead of NSAttributedString's _initWithDOMRange
1669         https://bugs.webkit.org/show_bug.cgi?id=164501
1670         <rdar://problem/29152282>
1671
1672         Reviewed by Sam Weinig.
1673
1674         Align what [WebHTMLView attributedString] returns to what would be used on copy & paste by using HTMLConverter
1675         instead of _initWithDOMRange in [WebHTMLView _attributeStringFromDOMRange].
1676
1677         * WebView/WebHTMLView.mm:
1678         (-[WebHTMLView _attributedStringFromDOMRange:]): Renamed from _attributeStringFromDOMRange.
1679         (-[WebHTMLView attributedString]):
1680         (-[WebHTMLView selectedAttributedString]):
1681         (-[WebHTMLView selectedString]): Moved to reduce the number of occurrences of the if-defs.
1682
1683 2016-11-04  Brent Fulgham  <bfulgham@apple.com>
1684
1685         Local HTML should be blocked from localStorage access unless "Disable Local File Restrictions" is checked
1686         https://bugs.webkit.org/show_bug.cgi?id=155185
1687         <rdar://problem/11101440>
1688
1689         Reviewed by Brady Eidson.
1690
1691         Provide SPI to access the new quirk for localStorage. The quirk defaults to 'on'. When active, this
1692         quirk says that localStorage access should be granted, without needing to grant universal file access.
1693
1694         If the quirk is turned off, then localStorage is blocked unless the WebKit client explicitly
1695         grants universal file access.
1696
1697         * WebView/WebPreferenceKeysPrivate.h:
1698         * WebView/WebPreferences.mm:
1699         (-[WebPreferences needsLocalStorageQuirk]): Added.
1700         (-[WebPreferences setNeedsLocalStorageQuirk:]): Added.
1701         * WebView/WebPreferencesPrivate.h:
1702         * WebView/WebView.mm:
1703         (-[WebView _preferencesChanged:]): Honor the new localStorage quirk.
1704
1705 2016-11-09  Alex Christensen  <achristensen@webkit.org>
1706
1707         Clean up Storage code
1708         https://bugs.webkit.org/show_bug.cgi?id=164562
1709
1710         Reviewed by Brady Eidson.
1711
1712         * Storage/WebStorageManager.mm:
1713         (-[WebStorageManager origins]):
1714         (-[WebStorageManager deleteAllOrigins]):
1715         (-[WebStorageManager deleteOrigin:]):
1716         (-[WebStorageManager diskUsageForOrigin:]):
1717         (-[WebStorageManager syncLocalStorage]):
1718         (-[WebStorageManager syncFileSystemAndTrackerDatabase]):
1719         (+[WebStorageManager setStorageDatabaseIdleInterval:]):
1720         (+[WebStorageManager closeIdleLocalStorageDatabases]):
1721         (WebKitInitializeStorageIfNecessary):
1722         * WebView/WebView.mm:
1723         (+[WebView _applicationWillTerminate]):
1724
1725 2016-11-09  Beth Dakin  <bdakin@apple.com>
1726
1727         Another attempted build fix.
1728
1729         * WebView/WebView.mm:
1730
1731 2016-11-09  Beth Dakin  <bdakin@apple.com>
1732
1733         Attempted build fix.
1734
1735         * WebView/WebView.mm:
1736
1737 2016-11-09  Darin Adler  <darin@apple.com>
1738
1739         Move Range from ExceptionCode to ExceptionOr
1740         https://bugs.webkit.org/show_bug.cgi?id=164457
1741
1742         Reviewed by Alex Christensen.
1743
1744         * DOM/DOMRange.mm:
1745         (-[DOMRange setStart:offset:]): Updated exception handling.
1746         (-[DOMRange setEnd:offset:]): Ditto.
1747         (-[DOMRange setStartBefore:]): Ditto.
1748         (-[DOMRange setStartAfter:]): Ditto.
1749         (-[DOMRange setEndBefore:]): Ditto.
1750         (-[DOMRange setEndAfter:]): Ditto.
1751         (-[DOMRange selectNode:]): Ditto.
1752         (-[DOMRange selectNodeContents:]): Ditto.
1753         (-[DOMRange compareBoundaryPoints:sourceRange:]): Ditto.
1754         (-[DOMRange deleteContents]): Ditto.
1755         (-[DOMRange extractContents]): Ditto.
1756         (-[DOMRange cloneContents]): Ditto.
1757         (-[DOMRange insertNode:]): Ditto.
1758         (-[DOMRange surroundContents:]): Ditto.
1759         (-[DOMRange createContextualFragment:]): Ditto.
1760         (-[DOMRange compareNode:]): Ditto.
1761         (-[DOMRange intersectsNode:]): Ditto.
1762         (-[DOMRange comparePoint:offset:]): Ditto.
1763         (-[DOMRange isPointInRange:offset:]): Ditto.
1764         (-[DOMRange expand:]): Ditto.
1765         * WebView/WebFrame.mm:
1766         (-[WebFrame _documentFragmentWithMarkupString:baseURLString:]): Ditto.
1767         (-[WebFrame _smartDeleteRangeForProposedRange:]): Deleted.
1768         This function was incorrectly implemented (set both start and end of
1769         the range to the computed start), not declared in any header file,
1770         not used anywhere inside WebKit, and I also could not find a use of it
1771         in outside-WebKit Apple code.
1772         * mac/DOM/DOMUIKitExtensions.mm:
1773         (-[DOMRange move:inDirection:]): Ditto.
1774         (-[DOMRange extend:inDirection:]): Ditto.
1775
1776 2016-11-09  Darin Adler  <darin@apple.com>
1777
1778         Move EventTarget from ExceptionCode to ExceptionOr
1779         https://bugs.webkit.org/show_bug.cgi?id=164465
1780
1781         Reviewed by Youenn Fablet.
1782
1783         * DOM/DOMNode.mm:
1784         (-[DOMNode dispatchEvent:]): Updated exception handling.
1785
1786 2016-11-09  Chris Dumez  <cdumez@apple.com>
1787
1788         [Mac] Stop using deprecated AppKit enumeration values
1789         https://bugs.webkit.org/show_bug.cgi?id=164494
1790
1791         Reviewed by Darin Adler.
1792
1793         Stop using deprecated AppKit enumeration values.
1794
1795         * Carbon/CarbonWindowAdapter.mm:
1796         (-[CarbonWindowAdapter initWithCarbonWindowRef:takingOwnership:disableOrdering:carbon:]):
1797         (-[CarbonWindowAdapter sendSuperEvent:]):
1798         * Plugins/Hosted/NetscapePluginHostProxy.mm:
1799         (WebKit::NetscapePluginHostProxy::beginModal):
1800         * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
1801         (WebKit::NetscapePluginInstanceProxy::syntheticKeyDownWithCommandModifier):
1802         * Plugins/Hosted/WebHostedNetscapePluginView.mm:
1803         (-[WebHostedNetscapePluginView drawRect:]):
1804         * Plugins/WebNetscapePluginEventHandlerCocoa.mm:
1805         (WebNetscapePluginEventHandlerCocoa::syntheticKeyDownWithCommandModifier):
1806         * WebCoreSupport/PopupMenuMac.mm:
1807         (PopupMenuMac::populate):
1808         (PopupMenuMac::show):
1809         * WebCoreSupport/WebContextMenuClient.mm:
1810         (WebContextMenuClient::showContextMenu):
1811         * WebCoreSupport/WebFrameLoaderClient.mm:
1812         (WebFrameLoaderClient::actionDictionary):
1813         * WebCoreSupport/WebInspectorClient.mm:
1814         (WebInspectorFrontendClient::canAttach):
1815         (-[WebInspectorWindowController window]):
1816         * WebInspector/WebNodeHighlight.mm:
1817         (-[WebNodeHighlight initWithTargetView:inspectorController:]):
1818         * WebView/WebFrameView.mm:
1819         (-[WebFrameView keyDown:keyDown:]):
1820         * WebView/WebFullScreenController.mm:
1821         (-[WebFullScreenController init]):
1822         (createBackgroundFullscreenWindow):
1823         * WebView/WebHTMLView.mm:
1824         (-[WebHTMLView _postFakeMouseMovedEventForFlagsChangedEvent:]):
1825         (-[WebHTMLView _setMouseDownEvent:_setMouseDownEvent:]):
1826         (-[WebHTMLView _updateMouseoverWithFakeEvent]):
1827         (isQuickLookEvent):
1828         (-[WebHTMLView hitTest:]):
1829         (-[WebHTMLView _sendToolTipMouseExited]):
1830         (-[WebHTMLView _sendToolTipMouseEntered]):
1831         (mouseEventIsPartOfClickOrDrag):
1832         (-[WebHTMLView _updateMouseoverWithEvent:]):
1833         (-[WebHTMLView _autoscroll]):
1834         (-[WebHTMLView acceptsFirstResponder]):
1835         (-[WebHTMLView viewDidMoveToWindow]):
1836         (-[WebHTMLView mouseDown:mouseDown:]):
1837         (currentKeyboardEvent):
1838         (-[WebHTMLView _handleStyleKeyEquivalent:]):
1839         (-[WebHTMLView _interpretKeyEvent:savingCommands:]):
1840         * WebView/WebPDFView.mm:
1841         (-[WebPDFView hitTest:]):
1842         (-[WebPDFView PDFViewWillClickOnLink:withURL:]):
1843         (-[WebPDFView _fakeKeyEventWithFunctionKey:]):
1844         * WebView/WebTextCompletionController.mm:
1845         (-[WebTextCompletionController _buildUI]):
1846         (-[WebTextCompletionController _placePopupWindow:]):
1847         * WebView/WebView.mm:
1848         (-[WebView applicationFlags:]):
1849
1850 2016-11-09  Beth Dakin  <bdakin@apple.com>
1851
1852         Support TouchBar in WebKit
1853         https://bugs.webkit.org/show_bug.cgi?id=164437
1854         -and corresponding-
1855         rdar://problem/28876524
1856
1857         Reviewed by Darin Adler.
1858
1859         * WebCoreSupport/WebEditorClient.mm:
1860         (WebEditorClient::respondToChangedSelection):
1861         (WebEditorClient::updateEditorStateAfterLayoutIfEditabilityChanged):
1862         * WebView/WebHTMLView.mm:
1863         (-[WebHTMLView candidateListTouchBarItem]):
1864         * WebView/WebView.mm:
1865         (-[_WebTextListTouchBarViewController initWithWebView:]):
1866         (-[_WebTextListTouchBarViewController _selectList:]):
1867         (-[_WebTextListTouchBarViewController setCurrentListType:]):
1868         (-[WebTextTouchBarItemController initWithWebView:]):
1869         (-[WebTextTouchBarItemController itemForIdentifier:]):
1870         (-[WebTextTouchBarItemController webTextListTouchBarViewController]):
1871         (-[WebTextTouchBarItemController setTextIsBold:]):
1872         (-[WebTextTouchBarItemController setTextIsItalic:]):
1873         (-[WebTextTouchBarItemController setTextIsUnderlined:]):
1874         (-[WebTextTouchBarItemController _webChangeTextStyle:]):
1875         (-[WebTextTouchBarItemController setCurrentTextAlignment:]):
1876         (-[WebTextTouchBarItemController _webChangeTextAlignment:]):
1877         (-[WebTextTouchBarItemController textColor]):
1878         (-[WebTextTouchBarItemController setTextColor:]):
1879         (-[WebTextTouchBarItemController _webChangeColor:]):
1880         (-[WebTextTouchBarItemController textListViewController]):
1881         (-[WebView _commonInitializationWithFrameName:groupName:]):
1882         (-[WebView showCandidates:forString:inRect:forSelectedRange:view:completionHandler:]):
1883         (-[WebView shouldRequestCandidates]):
1884         (-[WebView forceRequestCandidatesForTesting]):
1885         (-[WebView makeTouchBar]):
1886         (-[WebView touchBar:makeItemForIdentifier:]):
1887         (textCheckingResultFromNSTextCheckingResult):
1888         (-[WebView candidateListTouchBarItem:endSelectingCandidateAtIndex:]):
1889         (-[WebView candidateListTouchBarItem:changedCandidateListVisibility:]):
1890         (-[WebView _setUpPlaybackControlsManagerForMediaElement:]):
1891         (-[WebView _clearPlaybackControlsManager]):
1892         (-[WebView _dismissTextTouchBarPopoverItemWithIdentifier:]):
1893         (-[WebView _textTouchBarCustomizationAllowedIdentifiers]):
1894         (-[WebView _plainTextTouchBarCustomizationDefaultItemIdentifiers]):
1895         (-[WebView _richTextTouchBarCustomizationDefaultItemIdentifiers]):
1896         (-[WebView touchBarDidExitCustomization:]):
1897         (-[WebView touchBarWillEnterCustomization:]):
1898         (-[WebView didChangeAutomaticTextCompletion:]):
1899         (-[WebView setUpTextTouchBar:]):
1900         (-[WebView _isRichlyEditable]):
1901         (-[WebView textTouchBar]):
1902         (-[WebView updateTextTouchBar]):
1903         (-[WebView updateMediaTouchBar]):
1904         (-[WebView updateTouchBar]):
1905         (-[WebView prepareForMouseDown]):
1906         (-[WebView prepareForMouseUp]):
1907         (-[WebView webViewAdditionsWillDestroyView]):
1908         (-[WebView candidateList]):
1909         (-[WebView updateWebViewAdditions]): Deleted.
1910         * WebView/WebViewData.h:
1911         * WebView/WebViewInternal.h:
1912         * WebView/WebViewPrivate.h:
1913
1914 2016-11-04  Wenson Hsieh  <wenson_hsieh@apple.com>
1915
1916         Safari does not emit composition end if blurred for dead key / Japanese IME
1917         https://bugs.webkit.org/show_bug.cgi?id=164369
1918         <rdar://problem/29050439>
1919
1920         Reviewed by Ryosuke Niwa.
1921
1922         When canceling a composition, make sure that we clear the system IME state.
1923
1924         * WebCoreSupport/WebEditorClient.h:
1925         * WebCoreSupport/WebEditorClient.mm:
1926         (WebEditorClient::canceledComposition):
1927
1928 2016-11-04  Said Abou-Hallawa  <sabouhallawa@apple.com>
1929
1930         Add a setting and preferences to enable/disable async image decoding
1931         https://bugs.webkit.org/show_bug.cgi?id=164417
1932
1933         Reviewed by Simon Fraser.
1934
1935         Hook up the asyncImageDecodingEnabled setting for WebKit1.
1936
1937         * WebView/WebPreferenceKeysPrivate.h:
1938         * WebView/WebPreferences.mm:
1939         (+[WebPreferences initialize]):
1940         (-[WebPreferences asyncImageDecodingEnabled]):
1941         (-[WebPreferences setAsyncImageDecodingEnabled:]):
1942         * WebView/WebPreferencesPrivate.h:
1943         * WebView/WebView.mm:
1944         (-[WebView _preferencesChanged:]):
1945
1946 2016-11-01  Alex Christensen  <achristensen@webkit.org>
1947
1948         Remove PassRefPtr from DumpRenderTree
1949         https://bugs.webkit.org/show_bug.cgi?id=164307
1950
1951         Reviewed by Sam Weinig.
1952
1953         * WebView/WebGeolocationPosition.mm:
1954         (-[WebGeolocationPosition initWithGeolocationPosition:]):
1955
1956 2016-11-02  Romain Bellessort  <romain.bellessort@crf.canon.fr>
1957
1958         [Readable Streams API] Enable creation of ReadableByteStreamController
1959         https://bugs.webkit.org/show_bug.cgi?id=164014
1960
1961         Reviewed by Youenn Fablet.
1962
1963         Added flag for the byte stream part of Readable Streams API.
1964
1965         * Configurations/FeatureDefines.xcconfig:
1966
1967 2016-11-01  Ryosuke Niwa  <rniwa@webkit.org>
1968
1969         Remove CUSTOM_ELEMENTS build flag
1970         https://bugs.webkit.org/show_bug.cgi?id=164267
1971
1972         Reviewed by Antti Koivisto.
1973
1974         Removed the build flag.
1975
1976         * Configurations/FeatureDefines.xcconfig:
1977         * WebView/WebPreferences.mm:
1978         (+[WebPreferences initialize]):
1979         * WebView/WebView.mm:
1980         (-[WebView _preferencesChanged:]):
1981
1982 2016-11-01  Eric Carlson  <eric.carlson@apple.com>
1983
1984         [MediaStream] restrict media capture secure connections
1985         https://bugs.webkit.org/show_bug.cgi?id=164234
1986         <rdar://problem/28944906>
1987
1988         Reviewed by Alex Christensen.
1989
1990         * WebView/WebPreferenceKeysPrivate.h:
1991         * WebView/WebPreferences.mm:
1992         (+[WebPreferences initialize]): Initialize WebKitMediaCaptureRequiresSecureConnectionPreferenceKey.
1993         (-[WebPreferences mediaCaptureRequiresSecureConnection]): New.
1994         (-[WebPreferences setMediaCaptureRequiresSecureConnection:]): New.
1995         * WebView/WebPreferencesPrivate.h:
1996
1997         * WebView/WebView.mm:
1998         (-[WebView _preferencesChanged:]): Sync mediaCaptureRequiresSecureConnection.
1999
2000 2016-10-29  Filip Pizlo  <fpizlo@apple.com>
2001
2002         JSC should support SharedArrayBuffer
2003         https://bugs.webkit.org/show_bug.cgi?id=163986
2004
2005         Reviewed by Keith Miller.
2006         
2007         Support the RuntimeFlag.
2008
2009         * WebView/WebPreferencesPrivate.h:
2010
2011 2016-10-31  Wenson Hsieh  <wenson_hsieh@apple.com>
2012
2013         [WK1] Candidate visibility should not update as a result of selection during a dictionary lookup
2014         https://bugs.webkit.org/show_bug.cgi?id=164236
2015         <rdar://problem/28747712>
2016
2017         Reviewed by Beth Dakin.
2018
2019         See WebCore ChangeLog for more detail. Sets the Editor's isGettingDictionaryPopupInfo state to true during a
2020         dictionary lookup.
2021
2022         * WebCoreSupport/WebEditorClient.mm:
2023         (WebEditorClient::respondToChangedSelection):
2024         * WebView/WebImmediateActionController.mm:
2025         (+[WebImmediateActionController _dictionaryPopupInfoForRange:inFrame:withLookupOptions:indicatorOptions:transition:]):
2026
2027 2016-10-31  Darin Adler  <darin@apple.com>
2028
2029         Move ChildNode and ParentNode from ExceptionCode to Exception, add support for ExceptionOr<T&>
2030         https://bugs.webkit.org/show_bug.cgi?id=164214
2031
2032         Reviewed by Alex Christensen.
2033
2034         * DOM/DOMCSSPrimitiveValue.mm:
2035         (-[DOMCSSPrimitiveValue getCounterValue]): Updated since return value
2036         is a reference now.
2037         (-[DOMCSSPrimitiveValue getRectValue]): Ditto.
2038
2039         * DOM/DOMDocument.mm:
2040         (-[DOMDocument querySelector:]): Updated exception handling.
2041         (-[DOMDocument querySelectorAll:]): Ditto.
2042         * DOM/DOMDocumentFragment.mm:
2043         (-[DOMDocumentFragment querySelector:]): Ditto.
2044         (-[DOMDocumentFragment querySelectorAll:]): Ditto.
2045         * DOM/DOMElement.mm:
2046         (-[DOMElement querySelector:]): Ditto.
2047         (-[DOMElement querySelectorAll:]): Ditto.
2048
2049 2016-10-31  Darin Adler  <darin@apple.com>
2050
2051         Convert Document from ExceptionCode to Exception
2052         https://bugs.webkit.org/show_bug.cgi?id=164212
2053
2054         Reviewed by Alex Christensen.
2055
2056         * DOM/DOMDocument.mm:
2057         (-[DOMDocument setXmlVersion:]): Updated exception handling.
2058         (-[DOMDocument cookie]): Ditto.
2059         (-[DOMDocument setCookie:]): Ditto.
2060         (-[DOMDocument setBody:]): Ditto.
2061         (-[DOMDocument createElement:]): Ditto.
2062         (-[DOMDocument createCDATASection:]): Ditto.
2063         (-[DOMDocument createProcessingInstruction:data:]): Ditto.
2064         (-[DOMDocument createAttribute:]): Ditto.
2065         (-[DOMDocument createEntityReference:]): Ditto.
2066         (-[DOMDocument importNode:deep:]): Ditto.
2067         (-[DOMDocument createElementNS:qualifiedName:]): Ditto.
2068         (-[DOMDocument createAttributeNS:qualifiedName:]): Ditto.
2069         (-[DOMDocument getElementsByTagNameNS:localName:]): Ditto.
2070         (-[DOMDocument adoptNode:]): Ditto.
2071         (-[DOMDocument createEvent:]): Ditto.
2072
2073 2016-10-30  Darin Adler  <darin@apple.com>
2074
2075         Move Element, NamedNodeMap, and DOMStringMap from ExceptionCode to Exception
2076         https://bugs.webkit.org/show_bug.cgi?id=164206
2077
2078         Reviewed by Chris Dumez.
2079
2080         * DOM/DOMElement.mm:
2081         (-[DOMElement setInnerHTML:]): Updated exception handling.
2082         (-[DOMElement setOuterHTML:]): Ditto.
2083         (-[DOMElement setAttribute:value:]): Ditto.
2084         (-[DOMElement setAttributeNode:]): Ditto.
2085         (-[DOMElement removeAttributeNode:]): Ditto.
2086         (-[DOMElement setAttributeNS:qualifiedName:value:]): Ditto.
2087         (-[DOMElement setAttributeNodeNS:]): Ditto.
2088         (-[DOMElement matches:]): Ditto.
2089         (-[DOMElement closest:]): Ditto.
2090         (-[DOMElement webkitMatchesSelector:]): Ditto.
2091         * DOM/DOMHTMLElement.mm:
2092         (-[DOMHTMLElement insertAdjacentElement:element:]): Ditto.
2093         (-[DOMHTMLElement insertAdjacentHTML:html:]): Ditto.
2094         (-[DOMHTMLElement insertAdjacentText:text:]): Ditto.
2095         * DOM/DOMNamedNodeMap.mm:
2096         (-[DOMNamedNodeMap setNamedItem:]): Ditto.
2097         (-[DOMNamedNodeMap removeNamedItem:]): Ditto.
2098         (-[DOMNamedNodeMap setNamedItemNS:]): Ditto.
2099         (-[DOMNamedNodeMap removeNamedItemNS:localName:]): Ditto.
2100
2101 2016-10-29  Darin Adler  <darin@apple.com>
2102
2103         Convert more of DOM from ExceptionCode to Exception
2104         https://bugs.webkit.org/show_bug.cgi?id=164173
2105
2106         Reviewed by Ryosuke Niwa.
2107
2108         * DOM/DOMCharacterData.mm:
2109         (-[DOMCharacterData substringData:length:]): Updated since this
2110         now uses ExceptionOr.
2111         (-[DOMCharacterData insertData:data:]): Ditto.
2112         (-[DOMCharacterData deleteData:length:]): Ditto.
2113         (-[DOMCharacterData replaceData:length:data:]): Ditto.
2114         * DOM/DOMText.mm:
2115         (-[DOMText splitText:]): Ditto.
2116         (-[DOMText replaceWholeText:]): Removed unneeded exception code
2117         handling from function that does not throw an exception.
2118
2119 2016-10-28  Darin Adler  <darin@apple.com>
2120
2121         Move all classes in the HTML directory from ExceptionCode to Exception
2122         https://bugs.webkit.org/show_bug.cgi?id=163876
2123
2124         Reviewed by Sam Weinig.
2125
2126         * DOM/DOMCharacterData.mm:
2127         (-[DOMCharacterData remove]): Updated exception handling.
2128         * DOM/DOMDOMTokenList.mm:
2129         (-[DOMDOMTokenList toggle:force:]): Ditto.
2130         * DOM/DOMDocumentType.mm:
2131         (-[DOMDocumentType remove]): Ditto.
2132         * DOM/DOMElement.mm:
2133         (-[DOMElement remove]): Ditto.
2134         * DOM/DOMHTML.mm:
2135         (-[DOMHTMLInputElement setValueAsNumberWithChangeEvent:]): Ditto.
2136         * DOM/DOMHTMLCanvasElement.mm:
2137         (-[DOMHTMLCanvasElement toDataURL:]): Ditto.
2138         * DOM/DOMHTMLElement.mm:
2139         (-[DOMHTMLElement setInnerText:]): Ditto.
2140         (-[DOMHTMLElement setOuterText:]): Ditto.
2141         (-[DOMHTMLElement setContentEditable:]): Ditto.
2142         * DOM/DOMHTMLInputElement.mm:
2143         (-[DOMHTMLInputElement setMaxLength:]): Ditto.
2144         (-[DOMHTMLInputElement setValueAsDate:]): Ditto.
2145         (-[DOMHTMLInputElement setValueAsNumber:]): Ditto.
2146         (-[DOMHTMLInputElement stepUp:]): Ditto.
2147         (-[DOMHTMLInputElement stepDown:]): Ditto.
2148         (-[DOMHTMLInputElement setRangeText:]): Ditto.
2149         (-[DOMHTMLInputElement setRangeText:start:end:selectionMode:]): Ditto.
2150         * DOM/DOMHTMLMarqueeElement.mm:
2151         (-[DOMHTMLMarqueeElement setLoop:]): Ditto.
2152         * DOM/DOMHTMLMediaElement.mm:
2153         (-[DOMHTMLMediaElement setCurrentTime:]): Ditto.
2154         (-[DOMHTMLMediaElement setVolume:]): Ditto.
2155         * DOM/DOMHTMLOptionsCollection.mm:
2156         (-[DOMHTMLOptionsCollection setLength:]): Ditto.
2157         * DOM/DOMHTMLTableElement.mm:
2158         (-[DOMHTMLTableElement setCaption:]): Ditto.
2159         (-[DOMHTMLTableElement setTHead:]): Ditto.
2160         (-[DOMHTMLTableElement setTFoot:]): Ditto.
2161         (-[DOMHTMLTableElement insertRow:]): Ditto.
2162         (-[DOMHTMLTableElement deleteRow:]): Ditto.
2163         * DOM/DOMHTMLTableRowElement.mm:
2164         (-[DOMHTMLTableRowElement insertCell:]): Ditto.
2165         (-[DOMHTMLTableRowElement deleteCell:]): Ditto.
2166         * DOM/DOMHTMLTableSectionElement.mm:
2167         (-[DOMHTMLTableSectionElement insertRow:]): Ditto.
2168         (-[DOMHTMLTableSectionElement deleteRow:]): Ditto.
2169         * DOM/DOMHTMLTextAreaElement.mm:
2170         (-[DOMHTMLTextAreaElement setMaxLength:]): Ditto.
2171         (-[DOMHTMLTextAreaElement setRangeText:]): Ditto.
2172         (-[DOMHTMLTextAreaElement setRangeText:start:end:selectionMode:]): Ditto.
2173         * DOM/DOMHTMLVideoElement.mm:
2174         (-[DOMHTMLVideoElement webkitEnterFullscreen]): Ditto.
2175         (-[DOMHTMLVideoElement webkitEnterFullScreen]): Changed to call the other named
2176         version (lowercase S) instead of repeating the logic from that method.
2177         (-[DOMHTMLVideoElement webkitExitFullScreen]): Ditto.
2178         * DOM/DOMTimeRanges.mm:
2179         (-[DOMTimeRanges start:]): Updated exception handling.
2180         (-[DOMTimeRanges end:]): Ditto.
2181
2182 2016-10-27  Chris Dumez  <cdumez@apple.com>
2183
2184         Regression(r203601): Caused crashes in iBooks
2185         https://bugs.webkit.org/show_bug.cgi?id=164093
2186         <rdar://problem/28745634>
2187
2188         Reviewed by Darin Adler.
2189
2190         Restore pre-r203601 behavior when calling [DOMNode compareDocumentPosition:nil],
2191         which was to return Node::DOCUMENT_POSITION_DISCONNECTED.
2192
2193         * DOM/DOMNode.mm:
2194         (-[DOMNode compareDocumentPosition:]):
2195
2196 2016-10-27  Wenson Hsieh  <wenson_hsieh@apple.com>
2197
2198         Support "insertFromDrop" and "deleteByDrag" for the InputEvent spec
2199         https://bugs.webkit.org/show_bug.cgi?id=163948
2200         <rdar://problem/28921433>
2201
2202         Reviewed by Darin Adler.
2203
2204         Add support for new drag and drop-related EditAction enum values.
2205
2206         * WebCoreSupport/WebEditorClient.mm:
2207         (undoNameForEditAction):
2208
2209 2016-10-27  Dan Bernstein  <mitz@apple.com>
2210
2211         Reapplied the configuration changes from r207934 without breaking iOS builds.
2212
2213         * Configurations/Base.xcconfig:
2214         * Configurations/WebKitLegacy.xcconfig:
2215
2216 2016-10-27  Dan Bernstein  <mitz@apple.com>
2217
2218         Reverted the configuration changes from r207934 because they broke iOS builds not using the Apple-internal SDK.
2219
2220         * Configurations/Base.xcconfig:
2221         * Configurations/WebKitLegacy.xcconfig:
2222
2223 2016-10-26  Dan Bernstein  <mitz@apple.com>
2224
2225         [Xcode] WebKit fails to build when CLANG_WARN_DOCUMENTATION_COMMENTS is enabled
2226         https://bugs.webkit.org/show_bug.cgi?id=164048
2227
2228         Reviewed by Tim Horton.
2229
2230         * Configurations/Base.xcconfig: Enabled CLANG_WARN_DOCUMENTATION_COMMENTS.
2231         * Configurations/WebKitLegacy.xcconfig: Made the compiler treat the icu headers as system
2232           headers.
2233
2234         * History/WebBackForwardList.h: Fixed parameter name in @param entry.
2235         * Misc/WebDownload.h: Removed empty entries.
2236         * Misc/WebIconDatabase.h: Remove incorrect @param entries.
2237         * Misc/WebQuotaManager.h: Added missing parameter names in @param entries.
2238         * WebView/WebFrameLoadDelegate.h: Corrected parameter names in @param entries.
2239         * WebView/WebFrameViewPrivate.h: Changed incorrect @result to @abstract.
2240         * WebView/WebPolicyDelegate.h: Fixed parameter name and removed incorrect @param entries.
2241         * WebView/WebPreferences.h: Changed @method to @property in a couple of places.
2242         * WebView/WebResourceLoadDelegate.h: Fixed parameter names.
2243         * WebView/WebUIDelegate.h: Filled in two empty @param entries. Added missing parameter name,
2244           Fixed a typo and removed empty @discussion entry. Fixed some parameter names.
2245         * WebView/WebUIDelegatePrivate.h: Fixed parameter names.
2246         * WebView/WebView.h: Changed @method to @property in a couple of places.
2247         * WebView/WebViewPrivate.h: Fixed parameter names, changed incorrect @result to @abstract.
2248
2249 2016-10-26  Brian Burg  <bburg@apple.com>
2250
2251         Web Inspector: remove unused bool return value from FrontendChannel::sendMessageToFrontend
2252         https://bugs.webkit.org/show_bug.cgi?id=164046
2253
2254         Reviewed by Joseph Pecoraro.
2255
2256         * WebCoreSupport/WebInspectorClient.h:
2257
2258 2016-10-21  Alex Christensen  <achristensen@webkit.org>
2259
2260         URL::port should return Optional<uint16_t>
2261         https://bugs.webkit.org/show_bug.cgi?id=163806
2262
2263         Reviewed by Darin Adler.
2264
2265         * WebCoreSupport/WebSecurityOrigin.mm:
2266         (-[WebSecurityOrigin port]):
2267
2268 2016-10-24  Dave Hyatt  <hyatt@apple.com>
2269
2270         Remove CSSCharsetRule from the CSS OM
2271         https://bugs.webkit.org/show_bug.cgi?id=163891
2272
2273         Reviewed by Darin Adler.
2274
2275         * DOM/DOMCSSCharsetRule.mm:
2276         (-[DOMCSSCharsetRule encoding]):
2277
2278 2016-10-24  Youenn Fablet  <youenn@apple.com>
2279
2280         Activate WEB_RTC compilation flags for Mac bots
2281         https://bugs.webkit.org/show_bug.cgi?id=163886
2282
2283         Reviewed by Eric Carlson.
2284
2285         * Configurations/FeatureDefines.xcconfig:
2286
2287 2016-10-23  Chris Dumez  <cdumez@apple.com>
2288
2289         addEventListener() / removeEventListener() should use a union for last parameter
2290         https://bugs.webkit.org/show_bug.cgi?id=163863
2291
2292         Reviewed by Darin Adler.
2293
2294         Cast BOOL to bool to help to compiler construct the new variant-type parameter.
2295
2296         * DOM/DOMNode.mm:
2297         (-[DOMNode addEventListener:listener:useCapture:]):
2298         (-[DOMNode addEventListener:::]):
2299         (-[DOMNode removeEventListener:listener:useCapture:]):
2300         (-[DOMNode removeEventListener:::]):
2301
2302 2016-10-21  Wenson Hsieh  <wenson_hsieh@apple.com>
2303
2304         Support (insertFrom|deleteBy)Composition and (insert|delete)CompositionText inputTypes for InputEvents
2305         https://bugs.webkit.org/show_bug.cgi?id=163460
2306         <rdar://problem/28784142>
2307
2308         Reviewed by Darin Adler.
2309
2310         Handle new EditAction types for inserting/deleting pending/final compositions.
2311
2312         * WebCoreSupport/WebEditorClient.mm:
2313         (undoNameForEditAction):
2314
2315 2016-10-21  Jeremy Jones  <jeremyj@apple.com>
2316
2317         Implement basic pointer lock behavior for WebKit and WebKit2.
2318         https://bugs.webkit.org/show_bug.cgi?id=162745
2319
2320         Reviewed by Simon Fraser.
2321
2322         Add basic pointer lock functionality. User permission is not yet implemented.
2323
2324         * WebCoreSupport/WebChromeClient.h:
2325         * WebCoreSupport/WebChromeClient.mm:
2326         (WebChromeClient::requestPointerLock):
2327         (WebChromeClient::requestPointerUnlock):
2328
2329 2016-10-19  Myles C. Maxfield  <mmaxfield@apple.com>
2330
2331         [macOS] [iOS] Disable variation fonts on macOS El Capitan and iOS 9
2332         https://bugs.webkit.org/show_bug.cgi?id=163374
2333
2334         Reviewed by Darin Adler.
2335
2336         * Configurations/FeatureDefines.xcconfig:
2337
2338 2016-10-19  Alex Christensen  <achristensen@webkit.org>
2339
2340         Revert r207151
2341         https://bugs.webkit.org/show_bug.cgi?id=163675
2342
2343         Reviewed by Brent Fulgham.
2344
2345         * Misc/WebDownload.mm:
2346         (-[WebDownload _initWithLoadingCFURLConnection:request:response:delegate:proxy:]):
2347         * Misc/WebDownloadInternal.h:
2348         * WebCoreSupport/WebFrameLoaderClient.mm:
2349         (WebFrameLoaderClient::convertMainResourceLoadToDownload):
2350         * WebView/WebPreferences.mm:
2351         (+[WebPreferences _setCurrentNetworkLoaderSessionCookieAcceptPolicy:]):
2352         * WebView/WebView.mm:
2353         (-[WebView scheduleInRunLoop:forMode:]):
2354         (-[WebView unscheduleFromRunLoop:forMode:]):
2355
2356 2016-10-19  Ryan Haddad  <ryanhaddad@apple.com>
2357
2358         Unreviewed, rolling out r207557.
2359
2360         This change caused animations/font-variations tests to time
2361         out on pre-Sierra Macs.
2362
2363         Reverted changeset:
2364
2365         "[macOS] [iOS] Disable variation fonts on macOS El Capitan and
2366         iOS 9"
2367         https://bugs.webkit.org/show_bug.cgi?id=163374
2368         http://trac.webkit.org/changeset/207557
2369
2370 2016-10-19  Chris Dumez  <cdumez@apple.com>
2371
2372         Move HTML Interactive Form Validation behind an experimental flag
2373         https://bugs.webkit.org/show_bug.cgi?id=163673
2374
2375         Reviewed by Daniel Bates.
2376
2377         Re-disable HTML Interactive Form Validation by default on Mac WK1.
2378
2379         * WebView/WebViewData.mm:
2380         (-[WebViewPrivate init]):
2381
2382 2016-10-19  Myles C. Maxfield  <mmaxfield@apple.com>
2383
2384         [macOS] [iOS] Disable variation fonts on macOS El Capitan and iOS 9
2385         https://bugs.webkit.org/show_bug.cgi?id=163374
2386
2387         Reviewed by Darin Adler.
2388
2389         * Configurations/FeatureDefines.xcconfig:
2390
2391 2016-10-19  Simon Fraser  <simon.fraser@apple.com>
2392
2393         WebView needs to initialize the visualViewportEnabled Setting from WebKit preferences
2394         https://bugs.webkit.org/show_bug.cgi?id=163680
2395
2396         Reviewed by Dean Jackson.
2397
2398         Add code to set the Setting from WebKit prefs. This code is a mess and needs to be autogenerated.
2399
2400         * WebView/WebView.mm:
2401         (-[WebView _preferencesChanged:]):
2402
2403 2016-10-19  Darin Adler  <darin@apple.com>
2404
2405         Move XPath from ExceptionCode to Exception
2406         https://bugs.webkit.org/show_bug.cgi?id=163656
2407
2408         Reviewed by Chris Dumez.
2409
2410         * DOM/DOMDocument.mm:
2411         (wrap): Added. Helper function for wrapping a resolver.
2412         (-[DOMDocument createExpression:resolver:]): Use raiseOnDOMError.
2413         (-[DOMDocument evaluate:contextNode:resolver:type:inResult:]): Ditto.
2414         * DOM/DOMXPathExpression.mm:
2415         (-[DOMXPathExpression evaluate:type:inResult:]): Ditto.
2416         * DOM/DOMXPathResult.mm:
2417         (-[DOMXPathResult numberValue]): Ditto.
2418         (-[DOMXPathResult stringValue]): Ditto.
2419         (-[DOMXPathResult booleanValue]): Ditto.
2420         (-[DOMXPathResult singleNodeValue]): Ditto.
2421         (-[DOMXPathResult snapshotLength]): Ditto.
2422         (-[DOMXPathResult iterateNext]): Ditto.
2423         (-[DOMXPathResult snapshotItem:]): Ditto.
2424
2425 2016-10-18  Sam Weinig  <sam@webkit.org>
2426
2427         Replace std::experimental::variant with WTF::Variant (or similar)
2428         https://bugs.webkit.org/show_bug.cgi?id=163626
2429
2430         Reviewed by Chris Dumez.
2431
2432         Rename std::experimental::variant, Variant. Move helpers get/holds_alternative/etc.
2433         into the WTF namespace.
2434
2435         * DOM/DOMHTMLSelectElement.mm:
2436         (-[DOMHTMLSelectElement add:before:]):
2437
2438 2016-10-18  Simon Fraser  <simon.fraser@apple.com>
2439
2440         Add a MiniBrowser menu item to apply page scale in WK1 and WK2
2441         https://bugs.webkit.org/show_bug.cgi?id=163627
2442
2443         Reviewed by Dean Jackson.
2444
2445         Add an explanatory comment about viewScaleFactor not really being viewScaleFactor.
2446
2447         * WebView/WebViewPrivate.h:
2448
2449 2016-10-18  Dean Jackson  <dino@apple.com>
2450
2451         Remove CSS_SHAPES feature definition. This should always be on.
2452         https://bugs.webkit.org/show_bug.cgi?id=163628
2453         <rdar://problem/28834613>
2454
2455         Reviewed by Tim Horton.
2456
2457         * Configurations/FeatureDefines.xcconfig:
2458
2459 2016-10-18  Chris Dumez  <cdumez@apple.com>
2460
2461         Leverage new union type support for HTMLSelectElement.add() / HTMLOptionsCollection.add()
2462         https://bugs.webkit.org/show_bug.cgi?id=163608
2463
2464         Reviewed by Ryosuke Niwa.
2465
2466         Update add() call sites now that it takes std::variant types in.
2467
2468         * DOM/DOMHTMLOptionsCollection.mm:
2469         (-[DOMHTMLOptionsCollection add:index:]):
2470         * DOM/DOMHTMLSelectElement.mm:
2471         (-[DOMHTMLSelectElement add:before:]):
2472
2473 2016-10-18  Anders Carlsson  <andersca@apple.com>
2474
2475         Get rid of more WebHistoryItem cruft
2476         https://bugs.webkit.org/show_bug.cgi?id=163623
2477
2478         Reviewed by Tim Horton.
2479
2480         * History/WebHistoryItem.mm:
2481         (-[WebHistoryItem initFromDictionaryRepresentation:]):
2482         * History/WebHistoryItemPrivate.h:
2483
2484 2016-10-18  Wenson Hsieh  <wenson_hsieh@apple.com>
2485
2486         Showing and hiding candidates list is very distracting after selecting word
2487         https://bugs.webkit.org/show_bug.cgi?id=163609
2488         <rdar://problem/28747712>
2489
2490         Reviewed by Tim Horton.
2491
2492         Introduce WebView hooks for mousedown and mouseup. See radar for more details.
2493
2494         * WebView/WebHTMLView.mm:
2495         (-[WebHTMLView mouseDown:mouseDown:]):
2496         (-[WebHTMLView mouseUp:mouseUp:]):
2497         * WebView/WebView.mm:
2498         (-[WebView prepareForMouseDown]):
2499         (-[WebView prepareForMouseUp]):
2500         * WebView/WebViewInternal.h:
2501
2502 2016-10-17  Anders Carlsson  <andersca@apple.com>
2503
2504         Move some history specific HistoryItem code to WebHistoryItem
2505         https://bugs.webkit.org/show_bug.cgi?id=163567
2506
2507         Reviewed by Tim Horton.
2508
2509         * History/HistoryPropertyList.mm:
2510         (HistoryPropertyListWriter::writeHistoryItem):
2511         * History/WebHistory.mm:
2512         (-[WebHistory _visitedURL:withTitle:method:wasFailure:]):
2513         * History/WebHistoryItem.mm:
2514         (-[WebHistoryItem initFromDictionaryRepresentation:]):
2515         * History/WebHistoryItemInternal.h:
2516         * WebCoreSupport/WebFrameLoaderClient.mm:
2517         (addRedirectURL):
2518         (WebFrameLoaderClient::updateGlobalHistoryRedirectLinks):
2519
2520 2016-10-18  Eric Carlson  <eric.carlson@apple.com>
2521
2522         [MediaStream] Resolve constraints and enumerate devices in the UI process
2523         https://bugs.webkit.org/show_bug.cgi?id=162147
2524         <rdar://problem/28803569>
2525
2526         Reviewed by Darin Adler.
2527
2528         * WebCoreSupport/WebUserMediaClient.h:
2529         * WebCoreSupport/WebUserMediaClient.mm:
2530         (AddPermissionCheckToMap):
2531         (RemovePermissionCheckFromMap):
2532         (WebUserMediaClient::pageDestroyed):
2533         (WebUserMediaClient::requestUserMediaAccess):
2534         (WebUserMediaClient::enumerateMediaDevices):
2535         (WebUserMediaClient::cancelMediaDevicesEnumerationRequest):
2536         (-[WebUserMediaPolicyListener allow]):
2537         (-[WebUserMediaPolicyListener deny]):
2538         (-[WebUserMediaPolicyCheckerListener initWithMediaDevicesEnumerationRequest:]):
2539         (-[WebUserMediaPolicyCheckerListener cancelMediaDevicesEnumerationRequest]):
2540         (-[WebUserMediaPolicyCheckerListener allow]):
2541         (-[WebUserMediaPolicyCheckerListener deny]):
2542         (WebUserMediaClient::checkUserMediaPermission): Deleted.
2543         (WebUserMediaClient::cancelUserMediaPermissionCheck): Deleted.
2544         (-[WebUserMediaPolicyCheckerListener initWithUserMediaPermissionCheck:]): Deleted.
2545         (-[WebUserMediaPolicyCheckerListener cancelUserMediaPermissionCheck]): Deleted.
2546
2547 2016-10-17  Antti Koivisto  <antti@apple.com>
2548
2549         Rename setNeedsStyleRecalc to invalidateStyle
2550         https://bugs.webkit.org/show_bug.cgi?id=163542
2551
2552         Reviewed by Darin Adler.
2553
2554         * Plugins/Hosted/WebHostedNetscapePluginView.mm:
2555         (-[WebHostedNetscapePluginView createPluginLayer]):
2556         * Plugins/WebNetscapePluginView.mm:
2557         (-[WebNetscapePluginView createPlugin]):
2558
2559 2016-10-17  Jeremy Jones  <jeremyj@apple.com>
2560
2561         Enable keyboard in fullscreen.
2562         https://bugs.webkit.org/show_bug.cgi?id=163146
2563
2564         Reviewed by Jer Noble.
2565
2566         Allow keyboard in fullscreen.
2567
2568         * WebView/WebView.mm:
2569         (-[WebView _supportsFullScreenForElement:withKeyboard:]):
2570
2571 2016-10-17  Chris Dumez  <cdumez@apple.com>
2572
2573         Move form.reportValidity() behind InteractiveFormValidation setting
2574         https://bugs.webkit.org/show_bug.cgi?id=163550
2575
2576         Reviewed by Darin Adler.
2577
2578         Enable InteractiveFormValidation setting by default and link it to
2579         RuntimeEnabledFeatures so we can use it in the IDL.
2580
2581         * WebView/WebView.mm:
2582         (-[WebView _preferencesChanged:]):
2583         * WebView/WebViewData.mm:
2584         (-[WebViewPrivate init]):
2585
2586 2016-10-17  Anders Carlsson  <andersca@apple.com>
2587
2588         Fix iOS build.
2589
2590         * History/WebBackForwardList.mm:
2591         (-[WebBackForwardList dictionaryRepresentation]):
2592
2593 2016-10-17  Anders Carlsson  <andersca@apple.com>
2594
2595         CTTE some of the BackForwardList member functions
2596         https://bugs.webkit.org/show_bug.cgi?id=163555
2597
2598         Reviewed by Dan Bernstein.
2599
2600         * History/BackForwardList.h:
2601         (BackForwardList::entries):
2602         * History/BackForwardList.mm:
2603         (BackForwardList::removeItem):
2604         (BackForwardList::containsItem):
2605         (BackForwardList::entries): Deleted.
2606         * History/WebBackForwardList.mm:
2607         (-[WebBackForwardList removeItem:]):
2608         (-[WebBackForwardList containsItem:]):
2609         (-[WebBackForwardList description]):
2610
2611 2016-10-17  Anders Carlsson  <andersca@apple.com>
2612
2613         Remove WEBCORE_EXPORT from BackForwardList, it lives in WebKit now
2614         https://bugs.webkit.org/show_bug.cgi?id=163551
2615
2616         Reviewed by Tim Horton.
2617
2618         * History/BackForwardList.h:
2619
2620 2016-10-16  Darin Adler  <darin@apple.com>
2621
2622         Move CSS classes from ExceptionCode to Exception
2623         https://bugs.webkit.org/show_bug.cgi?id=163494
2624
2625         Reviewed by Sam Weinig.
2626
2627         * DOM/DOMCSSMediaRule.mm:
2628         (-[DOMCSSMediaRule insertRule:index:]): Use raiseOnDOMError
2629         the new way to handle ExceptionOr instead of ExceptionCode.
2630         (-[DOMCSSMediaRule deleteRule:]): Ditto.
2631         * DOM/DOMCSSPrimitiveValue.mm:
2632         (-[DOMCSSPrimitiveValue setFloatValue:floatValue:]): Ditto.
2633         (-[DOMCSSPrimitiveValue getFloatValue:]): Ditto.
2634         (-[DOMCSSPrimitiveValue setStringValue:stringValue:]): Ditto.
2635         (-[DOMCSSPrimitiveValue getStringValue]): Ditto.
2636         (-[DOMCSSPrimitiveValue getCounterValue]): Ditto.
2637         (-[DOMCSSPrimitiveValue getRectValue]): Ditto.
2638         (-[DOMCSSPrimitiveValue getRGBColorValue]): Ditto.
2639         * DOM/DOMCSSRule.mm:
2640         (-[DOMCSSRule setCssText:]): Ditto.
2641         * DOM/DOMCSSStyleDeclaration.mm:
2642         (-[DOMCSSStyleDeclaration setCssText:]): Ditto.
2643         (-[DOMCSSStyleDeclaration removeProperty:]): Ditto.
2644         (-[DOMCSSStyleDeclaration setProperty:value:priority:]): Ditto.
2645         * DOM/DOMCSSStyleSheet.mm:
2646         (-[DOMCSSStyleSheet insertRule:index:]): Ditto.
2647         (-[DOMCSSStyleSheet deleteRule:]): Ditto.
2648         (-[DOMCSSStyleSheet addRule:style:index:]): Ditto.
2649         (-[DOMCSSStyleSheet removeRule:]): Ditto.
2650         * DOM/DOMCSSValue.mm:
2651         (-[DOMCSSValue setCssText:]): Ditto.
2652         * DOM/DOMMediaList.mm:
2653         (-[DOMMediaList setMediaText:]): Ditto.
2654         (-[DOMMediaList deleteMedium:]): Ditto.
2655         (-[DOMMediaList appendMedium:]): Ditto.
2656
2657         * DOM/ExceptionHandlers.h: Added an overload of raiseDOMException
2658         that works with a WebCore::Exception&& and overloads of
2659         raiseOnDOMError that work with WebCore::ExceptionOr&&.
2660         * DOM/ExceptionHandlers.mm:
2661         (raiseDOMException): Implemented the new version.
2662
2663 2016-10-15  Dan Bernstein  <mitz@apple.com>
2664
2665         REGRESSION (r191699): Contextual menu in Mail compose view doesn’t include any of the standard submenus
2666         https://bugs.webkit.org/show_bug.cgi?id=163492
2667         <rdar://problem/28654799>
2668
2669         Reviewed by Darin Adler.
2670
2671         Test: TestWebKitAPI/Tests/mac/ContextMenuDefaultItemsHaveTags.mm
2672
2673         * WebView/WebHTMLView.mm:
2674         (createMenuItem): Set the tag for items that have submenus as well.
2675
2676 2016-10-14  Anders Carlsson  <andersca@apple.com>
2677
2678         Clean up BackForwardClient
2679         https://bugs.webkit.org/show_bug.cgi?id=163454
2680
2681         Reviewed by Sam Weinig.
2682
2683         * History/BackForwardList.h:
2684         Remove override keywords.
2685
2686         * History/BackForwardList.mm:
2687         (BackForwardList::clearAllPageCaches): Deleted.
2688         Remove this, it's no longer used.
2689
2690         * WebView/WebView.mm:
2691         (-[WebView _clearBackForwardCache]): Deleted.
2692         * WebView/WebViewPrivate.h:
2693         Remove SPI that's no longer used by anyone.
2694
2695 2016-10-13  Anders Carlsson  <andersca@apple.com>
2696
2697         Move BackForwardList from WebCore to WebKitLegacy
2698         https://bugs.webkit.org/show_bug.cgi?id=163418
2699
2700         Reviewed by Tim Horton.
2701
2702         * History/BackForwardList.h: Renamed from Source/WebCore/history/BackForwardList.h.
2703         (BackForwardList::create):
2704         (BackForwardList::webView):
2705         * History/BackForwardList.mm: Renamed from Source/WebCore/history/BackForwardList.cpp.
2706         (BackForwardList::BackForwardList):
2707         (BackForwardList::close):
2708         (BackForwardList::containsItem):
2709         * History/WebBackForwardList.mm:
2710         (kit):
2711         (-[WebBackForwardList initWithBackForwardList:]):
2712         (-[WebBackForwardList setPageCacheSize:]):
2713         (-[WebBackForwardList pageCacheSize]):
2714         * History/WebBackForwardListInternal.h:
2715         * WebCoreSupport/WebFrameLoaderClient.mm:
2716         * WebView/WebFrameView.mm:
2717         * WebView/WebView.mm:
2718         (-[WebView _commonInitializationWithFrameName:groupName:]):
2719         (-[WebView initSimpleHTMLDocumentWithStyle:frame:preferences:groupName:]):
2720
2721 2016-10-13  Anders Carlsson  <andersca@apple.com>
2722
2723         Get rid of the HistoryItemVector typedef
2724         https://bugs.webkit.org/show_bug.cgi?id=163398
2725
2726         Reviewed by Beth Dakin.
2727
2728         Expand the HistoryitemVector typedef instead to make it more clear what types we are dealing with.
2729
2730         * History/WebBackForwardList.mm:
2731         (-[WebBackForwardList dictionaryRepresentation]):
2732         (vectorToNSArray):
2733         (-[WebBackForwardList backListWithLimit:]):
2734         (-[WebBackForwardList forwardListWithLimit:]):
2735         (-[WebBackForwardList description]):
2736         * History/WebHistoryItem.mm:
2737         (-[WebHistoryItem description]):
2738
2739 2016-10-12  Chris Dumez  <cdumez@apple.com>
2740
2741         [Web IDL] Drop support for legacy [ConstructorConditional=*]
2742         https://bugs.webkit.org/show_bug.cgi?id=163368
2743
2744         Reviewed by Ryosuke Niwa.
2745
2746         Drop ENABLE_DOM4_EVENTS_CONSTRUCTOR compiler flag.
2747
2748         * Configurations/FeatureDefines.xcconfig:
2749
2750 2016-10-12  Beth Dakin  <bdakin@apple.com>
2751
2752         Adobe Contribute CS 6.5 Trial crashes on launch
2753         https://bugs.webkit.org/show_bug.cgi?id=163365
2754         -and corresponding-
2755         <rdar://problem/28732731>
2756
2757         Reviewed by Tim Horton.
2758
2759         * Carbon/CarbonWindowFrame.m:
2760         (-[CarbonWindowFrame contentFill]):
2761
2762 2016-10-11  Daniel Bates  <dabates@apple.com>
2763
2764         Attempt to fix the Apple Internal Mac build following r207159
2765         (https://bugs.webkit.org/show_bug.cgi?id=163244)
2766
2767         * WebView/WebView.mm:
2768         (shouldRequireUserGestureToLoadVideo):
2769
2770 2016-10-11  Daniel Bates  <dabates@apple.com>
2771
2772         REGRESSION (r198251): -[UIWebView mediaPlaybackRequiresUserAction] defaults to NO
2773         https://bugs.webkit.org/show_bug.cgi?id=163259
2774         <rdar://problem/28680515>
2775
2776         Reviewed by Jer Noble.
2777
2778         In WebKit1 on iOS we want to require user action to load and play videos by default and
2779         allow an embedding app to change this behavior via -[UIWebView setMediaPlaybackRequiresUserAction:].
2780         Following r198251, -[UIWebView mediaPlaybackRequiresUserAction] defaults to NO and videos
2781         can load and play without being initiated by a user action.
2782
2783         * WebView/WebPreferences.mm:
2784         (+[WebPreferences initialize]): Initialize the default value of the deprecated preference
2785         WebKitRequiresUserGestureForMediaPlaybackPreferenceKey to YES on iOS. The value of this
2786         preference takes precedence over the values of its replacement preferences
2787         WebKitRequiresUserGestureForVideoPlaybackPreferenceKey and WebKitRequiresUserGestureForAudioPlaybackPreferenceKey.
2788
2789 2016-10-11  Daniel Bates  <dabates@apple.com>
2790
2791         [iOS] REGRESSION (r197953): User gesture required to load video in iOS 9-built apps
2792         https://bugs.webkit.org/show_bug.cgi?id=163244
2793         <rdar://problem/27250015>
2794
2795         Reviewed by Jer Noble.
2796
2797         Enable or disable the Setting::requiresUserGestureToLoadVideo() in legacy WebKit depending
2798         on the version of iOS SDK that the app was linked against. We require a user gesture to
2799         begin loading a video as of iOS 10.
2800
2801         * WebView/WebView.mm:
2802         (shouldRequireUserGestureToLoadVideo):
2803         (-[WebView _preferencesChanged:]): Modified to pass the WebKit requiresUserGestureToLoadVideo
2804         preference to WebCore.
2805
2806 2016-10-11  Alex Christensen  <achristensen@webkit.org>
2807
2808         Remove dead networking code
2809         https://bugs.webkit.org/show_bug.cgi?id=163263
2810
2811         Reviewed by Daniel Bates.
2812
2813         * Misc/WebDownload.mm:
2814         (-[WebDownload _initWithLoadingCFURLConnection:request:response:delegate:proxy:]): Deleted.
2815         * Misc/WebDownloadInternal.h:
2816         * WebCoreSupport/WebFrameLoaderClient.mm:
2817         (WebFrameLoaderClient::convertMainResourceLoadToDownload):
2818         * WebView/WebPreferences.mm:
2819         (+[WebPreferences _setCurrentNetworkLoaderSessionCookieAcceptPolicy:]):
2820         * WebView/WebView.mm:
2821         (-[WebView scheduleInRunLoop:forMode:]):
2822         (-[WebView unscheduleFromRunLoop:forMode:]):
2823
2824 2016-10-10  Zan Dobersek  <zdobersek@igalia.com>
2825
2826         Add ENABLE_ENCRYPTED_MEDIA configuration option
2827         https://bugs.webkit.org/show_bug.cgi?id=163219
2828
2829         Reviewed by Darin Adler.
2830
2831         * Configurations/FeatureDefines.xcconfig:
2832         Add the ENABLE_ENCRYPTED_MEDIA configuration option. It will be used
2833         to enable or disable the new EME implementation at build-time.
2834
2835 2016-10-10  Darin Adler  <darin@apple.com>
2836
2837         Move NotificationCenter from legacy to new DOM exceptions
2838         https://bugs.webkit.org/show_bug.cgi?id=163217
2839
2840         Reviewed by Chris Dumez.
2841
2842         * WebView/WebView.mm:
2843         (-[WebView _notificationIDForTesting:]): Pass reference to page rather than pointer.
2844
2845 2016-10-09  Wenson Hsieh  <wenson_hsieh@apple.com>
2846
2847         Support InputEvent.inputType for the new InputEvent spec
2848         https://bugs.webkit.org/show_bug.cgi?id=163025
2849         <rdar://problem/28658092>
2850
2851         Reviewed by Darin Adler.
2852
2853         Accounts for some changes to the EditAction enum in nameForEditAction. See WebCore ChangeLog
2854         entry for more details.
2855
2856         * WebCoreSupport/WebEditorClient.mm:
2857         (undoNameForEditAction):
2858
2859 2016-10-06  Darin Adler  <darin@apple.com>
2860
2861         Next step on moving to modern way to return DOM exceptions
2862         https://bugs.webkit.org/show_bug.cgi?id=163016
2863
2864         Reviewed by Ryosuke Niwa.
2865
2866         * DOM/DOMDOMImplementation.mm:
2867         (-[DOMImplementation createDocumentType:publicId:systemId:]): Updated for
2868         name change from takeReturnValue to releaseReturnValue.
2869         (-[DOMImplementation createDocument:qualifiedName:doctype:]): Ditto.
2870
2871 2016-10-07  Simon Fraser  <simon.fraser@apple.com>
2872
2873         [WK1 Mac] Fix repaints of fixed-background elements in layer-backed WebViews
2874         https://bugs.webkit.org/show_bug.cgi?id=163154
2875         rdar://problem/28674216
2876
2877         Reviewed by Tim Horton.
2878         
2879         r55159 added code to counteract AppKit's adjustment of dirty regions during scrolling,
2880         by offsetting the dirty rect in -setNeedsDisplayInRect: if the call happens during
2881         the NSViewBoundsDidChangeNotification handling.
2882         
2883         However, AppKit only does dirty region adjustment in the code path that blits ("copy
2884         on scroll"), so r55159 produces incorrect behavior in, for example, layer-backed views.
2885         
2886         Fix by overriding -[NSClipView _canCopyOnScrollForDeltaX:deltaY:] to know if a single
2887         scroll is going to blit, and only do adjustments in -setNeedsDisplayInRect: if it is.
2888
2889         * WebView/WebClipView.h:
2890         * WebView/WebClipView.mm:
2891         (-[WebClipView _immediateScrollToPoint:]):
2892         (-[WebClipView _canCopyOnScrollForDeltaX:deltaY:]):
2893         (-[WebClipView currentScrollIsBlit]):
2894         * WebView/WebHTMLView.mm:
2895         (-[WebHTMLView setNeedsDisplayInRect:]):
2896         (-[WebHTMLView drawRect:]):
2897
2898 2016-10-06  Youenn Fablet  <youenn@apple.com>
2899
2900         CachedResource client handling methods should take reference
2901         https://bugs.webkit.org/show_bug.cgi?id=163014
2902
2903         Reviewed by Alex Christensen.
2904
2905         * WebView/WebHTMLView.mm:
2906         (promisedDataClient):
2907
2908 2016-10-05  Myles C. Maxfield  <mmaxfield@apple.com>
2909
2910         Put variation fonts work behind a compile-time flag
2911         https://bugs.webkit.org/show_bug.cgi?id=162949
2912
2913         Reviewed by Simon Fraser.
2914
2915         * Configurations/FeatureDefines.xcconfig:
2916
2917 2016-10-05  Zan Dobersek  <zdobersek@igalia.com>
2918
2919         Rename ENABLE_ENCRYPTED_MEDIA_V2 to ENABLE_LEGACY_ENCRYPTED_MEDIA
2920         https://bugs.webkit.org/show_bug.cgi?id=162903
2921
2922         Reviewed by Alex Christensen.
2923
2924         Rename build guards for the remaining implementation of the legacy EME API
2925         to ENABLE_LEGACY_ENCRYPTED_MEDIA. This will allow for the future implementation
2926         of the near-finished API to be guarded with the simple ENABLE_ENCRYPTED_MEDIA guards.
2927
2928         * Configurations/FeatureDefines.xcconfig:
2929         * WebView/WebPreferences.mm:
2930         (+[WebPreferences initialize]):
2931         * WebView/WebView.mm:
2932         (-[WebView _preferencesChanged:]):
2933
2934 2016-10-04  Said Abou-Hallawa  <sabouhallawa@apple.com>
2935
2936         The dragged image should be the current frame only of the animated image
2937         https://bugs.webkit.org/show_bug.cgi?id=162109
2938
2939         Reviewed by Tim Horton.
2940
2941         * DOM/DOM.mm:
2942         (-[DOMElement image]): Call the Image function with its new name.
2943         (-[DOMElement _imageTIFFRepresentation]): Ditto.
2944         * Misc/WebElementDictionary.mm:
2945         (-[WebElementDictionary _image]): Call the Image function with its new name.
2946         * Misc/WebIconDatabase.mm:
2947         (-[WebIconDatabase defaultIconWithSize:]): Call snapshotNSImage() to create the icon image.
2948         (webGetNSImage): Call the Image function with its new name.
2949         * WebCoreSupport/WebContextMenuClient.mm:
2950         (WebContextMenuClient::imageForCurrentSharingServicePickerItem): Call snapshotNSImage() instead of nsImage()..
2951         (WebContextMenuClient::contextMenuForEvent): Ditto.
2952         * WebView/WebHTMLView.mm:
2953         (-[WebHTMLView pasteboard:provideDataForType:]): Call the Image function with its new name.
2954
2955 2016-10-02  Ryan Haddad  <ryanhaddad@apple.com>
2956
2957         Unreviewed, rolling out r206683.
2958
2959         This change caused API test WebKit2.FindMatches to fail on
2960         Mac.
2961
2962         Reverted changeset:
2963
2964         "The dragged image should be the current frame only of the
2965         animated image"
2966         https://bugs.webkit.org/show_bug.cgi?id=162109
2967         http://trac.webkit.org/changeset/206683
2968
2969 2016-09-30  Said Abou-Hallawa  <sabouhallawa@apple.com>
2970
2971         The dragged image should be the current frame only of the animated image
2972         https://bugs.webkit.org/show_bug.cgi?id=162109
2973
2974         Reviewed by Tim Horton.
2975
2976         * DOM/DOM.mm:
2977         (-[DOMElement image]): Call the Image function with its new name.
2978         (-[DOMElement _imageTIFFRepresentation]): Ditto.
2979         * Misc/WebElementDictionary.mm:
2980         (-[WebElementDictionary _image]): Call the Image function with its new name.
2981         * Misc/WebIconDatabase.mm:
2982         (-[WebIconDatabase defaultIconWithSize:]): Call currentFrameNSImage() to create the icon image.
2983         (webGetNSImage): Call the Image function with its new name.
2984         * WebCoreSupport/WebContextMenuClient.mm:
2985         (WebContextMenuClient::imageForCurrentSharingServicePickerItem): Call currentFrameNSImage() instead of nsImage()..
2986         (WebContextMenuClient::contextMenuForEvent): Ditto.
2987         * WebView/WebHTMLView.mm:
2988         (-[WebHTMLView pasteboard:provideDataForType:]): Call the Image function with its new name.
2989
2990 2016-09-27  Jer Noble  <jer.noble@apple.com>
2991
2992         Remove deprecated ENCRYPTED_MEDIA implementation.
2993         https://bugs.webkit.org/show_bug.cgi?id=161010
2994
2995         Remove ENABLE_ENCRYPTED_MEDIA.
2996
2997         Reviewed by Eric Carlson.
2998
2999         * Configurations/FeatureDefines.xcconfig:
3000
3001 2016-09-26  Daniel Bates  <dabates@apple.com>
3002
3003         Rename IOS_TEXT_AUTOSIZING to TEXT_AUTOSIZING
3004         https://bugs.webkit.org/show_bug.cgi?id=162365
3005
3006         Reviewed by Simon Fraser.
3007
3008         * Configurations/FeatureDefines.xcconfig:
3009         * WebView/WebFrame.mm:
3010         * WebView/WebPreferences.mm:
3011         (+[WebPreferences initialize]):
3012         * WebView/WebView.mm:
3013         (-[WebView _preferencesChanged:]):
3014
3015 2016-09-25  Antti Koivisto  <antti@apple.com>
3016
3017         AuthorStyleSheets shouldn't trigger synchronous style resolutions
3018         https://bugs.webkit.org/show_bug.cgi?id=162532
3019
3020         Reviewed by Darin Adler.
3021
3022         * WebView/WebHTMLView.mm:
3023         (-[WebHTMLView reapplyStyles]):
3024         (-[WebHTMLView _setPrinting:minimumPageLogicalWidth:logicalHeight:originalPageWidth:originalPageHeight:maximumShrinkRatio:adjustViewSize:paginateScreenContent:]):
3025
3026 2016-09-24  Antti Koivisto  <antti@apple.com>
3027
3028         Move stylesheet change logic from Document to AuthorStyleSheets
3029         https://bugs.webkit.org/show_bug.cgi?id=162488
3030
3031         Reviewed by Andreas Kling.
3032
3033         * WebView/WebHTMLView.mm:
3034         (-[WebHTMLView reapplyStyles]):
3035         (-[WebHTMLView _setPrinting:minimumPageLogicalWidth:logicalHeight:originalPageWidth:originalPageHeight:maximumShrinkRatio:adjustViewSize:paginateScreenContent:]):
3036
3037 2016-09-23  Caitlin Potter  <caitp@igalia.com>
3038
3039         [JSC] Implement parsing of Async Functions
3040         https://bugs.webkit.org/show_bug.cgi?id=161409
3041
3042         Reviewed by Yusuke Suzuki.
3043
3044         * Configurations/FeatureDefines.xcconfig:
3045
3046 2016-09-23  Commit Queue  <commit-queue@webkit.org>
3047
3048         Unreviewed, rolling out r206311.
3049         https://bugs.webkit.org/show_bug.cgi?id=162495
3050
3051         Broke internal iOS build (Requested by anttik on #webkit).
3052
3053         Reverted changeset:
3054
3055         "Move stylesheet change logic from Document to
3056         AuthorStyleSheets"
3057         https://bugs.webkit.org/show_bug.cgi?id=162488
3058         http://trac.webkit.org/changeset/206311
3059
3060 2016-09-23  Antoine Quint  <graouts@apple.com>
3061
3062         Add a new runtime flag for work on modern media controls (off by default)
3063         https://bugs.webkit.org/show_bug.cgi?id=162420
3064         <rdar://problem/27989489>
3065
3066         Reviewed by Eric Carlson.
3067
3068         * WebView/WebPreferenceKeysPrivate.h:
3069         * WebView/WebPreferences.mm:
3070         (-[WebPreferences modernMediaControlsEnabled]):
3071         (-[WebPreferences setModernMediaControlsEnabled:]):
3072         * WebView/WebPreferencesPrivate.h:
3073         * WebView/WebView.mm:
3074         (-[WebView _preferencesChanged:]):
3075
3076 2016-09-21  Anders Carlsson  <andersca@apple.com>
3077
3078         Support openPaymentSetup API on ApplePaySession object
3079         https://bugs.webkit.org/show_bug.cgi?id=162357
3080         rdar://problem/26776939
3081
3082         Reviewed by Tim Horton.
3083
3084         Add openPaymentSetup stub.
3085
3086         * WebCoreSupport/WebPaymentCoordinatorClient.h:
3087         * WebCoreSupport/WebPaymentCoordinatorClient.mm:
3088         (WebPaymentCoordinatorClient::openPaymentSetup):
3089
3090 2016-09-19  Daniel Bates  <dabates@apple.com>
3091
3092         Remove ENABLE(TEXT_AUTOSIZING) automatic text size adjustment code
3093         https://bugs.webkit.org/show_bug.cgi?id=162167
3094
3095         Reviewed by Simon Fraser.
3096
3097         * Configurations/FeatureDefines.xcconfig:
3098
3099 2016-09-19  Joseph Pecoraro  <pecoraro@apple.com>
3100
3101         Web Inspector: Bring the inspected page's window forward when activating element search
3102         https://bugs.webkit.org/show_bug.cgi?id=162114
3103         <rdar://problem/28349357>
3104
3105         Reviewed by Brian Burg.
3106
3107         * WebCoreSupport/WebInspectorClient.mm:
3108         (WebInspectorClient::didSetSearchingForNode):
3109         When element search is activated bring the window
3110         containing the inspected page to the foreground.
3111
3112 2016-09-15  Brady Eidson  <beidson@apple.com>
3113
3114         WKWebView.hasOnlySecureContent always returns "YES" after going back to a CachedPage (even if it has http resources).
3115         <rdar://problem/27681261> and https://bugs.webkit.org/show_bug.cgi?id=162043
3116
3117         Reviewed by Brent Fulgham. 
3118
3119         * WebCoreSupport/WebFrameLoaderClient.h:
3120         * WebCoreSupport/WebFrameLoaderClient.mm:
3121         (WebFrameLoaderClient::dispatchDidCommitLoad):
3122
3123 2016-09-15  Anders Carlsson  <andersca@apple.com>
3124
3125         This was supposed to be committed with the previous patch!
3126
3127         * Plugins/WebBasePluginPackage.mm:
3128         (pathByResolvingSymlinksAndAliases): Deleted.
3129
3130 2016-09-15  Anders Carlsson  <andersca@apple.com>
3131
3132         Replace use of Carbon file system APIs in plug-in loading
3133         https://bugs.webkit.org/show_bug.cgi?id=162040
3134         rdar://problem/6017896
3135
3136         Reviewed by Sam Weinig.
3137
3138         * Plugins/WebBasePluginPackage.mm:
3139         (-[WebBasePluginPackage initWithPath:]):
3140         Use -[NSString stringByResolvingSymlinksInPath] directly here. We already check for duplicate bundle IDs, so there's no need to try
3141         to resolve aliases as well (and the modern WebKit plug-in implementation doesn't do this).
3142
3143 2016-09-15  Beth Dakin  <bdakin@apple.com>
3144
3145         Need hasMarkedText on Mac
3146         https://bugs.webkit.org/show_bug.cgi?id=162026
3147         -and corresponding-
3148         rdar://problem/28272353
3149
3150         Reviewed by Anders Carlsson.
3151
3152         * WebView/WebHTMLViewInternal.h:
3153
3154 2016-09-12  Dean Jackson  <dino@apple.com>
3155
3156         Replace RGBA32 with Color in member variables
3157         https://bugs.webkit.org/show_bug.cgi?id=161856
3158         <rdar://problem/28254324>
3159
3160         Reviewed by Simon Fraser.
3161
3162         In preparation for the Color class to become more than
3163         just a 4-byte RGBA value, I went through a few places
3164         that were using the RGBA32 type directly, and replaced
3165         them with Color. This will make some objects a little
3166         bigger e.g. BorderValue and its friends.
3167
3168         I mostly looked at the places that were using RGBA32 as
3169         a member variable. There is still a lot of RGBA32 use
3170         around the project, in particular the CSS parser.
3171
3172         There should be no behaviour change.
3173
3174         * Misc/WebKitNSStringExtras.mm:
3175         (-[NSString _web_drawAtPoint:font:textColor:allowingFontSmoothing:]): Explicitly
3176         call a Color constructor, rather than passing an RGBA32.
3177
3178 2016-09-13  Chris Dumez  <cdumez@apple.com>
3179
3180         Drop support for <isindex>
3181         https://bugs.webkit.org/show_bug.cgi?id=7139
3182
3183         Reviewed by Ryosuke Niwa.
3184
3185         Drop references to isindex.
3186
3187         * WebCoreSupport/WebEditorClient.mm:
3188         (attributesForAttributedStringConversion):
3189         * WebView/WebHTMLView.mm:
3190         (+[WebHTMLView _excludedElementsForAttributedStringConversion]):
3191
3192 2016-09-12  Chris Dumez  <cdumez@apple.com>
3193
3194         Switch remaining users of Document::inPageCache() to pageCacheState()
3195         https://bugs.webkit.org/show_bug.cgi?id=161865
3196
3197         Reviewed by Darin Adler.
3198
3199         Switch remaining users of Document::inPageCache() to pageCacheState() as
3200         the former one is confusing (given that it returns true while the
3201         pagehide event is being fired).
3202
3203         * WebView/WebHTMLView.mm:
3204         (-[WebHTMLView layoutToMinimumPageWidth:height:originalPageWidth:originalPageHeight:maximumShrinkRatio:adjustingViewSize:]):
3205         (-[WebHTMLView setNeedsLayout:]):
3206         (-[WebHTMLView setNeedsToApplyStyles:]):
3207
3208 2016-09-09  Tim Horton  <timothy_horton@apple.com>
3209
3210         Text replacement candidates don't always overwrite the entire original string
3211         https://bugs.webkit.org/show_bug.cgi?id=161779
3212         <rdar://problem/28033492>
3213
3214         Reviewed by Simon Fraser.
3215
3216         * WebCoreSupport/WebEditorClient.mm:
3217         (WebEditorClient::requestCandidatesForSelection):
3218         Make use of the shared implementation of contextRangeForCandidateRequest.
3219
3220 2016-09-08  Said Abou-Hallawa  <sabouhallawa@apple.com>
3221
3222         Move the BitmapImage platform dependent code to a new file named NativeImage[CG|Cairo].cpp
3223         https://bugs.webkit.org/show_bug.cgi?id=158684
3224
3225         Reviewed by Simon Fraser.
3226
3227         * DOM/DOM.mm:
3228         (-[DOMNode getPreviewSnapshotImage:andRects:]):
3229         * Misc/WebCache.mm:
3230         (+[WebCache imageForURL:]):
3231         Replace BitmapImage::getCGImageRef() with BitmapImage::nativeImage().
3232
3233 2016-09-07  Joseph Pecoraro  <pecoraro@apple.com>
3234
3235         [Mac] Address some clang static analyzer warnings in WebKit
3236         https://bugs.webkit.org/show_bug.cgi?id=161597
3237
3238         Reviewed by Darin Adler.
3239
3240         * Misc/WebIconDatabase.h:
3241         Remove unused instance variable. It has not been used since r16005 (2006)!
3242
3243         * Misc/WebSharingServicePickerController.mm:
3244         (-[WebSharingServicePickerController sharingServicePicker:sharingServicesForItems:mask:proposedSharingServices:]):
3245         Address array leak.
3246
3247         * WebCoreSupport/WebSelectionServiceController.mm:
3248         (WebSelectionServiceController::hasRelevantSelectionServices):
3249         Address attachment and cell leak.
3250
3251         * WebView/WebFullScreenController.h:
3252         * WebView/WebImmediateActionController.h:
3253         Remove unused instance variables.
3254
3255 2016-09-07  Simon Fraser  <simon.fraser@apple.com>
3256
3257         Enable the <meter> element on iOS
3258         https://bugs.webkit.org/show_bug.cgi?id=161714
3259         rdar://problem/8978410
3260
3261         Reviewed by Tim Horton.
3262
3263         Define ENABLE_METER_ELEMENT unconditionally now.
3264
3265         * Configurations/FeatureDefines.xcconfig:
3266
3267 2016-09-07  Mark Lam  <mark.lam@apple.com>
3268
3269         Add CatchScope and force all exception checks to be via ThrowScope or CatchScope.
3270         https://bugs.webkit.org/show_bug.cgi?id=161498
3271
3272         Reviewed by Geoffrey Garen.
3273
3274         * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
3275         (WebKit::NetscapePluginInstanceProxy::evaluate):
3276         (WebKit::NetscapePluginInstanceProxy::invoke):
3277         (WebKit::NetscapePluginInstanceProxy::invokeDefault):
3278         (WebKit::NetscapePluginInstanceProxy::construct):
3279         (WebKit::NetscapePluginInstanceProxy::getProperty):
3280         (WebKit::NetscapePluginInstanceProxy::setProperty):
3281         (WebKit::NetscapePluginInstanceProxy::removeProperty):
3282         (WebKit::NetscapePluginInstanceProxy::hasProperty):
3283         (WebKit::NetscapePluginInstanceProxy::hasMethod):
3284         (WebKit::NetscapePluginInstanceProxy::enumerate):
3285         * WebView/WebView.mm:
3286         (aeDescFromJSValue):
3287
3288 2016-09-07  Youenn Fablet  <youenn@apple.com>
3289
3290         [Streams API] Separate compile flag for ReadableStream and WritableStream
3291         https://bugs.webkit.org/show_bug.cgi?id=161044
3292
3293         Reviewed by Alex Christensen.
3294
3295         Moving from STREAMS_API to READABLE_STREAM_API and WRITABLE_STREAM_API compilation flags.
3296
3297         * Configurations/FeatureDefines.xcconfig:
3298
3299 2016-09-06  Chris Dumez  <cdumez@apple.com>
3300
3301         Add support for input.minLength / textArea.minLength
3302         https://bugs.webkit.org/show_bug.cgi?id=161644
3303
3304         Reviewed by Darin Adler.
3305
3306         Update ObjC bindings to reflect method renaming.
3307
3308         * DOM/DOMHTMLInputElement.mm:
3309         (-[DOMHTMLInputElement maxLength]):
3310         (-[DOMHTMLInputElement setMaxLength:]):
3311         * DOM/DOMHTMLTextAreaElement.mm:
3312         (-[DOMHTMLTextAreaElement maxLength]):
3313         (-[DOMHTMLTextAreaElement setMaxLength:]):
3314
3315 2016-09-06  Dan Bernstein  <mitz@apple.com>
3316
3317         <rdar://problem/8064563> Ugly NSLog in DOMInternal.mm
3318
3319         Rubber-stamped by Anders Carlsson.
3320
3321         * DOM/DOMInternal.mm:
3322         (-[WebScriptObject _initializeScriptDOMNodeImp]): Removed useless call to NSLog.
3323
3324 2016-09-06  Ryan Haddad  <ryanhaddad@apple.com>
3325
3326         Unreviewed, rolling out r205407.
3327
3328         Not the correct way to implement this functionality
3329
3330         Reverted changeset:
3331
3332         "Consult with the FrameLoaderClient about whether or not
3333         content extensions should be enabled when loading this URL."
3334         https://bugs.webkit.org/show_bug.cgi?id=161441
3335         http://trac.webkit.org/changeset/205407
3336
3337 2016-09-05  Darin Adler  <darin@apple.com>
3338
3339         More bindings improvements, particularly things not needed for JavaScript bindings
3340         https://bugs.webkit.org/show_bug.cgi?id=161572
3341
3342         Reviewed by Sam Weinig.
3343
3344         * DOM/DOMDOMImplementation.mm:
3345         (-[DOMImplementation hasFeature:version:]): Call SVGTests::hasFeatureForLegacyBindings
3346         instead of DOMImplementation::hasFeature. Also removed JSMainThreadNullState
3347         since this does not do anything that can invoke JavaScript.
3348
3349         * DOM/DOMDocument.mm:
3350         (-[DOMDocument defaultCharset]): Call defaultCharsetForLegacyBindings. Also removed
3351         JSMainThreadNullState.
3352
3353         * DOM/DOMDocumentType.mm:
3354         (-[DOMDocumentType entities]): Changed to simply return nil; same behavior as before,
3355         but with no dependency on WebCore. Also removed JSMainThreadNullState.
3356         (-[DOMDocumentType notations]): Ditto.
3357         (-[DOMDocumentType internalSubset]): Ditto, except empty string rather than nil.
3358
3359         * DOM/DOMNode.mm:
3360         (-[DOMNode isSupported:version:]): Call SVGTests::hasFeatureForLegacyBindings
3361         instead of Node::isSupportedForBindings. Also removed JSMainThreadNullState.
3362
3363 2016-09-04  Joseph Pecoraro  <pecoraro@apple.com>
3364
3365         Remove unnecessary RetainPtr.
3366
3367         Review comments on earlier change.
3368
3369         * WebView/WebImmediateActionController.mm:
3370         (-[WebImmediateActionController _defaultAnimationController]):
3371
3372 2016-09-03  Darin Adler  <darin@apple.com>
3373
3374         Streamline DOMImplementation, and move it to our new DOM exception system
3375         https://bugs.webkit.org/show_bug.cgi?id=161295
3376
3377         Reviewed by Ryosuke Niwa.
3378
3379         * DOM/DOMDOMImplementation.mm:
3380         (unwrap): Added. Use this instead of the IMPL macro.
3381         (-[DOMImplementation dealloc]): Updated to use unwrap.
3382         (-[DOMImplementation hasFeature:version:]): Ditto.
3383         (-[DOMImplementation createDocumentType:publicId:systemId:]): Updated to work with
3384         ExceptionOr.
3385         (-[DOMImplementation createDocument:qualifiedName:doctype:]): Ditto.
3386         (-[DOMImplementation createCSSStyleSheet:media:]): Removed exception logic since
3387         this function can no longer raise an exception.
3388         (-[DOMImplementation createHTMLDocument:]): Updated to use unwrap.
3389         (-[DOMImplementation hasFeature::]): Changed to call the non-deprecated version
3390         rather than duplicating its implementation. Also moved into the category as defined
3391         in the header.
3392         (-[DOMImplementation createDocumentType:::]): Ditto.
3393         (-[DOMImplementation createDocument:::]): Ditto.
3394         (-[DOMImplementation createCSSStyleSheet::]): Ditto.
3395
3396         * DOM/DOMDocument.mm: Removed unneeded include of DOMImplementation.h.
3397         (-[DOMDocument setXmlStandalone:]): Updated since setXMLStandalone no longer can
3398         raise an exception.
3399
3400         * WebView/WebFrame.mm:
3401         (-[WebFrame _canProvideDocumentSource]): Updated to use isTextMIMEType in its new
3402         location in MIMETypeRegistry instead of in DOMImplementation.
3403
3404 2016-09-03  Brian Weinstein  <bweinstein@apple.com>
3405
3406         Implement a stub version of FrameLoaderClient::shouldUseContentExtensionsForURL.
3407         https://bugs.webkit.org/show_bug.cgi?id=16144
3408
3409         Reviewed by Darin Adler.
3410
3411         * WebCoreSupport/WebFrameLoaderClient.h:
3412
3413 2016-09-02  Beth Dakin  <bdakin@apple.com>
3414
3415         Need to updateEditorState if an element change edit-ability without changing 
3416         selection
3417         https://bugs.webkit.org/show_bug.cgi?id=161546
3418         -and corresponding-
3419         rdar://problem/27806012
3420
3421         Reviewed by Ryosuke Niwa.
3422
3423         Every time WebEditorClient::respondToChangedSelection is called, we now save 
3424         whether the last state was contentEditable. That way in 
3425         updateEditorStateAfterLayoutIfNeeded() we can assess whether or not edit-ability 
3426         has changed. 
3427
3428         * WebCoreSupport/WebEditorClient.h:
3429         * WebCoreSupport/WebEditorClient.mm:
3430         (WebEditorClient::respondToChangedSelection):
3431         (WebEditorClient:: updateEditorStateAfterLayoutIfEditabilityChanged):
3432
3433 2016-09-02  Joseph Pecoraro  <pecoraro@apple.com>
3434
3435         [Mac] RetainPtr misuse, AnimationController leaks
3436         https://bugs.webkit.org/show_bug.cgi?id=161552
3437
3438         Reviewed by Tim Horton.
3439
3440         * WebView/WebImmediateActionController.mm:
3441         (-[WebImmediateActionController _defaultAnimationController]):
3442
3443 2016-07-08  Jer Noble  <jer.noble@apple.com>
3444
3445         Refactor WebPlaybackSessionModelMediaElement to be client based.
3446         https://bugs.webkit.org/show_bug.cgi?id=159580
3447
3448         Reviewed by Eric Carlson.
3449
3450         No longer necessary to tell the models and interfaces about each other.
3451
3452         * WebView/WebView.mm:
3453         (-[WebView _setUpPlaybackControlsManagerForMediaElement:]):
3454         (-[WebView _clearPlaybackControlsManager]):
3455
3456 2016-09-01  Dan Bernstein  <mitz@apple.com>
3457
3458         Build fix.
3459
3460         * Configurations/FeatureDefines.xcconfig:
3461
3462 2016-09-01  Myles C. Maxfield  <mmaxfield@apple.com>
3463
3464         Clean up TextRun-related code
3465         https://bugs.webkit.org/show_bug.cgi?id=161473
3466
3467         Reviewed by Simon Fraser.
3468
3469         Remove unused #includes.
3470
3471         * WebCoreSupport/WebDragClient.mm:
3472         * WebView/WebView.mm:
3473
3474 2016-08-31  Keith Rollin  <krollin@apple.com>
3475
3476         WebKit should set a subsystem for os_log so it's easier to filter for WebKit log messages
3477         https://bugs.webkit.org/show_bug.cgi?id=160969
3478         <rdar://problem/26068734>
3479
3480         Reviewed by Simon Fraser.
3481
3482         Enable subsystem- and channel-related data and functions when using
3483         RELEASE_LOG macros. Use the DECLARE_LOG_CHANNEL, DEFINE_LOG_CHANNEL,
3484         and LOG_CHANNEL_ADDRESS macros that are now defined in WTF.
3485
3486         * Misc/WebKitLogging.h:
3487         * Misc/WebKitLogging.m:
3488         * WebView/WebView.mm:
3489         (-[WebView _commonInitializationWithFrameName:groupName:]):
3490
3491 2016-08-31  Brady Eidson  <beidson@apple.com>
3492
3493         WK2 Gamepad provider on iOS.
3494         https://bugs.webkit.org/show_bug.cgi?id=161412
3495
3496         Reviewed by Tim Horton.
3497
3498         * Configurations/FeatureDefines.xcconfig:
3499
3500         * WebView/WebView.mm:
3501         (WebKitInitializeGamepadProviderIfNecessary):
3502
3503 2016-08-30  Mark Lam  <mark.lam@apple.com>
3504
3505         Introduce the ThrowScope and force every throw site to instantiate a ThrowScope.
3506         https://bugs.webkit.org/show_bug.cgi?id=161171
3507
3508         Reviewed by Filip Pizlo and Geoffrey Garen.
3509
3510         * Plugins/Hosted/NetscapePluginInstanceProxy.mm:
3511         (WebKit::NetscapePluginInstanceProxy::moveGlobalExceptionToExecState):
3512         * Plugins/Hosted/ProxyInstance.mm:
3513         (WebKit::ProxyInstance::invokeMethod):
3514
3515 2016-08-28  Andreas Kling  <akling@apple.com>
3516
3517         document.title setter can't throw.
3518         <https://webkit.org/b/161302>
3519
3520         Reviewed by Antti Koivisto.
3521
3522         * DOM/DOMDocument.mm:
3523         (-[DOMDocument setTitle:]):
3524
3525 2016-08-28  Andreas Kling  <akling@apple.com>
3526
3527         Clean up some .text attribute setters that don't throw.
3528         <https://webkit.org/b/161292>
3529
3530         Reviewed by Darin Adler.
3531
3532         * DOM/DOMHTMLTitleElement.mm:
3533         (-[DOMHTMLTitleElement setText:]):
3534
3535 2016-08-26  Sam Weinig  <sam@webkit.org>
3536
3537         Remove support for ENABLE_LEGACY_WEB_AUDIO
3538         https://bugs.webkit.org/show_bug.cgi?id=161262
3539
3540         Reviewed by Anders Carlsson.
3541
3542         * Configurations/FeatureDefines.xcconfig:
3543         Remove ENABLE_LEGACY_WEB_AUDIO
3544
3545 2016-08-25  Anders Carlsson  <andersca@apple.com>
3546
3547         Re-export DOMException NSStrings after r204717
3548         https://bugs.webkit.org/show_bug.cgi?id=161200
3549         <rdar://problem/27959937>
3550
3551         Reviewed by Alex Christensen.
3552
3553         * DOM/ExceptionHandlers.mm:
3554         (raiseDOMException):