REGRESSION (r103859): WKViews leak
[WebKit-https.git] / Source / WebKit2 / ChangeLog
1 2012-01-08  Dan Bernstein  <mitz@apple.com>
2
3         REGRESSION (r103859): WKViews leak
4         https://bugs.webkit.org/show_bug.cgi?id=75805
5
6         The flags changed event monitor added in r103859 was retaining the WKView (as it references
7         self in the handler block), causing it to leak.
8
9         * UIProcess/API/mac/WKView.mm:
10         (-[WKView dealloc]): Moved call to remove the flags changed event monitor from here...
11         (-[WKView viewDidMoveToWindow]): ...to here. Moved call to add the flags changed event
12         monitor to here from...
13         (-[WKView initWithFrame:contextRef:pageGroupRef:]): ...here.
14
15 2012-01-06  Mark Rowe  <mrowe@apple.com>
16
17         REGRESSION (WebKit2): Save as PDF no longer generates links to URLs
18         <http://webkit.org/b/65076> / <rdar://problem/9606246>
19
20         WebKit2 printing works by having the web process render the page content to a PDF. The PDF
21         data is then shipped to the UI process which will render it in to the printing graphics context.
22         Links were being lost because the API used to do the rendering of the PDF in to the printing
23         graphics context, CGContextDrawPDFPage, did not preserve the links that were present in the
24         PDF content received from the web process.
25
26         To fix this we switch to using PDFKit for drawing the PDF in to the printing graphics context.
27         PDFKit provides the ability for us to iterate over the links in the PDF content ourselves and
28         add links in to the printing graphics context.
29
30         Reviewed by Alexey Proskuryakov.
31
32         * UIProcess/API/mac/WKPrintingView.h:
33         * UIProcess/API/mac/WKPrintingView.mm:
34         (pdfAnnotationLinkClass): Look up the PDFAnnotationLink class from PDFKit as WebKit2 loads PDFKit lazily.
35         (pdfDocumentClass): Ditto.
36         (-[WKPrintingView _drawPDFDocument:page:atPoint:]): Switch to using the PDFKit equivalents of several types.
37         Iterate over the annotations present in the PDFPage, calling CGPDFContextSetURLForRect for each PDFAnnotationLink
38         that we find.
39         (-[WKPrintingView _drawPreview:]): Create an NSData to feed to PDFDocument.
40         (-[WKPrintingView drawRect:]): Ditto.
41         * WebKit2Prefix.h: Add the usual workaround to make Objective-C exceptions compile when C++ exception handling is disabled.
42
43 2012-01-06  Viatcheslav Ostapenko  <ostapenko.viatcheslav@nokia.com>
44
45         [Qt] [WK2] Minibrowser leaks memory ~6-7Mb per reload
46         https://bugs.webkit.org/show_bug.cgi?id=75746
47
48         Reset WebGraphicsLayer::m_layerTreeTileClient of all dependent 
49         layers from ~LayerTreeHostQt(). This replaces r103760 which
50         causes leaks of GraphicsLayerTextureMapper objects on UI side. 
51
52         Reviewed by Noam Rosenthal.
53
54         * WebProcess/WebCoreSupport/WebGraphicsLayer.cpp:
55         (WebCore::WebGraphicsLayer::syncCompositingStateForThisLayerOnly):
56         (WebCore::WebGraphicsLayer::setLayerTreeTileClient):
57         * WebProcess/WebCoreSupport/WebGraphicsLayer.h:
58         * WebProcess/WebPage/qt/LayerTreeHostQt.cpp:
59         (WebKit::LayerTreeHostQt::~LayerTreeHostQt):
60
61 2012-01-06  Alexey Proskuryakov  <ap@apple.com>
62
63         [Mac] Thread verifier assertions when printing
64         https://bugs.webkit.org/show_bug.cgi?id=75738
65
66         Reviewed by Sam Weinig.
67
68         * UIProcess/API/mac/WKPrintingView.mm:
69         (-[WKPrintingView dealloc]): Dealloc in main thread, so that WebFrameProxy doesn't get
70         deref'ed from a secondary one.
71         (-[WKPrintingView _adjustPrintingMarginsForHeaderAndFooter]): This method calls out to client,
72         which only expects that on main thread.
73         (-[WKPrintingView knowsPageRange:]): Call _adjustPrintingMarginsForHeaderAndFooter on main
74         thread.
75
76 2012-01-06  Alexey Proskuryakov  <ap@apple.com>
77
78         Need to allow SCNetworkReachability service in sandbox profile
79         https://bugs.webkit.org/show_bug.cgi?id=75724
80         <rdar://problem/10652415>
81
82         Reviewed by Mark Rowe.
83
84         * WebProcess/com.apple.WebProcess.sb:
85
86 2012-01-06  Benjamin Poulain  <bpoulain@apple.com>
87
88         [Mac] Sort the resources of WebKit2.xcodeproj
89         https://bugs.webkit.org/show_bug.cgi?id=75636
90
91         Reviewed by Andreas Kling.
92
93         * WebKit2.xcodeproj/project.pbxproj:
94
95 2012-01-06  Rafael Brandao  <rafael.lobo@openbossa.org>
96
97         [Qt][WK2] QQuickWebView breaks when an empty url is loaded
98         https://bugs.webkit.org/show_bug.cgi?id=75445
99
100         Reviewed by Tor Arne Vestbø.
101
102         * UIProcess/API/qt/qquickwebview.cpp:
103         (QQuickWebView::load):
104         * UIProcess/API/qt/tests/qmltests/WebView/tst_loadUrl.qml: Check if a request to load
105         an empty url is ignored. 'about:blank' should be used instead to load an empty page.
106         * UIProcess/API/qt/tests/qmltests/qmltests.pro:
107
108 2012-01-06  Tor Arne Vestbø  <tor.arne.vestbo@nokia.com>
109
110         [Qt] Move listing of include paths and libs to pri files in sources
111
112         Includepaths are sometimes modified by non-Qt contributors so keeping
113         them in files inside Sources makes it more likely that they are updated
114         along with project files for the other ports.
115
116         Using pri files instead of prf files for this also has the benefit that
117         the include() from the main target file can be parsed and followed by
118         Qt Creator -- something that does not work with load().
119
120         Dependency from a target to a library through the WEBKIT variable are
121         handled through forwarding-files in Tools/qmake/mkspecs/modules, which
122         set the source root of the module and include the right pri file.
123
124         Ideally we'd use the variant of include() that takes an optional
125         namespace to read the variables into, or the fromfile() function,
126         but both of these add an overhead of about 40% on the total qmake
127         runtime, due to making a deep copy of all the variables in the
128         project or re-reading all the prf files from scratch.
129
130         Reviewed by Simon Hausmann.
131         Reviewed by Ossy.
132
133         * Target.pri:
134         * WebKit2.pri: Renamed from Tools/qmake/mkspecs/features/webkit2.prf.
135
136 2012-01-06  Zeno Albisser  <zeno@webkit.org>
137
138         [Qt][WK2] Add test for application URL schemes.
139         https://bugs.webkit.org/show_bug.cgi?id=74933
140
141         Reviewed by Kenneth Rohde Christiansen.
142
143         * UIProcess/API/qt/tests/qmltests/WebView/tst_applicationScheme.qml: Added.
144         * UIProcess/API/qt/tests/qmltests/qmltests.pro:
145
146 2012-01-05  Dan Bernstein  <mitz@apple.com>
147
148         <rdar://problem/10633760> Update copyright strings
149
150         Reviewed by Mark Rowe.
151
152         * Info.plist:
153         * PluginProcess/Info.plist:
154         * WebProcess/Info.plist:
155
156 2012-01-05  Anders Carlsson  <andersca@apple.com>
157
158         Crash when trying to invalidate the NPRuntimeObjectMap for a plug-in in a subframe
159         https://bugs.webkit.org/show_bug.cgi?id=75667
160         <rdar://problem/10389454>
161
162         Reviewed by Kevin Decker.
163
164         NPRuntimeObjectMap::invalidate is called whenever a plug-in view is destroyed. If invalidate is called for an object map
165         whose plug-in has a null frame, we'd crash.
166
167         The plug-in will have a null frame if the plug-in view is destroyed because its containing frame has been removed from the document,
168         and if the plug-in view is being destroyed asynchronously due to the plug-in itself calling JavaScript that will remove the frame
169         (see PluginView::unprotectPluginFromDestruction).
170
171         The reason NPRuntimeObjectMap::invalidate will crash when the frame is null is because we were trying to access the frame's global
172         object, causing a null dereference. The reason we were trying to get at the frame's global object was to create a Strong handle to
173         a JSNPObject so we could stick the object in a vector so we could later iterate over the vector elements and call invalidate() on
174         each JSNPObject which will end up releasing the underlying NPObject.
175
176         However, it turns out that we don't need to stick the JSNPObject in a vector; we can just get the underlying NPObject directly and
177         stick that in a vector and then iterate over the NPObjects, releasing them.
178
179         * WebProcess/Plugins/Netscape/NPRuntimeObjectMap.cpp:
180         (WebKit::NPRuntimeObjectMap::invalidate):
181
182 2012-01-05  Alexey Proskuryakov  <ap@apple.com>
183
184         REGRESSION (r98912-r99538): Crash in WebKit::WebFrameLoaderClient::didDetectXSS
185         https://bugs.webkit.org/show_bug.cgi?id=75578
186
187         Reviewed by Daniel Bates.
188
189         * WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.cpp:
190         (WebKit::InjectedBundlePageLoaderClient::didDetectXSSForFrame):
191         Check for a correct struct member existence.
192
193 2012-01-05  Alexey Proskuryakov  <ap@apple.com>
194
195         WK2: Safari fails to open a PostScript file in Preview from context menu
196         https://bugs.webkit.org/show_bug.cgi?id=75643
197         <rdar://problem/9823430>
198
199         Reviewed by Dan Bernstein.
200
201         * UIProcess/API/mac/PDFViewController.mm: (WebKit::PDFViewController::setPDFDocumentData):
202         Append ".pdf" to file name when converting data, as suggested file name is created for
203         original MIME type.
204
205 2012-01-05  Zeno Albisser  <zeno@webkit.org>
206
207         [Qt][WK2] Implement custom URL schemes defined in QML.
208         https://bugs.webkit.org/show_bug.cgi?id=74931
209
210         Allow creation of custom UrlSchemeDelegates from QML.
211         A UrlSchemeDelegate contains a handler signal that is triggered
212         when a url matching the defined scheme is requested.
213         To allow for this a derivation of QNetworkAccessManager
214         is necessary.
215         The request is then handled in QML/JS and a reply
216         is sent back from the UIProcess to the WebProcess.
217
218         Reviewed by Kenneth Rohde Christiansen.
219
220         * Shared/qt/QtNetworkReplyData.cpp: Added.
221         (WebKit::QtNetworkReplyData::QtNetworkReplyData):
222         (WebKit::QtNetworkReplyData::encode):
223         (WebKit::QtNetworkReplyData::decode):
224         * Shared/qt/QtNetworkReplyData.h: Added.
225         * Shared/qt/QtNetworkRequestData.cpp: Added.
226         (WebKit::QtNetworkRequestData::QtNetworkRequestData):
227         (WebKit::QtNetworkRequestData::encode):
228         (WebKit::QtNetworkRequestData::decode):
229         * Shared/qt/QtNetworkRequestData.h: Added.
230         * Target.pri:
231         * UIProcess/API/qt/qquicknetworkreply.cpp: Added.
232         (QQuickNetworkReply::QQuickNetworkReply):
233         (QQuickNetworkReply::contentType):
234         (QQuickNetworkReply::setContentType):
235         (QQuickNetworkReply::operation):
236         (QQuickNetworkReply::setOperation):
237         (QQuickNetworkReply::contentDisposition):
238         (QQuickNetworkReply::setContentDisposition):
239         (QQuickNetworkReply::location):
240         (QQuickNetworkReply::setLocation):
241         (QQuickNetworkReply::lastModified):
242         (QQuickNetworkReply::setLastModified):
243         (QQuickNetworkReply::cookie):
244         (QQuickNetworkReply::setCookie):
245         (QQuickNetworkReply::userAgent):
246         (QQuickNetworkReply::setUserAgent):
247         (QQuickNetworkReply::server):
248         (QQuickNetworkReply::setServer):
249         (QQuickNetworkReply::data):
250         (QQuickNetworkReply::setData):
251         (QQuickNetworkReply::send):
252         (QQuickNetworkReply::networkRequestData):
253         (QQuickNetworkReply::setNetworkRequestData):
254         (QQuickNetworkReply::networkReplyData):
255         * UIProcess/API/qt/qquicknetworkreply_p.h: Added.
256         * UIProcess/API/qt/qquicknetworkrequest_p.h: Added.
257         * UIProcess/API/qt/qquickurlschemedelegate.cpp: Added.
258         (QQuickUrlSchemeDelegate::QQuickUrlSchemeDelegate):
259         (QQuickUrlSchemeDelegate::scheme):
260         (QQuickUrlSchemeDelegate::setScheme):
261         (QQuickUrlSchemeDelegate::request):
262         (QQuickUrlSchemeDelegate::reply):
263         * UIProcess/API/qt/qquickurlschemedelegate_p.h: Added.
264         * UIProcess/API/qt/qquickwebview.cpp:
265         (QQuickWebViewExperimental::QQuickWebViewExperimental):
266         (QQuickWebViewExperimental::schemeDelegates_At):
267         (QQuickWebViewExperimental::schemeDelegates_Append):
268         (QQuickWebViewExperimental::schemeDelegates_Count):
269         (QQuickWebViewExperimental::schemeDelegates_Clear):
270         (QQuickWebViewExperimental::schemeDelegates):
271         (QQuickWebViewExperimental::invokeApplicationSchemeHandler):
272         (QQuickWebViewExperimental::sendApplicationSchemeReply):
273         * UIProcess/API/qt/qquickwebview_p.h:
274         * UIProcess/WebPageProxy.h:
275         * UIProcess/WebPageProxy.messages.in:
276         * UIProcess/qt/QtPageClient.cpp:
277         (QtPageClient::handleApplicationSchemeRequest):
278         * UIProcess/qt/QtPageClient.h:
279         * UIProcess/qt/WebPageProxyQt.cpp:
280         (WebKit::WebPageProxy::registerApplicationScheme):
281         (WebKit::WebPageProxy::resolveApplicationSchemeRequest):
282         (WebKit::WebPageProxy::sendApplicationSchemeReply):
283         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
284         (WebKit::WebFrameLoaderClient::createNetworkingContext):
285         * WebProcess/WebCoreSupport/qt/WebFrameNetworkingContext.cpp:
286         * WebProcess/WebCoreSupport/qt/WebFrameNetworkingContext.h:
287         * WebProcess/WebPage/WebPage.h:
288         * WebProcess/WebPage/WebPage.messages.in:
289         * WebProcess/WebPage/qt/WebPageQt.cpp:
290         (WebKit::WebPage::registerApplicationScheme):
291         (WebKit::WebPage::receivedApplicationSchemeRequest):
292         (WebKit::WebPage::applicationSchemeReply):
293         * WebProcess/qt/QtNetworkAccessManager.cpp: Added.
294         (WebKit::QtNetworkAccessManager::QtNetworkAccessManager):
295         (WebKit::QtNetworkAccessManager::obtainOriginatingWebPage):
296         (WebKit::QtNetworkAccessManager::createRequest):
297         (WebKit::QtNetworkAccessManager::registerApplicationScheme):
298         * WebProcess/qt/QtNetworkAccessManager.h: Added.
299         * WebProcess/qt/QtNetworkReply.cpp: Added.
300         (WebKit::QtNetworkReply::QtNetworkReply):
301         (WebKit::QtNetworkReply::setData):
302         (WebKit::QtNetworkReply::setReplyData):
303         (WebKit::QtNetworkReply::readData):
304         (WebKit::QtNetworkReply::bytesAvailable):
305         (WebKit::QtNetworkReply::setHeader):
306         (WebKit::QtNetworkReply::abort):
307         (WebKit::QtNetworkReply::close):
308         (WebKit::QtNetworkReply::setReadBufferSize):
309         (WebKit::QtNetworkReply::canReadLine):
310         (WebKit::QtNetworkReply::finalize):
311         * WebProcess/qt/QtNetworkReply.h: Added.
312         * WebProcess/qt/WebProcessQt.cpp:
313         (WebKit::WebProcess::platformInitializeWebProcess):
314
315 2012-01-05  Fady Samuel  <fsamuel@chromium.org>
316
317         Move scalePageBy from eventSender to window.internals
318         https://bugs.webkit.org/show_bug.cgi?id=64512
319
320         Reviewed by Simon Fraser.
321
322         * win/WebKit2.def:
323         * win/WebKit2CFLite.def:
324
325 2012-01-05  Alexander Færøy  <alexander.faeroy@nokia.com>
326
327         Pass WebFrame instead of WebCore::Frame to the WebKit2 specific FrameNetworkingContext
328         https://bugs.webkit.org/show_bug.cgi?id=75550
329
330         Make the WebKit2 FrameNetworkingContext implementation store the
331         WebFrame instead of the WebCore::Frame as this is needed for the Qt
332         port to implement a.o. HTTP autentication and SSL support.
333
334         As the WebFrameNetworkingContext is partly shared across all WebKit2 ports,
335         all port specific files have been modified.
336
337         For the Qt implementation of FrameNetworkingContext, we also set a
338         property to the originatingObject for the page ID. We also switch to
339         using an OwnPtr instead of a raw C++ pointer for the
340         m_originatingObject member.
341
342         Based on original patch by Peter Hartmann.
343
344         Reviewed by Kenneth Rohde Christiansen.
345
346         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
347         (WebKit::WebFrameLoaderClient::createNetworkingContext):
348         * WebProcess/WebCoreSupport/efl/WebFrameNetworkingContext.h:
349         (WebFrameNetworkingContext::create):
350         (WebFrameNetworkingContext::WebFrameNetworkingContext):
351         * WebProcess/WebCoreSupport/gtk/WebFrameNetworkingContext.h:
352         (WebFrameNetworkingContext::create):
353         (WebFrameNetworkingContext::WebFrameNetworkingContext):
354         * WebProcess/WebCoreSupport/mac/WebFrameNetworkingContext.h:
355         (WebKit::WebFrameNetworkingContext::create):
356         (WebKit::WebFrameNetworkingContext::WebFrameNetworkingContext):
357         * WebProcess/WebCoreSupport/qt/WebFrameNetworkingContext.cpp:
358         (WebCore::WebFrameNetworkingContext::WebFrameNetworkingContext):
359         (WebCore::WebFrameNetworkingContext::~WebFrameNetworkingContext):
360         (WebCore::WebFrameNetworkingContext::create):
361         * WebProcess/WebCoreSupport/qt/WebFrameNetworkingContext.h:
362         * WebProcess/WebCoreSupport/win/WebFrameNetworkingContext.h:
363         (WebFrameNetworkingContext::create):
364         (WebFrameNetworkingContext::WebFrameNetworkingContext):
365
366 2012-01-05  Kenneth Rohde Christiansen  <kenneth@webkit.org>
367
368         [Qt] Implement QQuickWebView::inputMethodQuery
369
370         Reviewed by Simon Hausmann.
371
372         Implement the current Qt5 queries of inputMethodQuery.
373
374         * UIProcess/API/qt/qquickwebview.cpp:
375         (QQuickWebView::inputMethodQuery):
376         * UIProcess/API/qt/qquickwebview_p.h:
377
378 2012-01-05  Carlos Garcia Campos  <cgarcia@igalia.com>
379
380         [GTK] Add methods to get/set the WebView zoom level to WebKit2 GTK+ API
381         https://bugs.webkit.org/show_bug.cgi?id=75248
382
383         Reviewed by Gustavo Noronha Silva.
384
385         It uses the page zoom factor unconditionally for now.
386
387         * UIProcess/API/gtk/WebKitWebView.cpp:
388         (webkitWebViewSetProperty):
389         (webkitWebViewGetProperty):
390         (webkit_web_view_class_init): Add WebKitWebView:zoom-level
391         property.
392         (webkit_web_view_set_zoom_level): Set current zoom level.
393         (webkit_web_view_get_zoom_level): Get current zoom level.
394         * UIProcess/API/gtk/WebKitWebView.h:
395         * UIProcess/API/gtk/docs/webkit2gtk-sections.txt: Add new symbols.
396         * UIProcess/API/gtk/tests/TestWebKitWebView.cpp:
397         (testWebViewZoomLevel):
398         (beforeAll):
399
400 2012-01-05  Carlos Garcia Campos  <cgarcia@igalia.com>
401
402         [GTK] Rename webkit_web_view_load_alternate_html as webkit_web_view_replace_content in WebKit2 GTK+
403         https://bugs.webkit.org/show_bug.cgi?id=75433
404
405         Reviewed by Martin Robinson.
406
407         * UIProcess/API/gtk/WebKitWebView.cpp:
408         (webkitWebViewLoadFail): Use webkit_web_view_replace_content().
409         (webkitWebViewLoadChanged): Do not emit load-changed signal when
410         replacing content.
411         (webkitWebViewLoadFailed): Do not emit load-failed signal when
412         replacing content.
413         (webkitWebViewSetEstimatedLoadProgress): Do not emit
414         notify::estimated-load-progress signal when replacing content.
415         (webkit_web_view_replace_content):
416         * UIProcess/API/gtk/WebKitWebView.h:
417         * UIProcess/API/gtk/docs/webkit2gtk-sections.txt:
418         * UIProcess/API/gtk/tests/TestWebKitWebLoaderClient.cpp:
419         (beforeAll):
420         * UIProcess/API/gtk/tests/TestWebKitWebView.cpp:
421         (replaceContentTitleChangedCallback):
422         (replaceContentLoadCallback):
423         (testWebViewReplaceContent):
424         (beforeAll):
425         * UIProcess/API/gtk/tests/WebViewTest.cpp:
426         (WebViewTest::replaceContent):
427         * UIProcess/API/gtk/tests/WebViewTest.h:
428
429 2012-01-05  Keunsoon Lee  <keunsoon.lee@samsung.com>
430
431         [WK2][EFL] creating dummy functions for Download class on Efl port.
432         https://bugs.webkit.org/show_bug.cgi?id=75246
433
434         dummy functions for Download class on Efl port
435
436         Reviewed by Hajime Morita.
437
438         * PlatformEfl.cmake: add new file to compile
439         * WebProcess/Downloads/efl: Added.
440         * WebProcess/Downloads/efl/DownloadEfl.cpp: Added.
441         (WebKit::Download::start):
442         (WebKit::Download::startWithHandle):
443         (WebKit::Download::cancel):
444         (WebKit::Download::platformInvalidate):
445         (WebKit::Download::didDecideDestination):
446         (WebKit::Download::platformDidFinish):
447         (WebKit::Download::receivedCredential):
448         (WebKit::Download::receivedRequestToContinueWithoutCredential):
449         (WebKit::Download::receivedCancellation):
450         (WebKit::Download::useCredential):
451         (WebKit::Download::continueWithoutCredential):
452         (WebKit::Download::cancelAuthenticationChallenge):
453
454 2012-01-04  Dan Bernstein  <mitz@apple.com>
455
456         Allow WebProcess to launch a client process and become its first WebProcess.
457
458         This is the WebKit2 part of fixing <http://webkit.org/b/75444> Debugging WebProcess requires running a UI process first and waiting to attach
459
460         Reviewed by Anders Carlsson.
461
462         * PluginProcess/mac/PluginProcessMainMac.mm:
463         (WebKit::PluginProcessMain): Added a newline to stderr output.
464         * UIProcess/Launcher/mac/EnvironmentVariables.cpp:
465         (WebKit::EnvironmentVariables::preexistingProcessServiceNameKey): Added. Returns the name
466         of the environment variable that optionally tells a UI processs to look for a preexisting
467         web process instead of launching a new one.
468         (WebKit::EnvironmentVariables::preexistingProcessTypeKey): Added. Returns the name of the
469         environment variable that tells a UI process the type of the preexisting web process
470         indicated by the other variable.
471         * UIProcess/Launcher/mac/EnvironmentVariables.h:
472         * UIProcess/Launcher/mac/ProcessLauncherMac.mm:
473         (WebKit::ProcessLauncher::launchProcess): Changed to look for a preexisting web process if
474         the aforementioned environment variables are set and the preexisting process has not been
475         used yet.
476         * WebProcess/mac/WebProcessMainMac.mm:
477         (WebKit::WebProcessMain): Changed to look for the -client-executable command-line option,
478         and if present, launch the specified executable, setting variables in its environment that
479         tell it to use this preexisting web process, then wait for it to send a send right to its
480         listening port.
481
482 2012-01-04  Alexey Proskuryakov  <ap@apple.com>
483
484         First sentence is missing or clipped when printing a inline PDF
485         https://bugs.webkit.org/show_bug.cgi?id=75514
486         <rdar://problem/10640680>
487
488         Reviewed by Dan Bernstein.
489
490         * UIProcess/WebPageProxy.cpp:
491         (WebKit::WebPageProxy::headerHeight):
492         (WebKit::WebPageProxy::footerHeight):
493         (WebKit::WebPageProxy::drawHeader):
494         (WebKit::WebPageProxy::drawFooter):
495         Do not ask the client about headers and footers when printing a PDF.
496
497 2012-01-04  Alexander Færøy  <alexander.faeroy@nokia.com>
498
499         [Qt] Fix test regressions after r104025
500         https://bugs.webkit.org/show_bug.cgi?id=75545
501
502         Reviewed by Kenneth Rohde Christiansen.
503
504         * WebProcess/WebPage/WebPage.cpp:
505         (WebKit::WebPage::editorState):
506
507 2012-01-04  Andras Becsi  <andras.becsi@nokia.com>
508
509         REGRESSION(r104028): Broke editing tests and event coordinates in desktop behaviour
510         https://bugs.webkit.org/show_bug.cgi?id=75542
511
512
513         [Qt][WK2] Pinch zoom should affect the page size
514         https://bugs.webkit.org/show_bug.cgi?id=74601
515
516         Unreviewed roll-out.
517
518         * Shared/NativeWebMouseEvent.h:
519         * Shared/NativeWebTouchEvent.h:
520         * Shared/NativeWebWheelEvent.h:
521         * Shared/qt/NativeWebMouseEventQt.cpp:
522         (WebKit::NativeWebMouseEvent::NativeWebMouseEvent):
523         * Shared/qt/NativeWebTouchEventQt.cpp:
524         (WebKit::NativeWebTouchEvent::NativeWebTouchEvent):
525         * Shared/qt/NativeWebWheelEventQt.cpp:
526         (WebKit::NativeWebWheelEvent::NativeWebWheelEvent):
527         * Shared/qt/WebEventFactoryQt.cpp:
528         (WebKit::WebEventFactory::createWebMouseEvent):
529         (WebKit::WebEventFactory::createWebWheelEvent):
530         (WebKit::WebEventFactory::createWebTouchEvent):
531         * Shared/qt/WebEventFactoryQt.h:
532         * UIProcess/API/qt/qquickwebpage.cpp:
533         (QQuickWebPage::keyPressEvent):
534         (QQuickWebPage::keyReleaseEvent):
535         (QQuickWebPage::inputMethodEvent):
536         (QQuickWebPage::focusInEvent):
537         (QQuickWebPage::focusOutEvent):
538         (QQuickWebPage::mousePressEvent):
539         (QQuickWebPage::mouseMoveEvent):
540         (QQuickWebPage::mouseReleaseEvent):
541         (QQuickWebPage::mouseDoubleClickEvent):
542         (QQuickWebPage::wheelEvent):
543         (QQuickWebPage::hoverEnterEvent):
544         (QQuickWebPage::hoverMoveEvent):
545         (QQuickWebPage::hoverLeaveEvent):
546         (QQuickWebPage::dragMoveEvent):
547         (QQuickWebPage::dragEnterEvent):
548         (QQuickWebPage::dragLeaveEvent):
549         (QQuickWebPage::dropEvent):
550         (QQuickWebPage::geometryChanged):
551         (QQuickWebPage::event):
552         (QQuickWebPage::touchEvent):
553         (QQuickWebPagePrivate::QQuickWebPagePrivate):
554         (QQuickWebPagePrivate::paintToCurrentGLContext):
555         * UIProcess/API/qt/qquickwebpage_p.h:
556         * UIProcess/API/qt/qquickwebpage_p_p.h:
557         * UIProcess/API/qt/qquickwebview.cpp:
558         (QQuickWebViewPrivate::enableMouseEvents):
559         (QQuickWebViewPrivate::disableMouseEvents):
560         (QQuickWebViewPrivate::loadDidCommit):
561         (QQuickWebViewPrivate::didFinishFirstNonEmptyLayout):
562         (QQuickWebViewPrivate::didChangeContentsSize):
563         (QQuickWebViewPrivate::didChangeViewportProperties):
564         (QQuickWebViewPrivate::pageDidRequestScroll):
565         (QQuickWebViewPrivate::updateVisibleContentRectAndScale):
566         (QQuickWebViewPrivate::PostTransitionState::apply):
567         (QQuickWebViewPrivate::setUseTraditionalDesktopBehaviour):
568         (QQuickWebViewExperimental::setUseTraditionalDesktopBehaviour):
569         (QQuickWebViewExperimental::useTraditionalDesktopBehaviour):
570         (QQuickWebView::geometryChanged):
571         (QQuickWebView::focusInEvent):
572         (QQuickWebView::focusOutEvent):
573         * UIProcess/API/qt/qquickwebview_p.h:
574         * UIProcess/API/qt/qquickwebview_p_p.h:
575         * UIProcess/API/qt/qwebviewportinfo.cpp:
576         (QWebViewportInfo::contentsSize):
577         * UIProcess/API/qt/tests/qquickwebview/tst_qquickwebview.cpp:
578         (tst_QQuickWebView::scrollRequest):
579         * UIProcess/qt/QtPinchGestureRecognizer.cpp:
580         (WebKit::QtPinchGestureRecognizer::recognize):
581         * UIProcess/qt/QtViewportInteractionEngine.cpp:
582         (WebKit::QtViewportInteractionEngine::QtViewportInteractionEngine):
583         (WebKit::QtViewportInteractionEngine::setItemRectVisible):
584         (WebKit::QtViewportInteractionEngine::animateItemRectVisible):
585         (WebKit::QtViewportInteractionEngine::event):
586         (WebKit::QtViewportInteractionEngine::wheelEvent):
587         (WebKit::QtViewportInteractionEngine::pagePositionRequest):
588         (WebKit::QtViewportInteractionEngine::computePosRangeForItemAtScale):
589         (WebKit::QtViewportInteractionEngine::ensureContentWithinViewportBoundary):
590         (WebKit::QtViewportInteractionEngine::applyConstraints):
591         (WebKit::QtViewportInteractionEngine::currentCSSScale):
592         (WebKit::QtViewportInteractionEngine::panGestureStarted):
593         (WebKit::QtViewportInteractionEngine::panGestureRequestUpdate):
594         (WebKit::QtViewportInteractionEngine::panGestureEnded):
595         (WebKit::QtViewportInteractionEngine::pinchGestureStarted):
596         (WebKit::QtViewportInteractionEngine::pinchGestureRequestUpdate):
597         (WebKit::QtViewportInteractionEngine::scaleContent):
598         * UIProcess/qt/QtViewportInteractionEngine.h:
599         * UIProcess/qt/QtWebPageEventHandler.cpp:
600         (QtWebPageEventHandler::handleEvent):
601         (QtWebPageEventHandler::handleMouseMoveEvent):
602         (QtWebPageEventHandler::handleMousePressEvent):
603         (QtWebPageEventHandler::handleMouseReleaseEvent):
604         (QtWebPageEventHandler::handleWheelEvent):
605         (QtWebPageEventHandler::handleHoverLeaveEvent):
606         (QtWebPageEventHandler::handleHoverMoveEvent):
607         (QtWebPageEventHandler::handleDragEnterEvent):
608         (QtWebPageEventHandler::handleDragMoveEvent):
609         (QtWebPageEventHandler::handleDropEvent):
610         (QtWebPageEventHandler::handleSingleTapEvent):
611         (QtWebPageEventHandler::handleDoubleTapEvent):
612         (QtWebPageEventHandler::touchEvent):
613         * UIProcess/qt/QtWebPageEventHandler.h:
614
615 2012-01-04  Tor Arne Vestbø  <tor.arne.vestbo@nokia.com>
616
617         [Qt] Introduce new qmake variable 'WEBKIT' for signaling dependencies
618
619         The custom qmake variable 'WEBKIT' is used for signaling that a
620         target depends in some way on other subproject of the WebKit
621         project. For now this is limited to the set of intermediate
622         libraries: wtf, javascriptcore, webcore, and webkit2.
623
624         This replaces the previous convension of using load(foo) for
625         just include paths, and CONFIG += foo to also link against foo.
626
627         Adding a dependency results in additional include paths being
628         available, and potentially linking to the library. This is
629         decided by the build system based on conditions such as what
630         kind of target is being built and the general build config.
631
632         An advantage to his approach is that it simplifies the individual
633         foo.prf files, for example by allowing us to use INCLUDEPATH +=
634         and LIBS += as normal instead of prepending.
635
636         Reviewed by Simon Hausmann.
637
638         * Target.pri:
639         * UIProcess/API/qt/tests/qmltests/qmltests.pro:
640
641 2012-01-03  Andras Becsi  <andras.becsi@nokia.com>
642
643         [Qt][WK2] Pinch zoom should affect the page size
644         https://bugs.webkit.org/show_bug.cgi?id=74601
645
646         Reviewed by Kenneth Rohde Christiansen and Simon Hausmann.
647
648         The current implementation uses the scale property of the QQuickWebPage
649         to scale the page in response to pinch gestures.
650         However for layout and anchoring to work correctly in QML, pinching needs
651         to change the page size.
652         This patch applies the pinch scale to the page size and to the transformation
653         matrix of the drawing area.
654         Thus the page item's coordinate system is no longer a direct representation
655         of the WebCore::Page coordinate system and it is no longer suitable as
656         an inertial frame of reference for input events. The event propagation had
657         to be moved to the QQuickWebView and the positions translated to content
658         coordinates when NativeWebEvents are created.
659
660         * Shared/NativeWebMouseEvent.h:
661         * Shared/NativeWebTouchEvent.h:
662         * Shared/NativeWebWheelEvent.h:
663         * Shared/qt/NativeWebMouseEventQt.cpp:
664         (WebKit::NativeWebMouseEvent::NativeWebMouseEvent):
665         * Shared/qt/NativeWebTouchEventQt.cpp:
666         (WebKit::NativeWebTouchEvent::NativeWebTouchEvent):
667         * Shared/qt/NativeWebWheelEventQt.cpp:
668         (WebKit::NativeWebWheelEvent::NativeWebWheelEvent):
669         * Shared/qt/WebEventFactoryQt.cpp:
670         (WebKit::WebEventFactory::createWebMouseEvent):
671         (WebKit::WebEventFactory::createWebWheelEvent):
672         (WebKit::WebEventFactory::createWebTouchEvent):
673         * Shared/qt/WebEventFactoryQt.h:
674         * UIProcess/API/qt/qquickwebpage.cpp:
675         (QQuickWebPage::geometryChanged):
676         (QQuickWebPagePrivate::QQuickWebPagePrivate):
677         (QQuickWebPagePrivate::paintToCurrentGLContext):
678         (QQuickWebPage::usesTraditionalDesktopBehaviour):
679         (QQuickWebPage::setUsesTraditionalDesktopBehaviour):
680         (QQuickWebPage::eventHandler):
681         (QQuickWebPage::setContentSize):
682         (QQuickWebPage::contentSize):
683         (QQuickWebPage::setContentScale):
684         (QQuickWebPage::contentScale):
685         (QQuickWebPage::transformFromItem):
686         (QQuickWebPage::transformToItem):
687         (QQuickWebPagePrivate::updateSize):
688         * UIProcess/API/qt/qquickwebpage_p.h:
689         * UIProcess/API/qt/qquickwebpage_p_p.h:
690         * UIProcess/API/qt/qquickwebview.cpp:
691         (QQuickWebViewPrivate::enableMouseEvents):
692         (QQuickWebViewPrivate::disableMouseEvents):
693         (QQuickWebViewPrivate::loadDidCommit):
694         (QQuickWebViewPrivate::didFinishFirstNonEmptyLayout):
695         (QQuickWebViewPrivate::didChangeContentsSize):
696         (QQuickWebViewPrivate::didChangeViewportProperties):
697         (QQuickWebViewPrivate::pageDidRequestScroll):
698         (QQuickWebViewPrivate::updateVisibleContentRectAndScale):
699         (QQuickWebViewPrivate::PostTransitionState::apply):
700         (QQuickWebViewPrivate::setUseTraditionalDesktopBehaviour):
701         (QQuickWebViewExperimental::setUseTraditionalDesktopBehaviour):
702         (QQuickWebViewExperimental::useTraditionalDesktopBehaviour):
703         (QQuickWebView::mapToWebContent):
704         (QQuickWebView::mapRectToWebContent):
705         (QQuickWebView::mapFromWebContent):
706         (QQuickWebView::mapRectFromWebContent):
707         (QQuickWebView::geometryChanged):
708         (QQuickWebView::keyPressEvent):
709         (QQuickWebView::keyReleaseEvent):
710         (QQuickWebView::inputMethodEvent):
711         (QQuickWebView::focusInEvent):
712         (QQuickWebView::focusOutEvent):
713         (QQuickWebView::touchEvent):
714         (QQuickWebView::mousePressEvent):
715         (QQuickWebView::mouseMoveEvent):
716         (QQuickWebView::mouseReleaseEvent):
717         (QQuickWebView::mouseDoubleClickEvent):
718         (QQuickWebView::wheelEvent):
719         (QQuickWebView::hoverEnterEvent):
720         (QQuickWebView::hoverMoveEvent):
721         (QQuickWebView::hoverLeaveEvent):
722         (QQuickWebView::dragMoveEvent):
723         (QQuickWebView::dragEnterEvent):
724         (QQuickWebView::dragLeaveEvent):
725         (QQuickWebView::dropEvent):
726         (QQuickWebView::event):
727         * UIProcess/API/qt/qquickwebview_p.h:
728         * UIProcess/API/qt/qquickwebview_p_p.h:
729         * UIProcess/API/qt/qwebviewportinfo.cpp:
730         (QWebViewportInfo::contentsSize):
731         * UIProcess/API/qt/tests/qquickwebview/tst_qquickwebview.cpp:
732         (tst_QQuickWebView::scrollRequest):
733         * UIProcess/qt/QtPinchGestureRecognizer.cpp:
734         (WebKit::QtPinchGestureRecognizer::recognize):
735         * UIProcess/qt/QtViewportInteractionEngine.cpp:
736         (WebKit::QtViewportInteractionEngine::QtViewportInteractionEngine):
737         (WebKit::QtViewportInteractionEngine::setItemRectVisible):
738         (WebKit::QtViewportInteractionEngine::animateItemRectVisible):
739         (WebKit::QtViewportInteractionEngine::event):
740         (WebKit::QtViewportInteractionEngine::wheelEvent):
741         (WebKit::QtViewportInteractionEngine::pagePositionRequest):
742         (WebKit::QtViewportInteractionEngine::computePosRangeForItemAtScale):
743         (WebKit::QtViewportInteractionEngine::ensureContentWithinViewportBoundary):
744         (WebKit::QtViewportInteractionEngine::applyConstraints):
745         (WebKit::QtViewportInteractionEngine::currentCSSScale):
746         (WebKit::QtViewportInteractionEngine::panGestureStarted):
747         (WebKit::QtViewportInteractionEngine::panGestureRequestUpdate):
748         (WebKit::QtViewportInteractionEngine::panGestureEnded):
749         (WebKit::QtViewportInteractionEngine::pinchGestureStarted):
750         (WebKit::QtViewportInteractionEngine::pinchGestureRequestUpdate):
751         (WebKit::QtViewportInteractionEngine::scaleContent):
752         * UIProcess/qt/QtViewportInteractionEngine.h:
753         * UIProcess/qt/QtWebPageEventHandler.cpp:
754         (QtWebPageEventHandler::handleEvent):
755         (QtWebPageEventHandler::handleMouseMoveEvent):
756         (QtWebPageEventHandler::handleMousePressEvent):
757         (QtWebPageEventHandler::handleMouseReleaseEvent):
758         (QtWebPageEventHandler::handleWheelEvent):
759         (QtWebPageEventHandler::handleHoverLeaveEvent):
760         (QtWebPageEventHandler::handleHoverMoveEvent):
761         (QtWebPageEventHandler::handleDragEnterEvent):
762         (QtWebPageEventHandler::handleDragMoveEvent):
763         (QtWebPageEventHandler::handleDropEvent):
764         (QtWebPageEventHandler::handleSingleTapEvent):
765         (QtWebPageEventHandler::handleDoubleTapEvent):
766         (QtWebPageEventHandler::touchEvent):
767         * UIProcess/qt/QtWebPageEventHandler.h:
768
769 2012-01-03  Kenneth Rohde Christiansen  <kenneth@webkit.org>
770
771         [Qt] Clean up Qt specific part of editorState()
772
773         Reviewed by Simon Hausmann.
774
775         Use unsigned instead of int.
776         No need to clone the range as we don't modify it.
777         Support selections which include a composition.
778         If we are not in editable content make sure to use the document element
779         as the scope for calculating the positions and lengths.
780         Remove compositionStart/Length as there cannot be a selection and
781         composition at the same time.
782
783         Only tested manually as we don't have everything in place yet
784         to properly test this.
785
786         * Shared/EditorState.h:
787         * WebProcess/WebPage/WebPage.cpp:
788         (WebKit::WebPage::editorState):
789
790 2012-01-04  Mihnea Ovidenie  <mihnea@adobe.com>
791
792         [Mac]Fix build after changeset 103997
793         https://bugs.webkit.org/show_bug.cgi?id=75530
794
795         Reviewed by Andreas Kling.
796
797         * UIProcess/API/mac/WKView.mm:
798
799 2012-01-03  Carlos Garcia Campos  <cgarcia@igalia.com>
800
801         [GTK] Scrollbars are drawn behind the window resize grip
802         https://bugs.webkit.org/show_bug.cgi?id=75384
803
804         Reviewed by Martin Robinson.
805
806         * UIProcess/API/gtk/WebKitWebViewBase.cpp:
807         (webkitWebViewBaseNotifyResizerSizeForWindow): Get the size of the
808         main window resize grip and send it to the page proxy if it
809         overlaps with the view.
810         (toplevelWindowResizeGripVisibilityChanged): Call
811         webkitWebViewBaseNotifyResizerSizeForWindow().
812         (webkitWebViewBaseRealize): Get the toplevel window and connect to
813         notify::resize-grip-visible signal.
814         (webkitWebViewBaseSizeAllocate): Call
815         webkitWebViewBaseNotifyResizerSizeForWindow().
816
817 2012-01-03  Jon Lee  <jonlee@apple.com>
818
819         Leak of WebNotificationClient when page is destroyed
820         https://bugs.webkit.org/show_bug.cgi?id=74980
821         <rdar://problem/10611231>
822
823         Reviewed by Mark Rowe.
824
825         * WebProcess/WebCoreSupport/WebNotificationClient.cpp:
826         (WebKit::WebNotificationClient::notificationControllerDestroyed): Delete the instance.
827         * WebProcess/WebCoreSupport/WebNotificationClient.h:
828
829 2012-01-03  Sam Weinig  <sam@webkit.org>
830
831         Remove unnecessary forward declaration of Function
832         https://bugs.webkit.org/show_bug.cgi?id=75485
833
834         Reviewed by Dan Bernstein.
835
836         * Platform/WorkQueue.h:
837
838 2012-01-03  Carlos Garcia Campos  <cgarcia@igalia.com>
839
840         [GTK] Simplify loader client WebKit2 GTK+ API
841         https://bugs.webkit.org/show_bug.cgi?id=74605
842
843         Reviewed by Gustavo Noronha Silva.
844
845         Remove WebKitWebLoaderClient from public API keeping it as a
846         private object. Loading API has been reduced to two signals in
847         WebKitWebView.
848
849         * GNUmakefile.am: Remove WebKitWebLoaderClientPrivate.h.
850         * UIProcess/API/gtk/WebKitDefines.h: Remove forward delcarations
851         that are no longer needed.
852         * UIProcess/API/gtk/WebKitWebLoaderClient.cpp:
853         (didStartProvisionalLoadForFrame): Emit
854         WebKitWebView::load-changed signal with Started event.
855         (didReceiveServerRedirectForProvisionalLoadForFrame): Emit
856         WebKitWebView::load-changed signal with Redirected event.
857         (didFailProvisionalLoadWithErrorForFrame): Emit
858         WebKitWebView::load-failed signal with Started event.
859         (didCommitLoadForFrame): Emit WebKitWebView::load-changed signal
860         with Committed event.
861         (didFinishLoadForFrame): Emit WebKitWebView::load-changed signal
862         with Finished event.
863         (didFailLoadWithErrorForFrame): Emit WebKitWebView::load-failed
864         signal with Committed event.
865         (webkit_web_loader_client_init):
866         (webkit_web_loader_client_class_init):
867         * UIProcess/API/gtk/WebKitWebLoaderClient.h: Remove public API and
868         move private API here.
869         * UIProcess/API/gtk/WebKitWebLoaderClientPrivate.h: Removed.
870         * UIProcess/API/gtk/WebKitWebView.cpp:
871         (webkitWebViewLoadFail): Default implementation of
872         WebKitWebView::load-failed signal to show a custom error page.
873         (webkit_web_view_class_init): Add load-changed and load-failed
874         signals.
875         (webkitWebViewLoadChanged): Emit WebKitWebView::load-changed with
876         the given event.
877         (webkitWebViewLoadFailed): Emit WebKitWebView::load-failed signal
878         with the given event, failing uri and error.
879         * UIProcess/API/gtk/WebKitWebView.h:
880         * UIProcess/API/gtk/WebKitWebViewPrivate.h:
881         * UIProcess/API/gtk/docs/webkit2gtk-docs.sgml: Remove loader
882         client section.
883         * UIProcess/API/gtk/docs/webkit2gtk-sections.txt: Remove loader
884         client symbols.
885         * UIProcess/API/gtk/docs/webkit2gtk.types: Remove
886         webkit_web_loader_client_get_type.
887         * UIProcess/API/gtk/tests/LoadTrackingTest.cpp:
888         (loadChangedCallback):
889         (loadFailedCallback):
890         (LoadTrackingTest::LoadTrackingTest):
891         (LoadTrackingTest::~LoadTrackingTest):
892         (LoadTrackingTest::provisionalLoadStarted):
893         (LoadTrackingTest::provisionalLoadReceivedServerRedirect):
894         (LoadTrackingTest::provisionalLoadFailed):
895         (LoadTrackingTest::loadCommitted):
896         (LoadTrackingTest::loadFinished):
897         (LoadTrackingTest::loadFailed):
898         * UIProcess/API/gtk/tests/LoadTrackingTest.h:
899         * UIProcess/API/gtk/tests/TestWebKitWebLoaderClient.cpp:
900         (testLoadingError):
901         (LoadStopTrackingTest::loadCommitted):
902         (LoadStopTrackingTest::loadFailed):
903         (testLoadCancelled):
904         * UIProcess/API/gtk/tests/TestWebKitWebView.cpp:
905         (beforeAll):
906         * UIProcess/API/gtk/webkit2.h: Remove loader client header.
907         * UIProcess/API/gtk/webkit2marshal.list:
908
909 2012-01-03  Rafael Brandao  <rafael.lobo@openbossa.org>
910
911         [Qt][WK2] tst_favIconLoad.qml crashes on debug mode
912         https://bugs.webkit.org/show_bug.cgi?id=75448
913
914         Reviewed by Kenneth Rohde Christiansen.
915
916         * UIProcess/API/qt/tests/qmltests/WebView/tst_favIconLoad.qml: Loads
917         "about:blank" instead of an empty url between tests to clean favicon.
918
919 2012-01-02  Dan Bernstein  <mitz@apple.com>
920
921         Fixed a typo I made in r103871.
922
923         Fixes <http://webkit.org/b/75450> Inline PDF doesn't preview correctly when attempting to print its frame
924
925         * WebProcess/WebPage/WebPage.cpp:
926         (WebKit::WebPage::drawRectToPDF): Changed USE(GC) to USE(CG).
927
928 2012-01-02  Andy Estes  <aestes@apple.com>
929
930         Fix the Windows build (again).
931
932         * Platform/CoreIPC/Connection.h:
933
934 2012-01-02  Sam Weinig  <sam@webkit.org>
935
936         Fix windows build.
937
938         * Platform/CoreIPC/Connection.h:
939         * Platform/CoreIPC/win/ConnectionWin.cpp:
940         * Platform/RunLoop.h:
941         Missing declarations/includes of BinarySemaphore.
942
943 2012-01-02  Sam Weinig  <sam@webkit.org>
944
945         Move dispatchSentMessagesUntil out of the RunLoop class.
946         https://bugs.webkit.org/show_bug.cgi?id=75320
947
948         Reviewed by Dan Bernstein.
949
950         * Platform/CoreIPC/Connection.cpp:
951         (CoreIPC::Connection::SyncMessageState::waitWhileDispatchingSentWin32Messages):
952         * Platform/CoreIPC/Connection.h:
953         * Platform/CoreIPC/win/ConnectionWin.cpp:
954         (CoreIPC::Connection::dispatchSentMessagesUntil):
955         * Platform/win/RunLoopWin.cpp:
956
957 2012-01-02  Dan Bernstein  <mitz@apple.com>
958
959         Build fix.
960
961         * Platform/CoreIPC/mac/ConnectionMac.cpp:
962         * Platform/mac/SharedMemoryMac.cpp:
963
964 2012-01-02  Nikolas Zimmermann  <nzimmermann@rim.com>
965
966         Not reviewed. Fix build on Lion, by including mach_error.h in two places that need it.
967
968         * PluginProcess/mac/PluginProcessMainMac.mm:
969         * WebProcess/mac/WebProcessMainMac.mm:
970
971 2012-01-01  Dan Bernstein  <mitz@apple.com>
972
973         EnvironmentUtilities::stripValuesEndingWithString enters an infinite loop if the search value
974         occurs a component other than the first.
975
976         Reviewed by Anders Carlsson.
977
978         * Platform/unix/EnvironmentUtilities.cpp:
979         (WebKit::EnvironmentUtilities::stripValuesEndingWithString): Changed to start the search for
980         the next colon after the current colon.
981
982 2012-01-01  Dan Bernstein  <mitz@apple.com>
983
984         Improved reproting of kernel return codes.
985
986         Reviewed by Anders Carlsson.
987
988         * Platform/CoreIPC/mac/ConnectionMac.cpp:
989         (CoreIPC::Connection::exceptionSourceEventHandler): Added the error string to the log message.
990         * Platform/mac/SharedMemoryMac.cpp:
991         (WebKit::SharedMemory::create): Ditto.
992         * PluginProcess/mac/PluginProcessMainMac.mm:
993         (WebKit::PluginProcessMain): Ditto. Also changed to log to stderr.
994         * WebProcess/mac/WebProcessMainMac.mm:
995         (WebKit::WebProcessMain): Ditto.
996
997 2011-12-31  Dan Bernstein  <mitz@apple.com>
998
999         Continue trying to fix the ASSERT-enabled Windows build after r103858.
1000
1001         * WebProcess/WebPage/WebPage.cpp:
1002         (WebKit::WebPage::drawRectToPDF):
1003         (WebKit::WebPage::drawPagesToPDF):
1004
1005 2011-12-31  Dan Bernstein  <mitz@apple.com>
1006
1007         Start trying to fix the Windows build after r103858.
1008
1009         * WebProcess/WebPage/WebPage.cpp:
1010         (WebKit::drawPDFPage):
1011
1012 2011-12-31  Dan Bernstein  <mitz@apple.com>
1013
1014         <rdar://problem/10463059> Cannot print USPS shipping labels
1015         http://webkit.org/b/72801
1016
1017         Reviewed by Anders Carlsson and Alexey Proskuryakov.
1018
1019         * WebProcess/Plugins/PDF/BuiltInPDFView.cpp:
1020         (appendValuesInPDFNameSubtreeToVector): Copied from WebKit/mac/WebView/WebPDFDocumentExtras.mm.
1021         (getAllValuesInPDFNameTree): Ditto.
1022         (getAllScriptsInPDFDocument): Copied allScriptsInPDFDocument() from WebPDFDocumentExtras.mm
1023         and changed it to append to a Vector<RetainPtr<CFStringRef> >.
1024         (WebKit::BuiltInPDFView::create): Changed to take a WebFrame* rather than a Page*.
1025         (WebKit::BuiltInPDFView::BuiltInPDFView): Ditto. Updated initializer accordingly.
1026         (WebKit::BuiltInPDFView::pdfDocumentDidLoad): Copied and adapted code from
1027         -[WebPDFRepresentation finishedLoadingWithDataSource:] to run scripts from the PDF with a
1028         Doc object as the this object.
1029         (WebKit::BuiltInPDFView::initialize): Adapted for the change from having a Page* to having
1030         a WebFrame*.
1031         (WebKit::BuiltInPDFView::destroy): Ditto.
1032         (WebKit::BuiltInPDFView::isActive): Ditto.
1033         (WebKit::jsPDFDocInitialize): Added. Refs the BuiltInPDFView which is the private object for
1034         this Doc.
1035         (WebKit::jsPDFDocFinalize): Added. Derefs the BuiltInPDFView for this Doc.
1036         (WebKit::BuiltInPDFView::jsPDFDocPrint): Added. Calls WebCore::Chrome::print().
1037         (WebKit::BuiltInPDFView::makeJSPDFDoc): Copied from WebKit/mac/WebView/WebJSPDFDoc.mm and
1038         modified to use this BuiltInPDFView as the private object of the Doc being made.
1039         * WebProcess/Plugins/PDF/BuiltInPDFView.h:
1040         (WebKit::BuiltInPDFView::disconnectFromPage): Adapted for the change from having a Page* to
1041         having a WebFrame*.
1042         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
1043         (WebKit::WebFrameLoaderClient::createPlugin): Pass the WebFrame to WebPage::createPlugin().
1044         * WebProcess/WebPage/WebPage.cpp:
1045         (WebKit::WebPage::createPlugin): Added a WebFrame* parameter, which is used when creating
1046         a BuiltInPDFView.
1047         * WebProcess/WebPage/WebPage.h:
1048
1049 2011-12-31  Dan Bernstein  <mitz@apple.com>
1050
1051         <rdar://problem/8553040> REGRESSION (WebKit2): Safari status text doesn't change when you change the modifier keys without moving the mouse
1052         https://bugs.webkit.org/show_bug.cgi?id=75404
1053
1054         Reviewed by Jon Honeycutt.
1055
1056         * UIProcess/API/mac/WKView.mm:
1057         (-[WKView dealloc]): Remove the flags changed event monitor.
1058         (-[WKView _postFakeMouseMovedEventForFlagsChangedEvent:]): Added. Similarly to
1059         -[WebHTMLView _postFlagsChangedEvent:], creates a mouse moved event and passes it to
1060         -mouseMoved:.
1061         (-[WKView initWithFrame:contextRef:pageGroupRef:]): Create a local event monitor for flags
1062         changed events.
1063
1064 2011-12-31  Dan Bernstein  <mitz@apple.com>
1065
1066         <rdar://problem/8750356> REGRESSION (WebKit2): Printing a subframe containing a PDF prints the on-screen view instead of the entire PDF document
1067         <http://webkit.org/b/75232>
1068
1069         Reviewed by Alexey Proskuryakov.
1070
1071         * UIProcess/API/C/WKPage.cpp:
1072         (WKPageDrawPagesToPDF): Added WKPrintInfo parameter, which is passed through as a PrintInfo
1073         to the WebPageProxy.
1074         * UIProcess/API/C/WKPagePrivate.h:
1075         * UIProcess/API/mac/WKPrintingView.mm:
1076         (-[WKPrintingView _preparePDFDataForPrintingOnSecondaryThread]): Changed to pass the PrintInfo
1077         down to WebPageProxy::drawPagesToPDF.
1078         (-[WKPrintingView _drawPreview:]): Changed to pass the PrintInfo down to
1079         WebPageProxy::drawRectToPDF.
1080         * UIProcess/API/mac/WKView.mm:
1081         (-[WKView canChangeFrameLayout:]): Changed to use WebFrameProxy::isDisplayingPDFDocument, which
1082         works for subframes as well.
1083         (-[WKView printOperationWithPrintInfo:forFrame:]): Added a FIXME.
1084         * UIProcess/WebFrameProxy.cpp:
1085         (WebKit::WebFrameProxy::isDisplayingPDFDocument): Added.
1086         * UIProcess/WebFrameProxy.h:
1087         * UIProcess/WebPageProxy.cpp:
1088         (WebKit::WebPageProxy::drawRectToPDF): Added a PrintInfo parameter, which is passed through to
1089         the Web process.
1090         (WebKit::WebPageProxy::drawPagesToPDF): Ditto.
1091         * UIProcess/WebPageProxy.h:
1092         * WebProcess/Plugins/PDF/BuiltInPDFView.h:
1093         Added an override of pdfDocumentForPrinting() which returns the PDFDocument.
1094         * WebProcess/Plugins/Plugin.h:
1095         (WebKit::Plugin::pdfDocumentForPrinting): Added. This base class implementation returns 0.
1096         * WebProcess/Plugins/PluginView.h:
1097         (WebKit::PluginView::pdfDocumentForPrinting): Added. Calls through to the Plugin.
1098         * WebProcess/WebPage/WebPage.cpp:
1099         (WebKit::pdfDocumentForPrintingFrame): Added this helper function. If the frame is displaying
1100         a plug-in document, allows the plug-in to provide a PDF document for printing.
1101         (WebKit::WebPage::beginPrinting): Added an early return if the frame provides a PDF document
1102         for printing.
1103         (WebKit::WebPage::computePagesForPrinting): If the frame provides a PDF document for printing,
1104         create for each page in the PDF document a page rect with the size available for printing.
1105         (WebKit::drawPDFPage): Added this helper function, which draws a page from the PDF document
1106         into one of the aforementioned page rects. It rotates the PDF page 90 degrees if necessary to
1107         better match the aspect ratio of the paper, then it centers it on the paper. This matches the
1108         behavior of a PDFView when printed with default settings.
1109         (WebKit::WebPage::drawRectToPDF): If the frame provides a PDF document for printing, draw the
1110         PDF pages falling within the requested rect.
1111         (WebKit::WebPage::drawPagesToPDF): If the frame provides a PDF document for printing, draw
1112         the requested pages.
1113         * WebProcess/WebPage/WebPage.h:
1114         * WebProcess/WebPage/WebPage.messages.in: Added a PrintInfo parameter to DrawRectToPDF and
1115         DrawPagesToPDF.
1116
1117 2011-12-30  Dan Bernstein  <mitz@apple.com>
1118
1119         EnvironmentUtilities::stripValuesEndingWithString fails when the variable ends with the search value
1120         https://bugs.webkit.org/show_bug.cgi?id=75389
1121
1122         Reviewed by Anders Carlsson.
1123
1124         * Platform/unix/EnvironmentUtilities.cpp:
1125         (WebKit::EnvironmentUtilities::stripValuesEndingWithString): Fixed an off-by-1 error when
1126         examining the character after the match.
1127
1128 2011-12-29  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>
1129
1130         [Qt] Remove unused m_signalListeners from WorkQueue
1131         https://bugs.webkit.org/show_bug.cgi?id=75354
1132
1133         Reviewed by Andreas Kling.
1134
1135         This is unused since r76507.
1136
1137         * Platform/WorkQueue.h:
1138         * Platform/qt/WorkQueueQt.cpp:
1139         (WorkQueue::platformInvalidate):
1140
1141 2011-12-29  Carlos Garcia Campos  <cgarcia@igalia.com>
1142
1143         [GTK] Context menu is hidden right after showing it when first menu item is not disabled
1144         https://bugs.webkit.org/show_bug.cgi?id=75357
1145
1146         Reviewed by Martin Robinson.
1147
1148         The problem is that we are passing GDK_CURRENT_TIME (which is 0)
1149         to gtk_popup_menu, because the events are async and
1150         gtk_get_current_event is NULL when calling gtk_menu_popup. GtkMenu
1151         has a timeout to decide whether the press-release was fast enough
1152         and ignore the button release event in that case. That way, a
1153         normal right click shows the menu while a long press hides the
1154         menu when the button is released. So, we need to know the real time
1155         when the right button was pressed and pass it to gtk_popup_menu.
1156
1157         * UIProcess/WebPageProxy.h: Make
1158         currentlyProcessedMouseDownEvent() public.
1159         * UIProcess/gtk/WebContextMenuProxyGtk.cpp:
1160         (WebKit::WebContextMenuProxyGtk::showContextMenu): Use
1161         WebPageProxy::currentlyProcessedMouseDownEvent() to get the
1162         current mouse event and pass its button number and time to
1163         gtk_popup_menu.
1164
1165 2011-12-29  Carlos Garcia Campos  <cgarcia@igalia.com>
1166
1167         [GTK] Fix several conding style issues in WebKit2 GTK+ code
1168         https://bugs.webkit.org/show_bug.cgi?id=75339
1169
1170         Reviewed by Martin Robinson.
1171
1172         In addition to the WebKit coding style, code in UIProcess/API/gtk
1173         should follow style and conventions described here
1174         http://trac.webkit.org/wiki/WebKitGTK/AddingNewWebKit2API
1175
1176         * UIProcess/API/gtk/WebKitSettings.cpp: Remove trailing whitespaces.
1177         (webkit_settings_class_init): Remove trailing whitespaces, fix
1178         indentation issues in API doc comments, add missing trailing to
1179         some properties.
1180         (webkit_settings_set_enable_fullscreen): Move the code after
1181         get_enable_fullscreen() for consistency.
1182         * UIProcess/API/gtk/WebKitSettings.h: Remove trailing
1183         whitespaces. Fix * placement and line up parameters.
1184         * UIProcess/API/gtk/WebKitWebView.cpp: Remove several empty lines.
1185         (webkit_web_view_class_init): Mark property nicks and blurbs for translation.
1186         (webkitWebViewSetTitle): Remove trailing whitespaces.
1187         * UIProcess/API/gtk/WebKitWebView.h: Line up parameters.
1188         * UIProcess/API/gtk/WebKitWebViewBase.cpp: Use the angle-bracket
1189         form for including file from WebCore and wtf. Use GRefPtr for
1190         GtkIMContext and bool instead of gboolean. Use the placement new
1191         syntax for private struct instead of new/delete.
1192         (webkitWebViewBaseRealize):
1193         (webkitWebViewBaseFinalize):
1194         (webkit_web_view_base_init):
1195         (webkitWebViewBaseFocusInEvent):
1196         (webkitWebViewBaseFocusOutEvent):
1197         (webkitWebViewBaseKeyPressEvent): Remove trailing whitespaces.
1198         (webkitWebViewBaseKeyReleaseEvent):
1199         (webkit_web_view_base_class_init):
1200         (webkitWebViewBaseGetIMContext):
1201
1202 2011-12-28  Balazs Kelemen  <kbalazs@webkit.org>
1203
1204         [Qt][WK2] Crash in ~WebGraphicsLayer when running fast/multicol/pagination-* tests
1205         https://bugs.webkit.org/show_bug.cgi?id=75000
1206
1207         Reviewed by Noam Rosenthal.
1208
1209         Don't adopt a tile client that belongs to a parent layer.
1210         This is unnecessary and also unsafe because we can live
1211         through that client.
1212
1213         * WebProcess/WebCoreSupport/WebGraphicsLayer.cpp:
1214         (WebCore::WebGraphicsLayer::syncCompositingStateForThisLayerOnly):
1215
1216 2011-12-27  Dan Bernstein  <mitz@apple.com>
1217
1218         [mac] Stop using bootstrap_look_up2
1219         https://bugs.webkit.org/show_bug.cgi?id=75280
1220
1221         Reviewed by Mark Rowe.
1222
1223         * PluginProcess/mac/PluginProcessMainMac.mm:
1224         (WebKit::PluginProcessMain): Changed to use bootstrap_look_up() instead of
1225         bootstrap_look_up2().
1226         * WebProcess/mac/WebProcessMainMac.mm:
1227         (WebKit::WebProcessMain): Ditto.
1228
1229 2011-12-27  Kenneth Rohde Christiansen  <kenneth@webkit.org>
1230
1231         [Qt] Make the inputMethodEvent set or confirm the composition
1232         https://bugs.webkit.org/show_bug.cgi?id=75256
1233
1234         Reviewed by Chang Shu.
1235
1236         * UIProcess/qt/QtWebPageEventHandler.cpp:
1237         (QtWebPageEventHandler::inputMethodEvent):
1238
1239 2011-12-26  Mark Rowe  <mrowe@apple.com>
1240
1241         <http://webkit.org/b/75196> REGRESSION(r103643): Command-clicking a link no longer opens a new tab.
1242
1243         r103643 contained some botched copy-paste code that caused the state of the Command key
1244         to be lost when translating from a WebKit2 event to a WebCore event.
1245
1246         Reviewed by Dan Bernstein.
1247
1248         * Shared/WebEventConversion.cpp:
1249         (WebKit::WebKit2PlatformMouseEvent::WebKit2PlatformMouseEvent): Test for the correct modifier.
1250         (WebKit::WebKit2PlatformWheelEvent::WebKit2PlatformWheelEvent): Ditto.
1251         (WebKit::WebKit2PlatformKeyboardEvent::WebKit2PlatformKeyboardEvent): Ditto.
1252         (WebKit::WebKit2PlatformGestureEvent::WebKit2PlatformGestureEvent): Ditto.
1253         (WebKit::WebKit2PlatformTouchEvent::WebKit2PlatformTouchEvent): Ditto.
1254
1255 2011-12-26  Carlos Garcia Campos  <cgarcia@igalia.com>
1256
1257         Fix a crash in WebProcess when starting a download not initiated by a WebPage
1258         https://bugs.webkit.org/show_bug.cgi?id=75225
1259
1260         Reviewed by Darin Adler.
1261
1262         * WebProcess/WebProcess.cpp:
1263         (WebKit::WebProcess::downloadRequest): Check initiatingPage is not
1264         NULL before using it.
1265
1266 2011-12-25  Dan Bernstein  <mitz@apple.com>
1267
1268         Find indicators overlap when a match spans multiple text boxes
1269         https://bugs.webkit.org/show_bug.cgi?id=75220
1270
1271         Reviewed by Darin Adler.
1272
1273         * UIProcess/FindIndicator.cpp:
1274         (WebKit::findIndicatorsForTextRectsOverlap): Added this helper function that checks for
1275         pairwise intersections between all indicator rects.
1276         (WebKit::FindIndicator::FindIndicator): Changed to use a single rect (the union of all text
1277         rects) if any two indicator rects would otherwise overlap. This is similar to what Safari
1278         does, and it eliminates overlapping rects for adjacent text boxes. In rare cases (such as when
1279         a match spans two lines and adjacent text boxes on one of those lines) it results in a find
1280         indicator that is too large and obscures some non-match text.
1281         * UIProcess/FindIndicator.h:
1282
1283 2011-12-21  Sam Weinig  <sam@webkit.org>
1284
1285         Start extracting platform specific bits out of PlatformEvents
1286         https://bugs.webkit.org/show_bug.cgi?id=75063
1287
1288         Reviewed by Anders Carlsson.
1289
1290         * Shared/WebEventConversion.cpp:
1291         (WebKit::WebKit2PlatformMouseEvent::WebKit2PlatformMouseEvent):
1292         (WebKit::WebKit2PlatformWheelEvent::WebKit2PlatformWheelEvent):
1293         (WebKit::WebKit2PlatformKeyboardEvent::WebKit2PlatformKeyboardEvent):
1294         (WebKit::WebKit2PlatformGestureEvent::WebKit2PlatformGestureEvent):
1295         (WebKit::WebKit2PlatformTouchEvent::WebKit2PlatformTouchEvent):
1296         * UIProcess/API/mac/WKView.mm:
1297         * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
1298         (InitWebCoreSystemInterface):
1299
1300 2011-12-22  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>
1301
1302         [Qt] [WK2] Use HashMap instead of Vector in the builtin bundle
1303         https://bugs.webkit.org/show_bug.cgi?id=75112
1304
1305         Reviewed by Andreas Kling.
1306
1307         Fix my own FIXME now that HashMap have support to hold OwnPtr as value.
1308
1309         * WebProcess/qt/QtBuiltinBundle.cpp:
1310         (WebKit::QtBuiltinBundle::didCreatePage):
1311         (WebKit::QtBuiltinBundle::willDestroyPage):
1312         (WebKit::QtBuiltinBundle::handleMessageToNavigatorQtObject):
1313         (WebKit::QtBuiltinBundle::handleSetNavigatorQtObjectEnabled):
1314         * WebProcess/qt/QtBuiltinBundle.h:
1315
1316 2011-12-22  Anders Carlsson  <andersca@apple.com>
1317
1318         Remove the last of the WebKit2 display throttling
1319         https://bugs.webkit.org/show_bug.cgi?id=75109
1320
1321         Reviewed by Adam Roben.
1322
1323         The code to do display throttling in WebKit2 is complex and doesn't really help us except
1324         on an old benchmark that's no longer representative of real-world behavior; let's rip it out instead.
1325
1326         * WebProcess/WebPage/DrawingAreaImpl.cpp:
1327         (WebKit::DrawingAreaImpl::DrawingAreaImpl):
1328         (WebKit::DrawingAreaImpl::displayTimerFired):
1329         (WebKit::DrawingAreaImpl::display):
1330         * WebProcess/WebPage/DrawingAreaImpl.h:
1331         * WebProcess/WebPage/WebPage.cpp:
1332         (WebKit::WebPage::wheelEvent):
1333         (WebKit::WebPage::wheelEventSyncForTesting):
1334
1335 2011-12-22  Anders Carlsson  <andersca@apple.com>
1336
1337         Get rid of didStartAnimatedScroll and didCompleteAnimatedScroll
1338         https://bugs.webkit.org/show_bug.cgi?id=75107
1339
1340         Reviewed by Adam Roben.
1341
1342         This is another step towards removing the display throttling in WebKit2.
1343
1344         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
1345         (WebKit::WebChromeClient::dispatchViewportPropertiesDidChange):
1346         * WebProcess/WebCoreSupport/WebChromeClient.h:
1347
1348 2011-12-22  Anders Carlsson  <andersca@apple.com>
1349
1350         Remove didStartRubberBand and didCompleteRubberBand callbacks
1351         https://bugs.webkit.org/show_bug.cgi?id=75102
1352
1353         Reviewed by Adam Roben.
1354
1355         The code to do display throttling in WebKit2 is complex and doesn't really help us except
1356         on an old benchmark that's no longer representative of real-world behavior; let's rip it out instead.
1357
1358         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
1359         * WebProcess/WebCoreSupport/WebChromeClient.h:
1360
1361 2011-12-22  Ryuan Choi <ryuan.choi@samsung.com>, Tomasz Morawski <t.morawski@samsung.com>
1362
1363         [EFL][WK2] Add an option to build WebKit2.
1364         https://bugs.webkit.org/show_bug.cgi?id=61999
1365
1366         Reviewed by Eric Seidel.
1367
1368         Add build script for WebKit2 on EFL port.
1369
1370         * CMakeLists.txt:
1371         * PlatformEfl.cmake: Added.
1372
1373 2011-12-21  Eunmi Lee  <eunmi15.lee@samsung.com>
1374
1375         [EFL][WK2] Add efl port's ewk_view files
1376         https://bugs.webkit.org/show_bug.cgi?id=61915
1377
1378         Reviewed by Eric Seidel.
1379
1380         This is the initial version of WebKit2 EFL port's ewk_view.
1381         The ewk_view is Evas_Object to show the rendered web contents.
1382
1383         * UIProcess/API/efl/ewk_view.cpp: Added.
1384         (_ewk_view_smart_changed):
1385         (_ewk_view_smart_focus_in):
1386         (_ewk_view_smart_focus_out):
1387         (_ewk_view_smart_mouse_wheel):
1388         (_ewk_view_smart_mouse_down):
1389         (_ewk_view_smart_mouse_up):
1390         (_ewk_view_smart_mouse_move):
1391         (_ewk_view_smart_key_down):
1392         (_ewk_view_smart_key_up):
1393         (_ewk_view_on_focus_in):
1394         (_ewk_view_on_focus_out):
1395         (_ewk_view_on_mouse_wheel):
1396         (_ewk_view_on_mouse_down):
1397         (_ewk_view_on_mouse_up):
1398         (_ewk_view_on_mouse_move):
1399         (_ewk_view_on_key_down):
1400         (_ewk_view_on_key_up):
1401         (_ewk_view_priv_new):
1402         (_ewk_view_priv_del):
1403         (_ewk_view_smart_add):
1404         (_ewk_view_smart_del):
1405         (_ewk_view_smart_resize):
1406         (_ewk_view_smart_move):
1407         (_ewk_view_smart_calculate):
1408         (_ewk_view_smart_show):
1409         (_ewk_view_smart_hide):
1410         (ewk_view_smart_class_init):
1411         (_ewk_view_smart_class_new):
1412         (ewk_view_add):
1413         (ewk_view_page_get):
1414         * UIProcess/API/efl/ewk_view.h: Added.
1415
1416 2011-12-21  Timothy Hatcher  <timothy@apple.com>
1417
1418         Web Inspector: suppress incremental rendering and use application chrome mode
1419
1420         https://webkit.org/b/75026
1421
1422         Reviewed by Joseph Pecoraro.
1423
1424         * UIProcess/WebInspectorProxy.cpp:
1425         (WebKit::createInspectorPageGroup): Set suppress incremental rendering and use application chrome mode.
1426
1427 2011-12-21  Sam Weinig  <sam@webkit.org>
1428
1429         Cleanup up clients when deallocating WebKit2 API objects
1430         https://bugs.webkit.org/show_bug.cgi?id=75014
1431
1432         Reviewed by Adam Roben.
1433
1434         * UIProcess/API/mac/WKBrowsingContextController.mm:
1435         (-[WKBrowsingContextController dealloc]):
1436         * UIProcess/API/mac/WKConnection.mm:
1437         (-[WKConnection dealloc]):
1438         Clear clients on dealloc.
1439
1440 2011-12-21  Rafael Brandao  <rafael.lobo@openbossa.org>
1441
1442         [Qt][WK2] Add tests for favicon and fix icon url decoding issue
1443         https://bugs.webkit.org/show_bug.cgi?id=74967
1444
1445         Reviewed by Simon Hausmann.
1446
1447         * UIProcess/API/qt/qwebiconimageprovider.cpp: We already receive the url
1448         without the percent encoding and we should access WebIconDatabase with
1449         an encoded url. Added a test to cover this behavior.
1450         (QWebIconImageProvider::requestImage):
1451         * UIProcess/API/qt/tests/qmltests/WebView/tst_favIconLoad.qml: Added.
1452         * UIProcess/API/qt/tests/qmltests/common/favicon.html: Added.
1453         * UIProcess/API/qt/tests/qmltests/common/favicon.png: Added.
1454         * UIProcess/API/qt/tests/qmltests/common/favicon2.html: Added.
1455         * UIProcess/API/qt/tests/qmltests/common/small-favicon.png: Added.
1456         * UIProcess/API/qt/tests/qmltests/qmltests.pro:
1457
1458 2011-12-21  Sam Weinig  <sam@webkit.org>
1459
1460         Exception thrown when running WKBrowsingContextLoadDelegateTest.SimpleLoad test
1461         https://bugs.webkit.org/show_bug.cgi?id=75012
1462
1463         Reviewed by Adam Roben.
1464
1465         * UIProcess/API/mac/WKProcessGroup.mm:
1466         (-[WKProcessGroup dealloc]):
1467         Clear the WKContext's connection client.
1468
1469 2011-12-21  Michael Brüning  <michael.bruning@nokia.com>
1470
1471         [Qt][WK2] Fix tst_QQuickWebView::scrollRequest() API test
1472         https://bugs.webkit.org/show_bug.cgi?id=73994
1473
1474         Reviewed by Kenneth Rohde Christiansen.
1475
1476         Added a viewport meta tag so that the view is actually scrollable and
1477         does not get scaled to not be scrollable. Corrected the style
1478         definition for the <div> tag. Removed unneeded text in div
1479
1480         Rolled back changes some of the changes from the previous patch
1481         (r102453) because they weren't necessary.
1482
1483         * UIProcess/API/qt/tests/html/scroll.html:
1484         * UIProcess/API/qt/tests/qquickwebview/tst_qquickwebview.cpp:
1485         (tst_QQuickWebView::scrollRequest): Partially rolled back changes.
1486
1487 2011-12-21  Jessie Berlin  <jberlin@apple.com>
1488
1489         Windows build fix.
1490
1491         Replace all instances of "WebPropupMenuProxy" with "WebPopupMenuProxy".
1492
1493         * UIProcess/win/WebPopupMenuProxyWin.cpp:
1494         (WebKit::WebPopupMenuProxyWin::showPopupMenu):
1495         (WebKit::WebPopupMenuProxyWin::setFocusedIndex):
1496
1497 2011-12-20  Anders Carlsson  <andersca@apple.com>
1498
1499         Add ScrollableArea::contentsResized and have it call the scroll animator
1500         https://bugs.webkit.org/show_bug.cgi?id=74966
1501
1502         Reviewed by Sam Weinig.
1503
1504         * WebProcess/Plugins/PDF/BuiltInPDFView.cpp:
1505         (WebKit::BuiltInPDFView::scrollbarStyleChanged):
1506
1507 2011-12-20  Anders Carlsson  <andersca@apple.com>
1508
1509         Try to fix the Windows build.
1510
1511         * UIProcess/win/WebPopupMenuProxyWin.cpp:
1512         (WebKit::WebPopupMenuProxyWin::showPopupMenu):
1513         (WebKit::WebPopupMenuProxyWin::setFocusedIndex):
1514
1515 2011-12-20  Simon Hausmann  <simon.hausmann@nokia.com>
1516
1517         [Qt][WK2] Remove statusBarMessageChanged
1518         https://bugs.webkit.org/show_bug.cgi?id=74405
1519
1520         Reviewed by Tor Arne Vestbø.
1521
1522         Removing support for window.status updates from the public
1523         QML API. See bug for details.
1524
1525         * UIProcess/API/qt/qquickwebview_p.h:
1526         * UIProcess/qt/QtWebPageUIClient.cpp:
1527         (QtWebPageUIClient::QtWebPageUIClient):
1528         * UIProcess/qt/QtWebPageUIClient.h:
1529
1530 2011-12-20  Anders Carlsson  <andersca@apple.com>
1531
1532         Add ScrollableArea wrappers for a bunch of ScrollAnimator member functions
1533         https://bugs.webkit.org/show_bug.cgi?id=74951
1534
1535         Reviewed by Sam Weinig.
1536
1537         * WebProcess/Plugins/PDF/BuiltInPDFView.cpp:
1538         (WebKit::BuiltInPDFView::paint):
1539         (WebKit::BuiltInPDFView::handleMouseEvent):
1540         (WebKit::BuiltInPDFView::handleMouseEnterEvent):
1541         (WebKit::BuiltInPDFView::handleMouseLeaveEvent):
1542
1543 2011-12-20  Brent Fulgham  <bfulgham@webkit.org>
1544
1545         [WinCairo] Unreviewed build fix.
1546
1547         * win/WebKit2CFLite.def: Add missing export declaration.
1548
1549 2011-12-20  Simon Hausmann  <simon.hausmann@nokia.com>
1550
1551         [Qt] Build fix for gcc used on WK2 build bot.
1552
1553         * UIProcess/qt/QtWebPagePolicyClient.cpp:
1554         (QtWebPagePolicyClient::decidePolicyForNavigationAction): Don't do case:
1555         with values outside the range of the type. Instead switch() on the int instead.
1556
1557 2011-12-20  Rafael Brandao  <rafael.lobo@openbossa.org>
1558
1559         [Qt] Extend QQuickWebview::navigationRequested API
1560         https://bugs.webkit.org/show_bug.cgi?id=73818
1561
1562         Reviewed by Simon Hausmann.
1563
1564         Added url of the originating frame on QWebNavigationRequest,
1565         accessible via 'request.originatingUrl' on QML. Download action
1566         was moved to experimental, so in order to use it you should set
1567         'request.action = WebViewExperimental.DownloadRequest' on QML.
1568
1569         * UIProcess/API/qt/qquickwebview_p.h:
1570         * UIProcess/API/qt/qwebnavigationrequest.cpp:
1571         (QWebNavigationRequestPrivate::QWebNavigationRequestPrivate):
1572         (QWebNavigationRequest::QWebNavigationRequest):
1573         (QWebNavigationRequest::originatingUrl):
1574         * UIProcess/API/qt/qwebnavigationrequest_p.h:
1575         * UIProcess/API/qt/tests/qmltests/DesktopBehavior/tst_navigationRequested.qml:
1576         Tests were modified a bit to reuse urls and also added a test case to check
1577         originating url once a request is done.
1578         * UIProcess/qt/QtWebPagePolicyClient.cpp:
1579         (QtWebPagePolicyClient::decidePolicyForNavigationAction):
1580         * UIProcess/qt/QtWebPagePolicyClient.h:
1581
1582 2011-12-20  Balazs Kelemen  <kbalazs@webkit.org>
1583
1584         [Qt] WK2 Debugging quirks need some improvement
1585         https://bugs.webkit.org/show_bug.cgi?id=74859
1586
1587         Reviewed by Simon Hausmann.
1588
1589         Improvements added to make debugging WebKit2 more
1590         confortable and efficient:
1591         1. Unify debugging quirks. From now all of them are controlled
1592         by the QT_WEBKIT2_DEBUG environment variable.
1593         2. Disable crash handlers for WebKitTestRunner if debugging quirks
1594         are used to make it possible to use postmortem debugging via core dumps
1595         which is extremely useful for debugging bugs triggered by layout tests.
1596         3. Disable test timeout for WebKitTestRunner if debugging quirks
1597         are used because that makes debugging impossible.
1598
1599         * UIProcess/Launcher/qt/ProcessLauncherQt.cpp:
1600         (WebKit::QtWebProcess::setupChildProcess):
1601         * WebProcess/qt/WebProcessMainQt.cpp:
1602         (WebKit::WebProcessMainQt):
1603
1604 2011-12-20  Jesus Sanchez-Palencia  <jesus.palencia@openbossa.org>
1605
1606         [Qt][WK2]REGRESSION(r103310): It broke tst_QQuickWebView::loadNonexistentFileUrl() API test
1607         https://bugs.webkit.org/show_bug.cgi?id=74923
1608
1609         Rubber-stamped by Csaba Osztrogonác.
1610
1611         Fixing API usage after http://trac.webkit.org/changeset/103310.
1612
1613         * UIProcess/API/qt/tests/qquickwebview/tst_qquickwebview.cpp:
1614         (tst_QQuickWebView::loadNonexistentFileUrl):
1615
1616 2011-12-20  Simon Hausmann  <simon.hausmann@nokia.com>
1617
1618         [Qt] Favicon support should work with multiple web contexts
1619         https://bugs.webkit.org/show_bug.cgi?id=74922
1620
1621         Reviewed by Tor Arne Vestbø.
1622
1623         * UIProcess/API/qt/qquickwebview.cpp:
1624         (QQuickWebViewPrivate::initialize): Remove unnecessary use of QtWebContext::defaultContext(). There is
1625         already a member variable "context" which is the correct one.
1626         (QQuickWebViewPrivate::setIcon): Ditto.
1627         * UIProcess/API/qt/qwebiconimageprovider.cpp:
1628         (QWebIconImageProvider::requestImage): Extract the context id from the image id and use it to
1629         query the correct icon database.
1630         * UIProcess/qt/QtWebContext.cpp: Provide a mapping from id to qtwebcontext.
1631         (WebKit::generateContextID):
1632         (WebKit::QtWebContext::QtWebContext):
1633         (WebKit::QtWebContext::~QtWebContext):
1634         (WebKit::QtWebContext::contextByID):
1635         (WebKit::QtWebContext::initialize):
1636         * UIProcess/qt/QtWebContext.h:
1637         (WebKit::QtWebContext::context):
1638         (WebKit::QtWebContext::contextID):
1639         * UIProcess/qt/QtWebIconDatabaseClient.cpp:
1640         (QtWebIconDatabaseClient::QtWebIconDatabaseClient):
1641         (QtWebIconDatabaseClient::requestIconForPageURL): Store the context id in the icon url.
1642         * UIProcess/qt/QtWebIconDatabaseClient.h:
1643
1644 2011-12-20  Rafael Brandao  <rafael.lobo@openbossa.org>
1645
1646         [Qt][WK2] Implement favicon support
1647         https://bugs.webkit.org/show_bug.cgi?id=71082
1648
1649         Reviewed by Simon Hausmann.
1650
1651         Added attribute to QQuickWebView named "icon" that should be used
1652         as source for QQuickImage in order to display it. All images
1653         pointing to it will refresh when the icon is ready. We also use IDs
1654         to make it possible to handle different icons for the same page URL
1655         at different times (i.e. dynamically changing favicon).
1656
1657         IconDatabase storage lies on UIProcess and the synchronous call for
1658         the icon that happens on WebIconDatabase won't need to send any message
1659         to WebProcess. The part of IconDatabase on WebProcess handles the download
1660         of the resource whenever it is needed. Then the content downloaded is sent
1661         through IPC to the actual database, on UIProcess.
1662
1663         * Target.pri:
1664         * UIProcess/API/qt/qquickwebview.cpp:
1665         (QQuickWebViewPrivate::initialize):
1666         (QQuickWebViewPrivate::_q_onIconChangedForPageURL):
1667         (QQuickWebViewPrivate::setIcon):
1668         (QQuickWebView::icon):
1669         * UIProcess/API/qt/qquickwebview_p.h:
1670         * UIProcess/API/qt/qquickwebview_p_p.h:
1671         * UIProcess/API/qt/qwebiconimageprovider.cpp: Added.
1672         (QWebIconImageProvider::QWebIconImageProvider):
1673         (QWebIconImageProvider::~QWebIconImageProvider):
1674         (QWebIconImageProvider::requestImage):
1675         * UIProcess/API/qt/qwebiconimageprovider_p.h: Added.
1676         * UIProcess/WebContext.h:
1677         * UIProcess/WebIconDatabase.cpp:
1678         (WebKit::WebIconDatabase::synchronousIconURLForPageURL):
1679         (WebKit::WebIconDatabase::imageForPageURL): Added iconSize parameter
1680         and a default value for it to not break the old usage. The support for
1681         multiple sizes of favicons is still missing on WebCore.
1682         * UIProcess/WebIconDatabase.h:
1683         * UIProcess/qt/QtWebContext.cpp:
1684         (WebKit::QtWebContext::initialize):
1685         * UIProcess/qt/QtWebContext.h:
1686         (WebKit::QtWebContext::iconDatabase):
1687         * UIProcess/qt/QtWebIconDatabaseClient.cpp: Added.
1688         (toQtWebIconDatabaseClient):
1689         (QtWebIconDatabaseClient::QtWebIconDatabaseClient):
1690         (QtWebIconDatabaseClient::~QtWebIconDatabaseClient):
1691         (QtWebIconDatabaseClient::didChangeIconForPageURL):
1692         (QtWebIconDatabaseClient::iconImageForPageURL):
1693         (QtWebIconDatabaseClient::iconURLHashForPageURL):
1694         (QtWebIconDatabaseClient::requestIconForPageURL):
1695         (QtWebIconDatabaseClient::retainIconForPageURL):
1696         (QtWebIconDatabaseClient::releaseIconForPageURL):
1697         * UIProcess/qt/QtWebIconDatabaseClient.h: Added.
1698         * UIProcess/qt/QtWebPageLoadClient.cpp:
1699         (QtWebPageLoadClient::didStartProgress):
1700
1701 2011-12-20  Jesus Sanchez-Palencia  <jesus.palencia@openbossa.org>
1702
1703         [Qt] Improve QQuickWebView error handling API
1704         https://bugs.webkit.org/show_bug.cgi?id=73815
1705
1706         Reviewed by Simon Hausmann.
1707
1708         Modifying loadFail signal to include the error description
1709         and changing the ErrorType enum to ErrorDomain, to stay aligned
1710         with ResourceError API itself.
1711
1712         * UIProcess/API/qt/qquickwebview_p.h:
1713         * UIProcess/API/qt/tests/qmltests/WebView/tst_loadFail.qml:
1714         * UIProcess/qt/QtWebPageLoadClient.cpp:
1715         (QtWebPageLoadClient::dispatchLoadFailed):
1716
1717 2011-12-19  Sam Weinig  <sam@webkit.org>
1718
1719         Add support for scrollLineDown: and scrollLineUp: NSResponder selectors
1720         https://bugs.webkit.org/show_bug.cgi?id=74907
1721
1722         Reviewed by Dan Bernstein.
1723
1724         * UIProcess/API/mac/WKView.mm:
1725         Add implementations for scrollLineDown: and scrollLineUp: using our
1726         fun macros.
1727
1728 2011-12-19  Sam Weinig  <sam@webkit.org>
1729
1730         More PlatformEvent cleanup
1731         https://bugs.webkit.org/show_bug.cgi?id=74831
1732
1733         Reviewed by Dan Bernstein.
1734
1735         * WebProcess/WebPage/WebPage.cpp:
1736         (WebKit::handleContextMenuEvent):
1737         Update to use new names, access style.
1738
1739 2011-12-16  Jon Lee  <jonlee@apple.com>
1740
1741         [WK2] Extend show notification API to include the source page
1742         https://bugs.webkit.org/show_bug.cgi?id=74751
1743         <rdar://problem/10514541>
1744
1745         Reviewed by John Sullivan.
1746
1747         We add the source page that dispatched the notification in the API for convenience. In order to include the page,
1748         we move the show() message sent by WebNotificationManager from WebNotificationManagerProxy to WebPageProxy.
1749
1750         * WebProcess/Notifications/WebNotificationManager.cpp:
1751         (WebKit::WebNotificationManager::show): We aim the message at WebPageProxy instead of WebNotificationManagerProxy.
1752
1753         * UIProcess/Notifications/WebNotificationManagerProxy.messages.in: Remove the show() message.
1754         * UIProcess/WebPageProxy.messages.in: Add a showNotification() message.
1755
1756         * UIProcess/Notifications/WebNotificationManagerProxy.cpp:
1757         (WebKit::WebNotificationManagerProxy::show): This function is now called from the WebPageProxy.
1758         * UIProcess/Notifications/WebNotificationManagerProxy.h:
1759
1760         * UIProcess/API/C/WKNotificationProvider.h:
1761         * UIProcess/Notifications/WebNotificationProvider.cpp:
1762         (WebKit::WebNotificationProvider::show):
1763         * UIProcess/Notifications/WebNotificationProvider.h:
1764         * UIProcess/WebPageProxy.cpp:
1765         (WebKit::WebPageProxy::showNotification):
1766         * UIProcess/WebPageProxy.h:
1767
1768 2011-12-19  Jesus Sanchez-Palencia  <jesus.palencia@openbossa.org>
1769
1770         [Qt][WK2] QWebDownloadItems are leaking
1771         https://bugs.webkit.org/show_bug.cgi?id=74618
1772
1773         Reviewed by Kenneth Rohde Christiansen.
1774
1775         QWebDownloadItems are leaking when WebProcess raises a
1776         download failure before sending didReceiveResponse back to UIProcess.
1777         This can happen when QtFileDownloader fails in determineFilename(), for instance.
1778         It happens when QtDownloadManager::downloadFailed() is reached
1779         and has an "empty" downloadItem, which means we never got to
1780         QtDownloadManager::downloadReceivedResponse(). At this point
1781         QQuickWebView::downloadRequested() signal hasn't been emitted and
1782         the downloadItem will have null parent. Therefore, it will leak
1783         unless we delete it ourselves.
1784
1785         * UIProcess/qt/QtDownloadManager.cpp:
1786         (WebKit::QtDownloadManager::downloadFailed):
1787
1788 2011-12-19  Anders Carlsson  <andersca@apple.com>
1789
1790         Send gesture events through the event dispatcher and scrolling coordinator
1791         https://bugs.webkit.org/show_bug.cgi?id=74879
1792
1793         Reviewed by Andreas Kling.
1794
1795         * UIProcess/WebPageProxy.cpp:
1796         (WebKit::WebPageProxy::handleGestureEvent):
1797         Use the EventDispatcher message.
1798
1799         * WebProcess/WebPage/EventDispatcher.cpp:
1800         (WebKit::EventDispatcher::gestureEvent):
1801         Try to send the event to the scrolling coordinator first before dispatching it on the main thread.
1802
1803         (WebKit::EventDispatcher::dispatchGestureEvent):
1804         Just call through to the WebPageProxy.
1805
1806         * WebProcess/WebPage/EventDispatcher.h:
1807         * WebProcess/WebPage/EventDispatcher.messages.in:
1808         * WebProcess/WebPage/WebPage.h:
1809         * WebProcess/WebPage/WebPage.messages.in:
1810         Move the GestureEvent message from WebPage to EventDispatcher.
1811
1812 2011-12-19  Jesus Sanchez-Palencia  <jesus.palencia@openbossa.org>
1813
1814         [Qt] Setting QWebPreferences affect multiple WebViews
1815         https://bugs.webkit.org/show_bug.cgi?id=71559
1816
1817         Reviewed by Kenneth Rohde Christiansen.
1818
1819         The QWebPreferences are per WebView, but the actual implementation
1820         in WebKit2 make them per page group. Currently we share only one
1821         page group between all the views, so if we set preferences
1822         to one WebView the preferences are shared between them all, generating
1823         unexpected behavior. This patch fixes this by making each WebView have
1824         its own page group.
1825
1826         * UIProcess/API/qt/qquickwebview.cpp:
1827         (QQuickWebViewPrivate::QQuickWebViewPrivate):
1828         * UIProcess/API/qt/tests/qmltests/WebView/tst_preferences.qml:
1829
1830 2011-12-19  Eric Carlson  <eric.carlson@apple.com>
1831
1832         Enable <track> for Mac build
1833         https://bugs.webkit.org/show_bug.cgi?id=74838
1834
1835         Reviewed by Darin Adler.
1836
1837         * Configurations/FeatureDefines.xcconfig:
1838
1839 2011-12-19  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>
1840
1841         [Qt] [WK2] Fix build error due to unused variables
1842         https://bugs.webkit.org/show_bug.cgi?id=74862
1843
1844         Reviewed by Kenneth Rohde Christiansen.
1845
1846         * UIProcess/qt/QtWebPageEventHandler.cpp:
1847         (QtWebPageEventHandler::inputMethodEvent):
1848
1849 2011-12-19  Kenneth Rohde Christiansen  <kenneth@webkit.org>
1850
1851         [Qt] Add methods for setting, cancelling and confirming the composition
1852
1853         Reviewed by Simon Hausmann.
1854
1855         * UIProcess/WebPageProxy.h:
1856         * UIProcess/qt/WebPageProxyQt.cpp:
1857         (WebKit::WebPageProxy::setComposition):
1858         (WebKit::WebPageProxy::confirmComposition):
1859         (WebKit::WebPageProxy::cancelComposition):
1860         * WebProcess/WebPage/WebPage.h:
1861         * WebProcess/WebPage/WebPage.messages.in:
1862         * WebProcess/WebPage/qt/WebPageQt.cpp:
1863         (WebKit::targetFrameForEditing):
1864         (WebKit::WebPage::confirmComposition):
1865         (WebKit::WebPage::setComposition):
1866         (WebKit::WebPage::cancelComposition):
1867
1868 2011-12-19  Kenneth Rohde Christiansen  <kenneth@webkit.org>
1869
1870         First stab at upstreaming our virtual keyboard code
1871
1872         Reviewed by Simon Hausmann.
1873
1874         Add basic implementation of inputMethodEvent
1875
1876         * UIProcess/qt/QtWebPageEventHandler.cpp:
1877         (QtWebPageEventHandler::handleEvent):
1878         (QtWebPageEventHandler::inputMethodEvent):
1879         * UIProcess/qt/QtWebPageEventHandler.h:
1880
1881 2011-12-19  Simon Hausmann  <simon.hausmann@nokia.com>
1882
1883         [Qt][WK2] Add support for modal event loop processing for WTR
1884         https://bugs.webkit.org/show_bug.cgi?id=74852
1885
1886         Reviewed by Kenneth Rohde Christiansen.
1887
1888         Add support for nested event loops, used by WebPage::runModal().
1889
1890         * Platform/qt/RunLoopQt.cpp:
1891         (RunLoop::run):
1892         (RunLoop::stop):
1893
1894 2011-12-18  Sam Weinig  <sam@webkit.org>
1895
1896         Another attempt to fix the windows build.
1897
1898         * Platform/win/WorkQueueWin.cpp:
1899         (WorkQueue::performWorkOnRegisteredWorkThread):
1900         (WorkQueue::dispatch):
1901
1902 2011-12-18  Sam Weinig  <sam@webkit.org>
1903
1904         Try to fix the windows build.
1905
1906         * Platform/win/WorkQueueWin.cpp:
1907         (WorkQueue::performWorkOnRegisteredWorkThread):
1908
1909 2011-12-18  Sam Weinig  <sam@webkit.org>
1910
1911         Remove now unused WorkItem.h
1912         https://bugs.webkit.org/show_bug.cgi?id=74818
1913
1914         Reviewed by Andreas Kling.
1915
1916         * GNUmakefile.am:
1917         * Platform/CoreIPC/Connection.cpp:
1918         * Platform/RunLoop.cpp:
1919         * Platform/RunLoop.h:
1920         * Platform/WorkItem.h: Removed.
1921         * Platform/gtk/RunLoopGtk.cpp:
1922         * Platform/mac/RunLoopMac.mm:
1923         * Platform/mac/WorkQueueMac.cpp:
1924         (WorkQueue::platformInvalidate):
1925         * Platform/qt/RunLoopQt.cpp:
1926         * Platform/win/RunLoopWin.cpp:
1927         * Target.pri:
1928         * UIProcess/ResponsivenessTimer.cpp:
1929         * WebKit2.xcodeproj/project.pbxproj:
1930         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
1931         * win/WebKit2.vcproj:
1932
1933 2011-12-18  Anders Carlsson  <andersca@apple.com>
1934
1935         Set the main frame view scroll position asynchronously
1936         https://bugs.webkit.org/show_bug.cgi?id=74823
1937
1938         Reviewed by Sam Weinig.
1939
1940         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
1941         (WebKit::TiledCoreAnimationDrawingArea::TiledCoreAnimationDrawingArea):
1942         Don't make the background red.
1943
1944 2011-12-18  Sam Weinig  <sam@webkit.org>
1945
1946         Move timestamp down from PlatformEvent subclasses to the base class
1947         https://bugs.webkit.org/show_bug.cgi?id=74805
1948
1949         Reviewed by Anders Carlsson.
1950
1951         * Shared/WebEventConversion.cpp:
1952         (WebKit::WebKit2PlatformMouseEvent::WebKit2PlatformMouseEvent):
1953         (WebKit::WebKit2PlatformWheelEvent::WebKit2PlatformWheelEvent):
1954         (WebKit::WebKit2PlatformKeyboardEvent::WebKit2PlatformKeyboardEvent):
1955         (WebKit::WebKit2PlatformGestureEvent::WebKit2PlatformGestureEvent):
1956         (WebKit::WebKit2PlatformTouchEvent::WebKit2PlatformTouchEvent):
1957
1958 2011-12-18  Anders Carlsson  <andersca@apple.com>
1959
1960         Add a scrolling thread to the scrolling coordinator
1961         https://bugs.webkit.org/show_bug.cgi?id=74814
1962
1963         Reviewed by Andreas Kling.
1964
1965         Check if the scrolling coordinator can handle the wheel event before dispatching it
1966         to the main thread.
1967
1968         * WebProcess/WebPage/EventDispatcher.cpp:
1969         (WebKit::EventDispatcher::wheelEvent):
1970
1971 2011-12-18  Anders Carlsson  <andersca@apple.com>
1972
1973         EventDispatcher should keep track of all scrolling coordinators
1974         https://bugs.webkit.org/show_bug.cgi?id=74810
1975
1976         Reviewed by Andreas Kling.
1977
1978         * WebProcess/WebPage/EventDispatcher.cpp:
1979         (WebKit::EventDispatcher::addScrollingCoordinatorForPage):
1980         Get the scrolling coordinator from the WebCore page and add it to the map.
1981
1982         (WebKit::EventDispatcher::removeScrollingCoordinatorForPage):
1983         Remove the scrolling coordinator from the map.
1984
1985         (WebKit::EventDispatcher::sendDidHandleEvent):
1986         Add a new helper function, currently unused.
1987
1988         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
1989         (WebKit::TiledCoreAnimationDrawingArea::TiledCoreAnimationDrawingArea):
1990         Add the scrolling coordinator.
1991
1992         (WebKit::TiledCoreAnimationDrawingArea::~TiledCoreAnimationDrawingArea):
1993         Remove the scrolling coordinator.
1994
1995         * WebProcess/WebProcess.h:
1996         (WebKit::WebProcess::eventDispatcher):
1997         Add a getter.
1998
1999 2011-12-16  Anders Carlsson  <andersca@apple.com>
2000
2001         Move everyone off of WorkItem
2002         https://bugs.webkit.org/show_bug.cgi?id=74773
2003
2004         Reviewed by Darin Adler.
2005
2006         * Platform/CoreIPC/unix/ConnectionUnix.cpp:
2007         (CoreIPC::Connection::open):
2008         (CoreIPC::Connection::setShouldCloseConnectionOnProcessTermination):
2009         * Platform/CoreIPC/win/ConnectionWin.cpp:
2010         (CoreIPC::Connection::open):
2011         * Platform/RunLoop.cpp:
2012         (RunLoop::performWork):
2013         (RunLoop::dispatch):
2014         * Platform/RunLoop.h:
2015         * Platform/WorkQueue.cpp:
2016         * Platform/WorkQueue.h:
2017         (WorkQueue::WorkItemWin::function):
2018         * Platform/gtk/WorkQueueGtk.cpp:
2019         (WorkQueue::EventSource::EventSource):
2020         (WorkQueue::EventSource::executeEventSource):
2021         (WorkQueue::registerEventSourceHandler):
2022         (WorkQueue::dispatchOnSource):
2023         (WorkQueue::dispatch):
2024         (WorkQueue::dispatchAfterDelay):
2025         (WorkQueue::dispatchOnTermination):
2026         * Platform/mac/WorkQueueMac.cpp:
2027         (WorkQueue::executeFunction):
2028         (WorkQueue::dispatch):
2029         (WorkQueue::dispatchAfterDelay):
2030         * Platform/qt/WorkQueueQt.cpp:
2031         (WorkQueue::WorkItemQt::WorkItemQt):
2032         (WorkQueue::WorkItemQt::~WorkItemQt):
2033         (WorkQueue::WorkItemQt::execute):
2034         (WorkQueue::registerSocketEventHandler):
2035         (WorkQueue::dispatch):
2036         (WorkQueue::dispatchAfterDelay):
2037         (WorkQueue::dispatchOnTermination):
2038         * Platform/win/RunLoopWin.cpp:
2039         (RunLoop::wakeUp):
2040         * Platform/win/WorkQueueWin.cpp:
2041         (WorkQueue::WorkItemWin::WorkItemWin):
2042         (WorkQueue::WorkItemWin::create):
2043         (WorkQueue::HandleWorkItem::HandleWorkItem):
2044         (WorkQueue::HandleWorkItem::createByAdoptingHandle):
2045         (WorkQueue::registerHandle):
2046         (WorkQueue::dispatch):
2047         * UIProcess/Launcher/gtk/ProcessLauncherGtk.cpp:
2048         (WebKit::ProcessLauncher::launchProcess):
2049         * UIProcess/Launcher/qt/ProcessLauncherQt.cpp:
2050         (WebKit::ProcessLauncher::launchProcess):
2051         * UIProcess/Launcher/win/ProcessLauncherWin.cpp:
2052         (WebKit::ProcessLauncher::launchProcess):
2053         * WebProcess/mac/CoreIPCClientRunLoop.mm:
2054         (WebKit::callOnCoreIPCClientRunLoopAndWait):
2055
2056 2011-12-17  Sam Weinig  <sam@webkit.org>
2057
2058         Make PlatformTouchEvent inherit from PlatformEvent
2059         https://bugs.webkit.org/show_bug.cgi?id=74777
2060
2061         Reviewed by Andreas Kling.
2062
2063         * Shared/WebEventConversion.cpp:
2064         (WebKit::WebKit2PlatformTouchEvent::WebKit2PlatformTouchEvent):
2065         Add PlatformEvent prefix to enum types.
2066
2067 2011-12-16  Anders Carlsson  <andersca@apple.com>
2068
2069         Convert more WorkItems over to WTF::Functions
2070         https://bugs.webkit.org/show_bug.cgi?id=74770
2071
2072         Reviewed by Andreas Kling.
2073
2074         * Platform/WorkQueue.cpp:
2075         (WorkQueue::dispatchAfterDelay):
2076         * Platform/WorkQueue.h:
2077         * Shared/ChildProcess.cpp:
2078         (WebKit::ChildProcess::didCloseOnConnectionWorkQueue):
2079         * UIProcess/Launcher/ThreadLauncher.cpp:
2080         (WebKit::ThreadLauncher::launchThread):
2081         * UIProcess/Launcher/mac/ProcessLauncherMac.mm:
2082         (WebKit::ProcessLauncher::launchProcess):
2083         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
2084         (WebKit::NetscapePlugin::pluginThreadAsyncCall):
2085         * WebProcess/Plugins/PluginView.cpp:
2086         (WebKit::derefPluginView):
2087         (WebKit::PluginView::unprotectPluginFromDestruction):
2088
2089 2011-12-16  Mark Hahnenberg  <mhahnenberg@apple.com>
2090
2091         Windows test fix
2092
2093         Unreviewed test fix. All Windows tests were crashing when objects who were pointing to 
2094         static data members across DLL boundaries were getting garbage in their pointers.
2095
2096         * win/WebKit2.def:
2097
2098 2011-12-16  Ryosuke Niwa  <rniwa@webkit.org>
2099
2100         Rename registerCommandFor(Undo|Redo) to register(Undo|Redo)Step
2101         https://bugs.webkit.org/show_bug.cgi?id=74748
2102
2103         Reviewed by Eric Seidel.
2104
2105         * WebProcess/WebCoreSupport/WebEditorClient.cpp:
2106         (WebKit::WebEditorClient::registerUndoStep):
2107         (WebKit::WebEditorClient::registerRedoStep):
2108         * WebProcess/WebCoreSupport/WebEditorClient.h:
2109
2110 2011-12-16  Anders Carlsson  <andersca@apple.com>
2111
2112         Add a pretty dumb tile cache to WebTileCacheLayer
2113         https://bugs.webkit.org/show_bug.cgi?id=74753
2114
2115         Reviewed by Simon Fraser.
2116
2117         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
2118         (WebKit::TiledCoreAnimationDrawingArea::flushLayers):
2119         Always do a layout here, to prevent an ASSERT(!needsLayout()) when painting.
2120
2121 2011-12-16  Anders Carlsson  <andersca@apple.com>
2122
2123         TiledCoreAnimationDrawingArea should enable the scrolling coordinator
2124         https://bugs.webkit.org/show_bug.cgi?id=74724
2125
2126         Reviewed by Adam Roben.
2127
2128         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
2129         (WebKit::TiledCoreAnimationDrawingArea::TiledCoreAnimationDrawingArea):
2130
2131 2011-12-16  Sam Weinig  <sam@webkit.org>
2132
2133         Give PlatformEvents a base class
2134         https://bugs.webkit.org/show_bug.cgi?id=74685
2135
2136         Reviewed by Anders Carlsson.
2137
2138         Add a base class for PlatformMouseEvent, PlatformKeyboardEvent, PlatformWheelEvent
2139         and PlatformGestureEvent and move Type enumeration and modifiers down to it.
2140
2141         * Shared/WebEventConversion.cpp:
2142         (WebKit::WebKit2PlatformMouseEvent::WebKit2PlatformMouseEvent):
2143         (WebKit::WebKit2PlatformWheelEvent::WebKit2PlatformWheelEvent):
2144         (WebKit::WebKit2PlatformKeyboardEvent::WebKit2PlatformKeyboardEvent):
2145         (WebKit::WebKit2PlatformGestureEvent::WebKit2PlatformGestureEvent):
2146         * WebKit2.xcodeproj/project.pbxproj:
2147         * WebProcess/WebCoreSupport/gtk/WebEditorClientGtk.cpp:
2148         (WebKit::WebEditorClient::handleKeyboardEvent):
2149         * WebProcess/WebPage/WebPage.cpp:
2150         (WebKit::handleMouseEvent):
2151         (WebKit::WebPage::setInitialFocus):
2152         (WebKit::WebPage::handleEditingKeyboardEvent):
2153         (WebKit::WebPage::dragEnded):
2154         * WebProcess/WebPage/mac/WebPageMac.mm:
2155         (WebKit::WebPage::executeKeypressCommandsInternal):
2156         (WebKit::WebPage::handleEditingKeyboardEvent):
2157
2158 2011-12-16  Ryosuke Niwa  <rniwa@webkit.org>
2159
2160         Only EditCommandComposition should implement unapply and reapply
2161         https://bugs.webkit.org/show_bug.cgi?id=74490
2162
2163         Reviewed by Eric Seidel.
2164
2165         Renamed WebEditCommand to WebUndoStep and made necessary changes.
2166         Everything on WebProcess side should have the correct name now.
2167
2168         Names in the proxy and UIProcess are to be updated in a follow up.
2169
2170         * CMakeLists.txt:
2171         * GNUmakefile.am:
2172         * Target.pri:
2173         * WebKit2.xcodeproj/project.pbxproj:
2174         * WebProcess/WebCoreSupport/WebEditorClient.cpp:
2175         (WebKit::WebEditorClient::registerCommandForUndo):
2176         (WebKit::WebEditorClient::registerCommandForRedo):
2177         * WebProcess/WebCoreSupport/WebEditorClient.h:
2178         * WebProcess/WebPage/WebEditCommand.cpp: Removed.
2179         * WebProcess/WebPage/WebEditCommand.h: Removed.
2180         * WebProcess/WebPage/WebPage.cpp:
2181         (WebKit::WebPage::webUndoStep):
2182         (WebKit::WebPage::addWebUndoStep):
2183         (WebKit::WebPage::removeWebEditCommand):
2184         (WebKit::WebPage::unapplyEditCommand):
2185         (WebKit::WebPage::reapplyEditCommand):
2186         * WebProcess/WebPage/WebPage.h:
2187         * WebProcess/WebPage/WebUndoStep.cpp: Copied from Source/WebKit2/WebProcess/WebPage/WebEditCommand.cpp.
2188         (WebKit::generateUndoStep):
2189         (WebKit::WebUndoStep::create):
2190         * WebProcess/WebPage/WebUndoStep.h: Copied from Source/WebKit2/WebProcess/WebPage/WebEditCommand.h.
2191         (WebKit::WebUndoStep::entry):
2192         (WebKit::WebUndoStep::entryID):
2193         (WebKit::WebUndoStep::WebUndoStep):
2194         * win/WebKit2.vcproj:
2195
2196 2011-12-16  Simon Hausmann  <simon.hausmann@nokia.com>
2197
2198         [Qt] Eliminate dependency to QUndoStack
2199         https://bugs.webkit.org/show_bug.cgi?id=74691
2200
2201         Reviewed by Kenneth Rohde Christiansen.
2202
2203         Replaced the QUndoStack with two vectors. When calling unapply()
2204         on the edit command proxy, it will automatically re-register itself
2205         in the redo stack.
2206
2207         * UIProcess/qt/QtWebUndoController.cpp:
2208         (QtWebUndoController::registerEditCommand):
2209         (QtWebUndoController::clearAllEditCommands):
2210         (QtWebUndoController::canUndoRedo):
2211         (QtWebUndoController::executeUndoRedo):
2212         * UIProcess/qt/QtWebUndoController.h:
2213
2214 2011-12-16  Rafael Brandao  <rafael.lobo@openbossa.org>
2215
2216         [Qt][WK2] Move webView.page into experimental
2217         https://bugs.webkit.org/show_bug.cgi?id=74406
2218
2219         Reviewed by Simon Hausmann.
2220
2221         * UIProcess/API/qt/qquickwebview.cpp:
2222         (QQuickWebViewExperimental::page):
2223         * UIProcess/API/qt/qquickwebview_p.h:
2224         * UIProcess/API/qt/tests/qquickwebview/tst_qquickwebview.cpp:
2225         (tst_QQuickWebView::accessPage):
2226
2227 2011-12-16  Mark Hahnenberg  <mhahnenberg@apple.com>
2228
2229         De-virtualize destructors
2230         https://bugs.webkit.org/show_bug.cgi?id=74331
2231
2232         Reviewed by Geoffrey Garen.
2233
2234         * WebProcess/Plugins/Netscape/JSNPMethod.cpp: Add trivial destructor assert.
2235         * WebProcess/Plugins/Netscape/JSNPObject.cpp: Add static destroy.
2236         (WebKit::JSNPObject::destroy):
2237         * WebProcess/Plugins/Netscape/JSNPObject.h:
2238         * win/WebKit2.def: Add/remove necessary symbols.
2239         * win/WebKit2CFLite.def: Ditto.
2240
2241 2011-12-16  Carlos Garcia Campos  <cgarcia@igalia.com>
2242
2243         [GTK] Use bit field for bool members of WebKitWindowPropertiesPrivate
2244         https://bugs.webkit.org/show_bug.cgi?id=74713
2245
2246         Reviewed by Gustavo Noronha Silva.
2247
2248         Most of the members are bools, so it reduces the memory footprint.
2249
2250         * UIProcess/API/gtk/WebKitWindowProperties.cpp:
2251
2252 2011-12-16  Carlos Garcia Campos  <cgarcia@igalia.com>
2253
2254         [GTK] Window frame should be 0x0 when the toplevel window is not visible
2255         https://bugs.webkit.org/show_bug.cgi?id=74709
2256
2257         Reviewed by Gustavo Noronha Silva.
2258
2259         * UIProcess/API/gtk/WebKitUIClient.cpp:
2260         (getWindowFrame): Check also whether the toplevel is visible
2261         before getting its size and position.
2262
2263 2011-12-16  Michael Bruning  <michael.bruning@nokia.com>
2264
2265         [qt][wk2] Viewport info panel shows wrong current scale
2266         https://bugs.webkit.org/show_bug.cgi?id=74613
2267
2268         Reviewed by Kenneth Rohde Christiansen.
2269
2270         * UIProcess/API/qt/qwebviewportinfo.cpp:
2271         (QWebViewportInfo::currentScale): Added division by devicePixelRatio. Also
2272         added emission of currenScaleUpdated signal when the viewport constraints
2273         have been updated.
2274         (QWebViewportInfo::didUpdateViewportConstraints):
2275         * UIProcess/API/qt/qwebviewportinfo_p.h: Changed return type of
2276         currentScale to QVariant as it depends on the viewport interaction engine
2277         now.
2278         * UIProcess/qt/QtViewportInteractionEngine.cpp:
2279         (WebKit::QtViewportInteractionEngine::ensureContentWithinViewportBoundary): Changed
2280         to use currentCSSScale for getting the current css scale.
2281         (WebKit::QtViewportInteractionEngine::currentCSSScale): Added.
2282         * UIProcess/qt/QtViewportInteractionEngine.h: Added method currentCSSScale.
2283
2284 2011-12-15  Martin Robinson  <mrobinson@igalia.com>
2285
2286         Fix 'make dist' in preparation for the GTK+ release.
2287
2288         * GNUmakefile.am: Add missing header.
2289
2290 2011-12-15  Anders Carlsson  <andersca@apple.com>
2291
2292         Add support for accelerated compositing to the tiled Core Animation drawing area
2293         https://bugs.webkit.org/show_bug.cgi?id=74675
2294
2295         Reviewed by Andreas Kling.
2296
2297         Add a layer flush scheduler and get rid of the content layer since WebCore will manage that for us.
2298
2299         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.h:
2300         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
2301         (WebKit::TiledCoreAnimationDrawingArea::TiledCoreAnimationDrawingArea):
2302         (WebKit::TiledCoreAnimationDrawingArea::~TiledCoreAnimationDrawingArea):
2303         (WebKit::TiledCoreAnimationDrawingArea::setNeedsDisplay):
2304         (WebKit::TiledCoreAnimationDrawingArea::scroll):
2305         (WebKit::TiledCoreAnimationDrawingArea::setRootCompositingLayer):
2306         (WebKit::TiledCoreAnimationDrawingArea::scheduleCompositingLayerSync):
2307         (WebKit::TiledCoreAnimationDrawingArea::flushLayers):
2308         (WebKit::TiledCoreAnimationDrawingArea::updateGeometry):
2309
2310 2011-12-15  Sheriff Bot  <webkit.review.bot@gmail.com>
2311
2312         Unreviewed, rolling out r102652 and r102717.
2313         http://trac.webkit.org/changeset/102652
2314         http://trac.webkit.org/changeset/102717
2315         https://bugs.webkit.org/show_bug.cgi?id=74674
2316
2317         Broke too many webs. (Requested by kling on #webkit).
2318
2319         * UIProcess/API/mac/WKView.mm:
2320         (-[WKView _updateWindowAndViewFrames]):
2321         * UIProcess/WebPageProxy.h:
2322         * UIProcess/mac/WebPageProxyMac.mm:
2323         (WebKit::WebPageProxy::windowAndViewFramesChanged):
2324         * WebProcess/Plugins/PluginView.cpp:
2325         (WebKit::PluginView::windowAndViewFramesChanged):
2326         * WebProcess/Plugins/PluginView.h:
2327         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
2328         (WebKit::WebChromeClient::windowRect):
2329         * WebProcess/WebPage/WebPage.cpp:
2330         (WebKit::WebPage::windowAndViewFramesChanged):
2331         * WebProcess/WebPage/WebPage.h:
2332         (WebKit::WebPage::windowFrameInScreenCoordinates):
2333         (WebKit::WebPage::viewFrameInWindowCoordinates):
2334         (WebKit::WebPage::accessibilityPosition):
2335         * WebProcess/WebPage/WebPage.messages.in:
2336         * WebProcess/WebPage/mac/WKAccessibilityWebPageObject.mm:
2337         (-[WKAccessibilityWebPageObject accessibilityAttributeValue:]):
2338
2339 2011-12-15  Gustavo Noronha Silva  <gustavo.noronha@collabora.com>
2340
2341         [GTK] New API test for WindowProperties fails
2342         https://bugs.webkit.org/show_bug.cgi?id=74630
2343
2344         Reviewed by Martin Robinson.
2345
2346         * UIProcess/API/gtk/tests/TestWebKitWebView.cpp:
2347         (WindowProperties::viewReadyToShow): assert each member to make
2348         assertion error messages more useful, and avoid asserting x and y,
2349         since we are getting bad values from WebCore, for some reason.
2350         (testWebViewWindowProperties): use smaller values that fit inside the
2351         800x600 screen used by the bots.
2352
2353 2011-12-15  Anders Carlsson  <andersca@apple.com>
2354
2355         EventDispatcher should handle wheel events on the connection queue
2356         https://bugs.webkit.org/show_bug.cgi?id=74627
2357
2358         Reviewed by Andreas Kling.
2359
2360         Send wheel events to the EventDispatcher, which handles them on the connection work queue, and
2361         immediately bounces them to the main thread (for now).
2362
2363         * UIProcess/WebPageProxy.cpp:
2364         (WebKit::WebPageProxy::handleWheelEvent):
2365         (WebKit::WebPageProxy::didReceiveEvent):
2366         * WebProcess/WebPage/EventDispatcher.cpp:
2367         (WebKit::EventDispatcher::wheelEvent):
2368         (WebKit::EventDispatcher::dispatchWheelEvent):
2369         * WebProcess/WebPage/EventDispatcher.h:
2370         * WebProcess/WebPage/EventDispatcher.messages.in:
2371         * WebProcess/WebPage/WebPage.h:
2372
2373 2011-12-15  Jon Lee  <jonlee@apple.com>
2374
2375         [WK2] Extend WebNotification to include its origin
2376         https://bugs.webkit.org/show_bug.cgi?id=74615
2377         <rdar://problem/10587164>
2378
2379         Reviewed by Sam Weinig.
2380
2381         * Shared/API/c/WKSecurityOrigin.h: Expose API that converts the security origin to database
2382         identifier.
2383         * Shared/API/c/WKSecurityOrigin.cpp:
2384         (WKSecurityOriginCopyDatabaseIdentifier):
2385
2386         * UIProcess/Notifications/WebNotification.h: Extend WebNotification to include the origin.
2387         (WebKit::WebNotification::create):
2388         (WebKit::WebNotification::origin):
2389         * UIProcess/Notifications/WebNotification.cpp: Remove unneeded encode() and decode() functions.
2390         (WebKit::WebNotification::WebNotification):
2391
2392         * UIProcess/API/C/WKNotification.h: Expose WebNotification's origin().
2393         * UIProcess/API/C/WKNotification.cpp:
2394         (WKNotificationGetSecurityOrigin):
2395
2396         * UIProcess/Notifications/WebNotificationManagerProxy.messages.in: Update show() to include the
2397         origin of the notification.
2398         * UIProcess/Notifications/WebNotificationManagerProxy.cpp:
2399         (WebKit::WebNotificationManagerProxy::show):
2400         * UIProcess/Notifications/WebNotificationManagerProxy.h:
2401         * WebProcess/Notifications/WebNotificationManager.cpp:
2402         (WebKit::WebNotificationManager::show): Pass the notification's exec context's origin as
2403         identifier.
2404
2405 2011-12-15  Rafael Brandao  <rafael.lobo@openbossa.org>
2406
2407         [Qt][WK2] Add test for download policy on navigation request
2408         https://bugs.webkit.org/show_bug.cgi?id=74541
2409
2410         Reviewed by Tor Arne Vestbø.
2411
2412         * UIProcess/API/qt/tests/qmltests/DesktopBehavior/tst_navigationRequested.qml:
2413         * UIProcess/API/qt/tests/qmltests/WebView/tst_download.qml: Make it wait for a
2414         downloadFinished signal to finish the test.
2415
2416 2011-12-15  Anders Carlsson  <andersca@apple.com>
2417
2418         Move WorkQueue Mach handlers over to WTF::Function
2419         https://bugs.webkit.org/show_bug.cgi?id=74620
2420
2421         Reviewed by Sam Weinig.
2422
2423         * Platform/CoreIPC/mac/ConnectionMac.cpp:
2424         (CoreIPC::Connection::open):
2425         (CoreIPC::Connection::initializeDeadNameSource):
2426         * Platform/WorkQueue.h:
2427         * Platform/mac/WorkQueueMac.cpp:
2428         (WorkQueue::EventSource::EventSource):
2429         (WorkQueue::EventSource::eventHandler):
2430         (WorkQueue::registerMachPortEventHandler):
2431
2432 2011-12-14  Anders Carlsson  <andersca@apple.com>
2433
2434         Add WTF::Function to wtf/Forward.h
2435         https://bugs.webkit.org/show_bug.cgi?id=74576
2436
2437         Reviewed by Adam Roben.
2438
2439         * Platform/RunLoop.h:
2440         * Platform/WorkQueue.h:
2441         Remove forward declarations and just include wtf/Forward.h.
2442
2443 2011-12-15  Rafael Brandao  <rafael.lobo@openbossa.org>
2444
2445         [Qt][WK2] Move WebPreferences into experimental
2446         https://bugs.webkit.org/show_bug.cgi?id=74404
2447
2448         Reviewed by Tor Arne Vestbø.
2449
2450         * UIProcess/API/qt/qquickwebview.cpp:
2451         (QQuickWebViewExperimental::preferences):
2452         * UIProcess/API/qt/qquickwebview_p.h:
2453         * UIProcess/API/qt/tests/qmltests/DesktopBehavior/tst_messaging.qml:
2454         * UIProcess/API/qt/tests/qmltests/WebView/tst_preferences.qml:
2455
2456 2011-12-15  Carlos Garcia Campos  <cgarcia@igalia.com>
2457
2458         [GTK] Add WebKitWindowProperties to WebKit2 GTK+ API
2459         https://bugs.webkit.org/show_bug.cgi?id=74595
2460
2461         Reviewed by Gustavo Noronha Silva.
2462
2463         * GNUmakefile.am: Add new files to compilation.
2464         * UIProcess/API/gtk/WebKitUIClient.cpp:
2465         (createNewPage): Pass the dictionary containing the window
2466         features to webkitWebViewCreateNewPage().
2467         (toolbarsAreVisible): Return
2468         WebKitWindowProperties:toolbar-visible.
2469         (setToolbarsAreVisible): Set
2470         WebKitWindowProperties:toolbar-visible.
2471         (menuBarIsVisible): Return WebKitWindowProperties:menu-visible.
2472         (setMenuBarIsVisible): Set WebKitWindowProperties:menu-visible.
2473         (statusBarIsVisible): Return
2474         WebKitWindowProperties:status-visible.
2475         (setStatusBarIsVisible): Set
2476         WebKitWindowProperties:status-visible.
2477         (isResizable): Return WebKitWindowProperties:resizable.
2478         (setIsResizable): Set WebKitWindowProperties:resizable.
2479         (getWindowFrame): Return WebKitWindowProperties:geometry.
2480         (setWindowFrame): Set WebKitWindowProperties:geometry.
2481         (webkitUIClientAttachUIClientToPage): Initialize the UI client for
2482         the given page.
2483         * UIProcess/API/gtk/WebKitWebView.cpp:
2484         (webkit_web_view_init): Create a WebKitWindowProperties object for
2485         the view.
2486         (webkit_web_view_class_init):
2487         (webkitWebViewCreateNewPage): Update the WebKitWindowProperties
2488         object using the window features dictionary.
2489         (webkit_web_view_get_window_properties): Return the
2490         WebKitWindowProperties object of the view.
2491         * UIProcess/API/gtk/WebKitWebView.h:
2492         * UIProcess/API/gtk/WebKitWebViewPrivate.h:
2493         * UIProcess/API/gtk/WebKitWindowProperties.cpp: Added.
2494         (webkitWindowPropertiesFinalize):
2495         (webkitWindowPropertiesGetProperty):
2496         (webkitWindowPropertiesSetProperty):
2497         (webkit_window_properties_class_init):
2498         (webkit_window_properties_init):
2499         (webkitWindowPropertiesCreate): Create a new
2500         WebKitWindowProperties object.
2501         (webkitWindowPropertiesSetGeometry):
2502         (webkitWindowPropertiesSetToolbarVisible):
2503         (webkitWindowPropertiesSetMenubarVisible):
2504         (webkitWindowPropertiesSetStatusbarVisible):
2505         (webkitWindowPropertiesSetLocationbarVisible):
2506         (webkitWindowPropertiesSetScrollbarsVisible):
2507         (webkitWindowPropertiesSetResizable):
2508         (webkitWindowPropertiesSetFullscreen):
2509         (webkitWindowPropertiesUpdateFromWKWindowFeatures): Parse the
2510         window features dictionary and update the WebKitWindowProperties
2511         object accordingly.
2512         (webkit_window_properties_get_geometry):
2513         (webkit_window_properties_get_toolbar_visible):
2514         (webkit_window_properties_get_statusbar_visible):
2515         (webkit_window_properties_get_scrollbars_visible):
2516         (webkit_window_properties_get_menubar_visible):
2517         (webkit_window_properties_get_locationbar_visible):
2518         (webkit_window_properties_get_resizable):
2519         (webkit_window_properties_get_fullscreen):
2520         * UIProcess/API/gtk/WebKitWindowProperties.h: Added.
2521         * UIProcess/API/gtk/WebKitWindowPropertiesPrivate.h: Copied from Source/WebKit2/UIProcess/API/gtk/WebKitWebViewPrivate.h.
2522         * UIProcess/API/gtk/docs/webkit2gtk-docs.sgml: Add new section for
2523         WebKitWindowProperties.
2524         * UIProcess/API/gtk/docs/webkit2gtk-sections.txt: Add new symbols.
2525         * UIProcess/API/gtk/docs/webkit2gtk.types: Add
2526         webkit_window_properties_get_type.
2527         * UIProcess/API/gtk/tests/TestWebKitWebView.cpp:
2528         (WindowProperties::windowPropertiesNotifyCallback):
2529         (WindowProperties::viewReadyToShow):
2530         (WindowProperties::viewCreate):
2531         (WindowProperties::setExpectedWindowProperties):
2532         (testWebViewWindowProperties):
2533         (beforeAll):
2534         * UIProcess/API/gtk/webkit2.h: Include WebKitWindowProperties.h.
2535         * UIProcess/WebUIClient.cpp:
2536         (WebKit::WebUIClient::createNewPage): Add also "locationBarVisible"
2537         to the window features dictionary.
2538
2539 2011-12-15  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>
2540
2541         [Qt] [WK2] Remove QtWebPageProxy
2542         https://bugs.webkit.org/show_bug.cgi?id=74540
2543
2544         Reviewed by Kenneth Rohde Christiansen.
2545
2546         Move WebPageProxy* to QQuickWebViewPrivate. The remaining functions in
2547         QtWebPageProxy were simple wrappers to WebKit functionality (text zoom, page zoom
2548         and user agent setting). Since those wrappers are unused, they were removed. The
2549         signal in the class was also unused.
2550
2551         This patch also remove the code from WebContextMenuProxyQt, it was remains of a
2552         previous QMenu-based implementation. We want to rewrite this code for QML anyway,
2553         so I reverted to an empty state.
2554
2555         Farewell, QtWebPageProxy!
2556
2557         * Target.pri:
2558         * UIProcess/API/qt/qquickwebpage.cpp:
2559         * UIProcess/API/qt/qquickwebpage_p.h:
2560         * UIProcess/API/qt/qquickwebview.cpp:
2561         (QQuickWebViewPrivate::~QQuickWebViewPrivate):
2562         (QQuickWebViewPrivate::initialize):
2563         (QQuickWebViewPrivate::processDidCrash):
2564         (QQuickWebViewPrivate::createDrawingAreaProxy):
2565         (QQuickWebViewPrivate::updateVisibleContentRectAndScale):
2566         (QQuickWebViewPrivate::_q_viewportTrajectoryVectorChanged):
2567         (QQuickWebViewPrivate::_q_onVisibleChanged):
2568         (QQuickWebViewPrivate::updateViewportSize):
2569         (QQuickWebViewPrivate::computeViewportConstraints):
2570         (QQuickWebViewPrivate::setUseTraditionalDesktopBehaviour):
2571         (QQuickWebViewPrivate::setNavigatorQtObjectEnabled):
2572         (QQuickWebViewExperimental::postMessage):
2573         (QQuickWebView::load):
2574         (QQuickWebView::goBack):
2575         (QQuickWebView::goForward):
2576         (QQuickWebView::stop):
2577         (QQuickWebView::reload):
2578         (QQuickWebView::url):
2579         (QQuickWebView::canGoBack):
2580         (QQuickWebView::canGoForward):
2581         (QQuickWebView::loading):
2582         (QQuickWebView::canReload):
2583         (QQuickWebView::title):
2584         (QQuickWebView::pageRef):
2585         (QQuickWebView::loadHtml):
2586         * UIProcess/API/qt/qquickwebview_p.h:
2587         * UIProcess/API/qt/qquickwebview_p_p.h:
2588         * UIProcess/API/qt/qwebnavigationhistory_p_p.h:
2589         * UIProcess/API/qt/qwebpreferences.cpp:
2590         (QWebPreferencesPrivate::preferencesRef):
2591         * UIProcess/PageClient.h:
2592         * UIProcess/qt/QtPageClient.cpp:
2593         (QtPageClient::QtPageClient):
2594         (QtPageClient::initialize):
2595         (QtPageClient::createPopupMenuProxy):
2596         (QtPageClient::createContextMenuProxy):
2597         * UIProcess/qt/QtPageClient.h:
2598         * UIProcess/qt/QtWebPageProxy.cpp: Removed.
2599         * UIProcess/qt/QtWebPageProxy.h: Removed.
2600         * UIProcess/qt/WebContextMenuProxyQt.cpp:
2601         (WebKit::WebContextMenuProxyQt::WebContextMenuProxyQt):
2602         (WebKit::WebContextMenuProxyQt::create):
2603         (WebKit::WebContextMenuProxyQt::showContextMenu):
2604         (WebKit::WebContextMenuProxyQt::hideContextMenu):
2605         * UIProcess/qt/WebContextMenuProxyQt.h:
2606
2607 2011-12-15  Simon Hausmann  <simon.hausmann@nokia.com>
2608
2609         [WK2] Eliminate unnecessary GTK/QT ifdefs for shared memory implementation
2610         https://bugs.webkit.org/show_bug.cgi?id=74602
2611
2612         Reviewed by Kenneth Rohde Christiansen.
2613
2614         For shared memory Qt was using shm_open, Gtk was using files in /tmp. There
2615         is no reason to obfuscate the code with #ifdefs or let Gtk use an inferior
2616         method of opening shared memory. So this patch makes SharedMemoryUnix.cpp
2617         truly Qt and Gtk independent.
2618
2619         * Platform/unix/SharedMemoryUnix.cpp:
2620         (WebKit::SharedMemory::create):
2621
2622 2011-12-15  Simon Hausmann  <simon.hausmann@nokia.com>
2623
2624         [Qt] Cleanup: Remove unnecessary const_cast
2625
2626         Reviewed by Kenneth Christiansen.
2627
2628         * UIProcess/API/qt/qquickwebview.cpp:
2629         (QQuickWebView::preferences):
2630
2631 2011-12-15  Michael Brüning  <michael.bruning@nokia.com>
2632
2633         [QT][WK2]Add (experimental) viewport info view to Minibrowser/qt.
2634         https://bugs.webkit.org/show_bug.cgi?id=72893
2635
2636         Reviewed by Kenneth Rohde Christiansen.
2637
2638         This patch extends QQuickWebViewExperimental by a property named
2639         viewportInfo, which contains the viewport scalability and
2640         layout and contents size information. This property is exposed to
2641         QML through the experimental extension for QQuickWebView.
2642
2643         * Target.pri:
2644         * UIProcess/API/qt/qquickwebview.cpp:
2645         (QQuickWebViewPrivate::didChangeContentsSize):
2646         (QQuickWebViewPrivate::computeViewportConstraints):
2647         (QQuickWebViewPrivate::PostTransitionState::apply): Added applying
2648         contentsSize to viewportInfo.
2649         (QQuickWebViewExperimental::QQuickWebViewExperimental):
2650         (QQuickWebViewExperimental::viewportInfo):
2651         * UIProcess/API/qt/qquickwebview_p.h:
2652         * UIProcess/API/qt/qquickwebview_p_p.h: Moved PostTransitionState::apply
2653         to qquickwebview.cpp. Added friend QWebViewportInfo.
2654         * UIProcess/API/qt/qwebviewportinfo.cpp: Added.
2655         (QWebViewportInfo::QWebViewportInfo):
2656         (QWebViewportInfo::~QWebViewportInfo):
2657         (QWebViewportInfo::contentsSize):
2658         (QWebViewportInfo::currentScale):
2659         (QWebViewportInfo::devicePixelRatio):
2660         (QWebViewportInfo::initialScale):
2661         (QWebViewportInfo::minimumScale):
2662         (QWebViewportInfo::maximumScale):
2663         (QWebViewportInfo::isScalable):
2664         (QWebViewportInfo::layoutSize):
2665         (QWebViewportInfo::didUpdateContentsSize):
2666         (QWebViewportInfo::didUpdateCurrentScale):
2667         (QWebViewportInfo::didUpdateViewportConstraints):
2668         * UIProcess/API/qt/qwebviewportinfo_p.h: Added.
2669         * UIProcess/qt/QtViewportInteractionEngine.h:
2670         (WebKit::QtViewportInteractionEngine::Constraints::Constraints): Added layoutSize.
2671         (WebKit::QtViewportInteractionEngine::constraints): Added property to access m_contraints.
2672
2673 2011-12-15  Simon Hausmann  <simon.hausmann@nokia.com>
2674
2675         [WK2] WebPage::m_useFixedLayout variable unininitialized
2676         https://bugs.webkit.org/show_bug.cgi?id=74596
2677
2678         Reviewed by Kenneth Rohde Christiansen.
2679
2680         * WebProcess/WebPage/WebPage.cpp:
2681         (WebKit::WebPage::WebPage): Avoid uninitialized use through
2682         initialization in the constructor.
2683
2684 2011-12-15  Alexander Færøy  <ahf@0x90.dk>
2685
2686         [Qt] r102849 broke the Qt build on Mac OS X.
2687         https://bugs.webkit.org/show_bug.cgi?id=74594
2688
2689         Reviewed by Simon Hausmann.
2690
2691         The __APPLE__ macro is defined on all standard OS X compilers, which
2692         leads to various CoreGraphics headers to be included in the Qt build.
2693
2694         * config.h:
2695
2696 2011-12-14  Jing Zhao  <jingzhao@chromium.org>
2697
2698         Opening two popup menus by dispatchEvent() makes problems.
2699         https://bugs.webkit.org/show_bug.cgi?id=73304
2700
2701         Reviewed by Kent Tamura.
2702
2703         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
2704         (WebKit::WebChromeClient::hasOpenedPopup): Not implemented.
2705         * WebProcess/WebCoreSupport/WebChromeClient.h: Overrides hasOpenedPopup().
2706
2707 2011-12-14  Sam Weinig  <weinig@apple.com>
2708
2709         Remove whitespace from InheritedPropertySheets attributes in
2710         vsprops files to appease the Visual Studio project migrator.
2711
2712         Reviewed by Adam Roben.
2713
2714         * win/WebKit2Debug.vsprops:
2715         * win/WebKit2DebugAll.vsprops:
2716         * win/WebKit2DebugCairoCFLite.vsprops:
2717         * win/WebKit2Production.vsprops:
2718         * win/WebKit2Release.vsprops:
2719         * win/WebKit2ReleaseCairoCFLite.vsprops:
2720         * win/WebKit2WebProcessDebug.vsprops:
2721         * win/WebKit2WebProcessDebugAll.vsprops:
2722         * win/WebKit2WebProcessDebugCairoCFLite.vsprops:
2723         * win/WebKit2WebProcessProduction.vsprops:
2724         * win/WebKit2WebProcessRelease.vsprops:
2725         * win/WebKit2WebProcessReleaseCairoCFLite.vsprops:
2726
2727 2011-12-14  Anders Carlsson  <andersca@apple.com>
2728
2729         Add WorkQueue::dispatch and RunLoop::dispatch which both take WTF::Function objects
2730         https://bugs.webkit.org/show_bug.cgi?id=74574
2731
2732         Reviewed by Sam Weinig.
2733
2734         * Platform/CoreIPC/Connection.cpp:
2735         (CoreIPC::Connection::SyncMessageState::processIncomingMessage):
2736         (CoreIPC::Connection::addQueueClient):
2737         (CoreIPC::Connection::removeQueueClient):
2738         (CoreIPC::Connection::invalidate):
2739         (CoreIPC::Connection::sendMessage):
2740         (CoreIPC::Connection::postConnectionDidCloseOnConnectionWorkQueue):
2741         (CoreIPC::Connection::connectionDidClose):
2742         (CoreIPC::Connection::enqueueIncomingMessage):
2743         Switch over to dispatch.
2744
2745         * Platform/RunLoop.cpp:
2746         (RunLoop::dispatch):
2747         Create a FunctionWorkItem and call scheduleWork.
2748
2749         * Platform/RunLoop.h:
2750         Add dispatch.
2751
2752         * Platform/WorkItem.h:
2753         (FunctionWorkItem::FunctionWorkItem):
2754         (FunctionWorkItem::execute):
2755         (WorkItem::create):
2756         Add a helper work item that wraps a WTF::Function.
2757
2758         * Platform/WorkQueue.cpp:
2759         (WorkQueue::dispatch):
2760         Create a FunctionWorkItem and call scheduleWork.
2761
2762         * Platform/WorkQueue.h:
2763         Add dispatch.
2764
2765         * UIProcess/Launcher/ProcessLauncher.cpp:
2766         (WebKit::ProcessLauncher::ProcessLauncher):
2767         Switch over to dispatch.
2768
2769 2011-12-14  Hajime Morrita  <morrita@chromium.org>
2770
2771         JS_INLINE and WTF_INLINE should be visible from WebCore
2772         https://bugs.webkit.org/show_bug.cgi?id=73191
2773
2774         Reviewed by Kevin Ollivier.
2775
2776         Removed macro definitions which is now provided by Platform.h
2777
2778         * config.h:
2779
2780 2011-12-14  Alexey Proskuryakov  <ap@apple.com>
2781
2782         [Mac] Sandbox violation opening AppleSNBFBUserClient
2783         https://bugs.webkit.org/show_bug.cgi?id=74560
2784         <rdar://problem/10410896>
2785
2786         Reviewed by Darin Adler.
2787
2788         * WebProcess/com.apple.WebProcess.sb: Just allow it.
2789
2790 2011-12-13  Jon Lee  <jonlee@apple.com>
2791
2792         Enable notifications on Mac.
2793
2794         Reviewed by Sam Weinig.
2795
2796         * Configurations/FeatureDefines.xcconfig:
2797
2798 2011-12-14  Mark Rowe  <mrowe@apple.com>
2799
2800         <rdar://problem/10573872> NPN_GetValueForURL returns wrong value for NPNURLVProxy
2801
2802         Reviewed by Anders Carlsson.
2803
2804         * PluginProcess/PluginControllerProxy.cpp:
2805         (WebKit::PluginControllerProxy::proxiesForURL): Fix a copy-paste error.
2806
2807 2011-12-14  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>
2808
2809         [Qt] [WK2] Move QWebPreferences out of QtWebPageProxy
2810         https://bugs.webkit.org/show_bug.cgi?id=74525
2811
2812         Reviewed by Luiz Agostini.
2813
2814         This patch also uses internal WebKit API to set the Accelerate Compositing
2815         directly instead of going thru QWebPreferencesPrivate. The previous approach was
2816         always causing the QWebPreferences to be created making the "lazy initialization"
2817         useless.
2818
2819         * UIProcess/API/qt/qquickwebview.cpp:
2820         (QQuickWebViewPrivate::QQuickWebViewPrivate):
2821         (QQuickWebViewPrivate::initialize):
2822         (QQuickWebViewPrivate::navigatorQtObjectEnabled):
2823         (QQuickWebViewPrivate::setNavigatorQtObjectEnabled):
2824         (QQuickWebViewExperimental::postMessage):
2825         (QQuickWebView::preferences):
2826         * UIProcess/API/qt/qquickwebview_p_p.h:
2827         * UIProcess/API/qt/qwebpreferences.cpp:
2828         (QWebPreferencesPrivate::createPreferences):
2829         (QWebPreferencesPrivate::testAttribute):
2830         (QWebPreferencesPrivate::setAttribute):
2831         (QWebPreferences::navigatorQtObjectEnabled):
2832         (QWebPreferences::setNavigatorQtObjectEnabled):
2833         (QWebPreferencesPrivate::preferencesRef):
2834         * UIProcess/API/qt/qwebpreferences_p_p.h:
2835         * UIProcess/qt/QtWebPageProxy.cpp:
2836         (QtWebPageProxy::QtWebPageProxy):
2837         * UIProcess/qt/QtWebPageProxy.h:
2838
2839 2011-12-14  Carlos Garcia Campos  <cgarcia@igalia.com>
2840
2841         [GTK] Page size should be 0,0 when view widget is not realized
2842         https://bugs.webkit.org/show_bug.cgi?id=74523
2843
2844         Reviewed by Martin Robinson.
2845
2846         We currently return 1,1 because GTK+ initializes widget allocation
2847         as -1,-1,1,1.
2848
2849         * UIProcess/API/gtk/PageClientImpl.cpp:
2850         (WebKit::PageClientImpl::viewSize): Check whether widget is
2851         realized and return IntSize() in that case.
2852
2853 2011-12-14  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>
2854
2855         [Qt] [WK2] Move download handling out of QtWebPageProxy
2856         https://bugs.webkit.org/show_bug.cgi?id=74506
2857
2858         Reviewed by Kenneth Rohde Christiansen.
2859
2860         Also moves the creation of QtWebContext out of QtWebPageProxy.
2861
2862         * UIProcess/API/qt/qquickwebview.cpp:
2863         (QQuickWebViewPrivate::initialize):
2864         (QQuickWebViewPrivate::handleDownloadRequest):
2865         (QQuickWebViewPrivate::_q_onReceivedResponseFromDownload):
2866         * UIProcess/API/qt/qquickwebview_p.h:
2867         * UIProcess/API/qt/qquickwebview_p_p.h:
2868         * UIProcess/API/qt/qwebdownloaditem_p.h:
2869         * UIProcess/qt/QtPageClient.cpp:
2870         (QtPageClient::handleDownloadRequest):
2871         * UIProcess/qt/QtPageClient.h:
2872         * UIProcess/qt/QtWebPageProxy.cpp:
2873         (QtWebPageProxy::QtWebPageProxy):
2874         * UIProcess/qt/QtWebPageProxy.h:
2875
2876 2011-12-14  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>
2877
2878         [Qt] [WK2] Move QWebNavigationHistory to QQuickWebView
2879         https://bugs.webkit.org/show_bug.cgi?id=74442
2880
2881         Reviewed by Simon Hausmann.
2882
2883         QWebNavigationHistory used QtWebPageProxy to be QObject parent of the inner models,
2884         this patch change that to use OwnPtr instead. When creating the history object we pass
2885         only the WKPageRef and let it get the backForwardList.
2886
2887         * UIProcess/API/qt/qquickwebview.cpp:
2888         (QQuickWebViewPrivate::initialize):
2889         (QQuickWebViewPrivate::didChangeBackForwardList):
2890         (QQuickWebViewExperimental::navigationHistory):
2891         (QQuickWebViewExperimental::goForwardTo):
2892         (QQuickWebViewExperimental::goBackTo):
2893         * UIProcess/API/qt/qquickwebview_p_p.h:
2894         * UIProcess/API/qt/qwebnavigationhistory.cpp:
2895         (QWebNavigationListModelPrivate::createWebNavigationModel):
2896         (QWebNavigationHistoryPrivate::QWebNavigationHistoryPrivate):
2897         (QWebNavigationHistoryPrivate::createHistory):
2898         (QWebNavigationHistoryPrivate::goBackTo):
2899         (QWebNavigationHistoryPrivate::goForwardTo):
2900         (QWebNavigationListModel::QWebNavigationListModel):
2901         (QWebNavigationHistory::backItems):
2902         (QWebNavigationHistory::forwardItems):
2903         * UIProcess/API/qt/qwebnavigationhistory_p.h:
2904         * UIProcess/API/qt/qwebnavigationhistory_p_p.h:
2905         * UIProcess/qt/QtWebPageProxy.cpp:
2906         (QtWebPageProxy::QtWebPageProxy):
2907         * UIProcess/qt/QtWebPageProxy.h:
2908
2909 2011-12-14  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>
2910
2911         [Qt][WK2] Remove DrawingArea and QtWebPageEventHandler code from QtWebPageProxy
2912         https://bugs.webkit.org/show_bug.cgi?id=74414
2913
2914         Reviewed by Simon Hausmann.
2915
2916         This also moves QtWebPageEventHandler to inside QQuickWebPagePrivate, to avoid
2917         the WebPage having a backpointer to the QQuickWebView.
2918
2919         * Target.pri:
2920         * UIProcess/API/qt/qquickwebpage.cpp:
2921         (QQuickWebPage::geometryChanged):
2922         (QQuickWebPage::event):
2923         (QQuickWebPagePrivate::QQuickWebPagePrivate):
2924         (QQuickWebPagePrivate::initialize):
2925         (QQuickWebPagePrivate::setDrawingAreaSize):
2926         (QQuickWebPagePrivate::paintToCurrentGLContext):
2927         (QQuickWebPagePrivate::resetPaintNode):
2928         * UIProcess/API/qt/qquickwebpage_p.h:
2929         * UIProcess/API/qt/qquickwebpage_p_p.h:
2930         * UIProcess/API/qt/qquickwebview.cpp:
2931         (QQuickWebViewPrivate::initialize):
2932         (QQuickWebViewPrivate::initializeDesktop):
2933         (QQuickWebViewPrivate::initializeTouch):
2934         (QQuickWebViewPrivate::_q_resume):
2935         (QQuickWebViewPrivate::processDidCrash):
2936         (QQuickWebViewPrivate::didRelaunchProcess):
2937         (QQuickWebViewPrivate::createDrawingAreaProxy):
2938         (QQuickWebViewPrivate::updateVisibleContentRectAndScale):
2939         (QQuickWebViewPrivate::_q_viewportTrajectoryVectorChanged):
2940         (QQuickWebViewPrivate::updateViewportSize):
2941         * UIProcess/API/qt/qquickwebview_p_p.h:
2942         * UIProcess/qt/QtPageClient.cpp:
2943         (QtPageClient::createDrawingAreaProxy):
2944         * UIProcess/qt/QtPageClient.h:
2945         (QtPageClient::findStringInCustomRepresentation):
2946         (QtPageClient::countStringMatchesInCustomRepresentation):
2947         * UIProcess/qt/QtWebPageEventHandler.cpp:
2948         (QtWebPageEventHandler::QtWebPageEventHandler):
2949         (QtWebPageEventHandler::startDrag):
2950         * UIProcess/qt/QtWebPageEventHandler.h:
2951         * UIProcess/qt/QtWebPageProxy.cpp:
2952         (QtWebPageProxy::init):
2953         * UIProcess/qt/QtWebPageProxy.h:
2954
2955 2011-12-13  Gustavo Noronha Silva  <gns@gnome.org>
2956
2957         Unreviewed build fix.
2958
2959         * GNUmakefile.am: make sure we do not derreference the target link
2960         if it already exists, and replace it with the new one instead,
2961         otherwise we end up with a gtk link inside
2962         Source/WebKit2/UIProcess/API/gtk, which causes the documentation
2963         build to produce warnings, and make the build fail.
2964
2965 2011-12-13  Andreas Kling  <kling@webkit.org>
2966
2967         REGRESSION (r102652): New window opens with zero size at produbanco.com
2968         <http://webkit.org/b/74418> and <rdar://problem/10565998>
2969
2970         Reviewed by Anders Carlsson.
2971
2972         Don't use the cached window frame if it's empty (meaning we haven't received
2973         a WindowAndViewFramesChanged message yet.) Instead use the synchronous
2974         GetWindowFrame (WP->UIP) message.
2975
2976         This situation occurs when opening a new window via window.open(), in which
2977         WebCore::createWindow() will query the windowRect() on the new window.
2978
2979         I spent a long time trying to write a layout test for this but couldn't come
2980         up with something reliable. The windowRect() is non-empty before we get a
2981         chance to run JS in/on the new window, and we can't check against the
2982         requested geometry since it varies depending on whether the window manager
2983         has shown the new window yet.
2984
2985         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
2986         (WebKit::WebChromeClient::windowRect):
2987
2988 2011-12-13  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>
2989
2990         [Qt][WK2] Make QtPageClient dispatch directly to WebView when possible
2991         https://bugs.webkit.org/show_bug.cgi?id=74407
2992
2993         Reviewed by Simon Hausmann.
2994
2995         * UIProcess/API/qt/qquickwebview.cpp:
2996         (QQuickWebViewPrivate::QQuickWebViewPrivate):
2997         (QQuickWebViewPrivate::~QQuickWebViewPrivate):
2998         (QQuickWebViewPrivate::initialize):
2999         (QQuickWebViewPrivate::pageDidRequestScroll):
3000         (QQuickWebViewPrivate::processDidCrash):
3001         (QQuickWebViewPrivate::didRelaunchProcess):
3002         (QQuickWebViewPrivate::viewSize):
3003         (QQuickWebViewPrivate::didReceiveMessageFromNavigatorQtObject):
3004         (QQuickWebViewExperimental::QQuickWebViewExperimental):
3005         (QQuickWebView::QQuickWebView):
3006         * UIProcess/API/qt/qquickwebview_p_p.h:
3007         * UIProcess/qt/QtPageClient.cpp:
3008         (QtPageClient::QtPageClient):
3009         (QtPageClient::setViewNeedsDisplay):
3010         (QtPageClient::pageDidRequestScroll):
3011         (QtPageClient::processDidCrash):
3012         (QtPageClient::didRelaunchProcess):
3013         (QtPageClient::didChangeContentsSize):
3014         (QtPageClient::didChangeViewportProperties):
3015         (QtPageClient::createPopupMenuProxy):
3016         (QtPageClient::didReceiveMessageFromNavigatorQtObject):
3017         (QtPageClient::viewSize):
3018         (QtPageClient::isViewFocused):
3019         (QtPageClient::isViewVisible):
3020         * UIProcess/qt/QtPageClient.h:
3021         (QtPageClient::initialize):
3022         * UIProcess/qt/QtWebPageProxy.cpp:
3023         (QtWebPageProxy::QtWebPageProxy):
3024         * UIProcess/qt/QtWebPageProxy.h:
3025
3026 2011-12-13  Carlos Garcia Campos  <cgarcia@igalia.com>
3027
3028         [GTK] Add support for javascript dialogs in WebKit2 GTK+ API
3029         https://bugs.webkit.org/show_bug.cgi?id=71362
3030
3031         Reviewed by Martin Robinson.
3032
3033         * UIProcess/API/gtk/WebKitUIClient.cpp:
3034         (runJavaScriptAlert): Call webkitWebViewRunJavaScriptAlert().
3035         (runJavaScriptConfirm): Call webkitWebViewRunJavaScriptConfirm().
3036         (runJavaScriptPrompt): Call webkitWebViewRunJavaScriptPrompt().
3037         (webkitUIClientAttachUIClientToPage): Add implementation for
3038         runJavaScriptAlert, runJavaScriptConfirm and runJavaScriptPrompt
3039         callbacks.
3040         * UIProcess/API/gtk/WebKitWebView.cpp:
3041         (webkitWebViewCreateJavaScriptDialog):  Helper function to create
3042         javascript dialogs.
3043         (webkitWebViewScriptAlert): Default implementation of signal
3044         WebKitWebView::script-alert that shows a message dialog.
3045         (webkitWebViewScriptConfirm): Default implementation of signal
3046         WebKitWebView::script-confirm that shows a question dialog.
3047         (webkitWebViewScriptPrompt): Default implementation of signal
3048         WebKitWebView::script-prompt that shows a question dialog with a
3049         text entry.
3050         (webkit_web_view_class_init):
3051         (webkitWebViewRunJavaScriptAlert): Emit WebKitWebView::script-alert.
3052         (webkitWebViewRunJavaScriptConfirm): Emit WebKitWebView::script-confirm.
3053         (webkitWebViewRunJavaScriptPrompt): Emit WebKitWebView::script-prompt.
3054         * UIProcess/API/gtk/WebKitWebView.h:
3055         * UIProcess/API/gtk/WebKitWebViewPrivate.h:
3056         * UIProcess/API/gtk/tests/TestWebKitWebView.cpp:
3057         (testWebViewJavaScriptDialogs):
3058         (beforeAll):
3059         * UIProcess/API/gtk/webkit2marshal.list:
3060
3061 2011-12-13  Kenneth Rohde Christiansen  <kenneth@webkit.org>
3062
3063         [Qt] Make sure that touch events result in the page view gaining focus
3064
3065         Reviewed by Simon Hausmann.
3066
3067         * UIProcess/API/qt/qquickwebpage.cpp:
3068         (QQuickWebPage::touchEvent): Force active focus.
3069         * UIProcess/API/qt/qquickwebview.cpp:
3070         * UIProcess/API/qt/qquickwebview_p.h: Remove ::touchEvent override.
3071
3072 2011-12-13  Carlos Garcia Campos  <cgarcia@igalia.com>
3073
3074         [GTK] Initial UI client implementation for WebKit2 GTK +API
3075         https://bugs.webkit.org/show_bug.cgi?id=69753
3076
3077         Reviewed by Martin Robinson.
3078
3079         * GNUmakefile.am: Add new files to compilation.
3080         * UIProcess/API/gtk/WebKitUIClient.cpp: Added.
3081         (createNewPage): Call webkitWebViewCreateNewPage.
3082         (showPage): Call webkitWebViewReadyToShowPage.
3083         (closePage): Call webkitWebViewClosePage.
3084         (webkitUIClientAttachUIClientToPage): Initialize UI client and
3085         attach it to the given page.
3086         (webkit_ui_client_init):
3087         (webkit_ui_client_class_init):
3088         * UIProcess/API/gtk/WebKitUIClient.h: Added.
3089         * UIProcess/API/gtk/WebKitWebView.cpp:
3090         (webkitWebViewCreate): Default implementation of signal
3091         WebKitWebView::create that simply returns NULL.
3092         (webkitWebViewConstructed): Create the default UI client.
3093         (webkitWebViewAccumulatorObjectHandled):
3094         (webkit_web_view_class_init):
3095         (webkitWebViewCreateNewPage): Emit create signal.
3096         (webkitWebViewReadyToShowPage): Emit ready-to-show signal.
3097         (webkitWebViewClosePage): Emit close signal.
3098         * UIProcess/API/gtk/WebKitWebView.h:
3099         * UIProcess/API/gtk/WebKitWebViewPrivate.h:
3100         * UIProcess/API/gtk/tests/TestWebKitWebView.cpp:
3101         (testWebViewCreateReadyClose):
3102         (beforeAll):
3103         * UIProcess/API/gtk/webkit2marshal.list:
3104
3105 2011-12-13  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>
3106
3107         [Qt][WK2] Move load & navigation related functions out of QtWebPageProxy
3108         https://bugs.webkit.org/show_bug.cgi?id=74395
3109
3110         Reviewed by Simon Hausmann.
3111
3112         * Target.pri:
3113         * UIProcess/API/qt/qquickwebview.cpp:
3114         (QQuickWebViewPrivate::_q_onVisibleChanged):
3115         (QQuickWebViewPrivate::updateViewportSize):
3116         (QQuickWebViewPrivate::computeViewportConstraints):
3117         (QQuickWebViewPrivate::setUseTraditionalDesktopBehaviour):
3118         (QQuickWebViewPrivate::webPageProxy):
3119         (QQuickWebView::load):
3120         (QQuickWebView::goBack):
3121         (QQuickWebView::goForward):
3122         (QQuickWebView::stop):
3123         (QQuickWebView::reload):
3124         (QQuickWebView::url):
3125         (QQuickWebView::canGoBack):
3126         (QQuickWebView::canGoForward):
3127         (QQuickWebView::loading):
3128         (QQuickWebView::canReload):
3129         (QQuickWebView::title):
3130         (QQuickWebView::loadHtml):
3131         * UIProcess/API/qt/qquickwebview_p_p.h:
3132         * UIProcess/qt/QtWebPageProxy.cpp:
3133         (QtWebPageProxy::didReceiveMessageFromNavigatorQtObject):
3134         * UIProcess/qt/QtWebPageProxy.h:
3135
3136 2011-12-13  Carlos Garcia Campos  <cgarcia@igalia.com>
3137
3138         Unreviewed. Fix GTK+ build after r102640.
3139
3140         * GNUmakefile.am: Add DownloadProxy sources again.
3141
3142 2011-12-12  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>
3143
3144         [Qt][WK2] Move undo & edit command PageClient callbacks into QtWebUndoController
3145         https://bugs.webkit.org/show_bug.cgi?id=74364
3146
3147         Reviewed by Simon Hausmann.
3148
3149         The four callbacks in PageClient related to Undo depend only on the QUndoStack. So we
3150         move their handling to a QtWebUndoController (owned by QQuickWebViewPrivate). This also
3151         make QtWebUndoCommand an implementation detail.
3152
3153         * Target.pri:
3154         * UIProcess/API/qt/qquickwebview.cpp:
3155         (QQuickWebViewPrivate::QQuickWebViewPrivate):
3156         * UIProcess/API/qt/qquickwebview_p_p.h:
3157         * UIProcess/qt/QtPageClient.cpp:
3158         (QtPageClient::registerEditCommand):
3159         (QtPageClient::clearAllEditCommands):
3160         (QtPageClient::canUndoRedo):
3161         (QtPageClient::executeUndoRedo):
3162         * UIProcess/qt/QtPageClient.h:
3163         (QtPageClient::initialize):
3164         * UIProcess/qt/QtWebPageProxy.cpp:
3165         * UIProcess/qt/QtWebPageProxy.h:
3166         * UIProcess/qt/QtWebUndoController.cpp: Renamed from Source/WebKit2/UIProcess/qt/QtWebUndoCommand.cpp.
3167         (QtWebUndoCommand::inUndoRedo):
3168         (QtWebUndoCommand::QtWebUndoCommand):
3169         (QtWebUndoCommand::~QtWebUndoCommand):
3170         (QtWebUndoCommand::redo):
3171         (QtWebUndoCommand::undo):
3172         (QtWebUndoController::QtWebUndoController):
3173         (QtWebUndoController::registerEditCommand):
3174         (QtWebUndoController::clearAllEditCommands):
3175         (QtWebUndoController::canUndoRedo):
3176         (QtWebUndoController::executeUndoRedo):
3177         * UIProcess/qt/QtWebUndoController.h: Renamed from Source/WebKit2/UIProcess/qt/QtWebUndoCommand.h.
3178
3179 2011-12-12  Andreas Kling  <kling@webkit.org>
3180
3181         Resizing Cappuccino is very laggy on WebKit since Safari 5.1
3182         <http://webkit.org/b/71354> and <rdar://problem/10565998>
3183
3184         Reviewed by Anders Carlsson.
3185
3186         On Mac, we already cache the window rect through the WindowAndViewFramesChanged
3187         message, so simply return that in WebChromeClient::windowRect() instead of
3188         sending a synchronous query to the UIProcess.
3189
3190         Changed WindowAndViewFramesChanged to pass FloatRect/FloatPoint rather than
3191         IntRect/IntPoint to match the ChromeClient::windowRect() return type.
3192
3193         * UIProcess/API/mac/WKView.mm:
3194         (-[WKView _updateWindowAndViewFrames]):
3195         * UIProcess/WebPageProxy.cpp:
3196         (WebKit::WebPageProxy::setWindowFrame):
3197         * UIProcess/WebPageProxy.h:
3198         * UIProcess/mac/WebPageProxyMac.mm:
3199         (WebKit::WebPageProxy::windowAndViewFramesChanged):
3200         * WebProcess/Plugins/PluginView.cpp:
3201         (WebKit::PluginView::windowAndViewFramesChanged):
3202         * WebProcess/Plugins/PluginView.h:
3203         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
3204         (WebKit::WebChromeClient::windowRect):
3205         * WebProcess/WebPage/WebPage.cpp:
3206         (WebKit::WebPage::windowAndViewFramesChanged):
3207         * WebProcess/WebPage/WebPage.h:
3208         (WebKit::WebPage::windowFrameInScreenCoordinates):
3209         (WebKit::WebPage::viewFrameInWindowCoordinates):
3210         (WebKit::WebPage::accessibilityPosition):
3211         * WebProcess/WebPage/mac/WKAccessibilityWebPageObject.mm:
3212         (-[WKAccessibilityWebPageObject accessibilityAttributeValue:]):
3213
3214 2011-12-12  Anders Carlsson  <andersca@apple.com>
3215
3216         Add EventDispatcher class to WebKit2
3217         https://bugs.webkit.org/show_bug.cgi?id=74344
3218
3219         Reviewed by Sam Weinig.
3220
3221         The EventDispatcher is a singleton which will be in charge of dispatching events to WebPage objects.
3222
3223         * DerivedSources.make:
3224         * DerivedSources.pri:
3225         * GNUmakefile.am:
3226         * Target.pri:
3227         * WebKit2.xcodeproj/project.pbxproj:
3228         * win/WebKit2.vcproj:
3229         Add new files.
3230
3231         * Platform/CoreIPC/MessageID.h:
3232         Add EventDispatcher.
3233
3234         * WebProcess/WebConnectionToUIProcess.cpp:
3235         (WebKit::WebConnectionToUIProcess::WebConnectionToUIProcess):
3236         (WebKit::WebConnectionToUIProcess::invalidate):
3237         * WebProcess/WebConnectionToUIProcess.h:
3238         WebConnectionToUIProcess doesn't need to be a QueueClient. Also, move the call to open into WebProcess since
3239         we don't want to add queue clients after the connection has been opened.
3240
3241         * WebProcess/WebPage/EventDispatcher.cpp: Added.
3242         (WebKit::EventDispatcher::EventDispatcher):
3243         (WebKit::EventDispatcher::~EventDispatcher):
3244         (WebKit::EventDispatcher::didReceiveMessageOnConnectionWorkQueue):
3245         (WebKit::EventDispatcher::wheelEvent):
3246         * WebProcess/WebPage/EventDispatcher.h:
3247         * WebProcess/WebPage/EventDispatcher.messages.in: Added.
3248         Add new stub files.
3249
3250         * WebProcess/WebProcess.cpp:
3251         (WebKit::WebProcess::initialize):
3252         Add the event dispatcher as a queue client.
3253
3254         * WebProcess/WebProcess.h:
3255         Add an EventDispatcher member variable to the web process.
3256
3257 2011-12-12  Sam Weinig  <sam@webkit.org>
3258
3259         Prefix internal methods in Objective-C API files with an underscore
3260         https://bugs.webkit.org/show_bug.cgi?id=74363
3261
3262         Reviewed by Dan Bernstein.
3263
3264         * UIProcess/API/mac/WKBrowsingContextController.mm:
3265         (-[WKBrowsingContextController _pageRef]):
3266         (-[WKBrowsingContextController loadRequest:]):
3267         (-[WKBrowsingContextController loadFileURL:restrictToFilesWithin:]):
3268         (-[WKBrowsingContextController stopLoading]):
3269         (-[WKBrowsingContextController reload]):
3270         (-[WKBrowsingContextController reloadFromOrigin]):
3271         (-[WKBrowsingContextController goForward]):
3272         (-[WKBrowsingContextController canGoForward]):
3273         (-[WKBrowsingContextController goBack]):
3274         (-[WKBrowsingContextController canGoBack]):
3275         (-[WKBrowsingContextController activeURL]):
3276         (-[WKBrowsingContextController provisionalURL]):
3277         (-[WKBrowsingContextController committedURL]):
3278         (-[WKBrowsingContextController title]):
3279         (-[WKBrowsingContextController textZoom]):
3280         (-[WKBrowsingContextController setTextZoom:]):
3281         (-[WKBrowsingContextController pageZoom]):
3282         (-[WKBrowsingContextController setPageZoom:]):
3283         (-[WKBrowsingContextController setPaginationMode:]):
3284         (-[WKBrowsingContextController paginationMode]):
3285         (-[WKBrowsingContextController setPageLength:]):
3286         (-[WKBrowsingContextController pageLength]):
3287         (-[WKBrowsingContextController setGapBetweenPages:]):
3288         (-[WKBrowsingContextController gapBetweenPages]):
3289         (-[WKBrowsingContextController pageCount]):
3290         (-[WKBrowsingContextController _initWithPageRef:]):
3291         * UIProcess/API/mac/WKBrowsingContextControllerInternal.h:
3292         * UIProcess/API/mac/WKBrowsingContextGroup.mm:
3293         (-[WKBrowsingContextGroup allowsJavaScript]):
3294         (-[WKBrowsingContextGroup setAllowsJavaScript:]):
3295         (-[WKBrowsingContextGroup allowsPlugIns]):
3296         (-[WKBrowsingContextGroup setAllowsPlugIns:]):
3297         (-[WKBrowsingContextGroup _pageGroupRef]):
3298         * UIProcess/API/mac/WKBrowsingContextGroupInternal.h:
3299         * UIProcess/API/mac/WKConnection.mm:
3300         (-[WKConnection _initWithConnectionRef:]):
3301         * UIProcess/API/mac/WKConnectionInternal.h:
3302         * UIProcess/API/mac/WKProcessGroup.mm:
3303         (didCreateConnection):
3304         (-[WKProcessGroup _contextRef]):
3305         * UIProcess/API/mac/WKProcessGroupInternal.h:
3306         * UIProcess/API/mac/WKView.mm:
3307         (-[WKView initWithFrame:processGroup:browsingContextGroup:]):
3308         (-[WKView browsingContextController]):
3309
3310 2011-12-12  Ryosuke Niwa  <rniwa@webkit.org>
3311
3312         WebKit code shouldn't be calling applyCommand directly
3313         https://bugs.webkit.org/show_bug.cgi?id=74337
3314
3315         Reviewed by Darin Adler.
3316
3317         * WebProcess/WebPage/WebPage.cpp:
3318         (WebKit::WebPage::replaceSelectionWithText):
3319
3320 2011-12-12  Sam Weinig  <sam@webkit.org>
3321
3322         Remove unused getter on WKConnection.
3323
3324         Reviewed by Dan Bernstein.
3325
3326         * UIProcess/API/mac/WKConnection.mm:
3327
3328 2011-12-12  Brady Eidson  <beidson@apple.com>
3329
3330         Page cache should support pages with plugins.
3331         <rdar://problem/5190122> and https://bugs.webkit.org/show_bug.cgi?id=13634
3332
3333         Expose a WebKit2 preference for the page cache supporting plugins (on by default).
3334
3335         Reviewed by Anders Carlsson.
3336
3337         * Shared/WebPreferencesStore.h:
3338
3339         * UIProcess/API/C/WKPreferences.cpp:
3340         (WKPreferencesSetPageCacheSupportsPlugins):
3341         (WKPreferencesGetPageCacheSupportsPlugins):
3342         * UIProcess/API/C/WKPreferencesPrivate.h:
3343
3344         * WebProcess/WebPage/WebPage.cpp:
3345         (WebKit::WebPage::updatePreferences):
3346
3347 2011-12-12  Sam Weinig  <sam@webkit.org>
3348
3349         Add WKConnection objective-c wrapper around WKConnectionRef
3350         <rdar://problem/10446092>
3351         https://bugs.webkit.org/show_bug.cgi?id=74324
3352
3353         Reviewed by Anders Carlsson.
3354
3355         * UIProcess/API/mac/WKConnection.h: Added.
3356         * UIProcess/API/mac/WKConnection.mm: Added.
3357         (-[WKConnection dealloc]):
3358         (-[WKConnection connectionRef]):
3359         (-[WKConnection delegate]):
3360         (-[WKConnection setDelegate:]):
3361         (didReceiveMessage):
3362         (didClose):
3363         (setUpClient):
3364         (-[WKConnection initWithConnectionRef:]):
3365         * UIProcess/API/mac/WKConnectionInternal.h: Added.
3366         Added new class.
3367
3368         * UIProcess/API/mac/WKProcessGroup.h:
3369         * UIProcess/API/mac/WKProcessGroup.mm:
3370         (didCreateConnection):
3371         (setUpConnectionClient):
3372         (-[WKProcessGroup initWithInjectedBundleURL:]):
3373         (-[WKProcessGroup delegate]):
3374         (-[WKProcessGroup setDelegate:]):
3375         Add WKProcessGroupDelegate to inform the user of when connections are established.
3376
3377         * WebKit2.xcodeproj/project.pbxproj:
3378         Add new files.
3379
3380 2011-12-12  Anders Carlsson  <andersca@apple.com>
3381
3382         Rename QueueClient::willProcessMessageOnClientRunLoop
3383         https://bugs.webkit.org/show_bug.cgi?id=74325
3384
3385         Reviewed by Sam Weinig.
3386
3387         Rename the QueueClient willProcessMessageOnClientRunLoop function to didReceiveMessageOnConnectionWorkQueue
3388         and give it an out parameter to indicate whether the message was handled or not. This makes it more clear that
3389         the function is expected to handle the message.
3390
3391         * Platform/CoreIPC/Connection.cpp:
3392         (CoreIPC::Connection::processIncomingMessage):
3393         * Platform/CoreIPC/Connection.h:
3394         * Scripts/webkit2/messages.py:
3395         (async_case_statement):
3396         * Scripts/webkit2/messages_unittest.py:
3397         * WebProcess/WebConnectionToUIProcess.cpp:
3398         (WebKit::WebConnectionToUIProcess::didReceiveMessageOnConnectionWorkQueue):
3399         * WebProcess/WebConnectionToUIProcess.h:
3400         * WebProcess/WebProcess.cpp:
3401         (WebKit::WebProcess::didReceiveMessageOnConnectionWorkQueue):
3402         * WebProcess/WebProcess.h:
3403
3404 2011-12-12  Alexis Menard  <alexis.menard@openbossa.org>
3405
3406         Unreviewed cleanup fix.
3407
3408         Add missing files from https://bugs.webkit.org/show_bug.cgi?id=73016
3409
3410         Also remove the files that should be removed.
3411
3412         * UIProcess/API/qt/tests/qmltests/WebView/tst_navigationHistory.qml: Added.
3413         * UIProcess/qt/qwkhistory.cpp: Removed.
3414         * UIProcess/qt/qwkhistory.h: Removed.
3415         * UIProcess/qt/qwkhistory_p.h: Removed.
3416
3417 2011-12-12  Michael Bruning  <michael.bruning@nokia.com>
3418
3419         [qt][wk2] Postpone scroll effects when page transition is ongoing.
3420         https://bugs.webkit.org/show_bug.cgi?id=74177
3421
3422         Reviewed by Kenneth Rohde Christiansen.
3423
3424         * UIProcess/API/qt/qquickwebview.cpp:
3425         (QQuickWebViewPrivate::scrollPositionRequested):
3426         * UIProcess/API/qt/qquickwebview_p_p.h:
3427         (QQuickWebViewPrivate::PostTransitionState::apply):
3428
3429 2011-12-12  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>
3430
3431         [Qt][WK2] Remove dead code from QtWebPageProxy
3432         https://bugs.webkit.org/show_bug.cgi?id=74296
3433
3434         Reviewed by Andreas Kling.
3435
3436         * UIProcess/qt/QtWebPageProxy.cpp:
3437         * UIProcess/qt/QtWebPageProxy.h:
3438
3439 2011-12-12  Simon Hausmann  <simon.hausmann@nokia.com>
3440
3441         Unreviewed build fix.
3442
3443         Add missing files from https://bugs.webkit.org/show_bug.cgi?id=73016
3444
3445         * UIProcess/API/qt/qwebnavigationhistory.cpp: Added.
3446         (QWebNavigationListModelPrivate::QWebNavigationListModelPrivate):
3447         (QWebNavigationListModelPrivate::createWebNavigationModel):
3448         (QWebNavigationHistoryPrivate::QWebNavigationHistoryPrivate):
3449         (QWebNavigationHistoryPrivate::createHistory):
3450         (QWebNavigationHistoryPrivate::reset):
3451         (QWebNavigationHistoryPrivate::goBackTo):
3452         (QWebNavigationHistoryPrivate::goForwardTo):
3453         (QWebNavigationListModel::QWebNavigationListModel):
3454         (QWebNavigationListModel::~QWebNavigationListModel):
3455         (QWebNavigationListModel::rowCount):
3456         (QWebNavigationListModel::data):
3457         (QWebNavigationHistory::QWebNavigationHistory):
3458         (QWebNavigationHistory::~QWebNavigationHistory):
3459         (QWebNavigationHistory::backItems):
3460         (QWebNavigationHistory::forwardItems):
3461         * UIProcess/API/qt/qwebnavigationhistory_p.h: Added.
3462         * UIProcess/API/qt/qwebnavigationhistory_p_p.h: Added.
3463
3464 2011-12-12  Simon Hausmann  <simon.hausmann@nokia.com>
3465
3466         [Qt] Move postMessage/messageReceived APIS to experimental
3467
3468         Reviewed by Tor Arne Vestbø.
3469
3470         * UIProcess/API/qt/qquickwebview.cpp:
3471         (QQuickWebViewPrivate::setPageProxy):
3472         (QQuickWebViewExperimental::QQuickWebViewExperimental):
3473         (QQuickWebViewExperimental::postMessage):
3474         * UIProcess/API/qt/qquickwebview_p.h:
3475         * UIProcess/API/qt/tests/qmltests/DesktopBehavior/tst_messaging.qml:
3476
3477 2011-12-12  Alexis Menard  <alexis.menard@openbossa.org>
3478
3479         [Qt][WK2] History is not accessible in QML.
3480         https://bugs.webkit.org/show_bug.cgi?id=73016
3481
3482         Reviewed by Simon Hausmann.
3483
3484         Remove the old qwkhistory and create QWebNavigationHistory which is QML
3485         friendly with data models you can plug to a view in QML
3486
3487         * Target.pri:
3488         * UIProcess/API/qt/qquickwebview.cpp:
3489         (QQuickWebViewPrivate::didChangeBackForwardList):
3490         (QQuickWebViewExperimental::navigationHistory):
3491         (QQuickWebViewExperimental::goForwardTo):
3492         (QQuickWebViewExperimental::goBackTo):
3493         * UIProcess/API/qt/qquickwebview_p.h:
3494         * UIProcess/API/qt/qquickwebview_p_p.h:
3495         * UIProcess/API/qt/qwebnavigationhistory.cpp: Added.
3496         (QWebNavigationListModelPrivate::QWebNavigationListModelPrivate):
3497         (QWebNavigationListModelPrivate::createWebNavigationModel):
3498         (QWebNavigationHistoryPrivate::QWebNavigationHistoryPrivate):