[Qt][WK2] Fix zero sized views in all QML tests
[WebKit.git] / Source / WebKit2 / ChangeLog
1 2011-11-17  Jesus Sanchez-Palencia  <jesus.palencia@openbossa.org>
2
3         [Qt][WK2] Fix zero sized views in all QML tests
4         https://bugs.webkit.org/show_bug.cgi?id=72633
5
6         Reviewed by Noam Rosenthal.
7
8         After r100590, zero sized WebViews are no longer supported and,
9         therefore, the QML API tests need to be fixed.
10
11         * UIProcess/API/qt/tests/qmltests/WebView/tst_loadFail.qml:
12         * UIProcess/API/qt/tests/qmltests/WebView/tst_loadProgress.qml:
13         * UIProcess/API/qt/tests/qmltests/WebView/tst_loadProgressSignal.qml:
14         * UIProcess/API/qt/tests/qmltests/WebView/tst_loadZeroSizeView.qml: Removed.
15         * UIProcess/API/qt/tests/qmltests/WebView/tst_preferences.qml:
16         * UIProcess/API/qt/tests/qmltests/WebView/tst_properties.qml:
17         * UIProcess/API/qt/tests/qmltests/qmltests.pro:
18
19 2011-11-17  Alexis Menard  <alexis.menard@openbossa.org>
20
21         [Qt][WK2] Don't export the private QQuickView.
22
23         Reviewed by Kenneth Rohde Christiansen.
24
25         We don't need to export that class anymore as the experimental QML plugin
26         does not expose this object anymore.
27
28         * UIProcess/API/qt/qquickwebview_p_p.h:
29
30 2011-11-17  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>
31
32         [Qt] Expose setUseTraditionalDesktopBehaviour() in QML experimental API
33         https://bugs.webkit.org/show_bug.cgi?id=72610
34
35         Reviewed by Kenneth Rohde Christiansen.
36
37         * UIProcess/API/qt/qquickwebview_p.h:
38
39 2011-11-17  Kenneth Rohde Christiansen  <kenneth@webkit.org>
40
41         Print warning for the Qt port when a process crashes and is relaunched
42         https://bugs.webkit.org/show_bug.cgi?id=72607
43
44         Reviewed by Antonio Gomes.
45
46         Make the QtViewInterface::processDidCrash take a URL string argument,
47         for being able to say which url was the origin of the crash.
48
49         We now additionally store the load state and url at process exit. This
50         is needed for printing the warning and for further crash handling.
51
52         * UIProcess/PageClient.h:
53         * UIProcess/WebPageProxy.cpp:
54         (WebKit::WebPageProxy::processDidCrash):
55         * UIProcess/qt/QtViewInterface.cpp:
56         (WebKit::QtViewInterface::processDidCrash):
57         (WebKit::QtViewInterface::didRelaunchProcess):
58         * UIProcess/qt/QtViewInterface.h:
59         * UIProcess/qt/QtWebPageProxy.cpp:
60         (QtWebPageProxy::processDidCrash):
61         * UIProcess/qt/QtWebPageProxy.h:
62
63 2011-11-17  Alexis Menard  <alexis.menard@openbossa.org>
64
65         [Qt][WK2] Cleanup dead code in QtWebPageProxy.
66         https://bugs.webkit.org/show_bug.cgi?id=72608
67
68         Reviewed by Simon Hausmann.
69
70         Remove some dead code after we merged our views.
71         QQuickWebView is now using AC which means that this
72         path is never called now.
73
74         * UIProcess/qt/QtWebPageProxy.cpp:
75         (QtWebPageProxy::didReceiveDownloadResponse):
76         * UIProcess/qt/QtWebPageProxy.h:
77
78 2011-11-17  Tor Arne Vestbø  <tor.arne.vestbo@nokia.com>
79
80         [Qt] Remove forwarding header for WebKit2 C API
81
82         The Qt port of WebKit does not provide a C-API for the View classes.
83
84         Reviewed by Simon Hausmann.
85
86         * UIProcess/API/C/WebKit2.h:
87         * UIProcess/API/qt/WKView.h: Removed.
88
89 2011-11-17  Tor Arne Vestbø  <tor.arne.vestbo@nokia.com>
90
91         [Qt] Resolve import and web-process paths automatically for QML tests
92
93         Reviewed by Kenneth Rohde Christiansen.
94
95         * UIProcess/API/qt/tests/qmltests/qmltests.pro:
96         * UIProcess/API/qt/tests/qmltests/tst_qmltests.cpp:
97         (main):
98
99 2011-11-17  Tor Arne Vestbø  <tor.arne.vestbo@nokia.com>
100
101         [Qt] Move WebKit2 C++ APIs to private API and build QML extension plugin on top of that
102
103         A new extension object has been added to QQuickWebView (the same approach should be used
104         for other API classes that need experimental APIs). The QML extension mechanism is then
105         built on top of the experimental object.
106
107         https://bugs.webkit.org/show_bug.cgi?id=72522
108
109         Reviewed by Simon Hausmann.
110
111         * Target.pri:
112         * UIProcess/API/qt/qquickwebpage.cpp:
113         * UIProcess/API/qt/qquickwebpage.h: Removed.
114         * UIProcess/API/qt/qquickwebpage_p.h:
115         * UIProcess/API/qt/qquickwebpage_p_p.h: Renamed from Source/WebKit2/UIProcess/API/qt/qquickwebviewprivateextension_p.h.
116         * UIProcess/API/qt/qquickwebview.cpp:
117         (QQuickWebViewExperimental::QQuickWebViewExperimental):
118         (QQuickWebViewExperimental::~QQuickWebViewExperimental):
119         (QQuickWebViewExperimental::setUseTraditionalDesktopBehaviour):
120         (QQuickWebView::QQuickWebView):
121         (QQuickWebView::experimental):
122         * UIProcess/API/qt/qquickwebview.h: Removed.
123         * UIProcess/API/qt/qquickwebview_p.h:
124         * UIProcess/API/qt/qquickwebview_p_p.h: Copied from Source/WebKit2/UIProcess/API/qt/qquickwebview_p.h.
125         * UIProcess/API/qt/qquickwebviewprivateextension.cpp: Removed.
126         * UIProcess/API/qt/qwebdownloaditem.cpp:
127         * UIProcess/API/qt/qwebdownloaditem.h: Removed.
128         * UIProcess/API/qt/qwebdownloaditem_p.h:
129         * UIProcess/API/qt/qwebdownloaditem_p_p.h: Copied from Source/WebKit2/UIProcess/API/qt/qwebdownloaditem_p.h.
130         (QWebDownloadItemPrivate::didReceiveResponse):
131         * UIProcess/API/qt/qwebpreferences.cpp:
132         * UIProcess/API/qt/qwebpreferences.h: Removed.
133         * UIProcess/API/qt/qwebpreferences_p.h:
134         * UIProcess/API/qt/tests/qmltests/qmltests.pro:
135         * UIProcess/API/qt/tests/qmltests/tst_qmltests.cpp:
136         (DesktopWebView::DesktopWebView):
137         * UIProcess/API/qt/tests/qquickwebview/qquickwebview.pro:
138         * UIProcess/API/qt/tests/qquickwebview/tst_qquickwebview.cpp:
139         * UIProcess/qt/QtDownloadManager.cpp:
140         * UIProcess/qt/QtViewInterface.cpp:
141         * UIProcess/qt/QtWebError.h:
142         * UIProcess/qt/QtWebPageProxy.cpp:
143
144 2011-11-17  Kenneth Rohde Christiansen  <kenneth@webkit.org>
145
146         Unreviewed build fix.
147
148         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
149         (WebKit::WebFrameLoaderClient::transitionToCommittedForNewPage):
150
151 2011-11-16  Kenneth Rohde Christiansen  <kenneth@webkit.org>
152
153         Make use-fixed-layout work reliable
154         https://bugs.webkit.org/show_bug.cgi?id=72511
155
156         Reviewed by Simon Hausmann.
157
158         The code handling use-fixed-layout wasn't 100% reliable. The code
159         was changed to make sure the value is always correct.
160
161         It also doesn't set the value by looking at the previous FrameView,
162         as that wouldn't work in cases, such as when the web process has
163         crashed.
164
165         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
166         (WebKit::WebFrameLoaderClient::transitionToCommittedForNewPage):
167         * WebProcess/WebPage/WebPage.cpp:
168         (WebKit::WebPage::WebPage):
169         (WebKit::WebPage::setResizesToContentsUsingLayoutSize):
170         (WebKit::WebPage::setUseFixedLayout):
171         * WebProcess/WebPage/WebPage.h:
172         (WebKit::WebPage::useFixedLayout):
173
174             Store the state as m_useFixedLayout so that it can be used
175             from the WebFrameLoaderClient.
176
177 2011-11-17  Zalan Bujtas  <zbujtas@gmail.com>
178
179         [Qt][WK2] Do not apply new viewport properties until after the first visually non-empty layout.
180         https://bugs.webkit.org/show_bug.cgi?id=72508
181
182         Delay applying viewport properties on the viewport item until after the first visually non-empty
183         layout finished. It enables the viewport to be intact until the new page is ready to be rendered.
184
185         Reviewed by Kenneth Rohde Christiansen.
186
187         * UIProcess/API/qt/qquickwebview.cpp:
188         (QQuickWebViewPrivate::QQuickWebViewPrivate):
189         (QQuickWebViewPrivate::loadDidCommit):
190         (QQuickWebViewPrivate::didFinishFirstNonEmptyLayout):
191         (QQuickWebViewPrivate::didChangeContentsSize):
192         (QQuickWebViewPrivate::didChangeViewportProperties):
193         (QQuickWebViewPrivate::updateViewportSize):
194         (QQuickWebViewPrivate::computeViewportConstraints):
195         * UIProcess/API/qt/qquickwebview_p.h:
196         (PostTransitionState::isTransitioningToNewPage):
197         * UIProcess/qt/ClientImpl.cpp:
198         (qt_wk_didFirstVisuallyNonEmptyLayoutForFrame):
199         (setupPageLoaderClient):
200         * UIProcess/qt/QtViewInterface.cpp:
201         (WebKit::QtViewInterface::didFinishFirstNonEmptyLayout):
202         (WebKit::QtViewInterface::didChangeContentsSize):
203         (WebKit::QtViewInterface::didChangeViewportProperties):
204         (WebKit::QtViewInterface::startDrag):
205         * UIProcess/qt/QtViewInterface.h:
206         * UIProcess/qt/QtViewportInteractionEngine.cpp:
207         (WebKit::QtViewportInteractionEngine::reset):
208         (WebKit::QtViewportInteractionEngine::applyConstraints):
209         * UIProcess/qt/QtViewportInteractionEngine.h:
210         * UIProcess/qt/QtWebPageProxy.cpp:
211         (QtWebPageProxy::didFinishFirstNonEmptyLayout):
212         (QtWebPageProxy::didChangeContentsSize):
213         (QtWebPageProxy::didChangeViewportProperties):
214         (QtWebPageProxy::startDrag):
215         * UIProcess/qt/QtWebPageProxy.h:
216
217 2011-11-17  Eunmi Lee  <eunmi15.lee@samsung.com>
218
219         Reviewed by Martin Robinson.
220
221         [WK2] Move gtk/BackingStoreGtk.cpp to cairo/BackingStoreCairo.cpp to share with EFL port.
222         https://bugs.webkit.org/show_bug.cgi?id=62444
223
224         Rename gtk/BackingStoreGtk.cpp to cairo/BackingStoreCairo.cpp to share with EFL port.
225         The gtk/BackingStoreGtk.cpp only has cairo dependency, so it can be shared with other port
226         that uses cairo.
227
228         * GNUmakefile.am:
229         * UIProcess/BackingStore.h:
230         * UIProcess/cairo/BackingStoreCairo.cpp: Renamed from Source/WebKit2/UIProcess/gtk/BackingStoreGtk.cpp.
231         (WebKit::BackingStore::paint):
232         (WebKit::BackingStore::incorporateUpdate):
233         (WebKit::BackingStore::scroll):
234
235 2011-11-17  Nayan Kumar K  <nayankk@motorola.com>
236
237         [WebKit2][gtk] Add few more properties to WebKitSettings
238         https://bugs.webkit.org/show_bug.cgi?id=72468
239
240         Reviewed by Martin Robinson.
241
242         Add 'enable-private-browsing', 'enable-developer-extras, 'enable-resizable-text-areas'
243         and 'enable-tabs-to-links' properties to WebKitSettings.
244
245         * UIProcess/API/gtk/WebKitSettings.cpp:
246         (webKitSettingsSetProperty): Add new set functions.
247         (webKitSettingsGetProperty): Add new get functions.
248         (webkit_settings_class_init): Add new properties.
249         (webkit_settings_get_enable_private_browsing): Get 'enable-private-browsing' property.
250         (webkit_settings_set_enable_private_browsing): Set 'enable-private-browsing' property.
251         (webkit_settings_get_enable_developer_extras): Get 'enable-developer-extras' property.
252         (webkit_settings_set_enable_developer_extras): Set 'enable-developer-extras' property.
253         (webkit_settings_get_enable_resizable_text_areas): Get 'enable-resizable-text-areas' property.
254         (webkit_settings_set_enable_resizable_text_areas): Set 'enable-resizable-text-areas' property.
255         (webkit_settings_get_enable_tabs_to_links): Get 'enable-tabs-to-links' property.
256         (webkit_settings_set_enable_tabs_to_links): Set 'enable-tabs-to-links' property.
257         * UIProcess/API/gtk/WebKitSettings.h: New public APIs added.
258         * UIProcess/API/gtk/docs/webkit2gtk-sections.txt: New APIs added.
259         * UIProcess/API/gtk/tests/TestWebKitSettings.cpp:
260         (testWebKitSettings): Add new tests.
261
262 2011-11-17  Carlos Garcia Campos  <cgarcia@igalia.com>
263
264         Unreviewed. Fix WebKit2 GTK+ build after r100569.
265
266         * WebProcess/Downloads/soup/DownloadSoup.cpp:
267         (WebKit::DownloadClient::didReceiveResponse):
268
269 2011-11-17  Nayan Kumar K  <nayankk@motorola.com>
270
271         [WebKit2][gtk] Fix assert while running TestWebKitSettings
272         https://bugs.webkit.org/show_bug.cgi?id=72469
273
274         Reviewed by Martin Robinson.
275
276         * UIProcess/API/gtk/tests/TestWebKitSettings.cpp:
277         (testWebKitSettings): Correct the test.
278
279 2011-11-16  Carlos Garcia Campos  <cgarcia@igalia.com>
280
281         [GTK] Use a URI instead of local path to create download destination in WebKit2
282         https://bugs.webkit.org/show_bug.cgi?id=72500
283
284         Reviewed by Philippe Normand.
285
286         * WebProcess/Downloads/soup/DownloadSoup.cpp:
287         (WebKit::DownloadClient::didReceiveResponse): Use
288         g_file_new_for_uri() instad of g_file_new_for_path(). Also use
289         adoptGRef to fix a memory leak.
290
291 2011-11-16  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>
292
293         [Qt] Fix build after WTR AX support
294         https://bugs.webkit.org/show_bug.cgi?id=72560
295
296         Reviewed by Geoffrey Garen.
297
298         * WebProcess/InjectedBundle/API/c/WKBundlePage.cpp:
299         (WKAccessibilityRootObject):
300         (WKAccessibilityFocusedObject):
301
302 2011-11-11  Adrienne Walker  <enne@google.com>
303
304         [chromium] Expose mock scrollbars to window.internals
305         https://bugs.webkit.org/show_bug.cgi?id=72195
306
307         Reviewed by James Robinson.
308
309         * win/WebKit2.def:
310         * win/WebKit2CFLite.def:
311
312 2011-11-16  Dan Bernstein  <mitz@apple.com>
313
314         WebKit2 part of <rdar://problem/10262242> Add API for paginated display
315         https://bugs.webkit.org/show_bug.cgi?id=72537
316
317         Reviewed by Anders Carlsson.
318
319         * Shared/WebPageCreationParameters.cpp:
320         (WebKit::WebPageCreationParameters::encode): Encode the pagination mode and gap between pages.
321         (WebKit::WebPageCreationParameters::decode): Decode the pagination mode and gap between pages.
322         * Shared/WebPageCreationParameters.h: Added paginationMode and gapBetweenPages members.
323         * UIProcess/API/C/WKPage.cpp:
324         (WKPageSetPaginationMode): Added this API wrapper.
325         (WKPageGetPaginationMode): Ditto.
326         (WKPageSetGapBetweenPages): Ditto.
327         (WKPageGetGapBetweenPages): Ditto.
328         (WKPageGetPageCount): Ditto.
329         * UIProcess/API/C/WKPagePrivate.h: Added an enum and a definition of WKPaginationMode and
330         accessors.
331         * UIProcess/API/mac/WKBrowsingContextController.mm:
332         (-[WKBrowsingContextController setPaginationMode:]): Added this API wrapper.
333         (-[WKBrowsingContextController paginationMode]): Ditto.
334         (-[WKBrowsingContextController setGapBetweenPages:]): Ditto.
335         (-[WKBrowsingContextController gapBetweenPages]): Ditto.
336         (-[WKBrowsingContextController pageCount]): Ditto.
337         * UIProcess/API/mac/WKBrowsingContextControllerPrivate.h: Added. Includes an enum and a definition
338         of WKBrowsingContextPaginationMode and property declarations.
339         * UIProcess/WebPageProxy.cpp:
340         (WebKit::WebPageProxy::WebPageProxy): Added intialization of m_paginationMode, m_gapBetweenPages,
341         and m_pageCount.
342         (WebKit::WebPageProxy::setPaginationMode): Added this accessor, which caches the value and sends
343         a message to the WebPage.
344         (WebKit::WebPageProxy::setGapBetweenPages): Ditto.
345         (WebKit::WebPageProxy::creationParameters): Set the pagination mode and gap between pages in the
346         creation parameters.
347         (WebKit::WebPageProxy::didChangePageCount): Added. Updates the cached page count.
348         * UIProcess/WebPageProxy.h:
349         (WebKit::WebPageProxy::paginationMode): Added this getter that returns a cached value.
350         (WebKit::WebPageProxy::gapBetweenPages): Ditto.
351         (WebKit::WebPageProxy::pageCount): Ditto.
352         * UIProcess/WebPageProxy.messages.in: Added DidChangedPageCount, sent when the page count changes
353         after layout.
354         * WebKit2.xcodeproj/project.pbxproj: Added WKBrowsingContextControllerPrivate.h.
355         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp: 
356         (WebKit::WebFrameLoaderClient::dispatchDidLayout): Added a call to WebPage::mainFrameDidLayout(),
357         allowing the page to respond to changes in the column count.
358         * WebProcess/WebPage/WebPage.cpp:
359         (WebKit::WebPage::WebPage): Added initializer for m_cachedPageCount.
360         (WebKit::WebPage::setPaginationMode): Added.
361         (WebKit::WebPage::setGapBetweenPages): Added.
362         (WebKit::WebPage::mainFrameDidLayout): Added. Sends a DidChangePageCount message to the UI process
363         if the page count has changed.
364         * WebProcess/WebPage/WebPage.h:
365         * WebProcess/WebPage/WebPage.messages.in: Added SetPaginationMode and SetGapBetweenPages messages.
366
367 2011-11-16  Chris Fleizach  <cfleizach@apple.com>
368
369         WebKitTestRunner needs to support accessibility-related DRT APIs
370         https://bugs.webkit.org/show_bug.cgi?id=42131
371
372         Allow the injected bundle to retrieve the focused and root accessibility
373         objects.
374
375         Reviewed by Beth Dakin.
376
377         * WebProcess/InjectedBundle/API/c/WKBundlePage.cpp:
378         (WKAccessibilityRootObject):
379         (WKAccessibilityFocusedObject):
380         * WebProcess/InjectedBundle/API/c/WKBundlePagePrivate.h:
381
382 2011-11-16  Beth Dakin  <bdakin@apple.com>
383
384         https://bugs.webkit.org/show_bug.cgi?id=72400
385         Scrollbar uiStateTransitionProgress requires tracking the mouse all the time
386         -and corresponding-
387         <rdar://problem/10409328>
388
389         Reviewed by Darin Adler.
390
391         Set up our initial tracking area based on the currently recommended scrollbar 
392         style. Track the mouse all the time if the style is legacy.
393         * UIProcess/API/mac/WKView.mm:
394         (-[WKView initWithFrame:contextRef:pageGroupRef:]):
395
396         Now that we might be getting mouseMoved events all the time even when the window 
397         is not key, make sure we opt into the new 'onlyUpdateScrollbars' mode for 
398         EventHandler::mouseMoved() when the window is not focused.
399         * WebProcess/WebPage/WebPage.cpp:
400         (WebKit::handleMouseEvent):
401         (WebKit::WebPage::mouseEvent):
402         (WebKit::WebPage::mouseEventSyncForTesting):
403
404 2011-11-16  Martin Robinson  <mrobinson@igalia.com>
405
406         [GTK][WEBKIT2] Link error running gtkdoc-scangobj
407         https://bugs.webkit.org/show_bug.cgi?id=72365
408
409         Reviewed by Xan Lopez.
410
411         * webkit2gtk.pc.in: Add a libjavascriptcore requirement to the WebKit2 pkgconfig
412         file so that the compiler links to it.
413
414 2011-11-16  Balazs Kelemen  <kbalazs@webkit.org>
415
416         [WK2][X11] Don't leak the colormap we created for the plugin
417         https://bugs.webkit.org/show_bug.cgi?id=72144
418
419         Reviewed by Xan Lopez.
420
421         * WebProcess/Plugins/Netscape/x11/NetscapePluginX11.cpp:
422         (WebKit::NetscapePlugin::platformDestroy):
423
424 2011-11-16  Viatcheslav Ostapenko  <ostapenko.viatcheslav@nokia.com>
425
426         [Qt] [WK2] Crash in Connection::readyReadHandler() on socket error
427         https://bugs.webkit.org/show_bug.cgi?id=72392
428
429         Reviewed by Simon Hausmann.
430
431         Add QWeakPointer to SocketNotifierResourceGuard::m_socketNotifier to track
432         deallocation of referenced object.
433
434         * Platform/CoreIPC/unix/ConnectionUnix.cpp:
435         (CoreIPC::SocketNotifierResourceGuard::SocketNotifierResourceGuard):
436         (CoreIPC::SocketNotifierResourceGuard::~SocketNotifierResourceGuard):
437
438 2011-11-16  Zeno Albisser  <zeno@webkit.org>
439
440         [Qt][WK2][Mac] MiniBrowser cannot create socketpair.
441         https://bugs.webkit.org/show_bug.cgi?id=72389
442
443         Use SOCK_DGRAM on mac instead of SOCK_SEQPACKET.
444
445         Reviewed by Tor Arne Vestbø.
446
447         * UIProcess/Launcher/qt/ProcessLauncherQt.cpp:
448
449 2011-11-15  Carlos Garcia Campos  <cgarcia@igalia.com>
450
451         [GTK] Add webkit_web_view_load_request() to WebKit2 GTK+ API
452         https://bugs.webkit.org/show_bug.cgi?id=72380
453
454         Reviewed by Martin Robinson.
455
456         It adds an initial implementation of WebKitNetworkRequest
457         class that only contains a URI for now.
458
459         * GNUmakefile.am:
460         * UIProcess/API/gtk/WebKitNetworkRequest.cpp: Added.
461         (webkitNetworkRequestFinalize):
462         (webkitNetworkRequestGetProperty):
463         (webkitNetworkRequestSetProperty):
464         (webkit_network_request_class_init):
465         (webkit_network_request_init):
466         (webkit_network_request_new):
467         (webkit_network_request_get_uri):
468         * UIProcess/API/gtk/WebKitNetworkRequest.h: Added.
469         * UIProcess/API/gtk/WebKitWebView.cpp:
470         (webkit_web_view_load_request): Use WKPageLoadURLRequest() to load
471         the given WebKitNetworkRequest.
472         * UIProcess/API/gtk/WebKitWebView.h:
473         * UIProcess/API/gtk/docs/webkit2gtk-sections.txt: Add new symbols.
474         * UIProcess/API/gtk/tests/TestWebKitWebLoaderClient.cpp:
475         (testLoadRequest):
476         (beforeAll):
477         * UIProcess/API/gtk/tests/WebViewTest.cpp:
478         (WebViewTest::loadRequest):
479         * UIProcess/API/gtk/tests/WebViewTest.h:
480         * UIProcess/API/gtk/webkit2.h:
481
482 2011-11-15  Andy Estes  <aestes@apple.com>
483
484         Consolidate the logic that creates run loop observers for flushing layer tree changes to CoreAnimation
485         https://bugs.webkit.org/show_bug.cgi?id=72106
486
487         Reviewed by Anders Carlsson.
488
489         Remove code that schedules layer flushes and use LayerFlushScheduler instead.
490
491         * WebProcess/WebPage/ca/mac/LayerTreeHostCAMac.h: Replace
492         m_flushPendingLayerChangesRunLoopObserver with m_layerFlushScheduler
493         and implement the LayerFlushSchedulerClient interface.
494         * WebProcess/WebPage/ca/mac/LayerTreeHostCAMac.mm:
495         (WebKit::LayerTreeHostCAMac::LayerTreeHostCAMac): Instantiate
496         m_layerFlushScheduler with the LayerTreeHost as the client.
497         (WebKit::LayerTreeHostCAMac::~LayerTreeHostCAMac):
498         (WebKit::LayerTreeHostCAMac::scheduleLayerFlush): Call LayerFlushScheduler::schedule().
499         (WebKit::LayerTreeHostCAMac::setLayerFlushSchedulingEnabled): Call
500         LayerFlushScheduler::suspend() or LayerFlushScheduler::resume().
501         (WebKit::LayerTreeHostCAMac::invalidate): Call LayerFlushScheduler::invalidate().
502         (WebKit::LayerTreeHostCAMac::flushLayers): Do the work that
503         flushPendingLayerChangesRunLoopObserverCallback() used to do.
504         (WebKit::LayerTreeHostCAMac::didPerformScheduledLayerFlush): Call LayerFlushScheduler::invalidate().
505
506 2011-11-15  Sam Weinig  <sam@webkit.org>
507
508         Add a connection client to the WKContext, to notify when new connections to the WebProcess are established
509         https://bugs.webkit.org/show_bug.cgi?id=72433
510
511         Reviewed by Anders Carlsson.
512
513         * UIProcess/API/C/WKContext.cpp:
514         (WKContextSetConnectionClient):
515         * UIProcess/API/C/WKContext.h:
516         * UIProcess/WebContext.cpp:
517         (WebKit::WebContext::initializeConnectionClient):
518         * UIProcess/WebContext.h:
519         Add connection client API.
520
521         * UIProcess/WebContextConnectionClient.cpp: Added.
522         (WebKit::WebContextConnectionClient::didCreateConnection):
523         * UIProcess/WebContextConnectionClient.h: Added.
524         Add basic implementation of the client. It is currently never triggered.
525
526 2011-11-15  Jongseok Yang  <js45.yang@samsung.com>
527
528         [SOUP][WK2] Add initial WebCookieManagerSoup.cpp for webkit2
529         https://bugs.webkit.org/show_bug.cgi?id=72235
530
531         Reviewed by Gustavo Noronha Silva.
532
533         Add WebCookieManagerSoup.cpp and implement functions for the cookie accept policy.
534         It's required when using the soup network backend.
535         Remove WebCookieManagerEfl.cpp and WebCookieManagerGtk.cpp because GTK port and
536         EFL port use soup network backend without a network backend of their own.
537
538         * GNUmakefile.am:
539         * WebProcess/Cookies/efl/WebCookieManagerEfl.cpp: Removed.
540         * WebProcess/Cookies/gtk/WebCookieManagerGtk.cpp: Removed.
541         * WebProcess/Cookies/soup/WebCookieManagerSoup.cpp: Added.
542         (WebKit::WebCookieManager::platformSetHTTPCookieAcceptPolicy):
543         (WebKit::WebCookieManager::platformGetHTTPCookieAcceptPolicy):
544
545 2011-11-15  Jochen Eisinger  <jochen@chromium.org>
546
547         Rename ReferrerPolicy to clarify its meaning
548         https://bugs.webkit.org/show_bug.cgi?id=72420
549
550         Reviewed by Nate Chapin.
551
552         * WebProcess/WebCoreSupport/WebContextMenuClient.cpp:
553         (WebKit::WebContextMenuClient::searchWithGoogle):
554         * WebProcess/WebPage/WebPage.cpp:
555         (WebKit::WebPage::linkClicked):
556
557 2011-11-15  Sam Weinig  <sam@webkit.org>
558
559         Fix windows build.
560
561         * win/WebKit2Generated.make:
562
563 2011-11-15  Sam Weinig  <sam@webkit.org>
564
565         Add WebKit2 API object to represent a connection
566         https://bugs.webkit.org/show_bug.cgi?id=72421
567
568         Reviewed by Anders Carlsson.
569
570         * GNUmakefile.am:
571         * Target.pri:
572         * WebKit2.xcodeproj/project.pbxproj:
573         * win/WebKit2.vcproj:
574         Add new files.
575
576         * Shared/API/c/WKBase.h:
577         Add type.
578
579         * Shared/API/c/WKConnectionRef.cpp: Added.
580         (WKConnectionGetTypeID):
581         (WKConnectionSetConnectionClient):
582         (WKConnectionPostMessage):
583         * Shared/API/c/WKConnectionRef.h: Added.
584         Expose interface. Currently no support for synchronous messages.
585
586         * Shared/API/c/WKSharedAPICast.h:
587         Define relationship between WebConnection <-> WKConnectionRef.
588
589         * Shared/APIObject.h:
590         Add API type.
591
592         * Shared/WebConnection.cpp: Added.
593         (WebKit::WebConnection::~WebConnection):
594         (WebKit::WebConnection::initializeConnectionClient):
595         * Shared/WebConnection.h: Added.
596         (WebKit::WebConnection::type):
597         Sketch out the connection object. It is currently abstract
598         to allow different implementations for the UI and WebProcess sides
599         while retaining the same interface.
600
601         * Shared/WebConnectionClient.cpp: Added.
602         (WebKit::WebConnectionClient::didReceiveMessage):
603         (WebKit::WebConnectionClient::didClose):
604         * Shared/WebConnectionClient.h: Added.
605         Add simple client.
606
607         * UIProcess/API/C/WebKit2.h:
608         Add new file.
609
610 2011-11-15  Chris Fleizach2  <cfleizach@apple.com>
611
612         AX: WKAccessibilityWebObjectPage should not call super in accessibilityAttributeValue:
613         https://bugs.webkit.org/show_bug.cgi?id=72344
614
615         Reviewed by Beth Dakin.
616
617         * WebProcess/WebPage/mac/WKAccessibilityWebPageObject.mm:
618         (-[WKAccessibilityWebPageObject accessibilityAttributeValue:]):
619
620 2011-11-15  Anders Carlsson  <andersca@apple.com>
621
622         HostWindow screenToWindow/windowToScreen should be screenToRootView/rootViewToScreen
623         https://bugs.webkit.org/show_bug.cgi?id=72397
624
625         Reviewed by Dan Bernstein.
626
627         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
628         (WebKit::WebChromeClient::screenToRootView):
629         (WebKit::WebChromeClient::rootViewToScreen):
630         * WebProcess/WebCoreSupport/WebChromeClient.h:
631
632 2011-11-14  Anders Carlsson  <andersca@apple.com>
633
634         HostWindow invalidation functions should use root view coordinates
635         https://bugs.webkit.org/show_bug.cgi?id=72338
636
637         Reviewed by Dan Bernstein.
638
639         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
640         (WebKit::WebChromeClient::invalidateRootView):
641         (WebKit::WebChromeClient::invalidateContentsAndRootView):
642         * WebProcess/WebCoreSupport/WebChromeClient.h:
643
644 2011-11-15  Carlos Garcia Campos  <cgarcia@igalia.com>
645
646         [GTK] Implement download support in WebKit2
647         https://bugs.webkit.org/show_bug.cgi?id=72258
648
649         Reviewed by Martin Robinson.
650
651         * WebProcess/Downloads/Download.h:
652         * WebProcess/Downloads/soup/DownloadSoup.cpp:
653         (WebKit::DownloadClient::DownloadClient):
654         (WebKit::DownloadClient::downloadFailed):
655         (WebKit::DownloadClient::didReceiveResponse):
656         (WebKit::DownloadClient::didReceiveData):
657         (WebKit::DownloadClient::didFinishLoading):
658         (WebKit::DownloadClient::didFail):
659         (WebKit::DownloadClient::wasBlocked):
660         (WebKit::DownloadClient::cannotShowURL):
661         (WebKit::Download::start):
662         (WebKit::Download::startWithHandle):
663         (WebKit::Download::cancel):
664         (WebKit::Download::platformInvalidate):
665
666 2011-11-15  Mario Sanchez Prada  <msanchez@igalia.com>
667
668         [GTK][WEBKIT2] Add enable-caret-browsing property to WebKitSettings
669         https://bugs.webkit.org/show_bug.cgi?id=72267
670
671         Reviewed by Martin Robinson.
672
673         Allow getting and setting the 'enable-caret-browsing' property
674         through WebKitSettings.
675
676         * UIProcess/API/gtk/WebKitSettings.cpp:
677         (webKitSettingsSetProperty): Added property setter.
678         (webKitSettingsGetProperty): Added propery getter.
679         (webkit_settings_class_init): Install property.
680         (webkit_settings_get_enable_caret_browsing): Added.
681         (webkit_settings_set_enable_caret_browsing): Added.
682         * UIProcess/API/gtk/WebKitSettings.h: Expose new public APIs.
683         * UIProcess/API/gtk/docs/webkit2gtk-sections.txt: Add new sections for gtk-doc generation.
684         * UIProcess/API/gtk/tests/TestWebKitSettings.cpp:
685         (testWebKitSettings): Added new API test.
686
687 2011-11-14  Julien Chaffraix  <jchaffraix@webkit.org>
688
689         Add --css-grid-layout to build-webkit and the build systems
690         https://bugs.webkit.org/show_bug.cgi?id=72320
691
692         Reviewed by Ojan Vafai.
693
694         * Configurations/FeatureDefines.xcconfig:
695
696 2011-11-14  Tony Chang  <tony@chromium.org>
697
698         Remove the CSS3_FLEXBOX compile time flag and enable on all ports
699         https://bugs.webkit.org/show_bug.cgi?id=72196
700
701         Reviewed by Ojan Vafai.
702
703         * Configurations/FeatureDefines.xcconfig:
704
705 2011-11-14  Viatcheslav Ostapenko  <ostapenko.viatcheslav@nokia.com>
706
707         Intermittent asserts in TextureMapperGL::bindSurface on MiniBrowser startup
708         https://bugs.webkit.org/show_bug.cgi?id=72299
709
710         Reviewed by Noam Rosenthal.
711
712         Added check that clipping rect is valid.
713         Clear GL error that might remain from QT GL operations.
714         Added GL error assert for scissor test operations.
715
716         * UIProcess/API/qt/qquickwebpage.cpp:
717         (QQuickWebPagePrivate::paintToCurrentGLContext):
718
719 2011-11-14  Anders Carlsson  <andersca@apple.com>
720
721         Only send progress notifications for the main frame
722         https://bugs.webkit.org/show_bug.cgi?id=72302
723
724         Reviewed by Sam Weinig.
725
726         Since it's impossible in the API to tell which frame the progress notifications are for, just send them to the main frame for now.
727
728         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
729         (WebKit::WebFrameLoaderClient::postProgressStartedNotification):
730         (WebKit::WebFrameLoaderClient::postProgressEstimateChangedNotification):
731         (WebKit::WebFrameLoaderClient::postProgressFinishedNotification):
732
733 2011-11-14  Alexis Menard  <alexis.menard@openbossa.org>
734
735         [Qt][WK2] Cleanup QML tests.
736         https://bugs.webkit.org/show_bug.cgi?id=72259
737
738         Reviewed by Simon Hausmann.
739
740         Cleanup QML tests. This patch removes the duplicates after the merge of both views.
741         I also isolated the desktop specific bits into its own directory.
742
743         * UIProcess/API/qt/tests/qmltests/DesktopBehavior/tst_download.qml: Renamed from Source/WebKit2/UIProcess/API/qt/tests/qmltests/DesktopWebView/tst_download.qml.
744         * UIProcess/API/qt/tests/qmltests/DesktopBehavior/tst_linkHovered.qml: Renamed from Source/WebKit2/UIProcess/API/qt/tests/qmltests/DesktopWebView/tst_linkHovered.qml.
745         * UIProcess/API/qt/tests/qmltests/DesktopBehavior/tst_messaging.qml: Renamed from Source/WebKit2/UIProcess/API/qt/tests/qmltests/DesktopWebView/tst_messaging.qml.
746         * UIProcess/API/qt/tests/qmltests/DesktopBehavior/tst_navigationPolicyForUrl.qml: Renamed from Source/WebKit2/UIProcess/API/qt/tests/qmltests/DesktopWebView/tst_navigationPolicyForUrl.qml.
747         * UIProcess/API/qt/tests/qmltests/DesktopWebView/tst_loadProgressSignal.qml: Removed.
748         * UIProcess/API/qt/tests/qmltests/DesktopWebView/tst_loadZeroSizeView.qml: Removed.
749         * UIProcess/API/qt/tests/qmltests/DesktopWebView/tst_properties.qml: Removed.
750         * UIProcess/API/qt/tests/qmltests/TouchWebView/tst_load.qml: Removed.
751         * UIProcess/API/qt/tests/qmltests/TouchWebView/tst_loadFail.qml: Removed.
752         * UIProcess/API/qt/tests/qmltests/TouchWebView/tst_loadNegativeSizeView.qml: Removed.
753         * UIProcess/API/qt/tests/qmltests/TouchWebView/tst_loadProgress.qml: Removed.
754         * UIProcess/API/qt/tests/qmltests/WebView/tst_loadFail.qml: Renamed from Source/WebKit2/UIProcess/API/qt/tests/qmltests/DesktopWebView/tst_loadFail.qml.
755         * UIProcess/API/qt/tests/qmltests/WebView/tst_loadProgress.qml: Renamed from Source/WebKit2/UIProcess/API/qt/tests/qmltests/DesktopWebView/tst_loadProgress.qml.
756         * UIProcess/API/qt/tests/qmltests/WebView/tst_loadProgressSignal.qml: Renamed from Source/WebKit2/UIProcess/API/qt/tests/qmltests/TouchWebView/tst_loadProgressSignal.qml.
757         * UIProcess/API/qt/tests/qmltests/WebView/tst_loadZeroSizeView.qml: Renamed from Source/WebKit2/UIProcess/API/qt/tests/qmltests/TouchWebView/tst_loadZeroSizeView.qml.
758         * UIProcess/API/qt/tests/qmltests/WebView/tst_preferences.qml: Renamed from Source/WebKit2/UIProcess/API/qt/tests/qmltests/DesktopWebView/tst_preferences.qml.
759         * UIProcess/API/qt/tests/qmltests/WebView/tst_properties.qml: Renamed from Source/WebKit2/UIProcess/API/qt/tests/qmltests/TouchWebView/tst_properties.qml.
760         * UIProcess/API/qt/tests/qmltests/qmltests.pro:
761
762 2011-11-14  Mario Sanchez Prada  <msanchez@igalia.com>
763
764         Add support for the caretBrowsingEnabled preference in WebKit2
765         https://bugs.webkit.org/show_bug.cgi?id=72266
766
767         Reviewed by Chris Fleizach.
768
769         * Shared/WebPreferencesStore.h: Add caretBrowsingEnabled getter
770         and setter macro.
771         * UIProcess/API/C/WKPreferences.h:
772         * UIProcess/API/C/WKPreferences.cpp:
773         (WKPreferencesSetCaretBrowsingEnabled): Added.
774         (WKPreferencesGetCaretBrowsingEnabled): Added.
775         * WebProcess/WebPage/WebPage.cpp:
776         (WebKit::WebPage::updatePreferences): Update the
777         caretBrowsingEnabledKey preference.
778
779 2011-11-14  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>
780
781         [Qt] Remove reference to QWebNavigationController
782         https://bugs.webkit.org/show_bug.cgi?id=72257
783
784         Reviewed by Simon Hausmann.
785
786         QWebNavigationController was removed in r99946, this is just a leftover.
787
788         * UIProcess/API/qt/qquickwebview.cpp:
789         (QQuickWebViewPrivate::QQuickWebViewPrivate):
790         * UIProcess/API/qt/qquickwebview_p.h:
791
792 2011-11-10  Kenneth Rohde Christiansen  <kenneth@webkit.org>
793
794         [Qt] the QQuickWebView should support double-tap to zoom
795         https://bugs.webkit.org/show_bug.cgi?id=72030
796
797         Reviewed by Andreas Kling.
798
799         * UIProcess/qt/QtViewInterface.cpp:
800         * UIProcess/qt/QtViewInterface.h:
801         * UIProcess/qt/QtViewportInteractionEngine.cpp:
802         (WebKit::QtViewportInteractionEngine::animateItemRectVisible):
803         (WebKit::QtViewportInteractionEngine::zoomToAreaGestureEnded):
804         (WebKit::QtViewportInteractionEngine::ensureContentWithinViewportBoundary):
805         * UIProcess/qt/QtViewportInteractionEngine.h:
806         * UIProcess/qt/QtWebPageProxy.cpp:
807         (QtWebPageProxy::didFindZoomableArea):
808
809 2011-11-14  Zalan Bujtas  <zbujtas@gmail.com>
810
811         Build breaks with --no-javascript-debugger --no-inspector
812         https://bugs.webkit.org/show_bug.cgi?id=72228
813
814         Reviewed by Simon Hausmann.
815
816         * UIProcess/WebPageProxy.cpp:
817         (WebKit::WebPageProxy::maybeInitializeSandboxExtensionHandle):
818
819 2011-11-13  Mark Rowe  <mrowe@apple.com>
820
821         Fix the 32-bit build.
822
823         * WebProcess/mac/WebProcessMac.mm:
824         (WebKit::initializeSandbox): Use a format specifier and cast that works on more architectures.
825
826 2011-11-12  Laszlo Gombos  <laszlo.1.gombos@nokia.com>
827
828         [Qt][Symbian] Remove support for WINSCW compiler
829         https://bugs.webkit.org/show_bug.cgi?id=70178
830
831         Reviewed by Chang Shu.
832
833         * Shared/API/c/WKString.h:
834
835 2011-11-12  Dan Bernstein  <mitz@apple.com>
836
837         <rdar://problem/10294191> REGRESSION (WebKit2): Lookup bubble sized and positioned incorrectly (vertically off)
838         https://bugs.webkit.org/show_bug.cgi?id=72217
839
840         Reviewed by Dave Hyatt.
841
842         * UIProcess/API/mac/PageClientImpl.mm:
843         (WebKit::PageClientImpl::didPerformDictionaryLookup): Rather than adding the NSFont’s ascender
844         to the top of the text rect to establish the baseline here...
845         * WebProcess/WebPage/mac/WebPageMac.mm:
846         (WebKit::WebPage::performDictionaryLookupForRange): ...do it here, using the WebCore::Font’s
847         ascender, which is what’s actually used when drawing the text.
848
849 2011-11-11  Nayan Kumar K  <nayankk@motorola.com>
850
851         [GTK][WEBKIT2] Add font and charset properties to WebKitWebSettings
852         https://bugs.webkit.org/show_bug.cgi?id=68996
853
854         Reviewed by Martin Robinson.
855
856         Provision to query and set the font related properties (such as
857         font-family, font-size) and charset properties (such as default-
858         charset) is added.
859
860         * UIProcess/API/gtk/WebKitSettings.cpp: Added font and encoding properties.
861         (webKitSettingsSetProperty): GObject set property function.
862         (webKitSettingsGetProperty): GObject get property function.
863         (webkit_settings_class_init): Few more signals installed.
864         (webkit_settings_init): Initialization of instance variables.
865         (webkit_web_settings_get_default_font_family): Get 'default-font-family'.
866         (webkit_web_settings_set_default_font_family): Set 'default-font-family'.
867         (webkit_web_settings_get_monospace_font_family): Get 'monospace-font-family'.
868         (webkit_web_settings_set_monospace_font_family): Set 'monospace-font-family'.
869         (webkit_web_settings_get_serif_font_family): Get 'serif-font-family'.
870         (webkit_web_settings_set_serif_font_family): Set 'serif-font-family'.
871         (webkit_web_settings_get_sans_serif_font_family): Get 'sans-serif-font-family'.
872         (webkit_web_settings_set_sans_serif_font_family): Get 'sans-serif-font-family'.
873         (webkit_web_settings_get_cursive_font_family): Get 'cursive-font-family'.
874         (webkit_web_settings_set_cursive_font_family): Set 'cursive-font-family'.
875         (webkit_web_settings_get_fantasy_font_family): Get 'fantasy-font-family'.
876         (webkit_web_settings_set_fantasy_font_family): Set 'fantasy-font-family'.
877         (webkit_web_settings_get_pictograph_font_family): Get 'pictograph-font-family'.
878         (webkit_web_settings_set_pictograph_font_family): Set 'pictograph-font-family'.
879         (webkit_web_settings_get_default_font_size): Get 'default-font-size'.
880         (webkit_web_settings_set_default_font_size): Set 'default-font-size'.
881         (webkit_web_settings_get_default_monospace_font_size): Get 'default-monospace-font-size'.
882         (webkit_web_settings_set_default_monospace_font_size): Set 'default-monospace-font-size'.
883         (webkit_web_settings_get_minimum_font_size): Get 'minimum-font-size'.
884         (webkit_web_settings_set_minimum_font_size): Set 'minimum-font-size'.
885         (webkit_web_settings_get_default_charset): Get 'default-charset'.
886         (webkit_web_settings_set_default_charset): Set 'default-charset'.
887         * UIProcess/API/gtk/WebKitSettings.h: Add new sections for gtk-doc generation.
888         * UIProcess/API/gtk/docs/webkit2gtk-sections.txt: Expose new public APIs.
889         * UIProcess/API/gtk/tests/TestWebKitSettings.cpp:
890         (testWebKitSettings): Add new tests.
891
892 2011-11-11  Shinya Kawanaka  <shinyak@google.com>
893
894         Implement legacy text check emulation in unified text check interface.
895         https://bugs.webkit.org/show_bug.cgi?id=70299
896
897         Reviewed by Hajime Morita.
898
899         * win/WebKit2.def:
900         * win/WebKit2CFLite.def:
901
902 2011-11-11  Alexey Proskuryakov  <ap@apple.com>
903
904         WebProcess should use AppSandbox style quarantine
905         https://bugs.webkit.org/show_bug.cgi?id=72168
906         <rdar://problem/10434292>
907
908         Reviewed by Darin Adler.
909
910         * WebProcess/mac/WebProcessMac.mm: (WebKit::initializeSandbox): Just enable it.
911
912 2011-11-11  Darin Adler  <darin@apple.com>
913
914         * WebKit2.xcodeproj/project.pbxproj: Let a newer Xcode update this file.
915         If an older Xcode downgrades this file and we have a risk of some kind of
916         oscillating commit situation, please contact me so I know not to do this again.
917
918 2011-11-11  Mark Hahnenberg  <mhahnenberg@apple.com>
919
920         Add jsCast to replace static_cast
921         https://bugs.webkit.org/show_bug.cgi?id=72071
922
923         Reviewed by Geoffrey Garen.
924
925         Added new jsCast and changed all of the static_cast sites in functions that 
926         are in the MethodTable to use jsCast instead.
927
928         * WebProcess/Plugins/Netscape/JSNPObject.cpp:
929         (WebKit::JSNPObject::getCallData):
930         (WebKit::JSNPObject::getConstructData):
931         (WebKit::JSNPObject::getOwnPropertySlot):
932         (WebKit::JSNPObject::getOwnPropertyDescriptor):
933         (WebKit::JSNPObject::put):
934         (WebKit::JSNPObject::deleteProperty):
935         (WebKit::JSNPObject::deletePropertyByIndex):
936         (WebKit::JSNPObject::getOwnPropertyNames):
937
938 2011-11-11  Timothy Hatcher  <timothy@apple.com>
939
940         Only use the textured window style mask when there is no override inspector page.
941
942         https://webkit.org/b/72142
943
944         Reviewed by Dan Bernstein.
945
946         * UIProcess/mac/WebInspectorProxyMac.mm:
947         (WebKit::WebInspectorProxy::platformOpen): Don't set NSTexturedBackgroundWindowMask if
948         there is an override inspector page. Make setAutorecalculatesContentBorderThickness:,
949         setContentBorderThickness: and WKNSWindowMakeBottomCornersSquare conditional.
950
951 2011-11-11  Simon Hausmann  <simon.hausmann@nokia.com>
952
953         [Qt] Remove dead MeeGoTouch code.
954
955         Reviewed by Tor Arne Vestbø.
956
957         * WebProcess/qt/WebProcessMainQt.cpp:
958         (WebKit::WebProcessMainQt):
959
960 2011-11-11  Alexis Menard  <alexis.menard@openbossa.org>
961
962         [Qt] Add a way to have experimental features in WebKit2
963         https://bugs.webkit.org/show_bug.cgi?id=67707
964
965         Reviewed by Kenneth Rohde Christiansen.
966
967         Add new QML extensions for our public view. This extension
968         returns the private object of the view so that the user could
969         use unstable/unreleased APIs. This requires our private class
970         to be exported and QObject subclass.
971
972         * Target.pri:
973         * UIProcess/API/qt/qquickwebview.cpp:
974         * UIProcess/API/qt/qquickwebview_p.h:
975         * UIProcess/API/qt/qquickwebviewprivateextension.cpp: Added.
976         (QQuickWebViewPrivateExtension::QQuickWebViewPrivateExtension):
977         (QQuickWebViewPrivateExtension::viewPrivate):
978         * UIProcess/API/qt/qquickwebviewprivateextension_p.h: Added.
979
980 2011-11-11  Simon Hausmann  <simon.hausmann@nokia.com>
981
982         [Qt][WK2] Remove QWebNavigationController
983         https://bugs.webkit.org/show_bug.cgi?id=72113
984
985         Reviewed by Andreas Kling.
986
987         Fold the functions and properties of QWebNavigationController into
988         QQuickWebView.
989
990         * Target.pri:
991         * UIProcess/API/qt/WKView.h:
992         * UIProcess/API/qt/qquickwebpage.cpp:
993         (QQuickWebPagePrivate::QQuickWebPagePrivate):
994         * UIProcess/API/qt/qquickwebpage.h:
995         * UIProcess/API/qt/qquickwebpage_p.h:
996         * UIProcess/API/qt/qquickwebview.cpp:
997         (QQuickWebViewPrivate::initialize):
998         (QQuickWebView::goBack):
999         (QQuickWebView::goForward):
1000         (QQuickWebView::stop):
1001         (QQuickWebView::reload):
1002         (QQuickWebView::canGoBack):
1003         (QQuickWebView::canGoForward):
1004         (QQuickWebView::canStop):
1005         (QQuickWebView::canReload):
1006         (QQuickWebView::title):
1007         * UIProcess/API/qt/qquickwebview.h:
1008         * UIProcess/API/qt/qwebnavigationcontroller.cpp: Removed.
1009         * UIProcess/API/qt/qwebnavigationcontroller.h: Removed.
1010         * UIProcess/API/qt/tests/qquickwebview/tst_qquickwebview.cpp:
1011         (tst_QQuickWebView::navigationStatusAtStartup):
1012         (LoadStartedCatcher::onLoadStarted):
1013         (tst_QQuickWebView::stopEnabledAfterLoadStarted):
1014         (tst_QQuickWebView::backAndForward):
1015         (tst_QQuickWebView::reload):
1016         (tst_QQuickWebView::stop):
1017
1018 2011-11-10  Beth Dakin  <bdakin@apple.com>
1019
1020         Once more for the QT build.
1021
1022         * UIProcess/qt/QtWebPageProxy.cpp:
1023         (QtWebPageProxy::setFindIndicator):
1024         * UIProcess/qt/QtWebPageProxy.h:
1025
1026 2011-11-10  Beth Dakin  <bdakin@apple.com>
1027
1028         More attempted build fix.
1029
1030         * UIProcess/API/efl/PageClientImpl.cpp:
1031         (WebKit::PageClientImpl::setFindIndicator):
1032         * UIProcess/API/efl/PageClientImpl.h:
1033         * UIProcess/API/gtk/PageClientImpl.cpp:
1034         (WebKit::PageClientImpl::setFindIndicator):
1035         * UIProcess/API/gtk/PageClientImpl.h:
1036
1037 2011-11-10  Anders Carlsson  <andersca@apple.com>
1038
1039         Fix 32-bit build.
1040
1041         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
1042         (-[WKContentLayer drawInContext:]):
1043
1044 2011-11-10  Beth Dakin  <bdakin@apple.com>
1045
1046         Speculative build fix.
1047
1048         * UIProcess/win/WebView.cpp:
1049         (WebKit::WebView::setFindIndicator):
1050         * UIProcess/win/WebView.h:
1051
1052 2011-11-10  Beth Dakin  <bdakin@apple.com>
1053
1054         https://bugs.webkit.org/show_bug.cgi?id=66584
1055         WebKit2's find bouncy looks blurry after dragging window onto >1.0 scale factor 
1056         display
1057         -and corresponding-
1058         <rdar://problem/9987559>
1059
1060         Reviewed by Anders Carlsson.
1061
1062         The setFindIndicator message and various functions of the same name must all take 
1063         an additional parameter indicating whether or not setting the find indicator 
1064         should result in a bounce animation. This is because when the device scale factor 
1065         changes, if there is currently a find indicator, it must be re-set to a higher or 
1066         lower resolution version, but we don't want the bounce animation to happen again.
1067         * UIProcess/API/mac/FindIndicatorWindow.h:
1068         * UIProcess/API/mac/FindIndicatorWindow.mm:
1069         (WebKit::FindIndicatorWindow::setFindIndicator):
1070         * UIProcess/API/mac/PageClientImpl.h:
1071         * UIProcess/API/mac/PageClientImpl.mm:
1072         (WebKit::PageClientImpl::setFindIndicator):
1073         * UIProcess/API/mac/WKView.mm:
1074         (-[WKView _setFindIndicator:fadeOut:animate:]):
1075         * UIProcess/API/mac/WKViewInternal.h:
1076         * UIProcess/PageClient.h:
1077         * UIProcess/WebPageProxy.cpp:
1078         (WebKit::WebPageProxy::setFindIndicator):
1079         * UIProcess/WebPageProxy.h:
1080         * UIProcess/WebPageProxy.messages.in:
1081
1082         New function FindController::isShowingOverlay() is used to determine if 
1083         FindController::deviceScaleFactorDidChange() needs to be called.
1084         * WebProcess/WebPage/FindController.h:
1085         (WebKit::FindController::isShowingOverlay): 
1086
1087         FindController::deviceScaleFactorDidChange() calls updateFindIndicator to re-
1088         generate the bitmap at the appropriate scale factor, but tells it not to animate 
1089         this time.
1090         (WebKit::FindController::deviceScaleFactorDidChange):
1091
1092         updateFindIndicator() takes a new parameter indicating whether or not the 
1093         FindIndicator should animate. It defaults to true since the deviceScaleFactor 
1094         changing is the only case currently where we do not want it to animate.
1095         * WebProcess/WebPage/FindController.cpp:
1096         (WebKit::FindController::updateFindIndicator):
1097         (WebKit::FindController::hideFindIndicator):
1098
1099         Calls into FindController::deviceScaleFactorDidChange() when the scale factor has 
1100         changed and the find overlay is showing.
1101         * WebProcess/WebPage/WebPage.cpp:
1102         (WebKit::WebPage::setDeviceScaleFactor):
1103
1104 2011-11-10  Timothy Hatcher  <timothy@apple.com>
1105
1106         Make WKViews in NSPopovers render as they would in active windows.
1107
1108         The NSWindowDid{Become,Resign}KeyNotifications are not fired when NSPopovers
1109         are shown or hidden since they share key with the parent window. So WKView
1110         needs to update the active state during order on/off screen notifications.
1111
1112         https://webkit.org/b/68435
1113
1114         Reviewed by John Sullivan.
1115
1116         * UIProcess/API/mac/WKView.mm:
1117         (-[WKView _windowDidOrderOffScreen:]): Call viewStateDidChange with WebPageProxy::ViewWindowIsActive.
1118         (-[WKView _windowDidOrderOnScreen:]): Ditto.
1119
1120 2011-11-10  Anders Carlsson  <andersca@apple.com>
1121
1122         Add a simple content layer to TiledCoreAnimationDrawingArea
1123         https://bugs.webkit.org/show_bug.cgi?id=72044
1124
1125         Reviewed by Darin Adler.
1126
1127         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.h:
1128         Add a content layer member variable.
1129
1130         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
1131         (-[WKContentLayer _initWithWebPage:WebKit::]):
1132         Add initializer.
1133
1134         (-[WKContentLayer drawInContext:]):
1135         Lay out and draw the web page.
1136
1137         (WebKit::TiledCoreAnimationDrawingArea::TiledCoreAnimationDrawingArea):
1138         Add the content layer as a sublayer of the root layer.
1139
1140         (WebKit::TiledCoreAnimationDrawingArea::setNeedsDisplay):
1141         (WebKit::TiledCoreAnimationDrawingArea::scroll):
1142         Tell the content layer to paint.
1143
1144         (WebKit::TiledCoreAnimationDrawingArea::updateGeometry):
1145         Resize the content layer as well.
1146
1147 2011-11-10  Anders Carlsson  <andersca@apple.com>
1148
1149         The WKView layer hosting subview needs to be flipped
1150         https://bugs.webkit.org/show_bug.cgi?id=72042
1151
1152         Reviewed by Darin Adler.
1153
1154         In order to match the Core Animation layer hierarchy, the layer hosting WKView
1155         subview needs to be flipped.
1156
1157         * UIProcess/API/mac/WKView.mm:
1158         (-[WKFlippedView isFlipped]):
1159         Add a NSView subview whose sole purpose is to be flipped.
1160
1161         (-[WKView _enterAcceleratedCompositingMode:]):
1162         Create a WKFlippedView instead of a regular NSView.
1163
1164 2011-11-10  Balazs Kelemen  <kbalazs@webkit.org>
1165
1166         [Qt] X11 plugins need to be reworked for Qt5
1167         https://bugs.webkit.org/show_bug.cgi?id=70023
1168
1169         Reviewed by Simon Hausmann.
1170
1171         * Target.pri:
1172         * UIProcess/Plugins/unix/PluginInfoStoreUnix.cpp:
1173         (WebKit::PluginInfoStore::pluginsDirectories):
1174         Kill the last dependency from the WebKit1 plugin system.
1175         This is necessary because currently we don't build the WebKit1
1176         plugin code. The function is equivalent with the XP_UNIX part of
1177         PluginDatabase::defaultPluginDirectories.
1178
1179         * WebProcess/Plugins/Netscape/NetscapeBrowserFuncs.cpp:
1180         (WebKit::NPN_GetValue):
1181         * WebProcess/Plugins/Netscape/NetscapePlugin.h:
1182         * WebProcess/Plugins/Netscape/x11/NetscapePluginX11.cpp:
1183         (WebKit::getPluginDisplay):
1184         (WebKit::x11Screen):
1185         (WebKit::displayDepth):
1186         (WebKit::rootWindowID):
1187         (WebKit::NetscapePlugin::x11HostDisplay):
1188         (WebKit::NetscapePlugin::platformPostInitialize):
1189         (WebKit::NetscapePlugin::platformDestroy):
1190         (WebKit::NetscapePlugin::platformGeometryDidChange):
1191         (WebKit::NetscapePlugin::platformPaint):
1192         (WebKit::initializeXEvent):
1193         Rework plugin initialization and drawing model.
1194
1195 2011-11-10  Martin Robinson  <mrobinson@igalia.com>
1196
1197         [GTK] [WebKit2] Fix remaining gtkdoc errors
1198         https://bugs.webkit.org/show_bug.cgi?id=71990
1199
1200         Reviewed by Philippe Normand.
1201
1202         * UIProcess/API/gtk/WebKitWebView.cpp: Update add the phrase "property" to
1203         references to properties, because the gtkdoc stylesheet does not differeniate
1204         between properties and signals. Standardize the way we talk about property
1205         notifications.
1206         * UIProcess/API/gtk/docs/webkit2gtk-docs.sgml: Add an include to silence 
1207         warnings about GIR annotations.
1208         * UIProcess/API/gtk/docs/webkit2gtk-sections.txt: Add the decorators the private section.
1209
1210 2011-11-10  Kenneth Rohde Christiansen  <kenneth@webkit.org>
1211
1212         [Qt] Clean up how singe / double taps are handled
1213         https://bugs.webkit.org/show_bug.cgi?id=72024
1214
1215         Reviewed by Simon Hausmann.
1216
1217         Move all decision making to the QtWebPageProxy.
1218
1219         * UIProcess/qt/QtTapGestureRecognizer.cpp:
1220         (WebKit::QtTapGestureRecognizer::QtTapGestureRecognizer):
1221         (WebKit::QtTapGestureRecognizer::recognize):
1222         (WebKit::QtTapGestureRecognizer::tapTimeout):
1223         * UIProcess/qt/QtTapGestureRecognizer.h:
1224         * UIProcess/qt/QtWebPageProxy.cpp:
1225         (QtWebPageProxy::QtWebPageProxy):
1226         (QtWebPageProxy::handleSingleTapEvent):
1227         (QtWebPageProxy::handleDoubleTapEvent):
1228         * UIProcess/qt/QtWebPageProxy.h:
1229
1230 2011-11-10  Simon Hausmann  <simon.hausmann@nokia.com>
1231
1232         [Qt] Clean up build system
1233
1234         Reviewed by Tor Arne Vestbø.
1235
1236         Now that we use whole-archive linking we can fold the files that contain exported
1237         symbols back into the WebKit2 static library.
1238
1239         * Target.pri: Fold in sources from WebKit2.pri.
1240         * WebKit2.pri: Removed.
1241
1242 2011-11-10  Alexis Menard  <alexis.menard@openbossa.org>
1243
1244         [Qt] Merge QTouchWebView and QDesktopWebView into one class
1245         https://bugs.webkit.org/show_bug.cgi?id=71355
1246
1247         Reviewed by Kenneth Rohde Christiansen.
1248
1249         Merge QTouchWebView and QDesktopWebView into one class called
1250         QQuickWebView and its attached page QQuickWebPage. You can switch to the
1251         traditional desktop use case with the private header. Also now on desktop
1252         platforms AC is turn on by default. I also merged our two
1253         subclasses of QtViewInterface into one as the split doesn't make
1254         that much sense anymore. In the future we want to be able to enable the
1255         traditional desktop use case depending the platform the code is running.
1256         API tests and QML tests have been updated.
1257
1258         * Target.pri:
1259         * UIProcess/API/qt/WKView.h:
1260         * UIProcess/API/qt/qbasewebview.cpp: Removed.
1261         * UIProcess/API/qt/qbasewebview_p.h: Removed.
1262         * UIProcess/API/qt/qdesktopwebview.cpp: Removed.
1263         * UIProcess/API/qt/qdesktopwebview.h: Removed.
1264         * UIProcess/API/qt/qdesktopwebview_p.h: Removed.
1265         * UIProcess/API/qt/qquickwebpage.cpp: Renamed from Source/WebKit2/UIProcess/API/qt/qtouchwebpage.cpp.
1266         (QQuickWebPage::QQuickWebPage):
1267         (QQuickWebPage::~QQuickWebPage):
1268         (QQuickWebPage::keyPressEvent):
1269         (QQuickWebPage::keyReleaseEvent):
1270         (QQuickWebPage::inputMethodEvent):
1271         (QQuickWebPage::focusInEvent):
1272         (QQuickWebPage::focusOutEvent):
1273         (QQuickWebPage::mousePressEvent):
1274         (QQuickWebPage::mouseMoveEvent):
1275         (QQuickWebPage::mouseReleaseEvent):
1276         (QQuickWebPage::mouseDoubleClickEvent):
1277         (QQuickWebPage::wheelEvent):
1278         (QQuickWebPage::hoverEnterEvent):
1279         (QQuickWebPage::hoverMoveEvent):
1280         (QQuickWebPage::hoverLeaveEvent):
1281         (QQuickWebPage::dragMoveEvent):
1282         (QQuickWebPage::dragEnterEvent):
1283         (QQuickWebPage::dragLeaveEvent):
1284         (QQuickWebPage::dropEvent):
1285         (QQuickWebPage::geometryChanged):
1286         (QQuickWebPage::event):
1287         (QQuickWebPage::touchEvent):
1288         (QQuickWebPage::itemChange):
1289         (QQuickWebPagePrivate::QQuickWebPagePrivate):
1290         (QQuickWebPagePrivate::initializeSceneGraphConnections):
1291         (QQuickWebPagePrivate::setPageProxy):
1292         (computeEffectiveOpacity):
1293         (QQuickWebPagePrivate::paintToCurrentGLContext):
1294         (QQuickWebPagePrivate::_q_onAfterSceneRender):
1295         (QQuickWebPagePrivate::_q_onSceneGraphInitialized):
1296         * UIProcess/API/qt/qquickwebpage.h: Renamed from Source/WebKit2/UIProcess/API/qt/qtouchwebpage.h.
1297         * UIProcess/API/qt/qquickwebpage_p.h: Renamed from Source/WebKit2/UIProcess/API/qt/qtouchwebpage_p.h.
1298         * UIProcess/API/qt/qquickwebview.cpp: Added.
1299         (QQuickWebViewPrivate::QQuickWebViewPrivate):
1300         (QQuickWebViewPrivate::enableMouseEvents):
1301         (QQuickWebViewPrivate::disableMouseEvents):
1302         (QQuickWebViewPrivate::initialize):
1303         (QQuickWebViewPrivate::initializeDesktop):
1304         (QQuickWebViewPrivate::initializeTouch):
1305         (QQuickWebViewPrivate::loadDidCommit):
1306         (QQuickWebViewPrivate::contentSizeChanged):
1307         (QQuickWebViewPrivate::scrollPositionRequested):
1308         (QQuickWebViewPrivate::_q_viewportUpdated):
1309         (QQuickWebViewPrivate::_q_viewportTrajectoryVectorChanged):
1310         (QQuickWebViewPrivate::_q_onVisibleChanged):
1311         (QQuickWebViewPrivate::updateViewportSize):
1312         (QQuickWebViewPrivate::updateViewportConstraints):
1313         (QQuickWebViewPrivate::didChangeViewportProperties):
1314         (QQuickWebViewPrivate::runJavaScriptAlert):
1315         (QQuickWebViewPrivate::runJavaScriptConfirm):
1316         (QQuickWebViewPrivate::runJavaScriptPrompt):
1317         (QQuickWebViewPrivate::chooseFiles):
1318         (QQuickWebViewPrivate::_q_onOpenPanelFilesSelected):
1319         (QQuickWebViewPrivate::_q_onOpenPanelFinished):
1320         (QQuickWebViewPrivate::setUseTraditionalDesktopBehaviour):
1321         (toPolicyAction):
1322         (hasMetaMethod):
1323         (QQuickWebViewPrivate::navigationPolicyForURL):
1324         (QQuickWebViewPrivate::setPageProxy):
1325         (QQuickWebView::QQuickWebView):
1326         (QQuickWebView::~QQuickWebView):
1327         (QQuickWebView::page):
1328         (QQuickWebView::load):
1329         (QQuickWebView::postMessage):
1330         (QQuickWebView::url):
1331         (QQuickWebView::loadProgress):
1332         (QQuickWebView::title):
1333         (QQuickWebView::navigationController):
1334         (QQuickWebView::preferences):
1335         (QQuickWebView::geometryChanged):
1336         (QQuickWebView::touchEvent):
1337         (QQuickWebView::pageRef):
1338         * UIProcess/API/qt/qquickwebview.h: Renamed from Source/WebKit2/UIProcess/API/qt/qbasewebview.h.
1339         * UIProcess/API/qt/qquickwebview_p.h: Added.
1340         * UIProcess/API/qt/qtouchwebview.cpp: Removed.
1341         * UIProcess/API/qt/qtouchwebview.h: Removed.
1342         * UIProcess/API/qt/qtouchwebview_p.h: Removed.
1343         * UIProcess/API/qt/tests/commonviewtests/commonviewtests.pro: Removed.
1344         * UIProcess/API/qt/tests/commonviewtests/tst_commonviewtests.cpp: Removed.
1345         * UIProcess/API/qt/tests/commonviewtests/webviewabstraction.cpp: Removed.
1346         * UIProcess/API/qt/tests/commonviewtests/webviewabstraction.h: Removed.
1347         * UIProcess/API/qt/tests/qdesktopwebview/tst_qdesktopwebview.cpp: Removed.
1348         * UIProcess/API/qt/tests/qmltests/DesktopWebView/tst_download.qml:
1349         * UIProcess/API/qt/tests/qmltests/DesktopWebView/tst_linkHovered.qml:
1350         * UIProcess/API/qt/tests/qmltests/DesktopWebView/tst_loadFail.qml:
1351         * UIProcess/API/qt/tests/qmltests/DesktopWebView/tst_loadProgress.qml:
1352         * UIProcess/API/qt/tests/qmltests/DesktopWebView/tst_loadProgressSignal.qml:
1353         * UIProcess/API/qt/tests/qmltests/DesktopWebView/tst_loadZeroSizeView.qml:
1354         * UIProcess/API/qt/tests/qmltests/DesktopWebView/tst_messaging.qml:
1355         * UIProcess/API/qt/tests/qmltests/DesktopWebView/tst_navigationPolicyForUrl.qml:
1356         * UIProcess/API/qt/tests/qmltests/DesktopWebView/tst_preferences.qml:
1357         * UIProcess/API/qt/tests/qmltests/DesktopWebView/tst_properties.qml:
1358         * UIProcess/API/qt/tests/qmltests/TouchWebView/tst_load.qml:
1359         * UIProcess/API/qt/tests/qmltests/TouchWebView/tst_loadFail.qml:
1360         * UIProcess/API/qt/tests/qmltests/TouchWebView/tst_loadNegativeSizeView.qml:
1361         * UIProcess/API/qt/tests/qmltests/TouchWebView/tst_loadProgress.qml:
1362         * UIProcess/API/qt/tests/qmltests/TouchWebView/tst_loadProgressSignal.qml:
1363         * UIProcess/API/qt/tests/qmltests/TouchWebView/tst_loadZeroSizeView.qml:
1364         * UIProcess/API/qt/tests/qmltests/TouchWebView/tst_properties.qml:
1365         * UIProcess/API/qt/tests/qmltests/qmltests.pro:
1366         * UIProcess/API/qt/tests/qmltests/tst_qmltests.cpp:
1367         (DesktopWebView::DesktopWebView):
1368         (main):
1369         * UIProcess/API/qt/tests/qquickwebview/qquickwebview.pro: Renamed from Source/WebKit2/UIProcess/API/qt/tests/qdesktopwebview/qdesktopwebview.pro.
1370         * UIProcess/API/qt/tests/qquickwebview/tst_qquickwebview.cpp: Added.
1371         (tst_QQuickWebView::tst_QQuickWebView):
1372         (tst_QQuickWebView::init):
1373         (tst_QQuickWebView::cleanup):
1374         (tst_QQuickWebView::webView):
1375         (tst_QQuickWebView::accessPage):
1376         (tst_QQuickWebView::navigationStatusAtStartup):
1377         (LoadStartedCatcher::LoadStartedCatcher):
1378         (LoadStartedCatcher::onLoadStarted):
1379         (tst_QQuickWebView::stopEnabledAfterLoadStarted):
1380         (tst_QQuickWebView::baseUrl):
1381         (tst_QQuickWebView::loadEmptyUrl):
1382         (tst_QQuickWebView::loadEmptyPageViewVisible):
1383         (tst_QQuickWebView::loadEmptyPageViewHidden):
1384         (tst_QQuickWebView::loadNonexistentFileUrl):
1385         (tst_QQuickWebView::backAndForward):
1386         (tst_QQuickWebView::reload):
1387         (tst_QQuickWebView::stop):
1388         (tst_QQuickWebView::loadProgress):
1389         (tst_QQuickWebView::show):
1390         * UIProcess/API/qt/tests/qtouchwebview/qtouchwebview.pro: Removed.
1391         * UIProcess/API/qt/tests/qtouchwebview/tst_qtouchwebview.cpp: Removed.
1392         * UIProcess/API/qt/tests/testwindow.h:
1393         * UIProcess/TiledDrawingAreaProxy.h:
1394         * UIProcess/qt/QtGestureRecognizer.cpp:
1395         (WebKit::QtGestureRecognizer::QtGestureRecognizer):
1396         (WebKit::QtGestureRecognizer::setViewportInteractionEngine):
1397         * UIProcess/qt/QtGestureRecognizer.h:
1398         * UIProcess/qt/QtPanGestureRecognizer.cpp:
1399         (WebKit::QtPanGestureRecognizer::setViewportInteractionEngine):
1400         (WebKit::QtPanGestureRecognizer::recognize):
1401         * UIProcess/qt/QtPanGestureRecognizer.h:
1402         * UIProcess/qt/QtPinchGestureRecognizer.cpp:
1403         (WebKit::QtPinchGestureRecognizer::recognize):
1404         (WebKit::QtPinchGestureRecognizer::setViewportInteractionEngine):
1405         * UIProcess/qt/QtPinchGestureRecognizer.h:
1406         * UIProcess/qt/QtTouchViewInterface.cpp: Removed.
1407         * UIProcess/qt/QtTouchViewInterface.h: Removed.
1408         * UIProcess/qt/QtViewInterface.cpp: Added.
1409         (WebKit::QtViewInterface::QtViewInterface):
1410         (WebKit::QtViewInterface::didFindZoomableArea):
1411         (WebKit::QtViewInterface::sceneGraphUpdateQueue):
1412         (WebKit::QtViewInterface::setViewNeedsDisplay):
1413         (WebKit::QtViewInterface::drawingAreaSize):
1414         (WebKit::QtViewInterface::contentSizeChanged):
1415         (WebKit::QtViewInterface::scrollPositionRequested):
1416         (WebKit::QtViewInterface::isActive):
1417         (WebKit::QtViewInterface::hasFocus):
1418         (WebKit::QtViewInterface::isVisible):
1419         (WebKit::QtViewInterface::startDrag):
1420         (WebKit::QtViewInterface::didChangeViewportProperties):
1421         (WebKit::QtViewInterface::didChangeUrl):
1422         (WebKit::QtViewInterface::didChangeTitle):
1423         (WebKit::QtViewInterface::didChangeToolTip):
1424         (WebKit::QtViewInterface::didChangeStatusText):
1425         (WebKit::QtViewInterface::didChangeCursor):
1426         (WebKit::QtViewInterface::loadDidBegin):
1427         (WebKit::QtViewInterface::loadDidCommit):
1428         (WebKit::QtViewInterface::loadDidSucceed):
1429         (WebKit::QtViewInterface::loadDidFail):
1430         (WebKit::QtViewInterface::didChangeLoadProgress):
1431         (WebKit::QtViewInterface::didMouseMoveOverElement):
1432         (WebKit::QtViewInterface::showContextMenu):
1433         (WebKit::QtViewInterface::hideContextMenu):
1434         (WebKit::QtViewInterface::runJavaScriptAlert):
1435         (WebKit::QtViewInterface::runJavaScriptConfirm):
1436         (WebKit::QtViewInterface::runJavaScriptPrompt):
1437         (WebKit::QtViewInterface::processDidCrash):
1438         (WebKit::QtViewInterface::didRelaunchProcess):
1439         (WebKit::QtViewInterface::engine):
1440         (WebKit::QtViewInterface::downloadRequested):
1441         (WebKit::QtViewInterface::chooseFiles):
1442         * UIProcess/qt/QtViewInterface.h:
1443         * UIProcess/qt/QtWebPageProxy.h:
1444         (QtWebPageProxy::setViewportInteractionEngine):
1445         * UIProcess/qt/TiledDrawingAreaProxyQt.cpp:
1446         * WebKit2.pri:
1447
1448 2011-11-10  Carlos Garcia Campos  <cgarcia@igalia.com>
1449
1450         Unreviewed. Fix make distcheck build.
1451
1452         * GNUmakefile.am: Fix typos in gtk-doc files and scripts.
1453
1454 2011-11-10  Simon Hausmann  <simon.hausmann@nokia.com>
1455
1456         Unreviewed Mac build fix: Remove TapAndHold gesture type.
1457
1458         It broke the build because it's unhandled. Remove it since it's not
1459         supported at the moment anyway. (looks like an accidental addition?)
1460
1461         * Shared/WebEvent.h:
1462         * UIProcess/qt/QtTapGestureRecognizer.cpp:
1463         (WebKit::QtTapGestureRecognizer::tapAndHoldTimeout):
1464
1465 2011-11-09  Simon Hausmann  <simon.hausmann@nokia.com>
1466
1467         [Qt] Enable exports and constructor functions in static libs
1468
1469         Reviewed by Tor Arne Vestbø.
1470
1471         * WebProcess/WebPage/qt/WebPageQt.cpp:
1472         (WebKit::WebPage::platformInitialize): Remove unnecessary manual Qt resource
1473         initialization.
1474
1475 2011-11-10  Zeno Albisser  <zeno.albisser@nokia.com>
1476
1477         [Qt][WK2] Add Tap Gesture recognition to UIProcess
1478         https://bugs.webkit.org/show_bug.cgi?id=71841
1479
1480         Add a Tap gesture recognizer that delivers GestureSingleTap
1481         and GestureTapAndHold events through the WebPageProxy.
1482         Add a GestureTapAndHold to WebEvent.
1483         Add a DoubleTap gesture for zooming in and out.
1484
1485         This patch is based on work of Benjamin Poulain.
1486
1487         Reviewed by Kenneth Rohde Christiansen.
1488
1489         * Shared/WebEvent.h:
1490         * Target.pri:
1491         * UIProcess/qt/QtTapGestureRecognizer.cpp: Added.
1492         (WebKit::QtTapGestureRecognizer::QtTapGestureRecognizer):
1493         (WebKit::QtTapGestureRecognizer::setWebPageProxy):
1494         (WebKit::QtTapGestureRecognizer::recognize):
1495         (WebKit::QtTapGestureRecognizer::tapTimeout):
1496         (WebKit::QtTapGestureRecognizer::tapAndHoldTimeout):
1497         (WebKit::QtTapGestureRecognizer::reset):
1498         (WebKit::QtTapGestureRecognizer::timerEvent):
1499         * UIProcess/qt/QtTapGestureRecognizer.h: Added.
1500         * UIProcess/qt/QtWebPageProxy.cpp:
1501         (QtWebPageProxy::QtWebPageProxy):
1502         (QtWebPageProxy::processDidCrash):
1503         (QtWebPageProxy::doneWithTouchEvent):
1504         * UIProcess/qt/QtWebPageProxy.h:
1505
1506 2011-11-09  Shinya Kawanaka  <shinyak@google.com>
1507
1508         Internals.markerRangeForNode should be able to take markers by specifying a marker type.
1509         https://bugs.webkit.org/show_bug.cgi?id=71792
1510
1511         Reviewed by Hajime Morita.
1512
1513         * win/WebKit2.def: Exposed necessary references.
1514         * win/WebKit2CFLite.def: ditto.
1515
1516 2011-10-26  Martin Robinson  <mrobinson@igalia.com>
1517
1518         [GTK] [WebKit] Replace the gtkdoc autools magic with something more flexible
1519         https://bugs.webkit.org/show_bug.cgi?id=70877
1520
1521         Reviewed by Philippe Normand.
1522
1523         Add a script that runs gtkdoc manually instead of using the autotools
1524         magic. Remove now unused gtkdoc files.
1525
1526         * GNUmakefile.am: Remove references to removed gtkdoc files.
1527         * UIProcess/API/gtk/docs/GNUmakefile.am: Removed.
1528         * UIProcess/API/gtk/docs/build-gtkdoc: Added.
1529         * UIProcess/API/gtk/docs/gtkdoc.py: Added.
1530         * UIProcess/API/gtk/docs/version.xml.in: Removed.
1531
1532 2011-11-09  Alexey Proskuryakov  <ap@apple.com>
1533
1534         <rdar://problem/10423024> WebProcess doesn't use AuthBrokerAgent for proxy credentials
1535         https://bugs.webkit.org/show_bug.cgi?id=71964
1536
1537         Reviewed by Darin Adler.
1538
1539         * WebProcess/com.apple.WebProcess.sb: Allow mach-lookup of com.apple.cfnetwork.AuthBrokerAgent.
1540
1541 2011-11-09  Anders Carlsson  <andersca@apple.com>
1542
1543         Element::boundsInWindowSpace should be Element::boundsInRootViewSpace
1544         https://bugs.webkit.org/show_bug.cgi?id=71955
1545
1546         Reviewed by Sam Weinig.
1547
1548         * WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.cpp:
1549         (WebKit::InjectedBundleNodeHandle::elementBounds):
1550         Call Element::boundsInRootViewSpace.
1551
1552 2011-11-09  Alexis Menard  <alexis.menard@openbossa.org>
1553
1554         WebGraphicsLayer behaves wrongly when no contentsScale is set.
1555         https://bugs.webkit.org/show_bug.cgi?id=71959
1556
1557         Reviewed by Noam Rosenthal.
1558
1559         The contentsScale needs to get a default value just like
1560         TiledBackingStore in case no value is explicitely set.
1561
1562         It is covered by existing tests.
1563
1564         * WebProcess/WebCoreSupport/WebGraphicsLayer.cpp:
1565         (WebCore::WebGraphicsLayer::WebGraphicsLayer):
1566
1567 2011-11-09  Mark Hahnenberg  <mhahnenberg@apple.com>
1568
1569         De-virtualize JSObject::getOwnPropertyDescriptor
1570         https://bugs.webkit.org/show_bug.cgi?id=71523
1571
1572         Reviewed by Sam Weinig.
1573
1574         Added getOwnPropertyDescriptor to the MethodTable, changed all of the 
1575         virtual versions of getOwnPropertyDescriptor to static ones, and 
1576         changed all of the call sites to the corresponding lookup in the MethodTable.
1577
1578         * WebProcess/Plugins/Netscape/JSNPObject.cpp:
1579         (WebKit::JSNPObject::getOwnPropertyDescriptor):
1580         * WebProcess/Plugins/Netscape/JSNPObject.h:
1581
1582 2011-11-09  Alexandru Chiculita  <achicu@adobe.com>
1583
1584         Fixing build on MacOSX SL after 71838
1585         https://bugs.webkit.org/show_bug.cgi?id=71912
1586
1587         Reviewed by Anders Carlsson.
1588
1589         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
1590         (WebKit::TiledCoreAnimationDrawingArea::TiledCoreAnimationDrawingArea):
1591
1592 2011-11-09  Kenneth Rohde Christiansen  <kenneth@webkit.org>
1593
1594         [WebKit2] Prepare viewport meta handling for desktop usage
1595         https://bugs.webkit.org/show_bug.cgi?id=71907
1596
1597         Reviewed by Simon Hausmann.
1598
1599         This is only used by Qt so far. Now we don't always layout pages
1600         without the viewport meta tag, using 980 as the layout width, but
1601         instead we use that value (it is a setting) as a minimum value, or
1602         else we use the viewport width.
1603
1604         * UIProcess/API/qt/qtouchwebview.cpp:
1605         (QTouchWebViewPrivate::updateViewportSize):
1606         (QTouchWebViewPrivate::updateViewportConstraints):
1607         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
1608         (WebKit::WebChromeClient::dispatchViewportPropertiesDidChange):
1609         * WebProcess/WebPage/WebPage.cpp:
1610         (WebKit::WebPage::setViewportSize):
1611
1612 2011-11-09  Simon Hausmann  <simon.hausmann@nokia.com>
1613
1614         Unreviewed, rolling out r99701.
1615         http://trac.webkit.org/changeset/99701
1616
1617         Breaks Qt mac build
1618
1619         * WebProcess/WebPage/qt/WebPageQt.cpp:
1620         (initResources):
1621         (WebKit::WebPage::platformInitialize):
1622
1623 2011-11-09  Simon Hausmann  <simon.hausmann@nokia.com>
1624
1625         [Qt] Enable exports and constructor functions in static libs
1626
1627         Reviewed by Tor Arne Vestbø.
1628
1629         * WebProcess/WebPage/qt/WebPageQt.cpp:
1630         (WebKit::WebPage::platformInitialize): Remove unnecessary manual Qt resource
1631         initialization.
1632
1633 2011-11-09  Simon Hausmann  <simon.hausmann@nokia.com>
1634
1635         [Qt] Fix geolocation enabled build.
1636
1637         Reviewed by Tor Arne Vestbø.
1638
1639         * Target.pri: Add QT += location to get the right module includes.
1640         * UIProcess/qt/WebGeolocationProviderQt.cpp: Include the moc file with the right name (GeoLocation -> Geolocation)
1641         * UIProcess/qt/WebGeolocationProviderQt.h: Removed the ENABLE(GEOLOCATION) guards, otherwise moc doesn't generate
1642         code, because it can't interpret the ENABLE() macro.
1643
1644 2011-11-09  Simon Hausmann  <simon.hausmann@nokia.com>
1645
1646         [Qt] Build system cleanup
1647         https://bugs.webkit.org/show_bug.cgi?id=71815
1648
1649         Reviewed by Kenneth Rohde Christiansen.
1650
1651         * Target.pri: Removed duplicated sources that are compiled also into QtWebKit.so through api.pri.
1652         * UIProcess/qt/WebGeolocationProviderQt.cpp: Include the moc file here, as it should only be compiled
1653         if geolocation is enabled.
1654         * UIProcess/qt/WebGeolocationProviderQt.h: Provide ENABLE(GEOLOCATION) guards around class definition.
1655
1656 2011-11-08  Simon Hausmann  <simon.hausmann@nokia.com>
1657
1658         [Qt] Replace use of QApplication with QGuiApplication
1659         https://bugs.webkit.org/show_bug.cgi?id=71794
1660
1661         Reviewed by Andreas Kling.
1662
1663         * Platform/CoreIPC/unix/ConnectionUnix.cpp: Remove unnecessary QApplication inclusion.
1664         * Platform/qt/RunLoopQt.cpp: Replace QApplication include with QCoreApplication.
1665         * UIProcess/Launcher/qt/ProcessLauncherQt.cpp: Ditto.
1666         * UIProcess/Launcher/qt/ThreadLauncherQt.cpp: Remove unnecessary QApplication inclusion.
1667         * UIProcess/qt/QtWebPageProxy.cpp:
1668         (QtWebPageProxy::handleMousePressEvent): Replace QApplication usage with QStyleHints.
1669         (QtWebPageProxy::handleMouseDoubleClickEvent): Ditto.
1670
1671 2011-11-07  Adam Barth  <abarth@webkit.org>
1672
1673         Move static "policy" state from SecurityOrigin.cpp to SecurityPolicy.cpp
1674         https://bugs.webkit.org/show_bug.cgi?id=71755
1675
1676         Reviewed by Eric Seidel.
1677
1678         * WebProcess/InjectedBundle/InjectedBundle.cpp:
1679         (WebKit::InjectedBundle::addOriginAccessWhitelistEntry):
1680         (WebKit::InjectedBundle::removeOriginAccessWhitelistEntry):
1681         (WebKit::InjectedBundle::resetOriginAccessWhitelists):
1682         * WebProcess/Plugins/PluginView.cpp:
1683         (WebKit::PluginView::loadURL):
1684
1685 2011-11-08  Brent Fulgham  <bfulgham@webkit.org>
1686
1687         [WinCairo] Unreviewed build fix after r99613.
1688
1689         * win/WebKit2CFLite.def: Add missing export.
1690
1691 2011-11-08  Brent Fulgham  <bfulgham@webkit.org>
1692
1693         [WinCairo] Unreviewed build fix after r98624 and r99613.
1694
1695         * win/WebKit2CFLite.def: Add missing exports.
1696
1697 2011-11-08  Beth Dakin  <bdakin@apple.com>
1698
1699         https://bugs.webkit.org/show_bug.cgi?id=71856
1700         WebKit should use new NSWindowDidChangeBackingPropertiesNotification instead of 
1701         old NSWindowDidChangeResolutionNotification
1702         -and corresponding-
1703         <rdar://problem/10317253>
1704
1705         Reviewed by Tim Hatcher.
1706
1707         * UIProcess/API/mac/WKView.mm:
1708         (-[WKView addWindowObserversForWindow:]):
1709         (-[WKView removeWindowObservers]):
1710
1711         We have to check that the backing scale factor actually changed since this 
1712         notification can also be used to signify other changes. 
1713         (-[WKView _windowDidChangeBackingProperties:]):
1714
1715 2011-11-08  Anders Carlsson  <andersca@apple.com>
1716
1717         Add a basic layer hierarchy to the Core Animation drawing area
1718         https://bugs.webkit.org/show_bug.cgi?id=71838
1719
1720         Reviewed by Sam Weinig.
1721
1722         * UIProcess/API/mac/WKView.mm:
1723         (-[WKView drawRect:]):
1724         Return early if we're using a tiled drawing area.
1725
1726         (-[WKView initWithFrame:contextRef:pageGroupRef:]):
1727         If we're using a tiled drawing area, make the WKView layer backed and set its layer
1728         to a simple CALayer with a white background and set the view's content redraw policy
1729         to never to avoid ever calling drawRect.
1730
1731         * UIProcess/DrawingAreaProxy.h:
1732         (WebKit::DrawingAreaProxy::didUpdateGeometry):
1733         * UIProcess/DrawingAreaProxy.messages.in:
1734         Add a new didUpdateGeometry message.
1735
1736         * UIProcess/mac/TiledCoreAnimationDrawingAreaProxy.h:
1737         * UIProcess/mac/TiledCoreAnimationDrawingAreaProxy.mm:
1738         (WebKit::TiledCoreAnimationDrawingAreaProxy::TiledCoreAnimationDrawingAreaProxy):
1739         Initialize m_isWaitingForDidUpdateGeometry.
1740
1741         (WebKit::TiledCoreAnimationDrawingAreaProxy::sizeDidChange):
1742         Send an UpdateGeometry message to the web process and wait for a reply.
1743
1744         (WebKit::TiledCoreAnimationDrawingAreaProxy::enterAcceleratedCompositingMode):
1745         Tell the web page proxy to enter accelerated compositing mode.
1746
1747         (WebKit::TiledCoreAnimationDrawingAreaProxy::exitAcceleratedCompositingMode):
1748         Assert that this function is never called.
1749
1750         (WebKit::TiledCoreAnimationDrawingAreaProxy::didUpdateGeometry):
1751         Send another UpdateGeometry message if needed.
1752
1753         (WebKit::TiledCoreAnimationDrawingAreaProxy::sendUpdateGeometry):
1754         Add helper function to actually send the UpdateGeometry message.
1755
1756         * WebProcess/WebPage/DrawingArea.h:
1757         (WebKit::DrawingArea::updateGeometry):
1758         * WebProcess/WebPage/DrawingArea.messages.in:
1759         Add UpdateGeometry message.
1760
1761         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.h:
1762         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
1763         (WebKit::TiledCoreAnimationDrawingArea::TiledCoreAnimationDrawingArea):
1764         Create a red root layer and a remote layer client that hosts it.
1765
1766         (WebKit::TiledCoreAnimationDrawingArea::updateGeometry):
1767         Resize the root layer and tell the UI process that we've updated the geometry.
1768
1769 2011-11-08  Dan Bernstein  <mitz@apple.com>
1770
1771         <rdar://problem/10262225> Allow RenderView to have columns
1772         https://bugs.webkit.org/show_bug.cgi?id=71840
1773
1774         * win/WebKit2.def: Export Page::setPagination() for WebCoreTestSupport.
1775
1776 2011-11-08  Jon Lee  <jonlee@apple.com>
1777
1778         [WK2] Expose acceptMIMETypes for file inputs
1779         https://bugs.webkit.org/show_bug.cgi?id=71836
1780         <rdar://problem/10407367>
1781
1782         Reviewed by Anders Carlsson.
1783
1784         * Shared/WebOpenPanelParameters.cpp:
1785         (WebKit::WebOpenPanelParameters::acceptMIMETypes):
1786         * Shared/WebOpenPanelParameters.h:
1787         * UIProcess/API/C/WKOpenPanelParameters.cpp:
1788         (WKOpenPanelParametersCopyAcceptedMIMETypes):
1789         * UIProcess/API/C/WKOpenPanelParameters.h:
1790
1791 2011-11-08  Zan Dobersek  <zandobersek@gmail.com>
1792
1793         [WK2][GTK] The default database & local storage directory names should note they exist for Gtk port's needs
1794         https://bugs.webkit.org/show_bug.cgi?id=71837
1795
1796         Reviewed by Martin Robinson.
1797
1798         Ensure that directories for databases and local storage are in a 'webkitgtk'
1799         directory in current user's data directory, noting they originate from the Gtk port.
1800
1801         * UIProcess/gtk/WebContextGtk.cpp:
1802         (WebKit::WebContext::platformDefaultDatabaseDirectory):
1803         (WebKit::WebContext::platformDefaultLocalStorageDirectory):
1804
1805 2011-11-08  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>
1806
1807         [Qt] Workaround some problems in QML API tests
1808         https://bugs.webkit.org/show_bug.cgi?id=71818
1809
1810         Reviewed by Tor Arne Vestbø.
1811
1812         This commit workaround the issue of QML's QtTest crashing when we run tests after
1813         "windowShown". We delay to the next run of the mainloop. This workaround is not
1814         pretty but shouldn't affect the semantics of the tests. And we benefit more from
1815         having working tests right now.
1816
1817         This patch also improves Download to: wait for the load before emitting click, and
1818         properly identifying the "succeeded" signal of the downloadItem object.
1819
1820         * UIProcess/API/qt/tests/qmltests/DesktopWebView/tst_download.qml:
1821         * UIProcess/API/qt/tests/qmltests/DesktopWebView/tst_linkHovered.qml:
1822         * UIProcess/API/qt/tests/qmltests/DesktopWebView/tst_navigationPolicyForUrl.qml:
1823
1824 2011-11-08  Kenneth Rohde Christiansen  <kenneth@webkit.org>
1825
1826         Clean up QtViewportInteractionEngine
1827
1828         Reviewed by Simon Hausmann.
1829
1830         * UIProcess/qt/QtViewportInteractionEngine.cpp:
1831         (WebKit::QtViewportInteractionEngine::QtViewportInteractionEngine):
1832         (WebKit::QtViewportInteractionEngine::setItemRectVisible):
1833
1834             Rename the method to make it more obvious what it does. Avoid implicit
1835             conversion to/from QVariant.
1836
1837         (WebKit::QtViewportInteractionEngine::pagePositionRequest):
1838         (WebKit::QtViewportInteractionEngine::ensureContentWithinViewportBoundary):
1839         (WebKit::QtViewportInteractionEngine::itemSizeChanged):
1840
1841             Only call this method on item size changes, and not for every interaction
1842             with the viewport item. Before this change it was even being called during
1843             animations.
1844
1845         * UIProcess/qt/QtViewportInteractionEngine.h:
1846         (WebKit::QtViewportInteractionEngine::scaleAnimationValueChanged):
1847
1848             Rename to make it clean that this is called from the animator.
1849
1850 2011-11-08  Kenneth Rohde Christiansen  <kenneth@webkit.org>
1851
1852         [Qt] Improve the animation time constant
1853         https://bugs.webkit.org/show_bug.cgi?id=71790
1854
1855         Reviewed by Simon Hausmann.
1856
1857         Use 250 milliseconds instead of 400, which feels a lot more natural
1858         and makes the mini browser feel more responsive.
1859
1860         * UIProcess/qt/QtViewportInteractionEngine.cpp:
1861
1862 2011-11-08  Alexis Menard  <alexis.menard@openbossa.org>
1863
1864         [Qt] Merge QtDesktopWebPageProxy and QtTouchWebPageProxy into QtWebPageProxy.
1865         https://bugs.webkit.org/show_bug.cgi?id=71355
1866
1867         Reviewed by Simon Hausmann.
1868
1869         As we try to unify our public API offer we need to merge our double
1870         WebPageProxy implementations first into a common class. That will help
1871         to merge our TouchWebView and DesktopWebView views into one class later.
1872         This commit just merge stuff around and doesn't contain any functional changes.
1873
1874         * Target.pri:
1875         * UIProcess/API/qt/qdesktopwebview.cpp:
1876         (QDesktopWebViewPrivate::init):
1877         * UIProcess/API/qt/qtouchwebpage.cpp:
1878         (QTouchWebPagePrivate::paintToCurrentGLContext):
1879         * UIProcess/API/qt/qtouchwebpage.h:
1880         * UIProcess/API/qt/qtouchwebpage_p.h:
1881         * UIProcess/API/qt/qtouchwebview.cpp:
1882         (QTouchWebViewPrivate::init):
1883         (QTouchWebViewPrivate::_q_viewportUpdated):
1884         (QTouchWebViewPrivate::_q_viewportTrajectoryVectorChanged):
1885         * UIProcess/API/qt/qtouchwebview_p.h:
1886         * UIProcess/qt/QtDesktopWebPageProxy.cpp: Removed.
1887         * UIProcess/qt/QtDesktopWebPageProxy.h: Removed.
1888         * UIProcess/qt/QtTouchWebPageProxy.cpp: Removed.
1889         * UIProcess/qt/QtTouchWebPageProxy.h: Removed.
1890         * UIProcess/qt/QtWebPageProxy.cpp:
1891         (dragOperationToDropAction):
1892         (QtWebPageProxy::QtWebPageProxy):
1893         (QtWebPageProxy::handleEvent):
1894         (QtWebPageProxy::handleMouseMoveEvent):
1895         (QtWebPageProxy::handleMousePressEvent):
1896         (QtWebPageProxy::handleMouseReleaseEvent):
1897         (QtWebPageProxy::handleMouseDoubleClickEvent):
1898         (QtWebPageProxy::handleWheelEvent):
1899         (QtWebPageProxy::handleHoverLeaveEvent):
1900         (QtWebPageProxy::handleHoverMoveEvent):
1901         (QtWebPageProxy::handleDragEnterEvent):
1902         (QtWebPageProxy::handleDragLeaveEvent):
1903         (QtWebPageProxy::handleDragMoveEvent):
1904         (QtWebPageProxy::handleDropEvent):
1905         (QtWebPageProxy::timerEvent):
1906         (QtWebPageProxy::processDidCrash):
1907         (QtWebPageProxy::didReceiveDownloadResponse):
1908         (QtWebPageProxy::paintContent):
1909         (QtWebPageProxy::createDrawingAreaProxy):
1910         (QtWebPageProxy::renderToCurrentGLContext):
1911         (QtWebPageProxy::doneWithTouchEvent):
1912         (QtWebPageProxy::setVisibleContentRectAndScale):
1913         (QtWebPageProxy::setVisibleContentRectTrajectoryVector):
1914         (QtWebPageProxy::touchEvent):
1915         (QtWebPageProxy::findZoomableAreaForPoint):
1916         * UIProcess/qt/QtWebPageProxy.h:
1917
1918 2011-11-08  Zan Dobersek  <zandobersek@gmail.com>
1919
1920         [WK2][GTK] Application cache directory is incorrectly set
1921         https://bugs.webkit.org/show_bug.cgi?id=70680
1922
1923         Reviewed by Philippe Normand.
1924
1925         Correctly set application cache directory to be in current
1926         user's default cache directory.
1927
1928         * UIProcess/gtk/WebContextGtk.cpp:
1929         (WebKit::WebContext::applicationCacheDirectory):
1930
1931 2011-11-07  Emil A Eklund  <eae@chromium.org>
1932
1933         Revert platform and scrolling to ints
1934         https://bugs.webkit.org/show_bug.cgi?id=71585
1935
1936         Reviewed by Eric Seidel.
1937
1938         Replace all uses of LayoutUnit and related types with ints in platform
1939         and scrolling code.
1940
1941         * WebProcess/Plugins/PDF/BuiltInPDFView.cpp:
1942         (WebKit::BuiltInPDFView::invalidateScrollbarRect):
1943         (WebKit::BuiltInPDFView::visibleHeight):
1944         (WebKit::BuiltInPDFView::visibleWidth):
1945         * WebProcess/Plugins/PDF/BuiltInPDFView.h:
1946
1947 2011-11-07  Adam Barth  <abarth@webkit.org>
1948
1949         Move DomainRelaxationForbidden scheme registry to SchemeRegistry
1950         https://bugs.webkit.org/show_bug.cgi?id=71750
1951
1952         Reviewed by Eric Seidel.
1953
1954         * WebProcess/WebProcess.cpp:
1955         (WebKit::WebProcess::setDomainRelaxationForbiddenForURLScheme):
1956
1957 2011-11-07  Beth Dakin  <bdakin@apple.com>
1958
1959         https://bugs.webkit.org/show_bug.cgi?id=71490
1960         Support uiStateTransitionProgress for scrollbars
1961         -and corresponding-
1962         <rdar://problem/9849612>
1963
1964         Reviewed by Sam Weinig.
1965
1966         Scrollbar::mouseUp() now takes a PlatformMouseEvent as a parameter.
1967         * UIProcess/win/WebPopupMenuProxyWin.cpp:
1968         (WebKit::WebPopupMenuProxyWin::onLButtonUp):
1969         * WebProcess/Plugins/PDF/BuiltInPDFView.cpp:
1970         (WebKit::BuiltInPDFView::handleMouseEvent):
1971
1972 2011-11-07  Alexey Proskuryakov  <ap@apple.com>
1973
1974         The Full Keyboard Access preference should be read in the UI process
1975         https://bugs.webkit.org/show_bug.cgi?id=71734
1976         <rdar://problem/9237619>
1977
1978         Reviewed by Darin Adler.
1979
1980         This is consistent with how other global preferences (like language) are handled, and lets
1981         us tighten up the sandbox a little.
1982
1983         * Shared/WebProcessCreationParameters.cpp:
1984         (WebKit::WebProcessCreationParameters::encode):
1985         (WebKit::WebProcessCreationParameters::decode):
1986         * Shared/WebProcessCreationParameters.h:
1987         Added fullKeyboardAccessEnabled, so that newly started processes have the right preference value.
1988
1989         * UIProcess/WebContext.h:
1990         * UIProcess/WebContext.cpp:
1991         (WebKit::WebContext::fullKeyboardAccessModeChanged): If preference changes while a web process
1992         is already running, tell it.
1993         (WebKit::WebContext::ensureWebProcess): Set parameters.fullKeyboardAccessEnabled from current
1994         preference.
1995
1996         * UIProcess/WebProcessProxy.cpp: (WebKit::WebProcessProxy::fullKeyboardAccessEnabled):
1997         * UIProcess/mac/WebProcessProxyMac.mm: (WebKit::WebProcessProxy::fullKeyboardAccessEnabled):
1998         * UIProcess/WebProcessProxy.h:
1999         Proxy it to Objective-C code. WebProcessProxy is as good place to have the static function
2000         as any. One day, we will make code more consistent with language and other global preferences.
2001
2002         * UIProcess/mac/WKFullKeyboardAccessWatcher.h: Copied from Source/WebKit2/WebProcess/mac/WKFullKeyboardAccessWatcher.h.
2003         * UIProcess/mac/WKFullKeyboardAccessWatcher.mm: Copied from Source/WebKit2/WebProcess/mac/WKFullKeyboardAccessWatcher.mm.
2004         * WebProcess/mac/WKFullKeyboardAccessWatcher.h: Removed.
2005         * WebProcess/mac/WKFullKeyboardAccessWatcher.mm: Removed.
2006         (-[WKFullKeyboardAccessWatcher retrieveKeyboardUIModeFromPreferences:]): Once retrieved,
2007         push the preference value.
2008
2009         * WebKit2.xcodeproj/project.pbxproj: WKFullKeyboardAccessWatcher is now in UI process.
2010
2011         * WebProcess/WebProcess.h:
2012         * WebProcess/WebProcess.cpp:
2013         (WebKit::WebProcess::WebProcess):
2014         (WebKit::WebProcess::fullKeyboardAccessModeChanged):
2015         (WebKit::WebProcess::fullKeyboardAccessEnabled):
2016         * WebProcess/mac/WebProcessMac.mm:
2017         WebCprocess now holds the preference value in a mamber value, which UI process pushes
2018         updates to.
2019
2020         * WebProcess/WebProcess.messages.in: Added a message for changes preference value.
2021
2022         * WebProcess/com.apple.WebProcess.sb: We no longer need read access to com.apple.universalaccess.plist.
2023
2024 2011-11-07  Anders Carlsson  <andersca@apple.com>
2025
2026         Add TiledCoreAnimationDrawingArea stub classes
2027         https://bugs.webkit.org/show_bug.cgi?id=71729
2028
2029         Reviewed by Sam Weinig.
2030
2031         * Shared/DrawingAreaInfo.h:
2032         * UIProcess/API/mac/WKView.mm:
2033         (-[WKView _shouldUseTiledDrawingArea]):
2034         (-[WKView WebKit::]):
2035         * UIProcess/mac/TiledCoreAnimationDrawingAreaProxy.h: Copied from Source/WebKit2/Shared/DrawingAreaInfo.h.
2036         * UIProcess/mac/TiledCoreAnimationDrawingAreaProxy.mm: Copied from Source/WebKit2/WebProcess/WebPage/DrawingArea.cpp.
2037         (WebKit::TiledCoreAnimationDrawingAreaProxy::create):
2038         (WebKit::TiledCoreAnimationDrawingAreaProxy::TiledCoreAnimationDrawingAreaProxy):
2039         (WebKit::TiledCoreAnimationDrawingAreaProxy::~TiledCoreAnimationDrawingAreaProxy):
2040         (WebKit::TiledCoreAnimationDrawingAreaProxy::deviceScaleFactorDidChange):
2041         (WebKit::TiledCoreAnimationDrawingAreaProxy::sizeDidChange):
2042         * WebKit2.xcodeproj/project.pbxproj:
2043         * WebProcess/WebPage/DrawingArea.cpp:
2044         (WebKit::DrawingArea::create):
2045         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.h: Copied from Source/WebKit2/WebProcess/WebPage/DrawingArea.cpp.
2046         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm: Copied from Source/WebKit2/WebProcess/WebPage/DrawingArea.cpp.
2047         (WebKit::TiledCoreAnimationDrawingArea::create):
2048         (WebKit::TiledCoreAnimationDrawingArea::TiledCoreAnimationDrawingArea):
2049         (WebKit::TiledCoreAnimationDrawingArea::~TiledCoreAnimationDrawingArea):
2050         (WebKit::TiledCoreAnimationDrawingArea::setNeedsDisplay):
2051         (WebKit::TiledCoreAnimationDrawingArea::scroll):
2052         (WebKit::TiledCoreAnimationDrawingArea::setRootCompositingLayer):
2053         (WebKit::TiledCoreAnimationDrawingArea::scheduleCompositingLayerSync):
2054
2055 2011-11-07  Anders Carlsson  <andersca@apple.com>
2056
2057         Follow-up build fix.
2058
2059         * WebProcess/WebPage/DrawingAreaImpl.h:
2060
2061 2011-11-07  Anders Carlsson  <andersca@apple.com>
2062
2063         Remove unused DrawingArea::syncCompositingLayers
2064         https://bugs.webkit.org/show_bug.cgi?id=71717
2065
2066         Reviewed by John Sullivan.
2067
2068         * WebProcess/WebPage/DrawingArea.h:
2069         * WebProcess/WebPage/DrawingAreaImpl.cpp:
2070         * WebProcess/WebPage/TiledDrawingArea.h:
2071
2072 2011-11-07  Anders Carlsson  <andersca@apple.com>
2073
2074         Rename NetscapePlugin::wantsWindowRelativeNPWindowCoordinates to NetscapePlugin::wantsPluginRelativeNPWindowCoordinates
2075         https://bugs.webkit.org/show_bug.cgi?id=71708
2076
2077         Reviewed by Sam Weinig.
2078
2079         The name wantsPluginRelativeNPWindowCoordinates is more clear than wantsWindowRelativeNPWindowCoordinates. Rename the functions
2080         everywhere and, since the meaning is now inverted, invert the checks and return values.
2081
2082         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
2083         (WebKit::NetscapePlugin::callSetWindow):
2084         (WebKit::NetscapePlugin::geometryDidChange):
2085         * WebProcess/Plugins/Netscape/NetscapePlugin.h:
2086         * WebProcess/Plugins/Netscape/NetscapePluginNone.cpp:
2087         (WebKit::NetscapePlugin::wantsPluginRelativeNPWindowCoordinates):
2088         * WebProcess/Plugins/Netscape/mac/NetscapePluginMac.mm:
2089         (WebKit::NetscapePlugin::wantsPluginRelativeNPWindowCoordinates):
2090         * WebProcess/Plugins/Netscape/win/NetscapePluginWin.cpp:
2091         (WebKit::NetscapePlugin::wantsPluginRelativeNPWindowCoordinates):
2092         * WebProcess/Plugins/Netscape/x11/NetscapePluginX11.cpp:
2093         (WebKit::NetscapePlugin::wantsPluginRelativeNPWindowCoordinates):
2094
2095 2011-11-07  Anders Carlsson  <andersca@apple.com>
2096
2097         NetscapePlugin::wantsWindowRelativeNPWindowCoordinates should return false on Mac
2098         https://bugs.webkit.org/show_bug.cgi?id=71707
2099
2100         Reviewed by Sam Weinig.
2101
2102         This changes the way the fake Carbon plug-in window is positioned, so that it's always the same size
2103         and location as the plug-in (relative to the screen).
2104
2105         * WebProcess/Plugins/Netscape/NetscapePlugin.h:
2106         * WebProcess/Plugins/Netscape/mac/NetscapePluginMac.mm:
2107         (WebKit::NetscapePlugin::platformGeometryDidChange):
2108         Call updateFakeWindowBounds.
2109
2110         (WebKit::NetscapePlugin::updateFakeWindowBounds):
2111         Convert the plug-in position to screen coordinates and set the window bounds to be the location and
2112         size of the plug-in, where the location is relative to the screen.
2113
2114         (WebKit::NetscapePlugin::wantsWindowRelativeNPWindowCoordinates):
2115         Return false.
2116
2117         (WebKit::NetscapePlugin::windowAndViewFramesChanged):
2118         Call updateFakeWindowBounds.
2119
2120 2011-11-07  Sam Weinig  <sam@webkit.org>
2121
2122         WKPage.h should be in PrivateHeaders.
2123
2124         Rubber-stamped by Anders Carlsson.
2125
2126         * WebKit2.xcodeproj/project.pbxproj:
2127         Mark WKPage.h private.
2128
2129 2011-11-07  Anders Carlsson  <andersca@apple.com>
2130
2131         Simplify NetscapePlugin::convertPoint and make it work (in theory) with transformed plug-ins
2132         https://bugs.webkit.org/show_bug.cgi?id=71699
2133
2134         Reviewed by Sam Weinig.
2135
2136         Add a getScreenTransform function which given a coordinate space returns a transform that converts a
2137         point from that coordinate space to the screen coordinate space. We then get the source -> screen transform
2138         and the destination -> screen transform. We invert the destination -> screen transform, multiply it with the
2139         source -> screen transform and use mapPoint to get a complete affine transform from the source to the destination space
2140         and use mapPoint to map the source point and return the destination point.
2141
2142         * WebProcess/Plugins/Netscape/NetscapePlugin.h:
2143         * WebProcess/Plugins/Netscape/mac/NetscapePluginMac.mm:
2144         (WebKit::NetscapePlugin::getScreenTransform):
2145         (WebKit::NetscapePlugin::convertPoint):
2146
2147         * WebProcess/Plugins/PluginView.cpp:
2148         (WebKit::PluginView::initializePlugin):
2149         Call windowAndViewFramesChanged before viewGeometryDidChange so that the window and view frames will be up to date by
2150         the time NPP_SetWindow is called in the plug-in.
2151
2152 2011-11-07  Kenneth Rohde Christiansen  <kenneth@webkit.org>
2153
2154         [Qt] Put handling of gestures and their interaction in one place
2155         https://bugs.webkit.org/show_bug.cgi?id=71682
2156
2157         Reviewed by Simon Hausmann.
2158
2159         Before this patch, the interaction (ie. cancelling animations, events)
2160         was handled in the respective recognizers which then knew about each
2161         others.
2162
2163         * UIProcess/qt/QtGestureRecognizer.h:
2164         (WebKit::QtGestureRecognizer::isRecognized):
2165         * UIProcess/qt/QtPanGestureRecognizer.cpp:
2166         (WebKit::QtPanGestureRecognizer::recognize):
2167         * UIProcess/qt/QtPanGestureRecognizer.h:
2168         * UIProcess/qt/QtPinchGestureRecognizer.cpp:
2169         (WebKit::QtPinchGestureRecognizer::recognize):
2170         * UIProcess/qt/QtPinchGestureRecognizer.h:
2171         * UIProcess/qt/QtTouchWebPageProxy.cpp:
2172         (QtTouchWebPageProxy::QtTouchWebPageProxy):
2173         (QtTouchWebPageProxy::doneWithTouchEvent):
2174         * UIProcess/qt/QtTouchWebPageProxy.h:
2175         * UIProcess/qt/QtViewportInteractionEngine.cpp:
2176         (WebKit::QtViewportInteractionEngine::pagePositionRequest):
2177         (WebKit::QtViewportInteractionEngine::ensureContentWithinViewportBoundary):
2178         (WebKit::QtViewportInteractionEngine::scrollAnimationActive):
2179         (WebKit::QtViewportInteractionEngine::interruptScrollAnimation):
2180         (WebKit::QtViewportInteractionEngine::panGestureActive):
2181         (WebKit::QtViewportInteractionEngine::scaleAnimationActive):
2182         (WebKit::QtViewportInteractionEngine::interruptScaleAnimation):
2183         (WebKit::QtViewportInteractionEngine::pinchGestureActive):
2184         * UIProcess/qt/QtViewportInteractionEngine.h:
2185
2186 2011-11-07  Simon Hausmann  <simon.hausmann@nokia.com>
2187
2188         [Qt] Make it possible to include qdesktopwebview.h from apps
2189
2190         Reviewed by Tor Arne Vestbø.
2191
2192         * UIProcess/API/qt/qdesktopwebview.h: Don't include C API headers, forward
2193         declare the structs manually.
2194
2195 2011-11-07  Simon Hausmann  <simon.hausmann@nokia.com>
2196
2197         [Qt] Fix failing inspector tests after build system changes
2198         https://bugs.webkit.org/show_bug.cgi?id=71677
2199
2200         Reviewed by Tor Arne Vestbø.
2201
2202         Ensure symbols from the qt resource system are referenced
2203         from outside the static webcore library. One way of doing that is
2204         to initialize the resources right away, as explained in the documentation
2205         of th Qt resource system.
2206
2207         * WebProcess/WebPage/qt/WebPageQt.cpp:
2208         (initResources):
2209         (WebKit::WebPage::platformInitialize):
2210
2211 2011-11-03  Anders Carlsson  <andersca@apple.com>
2212
2213         Add NetscapePlugin::convertFromRootView
2214         https://bugs.webkit.org/show_bug.cgi?id=71526
2215
2216         Reviewed by Sam Weinig.
2217
2218         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
2219         (WebKit::NetscapePlugin::convertFromRootView):
2220         New function that converts a point from root view coordinates to plug-in coordinates.
2221         Returns false if the conversion can't be done.
2222
2223         * WebProcess/Plugins/Netscape/NetscapePlugin.h:
2224         * WebProcess/Plugins/Netscape/mac/NetscapePluginMac.mm:
2225         (WebKit::fillInCocoaEventFromMouseEvent):
2226         (WebKit::initializeMouseEvent):
2227         (WebKit::NetscapePlugin::platformHandleMouseEvent):
2228         (WebKit::NetscapePlugin::platformHandleWheelEvent):
2229         (WebKit::NetscapePlugin::platformHandleMouseEnterEvent):
2230         (WebKit::NetscapePlugin::platformHandleMouseLeaveEvent):
2231         Use convertFromRootView instead of subtracting m_frameRectInWindowCoordinates.location() from the
2232         event position (which is in root view coordinates).
2233
2234 2011-11-04  Tor Arne Vestbø  <tor.arne.vestbo@nokia.com>
2235
2236         [Qt] Refactor and clean up the qmake build system
2237
2238         The qmake build system has accumulated a bit of cruft and redundancy
2239         over time. There's also a fairly tight coupling between how to build
2240         the various targets, and _what_ to build, making it harder to add new
2241         rules or sources. This patch aims to elevate these issues somewhat.
2242
2243         This is a short-list of the changes:
2244
2245           * The rules for how to build targets are now mostly contained as
2246             prf-files in Tools/qmake/mkspecs/features. Using mkspecs also
2247             allows us to do pre- and post-processing of each project file,
2248             which helps to clean up the actual project files.
2249
2250           * Derived sources are no longer generated as a separate make-step
2251             but is part of each target's project file as a subdir. Makefile
2252             rules are used to ensure that we run make on the derived sources
2253             before running qmake on the actual target makefile. This makes
2254             it easier to keep a proper dependency between derived sources
2255             and the target.
2256
2257           * We use GNU make and the compiler to generate dependencies on
2258             UNIX-based systems running Qt 5. This allows us to lessen the
2259             need to run qmake, which should reduce compile time.
2260
2261           * WebKit2 is now build by default if building with Qt 5. It can
2262             be disabled by passing --no-webkit2 to build-webkit.
2263
2264         The result of these changes are hopefully a cleaner and easier
2265         build system to modify, and faster build times due to no longer
2266         running qmake on every single build. It's also a first step
2267         towards possibly generating the list of sources using another
2268         build system.
2269
2270         https://bugs.webkit.org/show_bug.cgi?id=71222
2271
2272         Reviewed by Simon Hausmann.
2273
2274         * DerivedSources.pri: Renamed from Source/WebKit2/DerivedSources.pro.
2275         * Target.pri: Copied from Source/WebKit2/WebKit2.pro.
2276         * UIProcess/API/qt/tests/tests.pri:
2277         * UIProcess/API/qt/tests/tests.pro: Removed.
2278         * WebKit2.pri:
2279         * WebKit2.pro:
2280         * WebKit2API.pri: Removed.
2281         * WebProcess.pro:
2282
2283 2011-11-04  Kenneth Rohde Christiansen  <kenneth@webkit.org>
2284
2285         [Qt] Support programmatic scrolling with the QTouchWebView
2286
2287         Reviewed by Simon Hausmann.
2288
2289         As more code can be shared between the programmatic scrolling and the
2290         method for ensuring that the contents are within valid bounds, this
2291         patch includes a bit of refactoring as well.
2292
2293         * UIProcess/API/qt/qdesktopwebview_p.h:
2294         (QDesktopWebViewPrivate::scrollPositionRequested):
2295         * UIProcess/API/qt/qtouchwebview.cpp:
2296         (QTouchWebViewPrivate::scrollPositionRequested):
2297         * UIProcess/API/qt/qtouchwebview_p.h:
2298         * UIProcess/qt/QtTouchViewInterface.cpp:
2299         (WebKit::QtTouchViewInterface::scrollPositionRequested):
2300         * UIProcess/qt/QtTouchViewInterface.h:
2301         * UIProcess/qt/QtViewInterface.h:
2302         * UIProcess/qt/QtViewportInteractionEngine.cpp:
2303         (WebKit::QtViewportInteractionEngine::event):
2304         (WebKit::boundPosition):
2305         (WebKit::QtViewportInteractionEngine::pagePositionRequest):
2306         (WebKit::QtViewportInteractionEngine::computePosRangeForItemAtScale):
2307         (WebKit::QtViewportInteractionEngine::ensureContentWithinViewportBoundary):
2308         (WebKit::QtViewportInteractionEngine::setConstraints):
2309         (WebKit::QtViewportInteractionEngine::pinchGestureEnded):
2310         (WebKit::QtViewportInteractionEngine::contentViewportChanged):
2311         * UIProcess/qt/QtViewportInteractionEngine.h:
2312         * UIProcess/qt/QtWebPageProxy.cpp:
2313         (QtWebPageProxy::pageDidRequestScroll):
2314         * UIProcess/qt/QtWebPageProxy.h:
2315
2316 2011-11-03  Mark Hahnenberg  <mhahnenberg@apple.com>
2317
2318         De-virtualize JSObject::getPropertyNames
2319         https://bugs.webkit.org/show_bug.cgi?id=71306
2320
2321         Reviewed by Darin Adler.
2322
2323         Added getPropertyNames to the MethodTable, changed all the virtual 
2324         implementations of getPropertyNames to static ones, and replaced 
2325         all call sites with corresponding lookups in the MethodTable.
2326
2327         * WebProcess/Plugins/Netscape/NPJSObject.cpp:
2328         (WebKit::NPJSObject::enumerate):
2329
2330 2011-11-03  Anders Carlsson  <andersca@apple.com>
2331
2332         Get rid of NetscapePlugin::m_clipRectInWindowCoordinates
2333         https://bugs.webkit.org/show_bug.cgi?id=71521
2334
2335         Reviewed by Dan Bernstein.
2336
2337         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
2338         (WebKit::NetscapePlugin::geometryDidChange):
2339         * WebProcess/Plugins/Netscape/NetscapePlugin.h:
2340
2341 2011-11-03  Anders Carlsson  <andersca@apple.com>
2342
2343         Use convertToRootView(IntPoint()) instead of m_frameRectInWindowCoordinates.location() where possible
2344         https://bugs.webkit.org/show_bug.cgi?id=71520
2345
2346         Reviewed by Dan Bernstein.
2347
2348         * WebProcess/Plugins/Netscape/win/NetscapePluginWin.cpp:
2349         (WebKit::NetscapePlugin::scheduleWindowedGeometryUpdate):
2350         (WebKit::NetscapePlugin::platformPaint):
2351         * WebProcess/Plugins/Netscape/x11/NetscapePluginX11.cpp:
2352         (WebKit::NetscapePlugin::platformHandleMouseEvent):
2353         (WebKit::NetscapePlugin::platformHandleWheelEvent):
2354         (WebKit::NetscapePlugin::platformHandleMouseEnterEvent):
2355         (WebKit::NetscapePlugin::platformHandleMouseLeaveEvent):
2356
2357 2011-11-03  Anders Carlsson  <andersca@apple.com>
2358
2359         Add NetscapePlugin::convertToRootView
2360         https://bugs.webkit.org/show_bug.cgi?id=71519
2361
2362         Reviewed by Darin Adler.
2363
2364         Yet another step towards eliminating uses of m_frameRectInWindowCoordinates.
2365
2366         Also, use the "root view" terminology, since that's really what we mean here.
2367
2368         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
2369         (WebKit::NetscapePlugin::callSetWindow):
2370         Use convertToRootView to get the plug-in location and clip rect in root view coordinates.
2371
2372         (WebKit::NetscapePlugin::convertToRootView):
2373         Apply the m_pluginToRootViewTransform.mapPoint transform.
2374
2375         * WebProcess/Plugins/Netscape/NetscapePlugin.h:
2376         Add convertToRootView.
2377
2378 2011-11-03  Anders Carlsson  <andersca@apple.com>
2379
2380         Move plug-in size and backing store checks to PluginProxy::updateBackingStore
2381         https://bugs.webkit.org/show_bug.cgi?id=71508
2382
2383         Reviewed by Darin Adler.
2384
2385         * WebProcess/Plugins/PluginProxy.cpp:
2386         (WebKit::PluginProxy::geometryDidChange):
2387         Remove code to send back an empty backing store if the plug-in size is empty
2388         or doesn't need a backing store. This check is now done...
2389
2390         (WebKit::PluginProxy::updateBackingStore):
2391         ...here.
2392
2393 2011-11-03  Anders Carlsson  <andersca@apple.com>
2394
2395         Get rid of PluginControllerProxy::m_frameRectInWindowCoordinates
2396         https://bugs.webkit.org/show_bug.cgi?id=71506
2397
2398         Reviewed by Darin Adler.
2399
2400         * PluginProcess/PluginControllerProxy.cpp:
2401         (WebKit::PluginControllerProxy::geometryDidChange):
2402         This no longer needs to take the frame rect in window coordinates.
2403
2404         * PluginProcess/PluginControllerProxy.h:
2405         * PluginProcess/PluginControllerProxy.messages.in:
2406         Remove frameRectInWindowCoordinates from the GeometryDidChange message.
2407
2408         * WebProcess/Plugins/PluginProxy.cpp:
2409         (WebKit::PluginProxy::geometryDidChange):
2410         Don't pass frameRectInWindowCoordinates when sending GeometryDidChange.
2411
2412 2011-11-03  Anders Carlsson  <andersca@apple.com>
2413
2414         Get rid of Plugin::wantsWindowRelativeCoordinates()
2415         https://bugs.webkit.org/show_bug.cgi?id=71504
2416
2417         Reviewed by Darin Adler.
2418
2419         Since all Plugin subclasses now return false for wantsWindowRelativeCoordinates,
2420         we can go ahead and remove it.
2421
2422         * PluginProcess/PluginControllerProxy.cpp:
2423         (WebKit::PluginControllerProxy::paint):
2424         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
2425         (WebKit::NetscapePlugin::snapshot):
2426         * WebProcess/Plugins/Netscape/NetscapePlugin.h:
2427         * WebProcess/Plugins/PDF/BuiltInPDFView.cpp:
2428         * WebProcess/Plugins/PDF/BuiltInPDFView.h:
2429         * WebProcess/Plugins/Plugin.h:
2430         * WebProcess/Plugins/PluginProxy.cpp:
2431         * WebProcess/Plugins/PluginProxy.h:
2432         * WebProcess/Plugins/PluginView.cpp:
2433         (WebKit::PluginView::paint):
2434
2435 2011-11-03  Anders Carlsson  <andersca@apple.com>
2436
2437         NetscapePlugin::wantsWindowRelativeCoordinates should return false for all ports
2438         https://bugs.webkit.org/show_bug.cgi?id=71501
2439
2440         Reviewed by Darin Adler.
2441
2442         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
2443         (WebKit::NetscapePlugin::wantsWindowRelativeCoordinates):
2444         Return false.
2445
2446         * WebProcess/Plugins/Netscape/x11/NetscapePluginX11.cpp:
2447         (WebKit::NetscapePlugin::platformGeometryDidChange):
2448         Use m_pluginSize instead of m_frameRectInWindowCoordinates.size().
2449
2450         (WebKit::NetscapePlugin::platformPaint):
2451         No need to translate back and forth between window and plug-in relative coordinates anymore.
2452
2453 2011-11-03  Darin Adler  <darin@apple.com>
2454
2455         Change remaining callers of releaseRef to call leakRef
2456         https://bugs.webkit.org/show_bug.cgi?id=71422
2457
2458         Reviewed by Darin Fisher.
2459
2460         * Platform/mac/ModuleMac.mm:
2461         (WebKit::Module::load):
2462         * Shared/API/c/WKArray.cpp:
2463         (WKArrayCreate):
2464         * Shared/API/c/WKData.cpp:
2465         (WKDataCreate):
2466         * Shared/API/c/WKDictionary.cpp:
2467         (WKDictionaryCopyKeys):
2468         * Shared/API/c/WKGeometry.cpp:
2469         (WKPointCreate):
2470         (WKSizeCreate):
2471         (WKRectCreate):
2472         * Shared/API/c/WKMutableArray.cpp:
2473         (WKMutableArrayCreate):
2474         * Shared/API/c/WKMutableDictionary.cpp:
2475         (WKMutableDictionaryCreate):
2476         * Shared/API/c/WKNumber.cpp:
2477         (WKBooleanCreate):
2478         (WKDoubleCreate):
2479         (WKUInt64Create):
2480         * Shared/API/c/WKSharedAPICast.h:
2481         (WebKit::toCopiedAPI):
2482         (WebKit::toCopiedURLAPI):
2483         * Shared/API/c/cf/WKErrorCF.cpp:
2484         (WKErrorCreateWithCFError):
2485         * Shared/API/c/cf/WKURLRequestCF.cpp:
2486         (WKURLRequestCreateWithCFURLRequest):
2487         * Shared/API/c/cf/WKURLResponseCF.cpp:
2488         (WKURLResponseCreateWithCFURLResponse):
2489         * Shared/API/c/mac/WKURLRequestNS.mm:
2490         (WKURLRequestCreateWithNSURLRequest):
2491         * Shared/API/c/mac/WKURLResponseNS.mm:
2492         (WKURLResponseCreateWithNSURLResponse):
2493         * Shared/cf/ArgumentCodersCF.cpp:
2494         (CoreIPC::decode):
2495         * UIProcess/API/C/WKBackForwardList.cpp:
2496         (WKBackForwardListCopyBackListWithLimit):
2497         (WKBackForwardListCopyForwardListWithLimit):
2498         * UIProcess/API/C/WKContext.cpp:
2499         (WKContextCreate):
2500         (WKContextCreateWithInjectedBundlePath):
2501         * UIProcess/API/C/WKCredential.cpp:
2502         (WKCredentialCreate):
2503         (WKCredentialCreateWithCertificateInfo):
2504         * UIProcess/API/C/WKDatabaseManager.cpp:
2505         (WKDatabaseManagerGetOriginKey):
2506         (WKDatabaseManagerGetOriginQuotaKey):
2507         (WKDatabaseManagerGetOriginUsageKey):
2508         (WKDatabaseManagerGetDatabaseDetailsKey):
2509         (WKDatabaseManagerGetDatabaseDetailsNameKey):
2510         (WKDatabaseManagerGetDatabaseDetailsDisplayNameKey):
2511         (WKDatabaseManagerGetDatabaseDetailsExpectedUsageKey):
2512         (WKDatabaseManagerGetDatabaseDetailsCurrentUsageKey):
2513         * UIProcess/API/C/WKFrame.cpp:
2514         (WKFrameCopyChildFrames):
2515         * UIProcess/API/C/WKGeolocationPosition.cpp:
2516         (WKGeolocationPositionCreate):
2517         * UIProcess/API/C/WKGrammarDetail.cpp:
2518         (WKGrammarDetailCreate):
2519         * UIProcess/API/C/WKPage.cpp:
2520         (WKPageGetSessionHistoryURLValueType):
2521         (WKPageCopySessionState):
2522         * UIProcess/API/C/WKPreferences.cpp:
2523         (WKPreferencesCreateWithIdentifier):
2524         * UIProcess/API/C/win/WKView.cpp:
2525         (WKViewCreate):
2526         * UIProcess/win/WebUndoClient.cpp:
2527         (WebKit::WebUndoClient::registerEditCommand):
2528         * WebProcess/InjectedBundle/API/c/WKBundleFrame.cpp:
2529         (WKBundleFrameCopyChildFrames):
2530         * WebProcess/InjectedBundle/API/c/WKBundleNodeHandle.cpp:
2531         (WKBundleNodeHandleCreate):
2532         (WKBundleNodeHandleCopyDocument):
2533         (WKBundleNodeHandleCopyHTMLTableCellElementCellAbove):
2534         (WKBundleNodeHandleCopyDocumentFrame):
2535         (WKBundleNodeHandleCopyHTMLFrameElementContentFrame):
2536         (WKBundleNodeHandleCopyHTMLIFrameElementContentFrame):
2537         * WebProcess/InjectedBundle/API/c/WKBundlePage.cpp:
2538         (WKBundlePageCopyTrackedRepaintRects):
2539         * WebProcess/InjectedBundle/API/c/WKBundleScriptWorld.cpp:
2540         (WKBundleScriptWorldCreateWorld):
2541         Use leakRef.
2542
2543 2011-11-02  Darin Adler  <darin@apple.com>
2544
2545         Change remaining callers of releaseRef to call leakRef
2546         https://bugs.webkit.org/show_bug.cgi?id=71422
2547
2548         Reviewed by Darin Fisher.
2549
2550         * Platform/mac/ModuleMac.mm:
2551         (WebKit::Module::load): Use leakRef.
2552         (WebKit::Module::unload): Use leakRef, and cast to void
2553         to avoid unused return value warning.
2554
2555         * Shared/API/c/WKArray.cpp:
2556         (WKArrayCreate):
2557         * Shared/API/c/WKData.cpp:
2558         (WKDataCreate):
2559         * Shared/API/c/WKDictionary.cpp:
2560         (WKDictionaryCopyKeys):
2561         * Shared/API/c/WKGeometry.cpp:
2562         (WKPointCreate):
2563         (WKSizeCreate):
2564         (WKRectCreate):
2565         * Shared/API/c/WKMutableArray.cpp:
2566         (WKMutableArrayCreate):
2567         * Shared/API/c/WKMutableDictionary.cpp:
2568         (WKMutableDictionaryCreate):
2569         * Shared/API/c/WKNumber.cpp:
2570         (WKBooleanCreate):
2571         (WKDoubleCreate):
2572         (WKUInt64Create):
2573         * Shared/API/c/WKSharedAPICast.h:
2574         (WebKit::toCopiedAPI):
2575         (WebKit::toCopiedURLAPI):
2576         * Shared/API/c/cf/WKErrorCF.cpp:
2577         (WKErrorCreateWithCFError):
2578         * Shared/API/c/cf/WKURLRequestCF.cpp:
2579         (WKURLRequestCreateWithCFURLRequest):
2580         * Shared/API/c/cf/WKURLResponseCF.cpp:
2581         (WKURLResponseCreateWithCFURLResponse):
2582         * Shared/API/c/mac/WKURLRequestNS.mm:
2583         (WKURLRequestCreateWithNSURLRequest):
2584         * Shared/API/c/mac/WKURLResponseNS.mm:
2585         (WKURLResponseCreateWithNSURLResponse):
2586         * Shared/cf/ArgumentCodersCF.cpp:
2587         (CoreIPC::decode):
2588         * UIProcess/API/C/WKBackForwardList.cpp:
2589         (WKBackForwardListCopyBackListWithLimit):
2590         (WKBackForwardListCopyForwardListWithLimit):
2591         * UIProcess/API/C/WKContext.cpp:
2592         (WKContextCreate):
2593         (WKContextCreateWithInjectedBundlePath):
2594         * UIProcess/API/C/WKCredential.cpp:
2595         (WKCredentialCreate):
2596         (WKCredentialCreateWithCertificateInfo):
2597         * UIProcess/API/C/WKDatabaseManager.cpp:
2598         (WKDatabaseManagerGetOriginKey):
2599         (WKDatabaseManagerGetOriginQuotaKey):
2600         (WKDatabaseManagerGetOriginUsageKey):
2601         (WKDatabaseManagerGetDatabaseDetailsKey):
2602         (WKDatabaseManagerGetDatabaseDetailsNameKey):
2603         (WKDatabaseManagerGetDatabaseDetailsDisplayNameKey):
2604         (WKDatabaseManagerGetDatabaseDetailsExpectedUsageKey):
2605         (WKDatabaseManagerGetDatabaseDetailsCurrentUsageKey):
2606         * UIProcess/API/C/WKFrame.cpp:
2607         (WKFrameCopyChildFrames):
2608         * UIProcess/API/C/WKGeolocationPosition.cpp:
2609         (WKGeolocationPositionCreate):
2610         * UIProcess/API/C/WKGrammarDetail.cpp:
2611         (WKGrammarDetailCreate):
2612         * UIProcess/API/C/WKPage.cpp:
2613         (WKPageGetSessionHistoryURLValueType):
2614         (WKPageCopySessionState):
2615         * UIProcess/API/C/WKPreferences.cpp:
2616         (WKPreferencesCreateWithIdentifier):
2617         * UIProcess/API/C/win/WKView.cpp:
2618         (WKViewCreate):
2619         * UIProcess/win/WebUndoClient.cpp:
2620         (WebKit::WebUndoClient::registerEditCommand):
2621         * WebProcess/InjectedBundle/API/c/WKBundleFrame.cpp:
2622         (WKBundleFrameCopyChildFrames):
2623         * WebProcess/InjectedBundle/API/c/WKBundleNodeHandle.cpp:
2624         (WKBundleNodeHandleCreate):
2625         (WKBundleNodeHandleCopyDocument):
2626         (WKBundleNodeHandleCopyHTMLTableCellElementCellAbove):
2627         (WKBundleNodeHandleCopyDocumentFrame):
2628         (WKBundleNodeHandleCopyHTMLFrameElementContentFrame):
2629         (WKBundleNodeHandleCopyHTMLIFrameElementContentFrame):
2630         * WebProcess/InjectedBundle/API/c/WKBundlePage.cpp:
2631         (WKBundlePageCopyTrackedRepaintRects):
2632         * WebProcess/InjectedBundle/API/c/WKBundleScriptWorld.cpp:
2633         (WKBundleScriptWorldCreateWorld):
2634         Use leakRef.
2635
2636 2011-11-03  Anders Carlsson  <andersca@apple.com>
2637
2638         NetscapePlugin should use plug-in relative coordinates on Mac
2639         https://bugs.webkit.org/show_bug.cgi?id=71486
2640
2641         Reviewed by Adam Roben.
2642
2643         * PluginProcess/PluginControllerProxy.cpp:
2644         (WebKit::PluginControllerProxy::paint):
2645         Don't translate the graphics context when the plug-in doesn't want window relative coordinates.
2646         This also fixed a bug I introduced in my previous commit where we'd always pass the dirty rect in
2647         plug-in coordinates even if the plug-in wants window relative coordinates.
2648
2649         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
2650         (WebKit::NetscapePlugin::snapshot):
2651         Don't do the whole translate dance if the plug-in doesn't want window relative coordinates.
2652
2653         (WebKit::NetscapePlugin::wantsWindowRelativeCoordinates):
2654         Return false for PLATFORM_ARCHITECTURE(MAC).
2655
2656         * WebProcess/Plugins/Netscape/mac/NetscapePluginMac.mm:
2657         (WebKit::NetscapePlugin::platformPaint):
2658         Simplify code now that we know that the we're always given plug-in relative coordinates.
2659
2660 2011-11-03  Anders Carlsson  <andersca@apple.com>
2661
2662         PluginControllerProxy's dirty rect should be in plug-in coordinates
2663         https://bugs.webkit.org/show_bug.cgi?id=71481
2664
2665         Reviewed by Sam Weinig.
2666
2667         * PluginProcess/PluginControllerProxy.cpp:
2668         (WebKit::PluginControllerProxy::paint):
2669         Convert the dirty rect to window coordinates before passing it to the plug-in.
2670
2671         (WebKit::PluginControllerProxy::invalidate):
2672         No need to convert the dirty rect to window coordinates.
2673
2674         (WebKit::PluginControllerProxy::paintEntirePlugin):
2675         Use m_pluginSize instead of m_frameRectInWindowCoordinates.isEmpty.
2676
2677 2011-11-03  Anders Carlsson  <andersca@apple.com>
2678
2679         Use the right function to determine whether NPWindow coordinates should be window relative
2680         https://bugs.webkit.org/show_bug.cgi?id=71480
2681
2682         Reviewed by Adam Roben.
2683
2684         We want to use wantsWindowRelativeNPWindowCoordinates here, and not wantsWindowRelativeCoordinates
2685         which is a temporary function that will be removed (and that returns the wrong value!)
2686
2687         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
2688         (WebKit::NetscapePlugin::geometryDidChange):
2689
2690 2011-11-03  Simon Hausmann  <simon.hausmann@nokia.com>
2691
2692         Unreviewed build fix after r99195.
2693
2694         The right name is restrictMinimumScaleFactorToViewportSize.
2695
2696         * UIProcess/API/qt/qtouchwebview.cpp:
2697         (QTouchWebViewPrivate::updateViewportConstraints):
2698
2699 2011-11-03  Carlos Garcia Campos  <cgarcia@igalia.com>
2700
2701         [GTK] Use WEBKIT_API instead of WK_EXPORT in WebKitEnumTypes.h
2702         https://bugs.webkit.org/show_bug.cgi?id=71457
2703
2704         Reviewed by Martin Robinson.
2705
2706         * GNUmakefile.am:
2707
2708 2011-11-03  Kenneth Rohde Christiansen  <kenneth@webkit.org>
2709
2710         [Qt] Bounce back limits are wrong in some situations
2711         https://bugs.webkit.org/show_bug.cgi?id=71471
2712
2713         Reviewed by Simon Hausmann.
2714
2715         The valid position points were in viewport coordinates, but we were
2716         requiring valid position points in content coordinates.
2717
2718         * UIProcess/qt/QtViewportInteractionEngine.cpp:
2719         (WebKit::QtViewportInteractionEngine::animateContentIntoBoundariesIfNeeded):
2720
2721 2011-11-03  Fady Samuel  <fsamuel@chromium.org>
2722
2723         Removing line in computeViewportAttributes that enforces a minimum scale factor to never allow zooming out more than viewport
2724         https://bugs.webkit.org/show_bug.cgi?id=70609
2725
2726         Reviewed by Kenneth Rohde Christiansen.
2727
2728         * UIProcess/API/qt/qtouchwebview.cpp:
2729         (QTouchWebViewPrivate::updateViewportConstraints):
2730         * WebProcess/WebPage/WebPage.cpp:
2731         (WebKit::WebPage::viewportConfigurationAsText):
2732
2733 2011-11-03  Andras Becsi  <andras.becsi@nokia.com>
2734
2735         [Qt][WK2] Fix the signal signature of the loadFailed API test.
2736
2737         Rubber-stamped by Simon Hausmann.
2738
2739         * UIProcess/API/qt/tests/commonviewtests/webviewabstraction.cpp:
2740         (WebViewAbstraction::touchViewLoadFailed):
2741         (WebViewAbstraction::desktopViewLoadFailed):
2742
2743 2011-11-03  Jocelyn Turcotte  <jocelyn.turcotte@nokia.com>
2744
2745         [Qt] Fix an assertion under WebPage::setViewportSize.
2746         https://bugs.webkit.org/show_bug.cgi?id=71473
2747
2748         Reviewed by Simon Hausmann.
2749
2750         The web view can have an empty size and it causes the assert in computeViewportAttributes.
2751         Don't notify the web page of such a size change in this case.
2752
2753         * UIProcess/API/qt/qtouchwebview.cpp:
2754         (QTouchWebViewPrivate::updateViewportSize):
2755
2756 2011-11-03  Jesus Sanchez-Palencia  <jesus.palencia@openbossa.org>
2757
2758         [WK2] State variable name refactor in WebPageProxy.cpp
2759         https://bugs.webkit.org/show_bug.cgi?id=71467
2760
2761         Reviewed by Andreas Kling.
2762
2763         Renaming m_inDecidePolicyForMIMEType to m_inDecidePolicyForResponse after
2764         https://bugs.webkit.org/show_bug.cgi?id=55827 .
2765
2766         * UIProcess/WebPageProxy.cpp:
2767         (WebKit::WebPageProxy::WebPageProxy):
2768         (WebKit::WebPageProxy::receivedPolicyDecision):
2769         (WebKit::WebPageProxy::decidePolicyForResponse):
2770         * UIProcess/WebPageProxy.h:
2771
2772 2011-11-03  Nayan Kumar K  <nayankk@motorola.com>
2773
2774         [GTK][WEBKIT2] Add support for title property in WebKitWebView.
2775         https://bugs.webkit.org/show_bug.cgi?id=68074
2776
2777         Reviewed by Philippe Normand.
2778
2779         Support for 'title' property is added in WebKitWebView.
2780         Functions to get the value of this property is provided.
2781
2782         * UIProcess/API/gtk/WebKitWebLoaderClient.cpp:
2783         (didReceiveTitleForFrame): LoaderClient titleRecieve callback.
2784         (webkitWebLoaderClientAttachLoaderClientToPage): Register didReceiveTitleForFrame callback.
2785         * UIProcess/API/gtk/WebKitWebView.cpp:
2786         (webkitWebViewGetProperty): 'title' property get function.
2787         (webkit_web_view_class_init): Register new property.
2788         (webkitWebViewSetTitle): Notify WebKitWebView about title receive.
2789         (webkit_web_view_get_title): API to get main frame title.
2790         * UIProcess/API/gtk/WebKitWebView.h: webkit_web_view_get_title API expose.
2791         * UIProcess/API/gtk/WebKitWebViewPrivate.h: Added private API.
2792         * UIProcess/API/gtk/tests/TestWebKitWebLoaderClient.cpp:
2793         (testWebViewTitle): Test webkit_web_view_get_title API.
2794         (beforeAll): Add testWebViewTitle test.
2795
2796 2011-11-03  Jesus Sanchez-Palencia  <jesus.palencia@openbossa.org>
2797
2798         [Qt][WK2] Download support and API in UIProcess
2799         https://bugs.webkit.org/show_bug.cgi?id=68962
2800
2801         Reviewed by Simon Hausmann.
2802
2803         We implement our WkContextDownloadClient and the needed callbacks.
2804         We also add APIs by exposing QWebDownloadItem. Objects from this type
2805         have their ownership handled by QDesktopWebView and will be created or
2806         destroyed as needed. Classes implementing ViewInterface (QDesktopWebViewPrivate
2807         and TouchViewInterface) will receive a signal (downloadRequested) with a pointer
2808         to the recently created QWebDownloadItem. With that they can connect the proper
2809         signals and slots, set the download destination path and then call start().
2810         Objects of this type will provide the progress of a download, a slot to cancel it,
2811         and signals for getting finished or failure status.
2812         QWebDownloadItem was also exposed in QML.
2813         Qt needed an asynchronous way for UIProcess to return a destination path to WebProcess,
2814         therefore the startTransfer API was added to WebKit2's Download handlers.
2815
2816         * Shared/qt/WebCoreArgumentCodersQt.cpp:
2817         (CoreIPC::::encode):
2818         (CoreIPC::::decode):
2819         Add encoding and decoding of suggestedFilename for ResourceResponse.
2820
2821         * UIProcess/API/qt/WKView.h:
2822         * UIProcess/API/qt/qbasewebview.h: Add signal downloadRequested.
2823         * UIProcess/API/qt/qdesktopwebview.cpp:
2824         (QDesktopWebViewPrivate::downloadRequested):
2825         * UIProcess/API/qt/qdesktopwebview_p.h:
2826
2827         * UIProcess/API/qt/qwebdownloaditem.cpp: Added.
2828         (QWebDownloadItemPrivate::QWebDownloadItemPrivate):
2829         (QWebDownloadItem::QWebDownloadItem):
2830         (QWebDownloadItem::~QWebDownloadItem):
2831         (QWebDownloadItem::url):
2832         (QWebDownloadItem::destinationPath):
2833         (QWebDownloadItem::setDestinationPath):
2834         (QWebDownloadItem::suggestedFilename):
2835         (QWebDownloadItem::mimeType):
2836         (QWebDownloadItem::expectedContentLength):
2837         (QWebDownloadItem::totalBytesReceived):
2838         (QWebDownloadItem::cancel):
2839         (QWebDownloadItem::start):
2840         * UIProcess/API/qt/qwebdownloaditem.h: Added.
2841         * UIProcess/API/qt/qwebdownloaditem_p.h: Added.
2842         (QWebDownloadItemPrivate::didReceiveResponse):
2843
2844         * UIProcess/API/qt/tests/qmltests/DesktopWebView/tst_download.qml: Added.
2845         * UIProcess/API/qt/tests/qmltests/common/download.html: Added.
2846         * UIProcess/API/qt/tests/qmltests/common/download.zip: Added.
2847         * UIProcess/API/qt/tests/qmltests/qmltests.pro:
2848
2849         * UIProcess/Downloads/DownloadProxy.cpp:
2850         (WebKit::DownloadProxy::startTransfer): Qt only function added.
2851         * UIProcess/Downloads/DownloadProxy.h:
2852
2853         * UIProcess/PageClient.h: Added Qt specific function to call handleDownloadRequest from QtWebPageProxy.
2854
2855         * UIProcess/WebContext.cpp:
2856         (WebKit::WebContext::download):
2857         Using WebPageProxy::handleDownloadRequest to bootstrap a download through PageClient.
2858
2859         * UIProcess/WebPageProxy.cpp:
2860         (WebKit::WebPageProxy::receivedPolicyDecision):
2861         Using handleDownloadRequest() to bootstrap a download through PageClient.
2862         (WebKit::WebPageProxy::handleDownloadRequest): Calls PageClient::handleDownloadRequest().
2863         * UIProcess/WebPageProxy.h:
2864
2865         * UIProcess/qt/QtDownloadManager.cpp: Added.
2866         (WebKit::toQtDownloadManager):
2867         (WebKit::qt_wk_didReceiveResponse):
2868         (WebKit::qt_wk_didCreateDestination):
2869         (WebKit::qt_wk_didFinishDownload):
2870         (WebKit::qt_wk_didFailDownload):
2871         (WebKit::qt_wk_didReceiveDataForDownload):
2872         (QtDownloadManager::downloadReceivedResponse): Will reach QtWebPageProxy::didReceiveDownloadResponse.
2873         (QtDownloadManager::downloadCreatedDestination):
2874         (QtDownloadManager::downloadFinished):
2875         (QtDownloadManager::downloadFailed):
2876         (QtDownloadManager::downloadDataReceived):
2877         * UIProcess/qt/QtDownloadManager.h: Added.
2878         Bootstrap our WKContextDownloadClient and set its callbacks.
2879         This entity will also handle all downloads and keep a map of them.
2880         It will be kept alive together with the WebContext as a static member
2881         of QtWebPageProxy, so we can keep it across several WebPages and, therefore,
2882         WebViews.
2883
2884         * UIProcess/qt/QtWebPageProxy.cpp:
2885         (QtWebPageProxy::defaultWKContext):
2886         (QtWebPageProxy::~QtWebPageProxy):
2887         (QtWebPageProxy::handleDownloadRequest):
2888         (QtWebPageProxy::didReceiveDownloadResponse):
2889         * UIProcess/qt/QtWebPageProxy.h:
2890         From now on it will keep a static QtDownloadManager to live together
2891         with the default WebContext. It implements PageClient::handleDownloadRequest.
2892         QtWebPageProxy::didReceiveDownloadResponse will emit the view's signal downloadRequested.
2893
2894        * UIProcess/qt/QtTouchViewInterface.h:
2895         (WebKit::QtTouchViewInterface::downloadRequested):
2896         * UIProcess/qt/QtViewInterface.h:
2897
2898         * UIProcess/qt/qweberror.cpp:
2899         (QWebError::description):
2900         * UIProcess/qt/qweberror.h:
2901         (QWebError::errorCodeAsDownloadError):
2902         Add Download error handling to QWebError and a new API
2903         to retrieve the error description from the original ResourceError.
2904         Also, it now has QWebDownloadItem::DownloadError errorCodeAsDownloadError()
2905         that returns the error code as a DownloadError.
2906
2907         * WebKit2.pro:
2908         * WebKit2API.pri:
2909
2910         * WebProcess/Downloads/Download.h:
2911         * WebProcess/Downloads/DownloadManager.cpp:
2912         (WebKit::DownloadManager::startTransfer):
2913         * WebProcess/Downloads/DownloadManager.h:
2914         Adding Qt specific startTransfer function.
2915
2916         * WebProcess/Downloads/qt/DownloadQt.cpp:
2917         (WebKit::Download::start):
2918         (WebKit::Download::startWithHandle):
2919         (WebKit::Download::didDecideDestination):
2920         (WebKit::Download::startTransfer):
2921         * WebProcess/Downloads/qt/QtFileDownloader.cpp:
2922         (WebKit::QtFileDownloader::init): start() was renamed to init().
2923         (WebKit::QtFileDownloader::determineFilename):
2924         Calling onReadyRead() here was unnecessary and it was triggering the overall
2925         download process even before DownloadManager finished startDownload(). This
2926         was leading to a DownloadManager with an empty list of downloads.
2927         (WebKit::QtFileDownloader::startTransfer): decidedDestination() became startTransfer().
2928         (WebKit::QtFileDownloader::abortDownloadWritingAndEmitError):
2929         (WebKit::QtFileDownloader::handleDownloadResponse):
2930         (WebKit::QtFileDownloader::onReadyRead):
2931         (WebKit::QtFileDownloader::onFinished):
2932         (WebKit::QtFileDownloader::cancel):
2933         * WebProcess/Downloads/qt/QtFileDownloader.h:
2934
2935         * WebProcess/WebProcess.cpp:
2936         (WebKit::WebProcess::startTransfer):
2937         * WebProcess/WebProcess.h:
2938         * WebProcess/WebProcess.messages.in:
2939         Adding Qt specific message StartTransfer and handling function.
2940
2941 2011-11-03  Nayan Kumar K  <nayankk@motorola.com>
2942
2943         Add webkit_web_view_load_html and webkit_web_view_load_plain_text APIs.
2944         https://bugs.webkit.org/show_bug.cgi?id=69249
2945
2946         Reviewed by Philippe Normand.
2947
2948         This patch adds support for 2 more load APIs, namely
2949         webkit_web_view_load_html and webkit_web_view_load_plain_text.
2950
2951         * UIProcess/API/gtk/WebKitWebView.cpp:
2952         (webkit_web_view_load_html): New API to load html string.
2953         (webkit_web_view_load_plain_text): New API to load plain text.
2954         * UIProcess/API/gtk/WebKitWebView.h: Public API addition.
2955         * UIProcess/API/gtk/tests/TestWebKitWebLoaderClient.cpp:
2956         (testLoadHtml): Test webkit_web_view_load_html API.
2957         (testLoadPlainText): Test webkit_web_view_load_plain_text API.
2958         (beforeAll): Add new tests.
2959         * UIProcess/API/gtk/tests/WebViewTest.cpp:
2960         (WebViewTest::loadHtml): Test webkit_web_view_load_html API.
2961         (WebViewTest::loadPlainText): Test webkit_web_view_load_plain_text API.
2962         * UIProcess/API/gtk/tests/WebViewTest.h:
2963
2964 2011-11-03  Simon Hausmann  <simon.hausmann@nokia.com>
2965
2966         [Qt][WK2] Failing assertion with desktop webview when touch mocking in MinBrowser
2967         https://bugs.webkit.org/show_bug.cgi?id=71452
2968
2969         Reviewed by Andreas Kling.
2970
2971         Don't re-implement touchEvent(), we don't intend to support touch events as we
2972         receive them from the QQuickCanvas at this point.
2973
2974         * UIProcess/API/qt/qdesktopwebview.cpp:
2975         * UIProcess/API/qt/qdesktopwebview.h:
2976
2977 2011-11-03  Simon Hausmann  <simon.hausmann@nokia.com>
2978
2979         [Qt] [WK2] MiniBrowser assert in QtWebProccess on startup in debug build.
2980         https://bugs.webkit.org/show_bug.cgi?id=71196
2981
2982         Reviewed by Kenneth Rohde Christiansen.
2983
2984         Ensure AC is turned off for the desktop view before we launch the process.
2985         This avoids "accidential" enterAc/exitAc calls that cause failing assertions
2986         because we don't really support AC in this setup.
2987
2988         The touch side works the same way, i.e. enable the preference before calling
2989         init().
2990
2991         * UIProcess/qt/QtDesktopWebPageProxy.cpp:
2992         (QtDesktopWebPageProxy::QtDesktopWebPageProxy):
2993
2994 2011-11-03  Balazs Kelemen  <kbalazs@webkit.org>
2995
2996         [Qt] X11 plugins need to be reworked for Qt5
2997         https://bugs.webkit.org/show_bug.cgi?id=70023
2998
2999         Reviewed by Simon Hausmann.
3000
3001         Disable X11 plugins.
3002         * config.h:
3003
3004 2011-11-03  Simon Hausmann  <simon.hausmann@nokia.com>
3005
3006         Unreviewed Qt build fix(es).
3007
3008         * UIProcess/qt/QtDesktopWebPageProxy.cpp:
3009         (QtDesktopWebPageProxy::handleDragMoveEvent): Adapt to dragSession API change.
3010         (QtDesktopWebPageProxy::handleDropEvent): Ditto.
3011         * WebProcess/Plugins/Netscape/NetscapePluginNone.cpp:
3012         (WebKit::NetscapePlugin::wantsWindowRelativeNPWindowCoordinates): Implement here
3013         also, for plugin-disabled builds.
3014
3015 2011-11-03  ChangSeok Oh  <shivamidow@gmail.com>
3016
3017         [GTK] Fix build-break on r99143
3018         https://bugs.webkit.org/show_bug.cgi?id=71440
3019
3020         Reviewed by Philippe Normand.
3021
3022         dragOperation() should be replaced with dragSession().operation since it was removed.
3023         And didDetectXSSForFrame of WKPageLoaderClient should be relocated.
3024
3025         * UIProcess/API/gtk/WebKitWebLoaderClient.cpp:
3026         (webkitWebLoaderClientAttachLoaderClientToPage):
3027         * UIProcess/API/gtk/WebKitWebViewBase.cpp:
3028         (webkitWebViewBaseDragDataReceived):
3029         (webkitWebViewBaseDragMotion):
3030
3031 2011-11-03  Mahesh Kulkarni  <mahesh.kulkarni@nokia.com>
3032
3033         [Qt] Flagging usage of X11 headers under PLAT_ARCH(X11)
3034         https://bugs.webkit.org/show_bug.cgi?id=71409
3035
3036         Reviewed by Simon Hausmann.
3037
3038         Build fix for building qtwebkit with latest qt5 which has removed Qt X11 headers.
3039
3040         * WebProcess/Plugins/Netscape/NetscapeBrowserFuncs.cpp:
3041
3042 2011-11-03  Philippe Normand  <pnormand@igalia.com>
3043
3044         Unreviewed, GTK build fix after r99093...
3045
3046         * PluginProcess/PluginControllerProxy.h:
3047
3048 2011-11-02  Viatcheslav Ostapenko  <ostapenko.viatcheslav@nokia.com>
3049
3050         [Qt] [WK] Debug build broken
3051         https://bugs.webkit.org/show_bug.cgi?id=71417
3052
3053         Add WKNumber.h for WKBooleanGetTypeID
3054         Replace WKGetTypeId with WKGetTypeID
3055         Add initialization for didDetectXSSForFrame member in WKBundlePageLoaderClient
3056         instance.
3057
3058         Reviewed by Noam Rosenthal.
3059
3060         * WebProcess/qt/QtBuiltinBundle.cpp:
3061         (WebKit::QtBuiltinBundle::handleSetNavigatorQtObjectEnabled):
3062         * WebProcess/qt/QtBuiltinBundlePage.cpp:
3063         (WebKit::QtBuiltinBundlePage::QtBuiltinBundlePage):
3064
3065 2011-11-02  Mark Hahnenberg  <mhahnenberg@apple.com>
3066
3067         De-virtualize JSObject::getOwnPropertyNames
3068         https://bugs.webkit.org/show_bug.cgi?id=71307
3069
3070         Reviewed by Darin Adler.
3071
3072         Added getOwnPropertyNames to the MethodTable, changed all the virtual 
3073         implementations of getOwnPropertyNames to static ones, and replaced 
3074         all call sites with corresponding lookups in the MethodTable.
3075
3076         * WebProcess/Plugins/Netscape/JSNPObject.cpp:
3077         (WebKit::JSNPObject::getOwnPropertyNames):
3078         * WebProcess/Plugins/Netscape/JSNPObject.h:
3079
3080 2011-11-02  Anders Carlsson  <andersca@apple.com>
3081
3082         Don't call NPP_SetWindow if the plug-in size or clip rect hasn't changed if the plug-in isn't using window relative coordinates
3083         https://bugs.webkit.org/show_bug.cgi?id=71418
3084
3085         Reviewed by Adam Roben.
3086
3087         This avoids calling into the plug-in when only the plug-in position relative to the window changes.
3088     
3089         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
3090         (WebKit::NetscapePlugin::geometryDidChange):
3091
3092 2011-11-02  Jon Lee  <jonlee@apple.com>
3093
3094         Fix syntax error.
3095
3096         * WebProcess/WebPage/WebPage.cpp:
3097         (WebKit::WebPage::performDragControllerAction):
3098
3099 2011-11-02  Jon Lee  <jonlee@apple.com>
3100
3101         Fix build error from r99108.
3102
3103         * WebProcess/WebPage/WebPage.cpp:
3104         (WebKit::WebPage::performDragControllerAction):
3105
3106 2011-11-02  Dean Jackson  <dino@apple.com>
3107
3108         Add ENABLE_CSS_SHADERS flag
3109         https://bugs.webkit.org/show_bug.cgi?id=71394
3110
3111         Reviewed by Sam Weinig.
3112
3113         * Configurations/FeatureDefines.xcconfig:
3114
3115 2011-11-02  Anders Carlsson  <andersca@apple.com>
3116
3117         Allow the various plug-in ports to decide whether NPWindow coordinates should be window-relative
3118         https://bugs.webkit.org/show_bug.cgi?id=71415
3119
3120         Reviewed by Darin Adler.
3121
3122         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
3123         (WebKit::NetscapePlugin::callSetWindow):
3124         Remove the PLUGIN_ARCHITECTURE(X11) ifdef and set the NPWindow members
3125         based on the return value of wantsWindowRelativeNPWindowCoordinates.
3126
3127         * WebProcess/Plugins/Netscape/NetscapePlugin.h:
3128         * WebProcess/Plugins/Netscape/mac/NetscapePluginMac.mm:
3129         (WebKit::NetscapePlugin::wantsWindowRelativeNPWindowCoordinates):
3130         * WebProcess/Plugins/Netscape/win/NetscapePluginWin.cpp:
3131         (WebKit::NetscapePlugin::wantsWindowRelativeNPWindowCoordinates):
3132         * WebProcess/Plugins/Netscape/x11/NetscapePluginX11.cpp:
3133         (WebKit::NetscapePlugin::wantsWindowRelativeNPWindowCoordinates):
3134         Add platform specific implementations.
3135
3136 2011-11-02  Viatcheslav Ostapenko  <ostapenko.viatcheslav@nokia.com>
3137
3138         [Qt] [WK] Debug build broken after r99065
3139         https://bugs.webkit.org/show_bug.cgi?id=71397
3140
3141         Remove reference to panGestureActive becuase it is not defined anywhere.
3142
3143         Reviewed by Simon Hausmann.
3144
3145         * UIProcess/qt/QtViewportInteractionEngine.cpp:
3146         (WebKit::QtViewportInteractionEngine::panGestureStarted):
3147
3148 2011-11-02  Jon Lee  <jonlee@apple.com>
3149
3150         Update dragging info on mac when user is dragging files into view
3151         https://bugs.webkit.org/show_bug.cgi?id=71325
3152         <rdar://problem/10379193>
3153
3154         Reviewed by Darin Adler.
3155
3156         * UIProcess/API/mac/WKView.mm:
3157         (-[WKView draggingUpdated:]): Based on the DragSession, we update NSDraggingInfo
3158         to update the badge and dragging formation.
3159
3160 2011-11-02  Jon Lee  <jonlee@apple.com>
3161
3162         Expand DragController to provide more information about the dragging session
3163         https://bugs.webkit.org/show_bug.cgi?id=71324
3164         <rdar://problem/10379175>
3165
3166         Reviewed by Darin Adler.
3167
3168         We now pass the DragSession struct from the Web to the UI process, instead of the
3169         DragOperation enum.
3170
3171         * Scripts/webkit2/messages.py:
3172         * Shared/WebCoreArgumentCoders.cpp:
3173         (CoreIPC::::encode):
3174         (CoreIPC::::decode):
3175         * Shared/WebCoreArgumentCoders.h:
3176         * UIProcess/API/mac/WKView.mm:
3177         (-[WKView draggingUpdated:]):
3178         * UIProcess/WebPageProxy.cpp:
3179         (WebKit::WebPageProxy::WebPageProxy): We now cache the last known DragSession state
3180         (WebKit::WebPageProxy::didPerformDragControllerAction):
3181         * UIProcess/WebPageProxy.h:
3182         (WebKit::WebPageProxy::dragSession):
3183         (WebKit::WebPageProxy::resetDragOperation):
3184         * UIProcess/WebPageProxy.messages.in:
3185         * UIProcess/win/WebView.cpp:
3186         (WebKit::WebView::keyStateToDragOperation):
3187         (WebKit::WebView::DragEnter):
3188         (WebKit::WebView::DragOver):
3189         * WebProcess/WebPage/WebPage.cpp:
3190         (WebKit::WebPage::performDragControllerAction):
3191
3192 2011-11-02  Anders Carlsson  <andersca@apple.com>
3193
3194         Get rid of Plugin::deprecatedGeometryDidChange
3195         https://bugs.webkit.org/show_bug.cgi?id=71411
3196
3197         Reviewed by Sam Weinig.
3198
3199         Now that all Plugin subclasses implement geometryDidChange and do all the work there
3200         we can get rid of deprecatedGeometryDidChange.
3201
3202         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
3203         * WebProcess/Plugins/Netscape/NetscapePlugin.h:
3204         * WebProcess/Plugins/PDF/BuiltInPDFView.cpp:
3205         * WebProcess/Plugins/PDF/BuiltInPDFView.h:
3206         * WebProcess/Plugins/Plugin.h:
3207         * WebProcess/Plugins/PluginProxy.cpp:
3208         * WebProcess/Plugins/PluginProxy.h:
3209         * WebProcess/Plugins/PluginView.cpp:
3210         (WebKit::PluginView::viewGeometryDidChange):
3211
3212 2011-11-02  Anders Carlsson  <andersca@apple.com>
3213
3214         Move back functions that were not added.
3215
3216         * UIProcess/API/C/WKPage.h:
3217
3218 2011-11-02  Anders Carlsson  <andersca@apple.com>
3219
3220         Fix build and WebKit2 ABI.
3221
3222         * Shared/APIClientTraits.cpp:
3223         * Shared/APIClientTraits.h:
3224         Add page loader client sizes.
3225
3226         * UIProcess/API/C/WKPage.h:
3227         Move the newly added callback functions in the loader client last and bump the
3228         WKPageLoaderClient version.
3229         
3230 2011-11-02  Anders Carlsson  <andersca@apple.com>
3231
3232         Fix build.
3233
3234         * WebProcess/Plugins/PluginView.h:
3235
3236 2011-11-02  Tom Sepez  <tsepez@chromium.org>
3237
3238         XSSAuditor is silent
3239         https://bugs.webkit.org/show_bug.cgi?id=70973
3240
3241         Reviewed by Adam Barth.
3242
3243         * UIProcess/API/C/WKPage.h:
3244         * UIProcess/API/gtk/WebKitWebLoaderClient.cpp:
3245         (webkitWebLoaderClientAttachLoaderClientToPage):
3246         * UIProcess/WebLoaderClient.cpp:
3247         (WebKit::WebLoaderClient::didDetectXSSForFrame):
3248         * UIProcess/WebLoaderClient.h:
3249         * UIProcess/WebPageProxy.cpp:
3250         (WebKit::WebPageProxy::didDetectXSSForFrame):
3251         * UIProcess/WebPageProxy.h:
3252         * UIProcess/WebPageProxy.messages.in:
3253         * WebProcess/InjectedBundle/API/c/WKBundlePage.h:
3254         * WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.cpp:
3255         (WebKit::InjectedBundlePageLoaderClient::didDetectXSSForFrame):
3256         * WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.h:
3257         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
3258         (WebKit::WebFrameLoaderClient::didDetectXSS):
3259         * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
3260
3261 2011-11-02  Anders Carlsson  <andersca@apple.com>
3262
3263         More window relative coordinate usage removal
3264         https://bugs.webkit.org/show_bug.cgi?id=71393
3265
3266         Reviewed by Adam Roben.
3267
3268         * WebProcess/Plugins/Netscape/win/NetscapePluginWin.cpp:
3269         (WebKit::NetscapePlugin::scheduleWindowedGeometryUpdate):
3270         Just use m_clipRect instead of converting m_clipRectInWindowCoordinates to plug-in coordinates.
3271
3272         (WebKit::NetscapePlugin::platformPaint):
3273         Use m_pluginSize instead of m_frameRectInWindowCoordinates.size().
3274
3275         * WebProcess/Plugins/Netscape/x11/NetscapePluginX11.cpp:
3276         (WebKit::NetscapePlugin::platformPaint):
3277         Ditto.
3278
3279 2011-11-02  Anders Carlsson  <andersca@apple.com>
3280
3281         Fix non-Mac builds and remove #if PLATFORM(MAC) around all contents scale factor functions.
3282
3283         * PluginProcess/PluginControllerProxy.cpp:
3284         (WebKit::PluginControllerProxy::PluginControllerProxy):
3285         (WebKit::PluginControllerProxy::contentsScaleFactor):
3286         (WebKit::PluginControllerProxy::geometryDidChange):
3287         * PluginProcess/PluginControllerProxy.h:
3288         * PluginProcess/PluginCreationParameters.cpp:
3289         (WebKit::PluginCreationParameters::PluginCreationParameters):
3290         (WebKit::PluginCreationParameters::encode):
3291         (WebKit::PluginCreationParameters::decode):
3292         * PluginProcess/PluginCreationParameters.h:
3293         * PluginProcess/mac/PluginControllerProxyMac.mm:
3294         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
3295         (WebKit::NetscapePlugin::contentsScaleFactor):
3296         (WebKit::NetscapePlugin::getAuthenticationInfo):
3297         (WebKit::NetscapePlugin::snapshot):
3298         (WebKit::NetscapePlugin::contentsScaleFactorChanged):
3299         * WebProcess/Plugins/Netscape/NetscapePlugin.h:
3300         * WebProcess/Plugins/Netscape/mac/NetscapePluginMac.mm:
3301         * WebProcess/Plugins/Plugin.h:
3302         * WebProcess/Plugins/PluginController.h:
3303         * WebProcess/Plugins/PluginProxy.cpp:
3304         (WebKit::PluginProxy::initialize):
3305         (WebKit::PluginProxy::contentsScaleFactorChanged):
3306         (WebKit::PluginProxy::contentsScaleFactor):
3307         * WebProcess/Plugins/PluginProxy.h:
3308         * WebProcess/Plugins/PluginView.cpp:
3309         (WebKit::PluginView::contentsScaleFactor):
3310
3311 2011-11-02  Anders Carlsson  <andersca@apple.com>
3312
3313         Use m_pluginSize instead of m_frameRectInWindowCoordinates.size() in NetscapePlugin.
3314         https://bugs.webkit.org/show_bug.cgi?id=71390
3315
3316         Reviewed by Adam Roben.
3317
3318         m_pluginSize is always equal to m_frameRectInWindowCoordinates.size() and this moves us one
3319         sall step further towards eliminating m_frameRectInWindowCoordinates.
3320
3321         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
3322         (WebKit::NetscapePlugin::invalidate):
3323         (WebKit::NetscapePlugin::snapshot):
3324
3325 2011-11-02  Anders Carlsson  <andersca@apple.com>
3326
3327         Fix non-Mac builds.
3328
3329         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
3330         (WebKit::NetscapePlugin::snapshot):
3331
3332 2011-11-02  Anders Carlsson  <andersca@apple.com>
3333
3334         Plug-in snapshots are blurry in HiDPI
3335         https://bugs.webkit.org/show_bug.cgi?id=71387
3336         <rdar://problem/10385393>
3337
3338         Reviewed by Adam Roben.
3339
3340         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
3341         (WebKit::NetscapePlugin::snapshot):
3342         Create the backing store in the right size and apply the contents scale factor
3343         to the newly created graphics context.
3344
3345         * WebProcess/Plugins/PluginView.cpp:
3346         (WebKit::PluginView::paint):
3347         Pass the scale factor to ShareableBitmap::paint.
3348
3349 2011-11-02  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>
3350
3351         [Qt] Implement message exchange between WebView and the web page
3352         https://bugs.webkit.org/show_bug.cgi?id=70545
3353
3354         Reviewed by Noam Rosenthal.
3355
3356         Adds a mechanism for the WebView to send messages to the JavaScript environment
3357         of the web page. In the WebView we have a method postMessage() and a signal
3358         messageReceived(), while in the web page we expose a navigator.qt object with a
3359         postMessage() method and a onmessage property. The messages are objects that
3360         follow the same structure as MessageEvents.
3361
3362         The feature is disabled by default, and can be enabled by setting
3363         QWebPreferences::navigatorQtObjectEnabled property to true. Changes take effect
3364         after the next load(). QML tests are included.
3365
3366         * UIProcess/qt/ClientImpl.h:
3367         * UIProcess/qt/ClientImpl.cpp:
3368         (setupContextInjectedBundleClient): Helper to register the injected bundle client.
3369         (qt_wk_didReceiveMessageFromInjectedBundle): Decode and dispatch a message received
3370         from the WebProcess to the WebPageProxy.
3371
3372         * UIProcess/PageClient.h:
3373         (WebKit::PageClient::didReceiveMessageFromNavigatorQtObject):
3374         * UIProcess/WebPageProxy.cpp:
3375         (WebKit::WebPageProxy::didReceiveMessageFromNavigatorQtObject):
3376         * UIProcess/WebPageProxy.h:
3377         Handle messages received from the navigator.qt object via the injected bundle. Called
3378         from the ClientImpl.
3379
3380         * UIProcess/API/qt/qbasewebview.cpp:
3381         (QBaseWebView::postMessage):
3382         (QBaseWebViewPrivate::setPageProxy):
3383         * UIProcess/API/qt/qbasewebview.h:
3384         * UIProcess/API/qt/qwebpreferences.cpp:
3385         (QWebPreferences::navigatorQtObjectEnabled):
3386         (QWebPreferences::setNavigatorQtObjectEnabled):
3387         * UIProcess/API/qt/qwebpreferences.h:
3388         The signal, slot and the setting to enable the feature.
3389
3390         * UIProcess/qt/QtWebPageProxy.cpp:
3391         (QtWebPageProxy::defaultWKContext): setup the injected bundle client for this the
3392         default context so we can listen to messages from it.
3393
3394         (QtWebPageProxy::QtWebPageProxy):
3395         (QtWebPageProxy::didReceiveMessageFromNavigatorQtObject):
3396         (QtWebPageProxy::setNavigatorQtObjectEnabled):
3397         (QtWebPageProxy::postMessageToNavigatorQtObject):
3398         * UIProcess/qt/QtWebPageProxy.h:
3399         (QtWebPageProxy::navigatorQtObjectEnabled):
3400         Enabling and sending messages to the navigator.qt object are done by sending messages to
3401         the injected bundle, identifying the page that we want to act on.
3402
3403         * UIProcess/API/qt/tests/qmltests/DesktopWebView/tst_messaging.qml: Added.
3404         * UIProcess/API/qt/tests/qmltests/common/messaging.html: Added.
3405         * UIProcess/API/qt/tests/qmltests/qmltests.pro:
3406         * WebProcess/qt/QtBuiltinBundle.cpp:
3407         (WebKit::QtBuiltinBundle::initialize):
3408         (WebKit::QtBuiltinBundle::didReceiveMessage):
3409         (WebKit::QtBuiltinBundle::handleMessageToNavigatorQtObject):
3410         (WebKit::QtBuiltinBundle::handleSetNavigatorQtObjectEnabled):
3411         * WebProcess/qt/QtBuiltinBundle.h:
3412         * WebProcess/qt/QtBuiltinBundlePage.cpp:
3413         (WebKit::QtBuiltinBundlePage::QtBuiltinBundlePage):
3414         (WebKit::QtBuiltinBundlePage::~QtBuiltinBundlePage):
3415         (WebKit::QtBuiltinBundlePage::didClearWindowForFrame):
3416         (WebKit::qt_postMessageCallback):
3417         (WebKit::QtBuiltinBundlePage::postMessageFromNavigatorQtObject):
3418         (WebKit::createWrappedMessage):
3419         (WebKit::QtBuiltinBundlePage::didReceiveMessageToNavigatorQtObject):
3420         (WebKit::QtBuiltinBundlePage::setNavigatorQtObjectEnabled):
3421         (WebKit::QtBuiltinBundlePage::registerNavigatorQtObject):
3422         (WebKit::QtBuiltinBundlePage::navigatorQtObjectClass):
3423         * WebProcess/qt/QtBuiltinBundlePage.h:
3424         (WebKit::QtBuiltinBundlePage::navigatorQtObjectEnabled):
3425
3426 2011-11-02  Jocelyn Turcotte  <jocelyn.turcotte@nokia.com>
3427
3428         [Qt] Fix qmltest API test failures related to r98973.
3429         https://bugs.webkit.org/show_bug.cgi?id=71280
3430
3431         Reviewed by Noam Rosenthal.
3432
3433         Most of the API was moved from TouchWebView.page to TouchWebView directly.
3434         Fixed the qml tests to reflect this change.
3435
3436         * UIProcess/API/qt/tests/qmltests/TouchWebView/tst_load.qml:
3437         * UIProcess/API/qt/tests/qmltests/TouchWebView/tst_loadFail.qml:
3438         * UIProcess/API/qt/tests/qmltests/TouchWebView/tst_loadNegativeSizeView.qml:
3439         * UIProcess/API/qt/tests/qmltests/TouchWebView/tst_loadProgress.qml:
3440         * UIProcess/API/qt/tests/qmltests/TouchWebView/tst_loadProgressSignal.qml:
3441         * UIProcess/API/qt/tests/qmltests/TouchWebView/tst_loadZeroSizeView.qml:
3442         * UIProcess/API/qt/tests/qmltests/TouchWebView/tst_properties.qml:
3443
3444 2011-11-02  Kenneth Rohde Christiansen  <kenneth@webkit.org>
3445
3446         [Qt] Handle interruption of page interaction better
3447         https://bugs.webkit.org/show_bug.cgi?id=71366
3448
3449         Reviewed by Simon Hausmann.
3450
3451         Touching the screen when a kinetic scrolling animation is running or
3452         it is bouncing back because it was out of bounds, the animation is
3453         immediately stopped and the content is immediately put into valid
3454         bounds.
3455
3456         Touching the screen when the contents is bouncing back from a pinch
3457         zoom which was out of bounds, we do not stop the animation, but
3458         instead ignored the touch events while the animation lasts.
3459
3460         In the future we want to queue the events instead.
3461
3462         This also fixes some issues which was present before: As the bounce
3463         back animation from pinch zoom centers the content using the contents
3464         point which was in the center of the viewport, this animation could
3465         not be used when stopping a pan animation, as it wouldn't position the
3466         content at the place it was when the pan animation was interrupted.
3467
3468         * UIProcess/qt/QtPanGestureRecognizer.cpp:
3469         (WebKit::QtPanGestureRecognizer::recognize):
3470         * UIProcess/qt/QtPinchGestureRecognizer.cpp:
3471         (WebKit::QtPinchGestureRecognizer::recognize):
3472         * UIProcess/qt/QtViewportInteractionEngine.cpp:
3473         (WebKit::QtViewportInteractionEngine::animateContentIntoBoundariesIfNeeded):
3474         (WebKit::QtViewportInteractionEngine::reset):
3475         (WebKit::QtViewportInteractionEngine::setConstraints):
3476         (WebKit::QtViewportInteractionEngine::panAnimationActive):
3477         (WebKit::QtViewportInteractionEngine::panGestureStarted):
3478         (WebKit::QtViewportInteractionEngine::panGestureCancelled):
3479         (WebKit::QtViewportInteractionEngine::pinchAnimationActive):
3480         * UIProcess/qt/QtViewportInteractionEngine.h:
3481
3482 2011-11-02  Zalan Bujtas  <zbujtas@gmail.com>
3483
3484         [Qt][WK2] Move content to resize (setResizesToContentsUsingLayoutSize) from UI process to Web process
3485         https://bugs.webkit.org/show_bug.cgi?id=71107
3486
3487         Reviewed by Kenneth Rohde Christiansen.
3488
3489         Reduce the number of IPC calls to WebProcess by moving the content to resize
3490         calls from UI process to Web process.
3491
3492         * UIProcess/API/qt/qtouchwebview.cpp:
3493         (QTouchWebViewPrivate::updateViewportSize):
3494         (QTouchWebViewPrivate::updateViewportConstraints):
3495         (QTouchWebView::geometryChanged):
3496         * UIProcess/API/qt/qtouchwebview_p.h:
3497         * UIProcess/WebPageProxy.cpp:
3498         (WebKit::WebPageProxy::setViewportSize):
3499         (WebKit::WebPageProxy::preferencesDidChange):
3500         * UIProcess/WebPageProxy.h:
3501         * UIProcess/qt/QtTouchWebPageProxy.cpp:
3502         * UIProcess/qt/QtTouchWebPageProxy.h:
3503         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
3504         (WebKit::WebChromeClient::dispatchViewportPropertiesDidChange):
3505         * WebProcess/WebPage/WebPage.messages.in:
3506
3507 2011-10-18  Dinu Jacob  <dinu.jacob@nokia.com>
3508
3509         [Qt][WK2]: Shouldn't send unhandled TouchCancel event to gesture recognizers
3510         https://bugs.webkit.org/show_bug.cgi?id=70333
3511
3512         Reviewed by Simon Hausmann.
3513
3514         Gesture recognizers should be reset for unhandled TouchCancel event.
3515
3516         * UIProcess/qt/qtouchwebpageproxy.cpp:
3517         (QTouchWebPageProxy::doneWithTouchEvent):
3518
3519 2011-11-02  Simon Hausmann  <simon.hausmann@nokia.com>
3520
3521         [Qt][WK2] Add support for touch event testing to WebKitTestRunner
3522         https://bugs.webkit.org/show_bug.cgi?id=71310
3523
3524         Reviewed by Kenneth Rohde Christiansen.
3525
3526         * UIProcess/WebPageProxy.cpp:
3527         (WebKit::WebPageProxy::handleTouchEvent): Add support for m_shouldSendEventsSynchronously.
3528         * UIProcess/qt/QtDesktopWebPageProxy.cpp:
3529         (QtDesktopWebPageProxy::handleEvent): Handle plain touch events in the desktop page proxy by
3530         forwarding them appropriately. We will receive them from WTR through ::event, but we won't
3531         receive them from QQuickCanvas (i.e. the user) because that doesn't uses ::event but only
3532         dedicated fooEvent() handlers, of which we don't re-implement the touch version.
3533         (QtDesktopWebPageProxy::handleTouchEvent): Forward touch events to WebPageProxy.
3534         * UIProcess/qt/QtDesktopWebPageProxy.h:
3535         * WebProcess/WebPage/WebPage.cpp:
3536         (WebKit::WebPage::touchEventSyncForTesting): Add support for synchronous touch event testing,
3537         similar to the way it's done for mouse events.
3538         * WebProcess/WebPage/WebPage.h: Ditto.
3539         * WebProcess/WebPage/WebPage.messages.in: Ditto.
3540
3541 2011-11-02  Simon Hausmann  <simon.hausmann@nokia.com>
3542
3543         [WK2] Remove unused/duplicated modifiers member from WebTouchEvent
3544         https://bugs.webkit.org/show_bug.cgi?id=71353
3545
3546         Reviewed by Kenneth Rohde Christiansen.
3547
3548         WebTouchEvent::m_[ctrl,alt,meta,shift]Key are redundant compared to
3549         WebEvent::m_modifiers. The latter is fully populated and used, the former
3550         can be safely removed.
3551
3552         * Shared/WebEvent.h:
3553         * Shared/WebTouchEvent.cpp:
3554         (WebKit::WebTouchEvent::WebTouchEvent):
3555         * Shared/qt/WebEventFactoryQt.cpp:
3556         (WebKit::WebEventFactory::createWebTouchEvent):
3557
3558 2011-11-02  Philippe Normand  <pnormand@igalia.com>
3559
3560         Unreviewed, skip testWebKitSettingsNewWithSettings affected by bug
3561         70127.
3562
3563         * UIProcess/API/gtk/tests/TestWebKitSettings.cpp:
3564         (testWebKitSettingsNewWithSettings):
3565
3566 2011-11-01  Andras Becsi  <andras.becsi@nokia.com>
3567
3568         [Qt][WK2] Make API tests less noisy
3569         https://bugs.webkit.org/show_bug.cgi?id=71295
3570
3571         Reviewed by Simon Hausmann.
3572
3573         Suppress superfluous debug messages of Qt5.
3574
3575         * UIProcess/API/qt/tests/commonviewtests/tst_commonviewtests.cpp: