Pass the right color space over to the web process so we can set it on our CA context
[WebKit-https.git] / Source / WebKit2 / ChangeLog
1 2012-06-11  Anders Carlsson  <andersca@apple.com>
2
3         Pass the right color space over to the web process so we can set it on our CA context
4         https://bugs.webkit.org/show_bug.cgi?id=88819
5         <rdar://problem/11629050>
6
7         Reviewed by John Sullivan.
8
9         * Platform/mac/LayerHostingContext.h:
10         (LayerHostingContext):
11         * Platform/mac/LayerHostingContext.mm:
12         (WebKit::LayerHostingContext::createForPort):
13         (WebKit::LayerHostingContext::createForWindowServer):
14         Use a single constructor and explicitly set up the parameters of the constructed object.
15
16         (WebKit::LayerHostingContext::setColorSpace):
17         (WebKit::LayerHostingContext::colorSpace):
18         Add getter and setter.
19
20         * Scripts/webkit2/messages.py:
21         (struct_or_class):
22         WebKit::ColorSpaceData is a struct.
23
24         * Shared/WebPageCreationParameters.cpp:
25         Encode and decode the color space parameter.
26
27         * Shared/WebPageCreationParameters.h:
28         Add the color space.
29
30         * Shared/mac/ColorSpaceData.h: Added.
31         * Shared/mac/ColorSpaceData.mm: Added.
32         Add a new class that represents a color space that can be sent over the wire.
33
34         * UIProcess/API/mac/PageClientImpl.h:
35         * UIProcess/API/mac/PageClientImpl.mm:
36         (WebKit::PageClientImpl::colorSpace):
37         Call through to the WKView.
38
39         * UIProcess/API/mac/WKView.mm:
40         (-[WKView _windowDidChangeBackingProperties:]):
41         Fix whitespace.
42
43         (-[WKView viewDidChangeBackingProperties]):
44         Check if our new color space is different from the current one and null the current one out if that is the case,
45         it will be reinitialized by the next call to -[WKView _colorSpace].
46         
47         (-[WKView _colorSpace:]):
48         Compute the color space. If we're not in a window we'll get the main screen's color space.
49
50         * UIProcess/DrawingAreaProxy.h:
51         (WebKit::DrawingAreaProxy::colorSpaceDidChange):
52         Add empty stub.
53
54         * UIProcess/PageClient.h:
55         Add colorSpace getter.
56
57         * UIProcess/WebPageProxy.cpp:
58         (WebKit::WebPageProxy::creationParameters):
59         Initialize the color space.
60
61         * UIProcess/mac/TiledCoreAnimationDrawingAreaProxy.h:
62         * UIProcess/mac/TiledCoreAnimationDrawingAreaProxy.mm:
63         (WebKit::TiledCoreAnimationDrawingAreaProxy::colorSpaceDidChange):
64         Send the new color space over to the web process.
65
66         * UIProcess/mac/WebPageProxyMac.mm:
67         (WebKit::WebPageProxy::colorSpace):
68         Call through to the page client.
69
70         * WebKit2.xcodeproj/project.pbxproj:
71         Add ColorSpaceData.h and ColorSpaceData.mm.
72
73         * WebProcess/WebPage/DrawingArea.h:
74         * WebProcess/WebPage/DrawingArea.messages.in:
75         Add SetColorSpace message.
76
77         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
78         (WebKit::TiledCoreAnimationDrawingArea::TiledCoreAnimationDrawingArea):
79         Set the color space from the creation parameters.
80
81         (WebKit::TiledCoreAnimationDrawingArea::setColorSpace):
82         Set the color space on the layer hosting context.
83
84         (WebKit::TiledCoreAnimationDrawingArea::updateLayerHostingContext):
85         Make sure we apply the color space from the previous layer hosting context if one exists.
86
87 2012-06-11  Anders Carlsson  <andersca@apple.com>
88
89         Crash when a plug-in tries to use the NPRuntime API with JavaScript disabled
90         https://bugs.webkit.org/show_bug.cgi?id=88797
91         <rdar://problem/11574844>
92
93         Reviewed by Brady Eidson.
94
95         * PluginProcess/PluginControllerProxy.cpp:
96         (WebKit::PluginControllerProxy::initialize):
97         Handle the windowNPObjectID being 0.
98
99         (WebKit::PluginControllerProxy::windowScriptNPObject):
100         Handle m_windownPObject being null.
101
102         * WebProcess/Plugins/PluginView.cpp:
103         (WebKit::PluginView::windowScriptNPObject):
104         Return null if JavaScript is disabled.
105
106         (WebKit::PluginView::pluginElementNPObject):
107         Ditto.
108
109 2012-06-11  Kenneth Rohde Christiansen  <kenneth@webkit.org>
110
111         Add QML api for setting device width and height
112         https://bugs.webkit.org/show_bug.cgi?id=88777
113
114         Reviewed by Simon Hausmann.
115
116         Add the new API and set the default values to 0 (unset). The
117         current values were introduced by Qt and only Qt depends on them.
118
119         * Shared/WebPreferencesStore.h:
120         (WebKit):
121         * UIProcess/API/qt/qquickwebview.cpp:
122         (QQuickWebViewExperimental::deviceWidth):
123         (QQuickWebViewExperimental::setDeviceWidth):
124         (QQuickWebViewExperimental::deviceHeight):
125         (QQuickWebViewExperimental::setDeviceHeight):
126         * UIProcess/API/qt/qquickwebview_p.h:
127         * UIProcess/qt/QtViewportHandler.cpp:
128         (WebKit::QtViewportHandler::viewportItemSizeChanged):
129         * WebProcess/WebPage/WebPage.cpp:
130         (WebKit::WebPage::sendViewportAttributesChanged):
131
132 2012-06-11  Michael Brüning  <michael.bruning@nokia.com>
133
134         [Qt][WK2] Compute and set cache capacities using the current CacheModel
135         https://bugs.webkit.org/show_bug.cgi?id=73918
136
137         Reviewed by Kenneth Rohde Christiansen.
138
139         Added implementation of cache model for Qt WK 2 port including supporting
140         functionality such as WebProcess creation parameters and default values
141         for disk cache directories.
142
143         * Shared/WebProcessCreationParameters.cpp:
144         (WebKit::WebProcessCreationParameters::encode):
145         (WebKit::WebProcessCreationParameters::decode):
146         * Shared/WebProcessCreationParameters.h:
147         (WebProcessCreationParameters):
148         * UIProcess/qt/WebContextQt.cpp:
149         (WebKit::defaultDiskCacheDirectory):
150         (WebKit):
151         (WebKit::WebContext::platformInitializeWebProcess):
152         * WebProcess/qt/WebProcessQt.cpp:
153         (WebKit::physicalMemorySizeInBytes):
154         (WebKit::WebProcess::platformSetCacheModel):
155         (WebKit::WebProcess::platformInitializeWebProcess):
156
157 2012-06-10  Darin Adler  <darin@apple.com>
158
159         Remove unneeded callRemovedLastRef function from TreeShared refactoring
160         https://bugs.webkit.org/show_bug.cgi?id=88653
161
162         Reviewed by Sam Weinig.
163
164         * win/WebKit2.def: Export removedLastRef instead of callRemovedLastRef.
165         * win/WebKit2CFLite.def: Ditto.
166
167 2012-06-10  Ryuan Choi  <ryuan.choi@samsung.com>
168
169         [EFL][WK2] Add and refactor ewk API in order to support MiniBrowser without WK API.
170         https://bugs.webkit.org/show_bug.cgi?id=84124
171
172         Reviewed by Chang Shu.
173
174         Modify ewk_view and add ewk_context to provide a platform-depedent WebKit2
175         API.
176         This patch provides the minimum to support MiniBrowser.
177
178         * PlatformEfl.cmake: add ewk_context.cpp.
179         * UIProcess/API/efl/EWebKit2.h: Added.
180         * UIProcess/API/efl/ewk_context.cpp: Added.
181         (_Ewk_Context):
182         (createDefaultWebContext):
183         (ewk_context_WKContext_get):
184         (ewk_context_default_get):
185         * UIProcess/API/efl/ewk_context.h: Added.
186         * UIProcess/API/efl/ewk_context_private.h: Added.
187         * UIProcess/API/efl/ewk_view.cpp:
188         (_Ewk_View_Private_Data):
189         (_ewk_view_priv_del):
190         (ewk_view_base_add):
191         (ewk_view_add_with_context):
192         (ewk_view_add):
193         (ewk_view_uri_set):
194         (ewk_view_uri_get):
195         * UIProcess/API/efl/ewk_view.h:
196         * UIProcess/API/efl/ewk_view_private.h:
197
198 2012-06-09  Sukolsak Sakshuwong  <sukolsak@google.com>
199
200         Add UNDO_MANAGER flag
201         https://bugs.webkit.org/show_bug.cgi?id=87908
202
203         Reviewed by Tony Chang.
204
205         * Configurations/FeatureDefines.xcconfig:
206
207 2012-06-08  Brent Fulgham  <bfulgham@webkit.org>
208         [WinCairo] Build fix after Windows export definition file change.
209
210         * win/WebKit2CFLite.def: This file needs to be kept in sync with
211         WebKit2.def (aside from the WebKitInterface exports.)
212
213 2012-06-08  Viatcheslav Ostapenko  <ostapenko.viatcheslav@nokia.com>
214
215         [Qt] [WK2] API tests randomly assert in WebLayerTreeRenderer::assignImageToLayer
216         https://bugs.webkit.org/show_bug.cgi?id=88667
217
218         Reviewed by Noam Rosenthal.
219
220         Move deactivation of WebLayerTreeRenderer from LayerTreeHostProxy::purgeBackingStores 
221         to WebLayerTreeRenderer::purgeGLResources. LayerTreeHostProxy::purgeBackingStores is 
222         invoked on main thread after going through call gate and it is too late to deactivate
223         renderer here, because some update messages are able to go through. 
224         WebLayerTreeRenderer::purgeGLResources is called directly from render node deallocation
225         and it is right place to deactivate renderer.
226
227         * UIProcess/LayerTreeHostProxy.cpp:
228         (WebKit::LayerTreeHostProxy::purgeBackingStores):
229         * UIProcess/WebLayerTreeRenderer.cpp:
230         (WebKit::WebLayerTreeRenderer::purgeGLResources):
231
232 2012-06-08  Carlos Garcia Campos  <cgarcia@igalia.com>
233
234         [GTK] Add API to get the library version to WebKit2 GTK+
235         https://bugs.webkit.org/show_bug.cgi?id=88426
236
237         Reviewed by Martin Robinson.
238
239         * GNUmakefile.am:
240         * GNUmakefile.list.am:
241         * UIProcess/API/gtk/WebKitVersion.cpp: Added.
242         (webkit_get_major_version):
243         (webkit_get_minor_version):
244         (webkit_get_micro_version):
245         * UIProcess/API/gtk/WebKitVersion.h.in: Added.
246         * UIProcess/API/gtk/docs/webkit2gtk-docs.sgml: Add new symbols.
247         * UIProcess/API/gtk/docs/webkit2gtk-sections.txt: Add new section
248         for WebKitVersion.
249         * UIProcess/API/gtk/tests/GNUmakefile.am:
250         * UIProcess/API/gtk/tests/TestWebKitVersion.cpp: Added.
251         (testWebKitVersion):
252         (testWebKitCheckVersion):
253         (beforeAll):
254         (afterAll):
255         * UIProcess/API/gtk/webkit2.h: Include WebKitVersion.h.
256
257 2012-06-08  Dan Bernstein  <mitz@apple.com>
258
259         Tried to fix the Snow Leopard build after r119806.
260
261         * WebKit2Prefix.h:
262
263 2012-06-08  Andy Estes  <aestes@apple.com>
264
265         [WebKit2] Move Mac-specific bits from config.h to WebKit2Prefix.h
266         https://bugs.webkit.org/show_bug.cgi?id=88625
267
268         Reviewed by Dan Bernstein.
269
270         Since the Mac supports prefix headers, there is no point in having
271         Mac-specific code in WebKit2's config.h. Move it to WebKit2Prefix.h.
272
273         * WebKit2Prefix.h:
274         * config.h:
275
276 2012-06-07  Kentaro Hara  <haraken@chromium.org>
277
278         Reduce Node object size from 72 byte to 64 byte
279         https://bugs.webkit.org/show_bug.cgi?id=88528
280
281         Reviewed by Ryosuke Niwa.
282
283         Added a symbol for callRemovedLastRef().
284
285         * mac/WebKit2.order:
286         * win/WebKit2.def:
287         * win/WebKit2CFLite.def:
288
289 2012-06-07  Andy Estes  <aestes@apple.com>
290
291         [WebKit2] Explicitly include CoreFoundation.h in config.h
292         https://bugs.webkit.org/show_bug.cgi?id=88619
293
294         Reviewed by Dan Bernstein.
295
296         WebKit2 relies (probably unintentionally) on CoreFoundation.h being
297         included by CoreGraphics.h (via CGSession.h), but some versions of
298         CoreGraphics headers don't include CoreFoundation.h. WebKit2 should
299         include it explicitly in config.h.
300
301         * config.h: Import CoreFoundation.h.
302
303 2012-06-07  Andy Estes  <aestes@apple.com>
304
305         [WebKit2] Only include Cocoa.h on platforms that use AppKit
306         https://bugs.webkit.org/show_bug.cgi?id=88517
307
308         Reviewed by Sam Weinig.
309
310         * WebKit2Prefix.h: Include Platform.h to get USE() macros. GTK needs to
311         include autotoolsconfig.h before including Platform.h, so do that first
312         if building on GTK. Then, if compiling an Objective-C file, it's safe
313         to include Foundation.h, but not necessarily Cocoa.h; only include the
314         latter if USE(APPKIT) is true.
315         * config.h: There's no need to import Cocoa.h since this is already
316         imported in the prefix header.
317
318 2012-06-07  Anders Carlsson  <andersca@apple.com>
319
320         Search highlight does not scroll with the content of the page, and find overlay doesn't work, on large-enough window
321         https://bugs.webkit.org/show_bug.cgi?id=88577
322         <rdar://problem/11430118>
323
324         Reviewed by John Sullivan.
325
326         Prevent the page overlay layer from falling into tiled mode.
327
328         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
329         (WebKit::TiledCoreAnimationDrawingArea::createPageOverlayLayer):
330
331 2012-06-07  Alexander Færøy  <ahf@0x90.dk>
332
333         Add QML API tests for Device Pixel Ratio
334         https://bugs.webkit.org/show_bug.cgi?id=88531
335
336         Reviewed by Kenneth Rohde Christiansen.
337
338         This patch adds an initial test case for the QML device pixel ratio
339         API. The test currently fails and is therefore marked as being
340         expected to fail. This will be fixed in a separated patch.
341
342         * UIProcess/API/qt/tests/qmltests/WebView/tst_devicePixelRatio.qml: Added.
343
344 2012-06-07  Christophe Dumez  <christophe.dumez@intel.com>
345
346         [EFL][WK2] WebKit2-EFL does not link in debug mode
347         https://bugs.webkit.org/show_bug.cgi?id=88518
348
349         Unreviewed. Fix WebKit2-EFL linking error in debug mode.
350
351         * CMakeLists.txt:
352
353 2012-06-07  Simon Pena  <spena@igalia.com>
354
355         [GTK] Fix broken build due to missing <SECTION> in GTK-DOC
356         https://bugs.webkit.org/show_bug.cgi?id=88525
357
358         Unreviewed gardening. Added missing <SECTION> tag.
359
360         * UIProcess/API/gtk/docs/webkit2gtk-sections.txt:
361
362 2012-06-07  Carlos Garcia Campos  <cgarcia@igalia.com>
363
364         [GTK] Add API to register custom URI schemes to WebKit2 GTK+ API
365         https://bugs.webkit.org/show_bug.cgi?id=84133
366
367         Reviewed by Martin Robinson.
368
369         * GNUmakefile.list.am: Add new files to compilation.
370         * UIProcess/API/gtk/WebKitPrivate.h:
371         * UIProcess/API/gtk/WebKitRequestManagerClient.cpp: Added.
372         (didReceiveURIRequest): Callback emitted by the C API when a
373         request for a custom URI scheme has been received. Call
374         webkitWebContextReceivedURIRequest() to handle the request.
375         (didFailToLoadURIRequest): Callback emitted by the C API when a
376         request for a custom URI scheme failed to load. Call
377         webkitWebContextDidFailToLoadURIRequest() to noitfy the web
378         context.
379         (attachRequestManagerClientToContext): Initialize the
380         WKSoupRequestManagerClient.
381         * UIProcess/API/gtk/WebKitRequestManagerClient.h: Added.
382         * UIProcess/API/gtk/WebKitURISchemeRequest.cpp: Added.
383         (webkit_uri_scheme_request_init):
384         (webkitURISchemeRequestFinalize):
385         (webkit_uri_scheme_request_class_init):
386         (webkitURISchemeRequestCreate): Create a new
387         WebKitURISchemeRequest for the given URI and request identifier.
388         (webkitURISchemeRequestGetID): Return the request identifier.
389         (webkitURISchemeRequestCancel): Cancel the request operation.
390         (webkit_uri_scheme_request_get_scheme): Return the scheme of the
391         request.
392         (webkit_uri_scheme_request_get_uri): Return the full URI of the
393         request.
394         (webkit_uri_scheme_request_get_path): Return the path of the URI.
395         (webkitURISchemeRequestReadCallback): Read callback emitted when
396         reading the contents of the input stream.
397         (webkit_uri_scheme_request_finish): Finish the request by reading
398         the contents of the input stream and sending the data to the
399         WebProcess.
400         * UIProcess/API/gtk/WebKitURISchemeRequest.h: Added.
401         * UIProcess/API/gtk/WebKitURISchemeRequestPrivate.h: Added.
402         * UIProcess/API/gtk/WebKitWebContext.cpp:
403         (WebKitURISchemeHandler::WebKitURISchemeHandler): Helper struct to
404         save callback and user data of registered URI schemes.
405         (createDefaultWebContext): Initialize the SoupRequestManager.
406         (webkit_web_context_register_uri_scheme): Public API to register a
407         custom URI scheme providing a callback that will be called to
408         handle requests for that URI scheme.
409         (webkitWebContextGetRequestManager): Helper private method to
410         return the SoupRequestManager.
411         (webkitWebContextReceivedURIRequest): Get the
412         WebKitURISchemeHandler for the given request identifier and call
413         the callback. Save the request in the request map.
414         (webkitWebContextDidFailToLoadURIRequest): Cancel the ongoing
415         request.
416         (webkitWebContextDidFinishURIRequest): Remove the request from the
417         map.
418         * UIProcess/API/gtk/WebKitWebContext.h:
419         * UIProcess/API/gtk/WebKitWebContextPrivate.h:
420         * UIProcess/API/gtk/docs/webkit2gtk-docs.sgml: Add
421         WebKitURISchemeRequest section.
422         * UIProcess/API/gtk/docs/webkit2gtk-sections.txt: Add new symbols.
423         * UIProcess/API/gtk/docs/webkit2gtk.types: Add
424         webkit_uri_scheme_request_get_type.
425         * UIProcess/API/gtk/tests/TestWebKitWebContext.cpp:
426         (testWebContextURIScheme):
427         (beforeAll):
428         * UIProcess/API/gtk/webkit2.h: Include WebKitURISchemeRequest.h.
429
430 2012-06-07  Andras Becsi  <andras.becsi@nokia.com>
431
432         [Qt][WK2] setPageItemRectVisible() is not guarded by ViewportUpdateDeferrer at scaleAnimationValueChanged()
433         https://bugs.webkit.org/show_bug.cgi?id=87954
434
435         Reviewed by Kenneth Rohde Christiansen.
436
437         Resetting the end value, the easing curve or the duration of the scale animation triggers
438         a recalculation of the animation interval. This might change the current value of the
439         animated property.
440         Since guarding of setPageItemRectVisible() relies on animation state change we have to
441         make sure we only act on animation value changes if the animation is in active state.
442
443         * UIProcess/qt/QtViewportHandler.cpp:
444         (WebKit::QtViewportHandler::QtViewportHandler):
445         (WebKit::QtViewportHandler::animatePageItemRectVisible):
446         (WebKit::QtViewportHandler::scaleAnimationValueChanged):
447
448 2012-06-06  Carlos Garcia Campos  <cgarcia@igalia.com>
449
450         [SOUP] WebSoupRequestManager should handle loading errors and zero-length replies
451         https://bugs.webkit.org/show_bug.cgi?id=88087
452
453         Reviewed by Martin Robinson.
454
455         * UIProcess/API/C/soup/WKSoupRequestManager.h:
456         * UIProcess/soup/WebSoupRequestManagerClient.cpp:
457         (WebKit::WebSoupRequestManagerClient::didFailToLoadURIRequest):
458         Call didFailToLoadURIRequest in the client if present.
459         * UIProcess/soup/WebSoupRequestManagerClient.h:
460         * UIProcess/soup/WebSoupRequestManagerProxy.cpp:
461         (WebKit::WebSoupRequestManagerProxy::WebSoupRequestManagerProxy):
462         Initialize m_loadFailed.
463         (WebKit::WebSoupRequestManagerProxy::didReceiveURIRequestData):
464         Don't send more data to the web process if the resource failed to
465         load.
466         (WebKit::WebSoupRequestManagerProxy::didFailToLoadURIRequest): Set
467         m_loadFailed and notifiy the client calling didFailToLoadURIRequest.
468         * UIProcess/soup/WebSoupRequestManagerProxy.h:
469         * UIProcess/soup/WebSoupRequestManagerProxy.messages.in: Add
470         DidFailToLoadURIRequest message.
471         * WebProcess/soup/WebKitSoupRequestGeneric.cpp:
472         (webkitSoupRequestGenericSendAsync): Pass the cancellable to the
473         WebSoupRequestManager.
474         * WebProcess/soup/WebSoupRequestManager.cpp:
475         (WebKit::WebSoupRequestAsyncData::WebSoupRequestAsyncData): Helper
476         struct to save requests.
477         (WebSoupRequestAsyncData): Add a weak pointer to invalidate the
478         request when it's destroyed before the operation has finished.
479         (WebKit::WebSoupRequestAsyncData::~WebSoupRequestAsyncData):
480         Remove the weak pointer.
481         (WebKit::WebSoupRequestAsyncData::requestFailed): Return whther
482         the request failed.
483         (WebKit::WebSoupRequestAsyncData::releaseResult): Return the
484         result and clear the pointer.
485         (WebKit::WebSoupRequestManager::didHandleURIRequest): Create and
486         empty memory stream for zero-length replies instead of creating an
487         error.
488         (WebKit::WebSoupRequestManager::didReceiveURIRequestData): If the
489         request failed and more data expected from the UI process, send a
490         message to the UI process to notify that the resource load failed.
491         (WebKit::WebSoupRequestManager::send): Save request information in
492         the request map.
493         * WebProcess/soup/WebSoupRequestManager.h:
494
495 2012-06-06  Andy Estes  <aestes@apple.com>
496
497         Wrap uppercaseWord, lowercaseWord, and capitalizeWord with USE(APPKIT)
498         https://bugs.webkit.org/show_bug.cgi?id=88504
499
500         Reviewed by Dan Bernstein.
501
502         uppercaseWord, lowercaseWord, and capitalizeWord are methods declared
503         by NSResponder that subclasses are expected to implement. WebKit should
504         only support these implementations on platforms that use AppKit.
505
506         * UIProcess/WebPageProxy.h:
507         * WebProcess/WebCoreSupport/WebEditorClient.h:
508         * WebProcess/WebCoreSupport/mac/WebEditorClientMac.mm:
509         * WebProcess/WebPage/WebPage.cpp:
510         * WebProcess/WebPage/WebPage.h:
511         * WebProcess/WebPage/WebPage.messages.in:
512
513 2012-06-06  chandra Shekar Vallala  <chandra.vallala@motorola.com>
514
515         [WK2-Gtk]Compilation errors with flag CONTEXT_MENUS=0
516         https://bugs.webkit.org/show_bug.cgi?id=87842
517
518         Reviewed by Martin Robinson.
519
520         Fix for compilation errors while building webkit2-gtk with CONTEXT_MENUS=0
521
522         * UIProcess/gtk/WebContextMenuProxyGtk.cpp: Added code under CONTEXT_MENUS CC
523         * UIProcess/gtk/WebContextMenuProxyGtk.h: Ditto
524         * WebProcess/WebCoreSupport/gtk/WebContextMenuClientGtk.cpp: Ditto
525
526 2012-06-06  Michael Brüning  <michael.bruning@nokia.com>
527
528         [Qt][WK2] Add preferredMinimumContentsWidth to the viewport info in MiniBrowser.
529         https://bugs.webkit.org/show_bug.cgi?id=88327
530
531         Reviewed by Kenneth Rohde Christiansen.
532
533         * UIProcess/API/qt/qquickwebview.cpp:
534         (QQuickWebViewExperimental::setPreferredMinimumContentsWidth):
535         * UIProcess/API/qt/qquickwebview_p.h:
536
537 2012-06-06  Tim Horton  <timothy_horton@apple.com>
538
539         WebPage::windowIsVisible is incorrect during resumePainting
540         https://bugs.webkit.org/show_bug.cgi?id=88374
541         <rdar://problem/11587039>
542
543         Reviewed by Simon Fraser.
544
545         Currently, when changing window visibility, WKView calls viewStateDidChange(ViewIsVisible)
546         and then _updateWindowVisibility. This means that during viewStateDidChange, the WebPage's
547         windowIsVisible state is incorrect.
548
549         viewStateDidChange(ViewIsVisible) can end up in (one of the DrawingArea implementations)::resumePainting(),
550         which uses windowIsVisible to determine whether or not to unpause requestAnimationFrame.
551
552         This results in a state where, with some configurations, doing the following:
553
554             1. requestAnimationFrame()
555             2. requestFullScreen()
556             3. requestAnimationFrame()
557             4. cancelFullScreen()
558             5. requestAnimationFrame()
559
560         Will cause the second and third rAF calls to have no effect. Even after cancelFullScreen() is called,
561         the fact that we have had unpaired suspend/resumeScriptedAnimations will cause the suspend count
562         on the ScriptedAnimationController to never return to zero, which will cause us to never
563         recover rAF functionality.
564
565         The fix is very simple: we should _updateWindowVisibility *before* viewStateDidChange, so that it is
566         always correct for any code called underneath that method.
567
568         * UIProcess/API/mac/WKView.mm:
569         (-[WKView viewDidMoveToWindow]):
570         (-[WKView _windowDidOrderOffScreen:]):
571         (-[WKView _windowDidOrderOnScreen:]):
572
573 2012-06-05  Dinu Jacob  <dinu.jacob@nokia.com>
574
575         [Qt][WK2] Use Component.onCompleted in API tests for single and multi file upload tests.
576         https://bugs.webkit.org/show_bug.cgi?id=88247
577
578         Reviewed by Kenneth Rohde Christiansen.
579
580         With r116936, Component.onCompleted can be used for callback instead of the
581         1s timer in single and multi file upload tests.
582
583         * UIProcess/API/qt/tests/qmltests/WebView/tst_multiFileUpload.qml:
584         * UIProcess/API/qt/tests/qmltests/WebView/tst_singleFileUpload.qml:
585
586 2012-06-04  Stephanie Lewis  <slewis@apple.com>
587
588         https://bugs.webkit.org/show_bug.cgi?id=88370
589         Memory sampler should trigger low memory signal
590
591         Reviewed by Geoff Garen.
592
593         Send low memory signal when running the memory sampler.  We'd
594         like to test memory that cannot be freed.
595
596         * Shared/WebMemorySampler.cpp:
597         (WebKit::WebMemorySampler::sampleTimerFired):
598         * Shared/WebMemorySampler.h:
599         (WebMemorySampler):
600         * Shared/mac/WebMemorySampler.mac.mm:
601         (WebKit):
602         (WebKit::WebMemorySampler::sendMemoryPressureEvent):
603
604 2012-06-05  Brady Eidson  <beidson@apple.com>
605
606         <rdar://problem/11575898> and https://bugs.webkit.org/show_bug.cgi?id=88372
607         REGRESSION(110494): Can no longer drag-and-drop links into FileMaker Pro 12
608
609         - Before r110494 we used to write the NSStringPboardType to the pasteboard.
610           After r110494 we write NSURLPboardType instead.
611           That's basically a no-op, but the NSStringPboardType needs to be restored.
612         - Before r110494 we wrote the link destination URL to the pasteboard.
613           After r110494 we write the image src URL if the link is an image.
614           We need to revert to writing the link URL.
615
616         Fortunately these changes can be accomplished with a 2-line fix.
617
618         Reviewed by Enrica Casucci.
619
620         * UIProcess/API/mac/WKView.mm:
621         (-[WKView _setPromisedData:WebCore::withFileName:withExtension:withTitle:withURL:withVisibleURL:withArchive:WebCore::forPasteboard:]):
622         n
623
624 2012-06-05  Tor Arne Vestbø  <tor.arne.vestbo@nokia.com>
625
626         [Qt] Implement log channel initialization for WebKit2
627
628         Reviewed by Alexis Menard.
629
630         * Platform/Logging.cpp:
631         (WebKit):
632         * Platform/Logging.h:
633         (WebKit):
634         * Platform/qt/LoggingQt.cpp: Copied from Source/WebKit2/Platform/gtk/LoggingGtk.cpp
635         (WebKit):
636         (WebKit::initializeLogChannel):
637         * Target.pri:
638
639 2012-06-05  Jocelyn Turcotte  <jocelyn.turcotte@nokia.com>
640
641         WebLayerTreeRenderer behaves wrongly when no contentsScale is set.
642         https://bugs.webkit.org/show_bug.cgi?id=88357
643
644         Reviewed by Alexis Menard.
645
646         The contentsScale needs to get a default value in case no
647         value is explicitely set yet.
648         This fixes the blank-until-resize problem when running MiniBrowser
649         in --desktop mode.
650
651         * UIProcess/WebLayerTreeRenderer.cpp:
652         (WebKit::WebLayerTreeRenderer::WebLayerTreeRenderer):
653
654 2012-06-05  Alexis Menard  <alexis.menard@openbossa.org>
655
656         [Qt] Don't propagate viewport size changes if the viewport is empty.
657         https://bugs.webkit.org/show_bug.cgi?id=88336
658
659         Reviewed by Tor Arne Vestbø.
660
661         Qt Quick sequentially set the x, y, width, height of the view. We really want to
662         start propagating further when the size of the viewport becomes valid, i.e. both
663         height and width are defined. In any case lower level classes are discarding an empty
664         size such as WebPage::sendViewportAttributesChanged() so it was pointless to send the size
665         through the IPC bus for nothing.
666
667         * UIProcess/API/qt/qquickwebview.cpp:
668         (QQuickWebViewLegacyPrivate::updateViewportSize):
669
670 2012-06-05  Carlos Garcia Campos  <cgarcia@igalia.com>
671
672         [GTK] Add webkit_download_get_received_data_length to WebKit2 GTK+ API
673         https://bugs.webkit.org/show_bug.cgi?id=88323
674
675         Reviewed by Martin Robinson.
676
677         * UIProcess/API/gtk/WebKitDownload.cpp:
678         (webkit_download_get_received_data_length):
679         * UIProcess/API/gtk/WebKitDownload.h:
680         * UIProcess/API/gtk/docs/webkit2gtk-sections.txt:
681         * UIProcess/API/gtk/tests/TestDownloads.cpp:
682
683 2012-06-05  Dongwoo Im  <dw.im@samsung.com>
684
685         Add 'isProtocolHandlerRegistered' and 'unregisterProtocolHandler'.
686         https://bugs.webkit.org/show_bug.cgi?id=73176
687
688         Reviewed by Adam Barth.
689
690         Two more APIs are added in Custom Scheme Handler specification.
691         http://dev.w3.org/html5/spec/Overview.html#custom-handlers
692         One is 'isProtocolHandlerRegistered' to query whether the specific URL
693         is registered or not.
694         The other is 'unregisterProtocolHandler' to remove the registered URL.
695
696         * Configurations/FeatureDefines.xcconfig: Add a macro 'ENABLE_CUSTOM_SCHEME_HANDLER'.
697
698 2012-06-05  Christophe Dumez  <christophe.dumez@intel.com>
699
700         [EFL][WK2] WebKit2-EFL does not link with gold linker
701         https://bugs.webkit.org/show_bug.cgi?id=88295
702
703         Unreviewed. Fix linking when using gold linker.
704
705         * PlatformEfl.cmake:
706
707 2012-06-05  Mario Sanchez Prada  <msanchez@igalia.com>
708
709         [GTK][WK2] Implement API for Geolocation permission requests in the GTK port
710         https://bugs.webkit.org/show_bug.cgi?id=83879
711
712         Reviewed by Carlos Garcia Campos.
713
714         Added a new kind of permission request for supporting the
715         Geolocation API in WebKit2GTK+.
716
717         New WebKitGeolocationPermissionRequest class, implementing the
718         WebKitPermissionRequest interface, to enabling client applications
719         to allow or deny geolocation permission requests.
720
721         * GNUmakefile.list.am: Added new files.
722         * UIProcess/API/gtk/WebKitGeolocationPermissionRequest.cpp: Added.
723         (_WebKitGeolocationPermissionRequestPrivate):
724         (webkitGeolocationPermissionRequestAllow):
725         (webkitGeolocationPermissionRequestDeny):
726         (webkit_permission_request_interface_init):
727         (webkit_geolocation_permission_request_init):
728         (webkitGeolocationPermissionRequestFinalize):
729         (webkit_geolocation_permission_request_class_init):
730         (webkitGeolocationPermissionRequestCreate):
731         * UIProcess/API/gtk/WebKitGeolocationPermissionRequest.h: Added.
732         (_WebKitGeolocationPermissionRequest):
733         (_WebKitGeolocationPermissionRequestClass):
734         * UIProcess/API/gtk/WebKitGeolocationPermissionRequestPrivate.h: Added.
735
736         Include WKGeolocationPermissionRequest.h in WebKitPrivate.h, so we
737         can use it from the new WebKitGeolocationPermissionRequest class.
738
739         * UIProcess/API/gtk/WebKitPrivate.h: Added new include.
740
741         Implement geolocation permission requests in the UI client.
742
743         * UIProcess/API/gtk/WebKitUIClient.cpp:
744         (decidePolicyForGeolocationPermissionRequest): Create a new
745         instance of the WebKitGeolocationPermissionRequest class and call
746         to webkitWebViewMakePermissionRequest().
747         (attachUIClientToView): Provide an implementation function for
748         decidePolicyForGeolocationPermissionRequest.
749         * UIProcess/API/gtk/WebKitWebView.h: Add new element to
750         WebKitPermissionRequestType enumeration for geolocation requests.
751         * UIProcess/API/gtk/webkit2.h: Added header file for
752         WebKitGeolocationPermissionRequest
753
754         New unit tests to test allowing and denying permission requests.
755
756         * UIProcess/API/gtk/tests/TestWebKitWebView.cpp:
757         (testWebViewPermissionRequests): New test that loads a simple HTML
758         with JavaScript code requesting the current location.
759         (beforeAll): Added new test.
760
761         Updated documentation files.
762
763         * UIProcess/API/gtk/docs/webkit2gtk-docs.sgml:
764         * UIProcess/API/gtk/docs/webkit2gtk-sections.txt:
765
766 2012-06-04  Sadrul Habib Chowdhury  <sadrul@chromium.org>
767
768         [chromium] Fix software rendering for device-scale-factor > 1
769         https://bugs.webkit.org/show_bug.cgi?id=88136
770
771         Reviewed by Darin Fisher.
772
773         Export WebCore::Page::setDeviceScaleFactor and WebCore::Settings::setDefaultDeviceScaleFactor.
774
775         * win/WebKit2.def:
776         * win/WebKit2CFLite.def:
777
778 2012-06-04  Andy Estes  <aestes@apple.com>
779
780         Use ENABLE() and USE() macros in a few more places
781         https://bugs.webkit.org/show_bug.cgi?id=88245
782
783         Reviewed by Anders Carlsson.
784
785         * UIProcess/API/C/WKPluginSiteDataManager.cpp: Only include npapi.h if
786         Netscape plug-in API is enabled.
787         * UIProcess/mac/CorrectionPanel.h: Wrap with USE(AUTOCORRECTION_PANEL)
788         * WebProcess/Authentication/AuthenticationManager.cpp: Use the stub
789         version of tryUsePlatformCertificateInfoForChallenge if
790         Security.framework isn't available.
791         * WebProcess/WebProcess.messages.in: Only generate two messages if
792         Security.framework is available.
793         * WebProcess/mac/KeychainItemShimMethods.mm: Wrap with
794         USE(SECURITY_FRAMEWORK).
795
796 2012-06-04  Andy Estes  <aestes@apple.com>
797
798         Add stub WebKit2 implementations of PLUGIN_PROXY_FOR_VIDEO methods declared in FrameLoaderClient
799         https://bugs.webkit.org/show_bug.cgi?id=88244
800
801         Reviewed by Anders Carlsson.
802
803         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
804         (WebKit::WebFrameLoaderClient::createMediaPlayerProxyPlugin): Add a stub implementation.
805         (WebKit::WebFrameLoaderClient::hideMediaPlayerProxyPlugin): Ditto.
806         (WebKit::WebFrameLoaderClient::showMediaPlayerProxyPlugin): Ditto.
807         * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
808
809 2012-06-04  Mario Sanchez Prada  <msanchez@igalia.com>
810
811         [GTK][WK2] Implement geolocation provider for the GTK port
812         https://bugs.webkit.org/show_bug.cgi?id=83877
813
814         Reviewed by Carlos Garcia Campos.
815
816         Add a new client-based geolocation provider for WebKit2GTK+, relying the
817         new Geoclue-based geolocation provider available in WebCore.
818
819         * GNUmakefile.am:
820         * GNUmakefile.list.am:
821         * UIProcess/API/gtk/WebKitGeolocationProvider.cpp: Added.
822         (toGeolocationProvider):
823         (startUpdatingCallback):
824         (stopUpdatingCallback):
825         (WebKitGeolocationProvider::~WebKitGeolocationProvider):
826         (WebKitGeolocationProvider::create):
827         (WebKitGeolocationProvider::WebKitGeolocationProvider):
828         (WebKitGeolocationProvider::startUpdating):
829         (WebKitGeolocationProvider::stopUpdating):
830         (WebKitGeolocationProvider::notifyPositionChanged):
831         (WebKitGeolocationProvider::notifyErrorOccurred):
832         * UIProcess/API/gtk/WebKitGeolocationProvider.h: Added.
833         * UIProcess/API/gtk/WebKitPrivate.h:
834         * UIProcess/API/gtk/WebKitWebContext.cpp:
835         (_WebKitWebContextPrivate):
836         (createDefaultWebContext):
837
838 2012-06-04  Zalan Bujtas  <zbujtas@gmail.com>
839
840         [Qt][WK2] Rename QtViewportInteractionEngine to QtViewportHandler.
841         https://bugs.webkit.org/show_bug.cgi?id=88226
842
843         Reviewed by Kenneth Rohde Christiansen.
844
845         * Target.pri:
846         * UIProcess/API/qt/qquickwebpage_p_p.h:
847         (WebKit):
848         * UIProcess/API/qt/qquickwebview.cpp:
849         (QQuickWebViewFlickablePrivate::~QQuickWebViewFlickablePrivate):
850         (QQuickWebViewFlickablePrivate::onComponentComplete):
851         (QQuickWebViewFlickablePrivate::didChangeViewportProperties):
852         (QQuickWebViewFlickablePrivate::updateViewportSize):
853         (QQuickWebViewFlickablePrivate::pageDidRequestScroll):
854         (QQuickWebViewFlickablePrivate::didChangeContentsSize):
855         * UIProcess/API/qt/qquickwebview_p.h:
856         (WebKit):
857         * UIProcess/API/qt/qquickwebview_p_p.h:
858         (WebKit):
859         (QQuickWebViewPrivate::viewportHandler):
860         (QQuickWebViewFlickablePrivate::viewportHandler):
861         (QQuickWebViewFlickablePrivate):
862         * UIProcess/API/qt/qwebkittest.cpp:
863         (QWebKitTest::contentsScale):
864         (QWebKitTest::devicePixelRatio):
865         (QWebKitTest::initialScale):
866         (QWebKitTest::minimumScale):
867         (QWebKitTest::maximumScale):
868         (QWebKitTest::isScalable):
869         (QWebKitTest::layoutSize):
870         * UIProcess/qt/QtGestureRecognizer.cpp:
871         (WebKit::QtGestureRecognizer::viewportHandler):
872         * UIProcess/qt/QtGestureRecognizer.h:
873         (WebKit):
874         * UIProcess/qt/QtPanGestureRecognizer.cpp:
875         (WebKit::QtPanGestureRecognizer::update):
876         (WebKit::QtPanGestureRecognizer::finish):
877         (WebKit::QtPanGestureRecognizer::cancel):
878         * UIProcess/qt/QtPinchGestureRecognizer.cpp:
879         (WebKit::QtPinchGestureRecognizer::update):
880         (WebKit::QtPinchGestureRecognizer::finish):
881         (WebKit::QtPinchGestureRecognizer::cancel):
882         * UIProcess/qt/QtViewportHandler.cpp: Copied from Source/WebKit2/UIProcess/qt/QtViewportInteractionEngine.cpp.
883         (WebKit::ViewportUpdateDeferrer::ViewportUpdateDeferrer):
884         (WebKit::ViewportUpdateDeferrer::~ViewportUpdateDeferrer):
885         (ViewportUpdateDeferrer):
886         (WebKit::QtViewportHandler::suspendPageContent):
887         (WebKit::QtViewportHandler::resumePageContent):
888         (WebKit::QtViewportHandler::cssScaleFromItem):
889         (WebKit::QtViewportHandler::itemScaleFromCSS):
890         (WebKit::QtViewportHandler::itemCoordFromCSS):
891         (WebKit::QtViewportHandler::itemRectFromCSS):
892         (WebKit::QtViewportHandler::QtViewportHandler):
893         (WebKit::QtViewportHandler::~QtViewportHandler):
894         (WebKit::QtViewportHandler::innerBoundedCSSScale):
895         (WebKit::QtViewportHandler::outerBoundedCSSScale):
896         (WebKit::QtViewportHandler::viewportAttributesChanged):
897         (WebKit::QtViewportHandler::pageContentsSizeChanged):
898         (WebKit::QtViewportHandler::setPageItemRectVisible):
899         (WebKit::QtViewportHandler::animatePageItemRectVisible):
900         (WebKit::QtViewportHandler::flickMoveStarted):
901         (WebKit::QtViewportHandler::flickMoveEnded):
902         (WebKit::QtViewportHandler::pageItemPositionChanged):
903         (WebKit::QtViewportHandler::pageContentPositionRequested):
904         (WebKit::QtViewportHandler::scaleAnimationStateChanged):
905         (WebKit::QtViewportHandler::scaleAnimationValueChanged):
906         (WebKit::QtViewportHandler::touchBegin):
907         (WebKit::QtViewportHandler::touchEnd):
908         (WebKit::QtViewportHandler::computePosRangeForPageItemAtScale):
909         (WebKit::QtViewportHandler::focusEditableArea):
910         (WebKit::QtViewportHandler::zoomToAreaGestureEnded):
911         (WebKit::QtViewportHandler::nearestValidBounds):
912         (WebKit::QtViewportHandler::setCSSScale):
913         (WebKit::QtViewportHandler::currentCSSScale):
914         (WebKit::QtViewportHandler::scrollAnimationActive):
915         (WebKit::QtViewportHandler::panGestureActive):
916         (WebKit::QtViewportHandler::panGestureStarted):
917         (WebKit::QtViewportHandler::panGestureRequestUpdate):
918         (WebKit::QtViewportHandler::panGestureEnded):
919         (WebKit::QtViewportHandler::panGestureCancelled):
920         (WebKit::QtViewportHandler::scaleAnimationActive):
921         (WebKit::QtViewportHandler::cancelScrollAnimation):
922         (WebKit::QtViewportHandler::interruptScaleAnimation):
923         (WebKit::QtViewportHandler::pinchGestureActive):
924         (WebKit::QtViewportHandler::pinchGestureStarted):
925         (WebKit::QtViewportHandler::pinchGestureRequestUpdate):
926         (WebKit::QtViewportHandler::pinchGestureEnded):
927         (WebKit::QtViewportHandler::pinchGestureCancelled):
928         (WebKit::QtViewportHandler::visibleContentsRect):
929         (WebKit::QtViewportHandler::informVisibleContentChange):
930         (WebKit::QtViewportHandler::viewportItemSizeChanged):
931         (WebKit::QtViewportHandler::scaleContent):
932         * UIProcess/qt/QtViewportHandler.h: Copied from Source/WebKit2/UIProcess/qt/QtViewportInteractionEngine.h.
933         (QtViewportHandler):
934         * UIProcess/qt/QtViewportInteractionEngine.cpp: Removed.
935         * UIProcess/qt/QtViewportInteractionEngine.h: Removed.
936         * UIProcess/qt/QtWebPageEventHandler.cpp:
937         (WebKit::QtWebPageEventHandler::QtWebPageEventHandler):
938         (WebKit::QtWebPageEventHandler::setViewportHandler):
939         (WebKit::QtWebPageEventHandler::inputPanelVisibleChanged):
940         (WebKit::QtWebPageEventHandler::doneWithTouchEvent):
941         (WebKit::QtWebPageEventHandler::didFindZoomableArea):
942         * UIProcess/qt/QtWebPageEventHandler.h:
943         (WebKit):
944         (QtWebPageEventHandler):
945         (WebKit::QtWebPageEventHandler::viewportHandler):
946
947 2012-06-04  David Kilzer  <ddkilzer@apple.com>
948
949         BUILD FIX: FeatureDefines.xcconfig should match across projects
950
951         * Configurations/FeatureDefines.xcconfig:
952         - Add missing ENABLE_LEGACY_CSS_VENDOR_PREFIXES.
953
954 2012-06-04  Allan Sandfeld Jensen  <allan.jensen@nokia.com>
955
956         [Qt] Tap-to-zoom overshoot animation.
957         https://bugs.webkit.org/show_bug.cgi?id=87108
958
959         Reviewed by Tor Arne Vestbø.
960
961         Reverts the change in animation, so the default is more "neutral".
962         This should be made configurable later.
963
964         * UIProcess/qt/QtViewportInteractionEngine.cpp:
965         (WebKit::QtViewportInteractionEngine::animatePageItemRectVisible):
966
967 2012-06-04  Andras Becsi  <andras.becsi@nokia.com>
968
969         [Qt][WK2] Refactor the tap gesture recognizer
970         https://bugs.webkit.org/show_bug.cgi?id=88096
971
972         Reviewed by Simon Hausmann.
973
974         Refactor the tap gesture recognizer so that its internal state machine is
975         self contained and independent of input event types.
976         Also change the internal API for tap highlighting to make the code easier
977         to understand on the caller side.
978
979         This patch makes the tap gesture recognizer more robust, consistent with
980         other gesture recognizers and fixes some issues related to highlighting
981         and link activation with respect to native touch events.
982
983         * UIProcess/qt/QtTapGestureRecognizer.cpp:
984         (WebKit::QtTapGestureRecognizer::QtTapGestureRecognizer):
985         (WebKit::QtTapGestureRecognizer::withinDistance):
986         (WebKit::QtTapGestureRecognizer::update):
987         (WebKit::QtTapGestureRecognizer::finish):
988         (WebKit::QtTapGestureRecognizer::cancel):
989         (WebKit::QtTapGestureRecognizer::highlightTimeout):
990         (WebKit::QtTapGestureRecognizer::singleTapTimeout):
991         (WebKit::QtTapGestureRecognizer::tapAndHoldTimeout):
992         (WebKit::QtTapGestureRecognizer::reset):
993         * UIProcess/qt/QtTapGestureRecognizer.h:
994         (QtTapGestureRecognizer):
995         * UIProcess/qt/QtWebPageEventHandler.cpp:
996         (WebKit::QtWebPageEventHandler::QtWebPageEventHandler):
997         (WebKit::QtWebPageEventHandler::activateTapHighlight):
998         (WebKit::QtWebPageEventHandler::deactivateTapHighlight):
999         (WebKit):
1000         (WebKit::QtWebPageEventHandler::handleSingleTapEvent):
1001         (WebKit::QtWebPageEventHandler::handleDoubleTapEvent):
1002         (WebKit::QtWebPageEventHandler::doneWithTouchEvent):
1003         * UIProcess/qt/QtWebPageEventHandler.h:
1004         (QtWebPageEventHandler):
1005
1006 2012-06-02  Geoffrey Garen  <ggaren@apple.com>
1007
1008         Try to fix the Windows build.
1009
1010         * win/WebKit2.def:
1011         * win/WebKit2CFLite.def:
1012
1013 2012-06-02  Andy Estes  <aestes@apple.com>
1014
1015         [WebKit2] Use USE(), ENABLE(), and HAVE() macros in more places
1016         https://bugs.webkit.org/show_bug.cgi?id=88182
1017
1018         Reviewed by Sam Weinig.
1019
1020         Use USE(APPKIT):
1021         * Shared/mac/NativeWebKeyboardEventMac.mm:
1022         * Shared/mac/NativeWebMouseEventMac.mm:
1023         * Shared/mac/NativeWebWheelEventMac.mm:
1024         * Shared/mac/WebEventFactory.h:
1025         * UIProcess/API/mac/WKTextInputWindowController.h:
1026         * UIProcess/API/mac/WKTextInputWindowController.mm:
1027         * UIProcess/PageClient.h:
1028         * UIProcess/WebPageProxy.h:
1029
1030         Use ENABLE(NETSCAPE_PLUGIN_API):
1031         * UIProcess/API/C/WKPluginSiteDataManager.cpp:
1032         (WKPluginSiteDataManagerClearSiteData):
1033         (WKPluginSiteDataManagerClearAllSiteData):
1034
1035         Use USE(AUTOCORRECTION_PANEL):
1036         * UIProcess/API/mac/PageClientImpl.h:
1037         * UIProcess/API/mac/PageClientImpl.mm:
1038         (WebKit::PageClientImpl::showCorrectionPanel):
1039         (WebKit::PageClientImpl::dismissCorrectionPanel):
1040         (WebKit::PageClientImpl::dismissCorrectionPanelSoon):
1041         * UIProcess/mac/CorrectionPanel.mm:
1042
1043         Use HAVE(HOSTED_CORE_ANIMATION):
1044         * UIProcess/mac/WebContextMac.mm:
1045
1046         Put ENABLE(FULLSCREEN_API) in the right place:
1047         * UIProcess/mac/WebFullScreenManagerProxyMac.mm:
1048
1049         Remove unnecessary use of USE(APPKIT):
1050         * UIProcess/mac/WebPageProxyMac.mm:
1051
1052         Use USE(SECURITY_FRAMEWORK):
1053         * WebProcess/Authentication/mac/AuthenticationManager.mac.mm:
1054
1055         Use ENABLE(CONTEXT_MENUS):
1056         * WebProcess/WebCoreSupport/mac/WebContextMenuClientMac.mm:
1057
1058         Use USE(SECURITY_FRAMEWORK):
1059         * WebProcess/WebProcess.h:
1060
1061         Remove unnecessary use of USE(SECURITY_FRAMEWORK):
1062         * WebProcess/mac/WebProcessMac.mm:
1063
1064 2012-06-02  Andy Estes  <aestes@apple.com>
1065
1066         Remove a duplicate INIT() from WebSystemInterface.mm
1067         https://bugs.webkit.org/show_bug.cgi?id=88181
1068
1069         Reviewed by Anders Carlsson.
1070
1071         * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
1072         (InitWebCoreSystemInterface):
1073
1074 2012-06-02  Andy Estes  <aestes@apple.com>
1075
1076         Remove unnecessary import of <Cocoa/Cocoa.h>
1077         https://bugs.webkit.org/show_bug.cgi?id=88180
1078
1079         Reviewed by Sam Weinig.
1080
1081         * UIProcess/mac/WKFullKeyboardAccessWatcher.h:
1082
1083 2012-06-02  Andy Estes  <aestes@apple.com>
1084
1085         Ensure cpu_type_t is defined by including <mach/machine.h>
1086         https://bugs.webkit.org/show_bug.cgi?id=88178
1087
1088         Reviewed by Anders Carlsson.
1089
1090         * Shared/Plugins/PluginModuleInfo.h:
1091
1092 2012-06-02  Sam Weinig  <sam@webkit.org>
1093
1094         InjectedBundles' sandbox extensions don't do what we think they do
1095         https://bugs.webkit.org/show_bug.cgi?id=88177
1096
1097         Reviewed by Anders Carlsson.
1098
1099         This cannot be tested with our current infrastructure (or any modifications of the
1100         infrastructure I can think of) since it relies on the bundle being put outside
1101         the build directory where WebKit is put.
1102
1103         * WebProcess/InjectedBundle/mac/InjectedBundleMac.cpp:
1104         (WebKit::InjectedBundle::load):
1105         Use SandboxExtension::consumePermanently() rather than consume(), otherwise,
1106         nulling out the SandboxExtension a few lines later invalidates the extension
1107         we just consumed.
1108
1109 2012-06-02  Dan Bernstein  <mitz@apple.com>
1110
1111         Reverted the last change.
1112
1113         * WebKit2.xcodeproj/project.pbxproj:
1114
1115 2012-06-02  Dan Bernstein  <mitz@apple.com>
1116
1117         Stop treating two Python scripts as private headers.
1118
1119         * WebKit2.xcodeproj/project.pbxproj: Removed model.py and parser.py from the Copy Headers
1120         build phase.
1121
1122 2012-06-02  Zeno Albisser  <zeno@webkit.org>
1123
1124         Fix and enable WebGL for WebKit2 on Qt.
1125         https://bugs.webkit.org/show_bug.cgi?id=86214
1126
1127         Added glue code to make use of GraphicsSurface
1128         as a backend for the webgl-canvas in case of WK2.
1129
1130         Reviewed by Noam Rosenthal.
1131
1132         * UIProcess/API/qt/qwebpreferences.cpp:
1133         (QWebPreferencesPrivate::testAttribute):
1134         (QWebPreferencesPrivate::setAttribute):
1135         (QWebPreferences::webGLEnabled):
1136         (QWebPreferences::setWebGLEnabled):
1137         * UIProcess/API/qt/qwebpreferences_p.h:
1138         * UIProcess/API/qt/qwebpreferences_p_p.h:
1139         Added WebGLEnabled enum to allow enabling/disabling of
1140         WebGL using QWebPreferences.
1141
1142         * UIProcess/LayerTreeHostProxy.cpp:
1143         (WebKit::LayerTreeHostProxy::syncCanvas):
1144         Dispatch syncCanvas calls to the apropriate
1145         WebLayerTreeRenderer.
1146
1147         * UIProcess/LayerTreeHostProxy.h:
1148         (LayerTreeHostProxy):
1149         * UIProcess/LayerTreeHostProxy.messages.in:
1150         * UIProcess/WebLayerTreeRenderer.h:
1151         (WebLayerTreeRenderer):
1152         * UIProcess/WebLayerTreeRenderer.cpp:
1153         (WebKit::WebLayerTreeRenderer::syncCanvas):
1154         (WebKit::WebLayerTreeRenderer::deleteLayer):
1155         (WebKit::WebLayerTreeRenderer::purgeGLResources):
1156         Create a TextureMapperSurfaceBackingStore for the canvas
1157         if necessary and pass or update the graphicsSurfaceToken
1158         for to be used with the backing store.
1159
1160         * WebProcess/WebCoreSupport/WebGraphicsLayer.cpp:
1161         (WebCore::WebGraphicsLayer::WebGraphicsLayer):
1162         (WebCore):
1163         (WebCore::WebGraphicsLayer::setContentsToCanvas):
1164         (WebCore::WebGraphicsLayer::syncCanvas):
1165         Copy the multisample framebuffer contents onto the GraphicsSurface.
1166         Notify the UIProcess of the availability of a new texture.
1167         (WebCore::WebGraphicsLayer::syncCompositingStateForThisLayerOnly):
1168         Sync the canvas as well.
1169
1170         * WebProcess/WebCoreSupport/WebGraphicsLayer.h:
1171         Added a pure virtual function syncCanvas.
1172         This is guarded by PLATFORM(QT).
1173         (WebGraphicsLayerClient):
1174         (WebGraphicsLayer):
1175
1176         * WebProcess/WebPage/qt/LayerTreeHostQt.cpp:
1177         (WebKit::LayerTreeHostQt::syncLayerChildren):
1178         (WebKit):
1179         (WebKit::LayerTreeHostQt::syncCanvas):
1180         * WebProcess/WebPage/qt/LayerTreeHostQt.h:
1181         (LayerTreeHostQt):
1182
1183 2012-06-01  Brady Eidson  <beidson@apple.com>
1184
1185         <rdar://problem/11335622> and https://bugs.webkit.org/show_bug.cgi?id=88119
1186         REGRESSION (r99448) Zero-sized plug-ins no longer get an NPP_SetWindow call
1187         
1188         Followup to r119260
1189
1190         Rubber-stamped by Anders Carlsson. 
1191
1192         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
1193         (WebKit::NetscapePlugin::callSetWindow): Set the m_hasCalledSetWindow here...
1194         (WebKit::NetscapePlugin::geometryDidChange): ...instead of here.
1195
1196 2012-06-01  Brady Eidson  <beidson@apple.com>
1197
1198         <rdar://problem/11335622> and https://bugs.webkit.org/show_bug.cgi?id=88119
1199         REGRESSION (r99448) Zero-sized plug-ins no longer get an NPP_SetWindow call
1200
1201         Reviewed by Oliver Hunt.
1202
1203         Add a flag to NetscapePlugin to track whether or not NPP_SetWindow has ever been called.
1204         Check this flag in geometryDidChange to make sure every plug-in gets the call at least once.
1205
1206         "Everybody gets one.  Tell him, Peter."
1207         "Apparently everybody gets one."
1208         "Bingo."
1209
1210         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
1211         (WebKit::NetscapePlugin::NetscapePlugin):
1212         (WebKit::NetscapePlugin::geometryDidChange):
1213         * WebProcess/Plugins/Netscape/NetscapePlugin.h:
1214         (NetscapePlugin):
1215
1216 2012-06-01  Dinu Jacob  <dinu.jacob@nokia.com>
1217
1218         [WK2] WebLayerTreeRenderer::setContentsSize called synchronously
1219         https://bugs.webkit.org/show_bug.cgi?id=88091
1220
1221         Reviewed by Noam Rosenthal.
1222
1223         Do not call WebLayerTreeRenderer::setContentsSize synchronously
1224         from LayerTreeHostProxy.
1225  
1226         * UIProcess/LayerTreeHostProxy.cpp:
1227         (WebKit::LayerTreeHostProxy::setContentsSize):
1228
1229 2012-06-01  Dinu Jacob  <dinu.jacob@nokia.com>
1230
1231         [Qt][WK2] Set QWebKitTest::isScalable default as false
1232         https://bugs.webkit.org/show_bug.cgi?id=88095
1233
1234         Reviewed by Tor Arne Vestbø.
1235
1236         Set QWebKitTest::isScalable default as false
1237
1238         * UIProcess/API/qt/qwebkittest.cpp:
1239         (QWebKitTest::isScalable):
1240
1241 2012-06-01  Allan Sandfeld Jensen  <allan.jensen@nokia.com>
1242
1243         [Qt] Remove QtViewportInteractionEngine::pageItemSizeChanged.
1244         https://bugs.webkit.org/show_bug.cgi?id=88082
1245
1246         Reviewed by Kenneth Rohde Christiansen.
1247
1248         The function was causing flickering, and after testing it was verified
1249         that it was no longer needed either.
1250
1251         * UIProcess/qt/QtViewportInteractionEngine.cpp:
1252         (WebKit::QtViewportInteractionEngine::QtViewportInteractionEngine):
1253         * UIProcess/qt/QtViewportInteractionEngine.h:
1254         (QtViewportInteractionEngine):
1255
1256 2012-06-01  Dinu Jacob  <dinu.jacob@nokia.com>
1257
1258         [Qt][WK2] Contents not rendered in MiniBrowser for some pages
1259         https://bugs.webkit.org/show_bug.cgi?id=87922
1260
1261         Reviewed by Kenneth Rohde Christiansen.
1262
1263         Set drawing area visible contents rect if new visible contents rect is different from
1264         the previous one.
1265
1266         * UIProcess/qt/QtViewportInteractionEngine.cpp:
1267         (WebKit::QtViewportInteractionEngine::informVisibleContentChange):
1268         * UIProcess/qt/QtViewportInteractionEngine.h:
1269         (QtViewportInteractionEngine):
1270
1271 2012-06-01  Kenneth Rohde Christiansen  <kenneth@webkit.org>
1272
1273         [Qt] Move suspension to QtViewportInteractionEngine
1274         https://bugs.webkit.org/show_bug.cgi?id=88078
1275
1276         Reviewed by Simon Hausmann.
1277
1278         Next step is to take care of visibility changes.
1279
1280         * UIProcess/API/qt/qquickwebview.cpp:
1281         (QQuickWebViewFlickablePrivate::QQuickWebViewFlickablePrivate):
1282         (QQuickWebViewFlickablePrivate::onComponentComplete):
1283         * UIProcess/API/qt/qquickwebview_p.h:
1284         * UIProcess/API/qt/qquickwebview_p_p.h:
1285         (QQuickWebViewPrivate):
1286         (QQuickWebViewFlickablePrivate):
1287         * UIProcess/qt/QtViewportInteractionEngine.cpp:
1288         (WebKit::ViewportUpdateDeferrer::ViewportUpdateDeferrer):
1289         (WebKit::ViewportUpdateDeferrer::~ViewportUpdateDeferrer):
1290         (WebKit::QtViewportInteractionEngine::suspendPageContent):
1291         (WebKit):
1292         (WebKit::QtViewportInteractionEngine::resumePageContent):
1293         * UIProcess/qt/QtViewportInteractionEngine.h:
1294         (QtViewportInteractionEngine):
1295
1296 2012-06-01  Dinu Jacob  <dinu.jacob@nokia.com>
1297
1298         [Qt][W2] Qml Error in ViewportInfoItem.qml in MiniBrowser
1299         https://bugs.webkit.org/show_bug.cgi?id=87999
1300
1301         Reviewed by Kenneth Rohde Christiansen.
1302
1303         Return default viewport attributes rather than invalid QVariant.
1304
1305         * UIProcess/API/qt/qwebkittest.cpp:
1306         (QWebKitTest::contentsScale):
1307         (QWebKitTest::devicePixelRatio):
1308         (QWebKitTest::initialScale):
1309         (QWebKitTest::minimumScale):
1310         (QWebKitTest::maximumScale):
1311         (QWebKitTest::isScalable):
1312         (QWebKitTest::layoutSize):
1313
1314 2012-05-31  Kenneth Rohde Christiansen  <kenneth@webkit.org>
1315
1316         [Qt] Clean up our viewport handling mess
1317         https://bugs.webkit.org/show_bug.cgi?id=87977
1318
1319         Reviewed by Simon Hausmann.
1320
1321         Consolidated functionality from QQuickWebViewPrivate* into
1322         ViewportInteractionEngine that belongs there, in preparation for
1323         renaming ViewportInteractionEngine in the future.
1324
1325         Remove unneeded methods and move others to private.
1326
1327         * UIProcess/API/qt/qquickwebview.cpp:
1328         (QQuickWebViewFlickablePrivate::QQuickWebViewFlickablePrivate):
1329         (QQuickWebViewFlickablePrivate::onComponentComplete):
1330         (QQuickWebViewFlickablePrivate::didChangeViewportProperties):
1331         (QQuickWebViewFlickablePrivate::updateViewportSize):
1332         (QQuickWebViewFlickablePrivate::_q_resume):
1333         (QQuickWebViewFlickablePrivate::pageDidRequestScroll):
1334         * UIProcess/API/qt/qquickwebview_p.h:
1335         * UIProcess/API/qt/qquickwebview_p_p.h:
1336         (QQuickWebViewPrivate):
1337         (QQuickWebViewFlickablePrivate):
1338         * UIProcess/qt/QtViewportInteractionEngine.cpp:
1339         (WebKit::ViewportUpdateDeferrer::~ViewportUpdateDeferrer):
1340         (WebKit::QtViewportInteractionEngine::QtViewportInteractionEngine):
1341         (WebKit::QtViewportInteractionEngine::viewportAttributesChanged):
1342         (WebKit::QtViewportInteractionEngine::pageContentsSizeChanged):
1343         (WebKit::QtViewportInteractionEngine::pageItemPositionChanged):
1344         (WebKit::QtViewportInteractionEngine::pageContentPositionRequested):
1345         (WebKit::QtViewportInteractionEngine::visibleContentsRect):
1346         (WebKit):
1347         (WebKit::QtViewportInteractionEngine::informVisibleContentChange):
1348         (WebKit::QtViewportInteractionEngine::viewportItemSizeChanged):
1349         * UIProcess/qt/QtViewportInteractionEngine.h:
1350         (WebKit):
1351         (QtViewportInteractionEngine):
1352
1353 2012-05-31  Hajime Morrita  <morrita@chromium.org>
1354
1355         REGRESSION(r117572): editing/spelling/spellcheck-async-remove-frame.html crashes on Mac
1356         https://bugs.webkit.org/show_bug.cgi?id=86859
1357
1358         Reviewed by Ryosuke Niwa.
1359
1360         * WebProcess/WebCoreSupport/WebEditorClient.cpp:
1361         (WebKit::WebEditorClient::requestCheckingOfString):
1362         * WebProcess/WebCoreSupport/WebEditorClient.h:
1363
1364 2012-05-31  Andy Estes  <aestes@apple.com>
1365
1366         [WebKit2] Remove nested #if conditions from messages.in files
1367         https://bugs.webkit.org/show_bug.cgi?id=88039
1368
1369         Reviewed by Filip Pizlo.
1370
1371         The code generator that processes messages.in files can't handle nested
1372         #if conditions. Sadly I added said conditions in r117700 but failed to
1373         verify the generated result. Un-nest the conditions I added.
1374
1375         * UIProcess/WebPageProxy.messages.in:
1376         * WebProcess/WebPage/WebPage.messages.in:
1377
1378 2012-05-31  Andy Estes  <aestes@apple.com>
1379
1380         Disentangle code that relies on USE(AUTOMATIC_TEXT_REPLACEMENT) from that which merely relies on PLATFORM(MAC)
1381         https://bugs.webkit.org/show_bug.cgi?id=87933
1382
1383         Reviewed by Dan Bernstein.
1384
1385         * WebProcess/WebCoreSupport/WebEditorClient.h:
1386         * WebProcess/WebCoreSupport/mac/WebEditorClientMac.mm:
1387
1388 2012-05-31  Carlos Garcia Campos  <cgarcia@igalia.com>
1389
1390         [GTK] Add webkit_download_get_request to WebKit2 GTK+ API
1391         https://bugs.webkit.org/show_bug.cgi?id=87957
1392
1393         Reviewed by Martin Robinson.
1394
1395         * UIProcess/API/gtk/WebKitDownload.cpp:
1396         (webkit_download_get_request): Return the WebKitURIRequest
1397         representing the request that originated the download.
1398         * UIProcess/API/gtk/WebKitDownload.h:
1399         * UIProcess/API/gtk/docs/webkit2gtk-sections.txt: Add new symbol.
1400         * UIProcess/API/gtk/tests/TestDownloads.cpp:
1401         (testDownloadLocalFile):
1402         (testDownloadRemoteFile):
1403
1404 2012-05-31  Carlos Garcia Campos  <cgarcia@igalia.com>
1405
1406         [SOUP] WebProcess crashes when a download is started from an existing ResourceHandle
1407         https://bugs.webkit.org/show_bug.cgi?id=87953
1408
1409         Reviewed by Martin Robinson.
1410
1411         The output stream to write the downloaded data is created in the
1412         didReceiveResponse callback of the download client. When a
1413         download is created for an existing ResourceHandle (this happens
1414         for example when policy decision is download), the response has
1415         already been received. In this case we should make sure that the
1416         download client is notified about the response, so that when data
1417         actually arrives the output stream has already been created.
1418
1419         * WebProcess/Downloads/soup/DownloadSoup.cpp:
1420         (WebKit::Download::startWithHandle):
1421
1422 2012-05-31  Carlos Garcia Campos  <cgarcia@igalia.com>
1423
1424         [GTK] Fix webkit_web_view_can_execute_editing_command() API doc
1425         https://bugs.webkit.org/show_bug.cgi?id=87930
1426
1427         Reviewed by Martin Robinson.
1428
1429         * UIProcess/API/gtk/WebKitWebView.cpp:
1430
1431 2012-05-31  Tor Arne Vestbø  <tor.arne.vestbo@nokia.com>
1432
1433         [Qt] Simplify QT_VERSION_CHECKS for Qt5 by introducing HAVE(QT5)
1434         https://bugs.webkit.org/show_bug.cgi?id=87955
1435
1436         Reviewed by Simon Hausmann.
1437
1438         * UIProcess/API/qt/tests/publicapi/tst_publicapi.cpp:
1439
1440 2012-05-31  Zalan Bujtas  <zbujtas@gmail.com>
1441
1442         [Qt][WK2] Add missing ViewportUpdateDeferrer guarding to setPageItemRectVisible() calls.
1443         https://bugs.webkit.org/show_bug.cgi?id=87936
1444
1445         Reviewed by Kenneth Rohde Christiansen.
1446
1447         * UIProcess/qt/QtViewportInteractionEngine.cpp:
1448         (WebKit::QtViewportInteractionEngine::viewportAttributesChanged):
1449         (WebKit::QtViewportInteractionEngine::pageContentsSizeChanged):
1450
1451 2012-05-31  Keunsoon Lee  <keunsoon.lee@samsung.com>
1452
1453         [EFL][WK2] Add WKURLRequestEfl and WKURLResponseEfl
1454         https://bugs.webkit.org/show_bug.cgi?id=70231
1455
1456         Reviewed by Chang Shu.
1457
1458         These codes can be used for WKPageDecidePolicyForResponseCallback on page policy callbacks.
1459         The callback conveys WKURLResponseRef and WKURLRequestRef as parameter.
1460
1461         By the way, EFL browser needs content type from response to decide correct policy.
1462         Another information, cookie, is necessary with similar reason.
1463         But, there is no way to obtain such information on WebKit2 main stream, except for WKURLRequestCopyURL().
1464
1465         So, EFL port created those files to extract necessary information from WKURLResponseRef and WKURLRequestRef,
1466         and not to desturb WebKit2 main stream. 
1467
1468         * Shared/API/c/efl/WKURLRequestEfl.cpp: Added.
1469         (WKURLRequestEflCopyCookies): extracting cookie information from WKURLRequestRef.
1470         * Shared/API/c/efl/WKURLRequestEfl.h: Added.
1471         * Shared/API/c/efl/WKURLResponseEfl.cpp: Added.
1472         (WKURLResponseEflCopyContentType): extracting content type (i.e. MIME type) from WKURLResponseRef.
1473         * Shared/API/c/efl/WKURLResponseEfl.h: Added.
1474         * Shared/efl/WebCoreArgumentCodersEfl.cpp: Added.
1475         (CoreIPC):
1476         (CoreIPC::::encode):
1477         (CoreIPC::::decode):
1478         * Shared/efl/WebURLRequestEfl.cpp: Added.
1479         (WebKit):
1480         (WebKit::WebURLRequestEfl::WebURLRequestEfl):
1481         (WebKit::WebURLRequestEfl::cookies): obtaining cookie information from ResourceRequest.
1482         * Shared/efl/WebURLRequestEfl.h: Added.
1483         (WebKit):
1484         (WebURLRequestEfl):
1485         (WebKit::WebURLRequestEfl::create):
1486         * Shared/efl/WebURLResponseEfl.cpp: Added.
1487         (WebKit):
1488         (WebKit::WebURLResponseEfl::WebURLResponseEfl):
1489         (WebKit::WebURLResponseEfl::contentType): obtaining content type (i.e. MIME type) from ResourceResponse.
1490         * Shared/efl/WebURLResponseEfl.h: Added.
1491         (WebKit):
1492         (WebURLResponseEfl):
1493         (WebKit::WebURLResponseEfl::create):
1494
1495 2012-05-31  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
1496
1497         [EFL][WK2] Rename ewk_private.h to ewk_view_private.h
1498         https://bugs.webkit.org/show_bug.cgi?id=87923
1499
1500         Reviewed by Kenneth Rohde Christiansen.
1501
1502         EFL WK1 decided to divide up ewk_private.h into each file's XXX_private.h file in order to maintain
1503         internal functions more easily. EFL WK2 needs to adjust this as well.
1504
1505         * UIProcess/API/efl/PageClientImpl.cpp:
1506         * UIProcess/API/efl/ewk_view_private.h: Renamed from Source/WebKit2/UIProcess/API/efl/ewk_private.h.
1507         (WebCore):
1508         * UIProcess/cairo/BackingStoreCairo.cpp:
1509
1510 2012-05-31  Andy Estes  <aestes@apple.com>
1511
1512         Move the specification of framework and library linking out of WebKit2.xcodeproj and into WebKit2.xcconfig
1513         https://bugs.webkit.org/show_bug.cgi?id=87932
1514
1515         Reviewed by Dan Bernstein.
1516
1517         Doing this makes it easier to vary linking based on SDK or other factors.
1518
1519         * Configurations/WebKit2.xcconfig: Create FRAMEWORK_AND_LIBRARY_LDFLAGS,
1520         which specifies the same list of frameworks and libraries that were
1521         previously in WebKit2's 'Link Binary With Libraries' build phase, and
1522         append it to $(OTHER_LDFLAGS).
1523         * WebKit2.xcodeproj/project.pbxproj: Remove all frameworks and
1524         libraries from the 'Link Binary With Libraries' build phase.
1525
1526 2012-05-30  Sudarsana Nagineni  <sudarsana.nagineni@linux.intel.com>
1527
1528         [GTK] [WK2] Memory leak in webkitWebViewBaseStartDrag
1529         https://bugs.webkit.org/show_bug.cgi?id=87756
1530
1531         Reviewed by Carlos Garcia Campos.
1532
1533         Fixed memory leaks in drag and drop by using adoptRef instead
1534         of just getting new references.
1535
1536         * UIProcess/API/gtk/WebKitWebViewBase.cpp:
1537         (webkitWebViewBaseStartDrag):
1538
1539 2012-05-30  Luiz Agostini  <luiz.agostini@nokia.com>
1540
1541         [Qt] handled touchmove events should not cancel tap gesture recognition
1542         https://bugs.webkit.org/show_bug.cgi?id=87808
1543
1544         Reviewed by Kenneth Rohde Christiansen.
1545
1546         Tap gesture recognition should not be canceled if a touchmove event is handled
1547         by the web process.
1548
1549         * UIProcess/qt/QtWebPageEventHandler.cpp:
1550         (WebKit::QtWebPageEventHandler::doneWithTouchEvent):
1551
1552 2012-05-30  Mario Sanchez Prada  <msanchez@igalia.com>
1553
1554         [GTK][WK2] Errors in documentation about  webkit_web_view_run_javascript()
1555         https://bugs.webkit.org/show_bug.cgi?id=87866
1556
1557         Reviewed by Martin Robinson.
1558
1559         * UIProcess/API/gtk/WebKitWebView.cpp: Fix errors.
1560
1561 2012-05-30  Andy Estes  <aestes@apple.com>
1562
1563         WebProcessMainMac.mm doesn't need to import WKView.h.
1564
1565         Rubber-stamped by Anders Carlsson. 
1566
1567         * WebProcess/mac/WebProcessMainMac.mm:
1568
1569 2012-05-30  Marcelo Lira  <marcelo.lira@openbossa.org>
1570
1571         WebKit2: Implement layoutTestController.setPluginsEnabled() in WebKitTestRunner.
1572         https://bugs.webkit.org/show_bug.cgi?id=58593
1573
1574         Adds the ability to change the pluginsEnabled flag in WebCore::Settings
1575         to WebKitTestRunner's LayoutTestController. The flag is modified via the
1576         public C API of the WebProcess.
1577
1578         Reviewed by Darin Adler.
1579
1580         * WebProcess/InjectedBundle/API/c/WKBundle.cpp:
1581         (WKBundleSetPluginsEnabled):
1582         * WebProcess/InjectedBundle/API/c/WKBundlePrivate.h:
1583         * WebProcess/InjectedBundle/InjectedBundle.cpp:
1584         (WebKit::InjectedBundle::setPluginsEnabled): Calls the setPluginsEnabled
1585         method for the WebCore::Settings of each WebCore::Page in the current
1586         page group.
1587         (WebKit):
1588         * WebProcess/InjectedBundle/InjectedBundle.h:
1589         (InjectedBundle):
1590
1591 2012-05-30  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>
1592
1593         HashTable.h has using directives for std::pair and std::make_pair
1594         https://bugs.webkit.org/show_bug.cgi?id=29919
1595
1596         Reviewed by Darin Adler.
1597
1598         Change code to use std::pair and std::make_pair.
1599
1600         * UIProcess/Launcher/mac/DynamicLinkerEnvironmentExtractor.mm:
1601         (WebKit::DynamicLinkerEnvironmentExtractor::processEnvironmentVariable):
1602         * UIProcess/WebContext.cpp:
1603         (WebKit::WebContext::postMessageToInjectedBundle):
1604
1605 2012-05-30  Kenneth Rohde Christiansen  <kenneth@webkit.org>
1606
1607         Unreviewed: Fix wrongly typed Qt slot.
1608
1609         * UIProcess/qt/QtViewportInteractionEngine.cpp:
1610         (WebKit::QtViewportInteractionEngine::QtViewportInteractionEngine):
1611
1612 2012-05-30  Kenneth Rohde Christiansen  <kenneth@webkit.org>
1613
1614         [Qt] Move ViewportAttribute related methods to the interaction engine.
1615         https://bugs.webkit.org/show_bug.cgi?id=87855
1616
1617         Reviewed by Simon Hausmann.
1618
1619         Move the logic of didChange{ViewportProperties|ContentsSize} to the
1620         interaction engine and update our testing object.
1621
1622         * UIProcess/API/qt/qquickwebview.cpp:
1623         (QQuickWebViewLegacyPrivate::QQuickWebViewLegacyPrivate):
1624         (QQuickWebViewFlickablePrivate::didChangeViewportProperties):
1625         (QQuickWebViewFlickablePrivate::didChangeContentsSize):
1626         * UIProcess/API/qt/qquickwebview_p_p.h:
1627         (QQuickWebViewPrivate):
1628         * UIProcess/API/qt/qwebkittest.cpp:
1629         (QWebKitTest::contentsScale):
1630         (QWebKitTest::devicePixelRatio):
1631         (QWebKitTest::initialScale):
1632         (QWebKitTest::minimumScale):
1633         (QWebKitTest::maximumScale):
1634         (QWebKitTest::isScalable):
1635         (QWebKitTest::layoutSize):
1636         * UIProcess/qt/QtViewportInteractionEngine.cpp:
1637         (WebKit::QtViewportInteractionEngine::viewportAttributesChanged):
1638         (WebKit):
1639         (WebKit::QtViewportInteractionEngine::pageContentsSizeChanged):
1640         * UIProcess/qt/QtViewportInteractionEngine.h:
1641         (QtViewportInteractionEngine):
1642
1643 2012-05-30  Kenneth Rohde Christiansen  <kenneth@webkit.org>
1644
1645         [Qt] Do renames in ViewportInteractionEngine as agreed upon
1646         https://bugs.webkit.org/show_bug.cgi?id=87845
1647
1648         Reviewed by Simon Hausmann.
1649
1650         Mostly moving methods around and renaming them to be more
1651         consistent and avoid terminology clashes.
1652
1653         * UIProcess/API/qt/qquickwebview.cpp:
1654         (QQuickWebViewFlickablePrivate::didChangeViewportProperties):
1655         (QQuickWebViewFlickablePrivate::pageDidRequestScroll):
1656         (QQuickWebViewFlickablePrivate::didChangeContentsSize):
1657         * UIProcess/qt/QtViewportInteractionEngine.cpp:
1658         (WebKit::boundPosition):
1659         (WebKit):
1660         (WebKit::QtViewportInteractionEngine::QtViewportInteractionEngine):
1661         (WebKit::QtViewportInteractionEngine::setPageItemRectVisible):
1662         (WebKit::QtViewportInteractionEngine::animatePageItemRectVisible):
1663         (WebKit::QtViewportInteractionEngine::flickMoveStarted):
1664         (WebKit::QtViewportInteractionEngine::flickMoveEnded):
1665         (WebKit::QtViewportInteractionEngine::pageItemPositionChanged):
1666         (WebKit::QtViewportInteractionEngine::pageContentPositionRequest):
1667         (WebKit::QtViewportInteractionEngine::scaleAnimationValueChanged):
1668         (WebKit::QtViewportInteractionEngine::computePosRangeForPageItemAtScale):
1669         (WebKit::QtViewportInteractionEngine::focusEditableArea):
1670         (WebKit::QtViewportInteractionEngine::zoomToAreaGestureEnded):
1671         (WebKit::QtViewportInteractionEngine::nearestValidBounds):
1672         (WebKit::QtViewportInteractionEngine::cancelScrollAnimation):
1673         (WebKit::QtViewportInteractionEngine::pinchGestureEnded):
1674         (WebKit::QtViewportInteractionEngine::pageItemSizeChanged):
1675         * UIProcess/qt/QtViewportInteractionEngine.h:
1676         (WebKit::QtViewportInteractionEngine::setDevicePixelRatio):
1677         (QtViewportInteractionEngine):
1678
1679 2012-05-30  Mariusz Grzegorczyk  <mariusz.g@samsung.com>, Ryuan Choi  <ryuan.choi@samsung.com>
1680
1681         [EFL][WK2] Fix WebKit2-EFL build
1682         https://bugs.webkit.org/show_bug.cgi?id=83693
1683
1684         Reviewed by Carlos Garcia Campos.
1685
1686         * CMakeLists.txt: Move IDL generator codes to generate port specific *.messages.in.
1687         * PlatformEfl.cmake: Add soup related files after r115411 and includes to fix build break.
1688         * UIProcess/API/efl/PageClientImpl.cpp: Fix build break with ENABLE_TOUCH_EVENTS.
1689         (WebKit):
1690         (WebKit::PageClientImpl::doneWithTouchEvent):
1691         * UIProcess/API/efl/PageClientImpl.h:
1692         (PageClientImpl):
1693         * WebProcess/WebCoreSupport/WebChromeClient.cpp: Fix build break with ENABLE_INPUT_TYPE_COLOR and ENABLE_REGISTER_PROTOCOL_HANDLER.
1694         (WebKit):
1695         (WebKit::WebChromeClient::createColorChooser):
1696         * WebProcess/WebCoreSupport/WebChromeClient.h:
1697         (WebChromeClient):
1698         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp: Fix build break with ENABLE_WEB_INTENTS
1699         (WebKit):
1700         (WebKit::WebFrameLoaderClient::dispatchIntent):
1701         * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
1702         (WebCore):
1703         (WebFrameLoaderClient):
1704         * WebProcess/WebProcess.cpp: Guard PLATFORM_STRATEGIES codes.
1705         (WebKit::WebProcess::didGetPlugins):
1706         * WebProcess/soup/WebSoupRequestManager.cpp: Try to share with EFL port.
1707         (WebKit::WebSoupRequestManager::didHandleURIRequest):
1708
1709 2012-05-30  Kenneth Rohde Christiansen  <kenneth@webkit.org>
1710
1711         [Qt] Variable renaming as preparation of further refactoring.
1712
1713         Rubberstamped by Simon Hausmann.
1714
1715         Change m_viewport to m_viewportItem and m_content to m_pageItem.
1716
1717         * UIProcess/qt/QtViewportInteractionEngine.cpp:
1718         (WebKit::QtViewportInteractionEngine::QtViewportInteractionEngine):
1719         (WebKit::QtViewportInteractionEngine::setItemRectVisible):
1720         (WebKit::QtViewportInteractionEngine::animateItemRectVisible):
1721         (WebKit::QtViewportInteractionEngine::flickableMoveStarted):
1722         (WebKit::QtViewportInteractionEngine::flickableMoveEnded):
1723         (WebKit::QtViewportInteractionEngine::flickableMovingPositionUpdate):
1724         (WebKit::QtViewportInteractionEngine::scaleAnimationStateChanged):
1725         (WebKit::QtViewportInteractionEngine::pagePositionRequest):
1726         (WebKit::QtViewportInteractionEngine::computePosRangeForItemAtScale):
1727         (WebKit::QtViewportInteractionEngine::focusEditableArea):
1728         (WebKit::QtViewportInteractionEngine::zoomToAreaGestureEnded):
1729         (WebKit::QtViewportInteractionEngine::nearestValidBounds):
1730         (WebKit::QtViewportInteractionEngine::reset):
1731         (WebKit::QtViewportInteractionEngine::setCSSScale):
1732         (WebKit::QtViewportInteractionEngine::currentCSSScale):
1733         (WebKit::QtViewportInteractionEngine::scrollAnimationActive):
1734         (WebKit::QtViewportInteractionEngine::panGestureActive):
1735         (WebKit::QtViewportInteractionEngine::panGestureStarted):
1736         (WebKit::QtViewportInteractionEngine::panGestureRequestUpdate):
1737         (WebKit::QtViewportInteractionEngine::panGestureEnded):
1738         (WebKit::QtViewportInteractionEngine::panGestureCancelled):
1739         (WebKit::QtViewportInteractionEngine::cancelScrollAnimation):
1740         (WebKit::QtViewportInteractionEngine::pinchGestureStarted):
1741         (WebKit::QtViewportInteractionEngine::pinchGestureRequestUpdate):
1742         (WebKit::QtViewportInteractionEngine::scaleContent):
1743         * UIProcess/qt/QtViewportInteractionEngine.h:
1744         (QtViewportInteractionEngine):
1745
1746 2012-05-30  Zalan Bujtas  <zbujtas@gmail.com>
1747
1748         [Qt][WK2] Do not use anonymous variables for ViewportUpdateDeferrer.
1749         https://bugs.webkit.org/show_bug.cgi?id=87831
1750
1751         Reviewed by Kenneth Rohde Christiansen.
1752
1753         * UIProcess/qt/QtViewportInteractionEngine.cpp:
1754         (WebKit::QtViewportInteractionEngine::pagePositionRequest):
1755         (WebKit::QtViewportInteractionEngine::cancelScrollAnimation):
1756         (WebKit::QtViewportInteractionEngine::itemSizeChanged):
1757
1758 2012-05-30  Carlos Garcia Campos  <cgarcia@igalia.com>
1759
1760         Unreviewed. Fix WebKit2GTK+ API tests in the bots.
1761
1762         * UIProcess/API/gtk/tests/TestWebKitWebView.cpp:
1763         (testWebViewCanShowMIMEType): Remove the check for multimedia and
1764         plugins MIME types since they depend on the configuration and they
1765         are not available in the bots.
1766
1767 2012-05-29  Jer Noble  <jer.noble@apple.com>
1768
1769         Noticeable delay taking an HTML5 trailer fullscreen.
1770         https://bugs.webkit.org/show_bug.cgi?id=87794
1771
1772         Reviewed by Darin Adler.
1773
1774         Work around a not-entirely understood delay when using the results of a CGWindowListCreateImage()
1775         call as the contents of a placeholder view.  The backing of the resulting CGImageRef resides on
1776         the WindowServer, and drawing that image requires synchronous calls to the WindowServer process.
1777         By copying the image data, up front, into our own process, we can avoid those synchronous calls
1778         later and avoid the delay-causing drawing behavior.
1779
1780         * UIProcess/mac/WKFullScreenWindowController.mm:
1781         (CGImageDeepCopy): Added a helper function which copies the image data into a new CGImage.
1782         (-[WKFullScreenWindowController enterFullScreen:]): Use the above.
1783
1784 2012-05-29  Sudarsana Nagineni  <sudarsana.nagineni@linux.intel.com>
1785
1786         [GTK] [WK2] Reproducible crash in performDragControllerAction
1787         https://bugs.webkit.org/show_bug.cgi?id=87744
1788
1789         Reviewed by Martin Robinson.
1790
1791         Fix a crash by using deref() instead of delete to dereference and
1792         release the platformData of DragData.
1793
1794         * WebProcess/WebPage/WebPage.cpp:
1795         (WebKit::WebPage::performDragControllerAction):
1796
1797 2012-05-29  Simon Pena  <spena@igalia.com>
1798
1799         [GTK] Missing field initializers for WKPageLoaderClient and WKPageUIClient
1800         https://bugs.webkit.org/show_bug.cgi?id=87745
1801
1802         Reviewed by Carlos Garcia Campos.
1803
1804         Add missing initializers for WKPageLoaderClient and
1805         WKPageUIClient, for callbacks WKPagePluginDidFailCallback and
1806         WKPageUnavailablePluginButtonClickedCallback, introduced in
1807         revision r116716.
1808
1809         * UIProcess/API/gtk/WebKitLoaderClient.cpp:
1810         (attachLoaderClientToView): Initialize WKPagePluginDidFailCallback
1811         * UIProcess/API/gtk/WebKitUIClient.cpp:
1812         (attachUIClientToView): Initialize callback
1813         WKPageUnavailablePluginButtonClickedCallback
1814
1815 2012-05-29  Carlos Garcia Campos  <cgarcia@igalia.com>
1816
1817         [GTK] Policy decision headers are not included in the main webkit2.h header
1818         https://bugs.webkit.org/show_bug.cgi?id=87753
1819
1820         Reviewed by Martin Robinson.
1821
1822         * UIProcess/API/gtk/webkit2.h: Include
1823         WebKitNavigationPolicyDecision.h and WebKitResponsePolicyDecision.h.
1824
1825 2012-05-29  Carlos Garcia Campos  <cgarcia@igalia.com>
1826
1827         [GTK] Add webkit_web_view_can_show_mime_type() to WebKit2 GTK+ API
1828         https://bugs.webkit.org/show_bug.cgi?id=85998
1829
1830         Reviewed by Martin Robinson.
1831
1832         And use it in the default handler of WebKitWebView::decide-policy
1833         signal to decide whether to use or ignore a response policy
1834         decision depending on whether the mime type of the response can be
1835         displayed in the WebView or not.
1836
1837         * UIProcess/API/gtk/WebKitURIResponse.cpp:
1838         (webkitURIResponseGetProperty): Add getter for mime-type property.
1839         (webkit_uri_response_class_init): Add mime-type property.
1840         (webkit_uri_response_get_mime_type): Return the mime type of the
1841         response.
1842         * UIProcess/API/gtk/WebKitURIResponse.h:
1843         * UIProcess/API/gtk/WebKitWebView.cpp:
1844         (webkitWebViewDecidePolicy): In case of response policy decisions,
1845         use the URI response to decide what to do: download if the
1846         response is an attachment, use if the mime type is supported by
1847         the web view or ignore otherwise.
1848         (webkit_web_view_can_show_mime_type): Returns whether the given
1849         mime type can be displayed in the WebView or not.
1850         * UIProcess/API/gtk/WebKitWebView.h:
1851         * UIProcess/API/gtk/docs/webkit2gtk-sections.txt: Add new symbols.
1852         * UIProcess/API/gtk/tests/TestResources.cpp:
1853         (testWebResourceResponse):
1854         (testWebResourceMimeType):
1855         (serverCallback):
1856         (beforeAll):
1857         * UIProcess/API/gtk/tests/TestWebKitWebView.cpp:
1858         (testWebViewCanShowMIMEType):
1859         (beforeAll):
1860
1861 2012-05-29  David Barr  <davidbarr@chromium.org>
1862
1863         Introduce ENABLE_CSS_IMAGE_RESOLUTION compile flag
1864         https://bugs.webkit.org/show_bug.cgi?id=87685
1865
1866         Reviewed by Eric Seidel.
1867
1868         Add a configuration option for CSS image-resolution support, disabling it by default.
1869
1870         * Configurations/FeatureDefines.xcconfig:
1871
1872 2012-05-29  Kenneth Rohde Christiansen  <kenneth@webkit.org>
1873
1874         [Qt] Move tests from DesktopBehavior which can be made to work
1875         https://bugs.webkit.org/show_bug.cgi?id=87736
1876
1877         Rubberstamped by Simon Hausmann.
1878
1879         Move and modify the following tests to WebView/ and make them
1880         use touch events.
1881
1882         * UIProcess/API/qt/tests/qmltests/WebView/tst_itemSelector.qml: Renamed from Source/WebKit2/UIProcess/API/qt/tests/qmltests/DesktopBehavior/tst_itemSelector.qml.
1883         * UIProcess/API/qt/tests/qmltests/WebView/tst_messaging.qml: Renamed from Source/WebKit2/UIProcess/API/qt/tests/qmltests/DesktopBehavior/tst_messaging.qml.
1884         * UIProcess/API/qt/tests/qmltests/WebView/tst_multiFileUpload.qml: Renamed from Source/WebKit2/UIProcess/API/qt/tests/qmltests/DesktopBehavior/tst_multiFileUpload.qml.
1885         * UIProcess/API/qt/tests/qmltests/WebView/tst_singleFileUpload.qml: Renamed from Source/WebKit2/UIProcess/API/qt/tests/qmltests/DesktopBehavior/tst_singleFileUpload.qml.
1886
1887 2012-05-29  Tor Arne Vestbø  <tor.arne.vestbo@nokia.com>
1888
1889         [Qt] Sync up favicon-implementation with WebView url changes in r118158
1890
1891         https://bugs.webkit.org/show_bug.cgi?id=87133
1892
1893         We now base64-encode the page url in the image-provider url, so that any
1894         normalization done by QUrl will not mess up the page-url. The logic of
1895         creating and parsing the provider-url has been moved into the image
1896         provider, to keep it in one place.
1897
1898         We were also releasing icons (even ones we hadn't retained), which we can't
1899         do since we don't know when the icon url is no longer in use.
1900
1901         Reviewed-by Simon Hausmann.
1902
1903         * UIProcess/API/qt/qquickwebview.cpp:
1904         (QQuickWebViewPrivate::initialize):
1905         (QQuickWebViewPrivate::loadProgressDidChange):
1906         (QQuickWebViewPrivate::_q_onUrlChanged):
1907         (QQuickWebViewPrivate::_q_onIconChangedForPageURL):
1908         (QQuickWebViewPrivate::updateIcon):
1909         (QQuickWebView::icon):
1910         * UIProcess/API/qt/qquickwebview_p.h:
1911         * UIProcess/API/qt/qquickwebview_p_p.h:
1912         (QQuickWebViewPrivate):
1913         * UIProcess/API/qt/qwebiconimageprovider.cpp:
1914         (QWebIconImageProvider::iconURLForPageURLInContext):
1915         (QWebIconImageProvider::requestImage):
1916         * UIProcess/API/qt/qwebiconimageprovider_p.h:
1917         (WebKit):
1918         * UIProcess/API/qt/tests/qmltests/WebView/tst_favIconLoad.qml:
1919         * UIProcess/qt/QtWebIconDatabaseClient.cpp:
1920         (WebKit::QtWebIconDatabaseClient::didChangeIconForPageURL):
1921         (WebKit::QtWebIconDatabaseClient::iconForPageURL):
1922         (WebKit):
1923         (WebKit::QtWebIconDatabaseClient::iconImageForPageURL):
1924         * UIProcess/qt/QtWebIconDatabaseClient.h:
1925         (QtWebIconDatabaseClient):
1926
1927 2012-05-29  Kenneth Rohde Christiansen  <kenneth@webkit.org>
1928
1929         [Qt][WK2] Fix failing qmltests::FitToView::test_basic()
1930         https://bugs.webkit.org/show_bug.cgi?id=87236
1931
1932         Reviewed by Simon Hausmann.
1933
1934         The fix is a combination of things. First of all some events
1935         were emitted at the wrong times or when nothing had changed.
1936
1937         We also initialized the view saying it was suspended which is
1938         not correct.
1939
1940         Another bug was that the touch tap, didn't result in marking
1941         the view as having user interaction. This was recently fixed
1942         in r118493.
1943
1944         * UIProcess/API/qt/qquickwebpage.cpp:
1945         (QQuickWebPage::setContentsScale):
1946         * UIProcess/API/qt/qquickwebview.cpp:
1947         (QQuickWebViewFlickablePrivate::QQuickWebViewFlickablePrivate):
1948
1949             Make sure pageIsSuspended is initialized to false.
1950
1951         (QQuickWebViewFlickablePrivate::_q_onInformVisibleContentChange):
1952
1953             Early bail out if there is no change.
1954
1955             Inform contentScaleCommitted if the scale changed since last time.
1956
1957         (QQuickWebViewFlickablePrivate::didChangeContentsSize):
1958
1959             Make sure to commit the right signals, ie. *Changed and not *Committed.
1960
1961         * UIProcess/API/qt/qquickwebview_p.h:
1962         * UIProcess/API/qt/qwebkittest.cpp:
1963         (touchPoint):
1964         (QWebKitTest::sendTouchEvent):
1965         (QWebKitTest::touchTap):
1966         (QWebKitTest::touchDoubleTap):
1967
1968             Add proper touch emulation for the testing system. Call directly
1969             to our WebKit API (avoid Qt event loop) to ensure all events gets
1970             delivered.
1971
1972         * UIProcess/API/qt/qwebkittest_p.h:
1973         * UIProcess/qt/QtViewportInteractionEngine.cpp:
1974         (WebKit::QtViewportInteractionEngine::setItemRectVisible):
1975
1976             Assert that a ViewportUpdateDeferrer is always used when calling
1977             this method.
1978
1979         (WebKit::QtViewportInteractionEngine::animateItemRectVisible):
1980
1981             Remove work around now we have the proper fix in place.
1982
1983         (WebKit::QtViewportInteractionEngine::pagePositionRequest):
1984
1985             Do not send the informVisibleContentChange manually, use the
1986             ViewportUpdateDeferrer instead.
1987
1988         (WebKit::QtViewportInteractionEngine::cancelScrollAnimation):
1989
1990             Add missing ViewportUpdateDeferrer.
1991
1992         (WebKit::QtViewportInteractionEngine::pinchGestureStarted):
1993
1994             No reason to emit informVisibleContentChange before pinch
1995             start, as it is always done on end (due to the ViewportUpdateDeferrer).
1996
1997         (WebKit::QtViewportInteractionEngine::itemSizeChanged):
1998
1999             Add missing ViewportUpdateDeferrer.
2000
2001 2012-05-29  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>
2002
2003         [Qt] [WK2] Allow user to inject JS scripts when the page loads
2004         https://bugs.webkit.org/show_bug.cgi?id=85827
2005
2006         Reviewed by Simon Hausmann.
2007
2008         Create a new experimental property to list URLs of JS scripts that should be
2009         loaded when a page is loaded. These scripts will run in the normal JS environment
2010         of the page.
2011
2012         The supported URL schemes are file:/// and qrc:///. The scripts are read from the
2013         UI process and transfered to the Web process.
2014
2015         Together with the experimental messaging API this provides a way for the
2016         application to manipulate the DOM (by injecting a script that does the
2017         manipulation and communicating with it via postMessage). This covers some of the
2018         use cases of QWebElement in our WK1 API.
2019
2020         * UIProcess/API/qt/qquickwebview.cpp:
2021         (QQuickWebViewPrivate::didRelaunchProcess):
2022         (readUserScript):
2023         (QQuickWebViewPrivate::updateUserScripts):
2024         (QQuickWebViewExperimental::userScripts):
2025         (QQuickWebViewExperimental::setUserScripts):
2026         * UIProcess/API/qt/qquickwebview_p.h:
2027         * UIProcess/API/qt/qquickwebview_p_p.h:
2028         (QQuickWebViewPrivate):
2029         * UIProcess/API/qt/tests/qmltests/WebView.pro:
2030         * UIProcess/API/qt/tests/qmltests/WebView/tst_userScripts.qml: Added.
2031         * UIProcess/API/qt/tests/qmltests/common/append-document-title.js: Added.
2032         * UIProcess/API/qt/tests/qmltests/common/big-user-script.js: Added.
2033         * UIProcess/API/qt/tests/qmltests/common/change-document-title.js: Added.
2034         * UIProcess/API/qt/tests/qmltests/resources.qrc: Added.
2035         * UIProcess/WebPageProxy.h:
2036         (WebPageProxy):
2037         * UIProcess/qt/WebPageProxyQt.cpp:
2038         (WebKit::WebPageProxy::setUserScripts):
2039         (WebKit):
2040         * WebProcess/WebPage/WebPage.h:
2041         (WebPage):
2042         * WebProcess/WebPage/WebPage.messages.in:
2043         * WebProcess/WebPage/qt/WebPageQt.cpp:
2044         (WebKit::WebPage::setUserScripts):
2045         (WebKit):
2046
2047 2012-05-29  Sheriff Bot  <webkit.review.bot@gmail.com>
2048
2049         Unreviewed, rolling out r118752.
2050         http://trac.webkit.org/changeset/118752
2051         https://bugs.webkit.org/show_bug.cgi?id=87731
2052
2053         incomplete patch (Requested by cmarcelo on #webkit).
2054
2055         * UIProcess/API/qt/qquickwebview.cpp:
2056         (QQuickWebViewPrivate::didRelaunchProcess):
2057         * UIProcess/API/qt/qquickwebview_p.h:
2058         * UIProcess/API/qt/qquickwebview_p_p.h:
2059         (QQuickWebViewPrivate):
2060         * UIProcess/API/qt/tests/qmltests/WebView.pro:
2061         * UIProcess/WebPageProxy.h:
2062         (WebPageProxy):
2063         * UIProcess/qt/WebPageProxyQt.cpp:
2064         * WebProcess/WebPage/WebPage.h:
2065         (WebPage):
2066         * WebProcess/WebPage/WebPage.messages.in:
2067         * WebProcess/WebPage/qt/WebPageQt.cpp:
2068
2069 2012-05-21  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>
2070
2071         [Qt] [WK2] Allow user to inject JS scripts when the page loads
2072         https://bugs.webkit.org/show_bug.cgi?id=85827
2073
2074         Reviewed by Simon Hausmann.
2075
2076         Create a new experimental property to list URLs of JS scripts that should be
2077         loaded when a page is loaded. These scripts will run in the normal JS environment
2078         of the page.
2079
2080         The supported URL schemes are file:/// and qrc:///. The scripts are read from the
2081         UI process and transfered to the Web process.
2082
2083         Together with the experimental messaging API this provides a way for the
2084         application to manipulate the DOM (by injecting a script that does the
2085         manipulation and communicating with it via postMessage). This covers some of the
2086         use cases of QWebElement in our WK1 API.
2087
2088         * UIProcess/API/qt/qquickwebview.cpp:
2089         (QQuickWebViewPrivate::didRelaunchProcess):
2090         (readUserScript):
2091         (QQuickWebViewPrivate::updateUserScripts):
2092         (QQuickWebViewExperimental::userScripts):
2093         (QQuickWebViewExperimental::setUserScripts):
2094         * UIProcess/API/qt/qquickwebview_p.h:
2095         * UIProcess/API/qt/qquickwebview_p_p.h:
2096         (QQuickWebViewPrivate):
2097         * UIProcess/API/qt/tests/qmltests/WebView.pro:
2098         * UIProcess/API/qt/tests/qmltests/WebView/tst_userScripts.qml: Added.
2099         * UIProcess/API/qt/tests/qmltests/common/append-document-title.js: Added.
2100         * UIProcess/API/qt/tests/qmltests/common/big-user-script.js: Added.
2101         * UIProcess/API/qt/tests/qmltests/common/change-document-title.js: Added.
2102         * UIProcess/API/qt/tests/qmltests/resources.qrc: Added.
2103         * UIProcess/WebPageProxy.h:
2104         (WebPageProxy):
2105         * UIProcess/qt/WebPageProxyQt.cpp:
2106         (WebKit::WebPageProxy::setUserScripts):
2107         (WebKit):
2108         * WebProcess/WebPage/WebPage.h:
2109         (WebPage):
2110         * WebProcess/WebPage/WebPage.messages.in:
2111         * WebProcess/WebPage/qt/WebPageQt.cpp:
2112         (WebKit::WebPage::setUserScripts):
2113         (WebKit):
2114
2115 2012-05-29  Carlos Garcia Campos  <cgarcia@igalia.com>
2116
2117         [GTK] Add return value information to WebKitWebView::load-failed signal documentation
2118         https://bugs.webkit.org/show_bug.cgi?id=87704
2119
2120         Reviewed by Martin Robinson.
2121
2122         * UIProcess/API/gtk/WebKitWebView.cpp:
2123         (webkit_web_view_class_init):
2124
2125 2012-05-29  Carlos Garcia Campos  <cgarcia@igalia.com>
2126
2127         [GTK] Add WebKitWebInspector.h to the list of WebKit2 GTK public headers
2128         https://bugs.webkit.org/show_bug.cgi?id=87703
2129
2130         Reviewed by Martin Robinson.
2131
2132         * GNUmakefile.list.am: Add WebKitWebInspector.h to webkit2gtk_h_api.
2133
2134 2012-05-25  Jesus Sanchez-Palencia  <jesus.palencia@openbossa.org>
2135
2136         WebKitTestRunner needs to support layoutTestController.setJavaScriptProfilingEnabled
2137         https://bugs.webkit.org/show_bug.cgi?id=42328
2138
2139         Reviewed by Eric Seidel.
2140
2141         Removed unneeded setJavaScriptProfilingEnabled function from WTR after its
2142         move to windows.internals.settings.
2143
2144         * WebProcess/InjectedBundle/API/c/WKBundleInspector.cpp:
2145         * WebProcess/InjectedBundle/API/c/WKBundleInspector.h:
2146         * WebProcess/WebPage/WebInspector.cpp:
2147         (WebKit::WebInspector::setJavaScriptProfilingEnabled):
2148         * win/WebKit2.def:
2149
2150 2012-05-28  No'am Rosenthal  <noam.rosenthal@nokia.com>
2151
2152         Remove unused argument coders for animation
2153         https://bugs.webkit.org/show_bug.cgi?id=87435
2154
2155         Reviewed by Sam Weinig.
2156
2157         Left the used argument coders only, behind a proper USE(UI_SIDE_COMPOSITING) flag.
2158
2159         * Shared/WebCoreArgumentCoders.cpp:
2160         (CoreIPC):
2161         * Shared/WebCoreArgumentCoders.h:
2162
2163 2012-05-28  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
2164
2165         Move allowRoundingHacks to Internals interface
2166         https://bugs.webkit.org/show_bug.cgi?id=87328
2167
2168         Reviewed by Hajime Morita.
2169
2170         * win/WebKit2.def: Add setAllowsRoundingHacks() to symbol filter.
2171
2172 2012-05-26  Geoffrey Garen  <ggaren@apple.com>
2173
2174         WebKit should be lazy-finalization-safe (esp. the DOM) v2
2175         https://bugs.webkit.org/show_bug.cgi?id=87581
2176
2177         Reviewed by Oliver Hunt.
2178
2179         * WebProcess/Plugins/Netscape/JSNPObject.cpp:
2180         (WebKit::JSNPObject::destroy):
2181         (WebKit::JSNPObject::leakNPObject):
2182         * WebProcess/Plugins/Netscape/NPRuntimeObjectMap.cpp:
2183         (WebKit::NPRuntimeObjectMap::finalize): Use static_cast instead of jsCast because
2184         jsCast does Structure-based validation, and our Structure is not guaranteed
2185         to be alive when we get finalized.
2186
2187 2012-05-25  Maciej Stachowiak  <mjs@apple.com>
2188
2189         REGRESSION (r116720): Subframe PDF scrolls extremely slowly
2190         https://bugs.webkit.org/show_bug.cgi?id=87557
2191         <rdar://problem/11499408>
2192
2193         Reviewed by Anders Carlsson.
2194         
2195         It's not possible to make an automated test for this.
2196
2197         * WebProcess/Plugins/PDF/BuiltInPDFView.mm:
2198         (WebKit::BuiltInPDFView::wantsWheelEvents): Return true instead of false and delete
2199         misleading comment. While the built-in PDF view would get added to the set of scrollable
2200         areas anyway, there are some code paths that check wantsWheelEvents explicitly, so it seems
2201         necessary to reutrn true.
2202
2203 2012-05-25  Brady Eidson  <beidson@apple.com>
2204
2205         https://bugs.webkit.org/show_bug.cgi?id=87418
2206         WebBackForwardList should separate "has no current index" from the integer value of the current index
2207
2208         This patch also renames "m_current" to "m_currentIndex" for clarity and symmetry with
2209         other variable names that reference "index",
2210
2211         It also removes the m_closed and m_enabled flags which were never actually used.
2212
2213         Reviewed by Darin Adler.
2214
2215         * UIProcess/WebBackForwardList.cpp:
2216         (WebKit::WebBackForwardList::WebBackForwardList):
2217         (WebKit::WebBackForwardList::addItem):
2218         (WebKit::WebBackForwardList::goToItem):
2219         (WebKit::WebBackForwardList::currentItem):
2220         (WebKit::WebBackForwardList::backItem):
2221         (WebKit::WebBackForwardList::forwardItem):
2222         (WebKit::WebBackForwardList::itemAtIndex):
2223         (WebKit::WebBackForwardList::backListCount):
2224         (WebKit::WebBackForwardList::forwardListCount):
2225         (WebKit::WebBackForwardList::backListAsImmutableArrayWithLimit):
2226         (WebKit::WebBackForwardList::forwardListAsImmutableArrayWithLimit):
2227         (WebKit::WebBackForwardList::clear):
2228
2229         * UIProcess/WebBackForwardList.h:
2230         (WebKit::WebBackForwardList::currentIndex):
2231         (WebBackForwardList):
2232
2233         * UIProcess/cf/WebBackForwardListCF.cpp:
2234         (WebKit::WebBackForwardList::createCFDictionaryRepresentation):
2235         (WebKit::WebBackForwardList::restoreFromCFDictionaryRepresentation):
2236
2237 2012-05-25  Beth Dakin  <bdakin@apple.com>
2238
2239         https://bugs.webkit.org/show_bug.cgi?id=87529
2240         Background tabs hosted in window server flash before painting 
2241         when they first become active
2242
2243         Reviewed by Anders Carlsson.
2244
2245         Initialize to LayerHostingModeInWindowServer if that is 
2246         available to avoid having to re-make the context and re-set 
2247         everything later on.
2248         * UIProcess/WebPageProxy.cpp:
2249         (WebKit::WebPageProxy::WebPageProxy):
2250
2251 2012-05-25  Mario Sanchez Prada  <msanchez@igalia.com>
2252
2253         [GTK][WK2] Implement API for generic permission requests
2254         https://bugs.webkit.org/show_bug.cgi?id=84018
2255
2256         Reviewed by Martin Robinson.
2257
2258         Added new 'permission-request' signal to WebKitWebView, to be
2259         fired when WebKit needs confirmation from the user on whether to
2260         allow or deny certain operations, such as sharing the user's
2261         location with web site through the Geolocation API.
2262
2263         New WebKitPermissionRequest interface, providing allow() and
2264         deny() operations, to be called over the objects implementing it
2265         when emitted along with the new 'permission-request' signal.
2266
2267         * UIProcess/API/gtk/WebKitPermissionRequest.cpp: Added.
2268         (webkit_permission_request_default_init):
2269         (webkit_permission_request_allow):
2270         (webkit_permission_request_deny):
2271         * UIProcess/API/gtk/WebKitPermissionRequest.h: Added.
2272         (_WebKitPermissionRequestIface):
2273         * GNUmakefile.am: Added new files.
2274
2275         Added the new signal to WebKitWebView, providing a default handler
2276         that will just deny the request when the signal is not handled.
2277
2278         * UIProcess/API/gtk/WebKitWebView.cpp:
2279         (webkitWebViewDecidePermissionRequest): Default handler.
2280         (webkit_web_view_class_init): Declare the new signal and connect
2281         to the default handler.
2282         (webkitWebViewMakePermissionRequest): Helper function to create a
2283         make a new permission request and emit the new signal signal.
2284         * UIProcess/API/gtk/WebKitWebView.h:
2285         (_WebKitWebViewClass):
2286         * UIProcess/API/gtk/WebKitWebViewPrivate.h: Declare the creational
2287         function webkitWebViewMakePermissionRequest for internal use only.
2288
2289         Updated documentation files.
2290
2291         * UIProcess/API/gtk/docs/webkit2gtk-docs.sgml:
2292         * UIProcess/API/gtk/docs/webkit2gtk-sections.txt:
2293
2294 2012-05-25  Grzegorz Czajkowski  <g.czajkowski@samsung.com>
2295
2296         [WK2] Fix client interface size for WKPageContextMenuClient.
2297         https://bugs.webkit.org/show_bug.cgi?id=87472
2298
2299         Reviewed by Carlos Garcia Campos.
2300
2301         Add correct offset for version 1 and 2 of WKPageContextMenuClient.
2302         Revision 109750 introduces a new API and increases size of interfaceSizesByVersion
2303         but the table is not properly initialized for newly introduced version 2.
2304
2305         * Shared/APIClientTraits.cpp:
2306         (WebKit):
2307
2308 2012-05-24  Andreas Kling  <kling@webkit.org>
2309
2310         Mac bots crashing under PluginInfo destructor.
2311         <http://webkit.org/b/87414>
2312         <rdar://problem/11527172>
2313
2314         Reviewed by Darin Adler.
2315
2316         We can't safely pass WTF::String to another thread without a deref() race,
2317         so pass the PluginInfo vector by pointer instead of by value.
2318
2319         * UIProcess/WebContext.cpp:
2320         (WebKit::WebContext::sendDidGetPlugins):
2321         (WebKit::WebContext::handleGetPlugins):
2322         * UIProcess/WebContext.h:
2323
2324 2012-05-25  Zalan Bujtas  <zbujtas@gmail.com>
2325
2326         [Qt][WK2] Fix failing qmltests::FitToView::test_basic()
2327         https://bugs.webkit.org/show_bug.cgi?id=87236
2328
2329         Reviewed by Kenneth Rohde Christiansen.
2330
2331         Rename contentViewportChanged to informVisibleContentChange() to
2332         reflect its functionality better. Centralize m_hadUserInteraction flag
2333         setting and add assertions on it to ensure that designated
2334         functions are called only on user interaction.
2335
2336         * UIProcess/API/qt/qquickwebview.cpp:
2337         (QQuickWebViewFlickablePrivate::onComponentComplete):
2338         (QQuickWebViewFlickablePrivate::updateViewportSize):
2339         (QQuickWebViewFlickablePrivate::_q_onInformVisibleContentChange):
2340         (QQuickWebViewFlickablePrivate::_q_resume):
2341         * UIProcess/API/qt/qquickwebview_p.h:
2342         * UIProcess/API/qt/qquickwebview_p_p.h:
2343         (QQuickWebViewPrivate::_q_onInformVisibleContentChange):
2344         (QQuickWebViewFlickablePrivate):
2345         * UIProcess/qt/QtViewportInteractionEngine.cpp:
2346         (WebKit::ViewportUpdateDeferrer::~ViewportUpdateDeferrer):
2347         (WebKit::QtViewportInteractionEngine::flickableMovingPositionUpdate):
2348         (WebKit::QtViewportInteractionEngine::pagePositionRequest):
2349         (WebKit::QtViewportInteractionEngine::touchBegin):
2350         (WebKit::QtViewportInteractionEngine::focusEditableArea):
2351         (WebKit::QtViewportInteractionEngine::zoomToAreaGestureEnded):
2352         (WebKit::QtViewportInteractionEngine::panGestureStarted):
2353         (WebKit::QtViewportInteractionEngine::pinchGestureStarted):
2354         * UIProcess/qt/QtViewportInteractionEngine.h:
2355         (QtViewportInteractionEngine):
2356
2357 2012-05-24  Tim Horton  <timothy_horton@apple.com>
2358
2359         Add feature defines for web-facing parts of CSS Regions and Exclusions
2360         https://bugs.webkit.org/show_bug.cgi?id=87442
2361         <rdar://problem/10887709>
2362
2363         Reviewed by Dan Bernstein.
2364
2365         * Configurations/FeatureDefines.xcconfig:
2366
2367 2012-05-24  Geoffrey Garen  <ggaren@apple.com>
2368
2369         WebKit should be lazy-finalization-safe (esp. the DOM)
2370         https://bugs.webkit.org/show_bug.cgi?id=87456
2371
2372         Reviewed by Filip Pizlo.
2373
2374         * WebProcess/Plugins/Netscape/NPRuntimeObjectMap.cpp:
2375         (WebKit::NPRuntimeObjectMap::getOrCreateJSObject): Use the new idioms.
2376
2377         (WebKit::NPRuntimeObjectMap::invalidate): Check for null while iterating,
2378         since that's possible now.
2379
2380         (WebKit::NPRuntimeObjectMap::finalize): Use the new idioms.
2381
2382 2012-05-24  Brady Eidson  <beidson@apple.com>
2383
2384         Fix the build after http://trac.webkit.org/changeset/118441
2385         Also fix a glaring bug with the new code, will run it by original reviewer retroactively.
2386
2387         * UIProcess/cf/WebBackForwardListCF.cpp:
2388         (WebKit::WebBackForwardList::restoreFromCFDictionaryRepresentation): Fix up the types of the ? operands
2389           to appease super-strict compilers. Don't allow negative indexes (besides the -1 "No index" index).
2390
2391 2012-05-24  Brady Eidson  <beidson@apple.com>
2392
2393         <rdar://problem/10090764> and https://bugs.webkit.org/show_bug.cgi?id=87417
2394         (Unrepro) Crashes saving session state in WebBackForwardList
2395
2396         Reviewed by Darin Adler.
2397
2398         * UIProcess/WebBackForwardList.cpp:
2399         (WebKit::WebBackForwardList::addItem): Null check the proposed item and also m_page, to make
2400           sure the page hasn't been closed making this list inactive. Be more aggressive about
2401           clearing the current entries out if there is no current item index.
2402         (WebKit::WebBackForwardList::itemAtIndex): Early null return if there is no current index.
2403         (WebKit::WebBackForwardList::clear): Don't put the current item back in the array if there was
2404           no current item.
2405
2406         * UIProcess/cf/WebBackForwardListCF.cpp:
2407         (WebKit::WebBackForwardList::createCFDictionaryRepresentation): Don't create a meaningless WebURL.
2408           Don't successfully return a dictionary if any of the entries were null. Be more aggressive about
2409           validating the current index we plan to return in the dictionary.
2410         (WebKit::WebBackForwardList::restoreFromCFDictionaryRepresentation): More aggressively validate the
2411           current index read from disk. Replace a meaningless sanity check with our typical ASSERT.
2412
2413 2012-05-24  Anders Carlsson  <andersca@apple.com>
2414
2415         Make sure that the layer hosting mode is up-to-date when reconnecting to a new web process
2416         https://bugs.webkit.org/show_bug.cgi?id=87421
2417         <rdar://problem/11510337>
2418
2419         Reviewed by Beth Dakin.
2420
2421         Send over the layer hosting mode as part of the web page creation parameters and create the right
2422         layer hosting context based on the mode.
2423
2424         * Shared/WebPageCreationParameters.cpp:
2425         (WebKit::WebPageCreationParameters::encode):
2426         (WebKit::WebPageCreationParameters::decode):
2427         * Shared/WebPageCreationParameters.h:
2428         (WebPageCreationParameters):
2429         * UIProcess/WebPageProxy.cpp:
2430         (WebKit::WebPageProxy::creationParameters):
2431         * WebProcess/WebPage/WebPage.cpp:
2432         (WebKit::WebPage::WebPage):
2433         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.h:
2434         (TiledCoreAnimationDrawingArea):
2435         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
2436         (WebKit::TiledCoreAnimationDrawingArea::TiledCoreAnimationDrawingArea):
2437         (WebKit::TiledCoreAnimationDrawingArea::setLayerHostingMode):
2438         (WebKit):
2439         (WebKit::TiledCoreAnimationDrawingArea::updateLayerHostingContext):
2440
2441 2012-05-24  John Mellor  <johnme@chromium.org>
2442
2443         Font Boosting: Add compile flag and runtime setting
2444         https://bugs.webkit.org/show_bug.cgi?id=87394
2445
2446         Reviewed by Adam Barth.
2447
2448         Add ENABLE_FONT_BOOSTING.
2449
2450         * Configurations/FeatureDefines.xcconfig:
2451
2452 2012-05-24  Yael Aharon  <yael.aharon@nokia.com>
2453
2454         [Qt] Stop using the flag FIXED_POSITION_CREATES_STACKING_CONTEXT
2455         https://bugs.webkit.org/show_bug.cgi?id=87392
2456
2457         Reviewed by Antonio Gomes.
2458
2459         Turn on the setting setFixedPositionCreatesStackingContext.
2460
2461         * WebProcess/WebPage/WebPage.cpp:
2462         (WebKit::WebPage::setResizesToContentsUsingLayoutSize):
2463
2464 2012-05-24  Alexey Proskuryakov  <ap@apple.com>
2465
2466         [WK2] Let the client give local files universal access on a case by case basis
2467         https://bugs.webkit.org/show_bug.cgi?id=87174
2468         <rdar://problem/11024330>
2469
2470         Reviewed by Maciej Stachowiak.
2471
2472         * WebProcess/InjectedBundle/API/c/WKBundlePage.h:
2473         * WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.cpp:
2474         (WebKit::InjectedBundlePageLoaderClient::shouldForceUniversalAccessFromLocalURL):
2475         * WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.h:
2476         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
2477         (WebKit::WebFrameLoaderClient::shouldForceUniversalAccessFromLocalURL):
2478         * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
2479         * WebProcess/qt/QtBuiltinBundlePage.cpp:
2480         (WebKit::QtBuiltinBundlePage::QtBuiltinBundlePage):
2481         Added glue code to call bundle client.
2482
2483 2012-05-24  Alexander Færøy  <alexander.faeroy@nokia.com>
2484
2485         Reorder arguments to compare() in the QML WebView tests
2486         https://bugs.webkit.org/show_bug.cgi?id=87374
2487
2488         Reviewed by Simon Hausmann.
2489
2490         Based on patch by Kenneth Rohde Christiansen.
2491
2492         The reordering is necessary to get correct information printed when
2493         the tests fails. Without this, the test suite will display the bogus
2494         value and not the expected value.
2495
2496         This patch also removes the delayed windowShown since this is not
2497         needed anymore, due to us using the touch events instead of mouse
2498         events.
2499
2500         * UIProcess/API/qt/tests/qmltests/WebView/tst_doubleTapToZoom.qml:
2501
2502 2012-05-24  Allan Sandfeld Jensen  <allan.jensen@nokia.com>
2503
2504         [Qt] Tiles not painted after wheel or keyboard scroll.
2505         https://bugs.webkit.org/show_bug.cgi?id=87358
2506
2507         Reviewed by Kenneth Rohde Christiansen.
2508
2509         After performing a scroll requested from the WebProcess we also need
2510         to inform the painting layer of the viewport change.
2511
2512         * UIProcess/qt/QtViewportInteractionEngine.cpp:
2513         (WebKit::QtViewportInteractionEngine::pagePositionRequest):
2514
2515 2012-05-24  Andras Becsi  <andras.becsi@nokia.com>
2516
2517         [Qt][WK2] Fix bounce-back animation on pinch->pan
2518         https://bugs.webkit.org/show_bug.cgi?id=87266
2519
2520         Reviewed by Kenneth Rohde Christiansen.
2521
2522         If ending an out-of-bounds pinch gesture with releasing one finger
2523         (transition to a pan gesture) the bounce back animation blinks in
2524         the end position immediately first, then animates the content back
2525         into bounds.
2526
2527         QtViewportInteractionEngine::cancelScrollAnimation should return
2528         early if there is no active kinetic animation.
2529
2530         * UIProcess/qt/QtViewportInteractionEngine.cpp:
2531         (WebKit::QtViewportInteractionEngine::cancelScrollAnimation):
2532
2533 2012-05-23  Ojan Vafai  <ojan@chromium.org>
2534
2535         add back the ability to disable flexbox
2536         https://bugs.webkit.org/show_bug.cgi?id=87147
2537
2538         Reviewed by Tony Chang.
2539
2540         * Configurations/FeatureDefines.xcconfig:
2541
2542 2012-05-23  Jer Noble  <jer.noble@apple.com>
2543
2544         REGRESSION (117623) - Entering/exiting fullscreen HTML5 videos, there is a quick animated fade
2545         https://bugs.webkit.org/show_bug.cgi?id=87294
2546
2547         Reviewed by Darin Adler.
2548
2549         When setting the sublayers array on the layer hosting view, wrap the call in a CATransaction which disables
2550         animations.
2551
2552         * UIProcess/API/mac/WKView.mm:
2553         (-[WKView _updateAcceleratedCompositingMode:WebKit::]):
2554
2555 2012-05-23  Dinu Jacob  <dinu.jacob@nokia.com>
2556
2557         [Qt][Wk2] Assertion failure when selecting an option in select list with size attribute greater than one
2558         https://bugs.webkit.org/show_bug.cgi?id=86974
2559
2560         Reviewed by Simon Hausmann.
2561
2562         Select list with size attribute greater than one will not initially have any
2563         item in selected state (if no option has 'selected' tag), resulting in
2564         m_selectedModelIndex in WebPopupMenuProxyQt to be invalid. Hence, need to check
2565         whether the old index is invalid before accessing the item at that index.
2566
2567         * UIProcess/API/qt/tests/qmltests/DesktopBehavior/tst_itemSelector.qml: Added new test that
2568           tests selection in a select list with size attribute value of 2.
2569         * UIProcess/API/qt/tests/qmltests/common/selectwithsize.html: Added.
2570         * UIProcess/qt/WebPopupMenuProxyQt.cpp:
2571         (WebKit::PopupMenuItemModel::select): Check whether old index is valid before accessing
2572           the item at that index.
2573
2574 2012-05-23  Jer Noble  <jer.noble@apple.com>
2575
2576         REGRESSION (r116188): After exiting full screen, Safari window is frozen, then inline video speeds through frames as it catches up with audio
2577         https://bugs.webkit.org/show_bug.cgi?id=87206
2578
2579         Reviewed by Darin Adler.
2580
2581         When re-enabling the Safari window's autodisplay flag, also force the window to re-display.
2582         Otherwise, the window will not repaint itself until it is forced to by user interaction.
2583
2584         * UIProcess/mac/WKFullScreenWindowController.mm:
2585         (-[WKFullScreenWindowController completeFinishExitFullScreenAnimationAfterRepaint]):
2586
2587 2012-05-23  Martin Robinson  <mrobinson@igalia.com>
2588
2589         [GTK] [WebKit2] Add an API to enable and disable composited layer indicators
2590         https://bugs.webkit.org/show_bug.cgi?id=87053
2591
2592         Reviewed by Carlos Garcia Campos.
2593
2594         Add a WebKitSetting that allows the client to enable and disable debug
2595         borders and repaint counters for accelerated content.
2596
2597         * UIProcess/API/gtk/WebKitSettings.cpp:
2598         (webKitSettingsSetProperty): Added.
2599         (webKitSettingsGetProperty): Added.
2600         (webkit_settings_class_init): Add the new property.
2601         (webkit_settings_set_draw_compositing_indicators): Added.
2602         (webkit_settings_get_draw_compositing_indicators): Added.
2603         * UIProcess/API/gtk/WebKitSettings.h:
2604         * UIProcess/API/gtk/docs/webkit2gtk-sections.txt: Add the new API points to the
2605         documentation.
2606         * UIProcess/API/gtk/test/TestWebKitSettings.h: Add a new unit test.
2607
2608 2012-05-23  Michael Brüning  <michael.bruning@nokia.com>
2609
2610         [Qt][WK2] Small refactoring WebPage::confirmComposition.
2611         https://bugs.webkit.org/show_bug.cgi?id=87243
2612
2613         Reviewed by Kenneth Rohde Christiansen.
2614
2615         Change nested if into an early return to reduce complexity.
2616
2617         * WebProcess/WebPage/qt/WebPageQt.cpp:
2618         (WebKit::WebPage::confirmComposition):
2619
2620 2012-05-22  Alexander Færøy  <alexander.faeroy@nokia.com>
2621
2622         [Qt] Missing tests for the evaluateJavaScript API
2623         https://bugs.webkit.org/show_bug.cgi?id=86351
2624
2625         Reviewed by Kenneth Rohde Christiansen.
2626
2627         * UIProcess/API/qt/tests/qmltests/WebView/tst_evaluateJavaScript.qml:
2628         * UIProcess/API/qt/tests/qmltests/common/evaluatejavascript.html: Added.
2629
2630 2012-05-23  Allan Sandfeld Jensen  <allan.jensen@nokia.com>
2631
2632         [Qt] FloatSize Qt Support
2633         https://bugs.webkit.org/show_bug.cgi?id=87237
2634
2635         Reviewed by Andreas Kling.
2636
2637         Basic cleanup possible to new Qt support in FloatSize.
2638
2639         * UIProcess/API/qt/qquickwebpage.cpp:
2640         (QQuickWebPagePrivate::updateSize):
2641         * UIProcess/API/qt/qwebkittest.cpp:
2642         (QWebKitTest::layoutSize):
2643
2644 2012-04-18  Tor Arne Vestbø  <tor.arne.vestbo@nokia.com>
2645
2646         [Qt] Make the web view's url property follow the active url
2647
2648         https://bugs.webkit.org/show_bug.cgi?id=77554
2649
2650         The url property of the webview now reflects the 'active' url of the
2651         page, which maps to either the currently loading url, in the case of
2652         an ongoing load, or the result of a load, even when the load failed.
2653
2654         In practice this means that setting the url though QML, or navigating
2655         to a new url in the page by e.g clicking, will both instantly change
2656         the url-property of the webview to the target url. This differs from
2657         earlier behavior, where we would update the url when the load
2658         committed.
2659
2660         An optional argument is added to loadHtml(), to allow setting
2661         the unreachable url when providing replacement content for failed
2662         loads.
2663
2664         Finally, the location bar in the minibrowser is updated to behave
2665         a bit more like normal browsers in terms of when the url will change
2666         and how active focus is handled.
2667
2668         Reviewed by Simon Hausmann.
2669
2670         * UIProcess/API/qt/qquickwebview.cpp:
2671         (QQuickWebViewPrivate::onComponentComplete):
2672         (QQuickWebView::reload):
2673         (QQuickWebView::url):
2674         (QQuickWebView::setUrl):
2675         (QQuickWebView::loadHtml):
2676         * UIProcess/API/qt/qquickwebview_p.h:
2677         * UIProcess/API/qt/tests/qmltests/DesktopBehavior.pro:
2678         * UIProcess/API/qt/tests/qmltests/WebView.pro:
2679         * UIProcess/API/qt/tests/qmltests/WebView/tst_loadUrl.qml:
2680         * UIProcess/API/qt/tests/qmltests/common/link.html: Added.
2681         * UIProcess/API/qt/tests/qmltests/common/redirect.html: Added.
2682         * UIProcess/qt/QtWebPageLoadClient.cpp:
2683         (QtWebPageLoadClient::QtWebPageLoadClient):
2684         (QtWebPageLoadClient::didStartProvisionalLoadForFrame):
2685         (QtWebPageLoadClient::didReceiveServerRedirectForProvisionalLoadForFrame):
2686         (QtWebPageLoadClient::didCommitLoadForFrame):
2687         (QtWebPageLoadClient::dispatchLoadFailed):
2688         (QtWebPageLoadClient::didFailProvisionalLoadWithErrorForFrame):
2689         (QtWebPageLoadClient::didFailLoadWithErrorForFrame):
2690         * UIProcess/qt/QtWebPageLoadClient.h:
2691         (QtWebPageLoadClient):
2692
2693 2012-05-23  Simon Hausmann  <simon.hausmann@nokia.com>
2694
2695         [Qt] Race condition in LayerTreeHost/Proxy can cause blank rendering
2696         https://bugs.webkit.org/show_bug.cgi?id=87239
2697
2698         Reviewed by Kenneth Rohde Christiansen.
2699
2700         On the UI process side the WebLayerTreeRenderer/LayerTreeHostProxy pair is
2701         created with m_active = false, which makes it ignore any incoming layer updates.
2702         It remains inactive until the ContentsSGNode is created and setActive(true) is called.
2703
2704         On the web process side the LayerTreeHost is created with m_waitingForUIProcess = false.
2705
2706         Those two variables must be in sync, otherwise a race condition can
2707         happen: The web process sends updates to the ui process before the
2708         ContentsSGNode is created. This can happen for example when re-using an
2709         existing WebProcess to create a QQuickWebView and load a page very fast
2710         from the disk cache. The update arrives on the ui process side, but it
2711         is discarded because setActive(true) hasn't been called yet. As a
2712         result any updates that would for example create and populate the tiles
2713         required for rendering are ignored.
2714
2715         This patch ensures that the variables are initialized with the same values and that calling
2716         setActive(true) will trigger the rendering of the next frame.
2717
2718         * UIProcess/WebLayerTreeRenderer.cpp:
2719         (WebKit::WebLayerTreeRenderer::setActive):
2720         * WebProcess/WebPage/qt/LayerTreeHostQt.cpp:
2721         (WebKit::LayerTreeHostQt::LayerTreeHostQt):
2722
2723 2012-05-23  Tor Arne Vestbø  <tor.arne.vestbo@nokia.com>
2724
2725         [Qt] Make QtWebError return the failing URL as a QString instead of QUrl
2726
2727         We don't want to use QUrl inside QtWebKit (only in the API layer), due
2728         to how QUrl normalizes the url.
2729
2730         Reviewed by Simon Hausmann.
2731
2732         * UIProcess/qt/QtWebError.cpp:
2733         (WebKit::QtWebError::url):
2734         * UIProcess/qt/QtWebError.h:
2735
2736 2012-05-22  Carlos Garcia Campos  <cgarcia@igalia.com>
2737
2738         [GTK] Add inspector API to WebKit2 GTK+
2739         https://bugs.webkit.org/show_bug.cgi?id=87113
2740
2741         Reviewed by Martin Robinson.
2742
2743         * GNUmakefile.list.am: Add new files to compilation.
2744         * UIProcess/API/C/gtk/WKInspectorClientGtk.cpp: Added.
2745         (WKInspectorSetInspectorClientGtk):
2746         * UIProcess/API/C/gtk/WKInspectorClientGtk.h: Added.
2747         * UIProcess/API/gtk/WebKitPrivate.h:
2748         * UIProcess/API/gtk/WebKitWebInspector.cpp: Added.
2749         (webkitWebInspectorFinalize):
2750         (webkit_web_inspector_init):
2751         (webkit_web_inspector_class_init):
2752         (openWindow): Emit WebKitWebInspector::open-window singal.
2753         (didClose): Emit WebKitWebInspector::closed signal.
2754         (bringToFront): Emit WebKitWebInspector::bring-to-front singal.
2755         (inspectedURLChanged): Set the inspected URI and emit
2756         GObject::notify signal if it changed.
2757         (attach): Emit WebKitWebInspector::attach signal.
2758         (detach): Emit WebKitWebInspector::detach signal.
2759         (didChangeAttachedHeight): Set the attached height and emit
2760         GObject::notify signal if it changed.
2761         (webkitWebInspectorCreate): Ceate a new WebKitWebInspector object
2762         for the given WKInspector. Also initialize and set the inspector
2763         client.
2764         (webkit_web_inspector_get_web_view): Return the web view used to
2765         render the inspector.
2766         (webkit_web_inspector_get_inspected_uri): Return the URI that is
2767         being inspected.
2768         (webkit_web_inspector_is_attached): Whether the inspector view is
2769         currently attached.
2770         (webkit_web_inspector_attach): Request to attach the inspector.
2771         (webkit_web_inspector_detach): Request to detach the inspector.
2772         (webkit_web_inspector_show): Request to show the inspector.
2773         (webkit_web_inspector_close): Request to close the inspector.
2774         (webkit_web_inspector_get_attached_height): Return the height that
2775         the inspector view should have when attached.
2776         * UIProcess/API/gtk/WebKitWebInspector.h: Added.
2777         * UIProcess/API/gtk/WebKitWebInspectorPrivate.h: Added.
2778         * UIProcess/API/gtk/WebKitWebView.cpp:
2779         (webkit_web_view_get_inspector): Return the WebKitWebInspector
2780         associated to the web view.
2781         * UIProcess/API/gtk/WebKitWebView.h:
2782         * UIProcess/API/gtk/docs/webkit2gtk-docs.sgml: Add new section for
2783         WebKitWebInspector.
2784         * UIProcess/API/gtk/docs/webkit2gtk-sections.txt: Ad new symbols.
2785         * UIProcess/API/gtk/docs/webkit2gtk.types: Add
2786         webkit_web_inspector_get_type.
2787         * UIProcess/API/gtk/tests/GNUmakefile.am: Add new test for the
2788         inspector API.
2789         * UIProcess/API/gtk/tests/TestInspector.cpp: Added.
2790         (testInspectorDefault):
2791         (testInspectorCustom):
2792         (testInspectorWindowDestroyed):
2793         (beforeAll):
2794         (afterAll):
2795         * UIProcess/API/gtk/tests/WebViewTest.cpp:
2796         (WebViewTest::showInWindowAndWaitUntilMapped): Add optional
2797         parameter to create a toplevel or popup window.
2798         (WebViewTest::resizeView): Helper function to set the widget
2799         allocation to a given size.
2800         * UIProcess/API/gtk/tests/WebViewTest.h:
2801         * UIProcess/API/gtk/webkit2.h: Include WebKitWebInspector.h
2802         * UIProcess/WebInspectorProxy.h:
2803         (WebKit::WebInspectorProxy::inspectorView): Return the view used
2804         to render the inspector.
2805         * UIProcess/gtk/WebInspectorClientGtk.cpp: Added.
2806         (WebKit::WebInspectorClientGtk::openWindow):
2807         (WebKit::WebInspectorClientGtk::didClose):
2808         (WebKit::WebInspectorClientGtk::bringToFront):
2809         (WebKit::WebInspectorClientGtk::inspectedURLChanged):
2810         (WebKit::WebInspectorClientGtk::attach):
2811         (WebKit::WebInspectorClientGtk::detach):
2812         (WebKit::WebInspectorClientGtk::didChangeAttachedHeight):
2813         * UIProcess/gtk/WebInspectorClientGtk.h: Added.
2814         * UIProcess/gtk/WebInspectorProxyGtk.cpp:
2815         (WebKit::inspectorViewDestroyed): Close the inspector page when
2816         the inspector view is destroyed, instead of when the inspector
2817         window is deleted, because the inspector view can now be inside a
2818         window created by the user.
2819         (WebKit::WebInspectorProxy::initializeInspectorClientGtk):
2820         Initialze the inspector client.
2821         (WebKit::WebInspectorProxy::platformCreateInspectorPage): Add a
2822         weak pointer to the inspector view to make sure it's NULL when
2823         destroyed.
2824         (WebKit::WebInspectorProxy::createInspectorWindow): Call
2825         openWindow on the inspector client, and return early if the
2826         callback was handled.
2827         (WebKit::WebInspectorProxy::platformOpen): Connect to destroy
2828         signal of the inspector view to close the page when the view is
2829         destroyed.
2830         (WebKit::WebInspectorProxy::platformDidClose): Call didClose on
2831         the inspector client.
2832         (WebKit::WebInspectorProxy::platformBringToFront): Call
2833         bringToFront on the inspector client, and return early if the
2834         callback was handled.
2835         (WebKit::WebInspectorProxy::platformInspectedURLChanged): Call
2836         inspectedURLChanged on the inspector client.
2837         (WebKit::WebInspectorProxy::platformAttach): Call attach on the
2838         inspector client and return if the callback was handled.
2839         (WebKit::WebInspectorProxy::platformDetach): Call detach on the
2840         inspector client and return if the callback was handled.
2841         (WebKit::WebInspectorProxy::platformSetAttachedWindowHeight): Call
2842         didChangeAttachedHeight on the inspector client.
2843
2844 2012-05-22  Anders Carlsson  <andersca@apple.com>
2845
2846         Functions dispatched by dispatchAfterEnsuringUpdatedScrollPosition can be called after drawing area has been destroyed
2847         https://bugs.webkit.org/show_bug.cgi?id=87173
2848         <rdar://problem/11474087>
2849
2850         Reviewed by Beth Dakin.
2851
2852         Don't try to call forceRepaint if the drawing area has already been destroyed.
2853
2854         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
2855         (WebKit::TiledCoreAnimationDrawingArea::forceRepaintAsync):
2856
2857 2012-05-22  Anders Carlsson  <andersca@apple.com>
2858
2859         Crash when a plug-in view outlives its containing WebPage
2860         https://bugs.webkit.org/show_bug.cgi?id=87163
2861         <rdar://problem/10849258>
2862
2863         Reviewed by Dan Bernstein.
2864
2865         In rare cases, when a plug-in is kept alive for some reason it can outlive its WebPage. When that happens,
2866         the PluginView destructor will try to access the (deleted) web page and we'll crash.
2867
2868         Fix this by making the WebPage destructor iterate over all the registered plug-ins and null out the m_webPage pointer.
2869         Don't try to access the WebPage object if it's null.
2870
2871         Also, remove PLATFORM(MAC) ifdefs around the HashSet of known plug-in views as well as the member functions that access the set;
2872         we want this to be cross platform now.
2873
2874         * WebProcess/Plugins/PluginView.cpp:
2875         (WebKit::PluginView::PluginView):
2876         (WebKit::PluginView::~PluginView):
2877         (WebKit::PluginView::webPageDestroyed):
2878         (WebKit):
2879         * WebProcess/Plugins/PluginView.h:
2880         (PluginView):
2881         * WebProcess/WebPage/WebPage.cpp:
2882         (WebKit::WebPage::~WebPage):
2883         (WebKit::WebPage::scalePage):
2884         (WebKit):
2885         * WebProcess/WebPage/WebPage.h:
2886         (WebPage):
2887
2888 == Rolled over to ChangeLog-2012-05-22 ==