[EFL] Rename TEST_THEME_DIR macro
[WebKit-https.git] / Source / WebKit2 / ChangeLog
1 2014-09-30  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
2
3         [EFL] Rename TEST_THEME_DIR macro
4         https://bugs.webkit.org/show_bug.cgi?id=137244
5
6         Reviewed by Csaba Osztrogonác.
7
8         TEST_THEME_DIR is to get a path for default theme though, it has used TEST_ prefix.
9         DEFAULT_THEME_DIR is better than it.
10
11         * UIProcess/API/efl/tests/UnitTestUtils/EWK2UnitTestEnvironment.cpp:
12         (EWK2UnitTest::EWK2UnitTestEnvironment::defaultTheme):
13         (EWK2UnitTest::EWK2UnitTestEnvironment::pathForTheme):
14         * UIProcess/efl/WebInspectorProxyEfl.cpp:
15         (WebKit::WebInspectorProxy::platformCreateInspectorPage):
16
17 2014-09-30  Christophe Dumez  <cdumez@apple.com>
18
19         Generalize is<>() / downcast<>() support to all types
20         https://bugs.webkit.org/show_bug.cgi?id=137243
21
22         Reviewed by Benjamin Poulain.
23
24         Generalize is<>() / downcast<>() support to all types, not just Nodes.
25
26         * WebProcess/InjectedBundle/API/mac/WKDOMDocument.mm:
27         (-[WKDOMDocument createElement:]):
28         (-[WKDOMDocument createTextNode:]):
29         (-[WKDOMDocument body]):
30         * WebProcess/InjectedBundle/API/mac/WKDOMText.mm:
31         (-[WKDOMText data]):
32         (-[WKDOMText setData:]):
33
34 2014-09-30  Chris Dumez  <cdumez@apple.com>
35
36         Use is<>() / downcast<>() for Element
37         https://bugs.webkit.org/show_bug.cgi?id=137241
38
39         Reviewed by Andreas Kling.
40
41         Use is<>() / downcast<>() for Element instead of isElementNode() /
42         toElement().
43
44         * Shared/WebRenderObject.cpp:
45         (WebKit::WebRenderObject::WebRenderObject):
46         * WebProcess/InjectedBundle/API/mac/WKDOMElement.mm:
47         (-[WKDOMElement hasAttribute:]):
48         (-[WKDOMElement getAttribute:]):
49         (-[WKDOMElement setAttribute:value:]):
50         (-[WKDOMElement tagName]):
51         * WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.cpp:
52         (WebKit::InjectedBundleNodeHandle::elementBounds):
53         * WebProcess/InjectedBundle/InjectedBundleHitTestResult.cpp:
54         (WebKit::InjectedBundleHitTestResult::mediaType):
55         * WebProcess/WebPage/ios/WebPageIOS.mm:
56         (WebKit::WebPage::sendTapHighlightForNodeIfNecessary):
57         (WebKit::WebPage::blurAssistedNode):
58         (WebKit::WebPage::getPositionInformation):
59         (WebKit::nextFocusableElement):
60         (WebKit::WebPage::elementDidFocus):
61
62 2014-09-30  Carlos Garcia Campos  <cgarcia@igalia.com>
63
64         REGRESSION(r173929): [GTK] TestInspector fails after r173929
65         https://bugs.webkit.org/show_bug.cgi?id=137247
66
67         Reviewed by Philippe Normand.
68
69         Add WebKitWebInspector:can-attach property to notify when the
70         inspector attach availability changes.
71
72         * UIProcess/API/C/gtk/WKInspectorClientGtk.h:
73         * UIProcess/API/gtk/WebKitWebInspector.cpp:
74         (webkit_web_inspector_class_init): Add WebKitWebInspector:can-attach property.
75         (didChangeAttachAvailability): Emit notify::can-attach.
76         (webkitWebInspectorCreate): Add implementation for didChangeAttachAvailability.
77         (webkit_web_inspector_get_can_attach): Return whether the inspector can be attached.
78         * UIProcess/API/gtk/WebKitWebInspector.h:
79         * UIProcess/API/gtk/docs/webkit2gtk-docs.sgml: Add index of new symbols in 2.8.
80         * UIProcess/API/gtk/docs/webkit2gtk-sections.txt: Add new symbol.
81         * UIProcess/gtk/WebInspectorClientGtk.cpp:
82         (WebKit::WebInspectorClientGtk::didChangeAttachAvailability):
83         * UIProcess/gtk/WebInspectorClientGtk.h:
84         * UIProcess/gtk/WebInspectorProxyGtk.cpp:
85         (WebKit::WebInspectorProxy::platformAttachAvailabilityChanged): Notify the client.
86
87 2014-09-30  Carlos Garcia Campos  <cgarcia@igalia.com>
88
89         [GTK] The remote web inspector shows the HTML content as plain text
90         https://bugs.webkit.org/show_bug.cgi?id=137250
91
92         Reviewed by Gustavo Noronha Silva.
93
94         Use GResource API directly to get the resource data, instead of
95         using the GFile API, and use g_content_type_guess() to get the
96         MIME Type.
97
98         * UIProcess/InspectorServer/gtk/WebInspectorServerGtk.cpp:
99         (WebKit::WebInspectorServer::platformResourceForPath):
100
101 2014-09-30  Carlos Garcia Campos  <cgarcia@igalia.com>
102
103         [GTK] Move GtkPopupMenu implementation to WebPopupMenuProxyGtk
104         https://bugs.webkit.org/show_bug.cgi?id=137193
105
106         Reviewed by Gustavo Noronha Silva.
107
108         GtkPopupMenu was in platform only to have a common implementation to
109         be shared with WebKit1. Now that it's only used by
110         WebPopupMenuProxyGtk in WebKit2, we can simplify the code by
111         merging the implementation directly into WebPopupMenuProxyGtk.
112
113         * UIProcess/gtk/WebPopupMenuProxyGtk.cpp:
114         (WebKit::WebPopupMenuProxyGtk::WebPopupMenuProxyGtk):
115         (WebKit::WebPopupMenuProxyGtk::~WebPopupMenuProxyGtk):
116         (WebKit::WebPopupMenuProxyGtk::populatePopupMenu):
117         (WebKit::WebPopupMenuProxyGtk::showPopupMenu):
118         (WebKit::WebPopupMenuProxyGtk::hidePopupMenu):
119         (WebKit::WebPopupMenuProxyGtk::typeAheadFind):
120         (WebKit::WebPopupMenuProxyGtk::resetTypeAheadFindState):
121         (WebKit::WebPopupMenuProxyGtk::selectItemCallback):
122         (WebKit::WebPopupMenuProxyGtk::keyPressEventCallback):
123         * UIProcess/gtk/WebPopupMenuProxyGtk.h:
124         (WebKit::WebPopupMenuProxyGtk::setCurrentlySelectedMenuItem):
125
126 2014-09-29  Christophe Dumez  <cdumez@apple.com>
127
128         Use is<>() / downcast<>() for Document
129         https://bugs.webkit.org/show_bug.cgi?id=137221
130
131         Reviewed by Andreas Kling.
132
133         Use is<>() / downcast<>() for Document instead of isDocumentNode() /
134         toDocument().
135
136         * WebProcess/InjectedBundle/API/mac/WKDOMDocument.mm:
137         (-[WKDOMDocument createElement:]):
138         (-[WKDOMDocument createTextNode:]):
139         (-[WKDOMDocument body]):
140
141 2014-09-29  Commit Queue  <commit-queue@webkit.org>
142
143         Unreviewed, rolling out r174045.
144         https://bugs.webkit.org/show_bug.cgi?id=137231
145
146         Introduced a crash during page loading tests on Mac (Requested
147         by rniwa on #webkit).
148
149         Reverted changeset:
150
151         "Replace OSObjectPtr with RetainPtr/adoptOS"
152         https://bugs.webkit.org/show_bug.cgi?id=137158
153         http://trac.webkit.org/changeset/174045
154
155 2014-09-29  Anders Carlsson  <andersca@apple.com>
156
157         Set the TBA versions based on the PLATFORM_NAME
158         https://bugs.webkit.org/show_bug.cgi?id=137226
159         Follow-up fix for <rdar://problem/17761459>.
160
161         Reviewed by Dan Bernstein.
162
163         * mac/rewrite-availability-macros.sh:
164         Turns out that MACOSX_DEPLOYMENT_TARGET is set even for iOS builds,
165         so set the versions based on the PLATFORM_NAME environment variable.
166
167 2014-09-29  Dan Bernstein  <mitz@apple.com>
168
169         Build fix.
170
171         * WebProcess/WebPage/ios/WebPageIOS.mm:
172         (WebKit::WebPage::performActionOnElement):
173
174 2014-09-27  Andy Estes  <aestes@apple.com>
175
176         [iOS] Add basic support for link navigation in WKPDFView
177         https://bugs.webkit.org/show_bug.cgi?id=137182
178
179         Reviewed by Tim Horton.
180
181         Teach WKPDFView to navigate to URLs when PDF link annotations are tapped.
182
183         * UIProcess/WebPageProxy.cpp:
184         (WebKit::WebPageProxy::navigateToURLWithSimulatedClick): Sent Messages::WebPage::NavigateToURLWithSimulatedClick.
185         * UIProcess/WebPageProxy.h:
186         * UIProcess/ios/WKPDFView.h:
187         * UIProcess/ios/WKPDFView.mm:
188         (-[WKPDFView _clearPages]): Removed self as the UIPDFAnnotationControllerDelegate.
189         (-[WKPDFView _revalidateViews]): Added self as the UIPDFAnnotationControllerDelegate.
190         (-[WKPDFView annotation:wasTouchedAtPoint:controller:]): Retrieved the URL from the touched annotation,
191         computed the touched point relative to the WKPDFView and to the screen, and called
192         navigateToURLWithSimulatedClick() after a 200 ms delay in order to show a soon-to-be-added tap highlight
193         (this value matches the delay in UIWebPDFView).
194         * WebProcess/WebPage/WebPage.cpp:
195         (WebKit::WebPage::navigateToURLWithSimulatedClick): Created a fake single-click MouseEvent and called
196         FrameLoader::urlSelected(). Creating a mouse event ensures that the navigation appears as a
197         NavigationTypeLinkClicked in navigation policy delegates.
198         * WebProcess/WebPage/WebPage.h:
199         * WebProcess/WebPage/WebPage.messages.in:
200
201 2014-09-29  Christophe Dumez  <cdumez@apple.com>
202
203         Use the new is<>() / downcast<>() for Text Nodes
204         https://bugs.webkit.org/show_bug.cgi?id=137188
205
206         Reviewed by Darin Adler.
207
208         Use the new is<>() / downcast<>() functions for Text Nodes instead of
209         isText() / toText().
210
211         * WebProcess/InjectedBundle/API/mac/WKDOMText.mm:
212         (-[WKDOMText data]):
213         (-[WKDOMText setData:]):
214
215 2014-09-29  Christophe Dumez  <cdumez@apple.com>
216
217         Make is<>() / downcast<>() work for HTMLDocument and its subclasses
218         https://bugs.webkit.org/show_bug.cgi?id=137169
219
220         Reviewed by Darin Adler.
221
222         Use is<>() / downcast<>() for HTMLDocument and its subclasses.
223
224         * WebProcess/WebPage/WebPage.cpp:
225         (WebKit::WebPage::pdfDocumentForPrintingFrame):
226
227 2014-09-29  Tibor Meszaros  <tmeszaros.u-szeged@partner.samsung.com>
228
229         Fix !ENABLE(INSPECTOR) build after r173929
230         https://bugs.webkit.org/show_bug.cgi?id=137210
231
232         Reviewed by Timothy Hatcher.
233
234         * UIProcess/WebProcessProxy.cpp:
235         (WebKit::WebProcessProxy::getLaunchOptions):
236
237 2014-09-29  Carlos Garcia Campos  <cgarcia@igalia.com>
238
239         REGRESSION(r172919): WebKitPluginProcess fails to scan GTK+2 plugins after r172919.
240         https://bugs.webkit.org/show_bug.cgi?id=137191
241
242         Reviewed by Philippe Normand.
243
244         In r172919 I moved the GTK+ symbols mix check earlier, before the
245         plugin is loaded and initialized. That made impossible to use the
246         GTK3 plugin process to scan gtk2 plugins, because we need to load
247         the plugin to get its metadata. But we don't need to initialize
248         the plugin to check if it requires GTK2, so we can do that check
249         in the UI process to decide which plugin process to use.
250
251         * Shared/Plugins/Netscape/x11/NetscapePluginModuleX11.cpp:
252         (WebKit::NetscapePluginModule::getPluginInfoForLoadedPlugin):
253         Remove the requires GTK2 check.
254         (WebKit::NetscapePluginModule::scanPlugin): Don't write
255         requires-gtk2 to stdout.
256         * UIProcess/Plugins/unix/PluginProcessProxyUnix.cpp:
257         (WebKit::pluginRequiresGtk2): Helper function to check if the
258         given plugin path requires GTK2.
259         (WebKit::PluginProcessProxy::scanPlugin): Check if the plugin path
260         requires GTK2 and use WebKitPluginProcess2 in such case, or return
261         early if GTK2 plugins are not enabled. Log error messages when
262         something fails scanning the plugin to make it easiert to debug
263         problems in the future.
264
265 2014-09-28  Myles C. Maxfield  <mmaxfield@apple.com>
266
267         Replace wkGetGlyphsForCharacters() with CGFontGetGlyphsForUnichars()
268         https://bugs.webkit.org/show_bug.cgi?id=137197
269
270         Reviewed by Alexey Proskuryakov.
271
272         No new tests because there is no behavior change.
273
274         * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
275         (InitWebCoreSystemInterface):
276         * mac/WebKit2.order:
277
278 2014-09-28  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
279
280         Use std::unique_ptr for ContextMenuController
281         https://bugs.webkit.org/show_bug.cgi?id=137178
282
283         Reviewed by Darin Adler.
284
285         Switch to using std::unique_ptr instead of OwnPtr and PassOwnPtr
286         for ContextMenuController class. Inherited class is changed by this use as well.
287
288         * WebProcess/WebCoreSupport/WebContextMenuClient.cpp:
289         (WebKit::WebContextMenuClient::customizeMenu):
290         * WebProcess/WebCoreSupport/WebContextMenuClient.h:
291
292 2014-09-28  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
293
294         Move ColorInputType class to std::unique_ptr
295         https://bugs.webkit.org/show_bug.cgi?id=137173
296
297         Reviewed by Darin Adler.
298
299         Replace uses of PassOwnPtr in code under ColorInputType class with std::unique_ptr.
300         Child classes follow this change as well.
301
302         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
303         (WebKit::WebChromeClient::createColorChooser):
304         * WebProcess/WebCoreSupport/WebChromeClient.h:
305
306 2014-09-26  Sam Weinig  <sam@webkit.org>
307
308         Replace OSObjectPtr with RetainPtr/adoptOS
309         https://bugs.webkit.org/show_bug.cgi?id=137158
310
311         Reviewed by Dan Bernstein.
312
313         * DatabaseProcess/EntryPoint/mac/XPCService/DatabaseServiceEntryPoint.mm:
314         (DatabaseServiceInitializer):
315         * NetworkProcess/EntryPoint/mac/XPCService/NetworkServiceEntryPoint.mm:
316         (WebKit::NetworkServiceInitializerDelegate::NetworkServiceInitializerDelegate):
317         (NetworkServiceInitializer):
318         * Platform/IPC/Connection.h:
319         (IPC::Connection::Identifier::Identifier):
320         * Platform/IPC/mac/ConnectionMac.mm:
321         (IPC::ConnectionTerminationWatchdog::createConnectionTerminationWatchdog):
322         (IPC::ConnectionTerminationWatchdog::ConnectionTerminationWatchdog):
323         * PluginProcess/EntryPoint/mac/XPCService/PluginServiceEntryPoint.mm:
324         (WebKit::PluginServiceInitializerDelegate::PluginServiceInitializerDelegate):
325         (PluginServiceInitializer):
326         * Shared/EntryPointUtilities/mac/XPCService/XPCServiceEntryPoint.h:
327         (WebKit::XPCServiceInitializerDelegate::XPCServiceInitializerDelegate):
328         (WebKit::XPCServiceInitializer):
329         * Shared/EntryPointUtilities/mac/XPCService/XPCServiceEntryPoint.mm:
330         (WebKit::XPCServiceInitializerDelegate::checkEntitlements):
331         (WebKit::XPCServiceInitializerDelegate::hasEntitlement):
332         * Shared/EntryPointUtilities/mac/XPCService/XPCServiceMain.Development.mm:
333         (WebKit::XPCServiceEventHandler):
334         * Shared/EntryPointUtilities/mac/XPCService/XPCServiceMain.mm:
335         (WebKit::XPCServiceEventHandler):
336         * UIProcess/Launcher/mac/ProcessLauncherMac.mm:
337         (WebKit::connectToService):
338         (WebKit::connectToReExecService):
339         * WebProcess/EntryPoint/mac/XPCService/WebContentServiceEntryPoint.mm:
340         (WebContentServiceInitializer):
341
342 2014-09-26  Christophe Dumez  <cdumez@apple.com>
343
344         Stop using legacy NODE_TYPE_CASTS() macro for HTML Elements
345         https://bugs.webkit.org/show_bug.cgi?id=137137
346
347         Reviewed by Benjamin Poulain.
348
349         Use is<>() / downcast<>() where appropriate.
350
351         * WebProcess/Plugins/PDF/PDFPluginTextAnnotation.mm:
352         (WebKit::PDFPluginTextAnnotation::value):
353         * WebProcess/Plugins/PluginView.cpp:
354         (WebKit::PluginView::initializePlugin):
355         (WebKit::PluginView::pluginSnapshotTimerFired):
356         (WebKit::PluginView::pluginDidReceiveUserInteraction):
357         * WebProcess/WebPage/WebPage.cpp:
358         (WebKit::WebPage::createPlugin):
359         * WebProcess/WebPage/ios/WebPageIOS.mm:
360         (WebKit::WebPage::performActionOnElement):
361
362 2014-09-26  Anders Carlsson  <andersca@apple.com>
363
364         Add API for loading local files
365         https://bugs.webkit.org/show_bug.cgi?id=137153
366         rdar://problem/17761459
367
368         Reviewed by Oliver Hunt.
369
370         * UIProcess/API/Cocoa/WKWebView.h:
371         * UIProcess/API/Cocoa/WKWebView.mm:
372         (-[WKWebView loadFileURL:allowingReadAccessToURL:]):
373         Load the file, wrapping the navigation ID in a WKNavigation using createLoadRequestNavigation.
374
375         * UIProcess/WebPageProxy.cpp:
376         (WebKit::WebPageProxy::loadFile):
377         * UIProcess/WebPageProxy.h:
378         Return the navigation ID (or 0 if the navigation failed).
379
380 2014-09-26  Timothy Hatcher  <timothy@apple.com>
381
382         Add WKInspector back function stubs that went missing from r173929.
383         My changes to WKDeprecatedFunctions.cpp got lost in the shuffle.
384
385         * Shared/API/c/WKDeprecatedFunctions.cpp:
386         (WKInspectorIsDebuggingJavaScript):
387         (WKInspectorToggleJavaScriptDebugging):
388         (WKInspectorIsProfilingJavaScript):
389         (WKInspectorToggleJavaScriptProfiling):
390
391 2014-09-26  Carlos Garcia Campos  <cgarcia@igalia.com>
392
393         REGRESSION(r173929): Web inspector doesn't work after r173929 when INSPECTOR_SERVER is enabled
394         https://bugs.webkit.org/show_bug.cgi?id=137150
395
396         Reviewed by Timothy Hatcher.
397
398         The inspector doesn't show any information about the inspected
399         page because it's sending messages to a remote frontend that is
400         not running.
401
402         * WebProcess/WebPage/WebInspector.cpp:
403         (WebKit::WebInspector::WebInspector): Initialize m_remoteFrontendConnected.
404         (WebKit::WebInspector::sendMessageToFrontend): Send
405         SendMessageToRemoteFrontend message to the UI process when remote
406         frontend is connected, or SendMessageToFrontend message to
407         WebInspectorUI otherwise.
408         (WebKit::WebInspector::remoteFrontendConnected): Set m_remoteFrontendConnected to true.
409         (WebKit::WebInspector::remoteFrontendDisconnected): Set m_remoteFrontendConnected to false.
410         * WebProcess/WebPage/WebInspector.h:
411
412 2014-09-26  Alberto Garcia  <berto@igalia.com>
413
414         [GTK] Don't include full path names in WebKitEnumTypes.h
415         https://bugs.webkit.org/show_bug.cgi?id=137148
416
417         Reviewed by Carlos Garcia Campos.
418
419         Replace @filename@ with @basename@ in the template, since we don't
420         want to include the full path name in the generated header.
421
422         * UIProcess/API/gtk/WebKitEnumTypes.h.template:
423
424 2014-09-25  Yusuke Suzuki  <utatane.tea@gmail.com>
425
426         Clean up unused parameter warnings
427         https://bugs.webkit.org/show_bug.cgi?id=137107
428
429         Reviewed by Benjamin Poulain.
430
431         * Scripts/webkit/messages.py:
432         (generate_message_handler):
433         Sometimes generated code doesn't use `connection` parameter. So `UNUSED_PARAM(connection)` is necessary.
434         * UIProcess/API/C/WKPage.cpp:
435         (WKPageIsPlayingAudio):
436
437 2014-09-25  Christophe Dumez  <cdumez@apple.com>
438
439         Use is<HTML*Element>() instead of isHTML*Element() - Part 2
440         https://bugs.webkit.org/show_bug.cgi?id=137103
441
442         Reviewed by Benjamin Poulain.
443
444         Use is<HTML*Element>() instead of isHTML*Element().
445
446         * WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.cpp:
447         (WebKit::InjectedBundleNodeHandle::htmlIFrameElementContentFrame):
448         * WebProcess/WebPage/WebFrame.cpp:
449         (WebKit::WebFrame::containsAnyFormElements):
450         * WebProcess/WebPage/WebPage.cpp:
451         (WebKit::WebPage::determinePrimarySnapshottedPlugIn):
452         * WebProcess/WebPage/ios/WebPageIOS.mm:
453         (WebKit::WebPage::getAssistedNodeInformation):
454
455 2014-09-25  Anders Carlsson  <andersca@apple.com>
456
457         Expand WK_MAC_TBA and WK_IOS_TBA to the current deployment target version (or NA).
458         https://bugs.webkit.org/show_bug.cgi?id=137127
459         Part of rdar://problem/17761459.
460
461         Reviewed by Dan Bernstein.
462
463         * mac/rewrite-availability-macros.sh:
464
465 2014-09-25  Tim Horton  <timothy_horton@apple.com>
466
467         CommitLayerTree decode fails in 32-bit apps on 64-bit devices (TransformationMatrix alignment differs)
468         https://bugs.webkit.org/show_bug.cgi?id=136444
469         <rdar://problem/17952526>
470
471         Reviewed by Anders Carlsson.
472
473         * Shared/WebCoreArgumentCoders.cpp:
474         (IPC::ArgumentCoder<TransformationMatrix>::encode):
475         (IPC::ArgumentCoder<TransformationMatrix>::decode):
476         Stop using SimpleArgumentCoder to encode/decode TransformationMatrix,
477         because the alignment of TransformationMatrix differs between architectures,
478         and there's no guarantee that both sides of a connection are the same architecture.
479
480 2014-09-25  Alberto Garcia  <berto@igalia.com>
481
482         Unreviewed typo fix.
483
484         * UIProcess/API/C/soup/WKContextSoup.cpp:
485
486 2014-09-25  Shivakumar JM  <shiva.jm@samsung.com>
487
488         [WebKit2] Fix build warning in WebKit2/WebProcess module.
489         https://bugs.webkit.org/show_bug.cgi?id=137105
490
491         Reviewed by Csaba Osztrogonác.
492
493         Fix build warning by removing unused parameter names
494
495         * WebProcess/WebPage/WebInspector.h:
496         (WebKit::WebInspector::didReceiveInvalidMessage):
497         * WebProcess/WebPage/WebInspectorUI.h:
498         (WebKit::WebInspectorUI::didReceiveInvalidMessage):
499
500 2014-09-24  Sam Weinig  <sam@webkit.org>
501
502         Remove incorrect use of the BKSProcessAssertionAllowSuspendOnSleep flag for process suspension in iOS WebKit2
503         <rdar://problem/18400566>
504         https://bugs.webkit.org/show_bug.cgi?id=137077
505
506         Reviewed by Anders Carlsson.
507
508         * UIProcess/ios/ProcessAssertionIOS.mm:
509         Remove use of the BKSProcessAssertionAllowSuspendOnSleep which does not do what we expect, and instead
510         causes processes to be suspended "forever" after sleep.
511
512 2014-09-24  Christophe Dumez  <cdumez@apple.com>
513
514         Use is<HTML*Element>() instead of isHTML*Element() - Part 1
515         https://bugs.webkit.org/show_bug.cgi?id=137068
516
517         Reviewed by Ryosuke Niwa.
518
519         Start using is<HTML*Element>() instead of isHTML*Element().
520         Remaining usages will be updated in a follow-up patch to
521         reduce the size of the change.
522
523         * WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.cpp:
524         (WebKit::InjectedBundleNodeHandle::setHTMLInputElementValueForUser):
525         (WebKit::InjectedBundleNodeHandle::isHTMLInputElementAutofilled):
526         (WebKit::InjectedBundleNodeHandle::setHTMLInputElementAutofilled):
527         (WebKit::InjectedBundleNodeHandle::htmlInputElementLastChangeWasUserEdit):
528         (WebKit::InjectedBundleNodeHandle::htmlTextAreaElementLastChangeWasUserEdit):
529         (WebKit::InjectedBundleNodeHandle::isTextField):
530         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
531         (WebKit::WebChromeClient::focusedElementChanged):
532         * WebProcess/WebCoreSupport/WebEditorClient.cpp:
533         (WebKit::WebEditorClient::textFieldDidBeginEditing):
534         (WebKit::WebEditorClient::textFieldDidEndEditing):
535         (WebKit::WebEditorClient::textDidChangeInTextField):
536         (WebKit::WebEditorClient::textDidChangeInTextArea):
537         (WebKit::WebEditorClient::doTextFieldCommandFromEvent):
538         (WebKit::WebEditorClient::textWillBeDeletedInTextField):
539         * WebProcess/WebPage/WebFrame.cpp:
540         (WebKit::WebFrame::containsAnyFormControls):
541         * WebProcess/WebPage/ios/WebPageIOS.mm:
542         (WebKit::WebPage::setAssistedNodeValue):
543         (WebKit::WebPage::setAssistedNodeValueAsNumber):
544         (WebKit::WebPage::setAssistedNodeSelectedIndex):
545
546 2014-09-23  Ada Chan  <adachan@apple.com>
547
548         Add stub implementation of WKPageIsPlayingAudio().
549         https://bugs.webkit.org/show_bug.cgi?id=137044
550
551         Reviewed by Anders Carlsson.
552
553         Also add an isPlayingAudioDidChange callback to WKPageUIClient.
554
555         * UIProcess/API/C/WKPage.cpp:
556         (WKPageIsPlayingAudio):
557         * UIProcess/API/C/WKPagePrivate.h:
558         * UIProcess/API/C/WKPageUIClient.h:
559
560 2014-09-21  Timothy Hatcher  <timothy@apple.com>
561
562         Make the Web Inspector use a separate web process.
563
564         https://bugs.webkit.org/show_bug.cgi?id=135120
565
566         Reviewed by Anders Carlsson.
567
568         * CMakeLists.txt:
569         * DerivedSources.make:
570         * PlatformEfl.cmake:
571         * PlatformGTK.cmake:
572         * WebKit2.xcodeproj/project.pbxproj:
573         Added new WebInspectorUI files and removed WebInspectorFrontendClient.cpp.
574
575         * Shared/APIObject.h: Added BundleInspectorUI.
576
577         * Shared/EntryPointUtilities/mac/LegacyProcess/ChildProcessEntryPoint.mm:
578         (WebKit::ChildProcessMainDelegate::getExtraInitializationData):
579         * Shared/EntryPointUtilities/mac/XPCService/XPCServiceEntryPoint.mm:
580         (WebKit::XPCServiceInitializerDelegate::getExtraInitializationData):
581         Add support for "inspector-process" data, a boolean that is used by
582         WebProcess::initializeProcessName.
583
584         * UIProcess/API/C/WKInspector.cpp:
585         (WKInspectorIsDebuggingJavaScript):
586         (WKInspectorToggleJavaScriptDebugging):
587         (WKInspectorIsProfilingJavaScript):
588         (WKInspectorToggleJavaScriptProfiling):
589         * UIProcess/API/C/WKInspector.h:
590         Stub out functions we don't support but need to keep for nightly compatibility.
591
592         * UIProcess/WebInspectorProxy.cpp:
593         (WebKit::WebInspectorPageGroups::createInspectorPageGroup):
594         (WebKit::WebInspectorProxy::WebInspectorProxy):
595         (WebKit::WebInspectorProxy::invalidate):
596         (WebKit::WebInspectorProxy::connect):
597         (WebKit::WebInspectorProxy::showConsole):
598         (WebKit::WebInspectorProxy::showResources):
599         (WebKit::WebInspectorProxy::showMainResourceForFrame):
600         (WebKit::WebInspectorProxy::attach):
601         (WebKit::WebInspectorProxy::detach):
602         (WebKit::WebInspectorProxy::inspectorContext):
603         (WebKit::WebInspectorProxy::dispatchMessageFromRemoteFrontend):
604         (WebKit::WebInspectorProxy::eagerlyCreateInspectorPage):
605         (WebKit::WebInspectorProxy::createInspectorPage):
606         (WebKit::WebInspectorProxy::open):
607         (WebKit::WebInspectorProxy::didClose):
608         (WebKit::WebInspectorProxy::attachAvailabilityChanged):
609         * UIProcess/WebInspectorProxy.h:
610         (WebKit::WebInspectorProxy::isConnected):
611         (WebKit::WebInspectorProxy::canAttach):
612         * UIProcess/WebInspectorProxy.messages.in:
613         * UIProcess/efl/WebInspectorProxyEfl.cpp:
614         (WebKit::WebInspectorProxy::platformCreateInspectorPage):
615         * UIProcess/gtk/WebInspectorProxyGtk.cpp:
616         (WebKit::WebInspectorProxy::platformCreateInspectorPage):
617         (WebKit::WebInspectorProxy::platformAttach):
618         * UIProcess/mac/WebInspectorProxyMac.mm:
619         (-[WKWebInspectorProxyObjCAdapter close]):
620         (WebKit::WebInspectorProxy::platformCreateInspectorPage):
621         (WebKit::WebInspectorProxy::platformDidClose):
622         (WebKit::WebInspectorProxy::platformHide):
623         (WebKit::WebInspectorProxy::platformSave):
624         (WebKit::WebInspectorProxy::platformAppend):
625         (WebKit::WebInspectorProxy::platformAttach):
626         Changed how the Inspector page is created by making it in a new WebContext for
627         the Inspector. This removes us from the main process pool and guarantees no process
628         sharing for our user interface. Also send new WebInspectorUI messages to the Inspector
629         page and not the inspected page when appropriate.
630
631         * UIProcess/WebProcessProxy.cpp:
632         (WebKit::WebProcessProxy::getLaunchOptions): Add "inspector-process" to extraInitializationData
633         if the context is the Inspector context. This is used by WebProcess::initializeProcessName.
634
635         * WebProcess/WebCoreSupport/WebInspectorClient.cpp:
636         (WebKit::WebInspectorClient::openInspectorFrontend):
637         (WebKit::WebInspectorClient::closeInspectorFrontend):
638         (WebKit::WebInspectorClient::bringFrontendToFront):
639         * WebProcess/WebCoreSupport/WebInspectorClient.h:
640         Remove the InspectorFrontendChannel class from WebInspectorClient and clean up a little.
641         InspectorFrontendChannel implementation moved to WebInspector.
642
643         * WebProcess/WebCoreSupport/WebInspectorFrontendClient.cpp: Removed. Superseded by WebInspectorUI.
644
645         * WebProcess/WebPage/WebInspector.cpp:
646         (WebKit::WebInspector::create):
647         (WebKit::WebInspector::WebInspector):
648         (WebKit::WebInspector::createInspectorPage):
649         (WebKit::WebInspector::closeFrontend):
650         (WebKit::WebInspector::openInNewTab):
651         (WebKit::WebInspector::showConsole):
652         (WebKit::WebInspector::showResources):
653         (WebKit::WebInspector::showMainResourceForFrame):
654         (WebKit::WebInspector::startPageProfiling):
655         (WebKit::WebInspector::stopPageProfiling):
656         (WebKit::WebInspector::canAttachWindow):
657         (WebKit::WebInspector::updateDockingAvailability):
658         (WebKit::WebInspector::sendMessageToBackend):
659         (WebKit::WebInspector::sendMessageToFrontend):
660         (WebKit::WebInspector::remoteFrontendConnected):
661         (WebKit::WebInspector::remoteFrontendDisconnected):
662         * WebProcess/WebPage/WebInspector.h:
663         (WebKit::WebInspector::didClose):
664         (WebKit::WebInspector::didReceiveInvalidMessage):
665         (WebKit::WebInspector::setAttached):
666         * WebProcess/WebPage/WebInspector.messages.in:
667         Stop taking an optional InspectorFrontendChannel and inherit it instead. Create a connection that
668         can be passed to the other web process for WebInspectorUI to use. Stop referencing Inspector's page
669         directly, since it is in another process now.
670
671         * WebProcess/WebPage/WebInspectorUI.cpp: Added.
672         (WebKit::WebInspectorUI::create):
673         (WebKit::WebInspectorUI::WebInspectorUI):
674         (WebKit::WebInspectorUI::establishConnection):
675         (WebKit::WebInspectorUI::windowObjectCleared):
676         (WebKit::WebInspectorUI::frontendLoaded):
677         (WebKit::WebInspectorUI::moveWindowBy):
678         (WebKit::WebInspectorUI::bringToFront):
679         (WebKit::WebInspectorUI::closeWindow):
680         (WebKit::WebInspectorUI::requestSetDockSide):
681         (WebKit::WebInspectorUI::setDockSide):
682         (WebKit::WebInspectorUI::changeAttachedWindowHeight):
683         (WebKit::WebInspectorUI::changeAttachedWindowWidth):
684         (WebKit::WebInspectorUI::setToolbarHeight):
685         (WebKit::WebInspectorUI::openInNewTab):
686         (WebKit::WebInspectorUI::save):
687         (WebKit::WebInspectorUI::append):
688         (WebKit::WebInspectorUI::inspectedURLChanged):
689         (WebKit::WebInspectorUI::showConsole):
690         (WebKit::WebInspectorUI::showResources):
691         (WebKit::WebInspectorUI::showMainResourceForFrame):
692         (WebKit::WebInspectorUI::startPageProfiling):
693         (WebKit::WebInspectorUI::stopPageProfiling):
694         (WebKit::WebInspectorUI::didSave):
695         (WebKit::WebInspectorUI::didAppend):
696         (WebKit::WebInspectorUI::sendMessageToFrontend):
697         (WebKit::WebInspectorUI::sendMessageToBackend):
698         (WebKit::WebInspectorUI::evaluateCommandOnLoad):
699         (WebKit::WebInspectorUI::evaluateExpressionOnLoad):
700         (WebKit::WebInspectorUI::evaluatePendingExpressions):
701         * WebProcess/WebPage/WebInspectorUI.h: Added.
702         (WebKit::WebInspectorUI::page):
703         (WebKit::WebInspectorUI::didClose):
704         (WebKit::WebInspectorUI::didReceiveInvalidMessage):
705         (WebKit::WebInspectorUI::attachedBottom):
706         (WebKit::WebInspectorUI::attachedRight):
707         (WebKit::WebInspectorUI::detached):
708         (WebKit::WebInspectorUI::evaluateCommandOnLoad):
709         * WebProcess/WebPage/WebInspectorUI.messages.in: Added.
710         * WebProcess/WebPage/efl/WebInspectorUIEfl.cpp: Added.
711         (WebKit::WebInspectorUI::canSave):
712         (WebKit::WebInspectorUI::localizedStringsURL):
713         * WebProcess/WebPage/gtk/WebInspectorUIGtk.cpp: Added.
714         (WebKit::WebInspectorUI::canSave):
715         (WebKit::WebInspectorUI::localizedStringsURL):
716         * WebProcess/WebPage/mac/WebInspectorUIMac.mm: Added.
717         (WebKit::WebInspectorUI::canSave):
718         (WebKit::WebInspectorUI::localizedStringsURL):
719         Implement the InspectorFrontendClient and handle a connection to the inspected page's WebInspector.
720
721         * WebProcess/WebPage/WebPage.cpp:
722         (WebKit::WebPage::WebPage):
723         (WebKit::WebPage::~WebPage):
724         (WebKit::WebPage::inspector):
725         (WebKit::WebPage::inspectorUI):
726         (WebKit::WebPage::didReceiveMessage):
727         Setup as a listener for WebInspectorUI messages.
728
729         * WebProcess/WebPage/WebPage.h:
730         (WebKit::WebPage::isInspectorPage): It is an Inspector page if we have a m_inspectorUI.
731
732         * WebProcess/cocoa/WebProcessCocoa.mm:
733         (WebKit::WebProcess::initializeProcessName):
734         Name the process "%@ Web Inspector" if it is an Inspector content process. Processes in that
735         context are not shared with multiple pages.
736
737 2014-09-24  Dean Jackson  <dino@apple.com>
738
739         Add a deprecated stub for WKPreferencesSetMultithreadedWebGLEnabled (and Get)
740         https://bugs.webkit.org/show_bug.cgi?id=137071
741
742         Reviewed by Brent Fulgham.
743
744         Put in stubs for WKPreferencesSetMultithreadedWebGLEnabled and
745         WKPreferencesGetMultithreadedWebGLEnabled. These were removed in
746         r173776 but are still needed for nightly builds to link
747         (or will be once Yosemite nightlies are available).
748
749         * Shared/API/c/WKDeprecatedFunctions.cpp:
750         (WKPreferencesSetMultithreadedWebGLEnabled):
751         (WKPreferencesGetMultithreadedWebGLEnabled):
752
753 2014-09-24  Daniel Bates  <dabates@apple.com>
754
755         [iOS] Fix the iOS build after <http://trac.webkit.org/changeset/173893>
756         (https://bugs.webkit.org/show_bug.cgi?id=137007)
757
758         Add closing parenthesis characters that were inadvertently removed in <http://trac.webkit.org/changeset/173893>.
759
760         * WebProcess/WebPage/ios/WebPageIOS.mm:
761         (WebKit::WebPage::setAssistedNodeSelectedIndex):
762         (WebKit::WebPage::getAssistedNodeInformation):
763
764 2014-09-23  Christophe Dumez  <cdumez@apple.com>
765
766         Unreviewed build fix after r173893.
767
768         Partial revert of r173893 to fix debug builds.
769
770         * WebProcess/Plugins/PDF/PDFPluginTextAnnotation.mm:
771         (WebKit::PDFPluginTextAnnotation::value):
772         * WebProcess/Plugins/PluginView.cpp:
773         (WebKit::PluginView::initializePlugin):
774         (WebKit::PluginView::pluginSnapshotTimerFired):
775         (WebKit::PluginView::pluginDidReceiveUserInteraction):
776         * WebProcess/WebPage/WebPage.cpp:
777         (WebKit::WebPage::createPlugin):
778
779 2014-09-23  Chris Dumez  <cdumez@apple.com>
780
781         Use downcast<HTML*Element>() instead of toHTML*Element()
782         https://bugs.webkit.org/show_bug.cgi?id=137007
783
784         Reviewed by Benjamin Poulain.
785
786         Use downcast<HTML*Element>() instead of toHTML*Element().
787
788         * WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.cpp:
789         (WebKit::InjectedBundleNodeHandle::setHTMLInputElementValueForUser):
790         (WebKit::InjectedBundleNodeHandle::isHTMLInputElementAutofilled):
791         (WebKit::InjectedBundleNodeHandle::setHTMLInputElementAutofilled):
792         (WebKit::InjectedBundleNodeHandle::htmlInputElementLastChangeWasUserEdit):
793         (WebKit::InjectedBundleNodeHandle::htmlTextAreaElementLastChangeWasUserEdit):
794         (WebKit::InjectedBundleNodeHandle::isTextField):
795         (WebKit::InjectedBundleNodeHandle::htmlTableCellElementCellAbove):
796         (WebKit::InjectedBundleNodeHandle::htmlIFrameElementContentFrame):
797         * WebProcess/Plugins/PDF/PDFPluginChoiceAnnotation.mm:
798         (WebKit::PDFPluginChoiceAnnotation::commit):
799         * WebProcess/Plugins/PDF/PDFPluginTextAnnotation.mm:
800         (WebKit::PDFPluginTextAnnotation::createAnnotationElement):
801         (WebKit::PDFPluginTextAnnotation::value):
802         * WebProcess/Plugins/PluginView.cpp:
803         (WebKit::PluginView::initializePlugin):
804         (WebKit::PluginView::pluginSnapshotTimerFired):
805         (WebKit::PluginView::pluginDidReceiveUserInteraction):
806         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
807         (WebKit::WebChromeClient::focusedElementChanged):
808         * WebProcess/WebCoreSupport/WebEditorClient.cpp:
809         (WebKit::WebEditorClient::textFieldDidBeginEditing):
810         (WebKit::WebEditorClient::textFieldDidEndEditing):
811         (WebKit::WebEditorClient::textDidChangeInTextField):
812         (WebKit::WebEditorClient::textDidChangeInTextArea):
813         (WebKit::WebEditorClient::doTextFieldCommandFromEvent):
814         (WebKit::WebEditorClient::textWillBeDeletedInTextField):
815         * WebProcess/WebPage/WebPage.cpp:
816         (WebKit::WebPage::createPlugin):
817         * WebProcess/WebPage/ios/WebPageIOS.mm:
818         (WebKit::WebPage::setAssistedNodeValue):
819         (WebKit::WebPage::setAssistedNodeValueAsNumber):
820         (WebKit::WebPage::setAssistedNodeSelectedIndex):
821         (WebKit::isAssistableNode): Deleted.
822         (WebKit::WebPage::getAssistedNodeInformation): Deleted.
823
824 2014-09-23  Jer Noble  <jer.noble@apple.com>
825
826         REGRESSION (r171197): Clip's content is drawn behind Safari window when entering Full Screen youtube html5 first time
827         https://bugs.webkit.org/show_bug.cgi?id=137029
828
829         Reviewed by Brent Fulgham.
830
831         In r171197, we ordered the full screen window on- and off-screen so that the fullscreen animation went to the
832         correct screen, which introduced a subtle glitch at the beginning and end of an animation. For entering, ensure
833         that the window is scaled to its starting size before ordering on-screen. For exiting, order the window off-
834         screen before resetting its clipping rect.
835
836         * UIProcess/mac/WKFullScreenWindowController.mm:
837         (-[WKFullScreenWindowController beganEnterFullScreenWithInitialFrame:finalFrame:]):
838         (-[WKFullScreenWindowController finishedExitFullScreenAnimation:]):
839
840 2014-09-23  Joseph Pecoraro  <pecoraro@apple.com>
841
842         Web Inspector: Should be able to attach a debugger to a JSContext before anything is executed
843         https://bugs.webkit.org/show_bug.cgi?id=136893
844
845         Reviewed by Timothy Hatcher.
846
847         * WebProcess/WebPage/WebInspector.cpp:
848         (WebKit::WebInspector::remoteFrontendConnected):
849
850 2014-09-22  Daniel Bates  <dabates@apple.com>
851
852         [Cocoa] Add UI delegate callback when window.close() is called
853         https://bugs.webkit.org/show_bug.cgi?id=137008
854         <rdar://problem/17801001>
855
856         Reviewed by Anders Carlsson.
857
858         Implement support infrastructure to notify the UI client when window.close() is called.
859
860         * UIProcess/API/Cocoa/WKUIDelegatePrivate.h: Added method declaration for -_webViewClose:.
861         * UIProcess/Cocoa/UIDelegate.h: Added override declaration for API::UIClient::close().
862         * UIProcess/Cocoa/UIDelegate.mm:
863         (WebKit::UIDelegate::setDelegate): Wire up delegate method to Objective-C selector, -[WKUIDelegatePrivate _webViewClose:].
864         (WebKit::UIDelegate::UIClient::close): Added; turns around and calls -[WKUIDelegatePrivate _webViewClose:] (if applicable).
865
866 2014-09-21  Chris Dumez  <cdumez@apple.com>
867
868         Generate Element casting helper functions
869         https://bugs.webkit.org/show_bug.cgi?id=136839
870
871         Reviewed by Darin Adler.
872
873         Use JSXXX::toWrapped() instead of toXXX() function.
874
875         * WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.cpp:
876         (WebKit::InjectedBundleNodeHandle::getOrCreate):
877         * WebProcess/InjectedBundle/DOM/InjectedBundleRangeHandle.cpp:
878         (WebKit::InjectedBundleRangeHandle::getOrCreate):
879         * WebProcess/InjectedBundle/InjectedBundle.cpp:
880         (WebKit::InjectedBundle::webNotificationID):
881
882 2014-09-19  Ryosuke Niwa  <rniwa@webkit.org>
883
884         WebContent crash in WebKit::WebPage::expandedRangeFromHandle
885         https://bugs.webkit.org/show_bug.cgi?id=136969
886
887         Reviewed by David Kilzer.
888
889         The crash was caused by m_currentBlockSelection and frame.selection().selection().toNormalizedRange()
890         both being null and the subsequent lines of code assuming currentRange to be not null.
891
892         Replace the assertion by an early exit since the range could be null here.
893
894         In the future, we should figure out if there are other things we need to do in addition
895         to checking the nullity when this race condition is hit.
896
897         * WebProcess/WebPage/ios/WebPageIOS.mm:
898         (WebKit::WebPage::computeExpandAndShrinkThresholdsForHandle):
899
900 2014-09-19  Dean Jackson  <dino@apple.com>
901
902         Multithreaded WebGL is a bad idea - remove it
903         https://bugs.webkit.org/show_bug.cgi?id=136964
904         <rdar://problem/18399858>
905
906         Reviewed by Brent Fulgham.
907
908         Remove the setting to allow multithreaded WebGL.
909
910         * Shared/WebPreferencesDefinitions.h:
911         * UIProcess/API/C/WKPreferences.cpp:
912         (WKPreferencesSetMultithreadedWebGLEnabled): Deleted.
913         (WKPreferencesGetMultithreadedWebGLEnabled): Deleted.
914         * UIProcess/API/C/WKPreferencesRefPrivate.h:
915         * WebProcess/WebPage/WebPage.cpp:
916         (WebKit::WebPage::updatePreferences):
917
918 2014-09-19  Simon Fraser  <simon.fraser@apple.com>
919
920         Provide a default argument for the most commonly used HitTestRequest variant
921         https://bugs.webkit.org/show_bug.cgi?id=136653
922
923         Reviewed by Darin Adler.
924
925         Make the default HitTestRequest flags be ReadOnly | Active | DisallowShadowContent
926         and change call sites using the default flags to use a HitTestRequest temporary.
927
928         * WebProcess/WebPage/ViewGestureGeometryCollector.cpp:
929         (WebKit::ViewGestureGeometryCollector::collectGeometryForSmartMagnificationGesture):
930         * WebProcess/WebPage/ios/WebPageIOS.mm:
931         (WebKit::WebPage::dynamicViewportSizeUpdate):
932
933 2014-09-19  Daniel Bates  <dabates@apple.com>
934
935         Always assume internal SDK when building configuration Production
936         https://bugs.webkit.org/show_bug.cgi?id=136925
937         <rdar://problem/18362399>
938
939         Reviewed by Dan Bernstein.
940
941         As a side effect of this change we will always enable ENABLE_TOUCH_EVENTS, ENABLE_IOS_{GESTURE, TOUCH}_EVENTS,
942         and ENABLE_XSLT when either building configuration Production or building with the Internal SDK.
943
944         * Configurations/Base.xcconfig:
945
946 2014-09-19  Simon Fraser  <simon.fraser@apple.com>
947
948         Fix the Mac Mavericks build. Only iOS cares about fencing.
949
950         * Platform/mac/LayerHostingContext.h:
951         * Platform/mac/LayerHostingContext.mm:
952
953 2014-09-19  Carlos Garcia Campos  <cgarcia@igalia.com>
954
955         [GTK] Missing inspector files in the tarball
956         https://bugs.webkit.org/show_bug.cgi?id=136952
957
958         Reviewed by Gustavo Noronha Silva.
959
960         * PlatformGTK.cmake: Use APPEND instead of GLOB to add individual
961         and generated files to the list of inspector files.
962
963 2014-09-19  Carlos Garcia Campos  <cgarcia@igalia.com>
964
965         Webkitgtk 2.5.3: tarball contains APPLE LICENSE file - stating not distributable
966         https://bugs.webkit.org/show_bug.cgi?id=136632
967
968         Reviewed by Gustavo Noronha Silva.
969
970         * PlatformGTK.cmake: Use only the icons from the gtk directory since they are free.
971
972 2014-09-19  Carlos Garcia Campos  <cgarcia@igalia.com>
973
974         [GTK] generate-inspector-gresource-manifest.py should receive the list of files from the makefile
975         https://bugs.webkit.org/show_bug.cgi?id=136943
976
977         Reviewed by Philippe Normand.
978
979         * PlatformGTK.cmake: Fix the inspector file list and pass it to
980         the generate-inspector-gresource-manifest.py script.
981
982 2014-09-18  Carlos Garcia Campos  <cgarcia@igalia.com>
983
984         [GTK] Dot not allow to create delete-on-destroy GMainLoopSources
985         https://bugs.webkit.org/show_bug.cgi?id=136923
986
987         Reviewed by Gustavo Noronha Silva.
988
989         * Platform/gtk/WorkQueueGtk.cpp:
990         (WorkQueue::dispatch): Use GMainLoopSource::scheduleAndDeleteOnDestroy().
991         (WorkQueue::dispatchAfter): Use GMainLoopSource::scheduleAfterDelayAndDeleteOnDestroy().
992
993 2014-09-18  Ryuan Choi  <ryuan.choi@gmail.com>
994
995         [EFL][CoordinatedGraphics] Remove setBackgroundColor message
996         https://bugs.webkit.org/show_bug.cgi?id=136824
997
998         Reviewed by Gyuyoung Kim.
999
1000         CoordinatedGraphics used setBackgroundColor() to draw the background of contents
1001         although tiles are not ready.
1002
1003         This patch removes setBackgroundColor() and uses pageExtendedBackgroundColor()
1004         which provides similar functionality.
1005
1006         * UIProcess/API/efl/EwkView.cpp:
1007         Enables or disables WKPageSetBackgroundExtendsBeyondPage to use pageExtendedBackgroundColor()
1008         (EwkView::EwkView):
1009         (EwkView::setBackgroundColor):
1010         * UIProcess/CoordinatedGraphics/CoordinatedGraphicsScene.cpp:
1011         (WebCore::CoordinatedGraphicsScene::CoordinatedGraphicsScene):
1012         (WebCore::CoordinatedGraphicsScene::paintToCurrentGLContext): Passed pageExtendedBackgroundColor.
1013         (WebCore::CoordinatedGraphicsScene::paintToGraphicsContext): Ditto.
1014         (WebCore::CoordinatedGraphicsScene::setBackgroundColor): Deleted.
1015         * UIProcess/CoordinatedGraphics/CoordinatedGraphicsScene.h:
1016         (WebCore::CoordinatedGraphicsScene::setDrawsBackground): Deleted.
1017         * UIProcess/CoordinatedGraphics/CoordinatedLayerTreeHostProxy.cpp:
1018         (WebKit::CoordinatedLayerTreeHostProxy::setBackgroundColor): Deleted.
1019         * UIProcess/CoordinatedGraphics/CoordinatedLayerTreeHostProxy.h:
1020         * UIProcess/CoordinatedGraphics/CoordinatedLayerTreeHostProxy.messages.in:
1021         * UIProcess/CoordinatedGraphics/WebView.cpp:
1022         (WebKit::WebView::paintToCurrentGLContext):
1023         * UIProcess/WebPageProxy.cpp:
1024         (WebKit::WebPageProxy::pageExtendedBackgroundColorDidChange):
1025         Refactored to use const reference for the Color parameter.
1026         * UIProcess/WebPageProxy.h:
1027         * UIProcess/efl/WebViewEfl.cpp:
1028         (WebKit::WebViewEfl::paintToCairoSurface):
1029         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
1030         (WebKit::WebChromeClient::pageExtendedBackgroundColorDidChange):
1031         Added PLATFORM(EFL) to pass PageExtendedBackgroundColorDidChange message.
1032         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.cpp:
1033         (WebKit::CoordinatedLayerTreeHost::setBackgroundColor): Deleted.
1034         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.h:
1035         * WebProcess/WebPage/LayerTreeHost.h:
1036         (WebKit::LayerTreeHost::setBackgroundColor): Deleted.
1037         * WebProcess/WebPage/WebPage.cpp:
1038         (WebKit::WebPage::mainFrameDidLayout):
1039
1040 2014-09-18  Jeremy Jones  <jeremyj@apple.com>
1041
1042         Improve fullscreen video rotation animation.
1043         https://bugs.webkit.org/show_bug.cgi?id=136870
1044
1045         Reviewed by Simon Fraser.
1046
1047         Remove WKCAContext from LayerHostingContext and use a fencePort to synchronize animation between processes.
1048
1049         * Platform/mac/LayerHostingContext.h: add setFencePort. Remove WKCAContext.
1050         * Platform/mac/LayerHostingContext.mm:
1051         (WebKit::LayerHostingContext::createForPort): Remove WKCAContext.
1052         (WebKit::LayerHostingContext::createForExternalHostingProcess): ditto
1053         (WebKit::LayerHostingContext::setRootLayer): ditto
1054         (WebKit::LayerHostingContext::rootLayer): ditto
1055         (WebKit::LayerHostingContext::contextID): ditto
1056         (WebKit::LayerHostingContext::invalidate): ditto
1057         (WebKit::LayerHostingContext::setColorSpace): ditto
1058         (WebKit::LayerHostingContext::colorSpace): ditto
1059         (WebKit::LayerHostingContext::setFencePort): added
1060         * UIProcess/ios/WebVideoFullscreenManagerProxy.mm:
1061         (WebKit::WebVideoFullscreenManagerProxy::setVideoLayerFrame): 
1062         * WebProcess/ios/WebVideoFullscreenManager.h:
1063         * WebProcess/ios/WebVideoFullscreenManager.messages.in: add fence port parameter
1064         * WebProcess/ios/WebVideoFullscreenManager.mm: ditto
1065         (WebKit::WebVideoFullscreenManager::didSetupFullscreen): ditto
1066         (WebKit::WebVideoFullscreenManager::setVideoLayerFrameFenced): ditto
1067
1068 2014-09-18  Simon Fraser  <simon.fraser@apple.com>
1069
1070         Avoid divide by zero when we get an empty rect while snapshotting a node
1071         https://bugs.webkit.org/show_bug.cgi?id=136932
1072         rdar://problem/18383473
1073
1074         Reviewed by Dean Jackson.
1075         
1076         renderer()->paintingRootRect() can return an empty rect for some inline configurations,
1077         for example an <a> containing a floated <span>
1078         
1079         When this occurs, avoid a divide by zero and return a null snapshot image.
1080
1081         * WebProcess/WebPage/WebPage.cpp:
1082         (WebKit::WebPage::snapshotNode):
1083
1084 2014-09-18  Carlos Garcia Campos  <cgarcia@igalia.com>
1085
1086         Incorrect pending API request URL when loading an HTML string
1087         https://bugs.webkit.org/show_bug.cgi?id=136913
1088
1089         Reviewed by Alexey Proskuryakov.
1090
1091         Use about:blank as pending API request URL when the given base URL
1092         is empty, otherwise use the given base URL.
1093
1094         * UIProcess/WebPageProxy.cpp:
1095         (WebKit::WebPageProxy::loadHTMLString):
1096
1097 2014-09-18  Tim Horton  <timothy_horton@apple.com>
1098
1099         Occasional unreproducible crashes in MessageReceiverMap::dispatchMessage
1100         https://bugs.webkit.org/show_bug.cgi?id=136909
1101         <rdar://problem/17758325>
1102
1103         Reviewed by Anders Carlsson.
1104
1105         * UIProcess/API/Cocoa/WKWebView.mm:
1106         (-[WKWebView dealloc]):
1107         We're seeing some messages dispatched on the WebContext that end up
1108         attempting to call dispatchMessage on a freed MessageReceiver.
1109         The WKRemoteObjectRegistry message receiver is added to the WebContext
1110         message receiver map, but never removed, despite the WebContext easily
1111         outliving the WKWebView that owns the remote object registry.
1112
1113 2014-09-17  Rohit Kumar  <kumar.rohit@samsung.com>
1114
1115         [EFL][WK2] Use the correct enum for control key in Ewk_Event_Modifiers in ewk_navigation_policy_decision.cpp
1116         https://bugs.webkit.org/show_bug.cgi?id=136740
1117
1118         Reviewed by Gyuyoung Kim.
1119
1120         * UIProcess/API/efl/ewk_navigation_policy_decision.cpp:
1121         (toEwkEventModifiers):
1122
1123 2014-09-17  Daniel Bates  <dabates@apple.com>
1124
1125         Unreviewed, rolling out r173695.
1126
1127         Broke building third-party Legacy WebKit apps; will
1128         investigate offline
1129
1130         Reverted changeset:
1131
1132         "[iOS] Make WebCore build with public iOS SDK"
1133         https://bugs.webkit.org/show_bug.cgi?id=136487
1134         http://trac.webkit.org/changeset/173695
1135
1136 2014-09-17  Simon Fraser  <simon.fraser@apple.com>
1137
1138         Fix an issue that caused video playback to not always use high resolution streams
1139         https://bugs.webkit.org/show_bug.cgi?id=136879
1140         rdar://problem/18316542
1141
1142         Reviewed by Eric Carlson.
1143         
1144         The underlying video framework expects to be able to use -[CALayer convertRect:toLayer:nil] on
1145         the video layer to obtain information about the display resolution of the video,
1146         including the device scale factor. This doesn't work for layers in the web process,
1147         which are remotely hosted into the UI process.
1148         
1149         For now, use a workaround which involves putting a scale transform equivalent to
1150         the device scale factor on the web process layer, and the inverse scale on the 
1151         hosting layer in the UI process.
1152         
1153         We have to do this in two places, for in-page video, and for fullscreen video.
1154
1155         * Shared/mac/RemoteLayerTreeTransaction.h: Add hostingDeviceScaleFactor to the LayerCreation
1156         properties.
1157         * Shared/mac/RemoteLayerTreeTransaction.mm:
1158         (WebKit::RemoteLayerTreeTransaction::LayerCreationProperties::LayerCreationProperties):
1159         (WebKit::RemoteLayerTreeTransaction::LayerCreationProperties::encode):
1160         (WebKit::RemoteLayerTreeTransaction::LayerCreationProperties::decode):
1161         * UIProcess/ios/RemoteLayerTreeHostIOS.mm:
1162         (-[WKRemoteView initWithFrame:contextID:hostingDeviceScaleFactor:]): Set the inverse scale
1163         transform on the layer.
1164         (WebKit::RemoteLayerTreeHost::createLayer):
1165         (-[WKRemoteView initWithFrame:contextID:]): Deleted.
1166         * UIProcess/ios/WebVideoFullscreenManagerProxy.h:
1167         * UIProcess/ios/WebVideoFullscreenManagerProxy.messages.in:
1168         * UIProcess/ios/WebVideoFullscreenManagerProxy.mm:
1169         (WebKit::WebVideoFullscreenManagerProxy::setupFullscreenWithID):
1170         * WebProcess/WebPage/mac/PlatformCALayerRemoteCustom.mm:
1171         (WebKit::PlatformCALayerRemoteCustom::PlatformCALayerRemoteCustom):
1172         * WebProcess/WebPage/mac/RemoteLayerTreeContext.h:
1173         (WebKit::RemoteLayerTreeContext::deviceScaleFactor):
1174         * WebProcess/WebPage/mac/RemoteLayerTreeContext.mm:
1175         (WebKit::RemoteLayerTreeContext::layerWasCreated):
1176         * WebProcess/ios/WebVideoFullscreenManager.mm:
1177         (WebKit::WebVideoFullscreenManager::enterFullscreenForNode):
1178         (WebKit::WebVideoFullscreenManager::didSetupFullscreen):
1179
1180 2014-09-17  Gavin Barraclough  <baraclough@apple.com>
1181
1182         Aways have a PageThrottler (sometimes have a UserActivity::Impl)
1183         https://bugs.webkit.org/show_bug.cgi?id=136892
1184
1185         Reviewed by Geoffrey Garen.
1186
1187         Some instances of Page have a PageThrottler to track activity on the Page, and some do not.
1188         (Specifically, those created from WebPage in WK2 do, those related to WK1, SVG & inspector do not).
1189
1190         We do this for three reasons:
1191             * We do not need to take AppNap assertions on WK1.
1192             * Some Pages do not track their visibility correctly, and would always claim to be visible.
1193             * Page VisibilityState is not set until after construction, so if we instantiate
1194
1195         Creating the entire PageThrottler lazily has the drawback that we have to check for its existence at
1196         numerous points throughout the code, and we'll miss activity that occurs between the Page being created
1197         & the PageThrottler added to it (really a theoretical problem right now, since they're currently always
1198         created pretty much back to back).
1199
1200         Instead, Page should always have a PageThrottler, & instead make the UserActivity::Impl on the
1201         PageThrottler be added later.
1202
1203         * WebProcess/Plugins/Netscape/NPRuntimeObjectMap.cpp:
1204         (WebKit::NPRuntimeObjectMap::evaluate):
1205             - createPageThrottler -> enablePageThrottler
1206         * WebProcess/WebPage/WebPage.cpp:
1207         (WebKit::WebPage::WebPage):
1208         (WebKit::WebPage::mouseEvent):
1209         (WebKit::WebPage::wheelEvent):
1210         (WebKit::WebPage::keyEvent):
1211             - Page::pageThrottler now returns a reference rather than a pointer
1212
1213 2014-09-17  Daniel Bates  <dabates@apple.com>
1214
1215         [iOS] Make WebCore build with public iOS SDK
1216         https://bugs.webkit.org/show_bug.cgi?id=136487
1217
1218         Reviewed by David Kilzer.
1219
1220         Update WebKit2 source files to include the wrapper SPI headers instead of the corresponding
1221         actual SPI header(s).
1222
1223         * Platform/mac/SharedMemoryMac.cpp:
1224         * Shared/ios/NativeWebTouchEventIOS.mm:
1225         * Shared/mac/RemoteLayerBackingStore.mm:
1226         * Shared/mac/RemoteLayerTreePropertyApplier.mm:
1227         * UIProcess/API/Cocoa/WKWebView.mm:
1228         * UIProcess/ios/WKPDFPageNumberIndicator.mm:
1229         * UIProcess/ios/WKScrollView.mm:
1230         * UIProcess/ios/WebMemoryPressureHandlerIOS.mm:
1231         * UIProcess/ios/forms/WKAirPlayRoutePicker.mm:
1232         * WebProcess/WebPage/WebPage.cpp:
1233
1234 2014-09-17  Gavin Barraclough  <barraclough@apple.com>
1235
1236         DOM timer throttling for hidden plugins
1237         https://bugs.webkit.org/show_bug.cgi?id=136197
1238
1239         Reviewed by Geoff Garen & Andreas Kling.
1240
1241         For non-visible web pages we slow timers (since they can't be driving animations, etc).
1242         We should do the same for plugins.
1243
1244         * PluginProcess/WebProcessConnection.cpp:
1245         * WebProcess/Plugins/Netscape/NPRuntimeObjectMap.cpp:
1246             - remove now redundant includes.
1247         * WebProcess/Plugins/PluginView.h:
1248             - audioHardwareActivity is now virtual, override.
1249
1250 2014-09-17  Carlos Garcia Campos  <cgarcia@igalia.com>
1251
1252         [GTK] WebKitWebView::load-failed-with-tls-errors should receive the failing URI instead of a host
1253         https://bugs.webkit.org/show_bug.cgi?id=136889
1254
1255         Reviewed by Gustavo Noronha Silva.
1256
1257         We were passing a host for two different reasons, first because
1258         it's more convenient to add an exception with
1259         webkit_web_context_allow_tls_certificate_for_host(), but also
1260         because we were assuming the active URI is the failing URI in case
1261         of failure. This assumption is correct because our current code
1262         does that, but I'm not sure we are doing it on purpose. That
1263         behaviour is not documented anywhere and it's not what WebKit2 does
1264         internaly.
1265
1266         * UIProcess/API/gtk/WebKitWebView.cpp:
1267         (webkit_web_view_class_init):
1268         (webkitWebViewLoadFailedWithTLSErrors):
1269         * UIProcess/API/gtk/WebKitWebView.h:
1270
1271 2014-09-16  Carlos Garcia Campos  <cgarcia@igalia.com>
1272
1273         [GTK] Fix layering violations in PasteboardGtk
1274         https://bugs.webkit.org/show_bug.cgi?id=136802
1275
1276         Reviewed by Darin Adler.
1277
1278         * WebProcess/WebCoreSupport/gtk/WebEditorClientGtk.cpp:
1279         (WebKit::WebEditorClient::updateGlobalSelection): Use new API to
1280         update the global selection.
1281
1282 2014-09-16  Carlos Garcia Campos  <cgarcia@igalia.com>
1283
1284         DragData should not depend on Clipboard, DocumentFragment, and Document
1285         https://bugs.webkit.org/show_bug.cgi?id=21358
1286
1287         Reviewed by Darin Adler.
1288
1289         * UIProcess/WebPageProxy.cpp:
1290         (WebKit::WebPageProxy::performDragControllerAction): Update to API
1291         change in DragData::asURL().
1292
1293 2014-09-16  Daniel Bates  <dabates@apple.com>
1294
1295         [iOS] Add iOS SDK name and version suffix to WebKitSystemInterface debug/release product name
1296         https://bugs.webkit.org/show_bug.cgi?id=136862
1297
1298         Reviewed by David Kilzer.
1299
1300         * Configurations/DebugRelease.xcconfig:
1301
1302 2014-09-16  Enrica Casucci  <enrica@apple.com>
1303
1304         Remove PLATFORM(IOS) from WebCore/editing (Part 3).
1305         https://bugs.webkit.org/show_bug.cgi?id=136474
1306
1307         Reviewed by Benjamin Poulain.
1308
1309         This is the updated version of the patch that was landed in r173340.
1310         This patch removes the use of PLATFORM(IOS) from TextAffinity.h
1311         and removes the assumption that EAffinity values match NSSelectionAffinity
1312         values. It also removes the includes in TextAffinity.h, creating the need to
1313         include explicitly the files when necessary.
1314
1315         * WebProcess/InjectedBundle/API/mac/WKDOMInternals.mm:
1316         * WebProcess/WebPage/WKAccessibilityWebPageObjectIOS.mm:
1317
1318 2014-09-16  Dan Bernstein  <mitz@apple.com>
1319
1320         Standardized the return type of a delegate method.
1321
1322         Rubber-stamped by Anders Carlsson.
1323
1324         * UIProcess/API/Cocoa/WKUIDelegatePrivate.h: Changed a return type from bool to BOOL.
1325
1326 2014-09-16  Tomas Popela  <tpopela@redhat.com>
1327
1328         [GTK] Typo in  webkit_security_manager_register_uri_scheme_as_empty_document documentation
1329         https://bugs.webkit.org/show_bug.cgi?id=136852
1330
1331         Reviewed by Carlos Garcia Campos.
1332
1333         * UIProcess/API/gtk/WebKitSecurityManager.cpp:
1334
1335 2014-09-13  Gavin Barraclough  <baraclough@apple.com>
1336
1337         Should call [BKSProcessAssertion invalidate]
1338         https://bugs.webkit.org/show_bug.cgi?id=136804
1339         <rdar://problem/17897780>
1340
1341         Reviewed by Darin Adler.
1342
1343         We should invalidate the process assertion before releasing it. Fortunately this is really easy,
1344         since there is a simple 1:1 relationship with ProcessAssertion, with their lifetimes matching exactly.
1345
1346         * UIProcess/ProcessAssertion.cpp:
1347         (WebKit::ProcessAssertion::~ProcessAssertion):
1348             - no-op implementation.
1349         * UIProcess/ProcessAssertion.h:
1350             - added destructor.
1351         * UIProcess/ios/ProcessAssertionIOS.mm:
1352         (WebKit::ProcessAssertion::~ProcessAssertion):
1353             - destructor invalidates the BKSProcessAssertion.
1354
1355 2014-09-15  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
1356
1357         REGRESSION(r170243): [EFL][WK2] Dirty image is shown when new page is loading on fixed layout 
1358         https://bugs.webkit.org/show_bug.cgi?id=136568
1359
1360         Reviewed by Csaba Osztrogonác.
1361
1362         r170243 landed wrong didCommitNewPage() since it always returns false. It cause that
1363         PageViewportControllerClientEfl::didChangeVisibleContents() continues to draw dirty image on 0,0 coordinate.
1364         This patch fixes the problem.
1365
1366         * UIProcess/API/efl/EwkView.h:
1367         (EwkView::waitingForNewPage):
1368         (EwkView::didCommitNewPage):
1369         * UIProcess/efl/PageViewportControllerClientEfl.cpp:
1370         (WebKit::PageViewportControllerClientEfl::didChangeVisibleContents):
1371
1372 2014-09-14  Chris Dumez  <cdumez@apple.com>
1373
1374         Rename Node::childNodeCount() to countChildNodes() and avoid inefficient uses
1375         https://bugs.webkit.org/show_bug.cgi?id=136789
1376
1377         Reviewed by Darin Adler.
1378
1379         Avoid calling slow Node::countChildNodes().
1380
1381         * WebProcess/WebPage/CoordinatedGraphics/WebPageCoordinatedGraphics.cpp:
1382         (WebKit::WebPage::findZoomableAreaForPoint):
1383         Replace call to "node->parentNode()->childNodeCount() != 1" by
1384         "!node->parentNode()->hasOneChild()" which is equivalent but more
1385         efficient.
1386
1387 2014-09-10  Jon Honeycutt  <jhoneycutt@apple.com>
1388
1389         Re-add the request autocomplete feature
1390
1391         <https://bugs.webkit.org/show_bug.cgi?id=136730>
1392
1393         This feature was rolled out in r148731 because it was only used by
1394         Chromium. As we consider supporting this feature, roll it back in, but
1395         leave it disabled.
1396
1397         This rolls out r148731 (which removed the feature) with small changes
1398         needed to make the code build in ToT, to match modern style, to make
1399         the tests run, and to remove unused code.
1400
1401         Reviewed by Andy Estes.
1402
1403         * Configurations/FeatureDefines.xcconfig:
1404         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
1405         (WebKit::WebFrameLoaderClient::didRequestAutocomplete):
1406         * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
1407
1408 2014-09-12  Tim Horton  <timothy_horton@apple.com>
1409
1410         Swiping back from a Twitter image to Twitter flashes to the wrong position
1411         https://bugs.webkit.org/show_bug.cgi?id=136798
1412         <rdar://problem/18324338>
1413
1414         Reviewed by Darin Adler and Sam Weinig.
1415
1416         * UIProcess/mac/ViewGestureController.h:
1417         * UIProcess/mac/ViewGestureControllerMac.mm:
1418         (WebKit::ViewGestureController::ViewGestureController):
1419         (WebKit::ViewGestureController::didFinishLoadForMainFrame):
1420         (WebKit::ViewGestureController::didSameDocumentNavigationForMainFrame):
1421         Add a 250ms repeating timer that we start in didFinishLoadForMainFrame
1422         if we are for some reason still loading, and in didSameDocumentNavigationForMainFrame
1423         unconditionally, to match behavior of the old swipe implementation.
1424
1425         Also, do the active gesture check in both of those places so that we don't
1426         start the timer if we're in the middle of a live swipe or have already torn
1427         down the snapshot (removeSwipeSnapshotAfterRepaint does this as well, so
1428         this isn't really a behavior change).
1429
1430         (WebKit::ViewGestureController::activeLoadMonitoringTimerFired):
1431         Every time the timer fires, check if we're still loading; if not,
1432         tear down the swipe snapshot (after repainting).
1433
1434         (WebKit::ViewGestureController::removeSwipeSnapshotAfterRepaint):
1435         Stop the active load monitoring timer.
1436
1437 2014-09-12  Commit Queue  <commit-queue@webkit.org>
1438
1439         Unreviewed, rolling out r173575.
1440         https://bugs.webkit.org/show_bug.cgi?id=136790
1441
1442         Failing tests (Requested by enrica on #webkit).
1443
1444         Reverted changeset:
1445
1446         "Remove PLATFORM(IOS) from WebCore/editing (Part 3)."
1447         https://bugs.webkit.org/show_bug.cgi?id=136474
1448         http://trac.webkit.org/changeset/173575
1449
1450 2014-09-12  Enrica Casucci  <enrica@apple.com>
1451
1452         Remove PLATFORM(IOS) from WebCore/editing (Part 3).
1453         https://bugs.webkit.org/show_bug.cgi?id=136474
1454
1455         Reviewed by Benjamin Poulain.
1456
1457         This is the updated version of the patch that was landed in r173340.
1458         I changed the use of IntPoint to FloatPoint since it was causing tests
1459         to fail.
1460         This patch removes the use of PLATFORM(IOS) from TextAffinity.h
1461         and removes the assumption that EAffinity values match NSSelectionAffinity
1462         values. It also removes the includes in TextAffinity.h, creating the need to
1463         include explicitly the files when necessary. It also removes the unnecessary
1464         use of platform specific types, replacing them with WebCore types.
1465
1466         * WebProcess/InjectedBundle/API/mac/WKDOMInternals.mm:
1467         * WebProcess/WebPage/WKAccessibilityWebPageObjectIOS.mm:
1468         (-[WKAccessibilityWebPageObject accessibilityHitTest:]):
1469
1470 2014-09-12  Dan Bernstein  <mitz@apple.com>
1471
1472         [Cocoa] Message generation scripts should be installed in WebKit.framework
1473         https://bugs.webkit.org/show_bug.cgi?id=136771
1474
1475         Reviewed by Anders Carlsson.
1476
1477         * DerivedSources.make: Updated for rename of Scripts/webkit2 to Scripts/webkit.
1478         * Scripts/generate-message-receiver.py:
1479         (main): Updated for rename from webkit2 to webkit.
1480         * Scripts/generate-messages-header.py:
1481         (main): Ditto.
1482         * Scripts/webkit: Renamed from Source/WebKit2/Scripts/webkit2.
1483         * Scripts/webkit/messages.py: Updated for rename.
1484         * Scripts/webkit/parser.py: Ditto.
1485         * WebKit2.xcodeproj/project.pbxproj: Moved the Copy Message Generation Scripts build phase
1486         from the WebKit2 target to the WebKit target and changed its destination to
1487         WebKit.framework/PrivateHeaders/Scripts/webkit. Removed the Remove Compiled Python Files
1488         build phase, since compiled files no longer get copied.
1489
1490 2014-09-12  Tim Horton  <timothy_horton@apple.com>
1491
1492         Flash of page scrolled to wrong origin before restoring scroll position after swiping back to CNN front page from an article
1493         https://bugs.webkit.org/show_bug.cgi?id=136788
1494         <rdar://problem/18314597>
1495
1496         Reviewed by Sam Weinig.
1497
1498         * UIProcess/mac/ViewGestureControllerMac.mm:
1499         (WebKit::ViewGestureController::didHitRenderTreeSizeThreshold):
1500         (WebKit::ViewGestureController::didFirstVisuallyNonEmptyLayoutForMainFrame):
1501         Always wait until didFinishLoadForMainFrame or didSameDocumentNavigationForMainFrame
1502         before removing the snapshot, because otherwise we don't know if the scroll
1503         position has been restored yet.
1504
1505         We should revisit this at some point, because it should be possible to
1506         determine if the scroll position has been restored appropriately, but for
1507         now it is safest to restore the antique behavior.
1508
1509 2014-09-12  Dan Bernstein  <mitz@apple.com>
1510
1511         Build fix.
1512
1513         Reverted r173564.
1514
1515         * DerivedSources.make:
1516         * Scripts/generate-message-receiver.py:
1517         (main):
1518         * Scripts/generate-messages-header.py:
1519         (main):
1520         * Scripts/webkit: Removed.
1521         * Scripts/webkit/LegacyMessageReceiver-expected.cpp: Removed.
1522         * Scripts/webkit/LegacyMessages-expected.h: Removed.
1523         * Scripts/webkit/MessageReceiver-expected.cpp: Removed.
1524         * Scripts/webkit/MessageReceiverSuperclass-expected.cpp: Removed.
1525         * Scripts/webkit/Messages-expected.h: Removed.
1526         * Scripts/webkit/MessagesSuperclass-expected.h: Removed.
1527         * Scripts/webkit/__init__.py: Removed.
1528         * Scripts/webkit/messages.py: Removed.
1529         * Scripts/webkit/messages_unittest.py: Removed.
1530         * Scripts/webkit/model.py: Removed.
1531         * Scripts/webkit/parser.py: Removed.
1532         * Scripts/webkit/test-legacy-messages.in: Removed.
1533         * Scripts/webkit/test-messages.in: Removed.
1534         * Scripts/webkit/test-superclass-messages.in: Removed.
1535         * Scripts/webkit2: Copied from Scripts/webkit2.
1536         * WebKit2.xcodeproj/project.pbxproj:
1537
1538 2014-09-11  Andy Estes  <aestes@apple.com>
1539
1540         [WebKit2] WKImageCreateCGImage crashes when passed a null WKImage
1541         https://bugs.webkit.org/show_bug.cgi?id=136768
1542
1543         Reviewed by Tim Horton.
1544
1545         WKImageCreateFromCGImage can return null, so it only seems fair that WKImageCreateCGImage should tolerate null.
1546
1547         * Shared/API/c/cg/WKImageCG.cpp:
1548         (WKImageCreateCGImage):
1549
1550 2014-09-12  Dan Bernstein  <mitz@apple.com>
1551
1552         [Cocoa] Message generation scripts should be installed in WebKit.framework
1553         https://bugs.webkit.org/show_bug.cgi?id=136771
1554
1555         Reviewed by Anders Carlsson.
1556
1557         * DerivedSources.make: Updated for rename of Scripts/webkit2 to Scripts/webkit.
1558         * Scripts/generate-message-receiver.py:
1559         (main): Updated for rename from webkit2 to webkit.
1560         * Scripts/generate-messages-header.py:
1561         (main): Ditto.
1562         * Scripts/webkit: Renamed from Source/WebKit2/Scripts/webkit2.
1563         * Scripts/webkit/messages.py: Updated for rename.
1564         * Scripts/webkit/parser.py: Ditto.
1565         * WebKit2.xcodeproj/project.pbxproj: Moved the Copy Message Generation Scripts build phase
1566         from the WebKit2 target to the WebKit target and changed its destination to
1567         WebKit.framework/PrivateHeaders/Scripts/webkit. Removed the Remove Compiled Python Files
1568         build phase, since compiled files no longer get copied.
1569
1570 2014-09-12  Michael Catanzaro  <mcatanzaro@igalia.com>
1571
1572         [GTK] Use a nicer HTTP authentication dialog
1573         https://bugs.webkit.org/show_bug.cgi?id=136615
1574
1575         Reviewed by Carlos Garcia Campos.
1576
1577         * UIProcess/API/gtk/WebKitAuthenticationDialog.cpp:
1578         (webkitAuthenticationDialogInitialize): Use a nicer layout.
1579         (packTwoColumnLayoutInBox): Deleted.
1580         (createLabel): Deleted.
1581         (createEntry): Deleted.
1582
1583 2014-09-12  Carlos Garcia Campos  <cgarcia@igalia.com>
1584
1585         REGRESSION(r173423): CertificateInfo is never sent to the UI process when using shared secondary process model
1586         https://bugs.webkit.org/show_bug.cgi?id=136669
1587
1588         Reviewed by Antti Koivisto.
1589
1590         * WebProcess/Network/WebResourceLoadScheduler.cpp:
1591         (WebKit::WebResourceLoadScheduler::scheduleLoad): Use
1592         ResourceLoader::shouldIncludeCertificateInfo() to initialize
1593         needsCertificateInfo parameter.
1594
1595 2014-09-11  Ryuan Choi  <ryuan.choi@gmail.com>
1596
1597         [EFL][CoordinatedGraphics] Move CoordinatedGraphicsScene and CoordinatedBackingStore to WebKit2
1598         https://bugs.webkit.org/show_bug.cgi?id=136770
1599
1600         Reviewed by Gyuyoung Kim.
1601
1602         CoordinatedGraphicsScene and CoordinatedBackingStore is only for UIProcess.
1603         This patch moved them from WebCore to WebKit2/UIProcess/CoordinatedGraphics/.
1604
1605         * PlatformEfl.cmake:
1606         * UIProcess/API/CoordinatedGraphics/WKCoordinatedScene.cpp:
1607         * UIProcess/CoordinatedGraphics/CoordinatedBackingStore.cpp: Renamed from Source/WebCore/platform/graphics/texmap/coordinated/CoordinatedBackingStore.cpp.
1608         * UIProcess/CoordinatedGraphics/CoordinatedBackingStore.h: Renamed from Source/WebCore/platform/graphics/texmap/coordinated/CoordinatedBackingStore.h.
1609         * UIProcess/CoordinatedGraphics/CoordinatedGraphicsScene.cpp: Renamed from Source/WebCore/platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.cpp.
1610         * UIProcess/CoordinatedGraphics/CoordinatedGraphicsScene.h: Renamed from Source/WebCore/platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.h.
1611         * UIProcess/CoordinatedGraphics/CoordinatedLayerTreeHostProxy.h:
1612         * UIProcess/CoordinatedGraphics/WebView.cpp:
1613         * UIProcess/efl/WebViewEfl.cpp:
1614
1615 2014-09-11  Bear Travis  <betravis@adobe.com>
1616
1617         [CSS Font Loading] Enable CSS Font Loading on Mac
1618         https://bugs.webkit.org/show_bug.cgi?id=135473
1619
1620         Reviewed by Antti Koivisto.
1621
1622         Enable CSS Font Loading in FeatureDefines.
1623
1624         * Configurations/FeatureDefines.xcconfig:
1625
1626 2014-09-11  Youenn Fablet  <youenn.fablet@crf.canon.fr>
1627
1628         [WK2] Authentication dialog is displayed for cross-origin XHR
1629         https://bugs.webkit.org/show_bug.cgi?id=131349
1630
1631         Reviewed by Alexey Proskuryakov.
1632
1633         Precomputing client credential policy in the Web Process before sending the resource load task to the Network Process.
1634
1635         * NetworkProcess/NetworkResourceLoader.cpp:
1636         (WebKit::NetworkResourceLoader::didReceiveAuthenticationChallenge): Added an ASSERT to ensure that credential policy is never set to DoNotAskClientForCrossOriginCredentials.
1637         * WebProcess/Network/WebResourceLoadScheduler.cpp:
1638         (WebKit::WebResourceLoadScheduler::scheduleLoad): Precomputing client credential policy to handle the case of cross-origin requests.
1639         * WebProcess/Network/WebResourceLoader.cpp:
1640         (WebKit::WebResourceLoader::willSendRequest): Added a TODO to check whether redirections need a specific handling.
1641
1642 2014-09-11  Carlos Garcia Campos  <cgarcia@igalia.com>
1643
1644         [GTK] Merge WebKitAuthenticationWidget into WebKitAuthenticationDialog
1645         https://bugs.webkit.org/show_bug.cgi?id=136700
1646
1647         Reviewed by Sergio Villar Senin.
1648
1649         Copy WebKitAuthenticationWidget implementation inside
1650         WebKitAuthenticationDialog using a normal GtkBox instead.
1651
1652         * UIProcess/API/gtk/WebKitAuthenticationDialog.cpp:
1653         (okButtonClicked):
1654         (cancelButtonClicked):
1655         (packTwoColumnLayoutInBox):
1656         (createLabel):
1657         (createEntry):
1658         (webkitAuthenticationDialogInitialize): Remove the
1659         CredentialStorageMode parameter since it's now a member.
1660         (webkitAuthenticationDialogNew): Initialize the
1661         CredentialStorageMode member too.
1662         * UIProcess/API/gtk/WebKitAuthenticationDialog.h:
1663
1664 2014-09-10  Antti Koivisto  <antti@apple.com>
1665
1666         NetworkResourceLoader cleanups
1667         https://bugs.webkit.org/show_bug.cgi?id=136701
1668
1669         Reviewed by Darin Adler.
1670
1671         After smashing NetworkResourceLoader together with the clients it can be made nicer.
1672
1673         * NetworkProcess/NetworkResourceLoadScheduler.cpp:
1674         (WebKit::NetworkResourceLoadScheduler::scheduleLoader):
1675         (WebKit::NetworkResourceLoadScheduler::removeLoader):
1676         * NetworkProcess/NetworkResourceLoader.cpp:
1677         (WebKit::NetworkResourceLoader::SynchronousLoadData::SynchronousLoadData):
1678
1679             The original request is now part of the loader.
1680
1681         (WebKit::sendReplyToSynchronousRequest):
1682         (WebKit::NetworkResourceLoader::NetworkResourceLoader):
1683
1684             Instead of copying everything out from NetworkResourceLoadParameters just include the whole thing as a const field.
1685             SanboxExtension construction moves to NetworkResourceLoadParameters::decode()
1686             Stuff that is related to starting the load moves to start().
1687
1688         (WebKit::NetworkResourceLoader::~NetworkResourceLoader):
1689         (WebKit::NetworkResourceLoader::start):
1690         (WebKit::NetworkResourceLoader::setDefersLoading):
1691
1692             Eliminate m_deferredRequest since we now always remember the original request.
1693
1694         (WebKit::NetworkResourceLoader::cleanup):
1695         (WebKit::NetworkResourceLoader::didConvertHandleToDownload):
1696         (WebKit::NetworkResourceLoader::abort):
1697         (WebKit::NetworkResourceLoader::didReceiveResponseAsync):
1698         (WebKit::NetworkResourceLoader::didFail):
1699         (WebKit::NetworkResourceLoader::willSendRequestAsync):
1700         (WebKit::NetworkResourceLoader::continueWillSendRequest):
1701
1702             Eliminate unnecessary m_suggestedRequestForWillSendRequest.
1703
1704         (WebKit::NetworkResourceLoader::wasBlocked):
1705         (WebKit::NetworkResourceLoader::cannotShowURL):
1706         (WebKit::NetworkResourceLoader::shouldUseCredentialStorage):
1707         (WebKit::NetworkResourceLoader::didReceiveAuthenticationChallenge):
1708         (WebKit::NetworkResourceLoader::receivedCancellation):
1709         (WebKit::NetworkResourceLoader::startBufferingTimerIfNeeded):
1710         (WebKit::NetworkResourceLoader::consumeSandboxExtensions):
1711         (WebKit::NetworkResourceLoader::invalidateSandboxExtensions):
1712         (WebKit::NetworkResourceLoader::sendAbortingOnFailure):
1713         * NetworkProcess/NetworkResourceLoader.h:
1714         (WebKit::NetworkResourceLoader::originalRequest):
1715         (WebKit::NetworkResourceLoader::currentRequest):
1716         (WebKit::NetworkResourceLoader::sessionID):
1717         (WebKit::NetworkResourceLoader::defersLoading):
1718         (WebKit::NetworkResourceLoader::isLoadingMainResource):
1719         (WebKit::NetworkResourceLoader::request): Deleted.
1720         (WebKit::NetworkResourceLoader::sendAbortingOnFailure): Deleted.
1721
1722             Made private and moved to cpp.
1723
1724         * NetworkProcess/mac/NetworkDiskCacheMonitor.mm:
1725         (WebKit::NetworkDiskCacheMonitor::NetworkDiskCacheMonitor):
1726
1727             Use original request instead of the current one. This might fix a bug where we didn't use file backing over redirects.
1728
1729         * Shared/Network/NetworkResourceLoadParameters.cpp:
1730         (WebKit::NetworkResourceLoadParameters::decode):
1731
1732             Decode to SanboxExtensions to the actual type rather than a handle.
1733
1734         * Shared/Network/NetworkResourceLoadParameters.h:
1735
1736 2014-09-10  Michael Catanzaro  <mcatanzaro@igalia.com>
1737
1738         [GTK] allow overwriting destination of download
1739         https://bugs.webkit.org/show_bug.cgi?id=136372
1740
1741         Reviewed by Carlos Garcia Campos.
1742
1743         * UIProcess/API/gtk/WebKitDownload.cpp:
1744         (webkitDownloadGetProperty): Added
1745         (webkit_download_class_init): Install webkitDownloadGetProperty
1746         (webkitDownloadDecideDestinationWithSuggestedFilename): Add
1747         allowOverwrite parameter and set it appropriately
1748         (webkit_download_get_allow_overwrite): Added
1749         (webkit_download_set_allow_overwrite): Added
1750         * UIProcess/API/gtk/WebKitDownload.h: New API
1751         * UIProcess/API/gtk/WebKitDownloadClient.cpp:
1752         (decideDestinationWithSuggestedFilename): Pass allowOverwrite to
1753         webkitDownloadDecideDestinationWithSuggestedFilename
1754         * UIProcess/API/gtk/WebKitDownloadPrivate.h: Add allowOverwrite
1755         parameter to webkitDownloadDecideDestinationWithSuggestedFilename
1756         * UIProcess/API/gtk/docs/webkit2gtk-sections.txt: New API
1757
1758 2014-09-10  Rohit Kumar  <kumar.rohit@samsung.com>
1759
1760         [GTK] Clean up the WebKit build from unused parameter warning in Webkit2/UIProcess module
1761         https://bugs.webkit.org/show_bug.cgi?id=136670
1762
1763         Reviewed by Martin Robinson.
1764
1765         * UIProcess/API/gtk/PageClientImpl.cpp:
1766         (WebKit::PageClientImpl::didSameDocumentNavigationForMainFrame):
1767
1768 2014-09-09  Enrica Casucci  <enrica@apple.com>
1769
1770         REGRESSION (WebKit2): -webkit-touch-callout: none has no effect.
1771         https://bugs.webkit.org/show_bug.cgi?id=136685
1772         rdar://problem/17629840
1773
1774         Reviewed by Benjamin Poulain.
1775
1776         We need to check if the touch callout is enabled for the element before starting
1777         the long press gesture.
1778         The information about the touch callout is returned together with the rest of data
1779         returned by the InteractionInformationAtPosition.
1780
1781         * Shared/InteractionInformationAtPosition.cpp:
1782         (WebKit::InteractionInformationAtPosition::encode):
1783         (WebKit::InteractionInformationAtPosition::decode):
1784         * Shared/InteractionInformationAtPosition.h:
1785         (WebKit::InteractionInformationAtPosition::InteractionInformationAtPosition):
1786         * UIProcess/ios/WKContentViewInteraction.mm:
1787         (-[WKContentView _actionForLongPress]):
1788         * WebProcess/WebPage/ios/WebPageIOS.mm:
1789         (WebKit::WebPage::getPositionInformation):
1790
1791 2014-09-09  Benjamin Poulain  <bpoulain@apple.com>
1792
1793         Disable the "unreachable-code" warning
1794         https://bugs.webkit.org/show_bug.cgi?id=136677
1795
1796         Reviewed by Darin Adler.
1797
1798         * Configurations/Base.xcconfig:
1799
1800 2014-09-09  Dan Bernstein  <mitz@apple.com>
1801
1802         [Cocoa] -[WKBackForwardList backList] contains an unnecessary nil check
1803         https://bugs.webkit.org/show_bug.cgi?id=136680
1804
1805         Reviewed by Anders Carlsson.
1806
1807         * UIProcess/API/Cocoa/WKBackForwardList.mm:
1808         (-[WKBackForwardList backList]): Removed nil check.
1809         (-[WKBackForwardList forwardList]): Ditto.
1810
1811 2014-09-09  Tim Horton  <timothy_horton@apple.com>
1812
1813         Make DrawingArea a real MessageReceiver
1814         https://bugs.webkit.org/show_bug.cgi?id=136438
1815
1816         Reviewed by Darin Adler.
1817
1818         * WebProcess/WebPage/DrawingArea.cpp:
1819         (WebKit::DrawingArea::DrawingArea):
1820         (WebKit::DrawingArea::~DrawingArea):
1821         * WebProcess/WebPage/DrawingArea.h:
1822         * WebProcess/WebPage/DrawingArea.messages.in:
1823         * WebProcess/WebPage/WebPage.cpp:
1824         (WebKit::WebPage::WebPage):
1825         (WebKit::WebPage::~WebPage):
1826         (WebKit::WebPage::didReceiveMessage):
1827         Make DrawingArea a real MessageReceiver instead of a LegacyReceiver that
1828         jumps through WebPage to receive its messages.
1829
1830 2014-09-08  Antti Koivisto  <antti@apple.com>
1831
1832         Pass certificate info as part of ResourceResponse
1833         https://bugs.webkit.org/show_bug.cgi?id=136611
1834
1835         Reviewed by Darin Adler.
1836
1837         * NetworkProcess/NetworkResourceLoader.cpp:
1838         (WebKit::NetworkResourceLoader::didReceiveResponseAsync):
1839
1840             Initialize the certificate info only if requested.
1841
1842         * WebProcess/Network/WebResourceLoader.cpp:
1843         (WebKit::WebResourceLoader::didReceiveResponse):
1844         (WebKit::WebResourceLoader::didReceiveResponseWithCertificateInfo): Deleted.
1845
1846             Rename didReceiveResponseWithCertificateInfo -> didReceiveResponse as it is now part of the response.
1847
1848         * WebProcess/Network/WebResourceLoader.h:
1849         * WebProcess/Network/WebResourceLoader.messages.in:
1850         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
1851
1852             Request certificate info for the main resource only.
1853
1854         (WebKit::WebFrameLoaderClient::dispatchDidCommitLoad):
1855         * WebProcess/WebPage/WebFrame.cpp:
1856         (WebKit::WebFrame::certificateInfo):
1857
1858 2014-09-08  Shivakumar JM  <shiva.jm@samsung.com>
1859
1860         [WebKit2] Fix build error in WebKit2/WebProcess module
1861         https://bugs.webkit.org/show_bug.cgi?id=136667
1862
1863         Reviewed by Darin Adler.
1864
1865         Fix the build error by handling default case.
1866
1867         * WebProcess/Network/WebResourceLoadScheduler.cpp:
1868         (WebKit::maximumBufferingTime):
1869
1870 2014-09-08  Simon Fraser  <simon.fraser@apple.com>
1871
1872         Fix the iOS build.
1873
1874         * Shared/EntryPointUtilities/mac/XPCService/XPCServiceMain.Development.mm:
1875         * Shared/EntryPointUtilities/mac/XPCService/XPCServiceMain.mm:
1876
1877 2014-09-08  Eva Balazsfalvi  <evab.u-szeged@partner.samsung.com>
1878
1879         Remove FILTERS flag
1880         https://bugs.webkit.org/show_bug.cgi?id=136571
1881
1882         Reviewed by Darin Adler.
1883
1884         * Configurations/FeatureDefines.xcconfig:
1885
1886 2014-09-08  Antti Koivisto  <antti@apple.com>
1887
1888         Buffer images on web process side
1889         https://bugs.webkit.org/show_bug.cgi?id=136631
1890
1891         Reviewed by Darin Adler.
1892
1893         We can substantially reduce IPC and decoding time for large images by allowing some buffering.
1894
1895         This patch makes us buffer image data up to 0.5s before sending it over to the web process.
1896
1897         * NetworkProcess/NetworkResourceLoader.cpp:
1898         (WebKit::NetworkResourceLoader::NetworkResourceLoader):
1899         (WebKit::NetworkResourceLoader::cleanup):
1900         (WebKit::NetworkResourceLoader::didReceiveBuffer):
1901
1902             Start the timer.
1903
1904         (WebKit::NetworkResourceLoader::didFinishLoading):
1905         (WebKit::NetworkResourceLoader::startBufferingTimerIfNeeded):
1906         (WebKit::NetworkResourceLoader::bufferingTimerFired):
1907         (WebKit::NetworkResourceLoader::sendBuffer):
1908
1909             Send the data when the timer fires or the load finishes, whichever happens first.
1910
1911         * NetworkProcess/NetworkResourceLoader.h:
1912         * Platform/IPC/ArgumentCoders.h:
1913
1914             Support encoding std::chrono::duration
1915
1916         * Shared/Network/NetworkResourceLoadParameters.cpp:
1917         (WebKit::NetworkResourceLoadParameters::NetworkResourceLoadParameters):
1918         (WebKit::NetworkResourceLoadParameters::encode):
1919         (WebKit::NetworkResourceLoadParameters::decode):
1920         * Shared/Network/NetworkResourceLoadParameters.h:
1921
1922             Pass maximimum buffering duration.
1923
1924         * WebProcess/Network/WebResourceLoadScheduler.cpp:
1925         (WebKit::maximumBufferingTime):
1926
1927             Deterimine duration from the resource type.
1928             Enabled full buffering for font resources. They are not decoded incrementally.
1929
1930         (WebKit::WebResourceLoadScheduler::scheduleLoad):
1931
1932 2014-09-08  Dan Bernstein  <mitz@apple.com>
1933
1934         HAVE(VOUCHERS) is not available outside of WebKit2
1935         https://bugs.webkit.org/show_bug.cgi?id=136637
1936
1937         Reviewed by Tim Horton.
1938
1939         * config.h: Moved the definition of HAVE_VOUCHERS from here to wtf’s Platform.h.
1940
1941 2014-09-08  Tim Horton  <timothy_horton@apple.com>
1942
1943         Try to fix the build after r173383, part 4.
1944
1945         * Shared/EntryPointUtilities/mac/XPCService/XPCServiceMain.Development.mm:
1946         Machine finally caught up so I could actually test the fixes!
1947
1948 2014-09-08  Tim Horton  <timothy_horton@apple.com>
1949
1950         Try to fix the build after r173383, part 3.
1951
1952         * Shared/EntryPointUtilities/mac/XPCService/XPCServiceMain.mm:
1953
1954 2014-09-08  Dan Bernstein  <mitz@apple.com>
1955
1956         Build fix.
1957
1958         * Platform/IPC/Connection.h:
1959
1960 2014-09-06  Sam Weinig  <sam@webkit.org>
1961
1962         XPCPtr should be converted into an all purpose smart pointer for os_objects
1963         https://bugs.webkit.org/show_bug.cgi?id=136602
1964
1965         Reviewed by Darin Adler.
1966
1967         * DatabaseProcess/EntryPoint/mac/XPCService/DatabaseServiceEntryPoint.mm:
1968         (DatabaseServiceInitializer):
1969         * NetworkProcess/EntryPoint/mac/XPCService/NetworkServiceEntryPoint.mm:
1970         (WebKit::NetworkServiceInitializerDelegate::NetworkServiceInitializerDelegate):
1971         (NetworkServiceInitializer):
1972         * Platform/IPC/Connection.h:
1973         (IPC::Connection::Identifier::Identifier):
1974         * Platform/IPC/mac/ConnectionMac.mm:
1975         (IPC::ConnectionTerminationWatchdog::createConnectionTerminationWatchdog):
1976         (IPC::ConnectionTerminationWatchdog::ConnectionTerminationWatchdog):
1977         * Platform/IPC/mac/XPCPtr.h: Removed.
1978         * PluginProcess/EntryPoint/mac/XPCService/PluginServiceEntryPoint.mm:
1979         (WebKit::PluginServiceInitializerDelegate::PluginServiceInitializerDelegate):
1980         (PluginServiceInitializer):
1981         * Shared/EntryPointUtilities/mac/XPCService/XPCServiceEntryPoint.h:
1982         (WebKit::XPCServiceInitializerDelegate::XPCServiceInitializerDelegate):
1983         (WebKit::XPCServiceInitializer):
1984         * Shared/EntryPointUtilities/mac/XPCService/XPCServiceEntryPoint.mm:
1985         (WebKit::XPCServiceInitializerDelegate::checkEntitlements):
1986         (WebKit::XPCServiceInitializerDelegate::hasEntitlement):
1987         * Shared/EntryPointUtilities/mac/XPCService/XPCServiceMain.Development.mm:
1988         (WebKit::XPCServiceEventHandler):
1989         * Shared/EntryPointUtilities/mac/XPCService/XPCServiceMain.mm:
1990         (WebKit::XPCServiceEventHandler):
1991         * UIProcess/Launcher/mac/ProcessLauncherMac.mm:
1992         (WebKit::connectToService):
1993         (WebKit::connectToReExecService):
1994         * WebProcess/EntryPoint/mac/XPCService/WebContentServiceEntryPoint.mm:
1995         (WebContentServiceInitializer):
1996         Update after the rename of XPCPtr to OSObjectPtr.
1997
1998 2014-09-06  Darin Adler  <darin@apple.com>
1999
2000         Make updates suggested by new version of Xcode
2001         https://bugs.webkit.org/show_bug.cgi?id=136603
2002
2003         Reviewed by Mark Rowe.
2004
2005         * Configurations/Base.xcconfig: Added CLANG_WARN_UNREACHABLE_CODE, COMBINE_HIDPI_IMAGES,
2006         and ENABLE_STRICT_OBJC_MSGSEND as suggested by the Xcode upgrade check.
2007
2008         * PluginProcess/mac/PluginProcessMac.mm:
2009         (WebKit::initializeCocoaOverrides): Changed NSConcreteTask_launch to use the same technique
2010         as the other functions in this file, doing the type casting right at the call to
2011         method_setImplementation so the global has a suitable type for making a function call,
2012         rather than relying on the abilty to call through a type without a specific argument list.
2013
2014         * UIProcess/Plugins/PluginInfoStore.cpp:
2015         (WebKit::pathExtension): Use size_t for the result of String::reverseFind rather than
2016         converting it to an int. Also don't rely on the fact that WTF's notFound becomes -1 when
2017         cast from size_t to int.
2018
2019         * WebKit2.xcodeproj/project.pbxproj: Let Xcode delete some orphaned items, and updated
2020         LastUpgradeCheck.
2021
2022 2014-09-06  Brian J. Burg  <burg@cs.washington.edu>
2023
2024         Web Inspector: convert DockSide to an enum class
2025         https://bugs.webkit.org/show_bug.cgi?id=136601
2026
2027         Reviewed by Timothy Hatcher.
2028
2029         * WebProcess/WebCoreSupport/WebInspectorFrontendClient.cpp:
2030         (WebKit::WebInspectorFrontendClient::attachWindow):
2031         * WebProcess/WebPage/WebInspector.cpp:
2032         (WebKit::WebInspector::attachedBottom):
2033         (WebKit::WebInspector::attachedRight):
2034         (WebKit::WebInspector::detached):
2035
2036 2014-09-06  Antti Koivisto  <antti@apple.com>
2037
2038         Serialize ResourceResponses using WebKit types
2039         https://bugs.webkit.org/show_bug.cgi?id=136545
2040
2041         Reviewed by Alexey Proskuryakov.
2042
2043         Remove the WK2 serialization code for responses. It moves to the types itself in WebCore where it is
2044         close to the data being serialized and less likely to get out of sync.
2045
2046         * Shared/WebCoreArgumentCoders.cpp:
2047         (IPC::ArgumentCoder<ResourceResponse>::encode): Deleted.
2048         (IPC::ArgumentCoder<ResourceResponse>::decode): Deleted.
2049         * Shared/WebCoreArgumentCoders.h:
2050         * Shared/mac/WebCoreArgumentCodersMac.mm:
2051         (IPC::ArgumentCoder<ResourceResponse>::encodePlatformData): Deleted.
2052         (IPC::ArgumentCoder<ResourceResponse>::decodePlatformData): Deleted.
2053
2054 2014-09-06  Ryuan Choi  <ryuan.choi@gmail.com>
2055
2056         [EFL] Drop evas object cursor support
2057         https://bugs.webkit.org/show_bug.cgi?id=136324
2058
2059         Reviewed by Gyuyoung Kim.
2060
2061         Removed evas object cursor because there are some bugs.
2062         ewebkit will only support ecore_x_cursor because ewebkit is available with X, now.
2063
2064         * UIProcess/API/efl/EwkView.cpp:
2065         (EwkViewEventHandler<EVAS_CALLBACK_MOUSE_IN>::handleEvent):
2066         (EwkView::EwkView):
2067         (EwkView::updateCursor): Simplifies not to use evas object cursor.
2068         (EwkView::setCursor): Ditto.
2069         * UIProcess/API/efl/EwkView.h:
2070
2071 2014-09-05  Commit Queue  <commit-queue@webkit.org>
2072
2073         Unreviewed, rolling out r173340 and r173342.
2074         https://bugs.webkit.org/show_bug.cgi?id=136596
2075
2076         Broke many tests (Requested by ap on #webkit).
2077
2078         Reverted changesets:
2079
2080         "Remove PLATFORM(IOS) from WebCore/editing (Part 3)."
2081         https://bugs.webkit.org/show_bug.cgi?id=136474
2082         http://trac.webkit.org/changeset/173340
2083
2084         "Build fix after r173340."
2085         http://trac.webkit.org/changeset/173342
2086
2087 2014-09-05  Joseph Pecoraro  <pecoraro@apple.com>
2088
2089         Use WTFString::split(char) in more places
2090         https://bugs.webkit.org/show_bug.cgi?id=136543
2091
2092         Reviewed by Sam Weinig.
2093
2094         * Shared/Plugins/Netscape/mac/NetscapePluginModuleMac.mm:
2095         (WebKit::PluginVersion::parse):
2096         * UIProcess/gtk/WebContextGtk.cpp:
2097         (WebKit::initInspectorServer):
2098         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
2099         (WebKit::isTransparentSilverlightBackgroundValue):
2100
2101 2014-09-05  Enrica Casucci  <enrica@apple.com>
2102
2103         Remove PLATFORM(IOS) from WebCore/editing (Part 3).
2104         https://bugs.webkit.org/show_bug.cgi?id=136474
2105
2106         Reviewed by Benjamin Poulain.
2107
2108         This patch removes the use of PLATFORM(IOS) from TextAffinity.h
2109         and removes the assumption that EAffinity values match NSSelectionAffinity
2110         values. It also removes the includes in TextAffinity.h, creating the need to
2111         include explicitly the files when necessary. It also removes the unnecessary
2112         use of platform specific types, replacing them with WebCore types.
2113
2114         * WebProcess/InjectedBundle/API/mac/WKDOMInternals.mm:
2115         * WebProcess/WebPage/WKAccessibilityWebPageObjectIOS.mm:
2116         (-[WKAccessibilityWebPageObject accessibilityHitTest:]):
2117
2118 2014-09-05  David Kilzer  <ddkilzer@apple.com>
2119
2120         JavaScriptCore should build with newer clang
2121         <http://webkit.org/b/136002>
2122         <rdar://problem/18020616>
2123
2124         Reviewed by Geoffrey Garen.
2125
2126         * Shared/API/c/WKString.cpp:
2127         (WKStringCreateWithJSString): Add NULL check to prevent
2128         WebKitTestRunner crashes that relied on the previous |this|
2129         behavior where NULL values were allowed.
2130
2131 2014-09-05  Beth Dakin  <bdakin@apple.com>
2132
2133         ScrollablArea::handleWheelEvent() should return early if the ScrollableArea is not 
2134         actually scrollable
2135         https://bugs.webkit.org/show_bug.cgi?id=136558
2136
2137         Reviewed by Simon Fraser.
2138
2139         New ScrollableArea virtual function.
2140         * WebProcess/Plugins/PDF/PDFPlugin.h:
2141
2142 2014-09-04  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
2143
2144         Unreviewed, speculative build fix on GTK port since r173305.
2145
2146         * UIProcess/API/gtk/WebKitURISchemeRequest.cpp:
2147         (webkitURISchemeRequestReadCallback):
2148
2149 2014-09-03  Andy Estes  <aestes@apple.com>
2150
2151         [Cocoa] Some WebKitLegacy headers migrated from WebCore incorrectly contain WEBCORE_EXPORT
2152         https://bugs.webkit.org/show_bug.cgi?id=136521
2153
2154         Reviewed by Anders Carlsson.
2155
2156         * config.h: Included <WebCore/PlatformExportMacros.h> instead of defining WEBCORE_EXPORT.
2157
2158 2014-09-04  Maciej Stachowiak  <mjs@apple.com>
2159
2160         Remove WebCoreSystemInterface glue for otherwise unused WKSI calls
2161         https://bugs.webkit.org/show_bug.cgi?id=136527
2162
2163         Reviewed by Alexey Proskuryakov.
2164
2165         * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
2166         (InitWebCoreSystemInterface):
2167
2168 2014-09-04  Antti Koivisto  <antti@apple.com>
2169
2170         Remove ResourceResponse::m_suggestedFilename
2171         https://bugs.webkit.org/show_bug.cgi?id=136534
2172
2173         Reviewed by Alexey Proskuryakov.
2174
2175         * Shared/WebCoreArgumentCoders.cpp:
2176         (IPC::ArgumentCoder<ResourceResponse>::encode):
2177         (IPC::ArgumentCoder<ResourceResponse>::decode):
2178
2179             No more m_suggestedFilename.
2180
2181         * WebProcess/Plugins/PDF/PDFPlugin.mm:
2182         (WebKit::PDFPlugin::addArchiveResource):
2183
2184             Fake the suggested filename by using the Content-Disposition header.
2185
2186 2014-09-04  Eva Balazsfalvi  <evab.u-szeged@partner.samsung.com>
2187
2188         Remove CSS_FILTERS flag
2189         https://bugs.webkit.org/show_bug.cgi?id=136529
2190
2191         Reviewed by Dirk Schulze.
2192
2193         * Configurations/FeatureDefines.xcconfig:
2194         * Shared/CoordinatedGraphics/CoordinatedGraphicsArgumentCoders.cpp:
2195         (IPC::ArgumentCoder<WebCore::FilterOperations>::decode):
2196         (IPC::ArgumentCoder<GraphicsLayerAnimation>::encode):
2197         (IPC::ArgumentCoder<GraphicsLayerAnimation>::decode):
2198         (IPC::ArgumentCoder<CoordinatedGraphicsLayerState>::encode):
2199         (IPC::ArgumentCoder<CoordinatedGraphicsLayerState>::decode):
2200         * Shared/CoordinatedGraphics/CoordinatedGraphicsArgumentCoders.h:
2201         * Shared/WebCoreArgumentCoders.cpp:
2202         * Shared/WebCoreArgumentCoders.h:
2203         * WebProcess/WebPage/mac/GraphicsLayerCARemote.cpp:
2204         (WebKit::GraphicsLayerCARemote::filtersCanBeComposited):
2205         * WebProcess/WebPage/mac/GraphicsLayerCARemote.h:
2206         * WebProcess/WebPage/mac/PlatformCAAnimationRemote.h:
2207         * WebProcess/WebPage/mac/PlatformCAAnimationRemote.mm:
2208         (WebKit::PlatformCAAnimationRemote::setFromValue):
2209         (WebKit::PlatformCAAnimationRemote::setToValue):
2210         (WebKit::PlatformCAAnimationRemote::setValues):
2211         * WebProcess/WebPage/mac/PlatformCALayerRemote.cpp:
2212         (WebKit::PlatformCALayerRemote::updateClonedLayerProperties):
2213         (WebKit::PlatformCALayerRemote::filtersCanBeComposited):
2214         * WebProcess/WebPage/mac/PlatformCALayerRemote.h:
2215
2216 2014-09-04  Commit Queue  <commit-queue@webkit.org>
2217
2218         Unreviewed, rolling out r173245.
2219         https://bugs.webkit.org/show_bug.cgi?id=136533
2220
2221         Broke JSC tests. (Requested by ddkilzer on #webkit).
2222
2223         Reverted changeset:
2224
2225         "JavaScriptCore should build with newer clang"
2226         https://bugs.webkit.org/show_bug.cgi?id=136002
2227         http://trac.webkit.org/changeset/173245
2228
2229 2014-09-04  Carlos Garcia Campos  <cgarcia@igalia.com>
2230
2231         Initialize m_usesNetworkProcess earlier in WebProcess::initializeWebProcess()
2232         https://bugs.webkit.org/show_bug.cgi?id=136478
2233
2234         Reviewed by Alexey Proskuryakov.
2235
2236         The soup network backend uses WebProcess::usesNetworkProcess()
2237         from WebProcess::platformSetCacheModel() and
2238         WebProcess::platformInitializeWebProcess(), both called before the
2239         m_usesNetworkProcess member has been initialized.
2240
2241         * WebProcess/WebProcess.cpp:
2242         (WebKit::WebProcess::initializeWebProcess): Move the
2243         m_usesNetworkProcess initialization at the beginning right before
2244         calling platformInitializeWebProcess().
2245         * WebProcess/cocoa/WebProcessCocoa.mm:
2246         (WebKit::WebProcess::platformSetCacheModel): Remove the early
2247         return when using the network process, since this was dead code
2248         before this change, and not really needed now that
2249         usesNetworkProcess() will return true.
2250         (WebKit::WebProcess::platformInitializeWebProcess): Remove comment
2251         that is not accurate since r171156.
2252
2253 2014-09-03  Michael Catanzaro  <mcatanzaro@igalia.com>
2254
2255         [SOUP] Race condition when downloading a file due to the intermediate temporary file
2256         https://bugs.webkit.org/show_bug.cgi?id=136423
2257
2258         Reviewed by Carlos Garcia Campos.
2259
2260         * Shared/Downloads/soup/DownloadSoup.cpp:
2261         (WebKit::DownloadClient::DownloadClient): Replace m_destinationURI with
2262         m_destinationFile and add m_createdDestination.
2263         (WebKit::DownloadClient::deleteFilesIfNeeded): Added.
2264         (WebKit::DownloadClient::downloadFailed): Call deleteFilesIfNeeded.
2265         (WebKit::DownloadClient::didReceiveResponse): Attempt to create the
2266         destination file before the intermediate file. Fail here if the file
2267         exists and overwrite is not allowed, so we don't erroneously fire the
2268         didCreateDestination event or waste time downloading the file when we
2269         know the download will fail.
2270         (WebKit::DownloadClient::didFinishLoading): Unconditionally overwrite
2271         the empty destination file.
2272         (WebKit::DownloadClient::cancel): Call deleteFilesIfNeeded.
2273         (WebKit::DownloadClient::deleteIntermediateFileInNeeded): Deleted.
2274
2275 2014-09-03  David Kilzer  <ddkilzer@apple.com>
2276
2277         JavaScriptCore should build with newer clang
2278         <http://webkit.org/b/136002>
2279         <rdar://problem/18020616>
2280
2281         Reviewed by Geoffrey Garen.
2282
2283         * Shared/API/c/WKString.cpp:
2284         (WKStringCreateWithJSString): Add NULL check to prevent
2285         WebKitTestRunner crashes that relied on the previous |this|
2286         behavior where NULL values were allowed.
2287
2288 2014-09-03  Enrica Casucci  <enrica@apple.com>
2289
2290         Remove PLATFORM(IOS) from WebCore/editing (Part 1).
2291         https://bugs.webkit.org/show_bug.cgi?id=136474
2292
2293         Reviewed by Tim Horton.
2294
2295         * UIProcess/WebEditCommandProxy.cpp:
2296         (WebKit::WebEditCommandProxy::nameForEditAction):
2297
2298 2014-09-03  Yongjun Zhang  <yongjun_zhang@apple.com>
2299
2300         https://bugs.webkit.org/show_bug.cgi?id=136395
2301         Need a way to get userAgent from WKWebView.
2302
2303         Add _userAgent property to return user agent string from WKWebView.
2304
2305         Reviewed by Anders Carlsson.
2306
2307         * UIProcess/API/Cocoa/WKWebView.mm:
2308         (-[WKWebView _userAgent]):
2309         * UIProcess/API/Cocoa/WKWebViewPrivate.h:
2310
2311 2014-09-02  Maciej Stachowiak  <mjs@apple.com>
2312
2313         Clean up naming for and slightly refactor legacy video fullscreen support
2314         https://bugs.webkit.org/show_bug.cgi?id=136446
2315
2316         Reviewed by Jer Noble.
2317
2318         Key changes:
2319         supportsFullscreenForNode(Node*) --> supportsVideoFullscreen()
2320         enterFullscreenForNode(Node*) --> enterVideoFullscreenForVideoElement(HTMLVideoElement*)
2321         exitFullscreenForNode(Node*) --> exitVideoFullscreen()
2322         
2323         The old versions had unnecessary parameters, did not clearly distinguish their purpose
2324         from enterFullscreenForElement and friends, and wrongly claimed generality to all Nodes.
2325         Also changed many other places to use HTMLVideoElement* instead of Node* or 
2326         HTMLMediaElement* when they were in fact only used for video elements and would only
2327         work for such.
2328
2329         Legacy video fullscreen in WebKit2 is only supported on iOS (for other ports that support
2330         it, it's WK1 only).
2331         
2332         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
2333         (WebKit::WebChromeClient::supportsVideoFullscreen): Adjust for renames as
2334         mentioned.
2335         (WebKit::WebChromeClient::enterVideoFullscreenForVideoElement): ditto
2336         (WebKit::WebChromeClient::exitVideoFullscreen): ditto
2337         * WebProcess/WebCoreSupport/WebChromeClient.h:
2338         * WebProcess/ios/WebVideoFullscreenManager.h:
2339         * WebProcess/ios/WebVideoFullscreenManager.mm:
2340         (WebKit::clientRectForElement): No need to be generic to node.
2341         (WebKit::WebVideoFullscreenManager::supportsVideoFullscreen): Adjust for the
2342         main refactoring. Also change m_node to m_videoElement with appropriate type change.
2343         (WebKit::WebVideoFullscreenManager::enterVideoFullscreenForVideoElement): ditto
2344         (WebKit::WebVideoFullscreenManager::exitVideoFullscreen): ditto
2345         (WebKit::WebVideoFullscreenManager::didEnterFullscreen): ditto 
2346         (WebKit::WebVideoFullscreenManager::didExitFullscreen): ditto
2347         (WebKit::WebVideoFullscreenManager::didCleanupFullscreen): ditto
2348
2349 2014-09-03  Dan Bernstein  <mitz@apple.com>
2350
2351         Get rid of HIGH_DPI_CANVAS leftovers
2352         https://bugs.webkit.org/show_bug.cgi?id=136491
2353
2354         Reviewed by Benjamin Poulain.
2355
2356         * Configurations/FeatureDefines.xcconfig: Removed definition of ENABLE_HIGH_DPI_CANVAS
2357         and removed it from FEATURE_DEFINES.
2358
2359 2014-09-02  Yongjun Zhang  <yongjun_zhang@apple.com>
2360
2361         Pass the resource identifier in willSendRequest callback.
2362         https://bugs.webkit.org/show_bug.cgi?id=136325
2363
2364         Reviewed by Dan Bernstein.
2365
2366         Add two new delegate methods webProcessPlugInBrowserContextController:frame:willSendRequestForResource:request:redirectResponse:
2367         and webProcessPlugInBrowserContextController:frame:didInitiateLoadForResource:request:pageIsProvisionallyLoading:. We will remove
2368         the old willSendRequest and didInitiateLoadForResource when clients adopt the new methods.
2369
2370         * WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInLoadDelegate.h:
2371         * WebProcess/InjectedBundle/API/mac/WKWebProcessPlugInBrowserContextController.mm:
2372         (willSendRequestForFrame):
2373         (didInitiateLoadForResource):
2374
2375 2014-09-02  Philippe Normand  <pnormand@igalia.com>
2376
2377         Unreviewed, GTK build fix after r173163.
2378
2379         * UIProcess/API/gtk/PageClientImpl.cpp:
2380         (WebKit::PageClientImpl::createDrawingAreaProxy):
2381         * UIProcess/DrawingAreaProxyImpl.cpp:
2382         (WebKit::DrawingAreaProxyImpl::DrawingAreaProxyImpl):
2383         (WebKit::DrawingAreaProxyImpl::update):
2384         (WebKit::DrawingAreaProxyImpl::didUpdateBackingStoreState):
2385         (WebKit::DrawingAreaProxyImpl::incorporateUpdate):
2386         (WebKit::DrawingAreaProxyImpl::sendUpdateBackingStoreState):
2387         (WebKit::DrawingAreaProxyImpl::waitForAndDispatchDidUpdateBackingStoreState):
2388         (WebKit::DrawingAreaProxyImpl::enterAcceleratedCompositingMode):
2389         (WebKit::DrawingAreaProxyImpl::exitAcceleratedCompositingMode):
2390         (WebKit::DrawingAreaProxyImpl::updateAcceleratedCompositingMode):
2391         * UIProcess/DrawingAreaProxyImpl.h:
2392
2393 2014-09-01  Timothy Horton  <timothy_horton@apple.com>
2394
2395         Fix the iOS build.
2396
2397         * UIProcess/ios/WKContentView.mm:
2398         (-[WKContentView _createDrawingAreaProxy]):
2399         Whoops.
2400
2401 2014-09-01  Ryuan Choi  <ryuan.choi@gmail.com>
2402
2403         Build break on the EFL port since r173163
2404         https://bugs.webkit.org/show_bug.cgi?id=136443
2405
2406         Unreviewed build fix.
2407
2408         * UIProcess/BackingStore.cpp:
2409         (WebKit::BackingStore::BackingStore):
2410         * UIProcess/BackingStore.h:
2411         * UIProcess/CoordinatedGraphics/CoordinatedDrawingAreaProxy.cpp:
2412         (WebKit::CoordinatedDrawingAreaProxy::CoordinatedDrawingAreaProxy):
2413         (WebKit::CoordinatedDrawingAreaProxy::updateViewport):
2414         (WebKit::CoordinatedDrawingAreaProxy::contentsRect):
2415         (WebKit::CoordinatedDrawingAreaProxy::update):
2416         (WebKit::CoordinatedDrawingAreaProxy::didUpdateBackingStoreState):
2417         (WebKit::CoordinatedDrawingAreaProxy::incorporateUpdate):
2418         (WebKit::CoordinatedDrawingAreaProxy::sendUpdateBackingStoreState):
2419         (WebKit::CoordinatedDrawingAreaProxy::waitForAndDispatchDidUpdateBackingStoreState):
2420         (WebKit::CoordinatedDrawingAreaProxy::enterAcceleratedCompositingMode):
2421         (WebKit::CoordinatedDrawingAreaProxy::exitAcceleratedCompositingMode):
2422         (WebKit::CoordinatedDrawingAreaProxy::updateAcceleratedCompositingMode):
2423         * UIProcess/CoordinatedGraphics/CoordinatedDrawingAreaProxy.h:
2424         (WebKit::CoordinatedDrawingAreaProxy::page):
2425         * UIProcess/CoordinatedGraphics/CoordinatedLayerTreeHostProxy.cpp:
2426         (WebKit::CoordinatedLayerTreeHostProxy::CoordinatedLayerTreeHostProxy):
2427         (WebKit::CoordinatedLayerTreeHostProxy::~CoordinatedLayerTreeHostProxy):
2428         (WebKit::CoordinatedLayerTreeHostProxy::commitCoordinatedGraphicsState):
2429         (WebKit::CoordinatedLayerTreeHostProxy::setVisibleContentsRect):
2430         (WebKit::CoordinatedLayerTreeHostProxy::renderNextFrame):
2431         (WebKit::CoordinatedLayerTreeHostProxy::purgeBackingStores):
2432         (WebKit::CoordinatedLayerTreeHostProxy::commitScrollOffset):
2433         * UIProcess/CoordinatedGraphics/WebView.cpp:
2434         (WebKit::WebView::createDrawingAreaProxy):
2435         * UIProcess/cairo/BackingStoreCairo.cpp:
2436         (WebKit::BackingStore::incorporateUpdate):
2437
2438 2014-09-01  Tim Horton  <timothy_horton@apple.com>
2439
2440         Remove two unused WebKit2 PDF-related preferences
2441         https://bugs.webkit.org/show_bug.cgi?id=136441
2442
2443         Reviewed by Dan Bernstein.
2444
2445         * Shared/WebPreferencesDefinitions.h:
2446         Move the macro arguments comment down near where the macros are being used.
2447         No need to check both PLATFORM(IOS) and PLATFORM(IOS_SIMULATOR); the second can't be true without the first.
2448         These two PDF preferences are long-unused; if we bring back their functionality,
2449         we'll bring back the preferences.
2450
2451 2014-09-01  Tim Horton  <timothy_horton@apple.com>
2452
2453         DrawingAreaProxy and friends can hold on to WebPageProxy by reference
2454         https://bugs.webkit.org/show_bug.cgi?id=136440
2455
2456         Reviewed by Dan Bernstein.
2457
2458         * UIProcess/API/mac/WKView.mm:
2459         (-[WKView _createDrawingAreaProxy]):
2460         * UIProcess/DrawingAreaProxy.cpp:
2461         (WebKit::DrawingAreaProxy::DrawingAreaProxy):
2462         (WebKit::DrawingAreaProxy::~DrawingAreaProxy):
2463         (WebKit::DrawingAreaProxy::setExposedRect):
2464         (WebKit::DrawingAreaProxy::exposedRectChangedTimerFired):
2465         * UIProcess/DrawingAreaProxy.h:
2466         * UIProcess/mac/RemoteLayerTreeDrawingAreaProxy.h:
2467         * UIProcess/mac/RemoteLayerTreeDrawingAreaProxy.mm:
2468         (WebKit::RemoteLayerTreeDrawingAreaProxy::RemoteLayerTreeDrawingAreaProxy):
2469         (WebKit::RemoteLayerTreeDrawingAreaProxy::~RemoteLayerTreeDrawingAreaProxy):
2470         (WebKit::RemoteLayerTreeDrawingAreaProxy::sizeDidChange):
2471         (WebKit::RemoteLayerTreeDrawingAreaProxy::deviceScaleFactorDidChange):
2472         (WebKit::RemoteLayerTreeDrawingAreaProxy::scaledExposedRect):
2473         (WebKit::RemoteLayerTreeDrawingAreaProxy::sendUpdateGeometry):
2474         (WebKit::RemoteLayerTreeDrawingAreaProxy::commitLayerTree):
2475         (WebKit::RemoteLayerTreeDrawingAreaProxy::acceleratedAnimationDidStart):
2476         (WebKit::RemoteLayerTreeDrawingAreaProxy::acceleratedAnimationDidEnd):
2477         (WebKit::RemoteLayerTreeDrawingAreaProxy::indicatorLocation):
2478         (WebKit::RemoteLayerTreeDrawingAreaProxy::indicatorScale):
2479         (WebKit::RemoteLayerTreeDrawingAreaProxy::updateDebugIndicator):
2480         (WebKit::RemoteLayerTreeDrawingAreaProxy::didRefreshDisplay):
2481         (WebKit::RemoteLayerTreeDrawingAreaProxy::waitForDidUpdateViewState):
2482         (WebKit::RemoteLayerTreeDrawingAreaProxy::dispatchAfterEnsuringDrawing):
2483         * UIProcess/mac/TiledCoreAnimationDrawingAreaProxy.h:
2484         * UIProcess/mac/TiledCoreAnimationDrawingAreaProxy.mm:
2485         (WebKit::TiledCoreAnimationDrawingAreaProxy::TiledCoreAnimationDrawingAreaProxy):
2486         (WebKit::TiledCoreAnimationDrawingAreaProxy::deviceScaleFactorDidChange):
2487         (WebKit::TiledCoreAnimationDrawingAreaProxy::sizeDidChange):
2488         (WebKit::TiledCoreAnimationDrawingAreaProxy::waitForPossibleGeometryUpdate):
2489         (WebKit::TiledCoreAnimationDrawingAreaProxy::colorSpaceDidChange):
2490         (WebKit::TiledCoreAnimationDrawingAreaProxy::minimumLayoutSizeDidChange):
2491         (WebKit::TiledCoreAnimationDrawingAreaProxy::enterAcceleratedCompositingMode):
2492         (WebKit::TiledCoreAnimationDrawingAreaProxy::updateAcceleratedCompositingMode):
2493         (WebKit::TiledCoreAnimationDrawingAreaProxy::didUpdateGeometry):
2494         (WebKit::TiledCoreAnimationDrawingAreaProxy::waitForDidUpdateViewState):
2495         (WebKit::TiledCoreAnimationDrawingAreaProxy::intrinsicContentSizeDidChange):
2496         (WebKit::TiledCoreAnimationDrawingAreaProxy::sendUpdateGeometry):
2497         (WebKit::TiledCoreAnimationDrawingAreaProxy::adjustTransientZoom):
2498         (WebKit::TiledCoreAnimationDrawingAreaProxy::commitTransientZoom):
2499
2500 2014-09-01  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
2501
2502         [CMAKE] Build warning by INTERFACE_LINK_LIBRARIES
2503         https://bugs.webkit.org/show_bug.cgi?id=136194
2504
2505         Reviewed by Csaba Osztrogonác.
2506
2507         Set the LINK_INTERFACE_LIBRARIES target property on the top level CMakeLists.txt.
2508
2509         * CMakeLists.txt:
2510
2511 2014-09-01  Michael Catanzaro  <mcatanzaro@igalia.com>
2512
2513         [SOUP] WebKitDownload cannot overwrite existing file
2514         https://bugs.webkit.org/show_bug.cgi?id=136322
2515
2516         Reviewed by Carlos Garcia Campos.
2517
2518         * Shared/Downloads/soup/DownloadSoup.cpp:
2519         (WebKit::DownloadClient::didReceiveResponse): pass a member variable
2520         to Download::decideDestinationWithSuggestedFilename instead of a
2521         temporary bool, so we can use the result in didFinishLoading.
2522         (WebKit::DownloadClient::didFinishLoading): overwrite the destination
2523         if Download::decideDestinationWithSuggestedFilename determined we
2524         should do so.
2525
2526 2014-08-31  Tim Horton  <timothy_horton@apple.com>
2527
2528         Occasional crashes (null deref) under ViewGestureController::endMagnificationGesture
2529         https://bugs.webkit.org/show_bug.cgi?id=136409
2530         <rdar://problem/18104748>
2531
2532         Reviewed by Dan Bernstein.
2533
2534         * UIProcess/mac/ViewGestureControllerMac.mm:
2535         (WebKit::ViewGestureController::endMagnificationGesture):
2536         Null-check DrawingArea.
2537
2538 2014-08-26  Maciej Stachowiak  <mjs@apple.com>
2539
2540         Use RetainPtr::autorelease in some places where it seems appropriate
2541         https://bugs.webkit.org/show_bug.cgi?id=136280
2542
2543         Reviewed by Darin Adler.
2544
2545         * Shared/Cocoa/WKNSURLExtras.mm:
2546         (urlWithWTFString): Use autorelease() instead of CFBridgingRelease(leakRef())
2547
2548 2014-08-29  Tim Horton  <timothy_horton@apple.com>
2549
2550         More occasional crashes in ServicesController::resfreshExistingServices
2551         https://bugs.webkit.org/show_bug.cgi?id=136387
2552         <rdar://problem/18167200>
2553
2554         Reviewed by Dan Bernstein.
2555
2556         * UIProcess/mac/ServicesController.mm:
2557         (WebKit::ServicesController::ServicesController):
2558         Speculative fix; if this block is called synchronously, we'll end up
2559         calling back into ::shared() before the NeverDestroyed is initialized,
2560         ending up with two ServicesControllers.
2561
2562 2014-08-29  Alexey Proskuryakov  <ap@apple.com>
2563
2564         Crashes in IPC code under VisitedLinkProvider::pendingVisitedLinksTimerFired
2565         https://bugs.webkit.org/show_bug.cgi?id=136384
2566         rdar://problem/16991213
2567
2568         Reviewed by Sam Weinig.
2569
2570         VisitedLinkProvider process tracking relied on a combination of WebPageProxy process
2571         lifecycle notifications and checking process state. As evidenced by multiple FIXMEs,
2572         these are not yet as reliable as they should be.
2573         
2574         Changed to unregister a process when it closes, not when it no longer has any pages
2575         using the particular VisitedLinkProvider or WebUserContentControllerProxy. This
2576         is a deoptimization that should not matter in practice.
2577
2578         * UIProcess/UserContent/WebUserContentControllerProxy.cpp:
2579         (WebKit::WebUserContentControllerProxy::~WebUserContentControllerProxy):
2580         (WebKit::WebUserContentControllerProxy::removeProcess):
2581         (WebKit::WebUserContentControllerProxy::addUserScript):
2582         (WebKit::WebUserContentControllerProxy::removeAllUserScripts):
2583         (WebKit::WebUserContentControllerProxy::addUserStyleSheet):
2584         (WebKit::WebUserContentControllerProxy::removeAllUserStyleSheets):
2585         (WebKit::WebUserContentControllerProxy::addUserScriptMessageHandler):
2586         (WebKit::WebUserContentControllerProxy::removeUserMessageHandlerForName):
2587         * UIProcess/UserContent/WebUserContentControllerProxy.h:
2588         * UIProcess/VisitedLinkProvider.cpp:
2589         (WebKit::VisitedLinkProvider::~VisitedLinkProvider):
2590         (WebKit::VisitedLinkProvider::removeProcess):
2591         (WebKit::VisitedLinkProvider::removeAll):
2592         (WebKit::VisitedLinkProvider::pendingVisitedLinksTimerFired):
2593         (WebKit::VisitedLinkProvider::resizeTable):
2594         * UIProcess/VisitedLinkProvider.h:
2595         * UIProcess/WebPageProxy.cpp:
2596         (WebKit::WebPageProxy::WebPageProxy):
2597         (WebKit::WebPageProxy::close):
2598         (WebKit::WebPageProxy::processDidFinishLaunching):
2599         (WebKit::WebPageProxy::resetStateAfterProcessExited):
2600         * UIProcess/WebProcessProxy.cpp:
2601         (WebKit::WebProcessProxy::disconnect):
2602         (WebKit::WebProcessProxy::addVisitedLinkProvider):
2603         (WebKit::WebProcessProxy::addWebUserContentControllerProxy):
2604         (WebKit::WebProcessProxy::didDestroyVisitedLinkProvider):
2605         (WebKit::WebProcessProxy::didDestroyWebUserContentControllerProxy):
2606         * UIProcess/WebProcessProxy.h:
2607
2608 2014-08-29  Alexey Proskuryakov  <ap@apple.com>
2609
2610         WebPageProxy::close() is a no-op for terminated processes
2611         https://bugs.webkit.org/show_bug.cgi?id=136378
2612         Related to <rdar://problem/16991213> and to <rdar://problem/17095600>
2613
2614         Reviewed by Brady Eidson.
2615
2616         Also fixes issues that got uncovered after making close() work.
2617
2618         * UIProcess/WebInspectorProxy.cpp: (WebKit::WebInspectorProxy::invalidate): Don't
2619         close the page, because it makes no sense, and causes an assertion now. Previosly,
2620         this was OK because the page was invalid already, and close() was a no-op.
2621
2622         * UIProcess/WebPageProxy.cpp:
2623         (WebKit::WebPageProxy::~WebPageProxy): Added some assertions to catch invalidation
2624         issues earlier.
2625         (WebKit::WebPageProxy::reattachToWebProcess): Make it an invariant that a page's
2626         process always has a message receiver for it, until close() removes it.
2627         (WebKit::WebPageProxy::close): Make this function work for all open pages, whether
2628         they have a page or not.
2629         (WebKit::WebPageProxy::processDidFinishLaunching): Added an asserion that process
2630         agrees about its state.
2631         (WebKit::WebPageProxy::resetStateAfterProcessExited): Don't remove a message receiver,
2632         we now only do this in reattach or close.
2633
2634 2014-08-29  Antti Koivisto  <antti@apple.com>
2635
2636         Remove NetworkResourceLoaderClient and subclasses.
2637         https://bugs.webkit.org/show_bug.cgi?id=136370
2638
2639         Reviewed by Darin Adler.
2640
2641         This code is needlessly abstract. Move what logic these classes have to NetworkResourceLoader.
2642
2643         * NetworkProcess/AsynchronousNetworkLoaderClient.cpp: Removed.
2644         * NetworkProcess/AsynchronousNetworkLoaderClient.h: Removed.
2645         * NetworkProcess/NetworkLoaderClient.h: Removed.
2646         * NetworkProcess/NetworkResourceLoader.cpp:
2647         (WebKit::NetworkResourceLoader::NetworkResourceLoader):
2648         (WebKit::NetworkResourceLoader::~NetworkResourceLoader):
2649         (WebKit::NetworkResourceLoader::isSynchronous):
2650         (WebKit::NetworkResourceLoader::didReceiveResponseAsync):
2651         (WebKit::NetworkResourceLoader::didReceiveBuffer):
2652         (WebKit::NetworkResourceLoader::didFinishLoading):
2653         (WebKit::NetworkResourceLoader::didFail):
2654         (WebKit::NetworkResourceLoader::willSendRequestAsync):
2655         (WebKit::NetworkResourceLoader::didSendData):
2656         (WebKit::NetworkResourceLoader::sendBuffer):
2657         (WebKit::NetworkResourceLoader::sendReplyToSynchronousRequest):
2658         (WebKit::NetworkResourceLoader::canAuthenticateAgainstProtectionSpaceAsync):
2659         * NetworkProcess/NetworkResourceLoader.h:
2660         (WebKit::NetworkResourceLoader::SynchronousLoadData::SynchronousLoadData):
2661         * NetworkProcess/SynchronousNetworkLoaderClient.cpp: Removed.
2662         * NetworkProcess/SynchronousNetworkLoaderClient.h: Removed.
2663         * WebKit2.xcodeproj/project.pbxproj:
2664
2665 2014-08-29  Csaba Osztrogonác  <ossy@webkit.org>
2666
2667         Unreviwed, remove empty directories.
2668
2669         * PluginProcess/qt: Removed.
2670         * Shared/API/c/qt: Removed.
2671         * Shared/Downloads/qt: Removed.
2672         * Shared/FileAPI: Removed.
2673         * Shared/qt: Removed.
2674         * UIProcess/API/C/qt: Removed.
2675         * UIProcess/API/cpp/qt: Removed.
2676         * UIProcess/API/qt: Removed.
2677         * UIProcess/API/qt/raw: Removed.
2678         * UIProcess/API/qt/tests: Removed.
2679         * UIProcess/API/qt/tests/html: Removed.
2680         * UIProcess/API/qt/tests/html/resources: Removed.
2681         * UIProcess/API/qt/tests/inspectorserver: Removed.
2682         * UIProcess/API/qt/tests/publicapi: Removed.
2683         * UIProcess/API/qt/tests/qmltests: Removed.
2684         * UIProcess/API/qt/tests/qmltests/DesktopBehavior: Removed.
2685         * UIProcess/API/qt/tests/qmltests/WebView: Removed.
2686         * UIProcess/API/qt/tests/qmltests/common: Removed.
2687         * UIProcess/API/qt/tests/qquickwebview: Removed.
2688         * UIProcess/API/qt/tests/qrawwebview: Removed.
2689         * UIProcess/InspectorServer/qt: Removed.
2690         * UIProcess/Launcher/qt: Removed.
2691         * UIProcess/Plugins/qt: Removed.
2692         * UIProcess/SharedWorkers: Removed.
2693         * UIProcess/qt: Removed.
2694         * WebProcess/Cookies/qt: Removed.
2695         * WebProcess/Downloads: Removed.
2696         * WebProcess/IndexedDB: Removed.
2697         * WebProcess/InjectedBundle/qt: Removed.
2698         * WebProcess/NetworkInfo: Removed.
2699         * WebProcess/Plugins/Netscape/qt: Removed.
2700         * WebProcess/WebCoreSupport/qt: Removed.
2701         * WebProcess/WebPage/qt: Removed.
2702         * WebProcess/qt: Removed.
2703         * qt: Removed.
2704
2705 2014-08-28  Tim Horton  <timothy_horton@apple.com>
2706
2707         _setDidMoveSwipeSnapshotCallback's block should only be called if the snapshot is going to move
2708         https://bugs.webkit.org/show_bug.cgi?id=136354
2709         <rdar://problem/18167791>
2710
2711         Reviewed by Simon Fraser.
2712
2713         * UIProcess/API/Cocoa/WKViewPrivate.h:
2714         Update the comment to note the new behavior.
2715
2716         * UIProcess/mac/ViewGestureControllerMac.mm:
2717         (WebKit::ViewGestureController::beginSwipeGesture):
2718         Don't call the block until the snapshot is actually moving (if the snapshot
2719         never moves because it's behind the live view, don't call the block at all).
2720
2721 2014-08-28  Tim Horton  <timothy_horton@apple.com>
2722
2723         Occasional thread-safety-related crashes on the ServicesController queue
2724         https://bugs.webkit.org/show_bug.cgi?id=136356
2725         <rdar://problem/18045685>
2726
2727         Reviewed by Dan Bernstein.
2728
2729         * UIProcess/mac/ServicesController.mm:
2730         (WebKit::hasCompatibleServicesForItems):
2731         Added. Check directly with NSSharingService if we have any services for the given items.
2732         We should eventually check Viewer and Editor services separately so the Web process can
2733         be smarter about when it shows the overlay, but for now this maintains the existing behavior.
2734
2735         (WebKit::ServicesController::refreshExistingServices):
2736         Make use of hasCompatibleServicesForItems instead of having NSSharingServicePicker construct NSMenus.
2737
2738 2014-08-28  Tim Horton  <timothy_horton@apple.com>
2739
2740         WebKit2 doesn't support viewer services that accept image attachments
2741         https://bugs.webkit.org/show_bug.cgi?id=136349
2742         <rdar://problem/18164606>
2743
2744         Reviewed by Brady Eidson.
2745
2746         * Shared/WebProcessCreationParameters.cpp:
2747         (WebKit::WebProcessCreationParameters::encode):
2748         (WebKit::WebProcessCreationParameters::decode):
2749         Encode the already-existing parameter.
2750
2751 2014-08-28  Zalan Bujtas  <zalan@apple.com>
2752
2753         Subpixel layout: Remove unused pixel snapping functions.
2754         https://bugs.webkit.org/show_bug.cgi?id=136341
2755
2756         Reviewed by Simon Fraser.
2757
2758         Let's not encourage integral snapping by having these functions around.
2759         
2760         No change in functionality.
2761
2762         * Shared/WebRenderObject.cpp:
2763         (WebKit::WebRenderObject::WebRenderObject):
2764
2765 2014-08-27  Enrica Casucci  <enrica@apple.com>
2766
2767         textStylingAtPosition returns incorrect values after executing toggleBold, toggleItalic and toggleUnderline.
2768         https://bugs.webkit.org/show_bug.cgi?id=136323
2769         rdar://problem/18141964
2770
2771         Reviewed by Antti Koivisto.
2772
2773         For underline style we need to check typingStyle first and use that information to populate
2774         the dictionary. If there is no typing style we can use the render style.
2775         We also need to update the editor state for the toggle commands to reflect the state in the UIProcess
2776         even for commands that don't change the selection.
2777
2778         * WebProcess/WebPage/WebPage.cpp:
2779         (WebKit::WebPage::editorState):
2780         * WebProcess/WebPage/ios/WebPageIOS.mm:
2781         (WebKit::WebPage::executeEditCommandWithCallback):
2782
2783 2014-08-28  Carlos Garcia Campos  <cgarcia@igalia.com>
2784
2785         [GTK] Add webkit_uri_response_get_http_headers to WebKit2 GTK+ API
2786         https://bugs.webkit.org/show_bug.cgi?id=136248
2787
2788         Reviewed by Gustavo Noronha Silva.
2789
2790         Add webkit_uri_response_get_http_headers() that returns the HTTP
2791         headers as a SoupMessageHeaders* like webkit_uri_request_get_http_headers().
2792
2793         * UIProcess/API/gtk/WebKitURIResponse.cpp:
2794         (webkitURIResponseGetProperty): Add http-headers property getter.
2795         (webkit_uri_response_class_init): Add http-headers property.
2796         (webkit_uri_response_get_http_headers): Return the HTTP headers as
2797         a SoupMessageHeaders* or NULL for non HTTP responses.
2798         * UIProcess/API/gtk/WebKitURIResponse.h:
2799         * UIProcess/API/gtk/docs/webkit2gtk-sections.txt: Add new symbol.
2800
2801 2014-08-27  Zalan Bujtas  <zalan@apple.com>
2802
2803         Subpixel layout: Rename LayoutRect's device pixel snapping functions.
2804         https://bugs.webkit.org/show_bug.cgi?id=136319
2805
2806         Reviewed by Simon Fraser.
2807
2808         From pixelSnappedForPainting() to snapRectToDevicePixels() and 
2809         pixelSnappedIntRect*() to snappedIntRect*().
2810
2811         No change in functionality.
2812
2813         * WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.cpp:
2814         (WebKit::InjectedBundleNodeHandle::renderedImage):
2815         * WebProcess/WebPage/WebPage.cpp:
2816         (WebKit::WebPage::snapshotNode):
2817         * WebProcess/WebPage/mac/ServicesOverlayController.mm:
2818         (WebKit::ServicesOverlayController::buildSelectionHighlight):
2819
2820 2014-08-27  Zalan Bujtas  <zalan@apple.com>
2821
2822         Subpixel layout: Rename FloatPoint/FloatRect device pixel snapping functions.
2823         https://bugs.webkit.org/show_bug.cgi?id=136314
2824
2825         Reviewed by Simon Fraser.
2826
2827         From *edToDevicePixels() to *PointToDevicePixels() (* = floor/round/ceil)
2828
2829         EnclosedIntRect -> enclosingIntRect() changes functionality for InspectorOverlay painting,
2830         but currently untestable.
2831
2832         * UIProcess/ios/WKContentViewInteraction.mm:
2833         (-[WKContentView _updateTapHighlight]):
2834
2835 2014-08-27  Tim Horton  <timothy_horton@apple.com>
2836
2837         WebKit2 swipe gesture should report the position of the snapshot to the client
2838         https://bugs.webkit.org/show_bug.cgi?id=136308
2839         rdar://problem/18105827
2840
2841         Reviewed by Simon Fraser.
2842
2843         * UIProcess/API/Cocoa/WKViewPrivate.h:
2844         * UIProcess/API/mac/WKView.mm:
2845         (-[WKView _setDidMoveSwipeSnapshotCallback:]):
2846         Add _setDidMoveSwipeSnapshotCallback, and plumb it to ViewGestureController.
2847         Callers provide a block which is called whenever ViewGestureController moves the
2848         swipe *snapshot* layer around.
2849
2850         * UIProcess/PageClient.h:
2851         * UIProcess/WebPageProxy.h:
2852         * UIProcess/mac/PageClientImpl.h:
2853         * UIProcess/mac/PageClientImpl.mm:
2854         (WebKit::PageClientImpl::boundsOfLayerInLayerBackedWindowCoordinates):
2855         * UIProcess/mac/WebPageProxyMac.mm:
2856         (WebKit::WebPageProxy::boundsOfLayerInLayerBackedWindowCoordinates):
2857         Expose a Mac-only way to get the bounds of a given CALayer in window coordinates,
2858         respecting transforms. This only works for layer-backed windows because
2859         it uses CA in order to do the mapping respecting transforms.
2860
2861         * UIProcess/mac/ViewGestureController.h:
2862         * UIProcess/mac/ViewGestureControllerMac.mm:
2863         (WebKit::ViewGestureController::ViewGestureController):
2864         (WebKit::ViewGestureController::~ViewGestureController):
2865         (WebKit::ViewGestureController::setDidMoveSwipeSnapshotCallback):
2866         Do the Block_copy and Block_release dance to keep our copy of the callback block.
2867
2868         (WebKit::ViewGestureController::beginSwipeGesture):
2869         (WebKit::ViewGestureController::handleSwipeGesture):
2870         (WebKit::ViewGestureController::didMoveSwipeSnapshotLayer):
2871         When the swipe snapshot layer moves around, call the block.
2872
2873 2014-08-27  Tim Horton  <timothy_horton@apple.com>
2874
2875         Occasional crashes in commitTransientZoom's transaction completion block
2876         https://bugs.webkit.org/show_bug.cgi?id=136309
2877         <rdar://problem/17215064>
2878
2879         Reviewed by Dan Bernstein.
2880
2881         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
2882         (WebKit::TiledCoreAnimationDrawingArea::commitTransientZoom):
2883         Hold a reference to zoomLayer and the WebPage. It's possible that either
2884         of these things could have gone away by the time the transaction is committed.
2885
2886 2014-08-27  Benjamin Poulain  <bpoulain@apple.com>
2887
2888         [iOS WK2] Provide a delegate callback to skip Geolocation authorization per page for WebApp
2889         https://bugs.webkit.org/show_bug.cgi?id=136243
2890
2891         Reviewed by Sam Weinig.
2892
2893         Just ask the UI if the authorization dialog needs to be skipped.
2894
2895         * UIProcess/API/Cocoa/WKUIDelegate.h:
2896         * UIProcess/API/Cocoa/WKUIDelegatePrivate.h:
2897         * UIProcess/ios/PageClientImplIOS.mm:
2898         (WebKit::PageClientImpl::decidePolicyForGeolocationPermissionRequest):
2899
2900         * UIProcess/ios/WKContentView.h:
2901         * UIProcess/ios/WKContentView.mm:
2902         (-[WKContentView _decidePolicyForGeolocationRequestFromOrigin:frame:request:]): Deleted.
2903         The code in WKContentView only exists due to legacy. Instead, the PageClient dispatch the request
2904         to the GeolocationProvider directly.
2905
2906         * UIProcess/ios/WKGeolocationProviderIOS.h:
2907         * UIProcess/ios/WKGeolocationProviderIOS.mm:
2908         (-[WKGeolocationProviderIOS decidePolicyForGeolocationRequestFromOrigin:frame:request:view:]):
2909         (-[WKGeolocationProviderIOS geolocationAuthorizationGranted]):
2910         (-[WKGeolocationProviderIOS positionChanged:]):
2911         (-[WKGeolocationProviderIOS decidePolicyForGeolocationRequestFromOrigin:frame:request:window:]): Deleted.
2912
2913 2014-08-27  Beth Dakin  <bdakin@apple.com>
2914
2915         overflow:scroll elements should not latch to the body if the body is 
2916         overflow:hidden
2917         https://bugs.webkit.org/show_bug.cgi?id=136273
2918
2919         Reviewed by Darin Adler.
2920
2921         New ScrollabeArea virtual function.
2922         * WebProcess/Plugins/PDF/PDFPlugin.h:
2923
2924 2014-08-26  Matt Lilek  <mrl@apple.com>
2925
2926         Add WebKit SPI to control the navigator.standalone property
2927         https://bugs.webkit.org/show_bug.cgi?id=136189
2928
2929         Reviewed by Andy Estes.
2930
2931         Add a property to WKPreferences that allows toggling this setting.
2932
2933         * UIProcess/API/Cocoa/WKPreferences.mm:
2934         (-[WKPreferences _isStandalone]):
2935         (-[WKPreferences _setStandalone:]):
2936         * UIProcess/API/Cocoa/WKPreferencesPrivate.h:
2937
2938 2014-08-26  Joseph Pecoraro  <pecoraro@apple.com>
2939
2940         FileReader cannot read files selected with <input type="file"> in iOS 8
2941         https://bugs.webkit.org/show_bug.cgi?id=136117
2942
2943         Reviewed by Alexey Proskuryakov.
2944
2945         * Resources/SandboxProfiles/ios/com.apple.WebKit.Networking.sb:
2946         Correct an overzealous deny that was accidentally denying all
2947         com.apple.app-sandbox.read extensions instead of just the ones
2948         in Application bundles it was trying to deny.
2949
2950 2014-08-26  Tim Horton  <timothy_horton@apple.com>
2951
2952         Crashes in ViewGestureController::beginSwipeGesture when swiping in rapid succession
2953         https://bugs.webkit.org/show_bug.cgi?id=136271
2954         <rdar://problem/17923694>
2955
2956         Reviewed by Simon Fraser.
2957
2958         It was possible to get into trackSwipeGesture while another swipe was still
2959         occurring, because the guard against this happening depended on m_pendingSwipeReason
2960         never being set while a swipe was occurring. However, if the very first scroll event
2961         had sufficient magnitude, we would still set m_pendingSwipeReason to InsufficientMagnitude,
2962         and then *never clear it*, leading to a path around the guard against multiple live swipes.
2963         This in turn allowed stale layers in m_liveSwipeLayers, which lead to the crash.
2964
2965         * UIProcess/mac/ViewGestureControllerMac.mm:
2966         (WebKit::ViewGestureController::handleScrollWheelEvent):
2967         Don't unset m_pendingSwipeReason before calling trackSwipeGesture;
2968         trackSwipeGesture will do it itself.
2969
2970         Don't set m_pendingSwipeReason to InsufficientMagnitude
2971         if the event actually *has* sufficient magnitude to start a swipe.
2972
2973         (WebKit::ViewGestureController::trackSwipeGesture):
2974         Assert that we don't have an active gesture while starting a swipe.
2975
2976         Reset m_pendingSwipeReason, because the swipe is no longer pending!
2977
2978 2014-08-26  Andy Estes  <aestes@apple.com>
2979
2980         [Cocoa] Some projects are incorrectly installed to $BUILT_PRODUCTS_DIR
2981         https://bugs.webkit.org/show_bug.cgi?id=136267
2982
2983         Reviewed by Dan Bernstein.
2984
2985         INSTALL_PATH was set to $BUILT_PRODUCTS_DIR for engineering configurations in r20225 as part of a build fix.
2986         Not only is this no longer necessary to build, but it causes built products to be incorrectly installed in
2987         engineering configurations.
2988
2989         Remove the setting of INSTALL_PATH from the pbxproj file so that the value specified in the xcconfig files is
2990         used instead.
2991
2992         * WebKit2.xcodeproj/project.pbxproj:
2993
2994 2014-08-25  Maciej Stachowiak  <mjs@apple.com>
2995
2996         Replace use of WKCopyCFLocalizationPreferredName with NSLocale public API
2997         https://bugs.webkit.org/show_bug.cgi?id=136082
2998
2999         Reviewed by Alexey Proskuryakov.
3000
3001         * UIProcess/Launcher/mac/ProcessLauncherMac.mm:
3002         (WebKit::connectToService): Remove accidental leftover retrieval
3003         of the localization.
3004         (WebKit::createProcess): Get current localization name from
3005         CFBundle API instead of using SPI.
3006         * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
3007         (InitWebCoreSystemInterface): Remove mention of WKCopyCFLocalizationPreferredName
3008         * mac/WebKit2.order: ditto
3009
3010 2014-08-26  Dana Burkart  <dburkart@apple.com>
3011
3012         The UNUSED_PARAM macros in ServicesOverlayController.mm are causing ASan build failures.
3013         https://bugs.webkit.org/show_bug.cgi?id=136262
3014
3015         Reviewed by David Kilzer.
3016
3017         * WebProcess/WebPage/mac/ServicesOverlayController.mm:
3018         (WebKit::ServicesOverlayController::selectionRectsDidChange):
3019         (WebKit::ServicesOverlayController::selectedTelephoneNumberRangesChanged):
3020
3021 2014-08-26  Csaba Osztrogonác  <ossy@webkit.org>
3022
3023         [EFL] URTBF after r172966.
3024
3025         * UIProcess/efl/WebViewEfl.h:
3026
3027 2014-08-26  Carlos Alberto Lopez Perez  <clopez@igalia.com>
3028
3029         REGRESSION(r172966) [GTK] Build broken.
3030
3031         Unreviewed build fix after r172966.
3032
3033         * UIProcess/API/gtk/PageClientImpl.cpp:
3034         (WebKit::PageClientImpl::didSameDocumentNavigationForMainFrame):
3035         * UIProcess/API/gtk/PageClientImpl.h:
3036
3037 2014-08-26  Simon Fraser  <simon.fraser@apple.com>
3038
3039         Crashes in hit testing under WebPage::determinePrimarySnapshottedPlugIn()
3040         https://bugs.webkit.org/show_bug.cgi?id=136240
3041         rdar://problem/17231462
3042
3043         Reviewed by Darin Adler.
3044         
3045         determinePrimarySnapshottedPlugIn() does render tree hit testing, so needs
3046         to ensure that layout is up-to-date.
3047
3048         * WebProcess/WebPage/WebPage.cpp:
3049         (WebKit::WebPage::determinePrimarySnapshottedPlugIn):
3050
3051 2014-08-26  Tim Horton  <timothy_horton@apple.com>
3052
3053         REGRESSION (r172771): Amazon product page becomes unresponsive after swiping back to it
3054         https://bugs.webkit.org/show_bug.cgi?id=136260
3055         <rdar://problem/18107826>
3056
3057         Reviewed by Dan Bernstein.
3058
3059         Previously, when a swipe ended up performing a same-document navigation,
3060         we would never get didFinishLoadForMainFrame nor didFirstVisuallyNonEmptyLayoutForMainFrame
3061         nor would we even get didHitRenderTreeSizeThreshold in all cases, so we would never
3062         remove the swipe snapshot. Previous implementations removed the snapshot on
3063         didSameDocumentNavigation for the main frame if the navigation type was Replace or Pop,
3064         so we will match that behavior.
3065
3066         Also, reinstate the watchdog that starts at swipe-end which would have prevented
3067         this bug from forever breaking the view it was associated with.
3068
3069         Also, defend against removing the snapshot before the swipe has finished (before
3070         we have even caused the navigation that we're watching for the effects of).
3071
3072         * UIProcess/API/mac/WKView.mm:
3073         (-[WKView _didSameDocumentNavigationForMainFrame:]):
3074         * UIProcess/API/mac/WKViewInternal.h:
3075         * UIProcess/PageClient.h:
3076         * UIProcess/WebPageProxy.cpp:
3077         (WebKit::WebPageProxy::didSameDocumentNavigationForFrame):
3078         * UIProcess/ios/PageClientImplIOS.h:
3079         * UIProcess/ios/PageClientImplIOS.mm:
3080         (WebKit::PageClientImpl::didSameDocumentNavigationForMainFrame):
3081         * UIProcess/mac/PageClientImpl.h:
3082         * UIProcess/mac/PageClientImpl.mm:
3083         (WebKit::PageClientImpl::didSameDocumentNavigationForMainFrame):
3084         Plumb main-frame same-document navigation notification from WebPageProxy
3085         to ViewGestureControllerMac via PageClient and WKView.
3086
3087         * UIProcess/mac/ViewGestureController.h:
3088         * UIProcess/mac/ViewGestureControllerMac.mm:
3089         (WebKit::ViewGestureController::ViewGestureController):
3090         (WebKit::ViewGestureController::beginSwipeGesture):
3091         (WebKit::ViewGestureController::endSwipeGesture):
3092         Keep track of whether a swipe is currently occurring. We can't use
3093         activeGestureType for this because the swipe currently remains the "active"
3094         gesture until the snapshot is removed.
3095
3096         Reintroduce the old swipeWatchdogTimer (and rename the shorter timer that starts
3097         when we get a visually non-empty layout) so that we will always remove the
3098         snapshot after 5 seconds, even if we haven't committed the load.
3099         This could lead to flashing back to the old content if we fail to get a single
3100         byte for 5 seconds, but that is a rare case and should eventually get additional
3101         special treatment (dropping the tiles until we do get content, or some such).
3102
3103         (WebKit::ViewGestureController::didHitRenderTreeSizeThreshold):
3104         If a swipe is still in progress, we haven't done our navigation and thus
3105         don't care about render tree size changes.
3106
3107         (WebKit::ViewGestureController::didFirstVisuallyNonEmptyLayoutForMainFrame):
3108         If a swipe is still in progress, we haven't done our navigation and thus
3109         don't care about layouts.
3110
3111         Stop the 5 second overall watchdog if we start the 3 second after-visuallyNonEmptyLayout
3112         watchdog. This means that the snapshot could stay up for a maximum of 8 seconds
3113         for a very, very slow load.
3114
3115         (WebKit::ViewGestureController::didFinishLoadForMainFrame):
3116         If a swipe is still in progress, we haven't done our navigation and thus
3117         don't care about loads that complete.
3118
3119         (WebKit::ViewGestureController::didSameDocumentNavigationForMainFrame):
3120         Remove the swipe snapshot after painting if we do replaceState or popState.
3121
3122         (WebKit::ViewGestureController::removeSwipeSnapshotAfterRepaint):
3123         If a swipe is still in progress, we shouldn't remove the snapshot yet.
3124
3125 2014-08-26  Carlos Garcia Campos  <cgarcia@igalia.com>
3126
3127         [GTK] Translations are not initialized in the UI process
3128         https://bugs.webkit.org/show_bug.cgi?id=136249
3129
3130         Reviewed by Philippe Normand.
3131
3132         This is breaking things like webkitContextMenuActionGetForContextMenuItem()
3133         for non English locales in the cases where we use the action title to guess the
3134         action, because the action title we get from the web process is translated while
3135         the one in the UI process is in English.
3136
3137         * UIProcess/API/gtk/WebKitWebContext.cpp:
3138         (createDefaultWebContext): Initialize gettext right before
3139         creating the default web context.
3140
3141 2014-08-26  Ryuan Choi  <ryuan.choi@samsung.com>
3142
3143         [EFL] Remove dead code in WebPageEfl.cpp
3144         https://bugs.webkit.org/show_bug.cgi?id=136246
3145
3146         Reviewed by Gyuyoung Kim.
3147
3148         * WebProcess/WebPage/efl/WebPageEfl.cpp:
3149         (WebKit::scroll): Deleted.
3150
3151 2014-08-26  Ryuan Choi  <ryuan.choi@samsung.com>
3152
3153         [EFL] Build break using clang
3154         https://bugs.webkit.org/show_bug.cgi?id=136245
3155
3156         Reviewed by Gyuyoung Kim.
3157
3158         * PlatformEfl.cmake: defines GTEST_HAS_RTTI=0
3159
3160 2014-08-25  Zalan Bujtas  <zalan@apple.com>
3161
3162         Subpixel layout: remove roundedLayoutPoint/roundedLayoutSize functions.
3163         https://bugs.webkit.org/show_bug.cgi?id=136236
3164
3165         Reviewed by Simon Fraser.
3166
3167         These functions simply call LayoutPoint/LayoutSize c'tors. They don't round the input value at all.
3168
3169         Non change in functionality.
3170
3171         * UIProcess/ios/WebPageProxyIOS.mm:
3172         (WebKit::WebPageProxy::computeCustomFixedPositionRect):
3173
3174 2014-08-25  Antti Koivisto  <antti@apple.com>
3175
3176         Don't pass priority as parameter to ResourceLoadScheduler
3177         https://bugs.webkit.org/show_bug.cgi?id=136232
3178
3179         Reviewed by Sam Weinig.
3180
3181         * NetworkProcess/NetworkResourceLoader.cpp:
3182         (WebKit::NetworkResourceLoader::NetworkResourceLoader):
3183         * NetworkProcess/NetworkResourceLoader.h:
3184         (WebKit::NetworkResourceLoader::priority): Deleted.
3185         * Shared/Network/NetworkResourceLoadParameters.cpp:
3186         (WebKit::NetworkResourceLoadParameters::NetworkResourceLoadParameters):
3187         (WebKit::NetworkResourceLoadParameters::encode):
3188         (WebKit::NetworkResourceLoadParameters::decode):
3189         * Shared/Network/NetworkResourceLoadParameters.h:
3190         * WebProcess/Network/WebResourceLoadScheduler.cpp:
3191         (WebKit::WebResourceLoadScheduler::scheduleSubresourceLoad):
3192         (WebKit::WebResourceLoadScheduler::schedulePluginStreamLoad):
3193         (WebKit::WebResourceLoadScheduler::scheduleLoad):
3194         * WebProcess/Network/WebResourceLoadScheduler.h:
3195         * WebProcess/WebCoreSupport/WebPlatformStrategies.cpp:
3196         (WebKit::WebPlatformStrategies::loadResourceSynchronously):
3197
3198 2014-08-25  Brady Eidson  <beidson@apple.com>
3199
3200         Don't crash when the DataDetectors framework is unavailable.
3201         <rdar://problem/18106066> and https://bugs.webkit.org/show_bug.cgi?id=136234
3202
3203         Reviewed by Tim Horton.
3204
3205         * WebProcess/WebPage/mac/ServicesOverlayController.mm:
3206         (WebKit::ServicesOverlayController::buildPhoneNumberHighlights): Bail if DD.framework didn’t soft link.
3207         (WebKit::ServicesOverlayController::buildSelectionHighlight): Ditto.
3208
3209 2014-08-25  Antti Koivisto  <antti@apple.com>
3210
3211         Remove load scheduling code from network process
3212         https://bugs.webkit.org/show_bug.cgi?id=136199
3213
3214         Reviewed by Darin Adler.
3215
3216         Most platforms just flush resource loads directly to the networking layer by
3217         making the parallel load count large. Also we always pass ResourceLoadPriorityHighest
3218         to the scheduler so no actual scheduling happens. This is effectively dead code.
3219
3220         Keep basic support for serializing loads. This is only used for testing.
3221
3222         * NetworkProcess/HostRecord.cpp: Removed.
3223         * NetworkProcess/HostRecord.h: Removed.
3224         * NetworkProcess/NetworkConnectionToWebProcess.cpp:
3225         (WebKit::NetworkConnectionToWebProcess::servePendingRequests):
3226         * NetworkProcess/NetworkProcess.cpp:
3227         (WebKit::NetworkProcess::getNetworkProcessStatistics):
3228         * NetworkProcess/NetworkResourceLoadScheduler.cpp:
3229         (WebKit::NetworkResourceLoadScheduler::NetworkResourceLoadScheduler):
3230         (WebKit::NetworkResourceLoadScheduler::scheduleLoader):
3231         (WebKit::NetworkResourceLoadScheduler::removeLoader):
3232         (WebKit::NetworkResourceLoadScheduler::loadsPendingCount):
3233         (WebKit::NetworkResourceLoadScheduler::loadsActiveCount):
3234         (WebKit::NetworkResourceLoadScheduler::scheduleServePendingRequests): Deleted.
3235         (WebKit::NetworkResourceLoadScheduler::requestTimerFired): Deleted.
3236         (WebKit::NetworkResourceLoadScheduler::hostForURL): Deleted.
3237         (WebKit::NetworkResourceLoadScheduler::receivedRedirect): Deleted.
3238         (WebKit::NetworkResourceLoadScheduler::servePendingRequests): Deleted.
3239         (WebKit::NetworkResourceLoadScheduler::removeScheduledLoaders): Deleted.
3240         (WebKit::NetworkResourceLoadScheduler::scheduleRemoveLoader): Deleted.
3241         (WebKit::NetworkResourceLoadScheduler::hostsPendingCount): Deleted.
3242         (WebKit::NetworkResourceLoadScheduler::hostsActiveCount): Deleted.
3243         * NetworkProcess/NetworkResourceLoadScheduler.h:
3244         * NetworkProcess/NetworkResourceLoader.cpp:
3245         (WebKit::NetworkResourceLoader::~NetworkResourceLoader):
3246         (WebKit::NetworkResourceLoader::cleanup):
3247         (WebKit::NetworkResourceLoader::continueWillSendRequest):
3248         * NetworkProcess/NetworkResourceLoader.h:
3249         (WebKit::NetworkResourceLoader::isLoadingMainResource):
3250         (WebKit::NetworkResourceLoader::setHostRecord): Deleted.
3251         (WebKit::NetworkResourceLoader::hostRecord): Deleted.
3252         * NetworkProcess/mac/NetworkResourceLoadSchedulerMac.mm:
3253         (WebKit::NetworkResourceLoadScheduler::platformInitializeNetworkSettings):
3254         (WebKit::NetworkResourceLoadScheduler::platformInitializeMaximumHTTPConnectionCountPerHost): Deleted.
3255         * NetworkProcess/soup/NetworkResourceLoadSchedulerSoup.cpp:
3256         (WebKit::NetworkResourceLoadScheduler::platformInitializeNetworkSettings):
3257         (WebKit::NetworkResourceLoadScheduler::platformInitializeMaximumHTTPConnectionCountPerHost): Deleted.
3258         * WebKit2.xcodeproj/project.pbxproj:
3259
3260 2014-08-25  Carlos Garcia Campos  <cgarcia@igalia.com>
3261
3262         [GTK] Older versions of WebKit should use the plugins cache in read only mode
3263         https://bugs.webkit.org/show_bug.cgi?id=136215
3264
3265         Reviewed by Philippe Normand.
3266
3267         Now that WebKitGTK+ 2.4 and 2.5 are parallel installable, since
3268         they use different versions of the plugins cache, apps using 2.4
3269         might override the plugins cache file. We should prevent this from
3270         happening by making older versions use the plugin cache, but not
3271         downgrade it.
3272
3273         * UIProcess/Plugins/gtk/PluginInfoCache.cpp:
3274         (WebKit::PluginInfoCache::PluginInfoCache):
3275         (WebKit::PluginInfoCache::updatePluginInfo):
3276         * UIProcess/Plugins/gtk/PluginInfoCache.h:
3277
3278 2014-08-25  Carlos Garcia Campos  <cgarcia@igalia.com>
3279
3280         [GTK] Should check if a plugin mixes GTK+ symbols earlier
3281         https://bugs.webkit.org/show_bug.cgi?id=136214
3282
3283         Reviewed by Philippe Normand.
3284
3285         We are currently checking if the plugin module and the plugin
3286         process mix GTK symbols after the plugin has been loaded and
3287         initialized. This is too late in many cases, since plugins can use
3288         GTK methods in the NP_Initialize implementation. This is causing
3289         the apps using WebKitGTK+ 2.4 to freeze when the plugin process
3290         scans the plugins and there's a plugin using GTK+3 installed. We
3291         should move the check earlier, once the module is loaded but
3292         before calling NP_Initialize.
3293
3294         * Shared/Plugins/Netscape/NetscapePluginModule.cpp:
3295         (WebKit::moduleMixesGtkSymbols):
3296         (WebKit::NetscapePluginModule::tryLoad):
3297         * WebProcess/Plugins/Netscape/x11/NetscapePluginX11.cpp:
3298         (WebKit::NetscapePlugin::platformPostInitialize):
3299
3300 2014-08-25  Zan Dobersek  <zdobersek@igalia.com>
3301
3302         Improve virtual method declarations in LayerTreeHostGtk
3303         https://bugs.webkit.org/show_bug.cgi?id=136210
3304
3305         Reviewed by Carlos Garcia Campos.
3306
3307         Mark the LayerTreeHostGtk class as final in the virtual inheritance hierarchy.
3308
3309         Order the public and private virtual method overrides from the LayerTreeHost
3310         and GraphicsLayerClient interfaces. Explicitly mark them as overriding the
3311         base class methods.
3312
3313         Remove the overriding notifyAnimationStarted() and notifyFlushRequired()
3314         methods since they are identical to the methods in the base class.
3315
3316         De-virtualize flushPendingLayerChanges(). It's not inherited and is not
3317         overriden by anything (and nothing can inherit from LayerTreeHostGtk from
3318         now on due to the final specifier).
3319
3320         * WebProcess/WebPage/gtk/LayerTreeHostGtk.cpp:
3321         (WebKit::LayerTreeHostGtk::notifyAnimationStarted): Deleted.
3322         (WebKit::LayerTreeHostGtk::notifyFlushRequired): Deleted.
3323         * WebProcess/WebPage/gtk/LayerTreeHostGtk.h:
3324         (WebKit::LayerTreeHostGtk::didCommitChangesForLayer): Deleted.
3325
3326 2014-08-24  Brian J. Burg  <burg@cs.washington.edu>
3327
3328         Remove unused method declarations replaced by WebPage::setViewState
3329         https://bugs.webkit.org/show_bug.cgi?id=136180
3330
3331         Reviewed by Darin Adler.
3332
3333         * WebProcess/WebPage/WebPage.h:
3334         Remove setFocused, setActive, setViewIsVisible. No longer used.
3335
3336 2014-08-23  Byungseon Shin  <sun.shin@lge.com>
3337  
3338         Unify GraphicsLayer::setContentsToMedia and setContentsToCanvas
3339         https://bugs.webkit.org/show_bug.cgi?id=109658
3340  
3341         Reviewed by Martin Robinson.
3342  
3343         Based on patch originally written by Tim Horton.
3344         Merge setContentsToMedia and setContentsToCanvas into setContentsToPlatformLayer.
3345  
3346         * Shared/CoordinatedGraphics/CoordinatedGraphicsArgumentCoders.cpp:
3347         (IPC::ArgumentCoder<CoordinatedGraphicsLayerState>::encode):
3348         (IPC::ArgumentCoder<CoordinatedGraphicsLayerState>::decode):
3349         Rename canvas -> platformLayer.
3350
3351 2014-08-22  Commit Queue  <commit-queue@webkit.org>
3352
3353         Unreviewed, rolling out r172866.
3354         https://bugs.webkit.org/show_bug.cgi?id=136177
3355
3356         Broke iOS build (Requested by othermaciej on #webkit).
3357
3358         Reverted changeset:
3359
3360         "Replace use of WKCopyCFLocalizationPreferredName with
3361         NSLocale public API"
3362         https://bugs.webkit.org/show_bug.cgi?id=136082
3363         http://trac.webkit.org/changeset/172866
3364
3365 2014-08-19  Maciej Stachowiak  <mjs@apple.com>
3366
3367         Replace use of WKCopyCFLocalizationPreferredName with NSLocale public API
3368         https://bugs.webkit.org/show_bug.cgi?id=136082
3369
3370         Reviewed by Alexey Proskuryakov.
3371
3372         * UIProcess/Launcher/mac/ProcessLauncherMac.mm:
3373         (WebKit::connectToService): Remove accidental leftover retrieval
3374         of the localization.
3375         (WebKit::createProcess): Get current localization name from
3376         CFBundle API instead of using SPI.
3377         * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
3378         (InitWebCoreSystemInterface): Remove mention of WKCopyCFLocalizationPreferredName
3379         * mac/WebKit2.order: ditto
3380
3381 2014-08-22  Daniel Bates  <dabates@apple.com>
3382
3383         [iOS] Disable ENABLE_IOS_{GESTURE, TOUCH}_EVENTS, and temporarily disable ENABLE_TOUCH_EVENTS
3384         and ENABLE_XSLT when building with the iOS public SDK
3385         https://bugs.webkit.org/show_bug.cgi?id=135945
3386
3387         Reviewed by Andy Estes.
3388
3389         * Configurations/FeatureDefines.xcconfig: Disable ENABLE_IOS_{GESTURE, TOUCH}_EVENTS, ENABLE_TOUCH_EVENTS
3390         and ENABLE_XSLT when building with the public SDK.
3391         * Shared/WebEventConversion.h: Write preprocessor logic in terms of ENABLE(IOS_TOUCH_EVENTS).
3392         * WebProcess/WebPage/WebPage.h: Ditto.
3393
3394 2014-08-22  Simon Fraser  <simon.fraser@apple.com>
3395
3396         Implement paint flashing via GraphicsLayers in the WK2 inspector overlay
3397         https://bugs.webkit.org/show_bug.cgi?id=136136
3398
3399         Reviewed by Sam Weinig, Joseph Pecoraro.
3400         
3401         Allow InspectorClient to have a custom implementation of showPaintRect(). For
3402         WebKit2's WebInspectorClient, implement this by creating a set of GraphicsLayers
3403         which are parented in a document overlay, with 0.25s fade-out animations.
3404         
3405         Also change InspectorInstrumentation::didPaintImpl() to no longer take a GraphicsContext;
3406         it makes no sense to paint the paint rects directly into the context of the web page.
3407         Now that the paint rects are painted into an overlay, the rectangles need to be converted
3408         to root document coordinates, which is done in InspectorInstrumentation::didPaintImpl().
3409         
3410         Remove the generic InspectorOverlay::drawOutline()-based indicators; they will
3411         be reimplemented in a later patch.
3412
3413         * WebProcess/WebCoreSupport/WebInspectorClient.cpp:
3414         (WebKit::RepaintIndicatorLayerClient::RepaintIndicatorLayerClient):
3415         (WebKit::RepaintIndicatorLayerClient::~RepaintIndicatorLayerClient):
3416         (WebKit::RepaintIndicatorLayerClient::notifyAnimationEnded):
3417         (WebKit::WebInspectorClient::WebInspectorClient):
3418         (WebKit::WebInspectorClient::~WebInspectorClient):
3419         (WebKit::WebInspectorClient::showPaintRect):
3420         (WebKit::WebInspectorClient::animationEndedForLayer):
3421         * WebProcess/WebCoreSupport/WebInspectorClient.h:
3422         (WebKit::WebInspectorClient::WebInspectorClient): Deleted.
3423
3424 2014-08-22  Jon Lee  <jonlee@apple.com>
3425
3426         Fix iOS build due to r172832 and move RUBBER_BANDING out of FeatureDefines.h
3427         https://bugs.webkit.org/show_bug.cgi?id=136157
3428
3429         Reviewed by Simon Fraser.
3430
3431         * Configurations/FeatureDefines.xcconfig: Add ENABLE(RUBBER_BANDING).
3432
3433 2014-08-21  Joseph Pecoraro  <pecoraro@apple.com>
3434
3435         Possible RetainPtr misuse in WKScriptMessage.mm - could leak
3436         https://bugs.webkit.org/show_bug.cgi?id=136140
3437
3438         Reviewed by Darin Adler.
3439
3440         Adopt a copy into a RetainPtr to avoid leaking.
3441
3442         * UIProcess/API/Cocoa/WKScriptMessage.mm:
3443         (-[WKScriptMessage _initWithBody:webView:frameInfo:name:]):
3444
3445 2014-08-21  Simon Fraser  <simon.fraser@apple.com>
3446
3447         Add animationDidEnd callbacks on GraphicsLayer
3448         https://bugs.webkit.org/show_bug.cgi?id=136084
3449
3450         Reviewed by Tim Horton.
3451
3452         Hook up GraphicsLayerClient::notifyAnimationEnded() so that code using GraphicsLayers directly
3453         can add animations, and know when they finish.
3454
3455         * UIProcess/mac/RemoteLayerTreeDrawingAreaProxy.h:
3456         * UIProcess/mac/RemoteLayerTreeDrawingAreaProxy.mm:
3457         (WebKit::RemoteLayerTreeDrawingAreaProxy::acceleratedAnimationDidEnd):
3458         * UIProcess/mac/RemoteLayerTreeHost.h:
3459         * UIProcess/mac/RemoteLayerTreeHost.mm:
3460         (WebKit::RemoteLayerTreeHost::animationDidEnd):
3461         * WebProcess/WebPage/DrawingArea.h:
3462         (WebKit::DrawingArea::acceleratedAnimationDidEnd):
3463         * WebProcess/WebPage/DrawingArea.messages.in:
3464         * WebProcess/WebPage/mac/PlatformCAAnimationRemote.mm:
3465         (-[WKAnimationDelegate animationDidStop:finished:]):
3466         * WebProcess/WebPage/mac/PlatformCALayerRemote.cpp:
3467         (WebKit::PlatformCALayerRemote::animationStarted):
3468         (WebKit::PlatformCALayerRemote::animationEnded):
3469         * WebProcess/WebPage/mac/PlatformCALayerRemote.h:
3470         * WebProcess/WebPage/mac/RemoteLayerTreeContext.h:
3471         * WebProcess/WebPage/mac/RemoteLayerTreeContext.mm:
3472         (WebKit::RemoteLayerTreeContext::layerWillBeDestroyed):
3473         (WebKit::RemoteLayerTreeContext::willStartAnimationOnLayer):
3474         (WebKit::RemoteLayerTreeContext::animationDidStart):
3475         (WebKit::RemoteLayerTreeContext::animationDidEnd):
3476         * WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.h:
3477         * WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.mm:
3478         (WebKit::RemoteLayerTreeDrawingArea::acceleratedAnimationDidEnd):
3479
3480 2014-08-21  Zalan Bujtas  <zalan@apple.com>
3481
3482         Enable SATURATED_LAYOUT_ARITHMETIC.
3483         https://bugs.webkit.org/show_bug.cgi?id=136106
3484
3485         Reviewed by Simon Fraser.