1eeeb5cfa5698fd27ad4475382369a3512e2ba04
[WebKit-https.git] / Source / WebKit2 / ChangeLog
1 2013-09-10  Sergio Villar Senin  <svillar@igalia.com>
2
3         [WK2][GTK] Frequent crashes when showing context menus in Debug builds
4         https://bugs.webkit.org/show_bug.cgi?id=121099
5
6         Reviewed by Carlos Garcia Campos.
7
8         Disconnect signal handlers when destroying the context menu proxy
9         object. This avoids use-after-free crashes when opening several
10         context menus in a row.
11
12         * UIProcess/gtk/WebContextMenuProxyGtk.cpp:
13         (WebKit::WebContextMenuProxyGtk::append):
14         (WebKit::WebContextMenuProxyGtk::~WebContextMenuProxyGtk):
15         * UIProcess/gtk/WebContextMenuProxyGtk.h:
16
17 2013-09-10  Allan Sandfeld Jensen  <allan.jensen@digia.com>
18
19         [Qt] make use of qtHaveModule() 
20         https://bugs.webkit.org/show_bug.cgi?id=121090
21
22         Reviewed by Jocelyn Turcotte.
23         Patch by Oswald Buddenhagen <oswald.buddenhagen@digia.com>
24
25         Use qtHaveModule instead of our own haveQtModule.
26
27         * WebProcess.pro:
28
29 2013-09-10  Carlos Garcia Campos  <cgarcia@igalia.com>
30
31         [GTK] /webkit2/WebKitWebView/default-menu fails when GtkSettings:gtk-show-input-method-menu is disabled
32         https://bugs.webkit.org/show_bug.cgi?id=121088
33
34         Reviewed by Xan Lopez.
35
36         * UIProcess/API/gtk/tests/TestContextMenu.cpp: Always check
37         Unicode submenu is present in default context menu for editable
38         content.
39
40 2013-09-09  Dean Jackson  <dino@apple.com>
41
42         [WebGL] Allow multithreaded OpenGL contexts
43         https://bugs.webkit.org/show_bug.cgi?id=121062
44
45         Reviewed by Simon Fraser.
46
47         Expose a new preference "multithreadedWebGLEnabled".
48
49         * Shared/WebPreferencesStore.h:
50         * UIProcess/API/C/WKPreferences.cpp:
51         (WKPreferencesSetMultithreadedWebGLEnabled):
52         (WKPreferencesGetMultithreadedWebGLEnabled):
53         * UIProcess/API/C/WKPreferencesPrivate.h:
54         * WebProcess/WebPage/WebPage.cpp:
55         (WebKit::WebPage::updatePreferences):
56         * mac/WebKit2.order:
57
58 2013-09-09  Dean Jackson  <dino@apple.com>
59
60         Enable WebGL for OS X nightlies
61         https://bugs.webkit.org/show_bug.cgi?id=121040
62
63         Reviewed by Beth Dakin.
64
65         * Shared/WebPreferencesStore.h: Set initial value to true.
66
67 2013-09-08  Anders Carlsson  <andersca@apple.com>
68
69         Begin moving off of TypeTraits.h
70         https://bugs.webkit.org/show_bug.cgi?id=121006
71
72         Reviewed by Darin Adler.
73
74         Convert uses of WTF type traits to STL type traits.
75
76         * Platform/CoreIPC/ArgumentCoder.h:
77         * Platform/CoreIPC/ArgumentCoders.h:
78         * Platform/CoreIPC/ArgumentDecoder.h:
79         * Platform/CoreIPC/ArgumentEncoder.h:
80         * Platform/CoreIPC/Arguments.h:
81         * Shared/API/c/WKSharedAPICast.h:
82         (WebKit::toImpl):
83
84 2013-09-09  Gustavo Noronha Silva  <gns@gnome.org>
85
86         Unreviewed build fix.
87
88         * GNUmakefile.list.am: Typo - left-over \ from a copy/paste, most likely.
89
90 2013-09-09  Anton Obzhirov  <a.obzhirov@samsung.com>
91
92         [GTK] Cancel the current active WebKitAuthenticationRequest on load failed
93         https://bugs.webkit.org/show_bug.cgi?id=120350
94
95         Reviewed by Carlos Garcia Campos.
96
97         The default dialog does not get closed and the authentication is not cancelled
98         if loading fails or is stopped on a page which requires HTTP authentication.
99
100         This patch cancels the authentication request on load failed
101         and adds new authentication cancelled signal in WebKitAuthenticationRequest
102         to allow the application handling of authentication UI.
103
104         * UIProcess/API/gtk/WebKitAuthenticationDialog.cpp:
105         (authenticationCancelled):
106         (webkitAuthenticationDialogInitialize):
107         (webkitAuthenticationDialogDispose):
108         (webkitAuthenticationDialogNew):
109         * UIProcess/API/gtk/WebKitAuthenticationDialog.h:
110         * UIProcess/API/gtk/WebKitAuthenticationRequest.cpp:
111         (webkit_authentication_request_class_init):
112         (webkit_authentication_request_cancel):
113         * UIProcess/API/gtk/WebKitWebView.cpp:
114         (webkitWebViewAuthenticate):
115         (webkitWebViewLoadFailed):
116         (webkitWebViewHandleAuthenticationChallenge):
117         (webkitWebViewCancelAuthenticationRequest):
118         * UIProcess/API/gtk/tests/TestWebKitWebView.cpp:
119         (testWebViewAuthenticationLoadCancelled):
120         (beforeAll):
121
122 2013-09-09  Brian Holt  <brian.holt@samsung.com>
123
124         [GTK][WK2] Update ContextMenu Download API
125         https://bugs.webkit.org/show_bug.cgi?id=120763
126
127         Reviewed by Carlos Garcia Campos.
128
129         Mark the new Download items in the Context Menu with the Since
130         tag, and include a unit test for Context Menu audio.
131
132         * UIProcess/API/gtk/WebKitContextMenuActions.h:
133         * UIProcess/API/gtk/tests/TestContextMenu.cpp:
134         (testContextMenuDefaultMenu):
135
136 2013-09-08  Christophe Dumez  <ch.dumez@sisa.samsung.com>
137
138         [wk2] REGRESSION (r154673): PDF scrolling moves very slowly
139         https://bugs.webkit.org/show_bug.cgi?id=120542
140
141         Reviewed by Tim Horton.
142
143         Handle 'wheel' events in addition to 'mousewheel'. This fixes
144         PDF scrolling.
145
146         * WebProcess/Plugins/PluginView.cpp:
147         (WebKit::PluginView::handleEvent):
148
149 2013-09-08  Anders Carlsson  <andersca@apple.com>
150
151         Move WTF::notFound to Vector.h and delete NotFound.h
152         https://bugs.webkit.org/show_bug.cgi?id=120990
153
154         Reviewed by Sam Weinig.
155
156         * Shared/EditorState.h:
157
158 2013-09-07  Anders Carlsson  <andersca@apple.com>
159
160         Get rid of PassOwnArrayPtr
161         https://bugs.webkit.org/show_bug.cgi?id=120964
162
163         Reviewed by Andreas Kling.
164
165         Remove unneeded includes.
166
167         * Shared/ImmutableArray.h:
168         * WebProcess/InjectedBundle/InjectedBundle.cpp:
169
170 2013-09-06  Ryosuke Niwa  <rniwa@webkit.org>
171
172         Range::ownerDocument should return Document&
173         https://bugs.webkit.org/show_bug.cgi?id=120908
174
175         Reviewed by Andreas Kling.
176
177         * WebProcess/InjectedBundle/API/mac/WKDOMRange.mm:
178         (-[WKDOMRange textRects]):
179
180 2013-09-05  Ryuan Choi  <ryuan.choi@samsung.com>
181
182         [CMAKE] Add c++0x into CXX_FLAGS as a default
183         https://bugs.webkit.org/show_bug.cgi?id=120812
184
185         Unreviewed build fix for EFL ports.
186
187         * UIProcess/API/efl/tests/UnitTestUtils/EWK2UnitTestBase.h: Added constexpr for in-class initialization.
188         * UIProcess/API/efl/tests/UnitTestUtils/EWK2UnitTestEnvironment.cpp: Added space between strings.
189         (EWK2UnitTest::EWK2UnitTestEnvironment::defaultTestPageUrl):
190         (EWK2UnitTest::EWK2UnitTestEnvironment::defaultTheme):
191         (EWK2UnitTest::EWK2UnitTestEnvironment::urlForResource):
192
193 2013-09-05  Alexey Proskuryakov  <ap@apple.com>
194
195         WKFullScreenWindowController extends lifetime of WKView, deleting it at a wrong time
196         https://bugs.webkit.org/show_bug.cgi?id=120792
197         <rdar://problem/14884666>
198
199         Reviewed by Jer Noble.
200
201         * UIProcess/API/mac/WKView.mm: (-[WKView fullScreenWindowController]):
202         Use a newly minted initializer for the controller.
203
204         * UIProcess/mac/WKFullScreenWindowController.h: Removed unused web view accessors.
205         Changed the class to take web view at initialization time.
206
207         * UIProcess/mac/WKFullScreenWindowController.mm:
208         (-[WKFullScreenWindowController initWithWindow:webView:]): Initialize the controller
209         inone step.
210         (-[WKFullScreenWindowController dealloc]): WebView is now a raw pointer, no need
211         to zero it.
212         (-[WKFullScreenWindowController close]): Make sure to not leave a dangling WKView
213         pointer (this method is indirectly but inevitably called when WKView is deallocated).
214
215 2013-09-05  Anders Carlsson  <andersca@apple.com>
216
217         Replace uses of CLANG_PRAGMA with #pragma
218
219         Rubber-stamped by Andreas Kling.
220
221         This file is only compiled by clang anyway.
222
223         * WebProcess/InjectedBundle/mac/InjectedBundleMac.mm:
224         (WebKit::InjectedBundle::load):
225
226 2013-09-05  Anders Carlsson  <andersca@apple.com>
227
228         GCAssertions.h should use STL type traits and static_assert
229         https://bugs.webkit.org/show_bug.cgi?id=120785
230
231         Reviewed by Andreas Kling.
232
233         Update for JavaScriptCore changes.
234
235         * WebProcess/Plugins/Netscape/JSNPMethod.cpp:
236
237 2013-09-05  Alberto Garcia  <berto@igalia.com>
238
239         [WK2] [GTK] Remove the test to disable AC under Wayland from WebKitWebViewGroup
240         https://bugs.webkit.org/show_bug.cgi?id=120762
241
242         Reviewed by Gustavo Noronha Silva.
243
244         The code to disable AC under Wayland is not run if we're using
245         WebKitTestRunner, so it would be better to move it to
246         WebKitWebViewBase.
247
248         However it's not really necessary to do that, instead it's much
249         simpler to disable accelerated compositing in all cases unless we
250         know we can support it.
251
252         * UIProcess/API/gtk/WebKitWebViewBase.cpp:
253         (webkitWebViewBaseUpdatePreferences):
254         * UIProcess/API/gtk/WebKitWebViewGroup.cpp:
255         (webkitWebViewGroupAttachSettingsToPageGroup):
256
257 2013-09-04  Alberto Garcia  <berto@igalia.com>
258
259         [WK2][GTK] ASSERTION in WebKit::LayerTreeHostGtk::invalidate
260         https://bugs.webkit.org/show_bug.cgi?id=117733
261
262         Reviewed by Martin Robinson.
263
264         If the GL context cannot be created then an invalid
265         LayerTreeHostGtk object will be returned.
266
267         This patch disables accelerated compositing if the system doesn't
268         support it.
269
270         * UIProcess/API/gtk/WebKitWebView.cpp:
271         (webkitWebViewUpdateSettings):
272         * UIProcess/API/gtk/WebKitWebViewBase.cpp:
273         (webkitWebViewBaseUpdatePreferences):
274         (webkitWebViewBaseCreateWebPage):
275         * UIProcess/API/gtk/WebKitWebViewBasePrivate.h:
276
277 2013-09-04  Commit Queue  <commit-queue@webkit.org>
278
279         Unreviewed, rolling out r154989.
280         http://trac.webkit.org/changeset/154989
281         https://bugs.webkit.org/show_bug.cgi?id=120678
282
283         This patch might broke apps using webkitgtk not from the main
284         thread (Requested by msanchez on #webkit).
285
286         * UIProcess/API/gtk/WebKitWebView.cpp:
287         (webkitWebViewRunAsModal):
288         * UIProcess/gtk/WebPopupMenuProxyGtk.cpp:
289         (WebKit::WebPopupMenuProxyGtk::showPopupMenu):
290
291 2013-09-04  Zan Dobersek  <zdobersek@igalia.com>
292
293         [GTK] Add support for the Wayland build target
294         https://bugs.webkit.org/show_bug.cgi?id=120627
295
296         Reviewed by Gustavo Noronha Silva.
297
298         * GNUmakefile.list.am: Build X11-specific NetscapePluginModule and NetscapePlugin classes if building the X11 target,
299         fall back to the generic, empty classes otherwise.
300         * PluginProcess/unix/PluginProcessMainUnix.cpp:
301         (WebKit::PluginProcessMainUnix): Guard the NetscapePluginModule::scanPlugin() invocation with PLUGIN_ARCHITECTURE(X11),
302         it's at the moment specific to the X11 implementation of the Netscape plugins.
303         * UIProcess/Plugins/unix/PluginProcessProxyUnix.cpp: Guard PluginProcessProxy::scanPlugin() with PLUGIN_ARCHITECTURE(X11),
304         just like it's guarded in the PluginProcessProxy class declaration.
305         * UIProcess/cairo/BackingStoreCairo.cpp: Additionally guard <gdk/gdkx.h> and WidgetBackingStoreGtkX11 inclusion and use
306         with PLATFORM(X11), this code should only be built when building the X11 target.
307         (WebKit::createBackingStoreForGTK):
308         * UIProcess/gtk/WebPageProxyGtk.cpp: Guard the createPluginContainer() and windowedPluginGeometryDidChange() methods and their
309         helper functions and objects with PLUGIN_ARCHITECTURE(X11), just like they're guarded in the WebPageProxy class declaration.
310         * config.h: Only define PLUGIN_ARCHITECTURE_X11 to 1 if we're actually building the X11 target.
311
312 2013-09-03  Darin Adler  <darin@apple.com>
313
314         REGRESSION (r154967) window resize is very choppy
315         https://bugs.webkit.org/show_bug.cgi?id=120653
316
317         Reviewed by Andreas Kling.
318
319         Andreas Kling spotted the bad change.
320
321         * Platform/CoreIPC/Connection.cpp:
322         (CoreIPC::Connection::waitForMessage): Roll out this incorrect change.
323         The code here is not the same as a call to take.
324
325 2013-09-03  Anton Obzhirov  <a.obzhirov@samsung.com>
326
327         [GTK] gdk threads deprecated functions calls should be refactored
328         https://bugs.webkit.org/show_bug.cgi?id=120070
329
330         Reviewed by Mario Sanchez Prada.
331
332         Removed deprecated functions gdk_threads_leave()/gdk_threads_enter() functions since
333         there is no more checks for threads lock in GTK 3.6.
334
335         * UIProcess/API/gtk/WebKitWebView.cpp:
336         (webkitWebViewRunAsModal):
337         * UIProcess/gtk/WebPopupMenuProxyGtk.cpp:
338         (WebKit::WebPopupMenuProxyGtk::showPopupMenu):
339
340 2013-09-03  Brian Holt  <brian.holt@samsung.com>
341
342         [GTK] [WK2] TestContextMenu default-menu fails
343         https://bugs.webkit.org/show_bug.cgi?id=120459
344
345         Reviewed by Gustavo Noronha Silva.
346
347         Add context menu items for downloading media elements.
348
349         * UIProcess/API/gtk/WebKitContextMenuActions.cpp:
350         (webkitContextMenuActionGetActionTag):
351         (webkitContextMenuActionGetForContextMenuItem):
352         (webkitContextMenuActionGetLabel):
353         * UIProcess/API/gtk/WebKitContextMenuActions.h:
354         * UIProcess/API/gtk/tests/TestContextMenu.cpp:
355
356 2013-09-02  Darin Adler  <darin@apple.com>
357
358         Cut down on double hashing and code needlessly using hash table iterators
359         https://bugs.webkit.org/show_bug.cgi?id=120611
360
361         Reviewed by Andreas Kling.
362
363         * Platform/CoreIPC/Connection.cpp:
364         (CoreIPC::Connection::waitForMessage): Use take instead of find/remove.
365
366         * UIProcess/WebPreferences.cpp:
367         (WebKit::WebPreferences::removePageGroup): Use the return value from remove
368         instead of find/remove.
369
370         * WebProcess/Geolocation/GeolocationPermissionRequestManager.cpp:
371         (WebKit::GeolocationPermissionRequestManager::cancelRequestForGeolocation):
372         (WebKit::GeolocationPermissionRequestManager::didReceiveGeolocationPermissionDecision):
373         Use take instead of find/remove.
374
375         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
376         (WebKit::NetscapePlugin::frameDidFinishLoading): Use take instead of find/remove.
377         (WebKit::NetscapePlugin::frameDidFail): Use take instead of find/remove.
378
379         * WebProcess/WebPage/WebBackForwardListProxy.cpp:
380         (WebKit::WebBackForwardListProxy::removeItem): Use take instead of find/remove.
381
382         * WebProcess/WebPage/WebPage.cpp:
383         (WebKit::WebPage::didFinishCheckingText): Use take instead of get/remove so we
384         hash only once.
385         (WebKit::WebPage::didCancelCheckingText): Ditto.
386         (WebKit::WebPage::stopExtendingIncrementalRenderingSuppression): Use the return
387         value from remove instead of contains/remove so we hash only once.
388
389 2013-09-02  Darin Adler  <darin@apple.com>
390
391         [Mac] No need for HardAutorelease, which is same as CFBridgingRelease
392         https://bugs.webkit.org/show_bug.cgi?id=120569
393
394         Reviewed by Andy Estes.
395
396         * Platform/mac/StringUtilities.mm:
397         (WebKit::nsStringFromWebCoreString): Use CFBridgingRelease. Also
398         changed condition to be a little cleaner and use a constant string for empty
399         strings as well as null strings.
400
401         * UIProcess/API/mac/WKBrowsingContextController.mm:
402         (autoreleased): Switched from autorelease to CFBridgingRelease for strings,
403         which eliminates a type cast and makes this work under GC, although I don't
404         think we should compile WebKit2 for GC.
405
406         * WebProcess/WebPage/mac/WKAccessibilityWebPageObject.mm:
407         (-[WKAccessibilityWebPageObject accessibilityAttributeValue:forParameter:]):
408         Use CFBridgingRelease.
409
410 2013-09-02  Csaba Osztrogonác  <ossy@webkit.org>
411
412         REGRESSION(r154909): caused many crashes on Qt WK2, EFL WK2
413         https://bugs.webkit.org/show_bug.cgi?id=120600
414
415         Reviewed by Andreas Kling.
416
417         * Shared/CoordinatedGraphics/CoordinatedGraphicsArgumentCoders.cpp:
418         (CoreIPC::::decode): keyTime should be double here too.
419
420 2013-09-01  Alexey Proskuryakov  <ap@apple.com>
421
422         [WK2][Mac] Drag and drop tests interfere with user's UI
423         https://bugs.webkit.org/show_bug.cgi?id=120538
424
425         Reviewed by Dan Bernstein.
426
427         * UIProcess/API/mac/WKView.mm: (-[WKView _setDragImage:at:linkDrag:]): Make it possible
428         to override drag initiation in subclasses. It is a bit unfortunate that this exposes
429         a deprecated API that we call, but probably not unfortunate enough to invent a new
430         scary looking name for the same function, and conditionally call that if implemented
431         by subclass.
432
433 2013-08-31  Santosh Mahto  <santosh.ma@samsung.com>
434
435         warning: unused parameter point and area in EwkView.cpp:1390
436         https://bugs.webkit.org/show_bug.cgi?id=120545
437
438         Reviewed by Darin Adler.
439
440         * UIProcess/API/efl/EwkView.cpp:
441         (EwkView::didFindZoomableArea): Added UNUSED_PARAM.
442
443 2013-08-31  Jae Hyun Park  <jae.park@company100.net>
444
445         Remove unused variable in LayerTreeHost
446         https://bugs.webkit.org/show_bug.cgi?id=118950
447
448         Reviewed by Anders Carlsson.
449
450         m_waitingForUIProcess has been renamed to m_isWaitingForRenderer as of
451         r152183, and it is a private variable in CoordinatedLayerTreeHost. Thus,
452         we don't need m_waitingForUIProcess in LayerTreeHost.
453
454         * WebProcess/WebPage/LayerTreeHost.h:
455
456 2013-08-30  Brian Holt  <brian.holt@samsung.com>
457
458         [GTK] [WK2] TestWebKitWebView snapshot fails
459         https://bugs.webkit.org/show_bug.cgi?id=120404
460
461         Reviewed by Darin Adler.
462
463         Fixed the snapshot test failure caused by GTK no longer allowing
464         widgets to resize.  Instead, resize the WebView by resizing the
465         window and waiting for the event to complete asynchronously.
466
467         * UIProcess/API/gtk/tests/WebViewTest.cpp:
468         (WebViewTest::resizeView):
469
470 2013-08-30  Csaba Osztrogonác  <ossy@webkit.org>
471
472         Add USE(PROTECTION_SPACE_AUTH_CALLBACK) guards to canAuthenticateAgainstProtectionSpace()
473         https://bugs.webkit.org/show_bug.cgi?id=120351
474
475         Reviewed by Darin Adler.
476
477         * NetworkProcess/AsynchronousNetworkLoaderClient.cpp:
478         * NetworkProcess/AsynchronousNetworkLoaderClient.h:
479         * NetworkProcess/NetworkLoaderClient.h:
480         * NetworkProcess/SynchronousNetworkLoaderClient.cpp:
481         * NetworkProcess/SynchronousNetworkLoaderClient.h:
482
483 2013-08-30  Gabor Abraham  <abrhm@inf.u-szeged.hu>
484
485         Fix, remove unused parameter in UIProcess/WebColorPicker.cpp.
486         https://bugs.webkit.org/show_bug.cgi?id=120525
487
488         Reviewed by Darin Adler.
489
490         * UIProcess/WebColorPicker.cpp:
491         (WebKit::WebColorPicker::showColorPicker):
492
493 2013-08-30  Tamas Czene  <tczene@inf.u-szeged.hu>
494
495         Resolve unused parameter warning in WebPlatformStrategies.cpp
496         https://bugs.webkit.org/show_bug.cgi?id=120515
497
498         Reviewed by Darin Adler.
499
500         * WebProcess/WebPage/TapHighlightController.cpp:
501         (WebKit::TapHighlightController::drawRect):
502
503 2013-08-30  Tamas Czene  <tczene@inf.u-szeged.hu>
504
505         Resolve unused parameter warning in FindController.cpp
506         https://bugs.webkit.org/show_bug.cgi?id=120516
507
508         Reviewed by Darin Adler.
509
510         * WebProcess/WebPage/FindController.cpp:
511         (WebKit::FindController::drawRect):
512
513 2013-08-30  Tamas Czene  <tczene@inf.u-szeged.hu>
514
515         Resolve unused parameter warning in WKBundlePageOverlay.cpp
516         https://bugs.webkit.org/show_bug.cgi?id=120521
517
518         Reviewed by Andreas Kling.
519
520         * WebProcess/InjectedBundle/API/c/WKBundlePageOverlay.cpp:
521         (WKBundlePageOverlayFractionFadedIn):
522
523 2013-08-30  Antti Koivisto  <antti@apple.com>
524
525         Remove code behind ENABLE(DIALOG_ELEMENT)
526         https://bugs.webkit.org/show_bug.cgi?id=120467
527
528         Reviewed by Darin Adler.
529
530         * Configurations/FeatureDefines.xcconfig:
531
532 2013-08-29  Sam Weinig  <sam@webkit.org>
533
534         Add ENABLE gaurds for Promises
535         https://bugs.webkit.org/show_bug.cgi?id=120488
536
537         Reviewed by Andreas Kling.
538
539         * Configurations/FeatureDefines.xcconfig:
540
541 2013-08-29  Zan Dobersek  <zdobersek@igalia.com>
542
543         [Automake] libWebCoreDOM.la could use a better name
544         https://bugs.webkit.org/show_bug.cgi?id=120232
545
546         Reviewed by Martin Robinson.
547
548         * GNUmakefile.am: libWebCoreDOM has a new name - libGObjectDOMBindings.
549
550 2013-08-29  Joseph Pecoraro  <pecoraro@apple.com>
551
552         Web Inspector: Download Web Archive of Inspected Page
553         https://bugs.webkit.org/show_bug.cgi?id=119774
554
555         Reviewed by Timothy Hatcher.
556
557         Update to support InspectorFrontendHost.save's new base64Encoded
558         parameter. It means the incoming content is binary data, not a string.
559
560         * UIProcess/WebInspectorProxy.cpp:
561         (WebKit::WebInspectorProxy::save):
562         * UIProcess/WebInspectorProxy.h:
563         * UIProcess/WebInspectorProxy.messages.in:
564         * UIProcess/efl/WebInspectorProxyEfl.cpp:
565         (WebKit::WebInspectorProxy::platformSave):
566         * UIProcess/gtk/WebInspectorProxyGtk.cpp:
567         (WebKit::WebInspectorProxy::platformSave):
568         * UIProcess/mac/WebInspectorProxyMac.mm:
569         (WebKit::WebInspectorProxy::platformSave):
570         * UIProcess/qt/WebInspectorProxyQt.cpp:
571         (WebKit::WebInspectorProxy::platformSave):
572         * WebProcess/WebCoreSupport/WebInspectorFrontendClient.cpp:
573         (WebKit::WebInspectorFrontendClient::save):
574         * WebProcess/WebCoreSupport/WebInspectorFrontendClient.h:
575         * WebProcess/WebPage/WebInspector.cpp:
576         (WebKit::WebInspector::save):
577         * WebProcess/WebPage/WebInspector.h:
578
579 2013-08-29  Brian Holt  <brian.holt@samsung.com>
580
581         [GTK] [WK2] TestWebKitWebView page-visibility fails
582         https://bugs.webkit.org/show_bug.cgi?id=120406
583
584         Reviewed by Gustavo Noronha Silva.
585
586         Removed the webkit prefix for document visibility properties.
587
588         * UIProcess/API/gtk/tests/TestWebKitWebView.cpp:
589         (testWebViewPageVisibility):
590
591 2013-08-28  Chris Curtis  <chris_curtis@apple.com>
592
593         https://bugs.webkit.org/show_bug.cgi?id=119548
594         Refactoring Exception throws.
595
596         Reviewed by Geoffrey Garen.
597         
598         Moved setting an exception into the vm, These functions changed to use the new functionality.
599
600         * WebProcess/Plugins/Netscape/JSNPObject.cpp:
601         (WebKit::JSNPObject::callMethod):
602         (WebKit::JSNPObject::callObject):
603         (WebKit::JSNPObject::callConstructor):
604         (WebKit::JSNPObject::throwInvalidAccessError):
605         * WebProcess/Plugins/Netscape/NPRuntimeObjectMap.cpp:
606         (WebKit::NPRuntimeObjectMap::moveGlobalExceptionToExecState):
607
608 2013-08-28  Anders Carlsson  <andersca@apple.com>
609
610         Allow the Flash plug-in to open its preference pane
611         https://bugs.webkit.org/show_bug.cgi?id=120431
612         <rdar://problem/14857039>
613
614         Reviewed by Andreas Kling.
615
616         Forward the -[NSWorkspace openFile:] call to the UI process and allow opening
617         the Flash preference pane (if Flash asks for it).
618
619         * PluginProcess/PluginProcess.h:
620         * PluginProcess/mac/PluginProcessMac.mm:
621         (WebKit::replacedNSWorkspace_openFile):
622         (WebKit::initializeCocoaOverrides):
623         (WebKit::PluginProcess::openFile):
624         * UIProcess/Plugins/PluginProcessProxy.h:
625         * UIProcess/Plugins/PluginProcessProxy.messages.in:
626         * UIProcess/Plugins/mac/PluginProcessProxyMac.mm:
627         (WebKit::PluginProcessProxy::openURL):
628         (WebKit::shouldOpenFile):
629         (WebKit::PluginProcessProxy::openFile):
630
631 2013-08-28  Tamas Czene  <tczene@inf.u-szeged.hu>
632
633         [wk2] Resolve unused parameters in WebPlatformStrategies.cpp
634         https://bugs.webkit.org/show_bug.cgi?id=120410
635
636         Reviewed by Darin Adler.
637
638         * WebProcess/WebCoreSupport/WebPlatformStrategies.cpp:
639         (WebKit::WebPlatformStrategies::getPluginInfo):
640         (WebKit::WebPlatformStrategies::transientLocalStorageNamespace):
641
642 2013-08-28  Tamas Czene  <tczene@inf.u-szeged.hu>
643
644         [wk2] Resolve unused parameter warnings in the WebProcess.cpp
645         https://bugs.webkit.org/show_bug.cgi?id=120412
646
647         Reviewed by Darin Adler.
648
649         * WebProcess/WebProcess.cpp:
650         (WebKit::WebProcess::startMemorySampler):
651
652 2013-08-28  Darin Adler  <darin@apple.com>
653
654         Eliminate Pasteboard::generalPasteboard
655         https://bugs.webkit.org/show_bug.cgi?id=120392
656
657         Reviewed by Anders Carlsson.
658
659         * WebProcess/WebCoreSupport/WebEditorClient.cpp:
660         (WebKit::WebEditorClient::updateGlobalSelection):
661         Use createForGlobalSelection instead of generalPasteboard and setSelectionMode.
662
663 2013-08-28  Ábrahám Gábor  <abrhm@inf.u-szeged.hu>
664
665         Fix unused variable warning.
666         https://bugs.webkit.org/show_bug.cgi?id=120396
667
668         Reviewed by Allan Sandfeld Jensen.
669
670         Fix unused variable compiler warning in PageOverlay.h
671
672         * WebProcess/WebPage/PageOverlay.h:
673         (WebKit::PageOverlay::Client::copyAccessibilityAttributeValue):
674         (WebKit::PageOverlay::Client::copyAccessibilityAttributeNames):
675
676
677 2013-08-28  Zan Dobersek  <zdobersek@igalia.com>
678
679         [GTK][WK2] Only set up a RedirectedXCompositeWindow if running under an X11 display
680         https://bugs.webkit.org/show_bug.cgi?id=120321
681
682         Reviewed by Gustavo Noronha Silva.
683
684         Only set up the RedirectedXCompositeWindow member of the WebKitWebViewBasePrivate struct
685         if we're running under an X11 display. This is now done in the webkitWebViewBaseConstructed
686         function rather than the constructor, which is removed.
687
688         This allows for the UIProcess to run in a Wayland environment even when built with accelerated
689         compositing enabled. Of course, at the moment there's no support yet for accelerated compositing
690         under Wayland, so we fall back to rendering the backing store. No changes are introduced to
691         the behavior under X11 - accelerated compositing will be used where possible, if supported.
692
693         * UIProcess/API/gtk/WebKitWebViewBase.cpp:
694         (webkitWebViewBaseConstructed):
695
696 2013-08-28  Zan Dobersek  <zdobersek@igalia.com>
697
698         [GTK][WK2] Disable accelerated compositing under Wayland
699         https://bugs.webkit.org/show_bug.cgi?id=120347
700
701         Reviewed by Martin Robinson.
702
703         Accelerated compositing is not yet supported under the Wayland display protocol,
704         so it should be disabled. Since it is enabled by default and the GTK WK2 API does
705         not provide any way to change that, it's enough to disable it when attaching the
706         WebKitSettings object to the WebPageGroup if running under Wayland.
707
708         * UIProcess/API/gtk/WebKitWebViewGroup.cpp:
709         (webkitWebViewGroupAttachSettingsToPageGroup):
710
711 2013-08-28  Alexandre Abreu  <alexandre.abreu@canonical.com>
712
713         Add a 'isMainFrame' parameter to QWebNavigationRequest.
714         https://bugs.webkit.org/show_bug.cgi?id=118860
715
716         Reviewed by Simon Hausmann.
717
718         * UIProcess/API/qt/qwebnavigationrequest.cpp:
719         (QWebNavigationRequestPrivate::QWebNavigationRequestPrivate):
720         (QWebNavigationRequest::QWebNavigationRequest):
721         (QWebNavigationRequest::navigationType):
722         (QWebNavigationRequest::isMainFrame):
723         * UIProcess/API/qt/qwebnavigationrequest_p.h:
724         * UIProcess/API/qt/tests/publicapi/tst_publicapi.cpp:
725         * UIProcess/qt/QtWebPagePolicyClient.cpp:
726         (WebKit::QtWebPagePolicyClient::decidePolicyForNavigationAction):
727         * UIProcess/qt/QtWebPagePolicyClient.h:
728
729 2013-08-27  Luciano Wolf  <luciano.wolf@openbossa.org>
730
731         100% cpu usage for "transition: opacity" animation
732         https://bugs.webkit.org/show_bug.cgi?id=120012
733
734         Reviewed by Noam Rosenthal.
735
736         Schedule animation timer after scheduling a layer flush. This way it
737         won't overwrite animation timer with "0", thus avoiding 100% cpu usage.
738
739         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.cpp:
740         (WebKit::CoordinatedLayerTreeHost::scheduleAnimation):
741
742 2013-08-27  Csaba Osztrogonác  <ossy@webkit.org>
743
744         [WK2][Soup] Add WebFrameNetworkingContext::webFrameLoaderClient() after r154490
745         https://bugs.webkit.org/show_bug.cgi?id=120353
746
747         Reviewed by Alexey Proskuryakov.
748
749         * WebProcess/WebCoreSupport/WebPlatformStrategies.cpp:
750         * WebProcess/WebCoreSupport/soup/WebFrameNetworkingContext.cpp:
751         (WebKit::WebFrameNetworkingContext::webFrameLoaderClient):
752         * WebProcess/WebCoreSupport/soup/WebFrameNetworkingContext.h:
753
754 2013-08-26  Santosh Mahto  <santosh.ma@samsung.com>
755
756         Fixing compilation warning "unused parameter" in WebPageProxy.cpp
757         https://bugs.webkit.org/show_bug.cgi?id=120205
758
759         Reviewed by Anders Carlsson.
760
761         * UIProcess/WebPageProxy.cpp:
762         (WebKit::WebPageProxy::findPlugin):
763         (WebKit::WebPageProxy::didBlockInsecurePluginVersion):
764         Added UNUSED_PARAM to avoid warning.
765
766 2013-08-23  Andy Estes  <aestes@apple.com>
767
768         Fix issues found by the Clang Static Analyzer
769         https://bugs.webkit.org/show_bug.cgi?id=120230
770
771         Reviewed by Darin Adler.
772
773         * UIProcess/API/mac/WKBrowsingContextController.mm:
774         (autoreleased): Don't leak CFURLs when in Objective-C GC.
775         * WebProcess/WebPage/mac/WKAccessibilityWebPageObject.mm:
776         (-[WKAccessibilityWebPageObject accessibilityAttributeValue:forParameter:]):
777         Don't leak CFStrings when in Objective-C GC.
778
779 2013-08-26  Csaba Osztrogonác  <ossy@webkit.org>
780
781         [WK2] Buildfix for non Mac platforms
782         https://bugs.webkit.org/show_bug.cgi?id=120294
783
784         Reviewed by Darin Adler.
785
786         * NetworkProcess/AsynchronousNetworkLoaderClient.cpp:
787         (WebKit::AsynchronousNetworkLoaderClient::didReceiveBuffer):
788         * NetworkProcess/NetworkResourceLoader.h:
789
790 2013-08-26  Alexey Proskuryakov  <ap@apple.com>
791
792         [Mac] can-read-in-dragstart-event.html and can-read-in-copy-and-cut-events.html fail
793         https://bugs.webkit.org/show_bug.cgi?id=113094
794
795         Reviewed by Darin Adler.
796
797         Return new pasteboard change count from all functions that change it.
798
799         * UIProcess/WebContext.h:
800         * UIProcess/WebContext.messages.in:
801         * UIProcess/mac/WebContextMac.mm:
802         (WebKit::WebContext::pasteboardCopy):
803         (WebKit::WebContext::addPasteboardTypes):
804         (WebKit::WebContext::setPasteboardTypes):
805         (WebKit::WebContext::setPasteboardPathnamesForType):
806         (WebKit::WebContext::setPasteboardStringForType):
807         (WebKit::WebContext::setPasteboardBufferForType):
808         * WebProcess/Plugins/PDF/PDFPlugin.mm:
809         (WebKit::PDFPlugin::writeItemsToPasteboard):
810         * WebProcess/WebCoreSupport/WebPlatformStrategies.cpp:
811         (WebKit::WebPlatformStrategies::copy):
812         (WebKit::WebPlatformStrategies::changeCount):
813         (WebKit::WebPlatformStrategies::addTypes):
814         (WebKit::WebPlatformStrategies::setTypes):
815         (WebKit::WebPlatformStrategies::setBufferForType):
816         (WebKit::WebPlatformStrategies::setPathnamesForType):
817         (WebKit::WebPlatformStrategies::setStringForType):
818         * WebProcess/WebCoreSupport/WebPlatformStrategies.h:
819
820 2013-08-26  Andreas Kling  <akling@apple.com>
821
822         Unreviewed build fix.
823
824         * WebProcess/WebPage/WebFrame.cpp:
825         (WebKit::WebFrame::createWithCoreMainFrame):
826         (WebKit::WebFrame::createSubframe):
827
828 2013-08-26  Pratik Solanki  <psolanki@apple.com>
829
830         PageGroup::groupSettings() should return a reference
831         https://bugs.webkit.org/show_bug.cgi?id=120319
832
833         Reviewed by Andreas Kling.
834
835         PageGroup::m_groupSettings is never NULL so we can just return a reference from groupSettings().
836
837         * WebProcess/Storage/StorageNamespaceImpl.cpp:
838         (WebKit::StorageNamespaceImpl::createLocalStorageNamespace):
839
840 2013-08-26  Andreas Kling  <akling@apple.com>
841
842         WebCore: Let Page create the main Frame.
843         <https://webkit.org/b/119964>
844
845         Reviewed by Anders Carlsson.
846
847         * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
848         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
849         (WebKit::WebFrameLoaderClient::WebFrameLoaderClient):
850
851             This starts out with a null WebFrame* pointer now.
852
853         (WebKit::WebFrameLoaderClient::setWebFrame):
854
855             WebFrame hooks itself up through this as soon as it's constructed.
856
857         (WebKit::WebFrameLoaderClient::frameLoaderDestroyed):
858
859             Tweak an out-of-date comment. The ref() we're balancing out comes from
860             WebFrame::create().
861
862         * WebProcess/WebPage/WebFrame.cpp:
863         (WebKit::WebFrame::createWithCoreMainFrame):
864
865             Rewrote createMainFrame() as createWithCoreMainFrame(). The new method wraps
866             an existing WebCore::Frame instead of creating a new one.
867
868         (WebKit::WebFrame::createSubframe):
869
870             Merged WebFrame::init() into here since the logic isn't shared with main
871             Frame creation anymore.
872
873         (WebKit::WebFrame::create):
874         (WebKit::WebFrame::WebFrame):
875
876             Call WebFrameLoaderClient::setWebFrame(this).
877
878         * WebProcess/WebPage/WebFrame.h:
879
880             WebFrame::m_frameLoaderClient is now an OwnPtr rather than an inline member.
881             This way it can be created before the WebFrame.
882
883         * WebProcess/WebPage/WebPage.cpp:
884         (WebKit::WebPage::WebPage):
885
886             Set up a WebFrameLoaderClient and pass it to the Page constructor along with
887             the other PageClients.
888
889 2013-08-24  Carlos Garcia Campos  <cgarcia@igalia.com>
890
891         [GTK] Add WebKit2 API for isolated worlds
892         https://bugs.webkit.org/show_bug.cgi?id=103377
893
894         Reviewed by Anders Carlsson.
895
896         * GNUmakefile.list.am: Add new files to compilation.
897         * UIProcess/API/gtk/docs/webkit2gtk-sections.txt: Add new symbols.
898         * UIProcess/API/gtk/tests/TestWebExtensions.cpp:
899         (testWebExtensionWindowObjectCleared):
900         (scriptDialogCallback):
901         (runJavaScriptInIsolatedWorldFinishedCallback):
902         (testWebExtensionIsolatedWorld):
903         (beforeAll):
904         * UIProcess/API/gtk/tests/WebExtensionTest.cpp:
905         (echoCallback):
906         (windowObjectCleared):
907         (getWebPage):
908         (methodCallCallback):
909         * WebProcess/InjectedBundle/API/gtk/WebKitFrame.cpp:
910         (webkit_frame_get_javascript_context_for_script_world): New public
911         method to tget the JavaScript execution context for a given script
912         world.
913         * WebProcess/InjectedBundle/API/gtk/WebKitFrame.h:
914         * WebProcess/InjectedBundle/API/gtk/WebKitScriptWorld.cpp: Added.
915         (scriptWorlds): Global WebKitScriptWorld map.
916         (_WebKitScriptWorldPrivate::~_WebKitScriptWorldPrivate):
917         (webkitScriptWorldGet): Get the WebKitScriptWorld wrapping the
918         given injected bundle script world.
919         (webkitScriptWorldGetInjectedBundleScriptWorld): Get the injected
920         bundle script world wrapped by the given WebKitScriptWorld.
921         (webkitScriptWorldWindowObjectCleared): Emit
922         WebKitScriptWorld::window-object-cleared signal.
923         (webkitScriptWorldCreate): Create a new WebKitScriptWorld wrapping
924         the given injected bundle script world.
925         (createDefaultScriptWorld): Create the default WebKitScriptWorld
926         wrapping the normal world.
927         (webkit_script_world_get_default): Return the default WebKitScriptWorld.
928         (webkit_script_world_new): Create a new isolated WebKitScriptWorld.
929         * WebProcess/InjectedBundle/API/gtk/WebKitScriptWorld.h: Added.
930         * WebProcess/InjectedBundle/API/gtk/WebKitScriptWorldPrivate.h: Added.
931         * WebProcess/InjectedBundle/API/gtk/WebKitWebPage.cpp:
932         (didClearWindowObjectForFrame): Call webkitScriptWorldWindowObjectCleared().
933         (webkitWebPageCreate): Add implementation for callback
934         didClearWindowObjectForFrame in injected bundle loader client.
935         * WebProcess/InjectedBundle/API/gtk/webkit-web-extension.h:
936         Include WebKitScriptWorld.h.
937
938 2013-08-26  Carlos Garcia Campos  <cgarcia@igalia.com>
939
940         [WebKit2] Offsets for WKBundlePageLoaderClient in APIClientTraits are wrong
941         https://bugs.webkit.org/show_bug.cgi?id=120268
942
943         Reviewed by Anders Carlsson.
944
945         * Shared/APIClientTraits.cpp: Use always the first member of every
946         version as the offset of the version.
947
948 2013-08-26  Carlos Garcia Campos  <cgarcia@igalia.com>
949
950         [GTK] Add missing initializer for pluginLoadPolicy in WKPageLoaderClient
951         https://bugs.webkit.org/show_bug.cgi?id=120289
952
953         Reviewed by Philippe Normand.
954
955         * UIProcess/API/gtk/WebKitLoaderClient.cpp:
956         (attachLoaderClientToView): Add initializer for pluginLoadPolicy
957         and rename the comment of the previous one as
958         pluginLoadPolicy_deprecatedForUseWithV2.
959
960 2013-08-26  Carlos Garcia Campos  <cgarcia@igalia.com>
961
962         [GTK] webkitCredentialGetCredential returns a temporary in g_return_val_if_fail
963         https://bugs.webkit.org/show_bug.cgi?id=120287
964
965         Reviewed by Philippe Normand.
966
967         * UIProcess/API/gtk/WebKitCredential.cpp:
968         (webkitCredentialGetCredential): Use ASSERT() instead of
969         g_return_val_if_fail() since this is a private function.
970
971 2013-08-25  Zan Dobersek  <zdobersek@igalia.com>
972
973         Unreviewed GTK build fix after r154565.
974
975         * UIProcess/API/gtk/tests/TestInspector.cpp: Include the Vector header.
976         * UIProcess/API/gtk/tests/TestResources.cpp: Ditto.
977
978 2013-08-24  Darin Adler  <darin@apple.com>
979
980         Frame::tree should return a reference instead of a pointer
981         https://bugs.webkit.org/show_bug.cgi?id=120259
982
983         Reviewed by Andreas Kling.
984
985         * WebProcess/Plugins/PluginView.cpp:
986         (WebKit::PluginView::performJavaScriptURLRequest):
987         * WebProcess/Storage/StorageAreaMap.cpp:
988         (WebKit::StorageAreaMap::dispatchSessionStorageEvent):
989         (WebKit::StorageAreaMap::dispatchLocalStorageEvent):
990         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
991         (WebKit::WebFrameLoaderClient::createFrame):
992         * WebProcess/WebCoreSupport/mac/WebContextMenuClientMac.mm:
993         (WebKit::WebContextMenuClient::searchWithSpotlight):
994         * WebProcess/WebPage/FindController.cpp:
995         (WebKit::frameWithSelection):
996         (WebKit::FindController::rectsForTextMatches):
997         * WebProcess/WebPage/WebFrame.cpp:
998         (WebKit::WebFrame::init):
999         (WebKit::WebFrame::contentsAsString):
1000         (WebKit::WebFrame::name):
1001         (WebKit::WebFrame::childFrames):
1002         * WebProcess/WebPage/WebPage.cpp:
1003         (WebKit::WebPage::clearMainFrameName):
1004         (WebKit::WebPage::setDrawsBackground):
1005         (WebKit::WebPage::setDrawsTransparentBackground):
1006         (WebKit::WebPage::setWindowResizerSize):
1007         (WebKit::frameWithSelection):
1008         (WebKit::WebPage::unmarkAllMisspellings):
1009         (WebKit::WebPage::unmarkAllBadGrammar):
1010         (WebKit::pageContainsAnyHorizontalScrollbars):
1011         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
1012         (WebKit::TiledCoreAnimationDrawingArea::forceRepaint):
1013         Use tree(). instead of tree()->.
1014
1015 2013-08-24  Commit Queue  <commit-queue@webkit.org>
1016
1017         Unreviewed, rolling out r154545.
1018         http://trac.webkit.org/changeset/154545
1019         https://bugs.webkit.org/show_bug.cgi?id=120252
1020
1021         Broke WebKit2 API tests (Requested by andersca on #webkit).
1022
1023         * GNUmakefile.list.am:
1024         * UIProcess/API/gtk/docs/webkit2gtk-sections.txt:
1025         * UIProcess/API/gtk/tests/TestWebExtensions.cpp:
1026         (beforeAll):
1027         * UIProcess/API/gtk/tests/WebExtensionTest.cpp:
1028         (methodCallCallback):
1029         * WebProcess/InjectedBundle/API/gtk/WebKitFrame.cpp:
1030         (webkit_frame_get_javascript_global_context):
1031         * WebProcess/InjectedBundle/API/gtk/WebKitFrame.h:
1032         * WebProcess/InjectedBundle/API/gtk/WebKitScriptWorld.cpp: Removed.
1033         * WebProcess/InjectedBundle/API/gtk/WebKitScriptWorld.h: Removed.
1034         * WebProcess/InjectedBundle/API/gtk/WebKitScriptWorldPrivate.h: Removed.
1035         * WebProcess/InjectedBundle/API/gtk/WebKitWebPage.cpp:
1036         (webkitWebPageCreate):
1037         * WebProcess/InjectedBundle/API/gtk/webkit-web-extension.h:
1038
1039 2013-08-24  Carlos Garcia Campos  <cgarcia@igalia.com>
1040
1041         [GTK] Add WebKit2 API for isolated worlds
1042         https://bugs.webkit.org/show_bug.cgi?id=103377
1043
1044         Reviewed by Anders Carlsson.
1045
1046         * GNUmakefile.list.am: Add new files to compilation.
1047         * UIProcess/API/gtk/docs/webkit2gtk-sections.txt: Add new symbols.
1048         * UIProcess/API/gtk/tests/TestWebExtensions.cpp:
1049         (testWebExtensionWindowObjectCleared):
1050         (scriptDialogCallback):
1051         (runJavaScriptInIsolatedWorldFinishedCallback):
1052         (testWebExtensionIsolatedWorld):
1053         (beforeAll):
1054         * UIProcess/API/gtk/tests/WebExtensionTest.cpp:
1055         (echoCallback):
1056         (windowObjectCleared):
1057         (getWebPage):
1058         (methodCallCallback):
1059         * WebProcess/InjectedBundle/API/gtk/WebKitFrame.cpp:
1060         (webkit_frame_get_javascript_context_for_script_world): New public
1061         method to tget the JavaScript execution context for a given script
1062         world.
1063         * WebProcess/InjectedBundle/API/gtk/WebKitFrame.h:
1064         * WebProcess/InjectedBundle/API/gtk/WebKitScriptWorld.cpp: Added.
1065         (scriptWorlds): Global WebKitScriptWorld map.
1066         (_WebKitScriptWorldPrivate::~_WebKitScriptWorldPrivate):
1067         (webkitScriptWorldGet): Get the WebKitScriptWorld wrapping the
1068         given injected bundle script world.
1069         (webkitScriptWorldGetInjectedBundleScriptWorld): Get the injected
1070         bundle script world wrapped by the given WebKitScriptWorld.
1071         (webkitScriptWorldWindowObjectCleared): Emit
1072         WebKitScriptWorld::window-object-cleared signal.
1073         (webkitScriptWorldCreate): Create a new WebKitScriptWorld wrapping
1074         the given injected bundle script world.
1075         (createDefaultScriptWorld): Create the default WebKitScriptWorld
1076         wrapping the normal world.
1077         (webkit_script_world_get_default): Return the default WebKitScriptWorld.
1078         (webkit_script_world_new): Create a new isolated WebKitScriptWorld.
1079         * WebProcess/InjectedBundle/API/gtk/WebKitScriptWorld.h: Added.
1080         * WebProcess/InjectedBundle/API/gtk/WebKitScriptWorldPrivate.h: Added.
1081         * WebProcess/InjectedBundle/API/gtk/WebKitWebPage.cpp:
1082         (didClearWindowObjectForFrame): Call webkitScriptWorldWindowObjectCleared().
1083         (webkitWebPageCreate): Add implementation for callback
1084         didClearWindowObjectForFrame in injected bundle loader client.
1085         * WebProcess/InjectedBundle/API/gtk/webkit-web-extension.h:
1086         Include WebKitScriptWorld.h.
1087
1088 2013-08-24  Carlos Garcia Campos  <cgarcia@igalia.com>
1089
1090         [GTK] Expose WebKitFrame in WebKit2GTK+ web extensions API
1091         https://bugs.webkit.org/show_bug.cgi?id=119743
1092
1093         Reviewed by Anders Carlsson.
1094
1095         * GNUmakefile.list.am: Add new files to compilation.
1096         * Shared/APIClientTraits.cpp: Update for new interface version.
1097         * Shared/APIClientTraits.h: Ditto.
1098         * UIProcess/API/gtk/docs/webkit2gtk-docs.sgml: Add WebKitFrame
1099         section.
1100         * UIProcess/API/gtk/docs/webkit2gtk-sections.txt: Add new public
1101         symbols.
1102         * UIProcess/API/gtk/docs/webkit2gtk.types: Add
1103         webkit_frame_get_type.
1104         * UIProcess/API/gtk/tests/FrameTest.cpp: Added.
1105         (WebKitFrameTest::create):
1106         (WebKitFrameTest::webPageFromArgs):
1107         (WebKitFrameTest::testMainFrame):
1108         (WebKitFrameTest::testURI):
1109         (WebKitFrameTest::testJavaScriptContext):
1110         (WebKitFrameTest::runTest):
1111         (registerTests):
1112         * UIProcess/API/gtk/tests/GNUmakefile.am: Add new test files.
1113         * UIProcess/API/gtk/tests/TestFrame.cpp: Added.
1114         (webkitFrameTestRun):
1115         (testWebKitFrameMainFrame):
1116         (testWebKitFrameURI):
1117         (testWebKitFrameJavaScriptContext):
1118         (beforeAll):
1119         (afterAll):
1120         * WebProcess/InjectedBundle/API/c/WKBundlePage.h: Add
1121         willDestroyFrame callback to the injected bundle loader client, to
1122         notify the client when a frame is about to be destroyed.
1123         * WebProcess/InjectedBundle/API/gtk/WebKitFrame.cpp: Added.
1124         (webkit_frame_class_init):
1125         (webkitFrameCreate):
1126         (webkit_frame_is_main_frame):
1127         (webkit_frame_get_uri):
1128         (webkit_frame_get_javascript_global_context):
1129         * WebProcess/InjectedBundle/API/gtk/WebKitFrame.h: Added.
1130         * WebProcess/InjectedBundle/API/gtk/WebKitFramePrivate.h: Added.
1131         * WebProcess/InjectedBundle/API/gtk/WebKitWebPage.cpp:
1132         (webkitFrameGetOrCreate): Helper function to create a WebKitFrame
1133         wrapping the given WebFrame or returning the wrapper if it already
1134         exists.
1135         (willDestroyFrame): Remove the WebKitFrame wrapping the given
1136         WebFrame if it exists.
1137         (webkitWebPageCreate): Add willDestroyFrame implementation to
1138         injected bundle loader client.
1139         (webkit_web_page_get_main_frame): Return the main frame of the
1140         page.
1141         * WebProcess/InjectedBundle/API/gtk/WebKitWebPage.h:
1142         * WebProcess/InjectedBundle/API/gtk/webkit-web-extension.h:
1143         Include WebKitFrame.h.
1144         * WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.cpp:
1145         (WebKit::InjectedBundlePageLoaderClient::willDestroyFrame): New
1146         callback to be called when a frame is about to be destroyed.
1147         * WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.h:
1148         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
1149         (WebKit::WebFrameLoaderClient::frameLoaderDestroyed): Call
1150         willDestroyFrame callback of injected bundle loader client.
1151         * WebProcess/qt/QtBuiltinBundlePage.cpp:
1152         (WebKit::QtBuiltinBundlePage::QtBuiltinBundlePage): Add
1153         willDestroyFrame callback.
1154
1155 2013-08-24  Antti Koivisto  <antti@apple.com>
1156
1157         Revert accidental change.
1158         
1159         Not reviewed.
1160
1161         * WebProcess/com.apple.WebProcess.sb.in:
1162
1163 2013-08-23  Beth Dakin  <bdakin@apple.com>
1164
1165         REGRESSION (r132545): Some PDFs generated by WebKit are blank when viewed in 
1166         Adobe Reader
1167         https://bugs.webkit.org/show_bug.cgi?id=120240
1168         -and corresponding-
1169         <rdar://problem/14634453>
1170
1171         Reviewed by Anders Carlsson.
1172
1173         Hook up new WebSystemInterface API to find out if the current context is the PDF 
1174         context. 
1175
1176         * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
1177         (InitWebCoreSystemInterface):
1178
1179 2013-08-23  Alexey Proskuryakov  <ap@apple.com>
1180
1181         [WK2] Assertion failures when loading XSL stylesheets with NetworkProcess
1182         https://bugs.webkit.org/show_bug.cgi?id=120186
1183         <rdar://problem/14080273>
1184
1185         Reviewed by Brady Eidson.
1186
1187         Covered by many existing tests.
1188
1189         * WebProcess/WebCoreSupport/WebPlatformStrategies.cpp:
1190         (WebKit::WebPlatformStrategies::loadResourceSynchronously): Pass frame ID and page ID.
1191         They are mostly needed for authentication, which is not supported with sync requests,
1192         but it will be supported some day.
1193
1194         * WebProcess/WebCoreSupport/mac/WebFrameNetworkingContext.h:
1195         * WebProcess/WebCoreSupport/mac/WebFrameNetworkingContext.mm:
1196         (WebKit::WebFrameNetworkingContext::webFrameLoaderClient):
1197         Added a way to get frame loader client from WebKit NetworkingContext subclass.
1198
1199 2013-08-22  Carlos Garcia Campos  <cgarcia@igalia.com>
1200
1201         [GTK] Wrong interface version used in WebKitWebPage for loader client
1202         https://bugs.webkit.org/show_bug.cgi?id=120199
1203
1204         Reviewed by Gustavo Noronha Silva.
1205
1206         * WebProcess/InjectedBundle/API/gtk/WebKitWebPage.cpp:
1207         (webkitWebPageCreate): Use kWKBundlePageLoaderClientCurrentVersion
1208         instead of kWKBundlePageResourceLoadClientCurrentVersion in loader
1209         client initialization.
1210
1211 2013-08-22  Simon Cooper  <scooper@apple.com>
1212
1213         Need to disable FakeSYSVSHM when sandboxing is not enabled
1214         https://bugs.webkit.org/show_bug.cgi?id=120182
1215         <rdar://problem/14814461>
1216
1217         Reviewed by Alexey Proskuryakov.
1218
1219         When not in a sandbox do not enable the FakeSYSVSHIM. This
1220         allows LocalConnection to work when Flash Player is run in
1221         "Unsafe Mode".
1222
1223         * PluginProcess/mac/PluginProcessShim.mm:
1224         (WebKit::shim_disabled):
1225
1226 2013-08-22  Andy Estes  <aestes@apple.com>
1227
1228         <https://webkit.org/b/120180> Fix issues with OTHER_LDFLAGS in various .xcconfig files
1229
1230         Reviewed by David Kilzer.
1231
1232         Adding ld flags for ASAN overwrote the unexported symbol flags we were
1233         previously specifying. Since the unexported symbol ld flags are only
1234         needed for the framework target, move them to WebKit2.xcconfig where we
1235         can add them to OTHER_LDFLAGS along with the ASAN values inherited from
1236         DebugRelease.xcconfig (and other values).
1237
1238         * Configurations/Base.xcconfig: Removed the unexported symbol ld flags.
1239         * Configurations/WebKit2.xcconfig: ... and moved them here.
1240
1241 2013-08-21  Tim Horton  <timothy_horton@apple.com>
1242
1243         Another null-deref under WebDragClient::startDrag
1244         https://bugs.webkit.org/show_bug.cgi?id=120145
1245         <rdar://problem/14650652>
1246
1247         Reviewed by Simon Fraser.
1248
1249         convertImageToBitmap can legitimately return null, so don't dereference it.
1250
1251         * WebProcess/WebCoreSupport/mac/WebDragClientMac.mm:
1252         (WebKit::WebDragClient::startDrag):
1253
1254 2013-08-21  Beth Dakin  <bdakin@apple.com>
1255
1256         <https://webkit.org/b/120140> Clients expect didFirstLayout-related calls to 
1257         happen before didLayout
1258
1259         Reviewed by Anders Carlsson.
1260
1261         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
1262         (WebKit::WebFrameLoaderClient::dispatchDidLayout):
1263
1264 2013-08-21  Alexey Proskuryakov  <ap@apple.com>
1265
1266         REGRESSION (r145458?): WebProcess doesn't respect UI process localization
1267         https://bugs.webkit.org/show_bug.cgi?id=120096
1268
1269         Reviewed by Darin Adler.
1270
1271         We used to get into a situation where CFBundle thought that we had no good localization,
1272         and used one passed as default. This is never the case with mixed localizations,
1273         so default is just ignored now.
1274
1275         I think that the previous behavior was a bit of a hack. As WebProcess is not localized,
1276         it's more honest to say that we want mixed localizations, and force the language
1277         to match UI process localization.
1278
1279         * Shared/EntryPointUtilities/mac/LegacyProcess/ChildProcessEntryPoint.h:
1280         (WebKit::ChildProcessMain): Don't set default localization, it's not taken into
1281         consideration unless all other attempts to compute bundle localization fail.
1282
1283         * UIProcess/Launcher/mac/ProcessLauncherMac.mm: (WebKit::createProcess): Pass
1284         UI process localization as -AppleLanguages argument, so that Core Foundation uses
1285         that instead of actual user languages. We want to match UI process localization.
1286
1287 2013-08-20  Gavin Barraclough  <barraclough@apple.com>
1288
1289         https://bugs.webkit.org/show_bug.cgi?id=120093
1290         Remove getOwnPropertyDescriptor trap
1291
1292         Reviewed by Geoff Garen.
1293
1294         All implementations of this method are now called via the method table, and equivalent in behaviour.
1295         Remove all duplicate implementations (and the method table trap), and add a single member function implementation on JSObject.
1296
1297         * WebProcess/Plugins/Netscape/JSNPObject.cpp:
1298         * WebProcess/Plugins/Netscape/JSNPObject.h:
1299             - remove getOwnPropertyDescriptor
1300
1301 2013-08-20  Pratik Solanki  <psolanki@apple.com>
1302
1303         <https://webkit.org/b/120029> Document::markers() should return a reference
1304
1305         Reviewed by Andreas Kling.
1306
1307         Document::m_markers is never NULL so return a reference from Document::markers(). Also mark
1308         m_markers as const and initialize it in member initialization.
1309
1310         * WebProcess/WebPage/FindController.cpp:
1311         (WebKit::FindController::rectsForTextMatches):
1312         * WebProcess/WebPage/WebPage.cpp:
1313         (WebKit::WebPage::unmarkAllMisspellings):
1314         (WebKit::WebPage::unmarkAllBadGrammar):
1315
1316 2013-08-20  Gavin Barraclough  <barraclough@apple.com>
1317
1318         https://bugs.webkit.org/show_bug.cgi?id=120053
1319         Remove custom getOwnPropertyDescriptor for JSNPObject
1320
1321         Reviewed by Oliver Hunt.
1322
1323         Think this is the last one!
1324
1325         * WebProcess/Plugins/Netscape/JSNPObject.cpp:
1326             - Remove custom getOwnPropertyDescriptor implementation.
1327
1328 2013-08-20  Anton Obzhirov  <a.obzhirov@samsung.com>
1329
1330         <https://webkit.org/b/119487> [Gtk] Cancel authentication on load failed
1331
1332         Reviewed by Martin Robinson.
1333
1334         Added callback to handle load-failed event in default authentication dialog.
1335         Authentication request gets cancelled and the dialog widget gets destroyed.
1336
1337         * UIProcess/API/gtk/WebKitAuthenticationDialog.cpp:
1338         (pageLoadFailed):
1339         (webkitAuthenticationDialogInitialize):
1340         (webkitAuthenticationDialogDispose):
1341         (webkit_authentication_dialog_class_init):
1342         (webkitAuthenticationDialogNew):
1343         * UIProcess/API/gtk/WebKitAuthenticationDialog.h:
1344         * UIProcess/API/gtk/WebKitWebView.cpp:
1345         (webkitWebViewAuthenticate):
1346
1347 2013-08-20  Allan Sandfeld Jensen  <allan.jensen@digia.com>
1348
1349         [Qt][WK2] Doesn't build without Plugin-process
1350         https://bugs.webkit.org/show_bug.cgi?id=120060
1351
1352         Reviewed by Jocelyn Turcotte.
1353
1354         Disable netscape plugin api in WebKit2 when the plugin architecture is unsupported for WebKit2.
1355
1356         * Target.pri:
1357
1358 2013-08-19  Ryosuke Niwa  <rniwa@webkit.org>
1359
1360         <https://webkit.org/b/120049> Delete code for Snow Leopard
1361
1362         Reviewed by Benjamin Poulain.
1363
1364         * NetworkProcess/mac/NetworkProcessMac.mm:
1365         (WebKit::overrideSystemProxies):
1366         (WebKit::NetworkProcess::platformInitializeNetworkProcess):
1367         * WebKit2Prefix.h:
1368
1369 2013-08-19  Beth Dakin  <bdakin@apple.com>
1370
1371         <https://webkit.org/b/120027> AXObjectCache's 
1372         accessibilityEnhancedUserInterfaceEnabled should be initialized on process 
1373         creation
1374
1375         Reviewed by Sam Weinig.
1376
1377         Right now we only call AXObjectCache::setEnhancedAccessibility() when AppKit sends 
1378         us a notification indicating that the value has changed. We should not have to 
1379         rely on that to properly initialize this value. It should be done with the 
1380         WebProcessCreationParamters. 
1381
1382         * Shared/WebProcessCreationParameters.cpp:
1383         (WebKit::WebProcessCreationParameters::encode):
1384         (WebKit::WebProcessCreationParameters::decode):
1385         * Shared/WebProcessCreationParameters.h:
1386         * UIProcess/mac/WebContextMac.mm:
1387         (WebKit::WebContext::platformInitializeWebProcess):
1388         * WebProcess/mac/WebProcessMac.mm:
1389         (WebKit::WebProcess::platformInitializeWebProcess):
1390
1391 2013-08-19  Pratik Solanki  <psolanki@apple.com>
1392
1393         <https://webkit.org/b/119918> Frame::selection() should return a reference
1394
1395         Reviewed by Darin Adler.
1396
1397         m_selection is never NULL so return a reference from Frame::selection(). Also removed some
1398         unnecessary null checks and assert diff ts exposed as a result.
1399
1400         * WebProcess/WebCoreSupport/WebEditorClient.cpp:
1401         (WebKit::WebEditorClient::updateGlobalSelection):
1402         * WebProcess/WebCoreSupport/gtk/WebEditorClientGtk.cpp:
1403         (WebKit::collapseSelection):
1404         (WebKit::WebEditorClient::updateGlobalSelection):
1405         * WebProcess/WebCoreSupport/mac/WebContextMenuClientMac.mm:
1406         (WebKit::WebContextMenuClient::lookUpInDictionary):
1407         (WebKit::WebContextMenuClient::searchWithSpotlight):
1408         * WebProcess/WebPage/FindController.cpp:
1409         (WebKit::frameWithSelection):
1410         (WebKit::FindController::updateFindUIAfterPageScroll):
1411         (WebKit::FindController::getFindIndicatorBitmapAndRect):
1412         (WebKit::FindController::getImageForFindMatch):
1413         (WebKit::FindController::selectFindMatch):
1414         (WebKit::FindController::updateFindIndicator):
1415         (WebKit::FindController::drawRect):
1416         * WebProcess/WebPage/WebPage.cpp:
1417         (WebKit::WebPage::editorState):
1418         (WebKit::WebPage::scaledSnapshotWithOptions):
1419         (WebKit::WebPage::centerSelectionInVisibleArea):
1420         (WebKit::frameWithSelection):
1421         (WebKit::WebPage::clearSelection):
1422         (WebKit::WebPage::confirmComposition):
1423         (WebKit::WebPage::setComposition):
1424         (WebKit::WebPage::currentSelectionAsRange):
1425         * WebProcess/WebPage/mac/WebPageMac.mm:
1426         (WebKit::WebPage::setComposition):
1427         (WebKit::WebPage::insertText):
1428         (WebKit::WebPage::insertDictatedText):
1429         (WebKit::WebPage::getMarkedRange):
1430         (WebKit::WebPage::getSelectedRange):
1431         (WebKit::WebPage::getAttributedSubstringFromRange):
1432         (WebKit::WebPage::characterIndexForPoint):
1433         (WebKit::convertToRange):
1434         (WebKit::WebPage::performDictionaryLookupAtLocation):
1435         (WebKit::WebPage::readSelectionFromPasteboard):
1436         (WebKit::WebPage::getStringSelectionForPasteboard):
1437         (WebKit::WebPage::getDataSelectionForPasteboard):
1438
1439 2013-08-18  Darin Adler  <darin@apple.com>
1440
1441         <https://webkit.org/b/119989> Make use of Node::ownerDocument a compile time error
1442
1443         Reviewed by Sam Weinig.
1444
1445         * WebProcess/Plugins/PDF/PDFPluginChoiceAnnotation.mm:
1446         (WebKit::PDFPluginChoiceAnnotation::createAnnotationElement): Use document instead of
1447         ownerDocument.
1448         * WebProcess/Plugins/PDF/PDFPluginTextAnnotation.mm:
1449         (WebKit::PDFPluginTextAnnotation::createAnnotationElement): Ditto.
1450
1451 2013-08-18  Dan Bernstein  <mitz@apple.com>
1452
1453         Fix clean engineering builds after r154251.
1454
1455         * WebKit2.xcodeproj/project.pbxproj: Removed references to the OfflineStorage XPC services
1456         from the “Copy XPC services for engineering builds” build phase.
1457
1458 2013-08-18  Gavin Barraclough  <barraclough@apple.com>
1459
1460         https://bugs.webkit.org/show_bug.cgi?id=119972
1461         Add attributes field to PropertySlot
1462
1463         Reviewed by Geoff Garen.
1464
1465         For all JSC types, this makes getOwnPropertyDescriptor redundant.
1466         There will be a bit more hacking required in WebCore to remove GOPD whilst maintaining current behaviour.
1467         (Current behaviour is in many ways broken, particularly in that GOPD & GOPS are inconsistent, but we should fix incrementally).
1468
1469         * WebProcess/Plugins/Netscape/JSNPObject.cpp:
1470         (WebKit::JSNPObject::getOwnPropertySlot):
1471         (WebKit::JSNPObject::getOwnPropertyDescriptor):
1472             - Pass attributes to PropertySlot::set* methods.
1473
1474 2013-08-16  Sam Weinig  <sam@webkit.org>
1475
1476         <https://webkit.org/b/119911> Remove the unused OfflineStorageProcess
1477
1478         Reviewed by Darin Adler.
1479
1480         * Configurations/OfflineStorageProcess.xcconfig: Removed.
1481         * Configurations/OfflineStorageService.Development.xcconfig: Removed.
1482         * Configurations/OfflineStorageService.xcconfig: Removed.
1483         * DerivedSources.make:
1484         * OfflineStorageProcess: Removed.
1485         * OfflineStorageProcess/EntryPoint: Removed.
1486         * OfflineStorageProcess/EntryPoint/mac: Removed.
1487         * OfflineStorageProcess/EntryPoint/mac/LegacyProcess: Removed.
1488         * OfflineStorageProcess/EntryPoint/mac/LegacyProcess/Info.plist: Removed.
1489         * OfflineStorageProcess/EntryPoint/mac/LegacyProcess/OfflineStorageProcessMain.mm: Removed.
1490         * OfflineStorageProcess/EntryPoint/mac/XPCService: Removed.
1491         * OfflineStorageProcess/EntryPoint/mac/XPCService/OfflineStorageService: Removed.
1492         * OfflineStorageProcess/EntryPoint/mac/XPCService/OfflineStorageService.Development: Removed.
1493         * OfflineStorageProcess/EntryPoint/mac/XPCService/OfflineStorageService.Development/Info.plist: Removed.
1494         * OfflineStorageProcess/EntryPoint/mac/XPCService/OfflineStorageService/Info.plist: Removed.
1495         * OfflineStorageProcess/EntryPoint/mac/XPCService/OfflineStorageServiceEntryPoint.mm: Removed.
1496         * OfflineStorageProcess/OfflineStorageProcess.cpp: Removed.
1497         * OfflineStorageProcess/OfflineStorageProcess.h: Removed.
1498         * OfflineStorageProcess/OfflineStorageProcess.messages.in: Removed.
1499         * OfflineStorageProcess/mac: Removed.
1500         * OfflineStorageProcess/mac/OfflineStorageProcessMac.mm: Removed.
1501         * OfflineStorageProcess/mac/com.apple.WebKit.OfflineStorage.sb: Removed.
1502         * Scripts/webkit2/messages.py:
1503         * Shared/OfflineStorage: Removed.
1504         * Shared/OfflineStorage/OfflineStorageProcessCreationParameters.cpp: Removed.
1505         * Shared/OfflineStorage/OfflineStorageProcessCreationParameters.h: Removed.
1506         * WebKit2.xcodeproj/project.pbxproj:
1507         Remove.
1508
1509 2013-08-17  Darin Adler  <darin@apple.com>
1510
1511         <https://webkit.org/b/119941> Make Page::dragController return a reference
1512
1513         Reviewed by Andreas Kling.
1514
1515         * WebProcess/WebPage/WebPage.cpp:
1516         (WebKit::WebPage::performDragControllerAction):
1517         (WebKit::WebPage::dragEnded):
1518         Updated call sites.
1519
1520 2013-08-17  David Kilzer  <ddkilzer@apple.com>
1521
1522         WebKit2 fails to build with trunk clang: error: 'WebPluginSiteDataManagerh' is used as a header guard here, followed by #define of a different macro [-Werror,-Wheader-guard]
1523         <http://webkit.org/b/119935>
1524         <rdar://problem/14764131>
1525
1526         Reviewed by Darin Adler.
1527
1528         * UIProcess/Plugins/WebPluginSiteDataManager.h: Fix typo
1529         introduced in r78647.
1530
1531 2013-08-16  Pratik Solanki  <psolanki@apple.com>
1532
1533         <https://webkit.org/b/119852> Frame::scriptController() should return a reference
1534
1535         Reviewed by Andreas Kling.
1536
1537         m_script is never NULL so we can just return a reference. Also remove some pointless null
1538         checks as a result of doing this.
1539
1540         * WebProcess/Plugins/Netscape/NPRuntimeObjectMap.cpp:
1541         (WebKit::NPRuntimeObjectMap::globalObject):
1542         * WebProcess/Plugins/PluginView.cpp:
1543         (WebKit::PluginView::performJavaScriptURLRequest):
1544         (WebKit::PluginView::windowScriptNPObject):
1545         (WebKit::PluginView::pluginElementNPObject):
1546         * WebProcess/WebPage/WebFrame.cpp:
1547         (WebKit::WebFrame::jsContext):
1548         (WebKit::WebFrame::jsContextForWorld):
1549         (WebKit::WebFrame::jsWrapperForWorld):
1550         * WebProcess/WebPage/WebInspector.cpp:
1551         (WebKit::WebInspector::didSave):
1552         (WebKit::WebInspector::didAppend):
1553         * WebProcess/WebPage/WebPage.cpp:
1554         (WebKit::WebPage::runJavaScriptInMainFrame):
1555
1556 2013-08-16  Brady Eidson  <beidson@apple.com>
1557
1558         (NetworkProcess)  Sync XHRs should load using async ResourceHandles, not ResourceHandle::loadResourceSynchronously
1559         https://bugs.webkit.org/show_bug.cgi?id=119493
1560
1561         Reviewed by Alexey Proskuryakov.
1562
1563         This patch does the following:
1564           - Consolidates SchedulableLoader and NetworkResourceLoader into one class.
1565           - Removes SyncNetworkResourceLoader.
1566           - Adds a NetworkLoaderClient interface that customizes certain behaviors of the NetworkResourceLoader.
1567           - Implements a SynchronousNetworkLoaderClient and AsynchronousNetworkLoaderClient for the two different types of loads.
1568
1569         The AsynchronousNetworkLoaderClient results in messaging back progress to the WebProcess as the load progresses.
1570         The SynchronousNetworkLoaderClient accumulates the response, data, and error to be communicated back to the WebProcess
1571         only when the load is complete.
1572
1573         Update small swaths of code to reflect that NetworkResourceLoader is the One True Loader (tm):
1574         * NetworkProcess/HostRecord.cpp:
1575         (WebKit::HostRecord::scheduleResourceLoader):
1576         (WebKit::HostRecord::addLoaderInProgress):
1577         (WebKit::removeLoaderFromQueue):
1578         (WebKit::HostRecord::removeLoader):
1579         (WebKit::HostRecord::servePendingRequestsForQueue):
1580         (WebKit::HostRecord::limitsRequests):
1581         * NetworkProcess/HostRecord.h:
1582
1583         * NetworkProcess/NetworkConnectionToWebProcess.cpp:
1584         (WebKit::NetworkConnectionToWebProcess::didClose):
1585         (WebKit::NetworkConnectionToWebProcess::performSynchronousLoad):
1586         (WebKit::NetworkConnectionToWebProcess::removeLoadIdentifier):
1587         * NetworkProcess/NetworkConnectionToWebProcess.h:
1588
1589         * NetworkProcess/NetworkProcess.cpp:
1590         * NetworkProcess/NetworkResourceLoadScheduler.cpp:
1591         (WebKit::NetworkResourceLoadScheduler::scheduleLoader):
1592         (WebKit::NetworkResourceLoadScheduler::removeLoader):
1593         (WebKit::NetworkResourceLoadScheduler::receivedRedirect):
1594         (WebKit::NetworkResourceLoadScheduler::removeScheduledLoaders):
1595         (WebKit::NetworkResourceLoadScheduler::scheduleRemoveLoader):
1596         * NetworkProcess/NetworkResourceLoadScheduler.h:
1597
1598         Combine ScheduleableLoader and NetworkResourceLoader into NetworkResourceLoader:
1599         * NetworkProcess/NetworkResourceLoader.cpp:
1600         (WebKit::NetworkResourceLoader::NetworkResourceLoader):
1601         (WebKit::NetworkResourceLoader::~NetworkResourceLoader):
1602         (WebKit::NetworkResourceLoader::isSynchronous):
1603         (WebKit::NetworkResourceLoader::start):
1604         (WebKit::NetworkResourceLoader::didReceiveResponseAsync):
1605         (WebKit::NetworkResourceLoader::didReceiveBuffer):
1606         (WebKit::NetworkResourceLoader::didFinishLoading):
1607         (WebKit::NetworkResourceLoader::didFail):
1608         (WebKit::NetworkResourceLoader::willSendRequestAsync):
1609         (WebKit::NetworkResourceLoader::continueWillSendRequest):
1610         (WebKit::NetworkResourceLoader::didSendData):
1611         (WebKit::NetworkResourceLoader::shouldUseCredentialStorage):
1612         (WebKit::NetworkResourceLoader::didReceiveAuthenticationChallenge):
1613         (WebKit::NetworkResourceLoader::consumeSandboxExtensions):
1614         (WebKit::NetworkResourceLoader::invalidateSandboxExtensions):
1615         (WebKit::NetworkResourceLoader::canAuthenticateAgainstProtectionSpaceAsync):
1616         * NetworkProcess/NetworkResourceLoader.h:
1617         (WebKit::NetworkResourceLoader::create):
1618         (WebKit::NetworkResourceLoader::connectionToWebProcess):
1619         (WebKit::NetworkResourceLoader::priority):
1620         (WebKit::NetworkResourceLoader::request):
1621         (WebKit::NetworkResourceLoader::isLoadingMainResource):
1622         (WebKit::NetworkResourceLoader::setHostRecord):
1623         (WebKit::NetworkResourceLoader::hostRecord):
1624         (WebKit::NetworkResourceLoader::sendAbortingOnFailure):
1625
1626         Add an abstract NetworkLoaderClient to adapt a load to be either synchronous or asynchronous:
1627         * NetworkProcess/NetworkLoaderClient.h:
1628         (WebKit::NetworkLoaderClient::~NetworkLoaderClient):
1629         (WebKit::NetworkLoaderClient::isSynchronous):
1630         (WebKit::NetworkLoaderClient::NetworkLoaderClient):
1631
1632         The asynchronous loader client, primarily to message progress back to the WebProcess as it happens:
1633         * NetworkProcess/AsynchronousNetworkLoaderClient.cpp: Added.
1634         (WebKit::AsynchronousNetworkLoaderClient::AsynchronousNetworkLoaderClient):
1635         (WebKit::AsynchronousNetworkLoaderClient::willSendRequest):
1636         (WebKit::AsynchronousNetworkLoaderClient::canAuthenticateAgainstProtectionSpace):
1637         (WebKit::AsynchronousNetworkLoaderClient::didReceiveResponse):
1638         (WebKit::AsynchronousNetworkLoaderClient::didReceiveBuffer):
1639         (WebKit::AsynchronousNetworkLoaderClient::didSendData):
1640         (WebKit::AsynchronousNetworkLoaderClient::didFinishLoading):
1641         (WebKit::AsynchronousNetworkLoaderClient::didFail):
1642         * NetworkProcess/AsynchronousNetworkLoaderClient.h:
1643         (WebKit::AsynchronousNetworkLoaderClient::create):
1644
1645         The synchronous loader client, primarily to accumulate results of the load to send back to the WebProcess all at once:
1646         * NetworkProcess/SynchronousNetworkLoaderClient.cpp: Added.
1647         (WebKit::SynchronousNetworkLoaderClient::SynchronousNetworkLoaderClient):
1648         (WebKit::SynchronousNetworkLoaderClient::~SynchronousNetworkLoaderClient):
1649         (WebKit::SynchronousNetworkLoaderClient::willSendRequest):
1650         (WebKit::SynchronousNetworkLoaderClient::canAuthenticateAgainstProtectionSpace):
1651         (WebKit::SynchronousNetworkLoaderClient::didReceiveResponse):
1652         (WebKit::SynchronousNetworkLoaderClient::didReceiveBuffer):
1653         (WebKit::SynchronousNetworkLoaderClient::didFinishLoading):
1654         (WebKit::SynchronousNetworkLoaderClient::didFail):
1655         (WebKit::SynchronousNetworkLoaderClient::sendDelayedReply):
1656         * NetworkProcess/SynchronousNetworkLoaderClient.h: Added.
1657         (WebKit::SynchronousNetworkLoaderClient::create):
1658
1659         * NetworkProcess/SchedulableLoader.cpp: Removed.
1660         * NetworkProcess/SchedulableLoader.h: Removed.
1661         * NetworkProcess/SyncNetworkResourceLoader.cpp: Removed.
1662         * NetworkProcess/SyncNetworkResourceLoader.h: Removed.
1663
1664         * WebKit2.xcodeproj/project.pbxproj:
1665
1666 2013-08-16  Gabor Rapcsanyi  <rgabor@webkit.org>
1667
1668         [Qt][ARM] Unreviewed buildfix after 154127.
1669
1670         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.h: Add missing header.
1671
1672 2013-08-15  Ryuan Choi  <ryuan.choi@samsung.com>
1673
1674         [EFL] Unreviewed build fix after r154142 and r154144.
1675
1676         * UIProcess/WebContext.cpp:
1677         (WebKit::WebContext::useTestingNetworkSession):
1678         Fixed build break when NETWORK_PROCESS is disabled after r154144.
1679
1680 2013-08-15  Chris Fleizach  <cfleizach@apple.com>
1681
1682         <https://webkit.org/b/119858> AX: Crash: com.apple.WebKit.WebContent at com.apple.WebKit2: WebKit::WebPage::accessibilityObjectForMainFramePlugin + 8
1683
1684         Reviewed by Tim Horton.
1685
1686         Ensure that the page is available before accessing it.
1687
1688         * WebProcess/WebPage/mac/WebPageMac.mm:
1689         (WebKit::WebPage::accessibilityObjectForMainFramePlugin):
1690
1691 2013-08-15  Alexey Proskuryakov  <ap@apple.com>
1692
1693         [WK2] NetworkProcess should use a temporary storage session for test
1694         https://bugs.webkit.org/show_bug.cgi?id=119855
1695
1696         Reviewed by Darin Adler.
1697
1698         We used to have a bundle API for WebKitTestRunner to do this in injected bundle, but
1699         NetworkProcess has no injected bundle.
1700
1701         Added a WKContext API, sending the information to NetworkProcess with initialization
1702         parameters. Reworked WebProcess path to do the same for consistency - bundle API
1703         is better per se, but not when we also need to have another one.
1704
1705         * NetworkProcess/NetworkProcess.cpp:
1706         (WebKit::NetworkProcess::initializeNetworkProcess):
1707         * Shared/Network/NetworkProcessCreationParameters.cpp:
1708         (WebKit::NetworkProcessCreationParameters::encode):
1709         (WebKit::NetworkProcessCreationParameters::decode):
1710         * Shared/Network/NetworkProcessCreationParameters.h:
1711         * Shared/WebProcessCreationParameters.cpp:
1712         (WebKit::WebProcessCreationParameters::encode):
1713         (WebKit::WebProcessCreationParameters::decode):
1714         * Shared/WebProcessCreationParameters.h:
1715         * UIProcess/API/C/WKContext.cpp:
1716         (WKContextUseTestingNetworkSession):
1717         * UIProcess/API/C/WKContextPrivate.h:
1718         * UIProcess/WebContext.cpp:
1719         (WebKit::WebContext::WebContext):
1720         (WebKit::WebContext::ensureNetworkProcess):
1721         (WebKit::WebContext::createNewWebProcess):
1722         (WebKit::WebContext::useTestingNetworkSession):
1723         * UIProcess/WebContext.h:
1724         * WebProcess/InjectedBundle/API/c/WKBundle.cpp:
1725         * WebProcess/InjectedBundle/API/c/WKBundlePrivate.h:
1726         * WebProcess/InjectedBundle/InjectedBundle.cpp:
1727         * WebProcess/InjectedBundle/InjectedBundle.h:
1728         * WebProcess/WebProcess.cpp:
1729         (WebKit::WebProcess::initializeWebProcess):
1730
1731 2013-08-15  Anders Carlsson  <andersca@apple.com>
1732
1733         <https://webkit.org/b/119859> Frame::loader() should return a reference
1734
1735         Reviewed by Andreas Kling.
1736
1737         * Shared/WebRenderLayer.cpp:
1738         (WebKit::WebRenderLayer::create):
1739         * Shared/WebRenderObject.cpp:
1740         (WebKit::WebRenderObject::create):
1741         * WebProcess/Geolocation/GeolocationPermissionRequestManager.cpp:
1742         (WebKit::GeolocationPermissionRequestManager::startRequestForGeolocation):
1743         * WebProcess/InjectedBundle/API/c/WKBundleFrame.cpp:
1744         (WKBundleFrameGetFrameLoadState):
1745         (WKBundleFrameClearOpener):
1746         (WKBundleFrameCallShouldCloseOnWebView):
1747         * WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.cpp:
1748         (WebKit::InjectedBundleNodeHandle::documentFrame):
1749         (WebKit::InjectedBundleNodeHandle::htmlFrameElementContentFrame):
1750         (WebKit::InjectedBundleNodeHandle::htmlIFrameElementContentFrame):
1751         * WebProcess/InjectedBundle/InjectedBundle.cpp:
1752         (WebKit::InjectedBundle::overrideBoolPreferenceForTestRunner):
1753         * WebProcess/InjectedBundle/InjectedBundleDOMWindowExtension.cpp:
1754         (WebKit::InjectedBundleDOMWindowExtension::frame):
1755         * WebProcess/InjectedBundle/InjectedBundleHitTestResult.cpp:
1756         (WebKit::InjectedBundleHitTestResult::frame):
1757         (WebKit::InjectedBundleHitTestResult::targetFrame):
1758         * WebProcess/Plugins/PDF/PDFPlugin.mm:
1759         (WebKit::PDFPlugin::clickedLink):
1760         * WebProcess/Plugins/PluginView.cpp:
1761         (WebKit::webPage):
1762         (WebKit::PluginView::didFailToInitializePlugin):
1763         (WebKit::PluginView::performFrameLoadURLRequest):
1764         (WebKit::PluginView::userAgent):
1765         (WebKit::PluginView::loadURL):
1766         (WebKit::PluginView::cancelManualStreamLoad):
1767         (WebKit::PluginView::proxiesForURL):
1768         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
1769         (WebKit::WebChromeClient::focusedElementChanged):
1770         (WebKit::WebChromeClient::focusedFrameChanged):
1771         (WebKit::WebChromeClient::runBeforeUnloadConfirmPanel):
1772         (WebKit::WebChromeClient::closeWindowSoon):
1773         (WebKit::WebChromeClient::runJavaScriptAlert):
1774         (WebKit::WebChromeClient::runJavaScriptConfirm):
1775         (WebKit::WebChromeClient::runJavaScriptPrompt):
1776         (WebKit::WebChromeClient::unavailablePluginButtonClicked):
1777         (WebKit::WebChromeClient::print):
1778         (WebKit::WebChromeClient::exceededDatabaseQuota):
1779         (WebKit::WebChromeClient::runOpenPanel):
1780         * WebProcess/WebCoreSupport/WebContextMenuClient.cpp:
1781         (WebKit::WebContextMenuClient::searchWithGoogle):
1782         * WebProcess/WebCoreSupport/WebEditorClient.cpp:
1783         (WebKit::WebEditorClient::textFieldDidBeginEditing):
1784         (WebKit::WebEditorClient::textFieldDidEndEditing):
1785         (WebKit::WebEditorClient::textDidChangeInTextField):
1786         (WebKit::WebEditorClient::textDidChangeInTextArea):
1787         (WebKit::WebEditorClient::doTextFieldCommandFromEvent):
1788         (WebKit::WebEditorClient::textWillBeDeletedInTextField):
1789         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
1790         (WebKit::WebFrameLoaderClient::dispatchDidReceiveServerRedirectForProvisionalLoad):
1791         (WebKit::WebFrameLoaderClient::dispatchDidStartProvisionalLoad):
1792         (WebKit::WebFrameLoaderClient::dispatchDidCommitLoad):
1793         (WebKit::WebFrameLoaderClient::dispatchDecidePolicyForResponse):
1794         (WebKit::WebFrameLoaderClient::dispatchDecidePolicyForNewWindowAction):
1795         (WebKit::WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
1796         (WebKit::WebFrameLoaderClient::dispatchWillSendSubmitEvent):
1797         (WebKit::WebFrameLoaderClient::dispatchWillSubmitForm):
1798         (WebKit::WebFrameLoaderClient::updateGlobalHistory):
1799         (WebKit::WebFrameLoaderClient::updateGlobalHistoryRedirectLinks):
1800         (WebKit::WebFrameLoaderClient::restoreViewState):
1801         (WebKit::WebFrameLoaderClient::createFrame):
1802         (WebKit::WebFrameLoaderClient::createJavaAppletWidget):
1803         (WebKit::WebFrameLoaderClient::objectContentType):
1804         * WebProcess/WebCoreSupport/WebPlatformStrategies.cpp:
1805         (WebKit::WebPlatformStrategies::getPluginInfo):
1806         * WebProcess/WebCoreSupport/mac/WebFrameNetworkingContext.mm:
1807         (WebKit::WebFrameNetworkingContext::blockedError):
1808         * WebProcess/WebPage/WebFrame.cpp:
1809         (WebKit::WebFrame::didReceivePolicyDecision):
1810         (WebKit::WebFrame::startDownload):
1811         (WebKit::WebFrame::source):
1812         (WebKit::WebFrame::contentsAsString):
1813         (WebKit::WebFrame::url):
1814         (WebKit::WebFrame::parentFrame):
1815         (WebKit::WebFrame::childFrames):
1816         (WebKit::WebFrame::stopLoading):
1817         (WebKit::WebFrame::frameForContext):
1818         (WebKit::WebFrame::provisionalURL):
1819         (WebKit::WebFrame::suggestedFilenameForResourceWithURL):
1820         (WebKit::WebFrame::mimeTypeForResourceWithURL):
1821         (WebKit::WebFrameFilter::shouldIncludeSubframe):
1822         * WebProcess/WebPage/WebPage.cpp:
1823         (WebKit::WebPage::createPlugin):
1824         (WebKit::WebPage::close):
1825         (WebKit::WebPage::tryClose):
1826         (WebKit::WebPage::loadURLRequest):
1827         (WebKit::WebPage::loadDataImpl):
1828         (WebKit::WebPage::linkClicked):
1829         (WebKit::WebPage::stopLoadingFrame):
1830         (WebKit::WebPage::stopLoading):
1831         (WebKit::WebPage::reload):
1832         (WebKit::WebPage::tryRestoreScrollPosition):
1833         (WebKit::WebPage::getMainResourceDataOfFrame):
1834         (WebKit::resourceDataForFrame):
1835         (WebKit::shouldReuseCommittedSandboxExtension):
1836         (WebKit::WebPage::SandboxExtensionTracker::didStartProvisionalLoad):
1837         (WebKit::WebPage::hasLocalDataForURL):
1838         (WebKit::WebPage::setCustomTextEncodingName):
1839         (WebKit::WebPage::canPluginHandleResponse):
1840         (WebKit::WebPage::canShowMIMEType):
1841         (WebKit::WebPage::didCommitLoad):
1842         * WebProcess/WebPage/mac/WebPageMac.mm:
1843         (WebKit::WebPage::platformHasLocalDataForURL):
1844         (WebKit::cachedResponseForURL):
1845         * WebProcess/WebProcess.cpp:
1846         (WebKit::WebProcess::downloadRequest):
1847
1848 2013-08-14  Filip Pizlo  <fpizlo@apple.com>
1849
1850         Typed arrays should be rewritten
1851         https://bugs.webkit.org/show_bug.cgi?id=119064
1852
1853         Reviewed by Oliver Hunt.
1854         
1855         You don't need to include JSUint8Array anymore if you just want to
1856         unwrap one; JSDOMBinding gives you all of the things you need.
1857
1858         * WebProcess/InjectedBundle/InjectedBundle.cpp:
1859
1860 2013-08-15  Eric Carlson  <eric.carlson@apple.com>
1861
1862         [Mac] Remove "legacy" media UI
1863         https://bugs.webkit.org/show_bug.cgi?id=119752
1864
1865         Reviewed by Jer Noble.
1866
1867         * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
1868         (InitWebCoreSystemInterface): Remove MediaControllerThemeAvailable.
1869
1870 2013-08-14  Dean Jackson  <dino@apple.com>
1871
1872         <https://webkit.org/b/119827> Allow primary plug-in detection to run more than once if necessary
1873
1874         Reviewed by Tim Horton.
1875
1876         We occasionally see cases where the primary plug-in detection runs before the plugins have been added
1877         to the page, especially if they do so in response to a load event. Tweak the algorithm so that it can
1878         run an arbitrary number of times if it fails.
1879
1880         While here, also have the detection run if there has ever been a plugin in the page as opposed to any
1881         current views. We may have snapshotted a plugin by now and deleted its view.
1882
1883         * WebProcess/WebPage/WebPage.cpp:
1884         (WebKit::WebPage::WebPage): initialise new members.
1885         (WebKit::WebPage::addPluginView): Mark that we've seen a plugin.
1886         (WebKit::WebPage::resetPrimarySnapshottedPlugIn): Reset new members.
1887         (WebKit::WebPage::determinePrimarySnapshottedPlugIn): Exit early if we've never
1888         seen a plugin, rather than if we don't have any active views. Also, if we didn't find anything set
1889         a timer to run again (maximum of two attempts at the moment).
1890         * WebProcess/WebPage/WebPage.h: New members - m_numberOfPrimarySnapshotDetectionAttempts
1891         and m_hasSeenPlugin.
1892
1893 2013-08-14  Dean Jackson  <dino@apple.com>
1894
1895         <https://webkit.org/b/119820> Add pluginView-related logging to WebPage
1896
1897         Reviewed by Tim Horton.
1898
1899         Add some more diagnostic output to help track down bugs.
1900
1901         * WebProcess/WebPage/WebPage.cpp:
1902         (WebKit::WebPage::addPluginView): More logging.
1903         (WebKit::WebPage::removePluginView): Ditto.
1904
1905 2013-08-14  Alexey Proskuryakov  <ap@apple.com>
1906
1907         [WK2] Sync messages with with non-default timeout sent from secondary threads always time out
1908         https://bugs.webkit.org/show_bug.cgi?id=119767
1909
1910         Fix by Justin Bur.
1911         Reviewed by Darin Adler.
1912
1913         * Platform/CoreIPC/Connection.cpp: (CoreIPC::Connection::sendSyncMessageFromSecondaryThread):
1914         The argument to wait() is absolute time, not a delta. This calculation matches one
1915         in Connection::waitForMessage().
1916
1917 2013-08-14  Tim Horton  <timothy_horton@apple.com>
1918
1919         REGRESSION (r153877): Plugin scanning slows creation of WebViews
1920         https://bugs.webkit.org/show_bug.cgi?id=119665
1921         <rdar://problem/14716549>
1922
1923         Reviewed by Darin Adler.
1924
1925         * WebProcess/WebCoreSupport/WebPlatformStrategies.cpp:
1926         (WebKit::WebPlatformStrategies::refreshPlugins):
1927         Don't repopulate the plugin cache in refreshPlugins, just invalidate it.
1928         It will be repopulated the next time something tries to use it.
1929
1930 2013-08-12  Dan Bernstein  <mitz@apple.com>
1931
1932         Fixed an off-by-(sizeof(char*) - 1) bug.
1933
1934         Reviewed by Sam Weinig.
1935
1936         * Shared/EntryPointUtilities/mac/XPCService/XPCServiceMain.Development.mm:
1937         (WebKit::XPCServiceEventHandler): Allocate a sufficiently large buffer.
1938
1939 2013-08-12  Beth Dakin  <bdakin@apple.com>
1940
1941         Remove didNewFirstVisuallyNonEmptyLayout from WebKit2
1942         https://bugs.webkit.org/show_bug.cgi?id=119658
1943
1944         Reviewed by Darin Adler.
1945
1946         Removing this function entirely will change some functionality in the Nightlies, 
1947         but we think that is an acceptable difference for the Nightlies. If is does cause 
1948         a problem though, we can roll out this patch and deprecate the function instead.
1949
1950         * UIProcess/API/C/WKPage.h:
1951         * UIProcess/WebLoaderClient.cpp:
1952         * UIProcess/WebLoaderClient.h:
1953         * UIProcess/WebPageProxy.cpp:
1954         (WebKit::WebPageProxy::initializeLoaderClient):
1955         * UIProcess/WebPageProxy.h:
1956         * UIProcess/WebPageProxy.messages.in:
1957         * WebProcess/InjectedBundle/API/c/WKBundlePage.h:
1958         * WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.cpp:
1959         * WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.h:
1960         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
1961         (WebKit::WebFrameLoaderClient::dispatchDidLayout):
1962         * WebProcess/WebPage/WebPage.cpp:
1963         (WebKit::WebPage::initializeInjectedBundleLoaderClient):
1964
1965 2013-08-12  Arunprasad Rajkumar  <arurajku@cisco.com>
1966
1967         [Qt] [WebKit2] Remove duplicate RAM Size calculation and reuse WTF::ramSize()
1968         https://bugs.webkit.org/show_bug.cgi?id=119663
1969
1970         Reviewed by Sam Weinig.
1971
1972         * WebProcess/qt/WebProcessQt.cpp:
1973         (WebKit::WebProcess::platformSetCacheModel):
1974
1975 2013-08-12  Anton Obzhirov  <a.obzhirov@samsung.com>
1976
1977         [GTK] Don't load GAIL when using GTK 3.2 or greater
1978         https://bugs.webkit.org/show_bug.cgi?id=72735
1979
1980         Reviewed by Carlos Garcia Campos.
1981
1982         * UIProcess/API/gtk/tests/AccessibilityTestServer.cpp:
1983         (main):
1984
1985 2013-08-09  Beth Dakin  <bdakin@apple.com>
1986
1987         AX: Not able to use arrow keys to read text in a WK2 app
1988         https://bugs.webkit.org/show_bug.cgi?id=119605
1989         -and corresponding-
1990         <rdar://problem/14281275>
1991
1992         Reviewed by Darin Adler.
1993
1994         Make all of these scrolling functions actually return the WebCore bools that 
1995         indicate whether or not scrolling happened. 
1996         * WebProcess/WebPage/WebPage.cpp:
1997         (WebKit::WebPage::scroll):
1998         (WebKit::WebPage::logicalScroll):
1999         (WebKit::WebPage::scrollBy):
2000         * WebProcess/WebPage/WebPage.h:
2001         * WebProcess/WebPage/mac/WebPageMac.mm:
2002         (WebKit::WebPage::executeKeypressCommandsInternal):
2003
2004         This function now gives accessibility a chance to handle the event too. And it 
2005         also actually tracks whether or not the event was handled by scrolling instead of 
2006         assuming that it was and universally returning true.
2007         (WebKit::WebPage::performNonEditingBehaviorForSelector):
2008
2009 2013-08-09  Brian Holt  <brian.holt@samsung.com>
2010
2011         [GTK] [WebKit2] Add an 'authenticate' signal to WebKitWebView
2012         https://bugs.webkit.org/show_bug.cgi?id=99352
2013
2014         Reviewed by Carlos Garcia Campos.
2015
2016         Add a new public class to the API, WebKitAuthenticationRequest, to be
2017         emitted along with a new WebKitWebView::authenticate signal to
2018         let client applications to provide their own authentication
2019         when the user is challenged with HTTP authentication. The
2020         credential is exposed through a new class WebKitCredential.
2021
2022         * GNUmakefile.list.am:
2023         * UIProcess/API/gtk/WebKitAuthenticationDialog.cpp:
2024         (okButtonClicked): Use new API for authentication.
2025         (cancelButtonClicked): Ditto.
2026         (webkitAuthenticationDialogInitialize):Get
2027         authenticationChallenge from request object.
2028         (webkitAuthenticationDialogNew): Ditto.
2029         * UIProcess/API/gtk/WebKitAuthenticationDialog.h:
2030         * UIProcess/API/gtk/WebKitAuthenticationRequest.cpp: Added new
2031         class representing a HTTP authentication request.
2032         (webkitAuthenticationRequestDispose):
2033         (webkit_authentication_request_class_init):
2034         (webkitAuthenticationRequestCreate):
2035         (webkitAuthenticationRequestGetAuthenticationChallenge):
2036         (webkit_authentication_request_can_save_credentials):
2037         (webkit_authentication_request_get_proposed_credential):
2038         (webkit_authentication_request_get_host):
2039         (webkit_authentication_request_get_port):
2040         (webkit_authentication_request_get_realm):
2041         (webkit_authentication_request_get_scheme):
2042         (webkit_authentication_request_is_for_proxy):
2043         (webkit_authentication_request_is_retry):
2044         (webkit_authentication_request_authenticate):
2045         (webkit_authentication_request_cancel):
2046         * UIProcess/API/gtk/WebKitAuthenticationRequest.h: Added.
2047         * UIProcess/API/gtk/WebKitAuthenticationRequestPrivate.h: Added.
2048         * UIProcess/API/gtk/WebKitCredential.cpp: Added new class to
2049         support credentials for HTTP authentication.
2050         (_WebKitCredential::_WebKitCredential):
2051         (webkitCredentialCreate):
2052         (webkitCredentialGetCredential):
2053         (webkit_credential_new):
2054         (webkit_credential_copy):
2055         (webkit_credential_free):
2056         (webkit_credential_get_username):
2057         (webkit_credential_get_password):
2058         (webkit_credential_has_password):
2059         (webkit_credential_get_persistence):
2060         * UIProcess/API/gtk/WebKitCredential.h: Added.
2061         * UIProcess/API/gtk/WebKitCredentialPrivate.h: Added.
2062         * UIProcess/API/gtk/WebKitWebView.cpp: Added authenticate signal.
2063         (webkitWebViewAuthenticate): Default signal handler for authenticate.
2064         (webkit_web_view_class_init): Ditto.
2065         (webkitWebViewHandleAuthenticationChallenge): Create an
2066         authentication request and emit it with authenticate signal.
2067         * UIProcess/API/gtk/WebKitWebView.h: Replaced reserved function
2068         pointer slot with for WebViewClass with function pointer to
2069         authenticate signal handler.
2070         * UIProcess/API/gtk/docs/webkit2gtk-docs.sgml: Added new section for
2071         the authentication request.
2072         * UIProcess/API/gtk/docs/webkit2gtk-sections.txt: Ditto.
2073         * UIProcess/API/gtk/docs/webkit2gtk.types: Added authentication
2074         request and credential types.
2075         * UIProcess/API/gtk/tests/TestWebKitWebView.cpp: Created a new
2076         unit test for HTTP authentication. A libsoup server callback
2077         handler is installed that creates soup messages with appropriate
2078         headers and body to test HTTP authentication.
2079         (testWebViewAuthenticationRequest): Test the authentication
2080         request and credential API.
2081         (testWebViewAuthenticationCancel): Test cancelled authentication.
2082         (testWebViewAuthenticationFailure): Test repeated authentication failures.
2083         (testWebViewAuthenticationNoCredential): Test continue without
2084         credentials.
2085         (testWebViewAuthenticationStorage): Test credential storage.
2086         (testWebViewAuthenticationSuccess): Test successful authentication.
2087         (beforeAll): Added tests.
2088         * UIProcess/API/gtk/webkit2.h: Added WebKitAuthenticationRequest and
2089         WebKitCredential headers.
2090
2091 2013-08-09  Tim Horton  <timothy_horton@apple.com>
2092
2093         PDFPlugin is disabled by default in nightlies on Mac accidentally
2094         https://bugs.webkit.org/show_bug.cgi?id=119615
2095
2096         Rubber-stamped by Andreas Kling.
2097
2098         Enable PDFPlugin by default on Mac at the WebKit2 level.
2099
2100         * Shared/WebPreferencesStore.h:
2101         * UIProcess/API/C/WKPreferencesPrivate.h:
2102
2103 2013-08-08  Tim Horton  <timothy_horton@apple.com>
2104
2105         navigator.plugins has plugins in it when plugins are disabled
2106         https://bugs.webkit.org/show_bug.cgi?id=119607
2107         <rdar://problem/14678030>
2108
2109         Reviewed by Anders Carlsson.
2110
2111         * UIProcess/WebProcessProxy.cpp:
2112         (WebKit::WebProcessProxy::getPlugins):
2113         Return a list of all plugins, and a list of only application plugins.
2114
2115         * UIProcess/WebProcessProxy.h:
2116         * UIProcess/WebProcessProxy.messages.in:
2117         * WebProcess/WebCoreSupport/WebPlatformStrategies.h:
2118         * WebProcess/WebCoreSupport/WebPlatformStrategies.cpp:
2119         (WebKit::WebPlatformStrategies::getPluginInfo):
2120         Add applicationPlugin parameter to getPlugins, and storage for the returned list.
2121
2122         (WebKit::WebPlatformStrategies::populatePluginCache):
2123         If plugins are disabled for the given page, give WebCore the list that
2124         only includes application plugins. Otherwise, give it the whole list
2125         as we are doing currently.
2126
2127 2013-08-08  Gavin Barraclough  <barraclough@apple.com>
2128
2129         Disable suppression of plugin process for Java
2130         https://bugs.webkit.org/show_bug.cgi?id=119604
2131
2132         Reviewed by Sam Weinig.
2133
2134         Workaround, the Java plugin doesn't like this.
2135
2136         * PluginProcess/mac/PluginProcessMac.mm:
2137         (WebKit::PluginProcess::platformInitializeProcess):
2138             - +1 active task count on the java plugin, to inhibit supression.
2139
2140 2013-08-08  Dean Jackson  <dino@apple.com>
2141
2142         Add logging to the primary plugin detection
2143         https://bugs.webkit.org/show_bug.cgi?id=119594
2144
2145         Reviewed by Tim Horton.
2146
2147         Add some simple logging to our primary plug-in detection.
2148
2149         * WebProcess/WebPage/WebPage.cpp:
2150         (WebKit::WebPage::determinePrimarySnapshottedPlugIn):
2151
2152 2013-08-08  Alexey Proskuryakov  <ap@apple.com>
2153
2154         WKBundleFrameCopyProvisionalURL crashes when there is no provisional loader
2155         https://bugs.webkit.org/show_bug.cgi?id=119587
2156
2157         Reviewed by Darin Adler.
2158
2159         * WebProcess/WebPage/WebFrame.cpp: (WebKit::WebFrame::provisionalURL): Added a null
2160         check, like we already have in WebFrame::url().
2161
2162 2013-08-07  Antti Koivisto  <antti@apple.com>
2163
2164         Try to fix EFL build.
2165         
2166         Not reviewed.
2167
2168         * CMakeLists.txt:
2169
2170 2013-08-06  Jer Noble  <jer.noble@apple.com>
2171
2172         Crash when entering fullscreen video playback from a WebView using WebKit2
2173         https://bugs.webkit.org/show_bug.cgi?id=119531
2174
2175         Reviewed by Tim Horton.
2176
2177         Initialize wkWindowSetScaledFrame and wkWindowSetAlpha when initializing WebCoreSystemInterface.
2178
2179         * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
2180         (InitWebCoreSystemInterface):
2181
2182 2013-08-06  Stephanie Lewis  <slewis@apple.com>
2183
2184         Update Order Files for Safari
2185         <rdar://problem/14517392>
2186
2187         Unreviewed.
2188
2189         * mac/WebKit2.order:
2190
2191 2013-08-04  Sam Weinig  <sam@webkit.org>
2192
2193         Remove support for HTML5 MicroData
2194         https://bugs.webkit.org/show_bug.cgi?id=119480
2195
2196         Reviewed by Anders Carlsson.
2197
2198         * Configurations/FeatureDefines.xcconfig:
2199
2200 2013-08-06  Eunmi Lee  <eunmi15.lee@samsung.com>
2201
2202         [EFL][WK2] Implement gesture recognizer.
2203         https://bugs.webkit.org/show_bug.cgi?id=102643
2204
2205         Reviewed by Gyuyoung Kim.
2206
2207         Recognize tap, pan and pinch gestures using touch events.
2208         The tap gesture is separated into single tap, double tap and
2209         'tap and hold'.
2210
2211         This patch references the webkit NIX port.
2212         https://github.com/WebKitNix/webkitnix
2213
2214         * PlatformEfl.cmake:
2215         * UIProcess/API/efl/EwkView.cpp:
2216         (EwkView::EwkView):
2217         (EwkView::doneWithTouchEvent):
2218         * UIProcess/API/efl/EwkView.h:
2219         * UIProcess/API/efl/GestureRecognizer.cpp: Added.
2220         (WebKit::GestureHandler::create):
2221         (WebKit::GestureHandler::GestureHandler):
2222         (WebKit::GestureHandler::handleSingleTap):
2223         (WebKit::GestureHandler::handleDoubleTap):
2224         (WebKit::GestureHandler::handleTapAndHold):
2225         (WebKit::GestureHandler::handlePanStarted):
2226         (WebKit::GestureHandler::handlePan):
2227         (WebKit::GestureHandler::handlePanFinished):
2228         (WebKit::GestureHandler::handlePinchStarted):
2229         (WebKit::GestureHandler::handlePinch):
2230         (WebKit::GestureHandler::handlePinchFinished):
2231         (WebKit::GestureRecognizer::GestureRecognizer):
2232         (WebKit::GestureRecognizer::~GestureRecognizer):
2233         (WebKit::GestureRecognizer::processTouchEvent):
2234         (WebKit::GestureRecognizer::doubleTapTimerCallback):
2235         (WebKit::GestureRecognizer::tapAndHoldTimerCallback):
2236         (WebKit::GestureRecognizer::exceedsPanThreshold):
2237         (WebKit::GestureRecognizer::exceedsDoubleTapThreshold):
2238         (WebKit::getPointAtIndex):
2239         (WebKit::createVectorWithWKArray):
2240         (WebKit::GestureRecognizer::noGesture):
2241         (WebKit::GestureRecognizer::singleTapGesture):
2242         (WebKit::GestureRecognizer::doubleTapGesture):
2243         (WebKit::GestureRecognizer::panGesture):
2244         (WebKit::GestureRecognizer::pinchGesture):
2245         (WebKit::GestureRecognizer::reset):
2246         (WebKit::GestureRecognizer::stopTapTimers):
2247         * UIProcess/API/efl/GestureRecognizer.h: Added.
2248         (WebKit::GestureRecognizer::create):
2249
2250 2013-07-23  David Farler  <dfarler@apple.com>
2251
2252         Provide optional OTHER_CFLAGS, OTHER_CPPFLAGS, OTHER_LDFLAGS additions for building with ASAN
2253         https://bugs.webkit.org/show_bug.cgi?id=117762
2254
2255         Reviewed by Mark Rowe.
2256
2257         * Configurations/DebugRelease.xcconfig:
2258         Add ASAN_OTHER_CFLAGS, CPLUSPLUSFLAGS, LDFLAGS.
2259         * Configurations/WebContentProcess.xcconfig:
2260         Add ASAN_OTHER_LDFLAGS.
2261         * Configurations/WebKit2.xcconfig:
2262         Add ASAN_OTHER_LDFLAGS.
2263
2264 2013-08-06  Andreas Kling  <akling@apple.com>
2265
2266         REGRESSION(r151403): Resizing is extremely laggy on many sites when plugins are disallowed.
2267         <http://webkit.org/b/119516>
2268         <rdar://problem/14648086>
2269
2270         Reviewed by Simon Fraser.
2271
2272         The web process relies on the WindowAndViewFramesChanged mechanism for caching a copy
2273         of the window rect for fast access from DOMWindow APIs.
2274
2275         We retain part of the optimization introduced in r151403, namely not computing the
2276         viewFrameInWindowCoordinates and accessibilityPosition unless the web process needs them.
2277
2278         * UIProcess/API/mac/WKView.mm:
2279         (-[WKView _updateWindowAndViewFrames]):
2280
2281 2013-07-26  Mark Rowe  <mrowe@apple.com>
2282
2283         Logging should be configurable using human-readable channel names rather than crazy bitmasks
2284         <http://webkit.org/b/119031>
2285
2286         Implement shared logic for initializing logging channels based on human-readable channel names in WTF,
2287         and rework the WebCore, WebKit and WebKit2 logging initialization on top of it.
2288
2289         Logging channels may now be enabled by providing a comma-separated list of channel names, with the special
2290         "all" name enabling all channels. Channel names prefixed with a leading "-" will result in the named channel
2291         being disabled. For instance, specifying "all,-history,-loading" will result in all logging channels except
2292         for history and loading being enabled.
2293
2294         For OS X developers, this also changes the name of the user defaults used to enable logging. This is done to allow
2295         the old user defaults to remain set for those people that need to switch between version of WebKit before and
2296         after this change. Where the old user default keys were WebCoreLogLevel, WebKitLogLevel and WebKit2LogLevel,
2297         the new user default keys are WebCoreLogging, WebKitLogging and WebKit2Logging.
2298
2299         For GTK developers, this changes the separator used in the WEBKIT_DEBUG environment variable to a comma for
2300         consistency with the other platforms and to enable more code sharing.
2301
2302         While doing this work I've also taken the opportunity to eliminate the need to touch multiple files when
2303         adding a new logging channel. Now only the header in the relevant project needs to be updated.
2304
2305         Reviewed by Sam Weinig.
2306
2307         * NetworkProcess/NetworkProcess.cpp: Switch from WebCore's InitializeLogging.h to Logging.h.
2308         * Platform/Logging.cpp: Use WEBKIT2_LOG_CHANNELS to define all of the channels.
2309         (WebKit::initializeLogChannelsIfNecessary): Pass the channels and the log level string to the new WTF function
2310         that handles the initialization.
2311         (WebKit::logChannelByName): Renamed to match our naming conventions. Calls through to the new WTF function
2312         to find a log channel rather than repeating the names of the log channels a further two times each.
2313         (WebKit::logLevelString): Provide a no-op implementation.
2314         * Platform/Logging.h: Declare a WEBKIT2_LOG_CHANNELS macro that can be used to apply a preprocessor macro
2315         across the set of all logging channels. Use this macro to declare the logging channels.
2316         * Platform/efl/LoggingEfl.cpp:
2317         (WebKit::logLevelString): Pull the value out of the WEBKIT_DEBUG environment variable.
2318         * Platform/gtk/LoggingGtk.cpp:
2319         (WebKit::logLevelString): Ditto.
2320         * Platform/mac/Logging.mac.mm:
2321         (WebKit::logLevelString): Pull the value out of the WebKit2Logging user default key.
2322         * Platform/qt/LoggingQt.cpp:
2323         (WebKit::logLevelString): Pull the value out of the QT_WEBKIT_LOG environment variable.
2324         * Shared/WebKit2Initialize.cpp: Switch from WebCore's InitializeLogging.h to Logging.h.
2325         * UIProcess/WebContext.cpp: Switch from WebCore's InitializeLogging.h to Logging.h.
2326
2327 2013-08-05  Anders Carlsson  <andersca@apple.com>
2328
2329         Ignore the Apple Java placeholder plug-in
2330         https://bugs.webkit.org/show_bug.cgi?id=119494
2331         <rdar://problem/14610818>
2332
2333         Reviewed by Beth Dakin.
2334
2335         Never attempt to load the Java placeholder plug-in.
2336
2337         * UIProcess/Plugins/mac/PluginInfoStoreMac.mm:
2338         (WebKit::PluginInfoStore::shouldUsePlugin):
2339
2340 2013-08-03  Tim Horton  <timothy_horton@apple.com>
2341
2342         Unreviewed, build and style fix for r153693.
2343
2344         * UIProcess/WebProcessProxy.cpp:
2345         * WebProcess/Plugins/PDF/PDFPlugin.h:
2346         * WebProcess/WebPage/WebPage.cpp:
2347
2348 2013-08-03  Tim Horton  <timothy_horton@apple.com>
2349
2350         Remove SimplePDFPlugin
2351         https://bugs.webkit.org/show_bug.cgi?id=119437
2352
2353         Reviewed by Alexey Proskuryakov.
2354
2355         * UIProcess/WebProcessProxy.cpp:
2356         (WebKit::WebProcessProxy::getPlugins):
2357         * WebProcess/WebPage/WebPage.cpp:
2358         (WebKit::WebPage::createPlugin):
2359         Don't add SimplePDFPlugin, nor try to instantiate it.
2360
2361         * WebProcess/Plugins/PDF/PDFPlugin.h:
2362         * WebProcess/Plugins/PDF/PDFPlugin.mm:
2363         Merge previously inherited behavior in from SimplePDFPlugin.
2364
2365         * WebKit2.xcodeproj/project.pbxproj:
2366         * WebProcess/Plugins/PDF/SimplePDFPlugin.h: Removed.
2367         * WebProcess/Plugins/PDF/SimplePDFPlugin.mm: Removed.
2368         Remove SimplePDFPlugin.
2369
2370 2013-08-03  Tim Horton  <timothy_horton@apple.com>
2371
2372         Remove pageOverlayShouldApplyFadeWhenPainting() and adopt composited fade for the Mac port
2373         https://bugs.webkit.org/show_bug.cgi?id=119411
2374
2375         Reviewed by Simon Fraser.
2376
2377         Mac is the only holdout that performs non-composited fades of page
2378         overlays. We should adopt that mechanism (as a precursor to doing a
2379         CA-accelerated fade) and remove the now-unnecessary property.
2380
2381         * WebProcess/InjectedBundle/API/c/WKBundlePageOverlay.cpp:
2382         (WKBundlePageOverlayFractionFadedIn):
2383         Always return 1 (fully-faded-in) so that clients who attempt to use this
2384         to bake the fade opacity into their painting will paint at full opacity,
2385         allowing us to do the composited fade separately.
2386
2387         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.h:
2388         * WebProcess/WebPage/DrawingArea.h:
2389         * WebProcess/WebPage/DrawingAreaImpl.cpp:
2390         * WebProcess/WebPage/DrawingAreaImpl.h:
2391         * WebProcess/WebPage/LayerTreeHost.h:
2392         * WebProcess/WebPage/PageOverlay.cpp:
2393         (WebKit::PageOverlay::PageOverlay):
2394         (WebKit::PageOverlay::setPage):
2395         (WebKit::PageOverlay::setNeedsDisplay):
2396         (WebKit::PageOverlay::fadeAnimationTimerFired):
2397         * WebProcess/WebPage/PageOverlay.h:
2398         Remove pageOverlayShouldApplyFadeWhenPainting and fractionFadedIn().
2399
2400         * WebProcess/WebPage/FindController.cpp:
2401         (WebKit::FindController::drawRect):
2402         Draw the find overlay without taking the PageOverlay's fade into account.
2403
2404         * WebProcess/WebPage/TapHighlightController.cpp:
2405         (WebKit::TapHighlightController::drawRect):
2406         Remove pageOverlayShouldApplyFadeWhenPainting. Since it's always
2407         "false" for all ports now, take the second path here.
2408
2409         * WebProcess/WebPage/mac/LayerTreeHostMac.h:
2410         * WebProcess/WebPage/mac/LayerTreeHostMac.mm:
2411         (WebKit::LayerTreeHostMac::setPageOverlayOpacity):
2412         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.h:
2413         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
2414         (WebKit::TiledCoreAnimationDrawingArea::setPageOverlayOpacity):
2415         Implement setPageOverlayOpacity for DrawingAreaImpl
2416         and TiledCoreAnimationDrawingArea.
2417
2418 2013-08-02  Gavin Barraclough  <barraclough@apple.com>
2419
2420         Remove no-arguments constructor to PropertySlot
2421         https://bugs.webkit.org/show_bug.cgi?id=119460
2422
2423         Reviewed by Geoff Garen.
2424
2425         This constructor was unsafe if getValue is subsequently called,
2426         and the property is a getter. Simplest to just remove it.
2427
2428         * WebProcess/Plugins/Netscape/JSNPObject.cpp:
2429         (WebKit::JSNPObject::getOwnPropertyDescriptor):
2430
2431 2013-08-02  Ruth Fong  <ruth_fong@apple.com>
2432
2433         [Forms: color] WebColorPickerMac deconstructor shouldn't assert a variable
2434         <rdar://problem/14627633> and https://bugs.webkit.org/show_bug.cgi?id=119419
2435
2436         Reviewed by Tim Horton.
2437
2438         * UIProcess/mac/WebColorPickerMac.mm:
2439         (WebKit::WebColorPickerMac::~WebColorPickerMac): If the m_colorPickerUI variable
2440           is not null, then properly destroy it first before destroying WebColorPickerMac object.
2441
2442 2013-08-02  Ruth Fong  <ruth_fong@apple.com>
2443
2444         [Forms: color] The positioning of the popover color well is inverted
2445         <rdar://problem/14635621> and https://bugs.webkit.org/show_bug.cgi?id=119455
2446
2447         Reviewed by Tim Horton.
2448
2449         This patch converts the coordinates of the <input type='color'> element to
2450         the window's base coordinate system.
2451
2452         * UIProcess/mac/WebColorPickerMac.mm:
2453         (-[WKColorPopoverMac initWithFrame:inView:]):
2454
2455 2013-08-01  Ruth Fong  <ruth_fong@apple.com>
2456
2457         [Forms: color] <input type='color'> popover color well implementation
2458         <rdar://problem/14411008> and https://bugs.webkit.org/show_bug.cgi?id=119356
2459
2460         Reviewed by Benjamin Poulain.
2461
2462         This patch adds an popover implementation of <input type='color'>.
2463
2464         * Configurations/FeatureDefines.xcconfig: Added and enabled INPUT_TYPE_COLOR_POPOVER.
2465
2466         * UIProcess/API/mac/PageClientImpl.mm:
2467         (WebKit::PageClientImpl::createColorPicker): Updated to pass the 
2468           coordinates of the <input type='color'> element and the WKView 
2469           object for the window.
2470
2471         * UIProcess/WebPageProxy.cpp:
2472         (WebKit::WebPageProxy::viewWillStartLiveResize): Close popover color 
2473           picker when the view is resized.
2474         (WebKit::WebPageProxy::viewInWindowStateDidChange): Close popover color
2475           picker when the view is no longer in the window.
2476         (WebKit::WebPageProxy::showColorPicker): Updated to show either a color panel
2477           or a popover color picker depending on whether INPUT_TYPE_COLOR_POPOVER is enabled.
2478
2479         * UIProcess/mac/WebColorPickerMac.h:
2480         * UIProcess/mac/WebColorPickerMac.mm:
2481         (WebKit::WebColorPickerMac::create):
2482         (WebKit::WebColorPickerMac::~WebColorPickerMac):
2483         (WebKit::WebColorPickerMac::WebColorPickerMac):
2484         (WebKit::WebColorPickerMac::endPicker):
2485         (WebKit::WebColorPickerMac::setSelectedColor):
2486         (WebKit::WebColorPickerMac::showColorPicker):
2487         Methods updated to handle both the color panel implementation and 
2488           the popover implementation; also renamed m_panel to m_colorPickerUI. 
2489
2490         (-[WKColorPopoverMac initWithFrame:WebCore::inView:]):
2491         (-[WKColorPopoverMac setAndShowPicker:WebKit::withColor:]):
2492         (-[WKColorPopoverMac dealloc]):
2493         (-[WKColorPopoverMac invalidate]):
2494         (-[WKColorPopoverMac windowWillClose:]):
2495         (-[WKColorPopoverMac didChooseColor:]):
2496         (-[WKColorPopoverMac setColor:]):
2497         WKColorPopoverMac provides the popover implementation of <input type='color'>.
2498
2499         (-[WKColorPanelMac didChooseColor:]): Updated to match the interface of 
2500           WKColorPickerMac::didChooseColor.
2501
2502 2013-08-01  Anders Carlsson  <andersca@apple.com>
2503
2504         Lots of leaks under WebContext::pluginInfoStoreDidLoadPlugins()
2505         https://bugs.webkit.org/show_bug.cgi?id=119412
2506
2507         Reviewed by Simon Fraser.
2508
2509         For some sick reason, the WKContextClient plugInInformationBecameAvailable callback function
2510         expects a +1 reference to the plug-in array. Isolate that hack to WebContextClient so that
2511         we don't leak the array if there is no WKContextClient.
2512         
2513         * UIProcess/WebContext.cpp:
2514         (WebKit::WebContext::pluginInfoStoreDidLoadPlugins):
2515         * UIProcess/WebContextClient.cpp:
2516         (WebKit::WebContextClient::plugInInformationBecameAvailable):
2517
2518 2013-08-01  Kwang Yul Seo  <skyul@company100.net>
2519
2520         Remove return statement in void function
2521         https://bugs.webkit.org/show_bug.cgi?id=119379
2522
2523         Reviewed by Darin Adler.
2524
2525         It does not make sense to return a value in void function.
2526
2527         * WebProcess/WebProcess.cpp:
2528         (WebKit::addCaseFoldedCharacters):
2529
2530 2013-08-01  Kwang Yul Seo  <skyul@company100.net>
2531
2532         [WK2] Add USE(SOUP) guard in WebProcess::destroyPrivateBrowsingSession
2533         https://bugs.webkit.org/show_bug.cgi?id=119381
2534
2535         Reviewed by Darin Adler.
2536
2537         The is a followup to r153355. I missed to add USE(SOUP) guard in
2538         WebProcess::destroyPrivateBrowsingSession.
2539
2540         * WebProcess/WebProcess.cpp:
2541         (WebKit::WebProcess::destroyPrivateBrowsingSession):
2542
2543 2013-08-01  Milian Wolff  <milian.wolff@kdab.com>
2544
2545         [Qt] Enable QML handling of crashed/unresponsive QtWebProcess
2546         https://bugs.webkit.org/show_bug.cgi?id=108474
2547
2548         Forward the processDidCrash, didRelaunchProcess, processDidBecomeUnresponsive
2549         and processDidBecomeResponsive signals to QML's WebView.experimental.
2550
2551         Reviewed by Jocelyn Turcotte.
2552
2553         * UIProcess/API/qt/qquickwebview.cpp:
2554         (QQuickWebViewPrivate::processDidCrash):
2555         (QQuickWebViewPrivate::didRelaunchProcess):
2556         (QQuickWebViewPrivate::processDidBecomeUnresponsive):
2557         (QQuickWebViewPrivate::processDidBecomeResponsive):
2558         * UIProcess/API/qt/qquickwebview_p.h:
2559         * UIProcess/API/qt/qquickwebview_p_p.h:
2560         (QQuickWebViewPrivate):
2561
2562 2013-07-31  Kwang Yul Seo  <skyul@company100.net>
2563
2564         Use emptyString instead of String("")
2565         https://bugs.webkit.org/show_bug.cgi?id=119335
2566
2567         Reviewed by Darin Adler.
2568
2569         Use emptyString() instead of String("") because it is better style and
2570         faster. This is a followup to r116908, removing all occurrences of
2571         String("") from WebKit.
2572
2573         * Shared/mac/WebEventFactory.mm:
2574         (WebKit::textFromEvent):
2575         (WebKit::unmodifiedTextFromEvent):
2576
2577 2013-07-31  Ruth Fong  <ruth_fong@apple.com>
2578
2579         <input type=color> Mac UI behaviour
2580         <rdar://problem/10269922> and https://bugs.webkit.org/show_bug.cgi?id=61276
2581
2582         Implemented <input type='color'> on Mac using the native color picker. 
2583
2584         Reviewed by Brady Eidson.
2585
2586         Code for WebColorPickerMac is derived from Chromium's color_chooser_mac.mm:
2587         https://code.google.com/p/chromium/codesearch#chromium/src/chrome/browser/ui/cocoa/color_chooser_mac.mm
2588
2589         * Configurations/FeatureDefines.xcconfig: Enabled INPUT_TYPE_COLOR.
2590
2591         * UIProcess/API/mac/PageClientImpl.mm:
2592         (WebKit::PageClientImpl::createColorPicker): Replaced stub implementation
2593           and return a WebColorPickerMac object.
2594
2595         * UIProcess/WebColorPicker.cpp:
2596         (WebKit::WebColorPicker::invalidate): Updated to call endChooser().
2597         (WebKit::WebColorPicker::showColorPicker): Added stub implementation.
2598         * UIProcess/WebColorPicker.h:
2599
2600         * UIProcess/WebPageProxy.cpp:
2601         (WebKit::WebPageProxy::close): Removed invalidation of removed color picker objects.
2602         (WebKit::WebPageProxy::showColorPicker): Updated so that it works for
2603           multiple <input type='color'> elements on a page.
2604         (WebKit::WebPageProxy::didEndColorPicker): Removed cleanup of removed color picker objects.
2605         (WebKit::WebPageProxy::resetStateAfterProcessExited): Removed cleanup of removed color picker objects.
2606
2607         * UIProcess/mac/WebColorPickerMac.h: Added.
2608         * UIProcess/mac/WebColorPickerMac.mm: Added.
2609         (WebKit::WebColorPickerMac::create):
2610         (WebKit::WebColorPickerMac::~WebColorPickerMac):
2611         (WebKit::WebColorPickerMac::WebColorPickerMac):
2612         (WebKit::WebColorPickerMac::endPicker):
2613         (WebKit::WebColorPickerMac::setSelectedColor):
2614         (WebKit::WebColorPickerMac::didChooseColor):
2615         (WebKit::WebColorPickerMac::showColorPicker):
2616         WebColorPickerMac contains a reference to a WKColorPanelMac object
2617           and is responsible for maintaining the color picker UI.
2618
2619         (-[WKColorPanelMac setAndShowPicker:withColor:]):
2620         (-[WKColorPanelMac invalidate]):
2621         (-[WKColorPanelMac windowWillClose:]):
2622         (-[WKColorPanelMac didChooseColor:]):
2623         (-[WKColorPanelMac setColor:]):
2624         WKColorPanelMac is a wrapper for a NSColorPanel object and 
2625           is responsible for the color picker UI.
2626
2627         * WebKit2.xcodeproj/project.pbxproj:
2628
2629         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
2630         (WebKit::WebChromeClient::createColorChooser): Updated to always create a 
2631           WebColorChooser object.
2632
2633         * WebProcess/WebCoreSupport/WebColorChooser.cpp:
2634         (WebKit::WebColorChooser::reattachColorChooser): Sets the page's 
2635           active color chooser to the current object and pings the UIProcess
2636           to show the color picker.
2637         (WebKit::WebColorChooser::setSelectedColor): Only sets the color in the
2638           color picker if the WebColorChooser object is the active color element.
2639         * WebProcess/WebCoreSupport/WebColorChooser.h:
2640
2641 2013-07-30  Gavin Barraclough  <barraclough@apple.com>
2642
2643         Some cleanup in JSValue::get
2644         https://bugs.webkit.org/show_bug.cgi?id=119343
2645
2646         Reviewed by Geoff Garen.
2647
2648         * WebProcess/Plugins/Netscape/JSNPObject.cpp:
2649         (WebKit::JSNPObject::getOwnPropertySlot):
2650         * WebProcess/Plugins/Netscape/JSNPObject.h:
2651             - getOwnPropertySlot, JSCell -> JSObject
2652
2653 2013-07-31  Allan Sandfeld Jensen  <allan.jensen@digia.com>
2654
2655         [Qt] Build WebKit with C++11
2656         https://bugs.webkit.org/show_bug.cgi?id=119337
2657
2658         Reviewed by Csaba Osztrogonác.
2659
2660         We no longer need to enable C++11 specifically for WebKit2.
2661
2662         * WebKit2.pri:
2663
2664 2013-07-30  Tim Horton  <timothy_horton@apple.com>
2665
2666         DHTML drag can result in a null-deref under WebDragClient::startDrag
2667         https://bugs.webkit.org/show_bug.cgi?id=119297
2668         <rdar://problem/14213012>
2669
2670         Reviewed by Simon Fraser.
2671
2672         * WebProcess/WebCoreSupport/mac/WebDragClientMac.mm:
2673         (WebKit::convertImageToBitmap):
2674         ShareableBitmap::createShareable can return null, but shouldn't dereference that.
2675
2676 2013-07-30  Ruth Fong  <ruth_fong@apple.com>
2677
2678         Rename <input type='color'> functions in WebPageProxy, WebColorPicker
2679         <rdar://problem/14549771> and https://bugs.webkit.org/show_bug.cgi?id=119097
2680
2681         Reviewed by Tim Horton.
2682
2683         In bug 119025, WebColorChooserProxy was renamed WebColorPicker. This patch makes the UIProcess consistent
2684         by renaming UIProcess INPUT_TYPE_COLOR functions from ...colorChooser to ...colorPicker.
2685
2686         * UIProcess/WebColorPicker.cpp:
2687         (WebKit::WebColorPicker::endPicker):
2688         * UIProcess/WebColorPicker.h:
2689         * UIProcess/WebColorPickerResultListenerProxy.cpp:
2690         (WebKit::WebColorPickerResultListenerProxy::setColor):
2691         * UIProcess/WebPageProxy.cpp:
2692         (WebKit::WebPageProxy::showColorPicker):
2693         (WebKit::WebPageProxy::setColorPickerColor):
2694         (WebKit::WebPageProxy::endColorPicker):
2695         (WebKit::WebPageProxy::didEndColorPicker):
2696         * UIProcess/WebPageProxy.h:
2697         * UIProcess/WebPageProxy.messages.in:
2698         * UIProcess/qt/WebColorPickerQt.cpp:
2699         (WebKit::WebColorPickerQt::createItem):
2700         (WebKit::WebColorPickerQt::notifyColorSelected):
2701         (WebKit::WebColorPickerQt::endPicker):
2702         * UIProcess/qt/WebColorPickerQt.h:
2703         * WebProcess/WebCoreSupport/WebColorChooser.cpp:
2704         (WebKit::WebColorChooser::WebColorChooser):
2705         (WebKit::WebColorChooser::setSelectedColor):
2706         (WebKit::WebColorChooser::endChooser):
2707         * WebProcess/WebPage/WebPage.cpp:
2708         (WebKit::WebPage::didEndColorPicker):
2709         * WebProcess/WebPage/WebPage.h:
2710         * WebProcess/WebPage/WebPage.messages.in:
2711
2712 2013-07-30  Anders Carlsson  <andersca@apple.com>
2713
2714         Speculative fix for crash due to string access on multiple threads
2715         https://bugs.webkit.org/show_bug.cgi?id=119279
2716         <rdar://problem/14267833>
2717
2718         Reviewed by Darin Adler.
2719
2720         We can't use String::isolatedCopy for passing the local storage directory to the storage thread since
2721         that returns a String that's copied and then destroyed after the call to bind returns, leaving a small window
2722         where the refcount can be accessed simultaneously from two threads.
2723
2724         Work around this by passing a PassRefPtr<StringImpl> to bind instead; the act of copying the PassRefPtr will
2725         clear out the original and so when the original is destroyed the underlying StringImpl pointer will be null.
2726
2727         * UIProcess/Storage/LocalStorageDatabaseTracker.cpp:
2728         (WebKit::LocalStorageDatabaseTracker::setLocalStorageDirectory):
2729         (WebKit::LocalStorageDatabaseTracker::setLocalStorageDirectoryInternal):
2730         * UIProcess/Storage/LocalStorageDatabaseTracker.h:
2731
2732 2013-07-30  Tim Horton  <timothy_horton@apple.com>
2733
2734         Fix typo in enum name ("SelectionInSnaphot" -> "SelectionInSnapshot")
2735         https://bugs.webkit.org/show_bug.cgi?id=119275
2736
2737         Reviewed by Simon Fraser.
2738
2739         * WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.cpp:
2740         (WebKit::imageForRect):
2741         * WebProcess/WebPage/WebPage.cpp:
2742         (WebKit::WebPage::scaledSnapshotWithOptions):
2743         Fix typo.
2744
2745 2013-07-30  Anders Carlsson  <andersca@apple.com>
2746
2747         Plug-in process crashes if plug-in is destroyed as a result of sending NPObjectMessageReceiver::Deallocate
2748         https://bugs.webkit.org/show_bug.cgi?id=119270
2749         <rdar://problem/13368226>
2750
2751         Reviewed by Darin Adler.
2752
2753         Normally we use the PluginDestructionProtector RAII object to prevent plug-ins from being destroyed while
2754         they're executing code. However, in the case of the NPObjectMessageReceiver::Deallocate message, we can't do this
2755         since we don't know the plug-in or connection. 
2756         
2757         Instead, add a counter to Connection that keeps track of whether sendSync is currently called and defer plug-in
2758         destruction if it is. (This approach is actually more robust and we should investigate getting rid of the destruction protector).
2759
2760         * Platform/CoreIPC/Connection.cpp:
2761         (CoreIPC::Connection::Connection):
2762         (CoreIPC::Connection::sendSyncMessage):
2763         * Platform/CoreIPC/Connection.h:
2764         (CoreIPC::Connection::inSendSync):
2765         * PluginProcess/PluginControllerProxy.cpp:
2766         (WebKit::PluginControllerProxy::destroy):
2767
2768 2013-07-30  Tim Horton  <timothy_horton@apple.com>
2769
2770         Null deref under WebPage::scaledSnapshotWithOptions
2771         https://bugs.webkit.org/show_bug.cgi?id=119243
2772         <rdar://problem/14502050>
2773
2774         Reviewed by Darin Adler.
2775
2776         * WebProcess/WebPage/WebPage.cpp:
2777         (WebKit::WebPage::scaledSnapshotWithOptions):
2778         WebFrame::coreFrame() can be null (if the Frame is already torn down),
2779         so we should check it.
2780
2781 2013-07-30  Tim Horton  <timothy_horton@apple.com>
2782
2783         Null deref under PluginView::handlesPageScaleFactor()
2784         https://bugs.webkit.org/show_bug.cgi?id=119231
2785         <rdar://problem/14440207>
2786
2787         Reviewed by Darin Adler.
2788
2789         Null-check the PluginView in the caller as well.
2790
2791         * WebProcess/WebPage/WebFrame.cpp:
2792         (WebKit::WebFrame::handlesPageScaleGesture):
2793
2794 2013-07-30  Patrick Gansterer  <paroga@webkit.org>
2795
2796         Remove unused Download*.cpp files
2797         https://bugs.webkit.org/show_bug.cgi?id=119248
2798
2799         Reviewed by Anders Carlsson.
2800
2801         * Shared/Downloads/cfnet/DownloadCFNet.cpp: Removed.
2802         * Shared/Downloads/curl/DownloadCurl.cpp: Removed.
2803
2804 2013-07-30  Jeff Miller  <jeffm@apple.com>
2805
2806         Page for WKPageLoaderClient processDidCrash callback always reports a process identifier of 0
2807         https://bugs.webkit.org/show_bug.cgi?id=119269
2808         <rdar://problem/14582393>
2809
2810         Reviewed by Anders Carlsson.
2811
2812         * UIProcess/WebPageProxy.cpp:
2813         (WebKit::WebPageProxy::processIdentifier):
2814         Return 0 if the page is closed instead of requiring isValid().
2815
2816 2013-07-30  Kwang Yul Seo  <skyul@company100.net>
2817
2818         [WK2] Move the implementation of WebEditorClient::checkTextOfParagraph to WebEditorClient.cpp
2819         https://bugs.webkit.org/show_bug.cgi?id=119034
2820
2821         Reviewed by Anders Carlsson.
2822
2823         The Mac and EFL ports use the same implementation of
2824         WebEditorClient::checkTextOfParagraph and GTK will use the same
2825         implementation too. So rather than duplicating the same code in
2826         platform specific files, move the implementation to platform agnostic
2827         WebProcess/WebCoreSupport/WebEditorClient.cpp.
2828
2829         * WebProcess/WebCoreSupport/WebEditorClient.cpp:
2830         (WebKit::WebEditorClient::checkTextOfParagraph):
2831         * WebProcess/WebCoreSupport/efl/WebEditorClientEfl.cpp:
2832         * WebProcess/WebCoreSupport/mac/WebEditorClientMac.mm:
2833
2834 2013-07-30  Brian Holt  <brian.holt@samsung.com>
2835
2836         [WebKit2] [Gtk] WebKitResponsePolicyDecision URI response property incorrect
2837         https://bugs.webkit.org/show_bug.cgi?id=119258
2838
2839         Reviewed by Martin Robinson.
2840
2841         Corrected the installed URI response property from PROP_REQUEST to
2842         PROP_RESPONSE and type from WEBKIT_TYPE_URI_REQUEST to
2843         WEBKIT_TYPE_URI_RESPONSE.
2844
2845         * UIProcess/API/gtk/WebKitResponsePolicyDecision.cpp:
2846         (webkit_response_policy_decision_class_init):
2847
2848 2013-07-29  Carlos Garcia Campos  <cgarcia@igalia.com>
2849
2850         Unreviewed. Fix make distcheck.
2851
2852         * GNUmakefile.list.am: Add missing header file to compilation.
2853
2854 2013-07-29  Tim Horton  <timothy_horton@apple.com>
2855
2856         [wk2] Flush the WebProcess’ implicit transaction when using endDeferringViewInWindowChangesSync
2857         https://bugs.webkit.org/show_bug.cgi?id=119225
2858         <rdar://problem/14568841>
2859
2860         Reviewed by Simon Fraser.
2861
2862         Tell CoreAnimation to flush the implicit transaction before replying
2863         when using endDeferringViewInWindowChangesSync, as that method's contract
2864         is that the WebProcess is totally ready to be in-window when it returns.
2865
2866         * UIProcess/API/mac/WKView.mm:
2867         (-[WKView endDeferringViewInWindowChanges]):
2868         Adopt viewInWindowStateDidChange.
2869
2870         (-[WKView endDeferringViewInWindowChangesSync]):
2871         Adopt viewInWindowStateDidChange, asking it to send a reply only if we're going to wait for one.
2872
2873         * UIProcess/WebPageProxy.cpp:
2874         (WebKit::WebPageProxy::viewInWindowStateDidChange):
2875         (WebKit::WebPageProxy::viewStateDidChange):
2876         Pull viewInWindowStateDidChange out of viewStateDidChange.
2877         Request a reply from SetIsInWindow if we're told to.
2878
2879         * UIProcess/WebPageProxy.h: Add WantsReplyOrNot and viewInWindowStateDidChange.
2880         * WebProcess/WebPage/WebPage.cpp:
2881         (WebKit::WebPage::didUpdateInWindowStateTimerFired):
2882         Don't build this version on Mac, we'll have a WebPageMac version.
2883
2884         (WebKit::WebPage::setIsInWindow):
2885         Only start the timer to send the didUpdateInWindowState reply if we're asked to.
2886
2887         * WebProcess/WebPage/WebPage.h:
2888         * WebProcess/WebPage/WebPage.messages.in:
2889         Add an argument to the SetIsInWindow message for whether the WebProcess
2890         should inform the UIProcess when SetIsInWindow completes or not.
2891
2892         * WebProcess/WebPage/mac/WebPageMac.mm:
2893         (WebKit::WebPage::didUpdateInWindowStateTimerFired):
2894         Tell CA to flush the implicit transaction before telling the UIProcess that
2895         we're finished moving in-window.
2896
2897 2013-07-29  Tim Horton  <timothy_horton@apple.com>
2898
2899         Null deref under PluginView::handlesPageScaleFactor()
2900         https://bugs.webkit.org/show_bug.cgi?id=119231
2901         <rdar://problem/14440207>
2902
2903         Reviewed by Simon Fraser.
2904
2905         * WebProcess/Plugins/PluginView.cpp:
2906         (WebKit::PluginView::handlesPageScaleFactor):
2907         * WebProcess/Plugins/PluginView.h:
2908         Null-check m_plugin and check m_isInitialized.
2909         Make pageScaleFactor() and handlesPageScaleFactor const.
2910
2911 2013-07-29  Anders Carlsson  <andersca@apple.com>
2912
2913         Remove setUnderlayPage() and associated code
2914         https://bugs.webkit.org/show_bug.cgi?id=119220
2915         <rdar://problem/14392426>
2916
2917         Reviewed by Jessie Berlin.
2918
2919         This is dead code, get rid of it.
2920
2921         * WebProcess/InjectedBundle/API/c/WKBundlePage.cpp:
2922         * WebProcess/InjectedBundle/API/c/WKBundlePage.h:
2923         * WebProcess/WebPage/WebPage.cpp:
2924         (WebKit::WebPage::close):
2925         (WebKit::WebPage::layoutIfNeeded):
2926         (WebKit::WebPage::drawRect):
2927         * WebProcess/WebPage/WebPage.h:
2928
2929 2013-07-29  Sergio Correia  <sergio.correia@openbossa.org>
2930
2931         CoordinatedGraphics: Add API to get and set the active state of a WebView
2932         https://bugs.webkit.org/show_bug.cgi?id=119067
2933
2934         Reviewed by Noam Rosenthal.
2935
2936         A view being in the "active" state generally means that it is not in the
2937         "background", although this definition can vary depending on the platform
2938         under consideration.
2939
2940         This patch adds the following APIs to WKView:
2941         - bool WKViewIsActive(WKViewRef)
2942         This API accepts a WKViewRef as parameter and returns a boolean indicating
2943         whether the given view is active.
2944
2945         - void WKViewSetIsActive(WKViewRef, bool)
2946         This API accepts a WKViewRef and a boolean as parameteres, and it sets the
2947         active state of the given view to the given boolean argument.
2948
2949         * UIProcess/API/C/CoordinatedGraphics/WKView.cpp:
2950         (WKViewIsActive): API added.
2951         (WKViewSetIsActive): Ditto.
2952         * UIProcess/API/C/CoordinatedGraphics/WKView.h: Export aforementioned API.
2953         * UIProcess/CoordinatedGraphics/WebView.cpp:
2954         (WebKit::WebView::initialize): Use new setActive method.
2955         (WebKit::WebView::setActive): Added method to set the active state of the
2956         view.
2957         (WebKit::WebView::isActive): Added method to return the active state of
2958         view.
2959         (WebKit::WebView::enterAcceleratedCompositingMode): Use new setActive
2960         method.
2961         (WebKit::WebView::exitAcceleratedCompositingMode): Ditto.
2962         * UIProcess/CoordinatedGraphics/WebView.h: Added declarations of isActive
2963         and setActive.
2964
2965 2013-07-29  Jae Hyun Park  <jae.park@company100.net>
2966
2967         Remove duplicated LayerTreeHost::supportsAcceleratedCompositing
2968         https://bugs.webkit.org/show_bug.cgi?id=118949
2969
2970         Reviewed by Noam Rosenthal.
2971
2972         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.cpp:
2973         * WebProcess/WebPage/LayerTreeHost.h:
2974         (WebKit::LayerTreeHost::supportsAcceleratedCompositing):
2975
2976 2013-07-29  Zan Dobersek  <zdobersek@igalia.com>
2977
2978         [Automake] Remove references to non-existent *_CFLAGS and *_LIBS variables
2979         https://bugs.webkit.org/show_bug.cgi?id=119212
2980
2981         Reviewed by Carlos Garcia Campos.
2982
2983         * GNUmakefile.am: Remove references to GLOBALDEPS_(CFLAGS|LIBS) and CLUTTER_(CFLAGS|LIBS)
2984         variables that are not defined during the configuration process.
2985
2986 2013-07-28  Grzegorz Czajkowski  <g.czajkowski@samsung.com>
2987
2988         [EFL][WK2] Simplify context_menu_spelling_items_availability unit test
2989         https://bugs.webkit.org/show_bug.cgi?id=119085
2990
2991         Reviewed by Gyuyoung Kim.
2992
2993         Use findContextMenuItem method to check whether the item
2994         appears in context menu.
2995
2996         * UIProcess/API/efl/tests/test_ewk2_text_checker.cpp:
2997         (EWK2TextCheckerTest::findContextMenuItem):
2998         Do not report failure inside the method.
2999         It doesn't allow to test the negative test cases.
3000
3001         (EWK2TextCheckerTest::checkCorrectnessOfSpellingItems):
3002         Use findContextMenuItem method.
3003
3004         (EWK2TextCheckerTest::toogleCheckSpellingWhileTyping):
3005         (EWK2TextCheckerTest::selectLearnSpelling):
3006         (EWK2TextCheckerTest::selectIgnoreSpelling):
3007         Verify the return value of findContextMenuItem.
3008
3009         (TEST_F):
3010         Reset wasContextMenuShown variable, it's needed after r152153.
3011         Use waitUntilTrue method.
3012
3013 2013-07-27  Jacky Jiang  <zhajiang@blackberry.com>
3014
3015         Replace all uses of GraphicsLayer::create function with the one that takes a GraphicsLayerFactory
3016         https://bugs.webkit.org/show_bug.cgi?id=119186
3017
3018         Reviewed by Anders Carlsson.
3019
3020         * UIProcess/mac/RemoteLayerTreeHost.mm:
3021         (WebKit::RemoteLayerTreeHost::getOrCreateLayer):
3022
3023 2013-07-27  Chris Fleizach  <cfleizach@apple.com>
3024
3025         AX: VoiceOver not working with data detection page overlays
3026         https://bugs.webkit.org/show_bug.cgi?id=118680
3027
3028         Reviewed by Sam Weinig.
3029
3030         Expose API in BundlePageOverlay so that accessibility attributes can be retrieved through the overlay.
3031         This requires two methods in a new callback struct. One to copy the attribute names, and the other to 
3032         copy the attribute values. I've folded both parameterized and non-parameterized attribute names into one method
3033         with a boolean to determine which one should be used. The non-parameterized attributes are not used or passed to the
3034         overlay at this time as there are no clients with such a need.
3035
3036         * WebProcess/InjectedBundle/API/c/WKBundlePageOverlay.cpp:
3037         (PageOverlayClientImpl::setAccessibilityClient):
3038         (PageOverlayClientImpl::PageOverlayClientImpl):
3039         (PageOverlayClientImpl::copyAccessibilityAttributeValue):
3040         (PageOverlayClientImpl::copyAccessibilityAttributeNames):
3041         (WKBundlePageOverlaySetAccessibilityClient):
3042         * WebProcess/InjectedBundle/API/c/WKBundlePageOverlay.h:
3043         * WebProcess/WebPage/PageOverlay.cpp:
3044         (WebKit::PageOverlay::copyAccessibilityAttributeValue):
3045         (WebKit::PageOverlay::copyAccessibilityAttributeNames):
3046         * WebProcess/WebPage/PageOverlay.h:
3047         (WebKit::PageOverlay::Client::copyAccessibilityAttributeValue):
3048         (WebKit::PageOverlay::Client::copyAccessibilityAttributeNames):
3049         (WebKit::PageOverlay::client):
3050         * WebProcess/WebPage/WebPage.cpp:
3051         (WebKit::WebPage::pageOverlayCopyAccessibilityAttributeValue):
3052         (WebKit::WebPage::pageOverlayCopyAccessibilityAttributesNames):
3053         * WebProcess/WebPage/WebPage.h:
3054         * WebProcess/WebPage/mac/WKAccessibilityWebPageObject.mm:
3055         (-[WKAccessibilityWebPageObject accessibilityParameterizedAttributeNames]):
3056         (-[WKAccessibilityWebPageObject _convertScreenPointToWindow:]):
3057         (-[WKAccessibilityWebPageObject accessibilityAttributeValue:forParameter:]):
3058
3059 2013-07-27  Simon Fraser  <simon.fraser@apple.com>
3060
3061         If entering fullscreen for a window fails, don't leave things in a bad state
3062         https://bugs.webkit.org/show_bug.cgi?id=119179
3063
3064         Reviewed by Sam Weinig.
3065         
3066         On Lion, attempting to take a video fullscreen when the Safari window is already
3067         fullscreen can sometimes fail, and AppKit informs us via windowDidFailToEnterFullScreen:
3068         
3069         When this happens we have to undo the work done when entering fullscreen, to
3070         avoid leaving things in a bad state.
3071
3072         * UIProcess/mac/WKFullScreenWindowController.mm:
3073         (-[WKFullScreenWindowController finishedEnterFullScreenAnimation:]):
3074
3075 2013-07-26  Tim Horton  <timothy_horton@apple.com>
3076
3077         Add a mode where autosizing fixes the FrameView height to at least the WKView height
3078         https://bugs.webkit.org/show_bug.cgi?id=119104
3079         <rdar://problem/14549021>
3080
3081         Reviewed by Anders Carlsson.
3082
3083         * Shared/WebPageCreationParameters.cpp:
3084         (WebKit::WebPageCreationParameters::encode):
3085         (WebKit::WebPageCreationParameters::decode):
3086         * Shared/WebPageCreationParameters.h:
3087         Add autoSizingShouldExpandToViewHeight parameter.
3088
3089         * UIProcess/API/mac/WKView.mm:
3090         (-[WKView minimumWidthForAutoLayout]):
3091         (-[WKView setMinimumWidthForAutoLayout:]):
3092         Un-deprecate these as they're still useful if not sending a height.
3093
3094         (-[WKView shouldExpandToViewHeightForAutoLayout]):
3095         (-[WKView setShouldExpandToViewHeightForAutoLayout:]):
3096         * UIProcess/API/mac/WKViewPrivate.h:
3097         New property, forward to WebPageProxy.
3098
3099         * UIProcess/WebPageProxy.cpp:
3100         (WebKit::WebPageProxy::WebPageProxy):
3101         (WebKit::WebPageProxy::creationParameters):
3102         (WebKit::WebPageProxy::setAutoSizingShouldExpandToViewHeight):
3103         * UIProcess/WebPageProxy.h:
3104         (WebKit::WebPageProxy::autoSizingShouldExpandToViewHeight):
3105         New property, forward to WebPage.
3106
3107         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
3108         (WebKit::WebFrameLoaderClient::transitionToCommittedForNewPage):
3109         If enabled, update the FrameView's autoSizeFixedMinimumHeight.
3110
3111         * WebProcess/WebPage/WebPage.cpp:
3112         (WebKit::WebPage::WebPage):
3113         (WebKit::WebPage::setAutoSizingShouldExpandToViewHeight):
3114         * WebProcess/WebPage/WebPage.h:
3115         (WebKit::WebPage::autoSizingShouldExpandToViewHeight):
3116         New property; if enabled, set FrameView's autoSizeFixedMinimumHeight,
3117         otherwise reset it to 0.
3118
3119         * WebProcess/WebPage/WebPage.messages.in:
3120         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
3121         (WebKit::TiledCoreAnimationDrawingArea::updateIntrinsicContentSizeTimerFired):
3122         (WebKit::TiledCoreAnimationDrawingArea::updateGeometry):
3123         Retrieve intrinsic content size explicitly from the FrameView, as
3124         it may not have used it as its final contentsSize if
3125         autoSizeFixedMinimumHeight is set.
3126
3127         Set the WebPage's size in case the load is committed so that the
3128         WebFrameLoaderClient doesn't reset us to the wrong size.
3129
3130         Update autoSizeFixedMinimumHeight if enabled when the view size changes.
3131
3132 2013-07-25  Andreas Kling  <akling@apple.com>
3133
3134         ChromeClient::focusedNodeChanged() should be focusedElementChanged().
3135         <http://webkit.org/b/119110>
3136
3137         Reviewed by Anders Carlsson.
3138
3139         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
3140         (WebKit::WebChromeClient::focusedElementChanged):
3141         * WebProcess/WebCoreSupport/WebChromeClient.h:
3142
3143 2013-07-25  Kwang Yul Seo  <skyul@company100.net>
3144
3145         [WK2][Soup] Add private browsing support
3146         https://bugs.webkit.org/show_bug.cgi?id=118657
3147
3148         Reviewed by Gustavo Noronha Silva.
3149
3150         Support private browsing in WK2 by implementing private browsing
3151         related methods in WebFrameNetworkingContext.
3152
3153         * WebProcess/InjectedBundle/InjectedBundle.cpp:
3154         (WebKit::InjectedBundle::setPrivateBrowsingEnabled):
3155         Add USE(SOUP) guard.
3156
3157         * WebProcess/WebCoreSupport/soup/WebFrameNetworkingContext.cpp:
3158         Add private browsing support methods. Copied from the Mac port.
3159         (WebKit::WebFrameNetworkingContext::ensurePrivateBrowsingSession):
3160         (WebKit::WebFrameNetworkingContext::destroyPrivateBrowsingSession):
3161         (WebKit::WebFrameNetworkingContext::storageSession):
3162         Check if the frame enables private browsing and return the private
3163         browsing session.
3164         * WebProcess/WebCoreSupport/soup/WebFrameNetworkingContext.h:
3165
3166         * WebProcess/WebProcess.cpp:
3167         (WebKit::WebProcess::ensurePrivateBrowsingSession):
3168         Add USE(SOUP) guard.
3169
3170 2013-07-25  Kwang Yul Seo  <skyul@company100.net>
3171
3172         Build fix: use of long long in CoreIPC::ArgumentEncoder and CoreIPC::ArgumentDecoder
3173         https://bugs.webkit.org/show_bug.cgi?id=118228
3174
3175         Reviewed by Anders Carlsson.
3176
3177         Build fails on some platforms where int64_t and long long are different types.
3178
3179         * Shared/FileAPI/BlobRegistrationData.cpp:
3180         (WebKit::BlobRegistrationData::encode):
3181         Add explicit casts to int64_t.
3182         (WebKit::BlobRegistrationData::decode):
3183         Use int64_t instead of long long.
3184
3185 2013-07-25  Anders Carlsson  <andersca@apple.com>
3186
3187         Remove lastModifiedDate from ResourceResponse
3188         https://bugs.webkit.org/show_bug.cgi?id=119092
3189
3190         Reviewed by Andreas Kling.
3191
3192         Update for WebCore changes.
3193
3194         * WebProcess/Plugins/PluginView.cpp:
3195         (WebKit::lastModifiedDate):
3196         Use ResourceResponse::lastModified() to get the last modified date.
3197
3198         (WebKit::PluginView::Stream::didReceiveResponse):
3199         Call the static lastModified function.
3200
3201         (WebKit::PluginView::manualLoadDidReceiveResponse):
3202         Ditto.
3203
3204 2013-07-25  Carlos Garcia Campos  <cgarcia@igalia.com>
3205
3206         [GTK] Add support for running unit tests in the web process
3207         https://bugs.webkit.org/show_bug.cgi?id=118427
3208
3209         Reviewed by Gustavo Noronha Silva.
3210
3211         Some tests, like GObject DOM bindings API tests, run entirely in
3212         the WebProcess, so we just need to start the test from the UI
3213         process and wait until the test finishes running in the
3214         WebProcess. Tests are split in two files, one containing the
3215         actual test that runs in the WebProcess and another one to add the
3216         tests to the glib test system that works as a
3217         proxy. WebProcessTestRunner class starts a private DBus session
3218         bus and starts the tests sending a message to the WebExtension
3219         waiting until it finishes or fails. WebProcess tests are created
3220         by defining a class derived from WebProcessTest class and
3221         implementing the static create method and the virtual runTest
3222         method. The macro REGISTER_TEST is used by the web process tests
3223         to register their test cases. This patch includes the migration
3224         of the WebKitDOMNode test, all other GObject DOM bindings tests
3225         will be migrated in the same way in follow up patches.
3226
3227         * UIProcess/API/gtk/tests/DOMNodeTest.cpp: Added.
3228         (WebKitDOMNodeTest::create): Create a new WebKitDOMNodeTest.
3229         (WebKitDOMNodeTest::webPageFromArgs): Get the pageID parameter
3230         from the arguments dictionary.
3231         (WebKitDOMNodeTest::testHierarchyNavigation):
3232         (WebKitDOMNodeTest::testInsertion):
3233         (WebKitDOMNodeTest::runTest): Run the given test.
3234         (registerTests): Register test cases.
3235         * UIProcess/API/gtk/tests/GNUmakefile.am: Add new files to
3236         compilation.
3237         * UIProcess/API/gtk/tests/TestDOMNode.cpp: Added.
3238         (testWebKitDOMNodeHierarchyNavigation):
3239         (testWebKitDOMNodeInsertion):
3240         (beforeAll):
3241         (afterAll):
3242         * UIProcess/API/gtk/tests/TestMain.cpp:
3243         (main): Unset DBUS_SESSION_BUS_ADDRESS environment variable to
3244         make sure that the GLib bus singleton is initialized by the
3245         private DBus session bus created by the tests.
3246         * UIProcess/API/gtk/tests/WebProcessTest.cpp: Added.
3247         (testsMap): Initialize and get the global map of tests.
3248         (WebProcessTest::add): Add a new test to the map, keeping a
3249         function to create the test.
3250         (WebProcessTest::create): Create a test for the given name.
3251         (methodCallCallback): Handle RunTest DBus method. It creates and
3252         runs the given test.
3253         (webkit_web_extension_initialize):Register the DBus service for
3254         this WebExtension.
3255         * UIProcess/API/gtk/tests/WebProcessTest.h: Added.
3256         * UIProcess/API/gtk/tests/WebProcessTestRunner.cpp: Added.
3257         (WebProcessTestRunner::WebProcessTestRunner): Start a private DBus
3258         session bus and get a connection to it.
3259         (WebProcessTestRunner::~WebProcessTestRunner): Stop the private
3260         DBus session bus.
3261         (WebProcessTestRunner::proxyCreatedCallback):
3262         (WebProcessTestRunner::proxy): Create a new proxy to send messages
3263         to the WebExtension if it doesn't exists.
3264         (WebProcessTestRunner::onNameAppeared): Called when the DBus
3265         service has been registered in the WebExtension and it's safe to
3266         create a proxy.
3267         (WebProcessTestRunner::onNameVanished): Called when the DBus
3268         service is unregistered. This happens when the web process crash,
3269         so we just exit here, because the g_asserts in the web process
3270         have already registered the error message.
3271         (WebProcessTestRunner::testFinishedCallback): Called when the
3272         WebProcess tests has finished.
3273         (WebProcessTestRunner::runTest): Send a message to the
3274         WebExtension to start the given test and monitor the service.
3275         (WebProcessTestRunner::finishTest): Save the test result and
3276         finish the main loop.
3277         * UIProcess/API/gtk/tests/WebProcessTestRunner.h: Added.
3278
3279 2013-05-05  Geoffrey Garen  <ggaren@apple.com>
3280
3281         Rolled back in r149527 with crash fixed.
3282
3283         Reviewed by Oliver Hunt.
3284
3285             Rationalized 'this' value conversion
3286             https://bugs.webkit.org/show_bug.cgi?id=115542
3287
3288 2013-07-24  Ruth Fong  <ruth_fong@apple.com>
3289
3290         Rename WebColorChooserProxy
3291         <rdar://problem/14528039> and https://bugs.webkit.org/show_bug.cgi?id=119025
3292
3293         Reviewed by Brady Eidson.
3294
3295         Renamed WebColorChooserProxy to WebColorPicker since the name WebColorChoooserProxy
3296         implies that it represents the same object as WebColorChooser, which is not true.
3297         Also, renamed createColorChooserProxy to createColorPicker in WebPageProxy and 
3298         platform-equivalent versions of it.
3299
3300         * CMakeLists.txt:
3301         * GNUmakefile.list.am:
3302         * Target.pri:
3303         * UIProcess/API/gtk/PageClientImpl.cpp:
3304         (WebKit::PageClientImpl::createColorPicker):
3305         * UIProcess/API/gtk/PageClientImpl.h:
3306         * UIProcess/API/mac/PageClientImpl.h:
3307         * UIProcess/API/mac/PageClientImpl.mm:
3308         (WebKit::PageClientImpl::createColorPicker):
3309         * UIProcess/API/qt/raw/qrawwebview.cpp:
3310         (QRawWebViewPrivate::createColorPicker):
3311         * UIProcess/API/qt/raw/qrawwebview_p_p.h:
3312         * UIProcess/CoordinatedGraphics/WebView.cpp:
3313         (WebKit::WebView::createColorPicker):
3314         * UIProcess/CoordinatedGraphics/WebView.h:
3315         * UIProcess/PageClient.h:
3316         * UIProcess/WebColorChooserProxy.cpp: Removed.
3317         * UIProcess/WebColorChooserProxy.h: Removed.
3318         * UIProcess/WebColorPicker.cpp: Copied from Source/WebKit2/UIProcess/WebColorChooserProxy.cpp.
3319         (WebKit::WebColorPicker::WebColorPicker):
3320         (WebKit::WebColorPicker::~WebColorPicker):
3321         (WebKit::WebColorPicker::endChooser):
3322         (WebKit::WebColorPicker::setSelectedColor):
3323         * UIProcess/WebColorPicker.h: Copied from Source/WebKit2/UIProcess/WebColorChooserProxy.h.
3324         (WebKit::WebColorPicker::create):
3325         * UIProcess/WebPageProxy.cpp:
3326         (WebKit::WebPageProxy::close):
3327         (WebKit::WebPageProxy::showColorChooser):
3328         (WebKit::WebPageProxy::setColorChooserColor):
3329         (WebKit::WebPageProxy::endColorChooser):
3330         (WebKit::WebPageProxy::didEndColorChooser):
3331         (WebKit::WebPageProxy::resetStateAfterProcessExited):
3332         * UIProcess/WebPageProxy.h: Renamed m_colorChooser to m_colorPicker.
3333         * UIProcess/qt/QtPageClient.cpp:
3334         (WebKit::QtPageClient::createColorPicker):
3335         * UIProcess/qt/QtPageClient.h:
3336         * UIProcess/qt/WebColorChooserProxyQt.cpp: Removed.
3337         * UIProcess/qt/WebColorChooserProxyQt.h: Removed.
3338         * UIProcess/qt/WebColorPickerQt.cpp: Added.
3339         (WebKit::ColorChooserContextObject::ColorChooserContextObject):
3340         (WebKit::ColorChooserContextObject::currentColor):
3341         (WebKit::ColorChooserContextObject::elementRect):
3342         (WebKit::ColorChooserContextObject::accept):
3343         (WebKit::ColorChooserContextObject::reject):
3344         (WebKit::WebColorPickerQt::WebColorPickerQt):
3345         (WebKit::WebColorPickerQt::~WebColorPickerQt):
3346         (WebKit::WebColorPickerQt::createItem):
3347         (WebKit::WebColorPickerQt::createContext):
3348         (WebKit::WebColorPickerQt::setSelectedColor):
3349         (WebKit::WebColorPickerQt::notifyColorSelected):
3350         (WebKit::WebColorPickerQt::endChooser):
3351         * UIProcess/qt/WebColorPickerQt.h: Added.
3352         (WebKit::WebColorPickerQt::create):
3353         * WebKit2.xcodeproj/project.pbxproj:
3354
3355 2013-07-24  Anders Carlsson  <andersca@apple.com>
3356
3357         Crash when calling WKPageGetProcessIdentifier after aborted process launch
3358         https://bugs.webkit.org/show_bug.cgi?id=119069
3359         <rdar://problem/14494064>
3360
3361         Reviewed by Andreas Kling.
3362
3363         * UIProcess/WebPageProxy.cpp:
3364         (WebKit::WebPageProxy::processIdentifier):
3365         Check if the page is closed instead of checking whether we have a process - We'll always have a process.
3366         
3367         (WebKit::WebPageProxy::isValid):
3368         Make this const.
3369
3370         * UIProcess/WebPageProxy.h:
3371
3372 2013-07-24  Kwang Yul Seo  <skyul@company100.net>
3373
3374         [WK2][Soup] Add entry point for network process
3375         https://bugs.webkit.org/show_bug.cgi?id=110136
3376
3377         Reviewed by Gustavo Noronha Silva.
3378
3379         Original patch by Balazs Kelemen <kbalazs@webkit.org>.
3380
3381         Added a common entry point for non-Mac Unix ports.
3382
3383         * NetworkProcess/unix/NetworkProcessMainUnix.cpp: Added.
3384         (WebKit::NetworkProcessMain):
3385         * NetworkProcess/unix/NetworkProcessMainUnix.h: Added.
3386         * unix/NetworkMainUnix.cpp: Added.
3387         (main):
3388
3389 2013-07-24  Jessie Berlin  <jberlin@apple.com>
3390
3391         Remove WKPageGetPlugInInformation - it is not used anymore
3392         https://bugs.webkit.org/show_bug.cgi?id=119047
3393
3394         Reviewed by Alexey Proskuryakov.
3395
3396         Revert r151172, which fixed a crash introduced in r151043, r151054, which fixed some naming
3397         and ref-churn issues introduced in r151043, and r151043, which added
3398         WKPageGetPlugInInformation.
3399
3400         * UIProcess/API/C/mac/WKPagePrivateMac.cpp:
3401         (WKPageIsURLKnownHSTSHost):
3402         * UIProcess/API/C/mac/WKPagePrivateMac.h:
3403         * UIProcess/Plugins/PluginProcessManager.h:
3404         * UIProcess/Plugins/mac/PluginProcessManagerMac.mm:
3405         * UIProcess/WebPageProxy.cpp:
3406         (WebKit::WebPageProxy::close):
3407         * UIProcess/WebPageProxy.h:
3408         * UIProcess/WebPageProxy.messages.in:
3409         * UIProcess/mac/WebPageProxyMac.mm:
3410         * WebProcess/Plugins/Netscape/NetscapePlugin.h:
3411         * WebProcess/Plugins/PDF/SimplePDFPlugin.h:
3412         * WebProcess/Plugins/Plugin.h:
3413         * WebProcess/Plugins/PluginProxy.h:
3414         * WebProcess/Plugins/PluginView.h:
3415         * WebProcess/WebPage/WebPage.h:
3416         * WebProcess/WebPage/WebPage.messages.in:
3417         * WebProcess/WebPage/mac/WebPageMac.mm:
3418
3419 2013-07-24  Jessie Berlin  <jberlin@apple.com>
3420
3421         Remove WKPageGetPlugInInformation - it is not used anymore
3422         https://bugs.webkit.org/show_bug.cgi?id=119047
3423
3424         Rubber-stamped by Alexey Proskuryakov.
3425
3426         Revert r152328, which added a key used only in the callback info for
3427         WKPageGetPlugInInformation.
3428
3429         * Shared/API/c/WKPluginInformation.cpp:
3430         * Shared/API/c/WKPluginInformation.h:
3431         * Shared/Plugins/Netscape/PluginInformation.cpp:
3432         * Shared/Plugins/Netscape/PluginInformation.h:
3433         * UIProcess/WebPageProxy.h:
3434         * UIProcess/WebPageProxy.messages.in:
3435         * UIProcess/mac/WebPageProxyMac.mm:
3436         (WebKit::WebPageProxy::containsPlugInCallback):
3437         * WebProcess/WebPage/mac/WebPageMac.mm:
3438         (WebKit::WebPage::containsPluginViewsWithPluginProcessToken):
3439
3440 2013-07-24  Anton Obzhirov  <a.obzhirov@samsung.com>
3441
3442         [GTK] TestInspectorServer unit test is timing out
3443         https://bugs.webkit.org/show_bug.cgi?id=105866
3444
3445         Reviewed by Gustavo Noronha Silva.
3446
3447         The test failed because it couldn't find inspector resources in default folder
3448         (make install step was missing). It uses now resources available in
3449         WebKitBuild folder. WebInspectorServerGtk was refactored as well to make
3450         easier to use WEBKIT_INSPECTOR_SERVER_PATH variable.
3451
3452         * UIProcess/API/gtk/tests/GNUmakefile.am:
3453         * UIProcess/API/gtk/tests/InspectorTestServer.cpp:
3454         (main):
3455         * UIProcess/API/gtk/tests/TestInspectorServer.cpp:
3456         (testInspectorServerPageList):
3457         * UIProcess/InspectorServer/gtk/WebInspectorServerGtk.cpp:
3458         (WebKit::WebInspectorServer::platformResourceForPath):
3459         (WebKit::WebInspectorServer::buildPageList):
3460         (WebKit::WebInspectorServer::inspectorServerFilesPath):
3461
3462 2013-07-23  Simon Cooper  <scooper@apple.com>
3463
3464         10.7: Java applets do not work due to sandbox violation/exception
3465         https://bugs.webkit.org/show_bug.cgi?id=118920
3466         <rdar://problem/14471541&12910934&14223830&14260729&14267679>
3467
3468         Reviewed by Alexey Proskuryakov.
3469
3470         Introduce versioning into the common profile and use it to fix
3471         a number of issues with Java on 10.7 and 10.8. Allow writing the
3472         com.apple.java.util.prefs preference file. This change also
3473         introduces a "/Library/Application Support/Java/PublicFiles"
3474         area which Java can read without any restrictions. Files written
3475         to this location will need to be created and written to by
3476         a privileged process.
3477
3478         * Resources/PlugInSandboxProfiles/com.apple.WebKit.plugin-common.sb:
3479         * Resources/PlugInSandboxProfiles/com.oracle.java.JavaAppletPlugin.sb:
3480
3481 2013-07-23  Eunmi Lee  <eunmi15.lee@samsung.com>
3482
3483         [EFL][WK2] Add doneWithTouchEvent callback to the WKViewClient.
3484         https://bugs.webkit.org/show_bug.cgi?id=110085
3485
3486         Reviewed by Kenneth Rohde Christiansen.
3487
3488         Add doneWithTouchEvent callback to the WKViewClient in order to get the
3489         result of touch events in the EwkView. The result will be used to
3490         recognize gestures in the Bug 102643.
3491
3492         APIs to get values from WKTouchEventRef and WKTouchPointRef are added
3493         because WKTypeRef is opaque to the applications.
3494
3495         * UIProcess/API/C/CoordinatedGraphics/WKView.h:
3496         * UIProcess/API/C/efl/WKAPICastEfl.h:
3497         (WebKit::toAPI):
3498         * UIProcess/API/C/efl/WKEventEfl.cpp:
3499         (WKTouchEventGetType):
3500         (WKTouchEventGetTouchPoints):
3501         (WKTouchEventGetModifiers):
3502         (WKTouchEventGetTimestamp):
3503         (WKTouchPointGetID):
3504         (WKTouchPointGetState):
3505         (WKTouchPointGetScreenPosition):
3506         (WKTouchPointGetPosition):
3507         (WKTouchPointGetRadius):
3508         (WKTouchPointGetRotationAngle):
3509         (WKTouchPointGetForceFactor):
3510         * UIProcess/API/C/efl/WKEventEfl.h:
3511         * UIProcess/API/efl/EwkView.cpp:
3512         (EwkView::doneWithTouchEvent):
3513         * UIProcess/API/efl/EwkView.h:
3514         * UIProcess/CoordinatedGraphics/WebView.cpp:
3515         (WebKit::WebView::doneWithTouchEvent):
3516         * UIProcess/CoordinatedGraphics/WebViewClient.cpp:
3517         (WebKit::WebViewClient::doneWithTouchEvent):
3518         * UIProcess/CoordinatedGraphics/WebViewClient.h:
3519         * UIProcess/efl/ViewClientEfl.cpp:
3520         (WebKit::ViewClientEfl::doneWithTouchEvent):
3521         (WebKit::ViewClientEfl::ViewClientEfl):
3522         * UIProcess/efl/ViewClientEfl.h:
3523
3524 2013-07-22  Alexey Proskuryakov  <ap@apple.com>
3525
3526         Frequent MESSAGE_CHECK failures in WebPageProxy::didReceiveEvent
3527         https://bugs.webkit.org/show_bug.cgi?id=118976
3528         <rdar://problem/14155030>
3529
3530         Reviewed by Sam Weinig.
3531
3532         * UIProcess/WebPageProxy.cpp: (WebKit::WebPageProxy::resetStateAfterProcessExited):
3533         Clear m_gestureEventQueue, just like we clear all other event queues here.
3534
3535 2013-07-21  Anders Carlsson  <andersca@apple.com>
3536
3537         Java Updater not launched on Lion and Mountain Lion
3538         https://bugs.webkit.org/show_bug.cgi?id=118953
3539         <rdar://problem/14496721>
3540
3541         Reviewed by Sam Weinig.
3542
3543         On Lion and Mountain Lion, -[NSURL isEqual:] will return NO for two file URLs if one of
3544         them has "localhost" specified, even if the paths are otherwise equal. Work around this by
3545         comparing the paths directly.
3546
3547         * UIProcess/Plugins/mac/PluginProcessProxyMac.mm:
3548         (WebKit::isJavaUpdaterURL):
3549
3550 2013-07-19  Morten Stenshorne  <mstensho@opera.com>
3551
3552         [GTK] Need a way to enable region based columns from the command line
3553         https://bugs.webkit.org/show_bug.cgi?id=116611
3554
3555         Reviewed by Martin Robinson.
3556
3557         Add an environment variable to enable experimental features.
3558
3559         This provides a means to enable experimental features without polluting
3560         the public API.
3561
3562         Environment variable name: WEBKITGTK_EXPERIMENTAL_FEATURES
3563
3564         Format: WEBKITGTK_EXPERIMENTAL_FEATURES="<feature1>=1,<feature2>=1,..."
3565         Or, to enable all experimental features: WEBKITGTK_EXPERIMENTAL_FEATURES=all
3566
3567         So far the only feature is region based columns (implement multicol using
3568         the CSS regions implementation rather than ColumnInfo & co) - REGION_BASED_COLUMNS.
3569
3570         Example: WEBKITGTK_EXPERIMENTAL_FEATURES="REGION_BASED_COLUMNS=1"
3571
3572         * GNUmakefile.list.am:
3573         * PlatformGTK.cmake:
3574         * UIProcess/API/gtk/WebKitSettings.cpp:
3575         (webKitSettingsConstructed):
3576         (webkit_settings_class_init):
3577         * UIProcess/gtk/ExperimentalFeatures.cpp: Added.
3578         (WebKit):
3579         (Setting):
3580         (WebKit::ExperimentalFeatures::ExperimentalFeatures):
3581         (WebKit::ExperimentalFeatures::isEnabled):
3582         (WebKit::ExperimentalFeatures::setEnableByName):
3583         (WebKit::ExperimentalFeatures::parseEnvironment):
3584         * UIProcess/gtk/ExperimentalFeatures.h: Added.
3585         (WebKit):
3586         (ExperimentalFeatures):
3587
3588 2013-07-18  Eunmi Lee  <eunmi15.lee@samsung.com>
3589
3590         [WK2] Share Qt port's codes to find zoomable area with CoordinatedGraphics.
3591         https://bugs.webkit.org/show_bug.cgi?id=118585
3592
3593         Reviewed by Anders Carlsson.
3594
3595         The function to find zoomable area is needed in order to implement the
3596         feature to scale for double-tap gesture. The WK2 EFL and NIX port want
3597         to use that function, so extract the code from the Qt port, make it
3598         usable in the CoordinatedGraphics and add API and callback.
3599
3600         * CMakeLists.txt:
3601         * Target.pri:
3602         * UIProcess/API/C/CoordinatedGraphics/WKView.cpp:
3603         (WKViewFindZoomableAreaForRect):
3604         * UIProcess/API/C/CoordinatedGraphics/WKView.h:
3605         * UIProcess/API/efl/EwkView.cpp:
3606         (EwkView::didFindZoomableArea):
3607         * UIProcess/API/efl/EwkView.h:
3608         * UIProcess/CoordinatedGraphics/WebPageProxyCoordinatedGraphics.cpp: Added.
3609         (WebKit::WebPageProxy::findZoomableAreaForPoint):
3610         (WebKit::WebPageProxy::didFindZoomableArea):
3611         * UIProcess/CoordinatedGraphics/WebView.cpp:
3612         (WebKit::WebView::didFindZoomableArea):
3613         (WebKit::WebView::findZoomableAreaForPoint):
3614         * UIProcess/CoordinatedGraphics/WebView.h:
3615         * UIProcess/CoordinatedGraphics/WebViewClient.cpp:
3616         (WebKit::WebViewClient::didFindZoomableArea):
3617         * UIProcess/CoordinatedGraphics/WebViewClient.h:
3618         * UIProcess/PageClient.h:
3619         * UIProcess/WebPageProxy.h:
3620         * UIProcess/WebPageProxy.messages.in:
3621         * UIProcess/efl/ViewClientEfl.cpp:
3622         (WebKit::ViewClientEfl::didFindZoomableArea):
3623         (WebKit::ViewClientEfl::ViewClientEfl):
3624         * UIProcess/efl/ViewClientEfl.h:
3625         * UIProcess/qt/WebPageProxyQt.cpp:
3626         * WebProcess/WebPage/CoordinatedGraphics/WebPageCoordinatedGraphics.cpp: Added.
3627         (WebKit::WebPage::findZoomableAreaForPoint):
3628         * WebProcess/WebPage/WebPage.cpp:
3629         * WebProcess/WebPage/WebPage.h:
3630         * WebProcess/WebPage/WebPage.messages.in:
3631
3632 2013-07-18  Simon Cooper  <scooper@apple.com>
3633
3634         Flash Player: deny file-read-data /Library/Application Support/Macromedia/FlashAuthor.cfg
3635         https://bugs.webkit.org/show_bug.cgi?id=118874
3636         <rdar://problem/14271327>
3637
3638         Reviewed by Alexey Proskuryakov.
3639
3640         Silently deny access to FlashAuthor.cfg. This location contains
3641         files containing lists of paths that Flash Player will
3642         "allow" access to (without asking the user). Since the plugin
3643         sandbox won't permit the access to the listed paths it is better
3644         to silently block attempts to read this "whitelist".
3645
3646         * Resources/PlugInSandboxProfiles/com.macromedia.Flash Player.plugin.sb:
3647
3648 2013-07-18  Tim Horton  <timothy_horton@apple.com>
3649
3650         [wk2] Ensure that the plugin layer is removed completely when the PluginProcess crashes
3651         https://bugs.webkit.org/show_bug.cgi?id=118862
3652
3653         Reviewed by Anders Carlsson.
3654
3655         * WebProcess/Plugins/PluginView.cpp:
3656         (WebKit::PluginView::PluginView):
3657         Add m_pluginProcessHasCrashed.
3658
3659         (WebKit::PluginView::platformLayer):
3660         Don't return the plugin's layer if it has crashed.
3661
3662         (WebKit::PluginView::pluginProcessCrashed):
3663         Set m_pluginProcessHasCrashed.
3664         Cause a style recalc so that we rebuild the layer tree; our layer won't be included.
3665
3666         * WebProcess/Plugins/PluginView.h:
3667         Add m_pluginProcessHasCrashed.
3668
3669 2013-07-18  Alexey Proskuryakov  <ap@apple.com>
3670
3671         <rdar://problem/13886443> Assertion failures in NetworkProcess in SandboxExtension::revoke when aborting SyncNetworkResourceLoader
3672         <rdar://problem/13826348> ASSERT(!m_useCount) fails in NetworkProcess at SandboxExtension::~SandboxExtension
3673         https://bugs.webkit.org/show_bug.cgi?id=118855
3674
3675         Reviewed by Brady Eidson.
3676
3677         * NetworkProcess/NetworkResourceLoader.cpp:
3678         (WebKit::NetworkResourceLoader::cleanup):
3679         (WebKit::NetworkResourceLoader::didFinishLoading):
3680         (WebKit::NetworkResourceLoader::didFail):
3681         Moved sandbox extension invalidation to cleanup() meaning that we won't fail to
3682         do this when aborting a loader that currently loading from network.
3683     
3684         * NetworkProcess/SchedulableLoader.cpp:
3685         (WebKit::SchedulableLoader::SchedulableLoader):
3686         (WebKit::SchedulableLoader::consumeSandboxExtensions):
3687         (WebKit::SchedulableLoader::invalidateSandboxExtensions):
3688         * NetworkProcess/SchedulableLoader.h:
3689         Keep track of whether sandbox extensions are consumed, we don't want to revoke
3690         extensions that were never consumed (as used to be the case with sync loaders,
3691         and would be with async ones after the above fix). Also, get rid of extensions
3692         immediately when invalidating, we won't need them again.
3693
3694 2013-07-18  Tim Horton  <timothy_horton@apple.com>
3695
3696         Remove PDFViewController and WKView "custom representations"
3697         https://bugs.webkit.org/show_bug.cgi?id=118720
3698
3699         Reviewed by Alexey Proskuryakov.
3700
3701         PDFViewController was the only implementation of
3702         a "custom representation" for a WKView. As it has
3703         been superceded by PDFPlugin, we can remove both
3704         PDFViewController and the notion of a WKView custom
3705         representation.
3706
3707         * UIProcess/API/gtk/PageClientImpl.cpp:
3708         * UIProcess/API/gtk/PageClientImpl.h:
3709         * UIProcess/API/mac/PDFViewController.h: Removed.
3710         * UIProcess/API/mac/PDFViewController.mm: Removed.
3711         * UIProcess/API/mac/PageClientImpl.h:
3712         * UIProcess/API/mac/PageClientImpl.mm:
3713         * UIProcess/API/mac/WKView.mm:
3714         (-[WKView accessibilityFocusedUIElement]):
3715         (-[WKView accessibilityHitTest:]):
3716         (-[WKView accessibilityAttributeValue:]):
3717         (-[WKView printOperationWithPrintInfo:forFrame:]):
3718         * UIProcess/API/mac/WKViewInternal.h:
3719         * UIProcess/API/qt/raw/qrawwebview_p_p.h:
3720         * UIProcess/CoordinatedGraphics/WebView.cpp:
3721         * UIProcess/CoordinatedGraphics/WebView.h:
3722         * UIProcess/DrawingAreaProxy.h:
3723         * UIProcess/DrawingAreaProxyImpl.cpp:
3724         * UIProcess/DrawingAreaProxyImpl.h:
3725         * UIProcess/PageClient.h:
3726         * UIProcess/WebPageProxy.cpp:
3727         (WebKit::WebPageProxy::WebPageProxy):
3728         (WebKit::WebPageProxy::supportsTextEncoding):
3729         (WebKit::WebPageProxy::supportsTextZoom):
3730         (WebKit::WebPageProxy::setTextZoomFactor):
3731         (WebKit::WebPageProxy::setPageZoomFactor):
3732         (WebKit::WebPageProxy::setPageAndTextZoomFactors):
3733         (WebKit::WebPageProxy::findString):
3734         (WebKit::WebPageProxy::countStringMatches):
3735         (WebKit::WebPageProxy::didCommitLoadForFrame):
3736         * UIProcess/WebPageProxy.h:
3737         (WebKit::WebPageProxy::textZoomFactor):
3738         (WebKit::WebPageProxy::pageZoomFactor):
3739         * UIProcess/WebPageProxy.messages.in:
3740         * UIProcess/qt/QtPageClient.h:
3741         * WebKit2.xcodeproj/project.pbxproj:
3742         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
3743         (WebKit::WebFrameLoaderClient::WebFrameLoaderClient):
3744         (WebKit::WebFrameLoaderClient::dispatchDidCommitLoad):
3745         (WebKit::WebFrameLoaderClient::committedLoad):
3746         (WebKit::WebFrameLoaderClient::finishedLoading):
3747         (WebKit::WebFrameLoaderClient::transitionToCommittedFromCachedFrame):
3748         (WebKit::WebFrameLoaderClient::transitionToCommittedForNewPage):
3749         * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
3750         * WebProcess/WebPage/DrawingArea.h:
3751         * WebProcess/WebPage/DrawingArea.messages.in:
3752         * WebProcess/WebPage/DrawingAreaImpl.cpp:
3753         (WebKit::DrawingAreaImpl::setNeedsDisplayInRect):
3754         (WebKit::DrawingAreaImpl::scroll):
3755         (WebKit::DrawingAreaImpl::exitAcceleratedCompositingMode):
3756         (WebKit::DrawingAreaImpl::display):
3757         * WebProcess/WebPage/DrawingAreaImpl.h:
3758         * WebProcess/WebPage/WebPage.cpp:
3759         * WebProcess/WebPage/WebPage.h:
3760         * WebProcess/WebPage/mac/WebPageMac.mm:
3761         (WebKit::WebPage::platformPreferencesDidChange):
3762         * mac/WebKit2.order:
3763
3764 2013-07-18  Dong-Gwan Kim  <donggwan.kim@samsung.com>
3765
3766         [EFL][WK2] Replace mouseClick with more meaningful method in test_ewk2_color_picker.cpp
3767         https://bugs.webkit.org/show_bug.cgi?id=118797
3768
3769         Reviewed by Christophe Dumez.
3770
3771         Some mouseClick methods are used in test_ewk2_color_picker.cpp.
3772         But it is difficult to understand what they mean.
3773         So i would like to replace those with more meaningful method for readability.
3774
3775         * UIProcess/API/efl/tests/test_ewk2_color_picker.cpp:
3776         (EWK2ColorPickerTest::clickButton):
3777         (TEST_F):
3778
3779 2013-07-18  Eunmi Lee  <eunmi15.lee@samsung.com>
3780
3781         [WK2] Replace getRect() to pixelSnappedBoundingBox().
3782         https://bugs.webkit.org/show_bug.cgi?id=118588
3783
3784         Reviewed by Noam Rosenthal.
3785
3786         The Node::getRect() function was removed in the
3787         http://trac.webkit.org/changeset/128006, so use
3788         pixelSnappedBoundingBox() instead.
3789
3790         * WebProcess/WebPage/WebPage.cpp:
3791         (WebKit::WebPage::findZoomableAreaForPoint):
3792
3793 2013-07-18  Dong-Gwan Kim  <donggwan.kim@samsung.com>
3794
3795         [EFL][WK2] Replace mouseClick with more meaningful method in test_ewk2_context_menu.cpp
3796         https://bugs.webkit.org/show_bug.cgi?id=118796
3797
3798         Reviewed by Christophe Dumez.
3799
3800         Some mouseClick methods are used in test_ewk2_context_menu.cpp.
3801         But it is difficult to understand what they mean.
3802         So i would like to replace those with more meaningful method for readability.
3803
3804         * UIProcess/API/efl/tests/test_ewk2_context_menu.cpp:
3805         (EWK2ContextMenuTest::testContextMenu):
3806         (EWK2ContextMenuTest::testContextMenuForRemoveAndAppend):
3807         (EWK2ContextMenuTest::testContextMenuForSubmenu):
3808         (EWK2ContextMenuTest::finishTest):
3809         (EWK2ContextMenuTest::showContextMenu):
3810         (TEST_F):
3811
3812 2013-07-18  Dong-Gwan Kim  <donggwan.kim@samsung.com>
3813
3814         [EFL][WK2] Replace mouseClick with more meaningful method in test_ewk2_file_chooser_request.cpp
3815         https://bugs.webkit.org/show_bug.cgi?id=118792
3816
3817         Reviewed by Christophe Dumez.
3818
3819         Some mouseClick methods are used in test_ewk2_file_chooser_request.cpp.
3820         But it is difficult to understand what they mean.
3821         So i would like to replace those with more meaningful method for readability.
3822
3823         * UIProcess/API/efl/tests/test_ewk2_file_chooser_request.cpp:
3824         (EWK2FileChooserRequestTest::clickFileInput):
3825         (TEST_F):
3826
3827 2013-07-18  Dong-Gwan Kim  <donggwan.kim@samsung.com>
3828
3829         [EFL][WK2] Move all the static methods into EWK2TextCheckerTest in test_ewk2_text_checker.cpp
3830         https://bugs.webkit.org/show_bug.cgi?id=118790
3831
3832         Reviewed by Christophe Dumez.
3833
3834         All the static methods should be moved to EWK2TextCheckerTest.
3835
3836         * UIProcess/API/efl/tests/test_ewk2_text_checker.cpp:
3837         (EWK2TextCheckerTest::resetCallbacksExecutionStats):
3838         (EWK2TextCheckerTest::onTimeout):
3839         (EWK2TextCheckerTest::onSettingChange):
3840         (EWK2TextCheckerTest::onSpellDocumentTag):
3841         (EWK2TextCheckerTest::onSpellDocumentTagClose):
3842         (EWK2TextCheckerTest::onSpellingCheck):
3843         (EWK2TextCheckerTest::onSpellingForKnownWord):
3844         (EWK2TextCheckerTest::onWordGuesses):
3845         (EWK2TextCheckerTest::onWordLearn):
3846         (EWK2TextCheckerTest::onWordIgnore):
3847         (EWK2TextCheckerTest::findContextMenuItem):
3848         (EWK2TextCheckerTest::checkCorrectnessOfSpellingItems):
3849         (EWK2TextCheckerTest::toogleCheckSpellingWhileTyping):
3850         (EWK2TextCheckerTest::checkClientSuggestionsForWord):
3851         (EWK2TextCheckerTest::selectLearnSpelling):
3852         (EWK2TextCheckerTest::selectIgnoreSpelling):
3853         (EWK2TextCheckerTest::countContextMenuItems):
3854         (EWK2TextCheckerTest::clickButton):
3855         (EWK2TextCheckerTest::showContextMenu):
3856         (EWK2TextCheckerTest::selectFirstWord):
3857
3858 2013-07-17  Tim Horton  <timothy_horton@apple.com>
3859
3860         Update blocked/missing plug-in UI
3861         https://bugs.webkit.org/show_bug.cgi?id=118347
3862         <rdar://problem/14209318>
3863
3864         Reviewed by Sam Weinig.
3865
3866         * Platform/CoreIPC/HandleMessage.h:
3867         (CoreIPC::callMemberFunction):
3868         Add a 6 argument -> 4 reply message handler.
3869         (It seems that FindPlugin is getting a little out of hand.)
3870
3871         * Shared/APIClientTraits.cpp:
3872         * Shared/APIClientTraits.h:
3873         * UIProcess/API/C/WKPage.h:
3874         * UIProcess/WebLoaderClient.cpp:
3875         (WebKit::WebLoaderClient::pluginLoadPolicy):
3876         * UIProcess/WebLoaderClient.h:
3877         Add an unavailability description out-argument to a new version of
3878         pluginLoadPolicy, so clients can override the text of the unavailable
3879         plugin indicator. Bump the WKPageLoaderClient version and update APIClientTraits.
3880
3881         * UIProcess/WebPageProxy.cpp:
3882         (WebKit::WebPageProxy::findPlugin):
3883         * UIProcess/WebPageProxy.h:
3884         * UIProcess/WebPageProxy.messages.in:
3885         Plumb the unavailability description through to the WebProcess via
3886         the FindPlugin message.
3887
3888         * WebProcess/WebPage/WebPage.cpp:
3889         (WebKit::WebPage::createPlugin):
3890         Acquire the unavailability description from the client
3891         (via FindPlugin) and hand it to the RenderEmbeddedObject.
3892
3893 2013-07-17  Commit Queue  <commit-queue@webkit.org>
3894
3895         Unreviewed, rolling out r152701, r152703, r152739, r152754,
3896         and r152756.
3897         http://trac.webkit.org/changeset/152701
3898         http://trac.webkit.org/changeset/152703
3899         http://trac.webkit.org/changeset/152739
3900         http://trac.webkit.org/changeset/152754
3901         http://trac.webkit.org/changeset/152756
3902         https://bugs.webkit.org/show_bug.cgi?id=118821
3903
3904         this was a buggy fix and we're going to try something
3905         different (Requested by thorton on #webkit).
3906
3907         * Platform/CoreIPC/HandleMessage.h:
3908         * Shared/APIClientTraits.cpp:
3909         * Shared/APIClientTraits.h:
3910         * UIProcess/API/C/WKPage.h:
3911         * UIProcess/WebLoaderClient.cpp:
3912         (WebKit::WebLoaderClient::pluginLoadPolicy):
3913         * UIProcess/WebLoaderClient.h:
3914         * UIProcess/WebPageProxy.cpp:
3915         (WebKit::WebPageProxy::findPlugin):
3916         * UIProcess/WebPageProxy.h:
3917         * UIProcess/WebPageProxy.messages.in:
3918         * WebProcess/Plugins/PluginProcessConnection.cpp:
3919         (WebKit::PluginProcessConnection::didClose):
3920         * WebProcess/Plugins/PluginView.cpp:
3921         (WebKit::PluginView::pluginProcessCrashed):
3922         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
3923         (WebKit::WebChromeClient::shouldUnavailablePluginMessageBeButton):
3924         * WebProcess/WebCoreSupport/WebChromeClient.h:
3925         * WebProcess/WebPage/WebPage.cpp:
3926         (WebKit::WebPage::createPlugin):
3927         (WebKit::WebPage::canPluginHandleResponse):
3928
3929 2013-07-17  Alexey Proskuryakov  <ap@apple.com>
3930
3931         [Mac] Crashes in CFURLGetBytes under WebProcess::updateActivePages()
3932         https://bugs.webkit.org/show_bug.cgi?id=118814
3933         <rdar://problem/14173389>
3934
3935         Reviewed by Brady Eidson.
3936
3937         Speculative fix. It's unclear how we end up with an invalid URL when committing
3938         a load.
3939
3940         * WebProcess/mac/WebProcessMac.mm: (WebKit::WebProcess::updateActivePages):
3941         Added a null check.
3942
3943 2013-07-17  Commit Queue  <commit-queue@webkit.org>
3944
3945         Unreviewed, rolling out r152786 and r152789.
3946         http://trac.webkit.org/changeset/152786
3947         http://trac.webkit.org/changeset/152789
3948         https://bugs.webkit.org/show_bug.cgi?id=118807
3949
3950         overly platform specific and dirty API (and Sam says no)
3951         (Requested by thorton on #webkit).
3952
3953         * WebProcess/InjectedBundle/API/c/WKBundlePageOverlay.cpp:
3954         * WebProcess/InjectedBundle/API/c/WKBundlePageOverlay.h:
3955         * WebProcess/WebPage/PageOverlay.cpp:
3956         * WebProcess/WebPage/PageOverlay.h:
3957         * WebProcess/WebPage/WebPage.cpp:
3958         * WebProcess/WebPage/WebPage.h:
3959         * WebProcess/WebPage/mac/WKAccessibilityWebPageObject.mm:
3960
3961 2013-07-17  Tim Horton  <timothy_horton@apple.com>
3962
3963         AX: VoiceOver not working with data detection page overlays
3964         https://bugs.webkit.org/show_bug.cgi?id=118680
3965
3966         Reviewed by Anders Carlsson.
3967
3968         Bump the API version after r152786.
3969
3970         * WebProcess/InjectedBundle/API/c/WKBundlePageOverlay.h:
3971
3972 2013-07-17  Simon Cooper  <scooper@apple.com>
3973
3974         YouTube webcam capture (Flash Plug-in) in Safari can't see built-in camera
3975         https://bugs.webkit.org/show_bug.cgi?id=118787
3976         <rdar://problem/14418799>
3977
3978         Reviewed by Alexey Proskuryakov.
3979
3980         Add support for built-in cameras, including the original iSight.
3981
3982         * Resources/PlugInSandboxProfiles/com.apple.WebKit.plugin-common.sb:
3983         * Resources/PlugInSandboxProfiles/com.macromedia.Flash Player.plugin.sb:
3984
3985 2013-07-17  Chris Fleizach  <cfleizach@apple.com>
3986
3987         AX: VoiceOver not working with data detection page overlays
3988         https://bugs.webkit.org/show_bug.cgi?id=118680
3989
3990         Reviewed by Tim Horton.
3991
3992         Expose API methods so that a client implementing data detectors is able to respond
3993         to the needs of accessibility clients like VoiceOver.
3994
3995         * WebProcess/InjectedBundle/API/c/WKBundlePageOverlay.cpp:
3996         (PageOverlayClientImpl::supportsDataDetection):
3997         (PageOverlayClientImpl::dataDetectorExistsAtPoint):
3998         (PageOverlayClientImpl::dataDetectorCopyTypeAtPoint):
3999         (PageOverlayClientImpl::showDataDetectorMenuAtPoint):
4000         * WebProcess/InjectedBundle/API/c/WKBundlePageOverlay.h:
4001         * WebProcess/WebPage/PageOverlay.cpp:
4002         (WebKit::PageOverlay::supportsDataDetection):
4003         (WebKit::PageOverlay::dataDetectorExistsAtPoint):
4004         (WebKit::PageOverlay::dataDetectorCopyTypeAtPoint):
4005         (WebKit::PageOverlay::dataDetectorOpenMenuAtPoint):
4006         * WebProcess/WebPage/PageOverlay.h:
4007         (WebKit::PageOverlay::Client::supportsDataDetection):
4008         (WebKit::PageOverlay::Client::dataDetectorExistsAtPoint):
4009         (WebKit::PageOverlay::Client::dataDetectorCopyTypeAtPoint):
4010         (WebKit::PageOverlay::Client::showDataDetectorMenuAtPoint):
4011         * WebProcess/WebPage/WebPage.cpp:
4012         (WebKit::WebPage::pageOverlayOpenDataDetectorMenuAtPoint):
4013         (WebKit::WebPage::pageOverlayDataDetectorCopyTypeAtPoint):
4014         (WebKit::WebPage::pageOverlayDataDetectorExistsAtPoint):
4015         (WebKit::WebPage::pageOverlaySupportsDataDetection):
4016         * WebProcess/WebPage/WebPage.h:
4017         * WebProcess/WebPage/mac/WKAccessibilityWebPageObject.mm:
4018         (-[WKAccessibilityWebPageObject accessibilityParameterizedAttributeNames]):
4019         (-[WKAccessibilityWebPageObject _convertScreenPointToWindow:]):
4020         (-[WKAccessibilityWebPageObject accessibilityAttributeValue:forParameter:]):
4021
4022 2013-07-17  Dong-Gwan Kim  <donggwan.kim@samsung.com>
4023
4024         [EFL][WK2] EWK2CookieManagerTest should be defined by inheriting from EWK2UnitTestBase.
4025         https://bugs.webkit.org/show_bug.cgi?id=118721
4026
4027         Reviewed by Christophe Dumez.
4028
4029         It should be defined as relevant test class specific to each test file for more readability.
4030         It could be helpful to remove unnecessary static methods.
4031
4032         * UIProcess/API/efl/tests/test_ewk2_cookie_manager.cpp:
4033         (compareHostNames):
4034         (onCookiesChanged):
4035         (EWK2CookieManagerTest::getAcceptPolicy):
4036         (EWK2CookieManagerTest::getHostnamesWithCookies):
4037         (EWK2CookieManagerTest::freeHostNames):
4038         (EWK2CookieManagerTest::countHostnamesWithCookies):
4039         (TEST_F):
4040
4041 2013-07-16  Balazs Kelemen  <kbalazs@webkit.org>
4042
4043         [CMake] Undefined references should be detected at build time
4044         https://bugs.webkit.org/show_bug.cgi?id=110236
4045
4046         Reviewed by Christophe Dumez.
4047
4048         Add library dependencies that were not defined explicitly before.
4049
4050         * CMakeLists.txt:
4051         * PlatformEfl.cmake:
4052
4053 2013-07-17  Dong-Gwan Kim  <donggwan.kim@samsung.com>
4054
4055         [EFL][WK2] EWK2WindowFeaturesTest should be defined by inheriting from EWK2UnitTestBase.
4056         https://bugs.webkit.org/show_bug.cgi?id=118780
4057
4058         Reviewed by Christophe Dumez.
4059
4060         It should be defined as relevant test class specific to each test file for more readability.
4061         It could be helpful to remove unnecessary static methods.
4062
4063         * UIProcess/API/efl/tests/test_ewk2_window_features.cpp:
4064         (EWK2WindowFeaturesTest::createDefaultWindow):
4065         (EWK2WindowFeaturesTest::createWindow):
4066         (TEST_F):
4067
4068 2013-07-17  Dong-Gwan Kim  <donggwan.kim@samsung.com>
4069
4070         [EFL][WK2] EWK2ViewTest should be defined by inheriting from EWK2UnitTestBase.
4071         https://bugs.webkit.org/show_bug.cgi?id=118779
4072
4073         Reviewed by Christophe Dumez.
4074
4075         It should be defined as relevant test class specific to each test file for more readability.
4076         It could be helpful to remove unnecessary static methods.
4077
4078         * UIProcess/API/efl/tests/test_ewk2_view.cpp:
4079         (EWK2ViewTest::onLoadFinishedForRedirection):
4080         (EWK2ViewTest::serverCallbackNavigation):
4081         (EWK2ViewTest::onFormAboutToBeSubmitted):
4082         (EWK2ViewTest::fullScreenCallback):
4083         (EWK2ViewTest::fullScreenExitCallback):
4084         (EWK2ViewTest::checkAlert):
4085         (EWK2ViewTest::checkConfirm):
4086         (EWK2ViewTest::checkPrompt):
4087         (EWK2ViewTest::onTextFound):
4088         (EWK2ViewTest::onVibrate):
4089         (EWK2ViewTest::onCancelVibration):
4090         (EWK2ViewTest::loadVibrationHTMLString):
4091         (EWK2ViewTest::onContentsSizeChangedPortrait):
4092         (EWK2ViewTest::onContentsSizeChangedLandscape):
4093         (EWK2ViewTest::PageContentsAsMHTMLCallback):
4094         (EWK2ViewTest::PageContentsAsStringCallback):
4095         (TEST_F):
4096
4097 2013-07-17  Dong-Gwan Kim  <donggwan.kim@samsung.com>
4098
4099         [EFL][WK2] EWK2StorageManagerTest should be defined by inheriting from EWK2UnitTestBase.
4100         https://bugs.webkit.org/show_bug.cgi?id=118777
4101
4102         Reviewed by Christophe Dumez.
4103
4104         It should be defined as relevant test class specific to each test file for more readability.
4105         It could be helpful to remove unnecessary static methods.
4106
4107         * UIProcess/API/efl/tests/test_ewk2_storage_manager.cpp:
4108         (EWK2StorageManagerTest::OriginData::OriginData):
4109         (EWK2StorageManagerTest::getStorageOriginsCallback):
4110         (EWK2StorageManagerTest::timerCallback):
4111         (EWK2StorageManagerTest::checkOrigin):