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