initial import
[vuplus_webkit] / Source / WebKit2 / ChangeLog
1 2011-09-15  Alexis Menard  <alexis.menard@openbossa.org>
2
3         [Qt][WK2] Make QWebError more friendly to QML.
4         https://bugs.webkit.org/show_bug.cgi?id=67785
5
6         Reviewed by Simon Hausmann.
7
8         Make sure that we can use the loading errors in QML. We send it via a QJSValue which
9         has the properties needed to get the error code, the url and the type of error.
10
11         * UIProcess/API/qt/qdesktopwebview.cpp:
12         (QDesktopWebViewPrivate::loadDidFail):
13         (QDesktopWebViewPrivate::engine):
14         * UIProcess/API/qt/qdesktopwebview.h:
15         * UIProcess/API/qt/qdesktopwebview_p.h:
16         * UIProcess/API/qt/qtouchwebpage.h:
17         * UIProcess/API/qt/tests/commonviewtests/tst_commonviewtests.cpp:
18         (tst_CommonViewTests::loadNonexistentFileUrl):
19         * UIProcess/API/qt/tests/commonviewtests/webviewabstraction.cpp:
20         (WebViewAbstraction::WebViewAbstraction):
21         (WebViewAbstraction::touchViewLoadFailed):
22         (WebViewAbstraction::desktopViewLoadFailed):
23         * UIProcess/API/qt/tests/commonviewtests/webviewabstraction.h:
24         * UIProcess/API/qt/tests/testwindow.h:
25         * UIProcess/qt/QtWebPageProxy.cpp:
26         (QtWebPageProxy::loadDidFail):
27         * UIProcess/qt/QtWebPageProxy.h:
28         * UIProcess/qt/TouchViewInterface.cpp:
29         (WebKit::TouchViewInterface::loadDidFail):
30         (WebKit::TouchViewInterface::engine):
31         * UIProcess/qt/TouchViewInterface.h:
32         * UIProcess/qt/ViewInterface.h:
33
34 2011-09-15  Adam Roben  <aroben@apple.com>
35
36         Remove WebKit2-specific knowledge from the Message class
37
38         This is in preparation for making some of our message-generations scripts usable by other
39         projects.
40
41         Fixes <http://webkit.org/b/68170> Model classes in WebKit2's message-generation scripts know
42         too much about WebKit2 details
43
44         Reviewed by Anders Carlsson.
45
46         * Scripts/webkit2/messages.py: Added constants for the message attributes we support.
47         (MessageReceiver.parse): Instead of recognizing individual attributes, just stick the
48         attributes into a set and pass it to the Message constructor.
49         (Message.__init__): Changed to take a generic set of attributes instead of individual
50         attributes.
51         (Message.has_attribute): Added. Returns true if the message has an attribute.
52         (message_is_variadic): Renamed from parameter_type_is_variadic. Code came from
53         Message.__init__, which set the old message.is_variadic property.
54
55         (decode_type):
56         (message_to_struct_declaration):
57         (forward_declarations_and_headers):
58         (async_case_statement):
59         (sync_case_statement):
60         (generate_message_handler):
61         Updated to use Message.has_attribute and message_is_variadic.
62
63 2011-09-14  Wajahat Siddiqui  <mdwajahatali.siddiqui@motorola.com>
64
65         Eliminate WebKit2 compilation warnings.
66         https://bugs.webkit.org/show_bug.cgi?id=65025
67
68         Warnings found with gcc on linux.
69
70         Reviewed by Sam Weinig.
71
72         * Platform/CoreIPC/ArgumentEncoder.cpp:
73         (CoreIPC::ArgumentEncoder::~ArgumentEncoder):
74         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
75         (WebKit::WebFrameLoaderClient::createPlugin):
76
77 2011-09-14  Ada Chan  <adachan@apple.com>
78
79         Implement WKBundleFrameCopyWebArchive().
80         http://bugs.webkit.org/show_bug.cgi?id=67857
81
82         Reviewed by Anders Carlsson.
83
84         * WebProcess/InjectedBundle/API/c/WKBundleFrame.cpp:
85         (WKBundleFrameCopyWebArchive): Call WebFrame::webArchiveData() and create a WKDataRef from the returned CFDataRef.
86         * WebProcess/InjectedBundle/API/c/WKBundleFrame.h:
87         * WebProcess/WebPage/WebFrame.cpp:
88         (WebKit::WebFrame::webArchiveData): Add WebFrame::webArchiveData().
89         * WebProcess/WebPage/WebFrame.h:
90         * WebProcess/WebPage/WebPage.cpp:
91         (WebKit::WebPage::getWebArchiveOfFrame): Move the logic to WebFrame::webArchiveData() and call that method here.
92
93 2011-09-14  Alexey Proskuryakov  <ap@apple.com>
94
95         Web Process doesn't need a permission to look up WebProcess service any more
96         https://bugs.webkit.org/show_bug.cgi?id=68101
97
98         Reviewed by Anders Carlsson.
99
100         * WebProcess/com.apple.WebProcess.sb:
101
102 2011-09-14  Mark Hahnenberg  <mhahnenberg@apple.com>
103
104         Unzip initialization lists and constructors in JSCell hierarchy (6/7)
105         https://bugs.webkit.org/show_bug.cgi?id=67692
106
107         Reviewed by Geoffrey Garen.
108
109         Completed the sixth level of the refactoring to add finishCreation() 
110         methods to all classes within the JSCell hierarchy with non-trivial 
111         constructor bodies.
112
113         This primarily consists of pushing the calls to finishCreation() down 
114         into the constructors of the subclasses of the fifth level of the hierarchy 
115         as well as pulling the finishCreation() calls out into the class's corresponding
116         create() method if it has one.  Doing both simultaneously allows us to 
117         maintain the invariant that the finishCreation() method chain is called exactly 
118         once during the creation of an object, since calling it any other number of 
119         times (0, 2, or more) will cause an assertion failure.
120
121         * WebProcess/Plugins/Netscape/JSNPMethod.cpp:
122         (WebKit::JSNPMethod::JSNPMethod):
123         * WebProcess/Plugins/Netscape/JSNPMethod.h:
124         (WebKit::JSNPMethod::create):
125
126 2011-09-13  Eric Seidel  <eric@webkit.org>
127
128         Remove ENABLE_SVG_USE as <use> is required by HTML5
129         https://bugs.webkit.org/show_bug.cgi?id=68019
130
131         Reviewed by Ryosuke Niwa.
132
133         * Configurations/FeatureDefines.xcconfig:
134
135 2011-09-13  Anders Carlsson  <andersca@apple.com>
136
137         Disable C++ exceptions when building with clang
138         https://bugs.webkit.org/show_bug.cgi?id=68031
139         <rdar://problem/9556880>
140
141         Reviewed by Mark Rowe.
142
143         * Configurations/Base.xcconfig:
144
145 2011-09-13  Eric Seidel  <eric@webkit.org>
146
147         Remove ENABLE_SVG_FOREIGN_OBJECT as it is a required part of HTML5
148         https://bugs.webkit.org/show_bug.cgi?id=68018
149
150         Reviewed by Ryosuke Niwa.
151
152         * Configurations/FeatureDefines.xcconfig:
153
154 2011-09-13  Chang Shu  <cshu@webkit.org>
155
156         [WK2] [Mac] Implement KeyDown function for WebKit2 EventSender.
157         https://bugs.webkit.org/show_bug.cgi?id=57515
158
159         The code change in WebKit2 allows key events being sent to WebProcess from UIProcess synchronously.
160
161         Reviewed by Darin Adler.
162
163         * UIProcess/API/C/WKPage.cpp:
164         (WKPageSetShouldSendKeyboardEventSynchronously):
165         * UIProcess/API/C/WKPagePrivate.h:
166         * UIProcess/WebPageProxy.cpp:
167         (WebKit::WebPageProxy::WebPageProxy):
168         (WebKit::WebPageProxy::handleKeyboardEvent):
169         * UIProcess/WebPageProxy.h:
170         (WebKit::WebPageProxy::setShouldSendKeyboardEventSynchronously):
171         * WebProcess/WebPage/WebPage.cpp:
172         (WebKit::WebPage::keyEventSyncForTesting):
173         * WebProcess/WebPage/WebPage.h:
174         * WebProcess/WebPage/WebPage.messages.in:
175
176 2011-09-12  Ryuan Choi  <ryuan.choi@samsung.com>
177
178         Reviewed by Eric Seidel.
179
180         [CMAKE][WK2] include cmakeconfig.h in WebKit2/config.h
181         https://bugs.webkit.org/show_bug.cgi?id=62692
182
183         * CMakeLists.txt: define WTF_USE_JSC=1.
184         * config.h: add cmakeconfig.h and define necessary macros for CMake build.
185
186 2011-09-12  Igor Oliveira  <igor.oliveira@openbossa.org>
187
188         [Qt] [WK2] implement support to upload files in Qt WebKit2
189         https://bugs.webkit.org/show_bug.cgi?id=67228
190
191         This patch implements support to upload files in the Desktop Qt WebKit2 implementation.
192
193         Reviewed by Andreas Kling.
194
195         * Shared/WebOpenPanelParameters.h:
196         (WebKit::WebOpenPanelParameters::selectedFileNames):
197         * UIProcess/API/qt/qdesktopwebview.cpp:
198         (QDesktopWebViewPrivate::chooseFiles):
199         (QDesktopWebViewPrivate::onOpenPanelFilesSelected):
200         (QDesktopWebViewPrivate::onOpenPanelFinished):
201         * UIProcess/API/qt/qdesktopwebview_p.h:
202         * UIProcess/qt/ClientImpl.cpp:
203
204         qt_wk_runOpenPanel supports single and multiple files selection.
205
206         (qt_wk_runOpenPanel):
207         * UIProcess/qt/ClientImpl.h:
208         * UIProcess/qt/QtWebPageProxy.cpp:
209         (QtWebPageProxy::init):
210         * UIProcess/qt/TouchViewInterface.h:
211         (WebKit::TouchViewInterface::chooseFiles):
212         * UIProcess/qt/ViewInterface.h:
213
214 2011-09-12  Alexis Menard  <alexis.menard@openbossa.org>
215
216         [Qt]Style error fix.
217
218         Reviewed by Andreas Kling.
219
220         * UIProcess/qt/QtWebPageProxy.cpp:
221
222 2011-09-11  Mark Rowe  <mrowe@apple.com>
223
224         <rdar://problem/9878268> Pressing caps lock after closing a showModalDialog window results in WebProcess exiting
225
226         It's incorrect to try and use -[NSApplication run] to run nested runloops as it is not possible to
227         interrupt a nested invocation of -run without also causing outer invocations to exit after processing
228         their next event. We can avoid this issue by using -[NSApplication run] for the outermost invocation
229         of the main runloop, while using CFRunLoopRun for any nested invocations.
230
231         Reviewed by Anders Carlsson.
232
233         * Platform/RunLoop.h:
234         * Platform/mac/RunLoopMac.mm:
235         (RunLoop::RunLoop): Initialize the nesting level to 0.
236         (RunLoop::run): Bump the nesting level, and only use -[NSApplication run] for the outermost invocation of the
237         runloop. We also switch from -[NSRunloop run] to CFRunLoopRun as the former will only exit when it has no sources
238         left to process, while CFRunLoopRun will return immediately after CFRunLoopStop is called on it.
239         (RunLoop::stop): Only go down the NSApp path for the outermost invocation of the runloop.
240
241 2011-09-11  Balazs Kelemen  <kbalazs@webkit.org>
242
243         [Qt][WK2] Qt layer should be hardened against C API versioning in the sense of build failures
244         https://bugs.webkit.org/show_bug.cgi?id=67094
245
246         Reviewed by Andreas Kling.
247
248         * UIProcess/qt/QtWebPageProxy.cpp:
249         (QtWebPageProxy::init):
250
251 2011-09-09  Oliver Hunt  <oliver@apple.com>
252
253         Remove support for anonymous storage from jsobjects
254         https://bugs.webkit.org/show_bug.cgi?id=67881
255
256         Reviewed by Sam Weinig.
257
258         Remove the use of AnonymousSlotCount.
259
260         * WebProcess/Plugins/Netscape/JSNPMethod.h:
261         (WebKit::JSNPMethod::createStructure):
262         * WebProcess/Plugins/Netscape/JSNPObject.h:
263         (WebKit::JSNPObject::createStructure):
264
265 2011-09-09  Chris Marrin  <cmarrin@apple.com>
266
267         requestAnimationFrame doesn't throttle on Mac
268         https://bugs.webkit.org/show_bug.cgi?id=67171
269
270         Reviewed by Simon Fraser.
271
272         Removed runLoopObserver for requestAnimationFrame. It's now
273         done by a Timer in ScriptedAnimationController in WebCore.
274
275         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
276         * WebProcess/WebCoreSupport/WebChromeClient.h:
277         * WebProcess/WebPage/WebPage.cpp:
278         (WebKit::WebPage::~WebPage):
279         * WebProcess/WebPage/WebPage.h:
280         * WebProcess/WebPage/mac/WebPageMac.mm:
281
282 2011-09-09  Fady Samuel  <fsamuel@chromium.org>
283
284         Move pageScaleFactor code from Frame.{h|cpp} to Page.{h|cpp}
285         https://bugs.webkit.org/show_bug.cgi?id=67250
286
287         Reviewed by Simon Fraser.
288
289         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
290         (WebKit::WebFrameLoaderClient::dispatchDidCommitLoad):
291         * WebProcess/WebPage/WebPage.cpp:
292         (WebKit::WebPage::scalePage):
293         (WebKit::WebPage::pageScaleFactor):
294
295 2011-09-09  Mark Hahnenberg  <mhahnenberg@apple.com>
296
297         Unzip initialization lists and constructors in JSCell hierarchy (5/7)
298         https://bugs.webkit.org/show_bug.cgi?id=67420
299
300         Reviewed by Geoffrey Garen.
301
302         Completed the fifth level of the refactoring to add finishCreation() 
303         methods to all classes within the JSCell hierarchy with non-trivial 
304         constructor bodies.
305
306         This primarily consists of pushing the calls to finishCreation() down 
307         into the constructors of the subclasses of the second level of the hierarchy 
308         as well as pulling the finishCreation() calls out into the class's corresponding
309         create() method if it has one.  Doing both simultaneously allows us to 
310         maintain the invariant that the finishCreation() method chain is called exactly 
311         once during the creation of an object, since calling it any other number of 
312         times (0, 2, or more) will cause an assertion failure.
313
314         * WebProcess/Plugins/Netscape/JSNPMethod.cpp:
315         (WebKit::JSNPMethod::JSNPMethod):
316         (WebKit::JSNPMethod::finishCreation):
317         * WebProcess/Plugins/Netscape/JSNPMethod.h:
318         (WebKit::JSNPMethod::create):
319         * WebProcess/Plugins/Netscape/JSNPObject.cpp:
320         (WebKit::JSNPObject::JSNPObject):
321         * WebProcess/Plugins/Netscape/JSNPObject.h:
322         (WebKit::JSNPObject::create):
323
324 2011-09-08  Mark Rowe  <mrowe@apple.com>
325
326         <rdar://problem/9742393> Spell checking a text area causes the page to reload
327
328         Ensure that m_pendingLearnOrIgnoreWordMessageCount is incremented when we use
329         executeEditCommand to ignore a word. This will ensure that WebPageProxy::ignoreWord
330         is expecting to be called, and will not turn around and terminate the web process.
331
332         Reviewed by Anders Carlsson.
333
334         * UIProcess/WebPageProxy.cpp:
335         (WebKit::WebPageProxy::executeEditCommand):
336
337 2011-09-08  Sam Weinig  <sam@webkit.org>
338
339         Remove accidentally committed typo.
340
341         * Platform/CoreIPC/Connection.cpp:
342         (CoreIPC::Connection::waitForSyncReply):
343
344 2011-09-08  Brian Weinstein  <bweinstein@apple.com>
345
346         WebKit2: Assertion when calling didPerform*Redirect on null source/destination URL string
347         https://bugs.webkit.org/show_bug.cgi?id=67794
348         <rdar://problem/9892024>
349         
350         Don't call didPerformClientRedirect or didPerformServerRedirect when source or destination URL string
351         is empty or null.
352         
353         If we call didPerformClientRedirect or didPerformServerRedirect when the source or destination is null,
354         it causes an assert in WKURLCF::WKURLCopyCFURL when we try to convert the WKURLRef into a CFURLRef.
355
356         Reviewed by Brady Eidson.
357
358         * UIProcess/WebContext.cpp:
359         (WebKit::WebContext::didPerformClientRedirect): Return early if the source or destination URL string is empty or null.
360         (WebKit::WebContext::didPerformServerRedirect): Ditto.
361
362 2011-09-08  Sam Weinig  <sam@webkit.org>
363
364         Remove the Completion object from JSC, I have never liked it
365         https://bugs.webkit.org/show_bug.cgi?id=67755
366
367         Reviewed by Gavin Barraclough.
368
369         * WebProcess/Plugins/Netscape/NPRuntimeObjectMap.cpp:
370         (WebKit::NPRuntimeObjectMap::evaluate):
371
372 2011-09-08  Anders Carlsson  <andersca@apple.com>
373
374         Don't release the modal placeholder window if it's closed
375         https://bugs.webkit.org/show_bug.cgi?id=67801
376         <rdar://problem/10088059>
377
378         Reviewed by Adam Roben.
379
380         This is a speculative fix - nothing should really be able to close the modal placeholder window.
381
382         * UIProcess/Plugins/mac/PluginProcessProxyMac.mm:
383         (WebKit::PluginProcessProxy::beginModal):
384
385 2011-09-07  Alexei Svitkine  <asvitkine@chromium.org>
386
387         Add test infrastructure to test rubber-banding overhang drawing along with layout tests for existing Chromium Mac overhang drawing in the non-gpu path.
388         https://bugs.webkit.org/show_bug.cgi?id=67511
389
390         Reviewed by Dimitri Glazkov.
391
392         * win/WebKit2.def:
393         * win/WebKit2CFLite.def:
394
395 2011-09-06  Oliver Hunt  <oliver@apple.com>
396
397         Remove JSObjectWithGlobalObject
398         https://bugs.webkit.org/show_bug.cgi?id=67689
399
400         Reviewed by Geoff Garen.
401
402         Remove JSObjectWithGlobalObject usage.
403
404         * WebProcess/Plugins/Netscape/JSNPObject.cpp:
405         (WebKit::JSNPObject::JSNPObject):
406         (WebKit::JSNPObject::finishCreation):
407         * WebProcess/Plugins/Netscape/JSNPObject.h:
408
409 2011-09-05  Jocelyn Turcotte  <jocelyn.turcotte@nokia.com>
410
411         [Qt][WK2] Make TiledDrawingArea request tiles only in the direction the viewport is panned to.
412         https://bugs.webkit.org/show_bug.cgi?id=67606
413
414         TiledBackingStore previously used different values for horizontal and vertial multiplication
415         to calculate the cover area. 
416         This patch replaces this mechanism, used to give a bigger panning range to vertical panning,
417         with the possibility to use the motion vector of the viewport to request tiles ahead instead.
418         This allows economies on rendering resources as tiles won't be rendered beside the trajectory
419         of the viewport.
420
421         * UIProcess/API/qt/qtouchwebview.cpp:
422         (QTouchWebViewPrivate::QTouchWebViewPrivate):
423         (QTouchWebViewPrivate::_q_viewportMotionVectorChanged):
424         * UIProcess/API/qt/qtouchwebview.h:
425         * UIProcess/API/qt/qtouchwebview_p.h:
426         * UIProcess/TiledDrawingAreaProxy.cpp:
427         (WebKit::TiledDrawingAreaProxy::setVisibleContentRectMotionVector):
428         * UIProcess/TiledDrawingAreaProxy.h:
429         * UIProcess/qt/ViewportInteractionEngine.cpp:
430         (WebKit::ViewportInteractionEngine::panGestureRequestUpdate):
431         (WebKit::ViewportInteractionEngine::panGestureEnded):
432         (WebKit::ViewportInteractionEngine::pinchGestureStarted):
433         * UIProcess/qt/ViewportInteractionEngine.h:
434         * UIProcess/qt/qtouchwebpageproxy.cpp:
435         (QTouchWebPageProxy::setVisibleContentRectMotionVector):
436         * UIProcess/qt/qtouchwebpageproxy.h:
437         * WebProcess/WebPage/DrawingArea.h:
438         (WebKit::DrawingArea::setVisibleContentRectMotionVector):
439         * WebProcess/WebPage/DrawingArea.messages.in:
440         * WebProcess/WebPage/TiledDrawingArea.cpp:
441         (WebKit::TiledDrawingArea::setVisibleContentRectMotionVector):
442         * WebProcess/WebPage/TiledDrawingArea.h:
443
444 2011-09-01  Jocelyn Turcotte  <jocelyn.turcotte@nokia.com>
445
446         [Qt] TiledBackingStore: Import the resizeEdgeTiles logic from TiledDrawindAreaProxy.
447         https://bugs.webkit.org/show_bug.cgi?id=67416
448
449         Reviewed by Kenneth Rohde Christiansen.
450
451         Original code by Antti Koivisto.
452         With the current code, when the page is layouted during load, edge tiles will
453         get removed instead of continuing to show their front buffer while the tile
454         is being rendered for the new size.
455
456         * WebProcess/WebPage/TiledBackingStoreRemoteTile.cpp:
457         (WebKit::TiledBackingStoreRemoteTile::updateBackBuffer):
458         (WebKit::TiledBackingStoreRemoteTile::resize):
459         * WebProcess/WebPage/TiledBackingStoreRemoteTile.h:
460
461 2011-09-01  Jocelyn Turcotte  <jocelyn.turcotte@nokia.com>
462
463         TiledDrawingArea: Fix issues where the tiles of the previous scale would be removed too early.
464         https://bugs.webkit.org/show_bug.cgi?id=67390
465
466         Reviewed by Tor Arne Vestbø.
467
468         The two issues addresssed are:
469         - The previous instance of the tile backing store would be destroyed in createTile which
470           would send removeTile messages for all its tiles before the DidRenderFrame message is sent for the new tiles.
471         - When quickly changing the scale a second time after a scale change, the previous tile set would
472           be replaced by the current incomplete tile set which may contain no tiles at all.
473         * WebProcess/WebPage/TiledDrawingArea.cpp:
474         (WebKit::TiledDrawingArea::setVisibleContentRectAndScale):
475         (WebKit::TiledDrawingArea::tiledBackingStorePaintEnd):
476         (WebKit::TiledDrawingArea::createTile):
477
478 2011-08-30  Jocelyn Turcotte  <jocelyn.turcotte@nokia.com>
479
480         [Qt][WK2] The scene graph is rendered continuously even when the page is idle.
481         https://bugs.webkit.org/show_bug.cgi?id=67195
482
483         Reviewed by Tor Arne Vestbø.
484
485         Since tiledBackingStorePaintEnd is called even when no tile is dirty, the TiledDrawingArea
486         and its proxy are looping over DidRenderFrame and RenderNextFrame messages.
487         This causes QSGItem::update() to be called and consumes a lot of useless CPU cycles on the UI process.
488
489         Introduce a bool to send DidRenderFrame only when dirty content was rendered.
490
491         * WebProcess/WebPage/TiledDrawingArea.cpp:
492         (WebKit::TiledDrawingArea::TiledDrawingArea):
493         (WebKit::TiledDrawingArea::tiledBackingStorePaint):
494         (WebKit::TiledDrawingArea::tiledBackingStorePaintEnd):
495         * WebProcess/WebPage/TiledDrawingArea.h:
496
497 2011-08-30  Jocelyn Turcotte  <jocelyn.turcotte@nokia.com>
498
499         [Qt][WK2] Make sure that the visible content rect and the content scale get to the web process in one single message.
500         https://bugs.webkit.org/show_bug.cgi?id=67189
501
502         Reviewed by Kenneth Rohde Christiansen.
503
504         The TiledBackingStore needs to know the screen size of the viewport to know how many tiles to
505         create, and since the visible content rect is given in page coordinates, the contents scale is
506         necessary to calculate the viewport size.
507         Both the rect and the scale then need to arrive to the web process at the same time to prevent
508         picking the new visible rect with the old scale or vice-versa which can produce a huge viewport size
509         and create/render an insane amount of tiles.
510
511         Things this patch does:
512         - Merge the visible contents rect and content scale handling together.
513         - Make QTouchWebView responsible for telling those viewport values to the web process instead of QTouchWebPage.
514         - Prevent updating the viewport in ViewportInteractionEngine while a pinch is in progress and update the viewport at the end.
515
516         * UIProcess/API/qt/qtouchwebpage.cpp:
517         * UIProcess/API/qt/qtouchwebpage.h:
518         * UIProcess/API/qt/qtouchwebpage_p.h:
519         * UIProcess/API/qt/qtouchwebview.cpp:
520         (QTouchWebViewPrivate::QTouchWebViewPrivate):
521         (QTouchWebViewPrivate::_q_viewportUpdated):
522         (QTouchWebView::geometryChanged):
523         * UIProcess/API/qt/qtouchwebview.h:
524         * UIProcess/API/qt/qtouchwebview_p.h:
525         * UIProcess/TiledDrawingAreaProxy.cpp:
526         (WebKit::TiledDrawingAreaProxy::setVisibleContentRectAndScale):
527         * UIProcess/TiledDrawingAreaProxy.h:
528         * UIProcess/qt/ViewportInteractionEngine.cpp:
529         (WebKit::ViewportInteractionEngine::ViewportInteractionEngine):
530         (WebKit::ViewportInteractionEngine::~ViewportInteractionEngine): Allows OwnPtr with the forward declaration of ViewportUpdateGuard.
531         (WebKit::ViewportInteractionEngine::setConstraints):
532         (WebKit::ViewportInteractionEngine::pinchGestureStarted):
533         (WebKit::ViewportInteractionEngine::pinchGestureEnded):
534         (WebKit::ViewportInteractionEngine::contentViewportChanged):
535         * UIProcess/qt/ViewportInteractionEngine.h:
536         * UIProcess/qt/qtouchwebpageproxy.cpp:
537         (QTouchWebPageProxy::setVisibleContentRectAndScale):
538         * UIProcess/qt/qtouchwebpageproxy.h:
539         * WebProcess/WebPage/DrawingArea.h:
540         (WebKit::DrawingArea::setVisibleContentRectAndScale):
541         * WebProcess/WebPage/DrawingArea.messages.in:
542         * WebProcess/WebPage/TiledDrawingArea.cpp:
543         (WebKit::TiledDrawingArea::setVisibleContentRectAndScale):
544         * WebProcess/WebPage/TiledDrawingArea.h:
545
546 2011-08-29  Jocelyn Turcotte  <jocelyn.turcotte@nokia.com>
547
548         [Qt][WK2] Rename SGAgent to SGUpdateQueue to sharpen it's responsability.
549         https://bugs.webkit.org/show_bug.cgi?id=67122
550
551         Reviewed by Tor Arne Vestbø.
552
553         * UIProcess/API/qt/qtouchwebpage.cpp:
554         (QTouchWebPage::updatePaintNode):
555         (QTouchWebPagePrivate::QTouchWebPagePrivate):
556         * UIProcess/API/qt/qtouchwebpage_p.h:
557         * UIProcess/qt/SGUpdateQueue.cpp: Renamed from Source/WebKit2/UIProcess/qt/SGAgent.cpp.
558         (WebKit::NodeUpdateCreateTile::NodeUpdateCreateTile):
559         (WebKit::NodeUpdateRemoveTile::NodeUpdateRemoveTile):
560         (WebKit::NodeUpdateSetBackBuffer::NodeUpdateSetBackBuffer):
561         (WebKit::NodeUpdateSwapTileBuffers::NodeUpdateSwapTileBuffers):
562         (WebKit::SGUpdateQueue::SGUpdateQueue):
563         (WebKit::SGUpdateQueue::createTileNode):
564         (WebKit::SGUpdateQueue::removeTileNode):
565         (WebKit::SGUpdateQueue::setNodeBackBuffer):
566         (WebKit::SGUpdateQueue::swapTileBuffers):
567         (WebKit::SGUpdateQueue::applyUpdates):
568         (WebKit::SGUpdateQueue::getScaleNode):
569         * UIProcess/qt/SGUpdateQueue.h: Renamed from Source/WebKit2/UIProcess/qt/SGAgent.h.
570         (WebKit::SGUpdateQueue::isSwapPending):
571         (WebKit::NodeUpdate::NodeUpdate):
572         (WebKit::NodeUpdate::~NodeUpdate):
573         * UIProcess/qt/TiledDrawingAreaProxyQt.cpp:
574         (WebKit::TiledDrawingAreaProxy::updateWebView):
575         (WebKit::TiledDrawingAreaProxy::createTile):
576         (WebKit::TiledDrawingAreaProxy::updateTile):
577         (WebKit::TiledDrawingAreaProxy::didRenderFrame):
578         (WebKit::TiledDrawingAreaProxy::removeTile):
579         * UIProcess/qt/TouchViewInterface.cpp:
580         (WebKit::TouchViewInterface::sceneGraphUpdateQueue):
581         * UIProcess/qt/TouchViewInterface.h:
582         * WebKit2.pro:
583
584 2011-09-07  Alexis Menard  <alexis.menard@openbossa.org>
585
586         [Qt] Unreviewed suppression of an unnecessary debug output. 
587
588         * UIProcess/API/qt/tests/qmltests/qmltests.pro:
589
590 2011-09-07  Sheriff Bot  <webkit.review.bot@gmail.com>
591
592         Unreviewed, rolling out r94627 and r94632.
593         http://trac.webkit.org/changeset/94627
594         http://trac.webkit.org/changeset/94632
595         https://bugs.webkit.org/show_bug.cgi?id=67698
596
597         It broke tests on GTK and Qt (Requested by Ossy on #webkit).
598
599         * WebProcess/Plugins/Netscape/JSNPMethod.cpp:
600         (WebKit::JSNPMethod::JSNPMethod):
601         (WebKit::JSNPMethod::create):
602         * WebProcess/Plugins/Netscape/JSNPMethod.h:
603         * WebProcess/Plugins/Netscape/JSNPObject.cpp:
604         (WebKit::JSNPObject::JSNPObject):
605         (WebKit::JSNPObject::create):
606         * WebProcess/Plugins/Netscape/JSNPObject.h:
607
608 2011-09-06  Ryosuke Niwa  <rniwa@webkit.org>
609
610         fast/forms/suggested-value-crash.html crashes on Windows
611         https://bugs.webkit.org/show_bug.cgi?id=67688
612
613         Reviewed by Adam Barth.
614
615         Removed sybmols for inputTag and textareaTag. Added the symbol for StringImpl::equal.
616
617         * win/WebKit2.def:
618         * win/WebKit2CFLite.def:
619
620 2011-09-06  Mark Hahnenberg  <mhahnenberg@apple.com>
621
622         Unzip initialization lists and constructors in JSCell hierarchy (5/7)
623         https://bugs.webkit.org/show_bug.cgi?id=67420
624
625         Reviewed by Geoffrey Garen.
626
627         Completed the fifth level of the refactoring to add finishCreation() 
628         methods to all classes within the JSCell hierarchy with non-trivial 
629         constructor bodies.
630
631         This primarily consists of pushing the calls to finishCreation() down 
632         into the constructors of the subclasses of the second level of the hierarchy 
633         as well as pulling the finishCreation() calls out into the class's corresponding
634         create() method if it has one.  Doing both simultaneously allows us to 
635         maintain the invariant that the finishCreation() method chain is called exactly 
636         once during the creation of an object, since calling it any other number of 
637         times (0, 2, or more) will cause an assertion failure.
638
639         * WebProcess/Plugins/Netscape/JSNPMethod.cpp:
640         (WebKit::JSNPMethod::JSNPMethod):
641         (WebKit::JSNPMethod::finishCreation):
642         * WebProcess/Plugins/Netscape/JSNPMethod.h:
643         (WebKit::JSNPMethod::create):
644         * WebProcess/Plugins/Netscape/JSNPObject.cpp:
645         (WebKit::JSNPObject::JSNPObject):
646         * WebProcess/Plugins/Netscape/JSNPObject.h:
647         (WebKit::JSNPObject::create):
648
649 2011-09-06  Ryosuke Niwa  <rniwa@webkit.org>
650
651         Rename confirmCompositionWithoutDisturbingSelection to cancelComposition
652         https://bugs.webkit.org/show_bug.cgi?id=67569
653
654         Reviewed by Antonio Gomes.
655
656         * UIProcess/API/mac/WKView.mm:
657         (-[WKView resignFirstResponder]):
658         (-[WKView _updateTextInputStateIncludingSecureInputState:]):
659         * UIProcess/WebPageProxy.h:
660         * UIProcess/mac/WebPageProxyMac.mm:
661         (WebKit::WebPageProxy::cancelComposition):
662         * WebProcess/WebPage/WebPage.h:
663         * WebProcess/WebPage/WebPage.messages.in:
664         * WebProcess/WebPage/mac/WebPageMac.mm:
665         (WebKit::WebPage::cancelComposition):
666
667 2011-09-05  Oliver Hunt  <oliver@apple.com>
668
669         An object's structure should reference the global object responsible for its creation
670         https://bugs.webkit.org/show_bug.cgi?id=67624
671
672         Reviewed by Gavin Barraclough.
673
674         Update for new Structure::create globalObject parameter.
675
676         * WebProcess/Plugins/Netscape/JSNPMethod.cpp:
677         (WebKit::JSNPMethod::create):
678         * WebProcess/Plugins/Netscape/JSNPMethod.h:
679         (WebKit::JSNPMethod::createStructure):
680         * WebProcess/Plugins/Netscape/JSNPObject.cpp:
681         (WebKit::JSNPObject::create):
682         * WebProcess/Plugins/Netscape/JSNPObject.h:
683         (WebKit::JSNPObject::createStructure):
684
685 2011-09-06  Ryosuke Niwa  <rniwa@webkit.org>
686
687         REGRESSION(r94274): FormManagerTest.PreviewForm and FillFormNonEmptyField fail on chromium
688         https://bugs.webkit.org/show_bug.cgi?id=67453
689
690         Reviewed by Kent Tamura.
691
692         Add symbols for internals.
693
694         * win/WebKit2.def:
695         * win/WebKit2CFLite.def:
696
697 2011-09-06  Wajahat Siddiqui  <mdwajahatali.siddiqui@motorola.com>
698
699         [GTK] Use soup_session_add_feature_by_type uniformly in WebKit2.
700         https://bugs.webkit.org/show_bug.cgi?id=67593
701
702         Reviewed by Martin Robinson.
703
704         Using soup_session_add_feature_by_type for adding all soup features 
705         instead of adding using GRefPtr.
706
707         * WebProcess/gtk/WebProcessMainGtk.cpp:
708         (WebKit::WebProcessMainGtk):
709
710 2011-09-05  Balazs Kelemen  <kbalazs@webkit.org>
711
712         [Qt][WK2] Add pixel test support
713         https://bugs.webkit.org/show_bug.cgi?id=66283
714
715         Reviewed by Andreas Kling.
716
717         * Shared/API/c/qt/WKImageQt.cpp: Added.
718         (WKImageCreateQImage):  C style (private) API to get the contents of the backing
719         store as an image.
720         * Shared/API/c/qt/WKImageQt.h: Added.
721         * Shared/qt/ShareableBitmapQt.cpp:
722         (WebKit::ShareableBitmap::createImage): Typo. Remove useless ifdef.
723         * WebKit2API.pri:
724
725 2011-09-05  Andras Becsi  <andras.becsi@nokia.com>
726
727         [Qt][WK2] Fix the build
728
729         Rubber-stamped by Csaba Osztrogonác.
730
731         * DerivedSources.pro: Add missing PluginProcessConnection.messages.in after r94456.
732
733 2011-09-02  Sheriff Bot  <webkit.review.bot@gmail.com>
734
735         Unreviewed, rolling out r94473.
736         http://trac.webkit.org/changeset/94473
737         https://bugs.webkit.org/show_bug.cgi?id=67547
738
739         Putting http://trac.webkit.org/changeset/94454 back in as
740         http://trac.webkit.org/changeset/94472 fixed the problem
741         (Requested by msaboff on #webkit).
742
743         * UIProcess/API/C/WKContext.cpp:
744         (WKContextGarbageCollectJavaScriptObjects):
745         * UIProcess/API/C/WKContext.h:
746         * UIProcess/WebContext.cpp:
747         (WebKit::WebContext::garbageCollectJavaScriptObjects):
748         * UIProcess/WebContext.h:
749         * WebProcess/WebProcess.cpp:
750         (WebKit::WebProcess::garbageCollectJavaScriptObjects):
751         * WebProcess/WebProcess.h:
752         * WebProcess/WebProcess.messages.in:
753
754 2011-09-02  Sheriff Bot  <webkit.review.bot@gmail.com>
755
756         Unreviewed, rolling out r94454.
757         http://trac.webkit.org/changeset/94454
758         https://bugs.webkit.org/show_bug.cgi?id=67546
759
760         "Broke Windows and SnowLeopard, also no reply on the bug."
761         (Requested by jchaffraix on #webkit).
762
763         * UIProcess/API/C/WKContext.cpp:
764         * UIProcess/API/C/WKContext.h:
765         * UIProcess/WebContext.cpp:
766         * UIProcess/WebContext.h:
767         * WebProcess/WebProcess.cpp:
768         * WebProcess/WebProcess.h:
769         * WebProcess/WebProcess.messages.in:
770
771 2011-09-02  Michael Saboff  <msaboff@apple.com>
772
773         Fixed release build by removing #ifndef NDEBUG to
774         allow definition of gcController().
775
776         Rubber-stamp by Sam Weinig.
777
778         * WebProcess/WebProcess.cpp:
779
780 2011-09-02  Anders Carlsson  <andersca@apple.com>
781
782         NPN_SetException doesn't work with OOP plug-ins
783         https://bugs.webkit.org/show_bug.cgi?id=67524
784
785         Reviewed by Sam Weinig.
786
787         * DerivedSources.make:
788         Add PluginProcessConnection.messages.in.
789
790         * GNUmakefile.am:
791         Add generated files.
792
793         * Platform/CoreIPC/MessageID.h:
794         Add MessageClassPluginProcessConnection.
795
796         * PluginProcess/PluginProcess.cpp:
797         (WebKit::PluginProcess::initialize):
798         Set the set exception function.
799
800         * PluginProcess/WebProcessConnection.cpp:
801         (WebKit::ConnectionStack::current):
802         (WebKit::ConnectionStack::CurrentConnectionPusher::CurrentConnectionPusher):
803         (WebKit::ConnectionStack::CurrentConnectionPusher::~CurrentConnectionPusher):
804         Add a helper class for managing a stack of CoreIPC connections, along with a RAII
805         object to push/pop connections onto it.
806
807         (WebKit::connectionStack):
808         Add getter.
809
810         (WebKit::WebProcessConnection::setGlobalException):
811         Get the current connection and send a PluginProcessConnection::SetException message to it.
812
813         (WebKit::WebProcessConnection::didReceiveMessage):
814         (WebKit::WebProcessConnection::didReceiveSyncMessage):
815         Create connection pushers.
816
817         * PluginProcess/WebProcessConnection.h:
818         Add setGlobalException.
819
820         * WebKit2.pro:
821         * WebKit2.xcodeproj/project.pbxproj:
822         Add new files.
823
824         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
825         (WebKit::NetscapePlugin::setSetExceptionFunction):
826         New function for setting the 'setException' function.
827
828         (WebKit::NetscapePlugin::setException):
829         Call the 'setException' function.
830
831         * WebProcess/Plugins/PluginProcessConnection.cpp:
832         (WebKit::PluginProcessConnection::didReceiveSyncMessage):
833         Call the message receiver function.
834
835         (WebKit::PluginProcessConnection::setException):
836         Call the NPRuntimeObjectMap.
837         
838         * WebProcess/Plugins/PluginProcessConnection.messages.in:
839         Add new messages file.
840
841         * WebProcess/WebPage/WebPage.cpp:
842         (WebKit::WebPage::createPlugin):
843         When not using the plug-in process, make sure to call NetscapePlugin::setSetExceptionFunction.
844
845 2011-09-02  Ada Chan  <adachan@apple.com>
846
847         Add WKContextGarbageCollectJavaScriptObjects() which does a garbage collection in the WebProcess
848         https://bugs.webkit.org/show_bug.cgi?id=67526
849
850         Reviewed by Darin Adler.
851
852         * UIProcess/API/C/WKContext.cpp:
853         (WKContextGarbageCollectJavaScriptObjects):
854         * UIProcess/API/C/WKContext.h:
855         * UIProcess/WebContext.cpp:
856         (WebKit::WebContext::garbageCollectJavaScriptObjects): Send a message to WebProcess to garbage collect JS objects.
857         * UIProcess/WebContext.h:
858         * WebProcess/WebProcess.cpp:
859         (WebKit::WebProcess::garbageCollectJavaScriptObjects): Call GCController::garbageCollectNow().
860         * WebProcess/WebProcess.h:
861         * WebProcess/WebProcess.messages.in: Add GarbageCollectJavaScriptObjects message.
862
863 2011-09-02  Anders Carlsson  <andersca@apple.com>
864
865         Remove plug-in paths from web process sandbox
866         https://bugs.webkit.org/show_bug.cgi?id=67518
867
868         Reviewed by Adam Roben.
869
870         Plug-ins are never accessed from the web process, so remove plug-in paths from the sandbox profile.
871
872         * WebProcess/com.apple.WebProcess.sb:
873
874 2011-09-02  Anders Carlsson  <andersca@apple.com>
875
876         Assertion/crash when running netscape-plugin-property-access-exception.html test
877         https://bugs.webkit.org/show_bug.cgi?id=67517
878
879         Reviewed by Adam Roben.
880
881         Make sure to initialize the NPVariant in case the plug-in returns true from NP_GetProperty,
882         but doesn't set the result NPVariant to anything.
883
884         * Shared/Plugins/NPObjectMessageReceiver.cpp:
885         (WebKit::NPObjectMessageReceiver::getProperty):
886
887 2011-09-02  Anders Carlsson  <andersca@apple.com>
888
889         The private browsing state isn't saved when it changes
890         https://bugs.webkit.org/show_bug.cgi?id=67508
891
892         Reviewed by Sam Weinig.
893
894         Store the new private browsing state so subsequent queries for it
895         will return the right value.
896
897         * PluginProcess/PluginControllerProxy.cpp:
898         (WebKit::PluginControllerProxy::privateBrowsingStateChanged):
899
900 2011-09-02  Ravi Phaneendra Kasibhatla  <ravi.kasibhatla@motorola.com>
901
902         [WK2] Anchor elements doesn't get focus on TAB key press.
903         https://bugs.webkit.org/show_bug.cgi?id=66949
904
905         Reviewed by Adam Roben.
906
907         Setting the default property value of TabsToLinks to true
908         only for GTK platform since Win & Mac platforms doesn't want 
909         it to be set to true by default.
910
911         * Shared/WebPreferencesStore.h:
912         Set the default value of key TabsToLinks to true for GTK platform only.
913
914 2011-09-02  Balazs Kelemen  <kbalazs@webkit.org>
915
916         [Qt][WK2] Cannot gathering glyph page statistics
917         https://bugs.webkit.org/show_bug.cgi?id=67475
918
919         Rubber stamped by Csaba Osztrogonác.
920
921         Fix Qt WK2 build without having QRAWFONT.
922
923         * WebProcess/WebProcess.cpp:
924         (WebKit::WebProcess::getWebCoreStatistics):
925
926 2011-09-02  Mark Rowe  <mrowe@apple.com>
927
928         <http://webkit.org/b/67467> WebProcessProxy::secItemCopyMatching / WebProcessProxy::secItemAdd
929         leak the results of the APIs they wrap.
930
931         Reviewed by Dan Bernstein.
932
933         * UIProcess/mac/WebProcessProxyMac.mm:
934         (WebKit::WebProcessProxy::secItemCopyMatching): Adopt the result of SecItemCopyMatching in to a
935         RetainPtr to ensure it gets released at the appropriate time.
936         (WebKit::WebProcessProxy::secItemAdd): Ditto for SecItemAdd.
937
938 2011-09-01  Ada Chan  <adachan@apple.com>
939
940         Cut down the ifdefs in WebKit::getWebCoreMemoryCacheStatistics() now that 
941         MemoryCache::Statistics always has the xslStyleSheets field.
942
943         Reviewed by Darin Adler.
944
945         * WebProcess/WebProcess.cpp:
946         (WebKit::getWebCoreMemoryCacheStatistics):
947
948 2011-09-01  Mark Hahnenberg  <mhahnenberg@apple.com>
949
950         Unzip initialization lists and constructors in JSCell hierarchy (4/7)
951         https://bugs.webkit.org/show_bug.cgi?id=67174
952
953         Reviewed by Oliver Hunt.
954
955         Completed the fourth level of the refactoring to add finishCreation() 
956         methods to all classes within the JSCell hierarchy with non-trivial 
957         constructor bodies.
958
959         This primarily consists of pushing the calls to finishCreation() down 
960         into the constructors of the subclasses of the second level of the hierarchy 
961         as well as pulling the finishCreation() calls out into the class's corresponding
962         create() method if it has one.  Doing both simultaneously allows us to 
963         maintain the invariant that the finishCreation() method chain is called exactly 
964         once during the creation of an object, since calling it any other number of 
965         times (0, 2, or more) will cause an assertion failure.
966
967         * WebProcess/Plugins/Netscape/JSNPObject.cpp:
968         (WebKit::JSNPObject::JSNPObject):
969         (WebKit::JSNPObject::finishCreation):
970         * WebProcess/Plugins/Netscape/JSNPObject.h:
971
972 2011-09-01  Ada Chan  <adachan@apple.com>
973
974         Gather memory cache statistics in WebProcess::getWebCoreStatistics().
975         https://bugs.webkit.org/show_bug.cgi?id=67160
976
977         Reviewed by Darin Adler.
978
979         Encode and decode webCoreCacheStatistics data member in StatisticsData.
980         * Shared/StatisticsData.cpp:
981         (WebKit::StatisticsData::encode):
982         (WebKit::StatisticsData::decode):
983         * Shared/StatisticsData.h:
984
985         Convert the cache statistics data into an ImmutableArray and return it in WebContext::didGetWebCoreStatistics().
986         * UIProcess/WebContext.cpp:
987         (WebKit::WebContext::didGetWebCoreStatistics):
988
989         Store memory cache statistics into the StatisticsData object.
990         * WebProcess/WebProcess.cpp:
991         (WebKit::getWebCoreMemoryCacheStatistics):
992         (WebKit::WebProcess::getWebCoreStatistics):
993
994 2011-09-01  Tim Horton  <timothy_horton@apple.com>
995
996         REGRESSION: Rendering artifacts on a rotated, pattern filled shape
997         https://bugs.webkit.org/show_bug.cgi?id=53055
998         <rdar://problem/8910917>
999
1000         Reviewed by Simon Fraser.
1001
1002         Introduce wkCGPatternCreateWithImageAndTransform.
1003
1004         * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
1005         (InitWebCoreSystemInterface):
1006
1007 2011-09-01  Gopal Raghavan  <gopal.1.raghavan@nokia.com>
1008
1009         [Qt] TouchWebView crashes with segmentation fault
1010         https://bugs.webkit.org/show_bug.cgi?id=67308
1011
1012         Reviewed by Benjamin Poulain.
1013
1014         If you instantiate TouchWebView element with height and width in a qml file and
1015         load a url it crashes.
1016         The functions setWidth() and setHeight() are called sequentially therefore it can happen
1017         that computeViewportAttributes was called with a size like (width, 0) breaking the
1018         assumption of the function that the size is valid. The patch makes sure we compute the
1019         viewport when both height and width are valid.
1020
1021         * UIProcess/API/qt/qtouchwebview.cpp:
1022         (QTouchWebViewPrivate::updateViewportConstraints):
1023         * UIProcess/API/qt/tests/qmltests/TouchWebView/tst_load.qml: Added.
1024         * UIProcess/API/qt/tests/qmltests/TouchWebView/tst_loadNegativeSizeView.qml: Added.
1025         * UIProcess/API/qt/tests/qmltests/TouchWebView/tst_loadZeroSizeView.qml: Added.
1026         * UIProcess/API/qt/tests/qmltests/qmltests.pro:
1027
1028 2011-09-01  Ada Chan  <adachan@apple.com>
1029
1030         Gather JavaScript, FastMalloc, icon, font, and glyph page statistics in WebProcess::getWebCoreStatistics().
1031         https://bugs.webkit.org/show_bug.cgi?id=67160
1032
1033         Reviewed by Darin Adler.
1034
1035         Encode and decode the data members in StatisticsData.
1036         * Shared/StatisticsData.cpp:
1037         (WebKit::StatisticsData::encode):
1038         (WebKit::StatisticsData::decode):
1039         (WebKit::StatisticsData::StatisticsData):
1040
1041         Add three data members to StatisticsData:
1042         - statisticsNumbers: Map containing statistics values that are numbers, mapped by their names, such as 
1043         JavaScriptObjectsCount, CachedFontDataCount, etc.
1044         - javaScriptProtectedObjectTypeCounts
1045         - javaScriptObjectTypeCounts
1046         * Shared/StatisticsData.h:
1047
1048         Create a WK::Dictionary containing statistics values mapped by their names and return that dictionary
1049         in WebContext::didGetWebCoreStatistics().
1050         * UIProcess/WebContext.cpp:
1051         (WebKit::createDictionaryFromHashMap):
1052         (WebKit::WebContext::didGetWebCoreStatistics):
1053
1054         Package JavaScript, FastMalloc, icon, font, and glyph page statistics into a StatisticsData object
1055         and send it to the UIProcess.
1056         * WebProcess/WebProcess.cpp:
1057         (WebKit::fromCountedSetToHashMap):
1058         (WebKit::WebProcess::getWebCoreStatistics):
1059
1060 2011-09-01  Xan Lopez  <xlopez@igalia.com>
1061
1062         [GTK] Add XRender lib dependencies explicitly
1063
1064         Reviewed by Philippe Normand.
1065
1066         This is needed when using the GNU/Gold linker, since we use
1067         XRender directly.
1068
1069         * GNUmakefile.am:
1070
1071 2011-08-31  Anders Carlsson  <andersca@apple.com>
1072
1073         Jagged text shown in find-in-page highlight
1074         https://bugs.webkit.org/show_bug.cgi?id=67347
1075         <rdar://problem/9870444>
1076
1077         Reviewed by Dan Bernstein.
1078
1079         When painting each text line in the find indicator, make sure to clip it against
1080         the text rect and not paint the entire rect over and over.
1081
1082         * UIProcess/FindIndicator.cpp:
1083         (WebKit::FindIndicator::draw):
1084
1085 2011-08-31  Beth Dakin  <bdakin@apple.com>
1086
1087         https://bugs.webkit.org/show_bug.cgi?id=67322
1088         Re-name overrideBackingScaleFactor
1089
1090         Reviewed by John Sullivan.
1091
1092         API is now WKPageSetCustomBackingScaleFactor() and WKPageGetBackingScaleFactor() 
1093         which returns the custom scale factor if one was set, and the intrinsic scale 
1094         factor otherwise. 
1095         * UIProcess/API/C/WKPage.cpp:
1096         (WKPageGetBackingScaleFactor):
1097         (WKPageSetCustomBackingScaleFactor):
1098         * UIProcess/API/C/WKPage.h:
1099
1100         Re-named _deviceScaleFactor to _intrinsicDeviceScaleFactor since it only ever 
1101         refers to the intrinsic value.
1102         * UIProcess/API/mac/WKView.mm:
1103         (-[WKView viewDidMoveToWindow]):
1104         (-[WKView _windowDidChangeResolution:]):
1105         (-[WKView _intrinsicDeviceScaleFactor]):
1106
1107         WebPageProxy stores both the customDeviceScaleFactor and the 
1108         intrinsicDeviceScaleFactor. deviceScaleFactor() returns the appropriate value that 
1109         should be the one used. 
1110         * UIProcess/WebPageProxy.cpp:
1111         (WebKit::WebPageProxy::WebPageProxy):
1112         (WebKit::WebPageProxy::setIntrinsicDeviceScaleFactor):
1113         (WebKit::WebPageProxy::deviceScaleFactor):
1114         (WebKit::WebPageProxy::setCustomDeviceScaleFactor):
1115         (WebKit::WebPageProxy::creationParameters):
1116         * UIProcess/WebPageProxy.h:
1117
1118 2011-08-31  Anders Carlsson  <andersca@apple.com>
1119
1120         REGRESSION(r93902): Can't open external links on gmail
1121         https://bugs.webkit.org/show_bug.cgi?id=67234
1122         <rdar://problem/10053636>
1123
1124         Reviewed by Alexey Proskuryakov.
1125
1126         * Shared/cf/ArgumentCodersCF.cpp:
1127         (CoreIPC::decode):
1128         If we encounter an empty URL string, create an empty url by using NSURL, just
1129         like we do in WebCore when converting an empty KURL to an NSURL.
1130
1131         * WebKit2.xcodeproj/project.pbxproj:
1132         Compile ArgumentCodersCF.cpp as Objective-C++ for now.
1133
1134 2011-08-30  Beth Dakin  <bdakin@apple.com>
1135
1136         https://bugs.webkit.org/show_bug.cgi?id=67150
1137         Would like API to use a custom device scale factor for a particular WebView/WKView
1138         -and corresponding-
1139         <rdar://problem/10041016>
1140
1141         Reviewed by Darin Adler.
1142
1143         New API is setOverrideBackingScaleFactor() on WKPage
1144         * UIProcess/API/C/WKPage.cpp:
1145         (WKPageGetOverrideBackingScaleFactor):
1146         (WKPageSetOverrideBackingScaleFactor):
1147         * UIProcess/API/C/WKPage.h:
1148         * UIProcess/WebPageProxy.cpp:
1149         (WebKit::WebPageProxy::WebPageProxy):
1150         (WebKit::WebPageProxy::deviceScaleFactor):
1151         (WebKit::WebPageProxy::setOverrideBackingScaleFactor):
1152         * UIProcess/WebPageProxy.h:
1153         (WebKit::WebPageProxy::overrideBackingScaleFactor):
1154
1155 2011-08-30  Aaron Colwell  <acolwell@chromium.org>
1156
1157         Add MediaSource API to HTMLMediaElement
1158         https://bugs.webkit.org/show_bug.cgi?id=64731
1159
1160         Reviewed by Eric Carlson.
1161
1162         * Configurations/FeatureDefines.xcconfig:
1163
1164 2011-08-30  Ada Chan  <adachan@apple.com>
1165
1166         Laying some groundwork to fetch performance statistics from WebProcess.
1167         https://bugs.webkit.org/show_bug.cgi?id=67160
1168
1169         Reviewed by Darin Adler.
1170
1171         Add WKContextGetStatistics() which sends a message to WebProcess to fetch the performance statistics.
1172         * UIProcess/API/C/WKContext.cpp:
1173         (WKContextGetStatistics):
1174         * UIProcess/API/C/WKContext.h:
1175         * UIProcess/WebContext.cpp:
1176         (WebKit::WebContext::~WebContext):
1177         (WebKit::WebContext::getWebCoreStatistics):
1178         (WebKit::WebContext::didGetWebCoreStatistics):
1179         * UIProcess/WebContext.h:
1180         * UIProcess/WebContext.messages.in: Add the DidGetWebCoreStatistics message that WebProcess can send when it has
1181         the performance statistics ready.
1182
1183         Add WebProcess::getWebCoreStatistics().  Currently it just sends back an empty StatisticsData object.
1184         It will gather the performance statistics to store in the StatisticsData object in a future patch.
1185         * WebProcess/WebProcess.cpp:
1186         (WebKit::WebProcess::getWebCoreStatistics):
1187         * WebProcess/WebProcess.h:
1188         * WebProcess/WebProcess.messages.in:
1189
1190         Add the skeleton for StatisticsData.
1191         * Scripts/webkit2/messages.py:
1192         * Shared/StatisticsData.cpp: Added.
1193         (WebKit::StatisticsData::encode):
1194         (WebKit::StatisticsData::decode):
1195         (WebKit::StatisticsData::StatisticsData):
1196         * Shared/StatisticsData.h: Added.
1197
1198         Add StatisticsData.h/cpp to project.
1199         * CMakeLists.txt:
1200         * GNUmakefile.am:
1201         * WebKit2.pro:
1202         * WebKit2.xcodeproj/project.pbxproj:
1203         * win/WebKit2.vcproj:
1204
1205 2011-08-29  Alexey Proskuryakov  <ap@apple.com>
1206
1207         DumpRenderTree should begin each test with an empty cookie store
1208         https://bugs.webkit.org/show_bug.cgi?id=63545
1209         <rdar://problem/5666907>
1210
1211         Reviewed by Darin Adler.
1212
1213         * WebProcess/Cookies/cf/WebCookieManagerCFNet.cpp:
1214         (WebKit::WebCookieManager::platformSetHTTPCookieAcceptPolicy):
1215         (WebKit::WebCookieManager::platformGetHTTPCookieAcceptPolicy):
1216         Updated to use currentCFHTTPCookieStorage() instead of privateBrowsingCookieStorage().
1217
1218         * WebProcess/Cookies/mac/WebCookieManagerMac.mm:
1219         (WebKit::WebCookieManager::platformSetHTTPCookieAcceptPolicy):
1220         There is no no need to access cookie storage through session manually - we already have code
1221         for that in WebCore.
1222
1223         * WebProcess/InjectedBundle/API/c/WKBundle.cpp:
1224         (WKBundleSwitchNetworkLoaderToNewTestingSession):
1225         * WebProcess/InjectedBundle/API/c/WKBundlePrivate.h:
1226         * WebProcess/InjectedBundle/InjectedBundle.cpp:
1227         (WebKit::InjectedBundle::switchNetworkLoaderToNewTestingSession):
1228         * WebProcess/InjectedBundle/InjectedBundle.h:
1229         Exposed bundle SPI to use a private default session. It's separate from private browsing,
1230         because some tests enable the latter, and we don't want to mix them up.
1231
1232         * WebProcess/WebPage/mac/WebPageMac.mm:
1233         (WebKit::WebPage::platformHasLocalDataForURL):
1234         (WebKit::cachedResponseForURL):
1235         Updated to use currentStorageSession() instead of privateBrowsingStorageSession().
1236
1237         * WebProcess/win/WebProcessWin.cpp: (WebKit::WebProcess::platformInitializeWebProcess):
1238         ResourceHandle::setDefaultStorageSession() no longer steals a reference, so retain it properly.
1239
1240 2011-08-30  Alexis Menard  <alexis.menard@openbossa.org>
1241
1242         [Qt][WK2] Make mouse over work again for QDesktopWebView.
1243         https://bugs.webkit.org/show_bug.cgi?id=67200
1244
1245         Reviewed by Noam Rosenthal.
1246
1247         The API has changed after QGraphicsView, SceneGraph sends
1248         QHoverEvents now.
1249
1250         * UIProcess/qt/qdesktopwebpageproxy.cpp:
1251         (QDesktopWebPageProxy::handleEvent):
1252         (QDesktopWebPageProxy::handleHoverMoveEvent):
1253         * UIProcess/qt/qdesktopwebpageproxy.h:
1254
1255 2011-08-30  Kaustubh Atrawalkar  <kaustubh@motorola.com>
1256
1257         The unused ScrollView* argument can and should be removed from
1258         scrollRectIntoView.
1259         https://bugs.webkit.org/show_bug.cgi?id=67117
1260
1261         Reviewed by Darin Adler.
1262
1263         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
1264         (WebKit::WebChromeClient::scrollRectIntoView):
1265         * WebProcess/WebCoreSupport/WebChromeClient.h:
1266
1267 2011-08-29  Ryosuke Niwa  <rniwa@webkit.org>
1268
1269         Another Windows build fix after r94047.
1270
1271         * win/WebKit2.def:
1272         * win/WebKit2CFLite.def:
1273
1274 2011-08-29  Ryosuke Niwa  <rniwa@webkit.org>
1275
1276         Export more symbols for r94038.
1277
1278         * win/WebKit2.def:
1279         * win/WebKit2CFLite.def:
1280
1281 2011-08-29  Ryosuke Niwa  <rniwa@webkit.org>
1282
1283         Windows build fix for r94038.
1284
1285         * win/WebKit2.def:
1286         * win/WebKit2CFLite.def:
1287
1288 2011-08-29  Gopal Raghavan  <gopal.1.raghavan@nokia.com>
1289
1290
1291         [Qt] QTouchWebView url property test missing
1292         https://bugs.webkit.org/show_bug.cgi?id=67159
1293
1294         Reviewed by Noam Rosenthal.
1295
1296         Added qml test case to check url property of QTouchWebView. Since url is a readonly property, we make sure that it's set after load() is called.
1297
1298         * UIProcess/API/qt/tests/qmltests/TouchWebView/tst_properties.qml:
1299
1300 2011-08-29  Gopal Raghavan  <gopal.1.raghavan@nokia.com>
1301
1302         [Qt] QDesktopWebView url property test missing
1303         https://bugs.webkit.org/show_bug.cgi?id=67155
1304
1305         Reviewed by Noam Rosenthal.
1306
1307         Added qml test case to check url property. Since url is a readonly property, we make sure that it's set after load() is called.
1308
1309         * UIProcess/API/qt/tests/qmltests/DesktopWebView/tst_properties.qml:
1310
1311 2011-08-29  Sheriff Bot  <webkit.review.bot@gmail.com>
1312
1313         Unreviewed, rolling out r93987, r93992, r93995, r93998, and
1314         r93999.
1315         http://trac.webkit.org/changeset/93987
1316         http://trac.webkit.org/changeset/93992
1317         http://trac.webkit.org/changeset/93995
1318         http://trac.webkit.org/changeset/93998
1319         http://trac.webkit.org/changeset/93999
1320         https://bugs.webkit.org/show_bug.cgi?id=67147
1321
1322         Many failing tests (Requested by ap on #webkit).
1323
1324         * WebProcess/Cookies/cf/WebCookieManagerCFNet.cpp:
1325         (WebKit::WebCookieManager::platformSetHTTPCookieAcceptPolicy):
1326         (WebKit::WebCookieManager::platformGetHTTPCookieAcceptPolicy):
1327         * WebProcess/InjectedBundle/API/c/WKBundle.cpp:
1328         * WebProcess/InjectedBundle/API/c/WKBundlePrivate.h:
1329         * WebProcess/InjectedBundle/InjectedBundle.cpp:
1330         * WebProcess/InjectedBundle/InjectedBundle.h:
1331         * WebProcess/win/WebProcessWin.cpp:
1332         (WebKit::WebProcess::platformInitializeWebProcess):
1333
1334 2011-08-26  Martin Robinson  <mrobinson@igalia.com>
1335
1336         Reviewed by Xan Lopez.
1337
1338         [GTK] Build WebKit2 unconditionally
1339         https://bugs.webkit.org/show_bug.cgi?id=62749
1340
1341         Build WebKit2 by default. This will make the bots build it and catch
1342         build errors when they occur.
1343
1344         * GNUmakefile.am: Enable WebKit2 by default, but remove references to the WebKit2
1345         PC file, which should not be shipped until WebKit2 is actually shipped officially.
1346
1347 2011-08-29  Alexey Proskuryakov  <ap@apple.com>
1348
1349         Windows build fix.
1350
1351         * WebProcess/Cookies/cf/WebCookieManagerCFNet.cpp:
1352         (WebKit::WebCookieManager::platformSetHTTPCookieAcceptPolicy):
1353         (WebKit::WebCookieManager::platformGetHTTPCookieAcceptPolicy):
1354         Updated for new function name and signature: currentCFHTTPCookieStorage().
1355
1356 2011-08-26  Alexey Proskuryakov  <ap@apple.com>
1357
1358         DumpRenderTree should begin each test with an empty cookie store
1359         https://bugs.webkit.org/show_bug.cgi?id=63545
1360         <rdar://problem/5666907>
1361
1362         Reviewed by Darin Adler.
1363
1364         * WebProcess/win/WebProcessWin.cpp: (WebKit::WebProcess::platformInitializeWebProcess):
1365         ResourceHandle::setDefaultStorageSession() no longer steals a reference, so retain it properly.
1366
1367         * WebProcess/InjectedBundle/API/c/WKBundle.cpp:
1368         (WKBundleUsePrivateSessionForNetworkLoading):
1369         * WebProcess/InjectedBundle/API/c/WKBundlePrivate.h:
1370         * WebProcess/InjectedBundle/InjectedBundle.cpp:
1371         (WebKit::InjectedBundle::usePrivateSessionForNetworkLoading):
1372         * WebProcess/InjectedBundle/InjectedBundle.h:
1373         Exposed bundle SPI to use a private default session. It's separate from private browsing,
1374         because some tests enable the latter, and we don't want to mix them up.
1375
1376 2011-08-29  Chris Marrin  <cmarrin@apple.com>
1377
1378         Fixed a build problem caused by http://trac.webkit.org/changeset/93980
1379
1380         Unreviewed.
1381
1382         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
1383
1384 2011-08-23  Chris Marrin  <cmarrin@apple.com>
1385
1386         [mac] requestAnimationFrame support for mac port
1387         https://bugs.webkit.org/show_bug.cgi?id=59146
1388
1389         Reviewed by Simon Fraser.
1390
1391         Implement requestAnimationFrame for WebKit2. Add a
1392         CFRunLoopObserver to WebPage, which runs just before
1393         the syncCompositingState RLO and calls into the 
1394         ScriptedAnimationController if scheduleAnimation() has
1395         been called.
1396
1397         * Configurations/FeatureDefines.xcconfig:
1398         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
1399         (WebKit::WebChromeClient::scheduleAnimation):
1400         * WebProcess/WebCoreSupport/WebChromeClient.h:
1401         * WebProcess/WebPage/WebPage.cpp:
1402         (WebKit::WebPage::WebPage):
1403         (WebKit::WebPage::~WebPage):
1404         * WebProcess/WebPage/WebPage.h:
1405         * WebProcess/WebPage/mac/WebPageMac.mm:
1406         (WebKit::WebPage::requestAnimationFrameRunLoopObserverCallback):
1407         (WebKit::WebPage::scheduleAnimation):
1408         (WebKit::WebPage::unscheduleAnimation):
1409         * WebProcess/WebPage/ca/mac/LayerTreeHostCAMac.cpp:
1410         * WebProcess/WebPage/ca/mac/LayerTreeHostCAMac.h:
1411
1412 2011-08-29  Pierre Rossi  <pierre.rossi@gmail.com>
1413
1414         [Qt] NPAPI support doesn't honor the ENABLE_NETSCAPE_PLUGIN_API define in WebKit2
1415         https://bugs.webkit.org/show_bug.cgi?id=67123
1416
1417         We could simply use the defines already in place for this.
1418
1419         Reviewed by Andreas Kling.
1420
1421         * WebKit2.pro:
1422
1423 2011-08-29  Vamshikrishna Yellenki  <vamshi@motorola.com>
1424
1425         [GTK][WK2] Compilation error in WebKit2 GTK - Revision 93953
1426         https://bugs.webkit.org/show_bug.cgi?id=67111
1427
1428         Reviewed by Martin Robinson.
1429
1430         WebKit2 GTK build error.
1431
1432         * WebProcess/WebCoreSupport/gtk/WebErrorsGtk.cpp:
1433         Include <WebCore/ResourceError.h> explicitly to remove WebCore::ResourceError
1434         inclusion error.
1435
1436 2011-08-28  Balazs Kelemen  <kbalazs@webkit.org>
1437
1438         [Qt][WK2] Unreviewed build fix.
1439
1440         * UIProcess/qt/QtWebPageProxy.cpp:
1441         (QtWebPageProxy::init): Initialize the WKPageUIClient with memset
1442         to avoid missing initializer warning. The missing initializer is the
1443         result of using a version 0 WKPageUIClient while it has newer version (1).
1444         We have nothing to do with the callbacks in the new version so I voted
1445         for memset.
1446         * WebProcess/WebCoreSupport/qt/WebErrorsQt.cpp: Include ResourceError.h.
1447
1448 2011-08-26  Sam Weinig  <sam@webkit.org>
1449
1450         Stop using custom NSErrors for WebKit2 WebErrors
1451         https://bugs.webkit.org/show_bug.cgi?id=67075
1452
1453         Reviewed by Anders Carlsson.
1454
1455         * WebProcess/WebCoreSupport/WebErrors.h:
1456         * WebProcess/WebCoreSupport/mac/WebErrorsMac.mm:
1457         (WebKit::createNSError):
1458         (WebKit::cancelledError):
1459         (WebKit::fileDoesNotExistError):
1460         (WebKit::blockedError):
1461         (WebKit::cannotShowURLError):
1462         (WebKit::interruptedForPolicyChangeError):
1463         (WebKit::cannotShowMIMETypeError):
1464         (WebKit::pluginWillHandleLoadError):
1465         There is no reason to use custom registered NSErrors anymore, so don't.
1466
1467 2011-08-26  Anders Carlsson  <andersca@apple.com>
1468
1469         Fix build.
1470
1471         * WebProcess/Plugins/Netscape/NetscapePlugin.h:
1472
1473 2011-08-26  Sam Weinig  <sam@webkit.org>
1474
1475         Fold _webkit_initWithDomain into _webkit_errorWithDomain in WebKit2
1476         https://bugs.webkit.org/show_bug.cgi?id=67063
1477
1478         Reviewed by Anders Carlsson.
1479
1480         * WebProcess/WebCoreSupport/mac/WebErrorsMac.mm:
1481         (+[NSError _webkit_errorWithDomain:code:URL:]):
1482
1483 2011-08-26  Anders Carlsson  <andersca@apple.com>
1484
1485         Implement NPN_ScheduleTimer/NPN_UnscheduleTimer
1486         https://bugs.webkit.org/show_bug.cgi?id=67062
1487
1488         Reviewed by Sam Weinig.
1489
1490         * WebProcess/Plugins/Netscape/NetscapeBrowserFuncs.cpp:
1491         (WebKit::NPN_ScheduleTimer):
1492         Call NetscapePlugin::scheduleTimer.
1493
1494         (WebKit::NPN_UnscheduleTimer):
1495         Call NetscapePlugin::unscheduleTimer.
1496
1497         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
1498         (WebKit::NetscapePlugin::NetscapePlugin):
1499         Initialize m_nextTimerID.
1500
1501         (WebKit::NetscapePlugin::Timer::start):
1502         Start the timer.
1503
1504         (WebKit::NetscapePlugin::Timer::stop):
1505         Stop the timer.
1506
1507         (WebKit::NetscapePlugin::Timer::timerFired):
1508         Call the right callback and unschedule the timer object if it's not a repeating timer.
1509
1510         (WebKit::NetscapePlugin::scheduleTimer):
1511         Create a new timer and start it.
1512
1513         (WebKit::NetscapePlugin::unscheduleTimer):
1514         Get the timer from the map and destroy it.
1515         
1516         (WebKit::NetscapePlugin::destroy):
1517         Destroy all timers.
1518
1519         * WebProcess/Plugins/Netscape/NetscapePlugin.h:
1520         Add Timer class.
1521
1522 2011-08-26  Sam Weinig  <sam@webkit.org>
1523
1524         Fix typo in Connection.cpp
1525         https://bugs.webkit.org/show_bug.cgi?id=67060
1526
1527         Reviewed by Anders Carlsson.
1528
1529         * Platform/CoreIPC/Connection.cpp:
1530         (CoreIPC::Connection::waitForSyncReply):
1531         We want timedOut, not timeout.  There is not a current way to cause this
1532         to be an issue. This issue was caught by the Clang Static Analyzer.
1533
1534 2011-08-26  Alice Liu  <alice.liu@apple.com>
1535
1536         https://bugs.webkit.org/show_bug.cgi?id=66823
1537         Add the request info to the WebPageProxy::CreateNewPage message
1538
1539         Reviewed by Anders Carlsson.
1540
1541         Update function declarations with additional ResourceRequest parameter:
1542         * UIProcess/API/C/WKPage.h:
1543         * UIProcess/WebPageProxy.cpp:
1544         (WebKit::WebPageProxy::createNewPage):
1545         * UIProcess/WebPageProxy.h:
1546         * UIProcess/WebPageProxy.messages.in:
1547         * UIProcess/WebUIClient.cpp:
1548         (WebKit::WebUIClient::createNewPage):
1549         * UIProcess/WebUIClient.h:
1550
1551         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
1552         (WebKit::WebChromeClient::createWindow): 
1553         Pass the ResourceRequest within the FrameLoadRequest.
1554
1555 2011-08-26  Alexis Menard  <alexis.menard@openbossa.org>
1556
1557         [Qt][WK2]REGRESSION(r93784): It made many tests crash
1558         https://bugs.webkit.org/show_bug.cgi?id=66958
1559
1560         Reviewed by Anders Carlsson.
1561
1562         Don't try to make sure the WebContext is deleted, for now the leak
1563         is intended and when multiple processes per context will be supported
1564         this leak should be fixed. This was the cause of DRT crashing on the bot,
1565         the context was deleted after the first test, letting other tests with nothing
1566         but a bad context.
1567
1568         * UIProcess/qt/QtWebPageProxy.cpp:
1569         (QtWebPageProxy::~QtWebPageProxy):
1570
1571 2011-08-26  Anders Carlsson  <andersca@apple.com>
1572
1573         Fix handling of keyup events in the new Cocoa text input model
1574         https://bugs.webkit.org/show_bug.cgi?id=67045
1575
1576         Reviewed by Sam Weinig.
1577
1578         Use a counter instead of a boolean for deciding when to ignore keyup events, because
1579         if multiple keys are pressed simultaneously then we need to ignore more than one keyup event in a row.
1580
1581         Also if a keyboard event is an autorepeating event we won't get a keyup event so don't increment the counter
1582         in that case.
1583
1584         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
1585         (WebKit::NetscapePlugin::NetscapePlugin):
1586         * WebProcess/Plugins/Netscape/NetscapePlugin.h:
1587         * WebProcess/Plugins/Netscape/mac/NetscapePluginMac.mm:
1588         (WebKit::NetscapePlugin::platformHandleKeyboardEvent):
1589
1590 2011-08-26  Jessie Berlin  <jberlin@apple.com>
1591
1592         Gut WKPageCreateSnapshotOfVisibleContent so that it can be removed later.
1593         https://bugs.webkit.org/show_bug.cgi?id=66979.
1594
1595         Removing the function altogether would break the nightlies.
1596         This patch removes the code behind it so that it is clear that
1597         WKPageCreateSnapshotOfVisibleContent should not be used, and so that the code isn't just
1598         left rotting in the tree.
1599
1600         Reviewed by Brian Weinstein.
1601
1602         * UIProcess/API/C/WKPage.cpp:
1603         (WKPageCreateSnapshotOfVisibleContent):
1604         Return 0.
1605         * UIProcess/API/C/WKPagePrivate.h:
1606         Update the comment and add a link to the bug.
1607
1608         * UIProcess/WebPageProxy.cpp:
1609         * UIProcess/WebPageProxy.h:
1610
1611         * WebProcess/WebPage/WebPage.cpp:
1612         * WebProcess/WebPage/WebPage.h:
1613         * WebProcess/WebPage/WebPage.messages.in:
1614
1615 2011-08-25  Anders Carlsson  <andersca@apple.com>
1616
1617         kNPEventStartIME doesn't work correctly for NPAPI
1618         https://bugs.webkit.org/show_bug.cgi?id=65264
1619         <rdar://problem/9996476>
1620
1621         Reviewed by Sam Weinig.
1622
1623         In order to remain compatible with older plug-ins, the updated input model won't
1624         be turned on unless a plug-in explicitly asks whether we support it. The plug-in must do
1625         this before any keyboard events have been processed.
1626
1627         * PluginProcess/mac/PluginControllerProxyMac.mm:
1628         (WebKit::PluginControllerProxy::setComplexTextInputState):
1629         Add the CoreIPC::DispatchMessageEvenWhenWaitingForSyncReply flag to this message since we want
1630         the web process to handle it while it's waiting for a reply to the PluginControllerProxy::HandleMouseEvent
1631         synchronous message.
1632
1633         * WebProcess/Plugins/Netscape/NetscapeBrowserFuncs.cpp:
1634         (WebKit::NPN_GetValue):
1635         Implement the logic for when to turn off the legacy Cocoa text input model support.
1636
1637         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
1638         (WebKit::NetscapePlugin::NetscapePlugin):
1639         Initialize m_ignoreNextKeyUpEvent to false.
1640
1641         * WebProcess/Plugins/Netscape/NetscapePlugin.h:
1642         Add m_ignoreNextKeyUpEvent member variable.
1643
1644         (WebKit::NetscapePlugin::hasHandledAKeyDownEvent):
1645         Add a getter.
1646
1647         * WebProcess/Plugins/Netscape/mac/NetscapePluginMac.mm:
1648         (WebKit::NetscapePlugin::platformHandleKeyboardEvent):
1649         Don't send keydown and keyup events when complex text input is enabled in the updated model.
1650
1651 2011-08-25  Anders Carlsson  <andersca@apple.com>
1652
1653         Correctly handle events in the updated Cocoa text input model
1654         https://bugs.webkit.org/show_bug.cgi?id=67005
1655
1656         Reviewed by Sam Weinig.
1657
1658         * UIProcess/API/mac/WKTextInputWindowController.mm:
1659         (-[WKTextInputPanel _interpretKeyEvent:usingLegacyCocoaTextInput:string:]):
1660         When using the updated model, always return a string even for 'simple' characters.
1661
1662         * UIProcess/API/mac/WKView.mm:
1663         (-[WKView _tryHandlePluginComplexTextInputKeyDown:]):
1664         Only let the input method have a crack at the event in the legacy model.
1665
1666 2011-08-25  Jeff Miller  <jeffm@apple.com>
1667
1668         Move Windows-specific WebPageProxy code to WebPageProxyWin.cpp
1669         https://bugs.webkit.org/show_bug.cgi?id=67002
1670
1671         Reviewed by Brian Weinstein.
1672
1673         * UIProcess/WebPageProxy.cpp: Moved Windows-only functions to WebPageProxyWin.cpp.
1674         
1675         * UIProcess/win/WebPageProxyWin.cpp:
1676         (WebKit::WebPageProxy::firstRectForCharacterInSelectedRange): Moved from WebPageProxy.cpp.
1677         (WebKit::WebPageProxy::getSelectedText): Moved from WebPageProxy.cpp.
1678         (WebKit::WebPageProxy::gestureWillBegin): Moved from WebPageProxy.cpp.
1679         (WebKit::WebPageProxy::gestureDidScroll): Moved from WebPageProxy.cpp.
1680         (WebKit::WebPageProxy::gestureDidEnd): Moved from WebPageProxy.cpp.
1681         (WebKit::WebPageProxy::setGestureReachedScrollingLimit): Moved from WebPageProxy.cpp.
1682         (WebKit::WebPageProxy::startDragDrop): Moved from WebPageProxy.cpp.
1683         (WebKit::WebPageProxy::didChangeCompositionSelection): Moved from WebPageProxy.cpp.
1684         (WebKit::WebPageProxy::confirmComposition): Moved from WebPageProxy.cpp.
1685         (WebKit::WebPageProxy::setComposition): Moved from WebPageProxy.cpp.
1686
1687 2011-08-25  Anders Carlsson  <andersca@apple.com>
1688
1689         Handle key-down events in the updated Cocoa text input model
1690         https://bugs.webkit.org/show_bug.cgi?id=67001
1691
1692         Reviewed by Sam Weinig.
1693
1694         * UIProcess/API/mac/WKView.mm:
1695         (-[WKView performKeyEquivalent:]):
1696         Call _disableComplexTextInputIfNecessary so that we'll inform the plug-in that complex text
1697         input has been disabled.
1698
1699         (-[WKView _disableComplexTextInputIfNecessary]):
1700         If the plug-in is using the updated Cocoa text input model specification, disable text input
1701         if the text input window has been dismissed for whatever reason.
1702
1703         (-[WKView _tryHandlePluginComplexTextInputKeyDown:]):
1704         Call _disableComplexTextInputIfNecessary so that we'll inform the plug-in that complex text
1705         input has been disabled.
1706         
1707         (-[WKView _tryPostProcessPluginComplexTextInputKeyDown:]):
1708         If the plug-in is using the updated Cocoa text input model specification, let the input methods
1709         have a go at the keyboard event.
1710
1711         * WebProcess/Plugins/Netscape/mac/NetscapePluginMac.mm:
1712         (WebKit::NetscapePlugin::setComplexTextInputEnabled):
1713         Actually set m_isComplexTextInputEnabled to the right value.
1714
1715 2011-08-25  Anders Carlsson  <andersca@apple.com>
1716
1717         Factor code to send a key-down event to the plug-in out into a new function
1718         https://bugs.webkit.org/show_bug.cgi?id=66999
1719
1720         Reviewed by Darin Adler.
1721
1722         * UIProcess/API/mac/WKView.mm:
1723         (-[WKView _handlePluginComplexTextInputKeyDown:]):
1724         (-[WKView _tryHandlePluginComplexTextInputKeyDown:]):
1725
1726 2011-08-25  Anders Carlsson  <andersca@apple.com>
1727
1728         WKView should keep track of the plug-in complex text input state
1729         https://bugs.webkit.org/show_bug.cgi?id=66990
1730
1731         Reviewed by Sam Weinig.
1732
1733         * UIProcess/API/mac/WKView.mm:
1734         Add a _pluginComplexTextInputState ivar to WKViewData.
1735
1736         (-[WKView _setPluginComplexTextInputState:]):
1737         Set the _pluginComplexTextInputState variable. If text input is being disabled, send back an empty string to the plug-in.
1738
1739         (-[WKView _setPluginComplexTextInputState:WebKit::pluginComplexTextInputIdentifier:]):
1740         Call -[WKView _setPluginComplexTextInputState:].
1741
1742 2011-08-25  Anders Carlsson  <andersca@apple.com>
1743
1744         Move file internal methods to a class continuation in WKView
1745         https://bugs.webkit.org/show_bug.cgi?id=66983
1746
1747         Reviewed by Dan Bernstein.
1748
1749         * UIProcess/API/mac/WKView.mm:
1750         (-[WKView _deviceScaleFactor]):
1751         (-[WKView _setDrawingAreaSize:]):
1752
1753 2011-08-25  Anders Carlsson  <andersca@apple.com>
1754
1755         More work on the updated Cocoa text input specification
1756         https://bugs.webkit.org/show_bug.cgi?id=66977
1757
1758         Reviewed by Sam Weinig.
1759
1760         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
1761         (WebKit::NetscapePlugin::NetscapePlugin):
1762         Initialize m_pluginWantsLegacyCocoaTextInput and m_hasHandledAKeyDownEvent.
1763
1764         * WebProcess/Plugins/Netscape/NetscapePlugin.h:
1765         Add m_pluginWantsLegacyCocoaTextInput and m_hasHandledAKeyDownEvent.
1766         
1767         (WebKit::NetscapePlugin::setPluginWantsLegacyCocoaTextInput):
1768         Add setter. Not called yet.
1769
1770         * WebProcess/Plugins/Netscape/mac/NetscapePluginMac.mm:
1771         (WebKit::NetscapePlugin::platformHandleKeyboardEvent):
1772         Set m_hasHandledAKeyDownEvent to true if we get a KeyDown event.
1773
1774         (WebKit::NetscapePlugin::sendComplexTextInput):
1775         If the plug-in is using the updated Cocoa text input spec, we can disable text input here.
1776
1777         (WebKit::NetscapePlugin::pluginFocusOrWindowFocusChanged):
1778         If the plug-in is using the updated Cocoa text input spec, text input is not enabled when
1779         the plug-in is focused.
1780
1781         (WebKit::NetscapePlugin::setComplexTextInputEnabled):
1782         Set the right text input state based on whether the plug-in is using the updated spec or not.
1783
1784 2011-08-25  Anders Carlsson  <andersca@apple.com>
1785
1786         Return the correct value for NPNVsupportsCarbonBool
1787         https://bugs.webkit.org/show_bug.cgi?id=66964
1788
1789         Reviewed by Adam Roben.
1790
1791         * WebProcess/Plugins/Netscape/NetscapeBrowserFuncs.cpp:
1792         (WebKit::NPN_GetValue):
1793         Remove a FIXME and set the value to true.
1794
1795 2011-08-25  Alexis Menard  <alexis.menard@openbossa.org>
1796
1797         [Qt][WK2] Remove QWKContext class and make sure the WebProcessProxy life is correctly managed.
1798         https://bugs.webkit.org/show_bug.cgi?id=66886
1799
1800         Reviewed by Benjamin Poulain.
1801
1802         Remove QWKContext class from Qt APIs as it is too low level for the vision
1803         of the Qt5 API. QtWebPageProxy now holds directly a WebContext which can be a custom one
1804         or default created one. This patch also ensure that the WebProcessProxy is correctly
1805         destroyed at application exit by removing the circular references between the WebContext,
1806         WebProcessProxy, and WebPageProxy.
1807
1808         * UIProcess/API/qt/qdesktopwebview.cpp:
1809         (QDesktopWebViewPrivate::QDesktopWebViewPrivate):
1810         * UIProcess/API/qt/qtouchwebview.cpp:
1811         (QTouchWebViewPrivate::QTouchWebViewPrivate):
1812         * UIProcess/qt/ClientImpl.cpp:
1813         (qt_wk_setStatusText):
1814         * UIProcess/qt/ClientImpl.h:
1815         * UIProcess/qt/QtWebPageProxy.cpp:
1816         (QtWebPageProxy::defaultWKContext):
1817         (QtWebPageProxy::QtWebPageProxy):
1818         (QtWebPageProxy::~QtWebPageProxy):
1819         * UIProcess/qt/QtWebPageProxy.h:
1820         * UIProcess/qt/qdesktopwebpageproxy.cpp:
1821         (QDesktopWebPageProxy::QDesktopWebPageProxy):
1822         * UIProcess/qt/qdesktopwebpageproxy.h:
1823         * UIProcess/qt/qtouchwebpageproxy.cpp:
1824         (QTouchWebPageProxy::QTouchWebPageProxy):
1825         * UIProcess/qt/qtouchwebpageproxy.h:
1826         * UIProcess/qt/qwkcontext.cpp: Removed.
1827         * UIProcess/qt/qwkcontext.h: Removed.
1828         * UIProcess/qt/qwkcontext_p.h: Removed.
1829         * WebKit2.pro:
1830
1831 2011-08-23  Jocelyn Turcotte  <jocelyn.turcotte@nokia.com>
1832
1833         [Qt][WK2] Drive tiling from the WebProcess and reuse TiledBackingStore.
1834         https://bugs.webkit.org/show_bug.cgi?id=66771
1835
1836         Reviewed by Tor Arne Vestbø.
1837
1838         We need the tiling logic to be moved to the web process to allow invalidated tile rects to be
1839         rendered with the same layout. This also allows the web process to render tiles into
1840         buffers readable directly by the GPU (on supported platforms). We also take the opportunity
1841         to use the TiledBackingStore in WebCore to have only one tiling implementation.
1842
1843         Before this patch:
1844         - TiledDrawingAreaProxy manages tiles from the UI process.
1845         - TiledDrawingArea received rendering requests for a rect and returns the result
1846           to the proxy through shared memory.
1847
1848         After this patch:
1849         - TiledDrawingArea uses a TiledBackingStore to manage tiles from the web process.
1850         - TiledBackingStoreRemoteTile forwards tile creations, update and removals to the proxy.
1851         - TiledDrawingAreaProxy updates the scene graph directly from requests.
1852
1853         It also implements tile buffer swapping correctly in SGTileNode, triggered by the DidRenderFrame message.
1854         Render throttling is implemented by waiting in TiledDrawingArea for the UI process to
1855         notify us when the last rendered frame is ready to make it to the screen.
1856         TiledDrawingAreaTileSets have been replaced by using two instances of TiledBackingStore instead.
1857
1858         * UIProcess/API/qt/qtouchwebpage.cpp:
1859         (QTouchWebPage::updatePaintNode):
1860         * UIProcess/API/qt/qtouchwebview.cpp:
1861         (QTouchWebViewPrivate::updateViewportState):
1862         * UIProcess/DrawingAreaProxy.h:
1863         (WebKit::DrawingAreaProxy::createTile):
1864         (WebKit::DrawingAreaProxy::updateTile):
1865         (WebKit::DrawingAreaProxy::didRenderFrame):
1866         (WebKit::DrawingAreaProxy::removeTile):
1867         * UIProcess/DrawingAreaProxy.messages.in:
1868         * UIProcess/TiledDrawingAreaProxy.cpp:
1869         (WebKit::TiledDrawingAreaProxy::create):
1870         (WebKit::TiledDrawingAreaProxy::TiledDrawingAreaProxy):
1871         (WebKit::TiledDrawingAreaProxy::~TiledDrawingAreaProxy):
1872         (WebKit::TiledDrawingAreaProxy::setVisibleContentRect):
1873         (WebKit::TiledDrawingAreaProxy::setContentsScale):
1874         (WebKit::TiledDrawingAreaProxy::renderNextFrame):
1875         (WebKit::TiledDrawingAreaProxy::sizeDidChange):
1876         (WebKit::TiledDrawingAreaProxy::paint):
1877         * UIProcess/TiledDrawingAreaProxy.h:
1878         * UIProcess/TiledDrawingAreaTile.h: Removed.
1879         * UIProcess/qt/SGAgent.cpp:
1880         (WebKit::NodeUpdateCreateTile::NodeUpdateCreateTile):
1881         (WebKit::NodeUpdateRemoveTile::NodeUpdateRemoveTile):
1882         (WebKit::NodeUpdateSetBackBuffer::NodeUpdateSetBackBuffer):
1883         (WebKit::NodeUpdateSwapTileBuffers::NodeUpdateSwapTileBuffers):
1884         (WebKit::SGAgent::SGAgent):
1885         (WebKit::SGAgent::createTileNode):
1886         (WebKit::SGAgent::removeTileNode):
1887         (WebKit::SGAgent::setNodeBackBuffer):
1888         (WebKit::SGAgent::swapTileBuffers):
1889         (WebKit::SGAgent::updatePaintNode):
1890         (WebKit::SGAgent::getScaleNode):
1891         Make the parenting logic more strict to allow SGAgent to handle the scale nodes itself (remove NodeUpdateCreateScale and use the scale in CreateTile).
1892         Delete the scale node when the last of its child tiles has been removed.
1893
1894         * UIProcess/qt/SGAgent.h:
1895         (WebKit::SGAgent::isSwapPending):
1896
1897         * UIProcess/qt/SGTileNode.cpp:
1898         (WebKit::SGTileNode::SGTileNode):
1899         (WebKit::SGTileNode::setBackBuffer):
1900         (WebKit::SGTileNode::swapIfNeeded):
1901         Replace setTargetRect, setSourceRect and setTexture by a single setBackBuffer method.
1902         This allows all those values to be used only when swapIfNeeded is called later.
1903
1904         * UIProcess/qt/SGTileNode.h:
1905         * UIProcess/qt/TiledDrawingAreaProxyQt.cpp:
1906         (WebKit::TiledDrawingAreaProxy::createTile):
1907         (WebKit::TiledDrawingAreaProxy::updateTile):
1908         (WebKit::TiledDrawingAreaProxy::didRenderFrame):
1909         (WebKit::TiledDrawingAreaProxy::removeTile):
1910         * UIProcess/qt/TiledDrawingAreaTileQt.cpp: Removed.
1911         * UIProcess/qt/qtouchwebpageproxy.cpp:
1912         (QTouchWebPageProxy::renderNextFrame):
1913         * UIProcess/qt/qtouchwebpageproxy.h:
1914         * WebKit2.pro:
1915         * WebProcess/WebPage/DrawingArea.h:
1916         (WebKit::DrawingArea::setVisibleContentRect):
1917         (WebKit::DrawingArea::setContentsScale):
1918         (WebKit::DrawingArea::renderNextFrame):
1919         * WebProcess/WebPage/DrawingArea.messages.in:
1920         * WebProcess/WebPage/TiledBackingStoreRemoteTile.cpp: Added.
1921         (WebKit::TiledBackingStoreRemoteTile::TiledBackingStoreRemoteTile):
1922         (WebKit::TiledBackingStoreRemoteTile::~TiledBackingStoreRemoteTile):
1923         (WebKit::TiledBackingStoreRemoteTile::isDirty):
1924         (WebKit::TiledBackingStoreRemoteTile::invalidate):
1925         (WebKit::TiledBackingStoreRemoteTile::updateBackBuffer):
1926         (WebKit::TiledBackingStoreRemoteTile::swapBackBufferToFront):
1927         (WebKit::TiledBackingStoreRemoteTile::isReadyToPaint):
1928         (WebKit::TiledBackingStoreRemoteTile::paint):
1929         (WebKit::TiledBackingStoreRemoteTileBackend::TiledBackingStoreRemoteTileBackend):
1930         (WebKit::TiledBackingStoreRemoteTileBackend::createTile):
1931         (WebKit::TiledBackingStoreRemoteTileBackend::paintCheckerPattern):
1932         * WebProcess/WebPage/TiledBackingStoreRemoteTile.h: Added.
1933         (WebKit::TiledBackingStoreRemoteTile::create):
1934         (WebKit::TiledBackingStoreRemoteTile::coordinate):
1935         (WebKit::TiledBackingStoreRemoteTile::rect):
1936         (WebKit::TiledBackingStoreRemoteTileClient::~TiledBackingStoreRemoteTileClient):
1937         (WebKit::TiledBackingStoreRemoteTileBackend::create):
1938         * WebProcess/WebPage/TiledDrawingArea.cpp:
1939         (WebKit::TiledDrawingArea::TiledDrawingArea):
1940         (WebKit::TiledDrawingArea::setNeedsDisplay):
1941         (WebKit::TiledDrawingArea::setSize):
1942         (WebKit::TiledDrawingArea::setVisibleContentRect):
1943         (WebKit::TiledDrawingArea::setContentsScale):
1944         (WebKit::TiledDrawingArea::renderNextFrame):
1945         (WebKit::TiledDrawingArea::suspendPainting):
1946         (WebKit::TiledDrawingArea::resumePainting):
1947         (WebKit::TiledDrawingArea::tiledBackingStorePaintBegin):
1948         (WebKit::TiledDrawingArea::tiledBackingStorePaint):
1949         (WebKit::TiledDrawingArea::tiledBackingStorePaintEnd):
1950         (WebKit::TiledDrawingArea::tiledBackingStoreIsUpdatingAllowed):
1951         (WebKit::TiledDrawingArea::tiledBackingStoreContentsRect):
1952         (WebKit::TiledDrawingArea::tiledBackingStoreVisibleRect):
1953         (WebKit::TiledDrawingArea::tiledBackingStoreBackgroundColor):
1954         (WebKit::TiledDrawingArea::createTile):
1955         (WebKit::TiledDrawingArea::updateTile):
1956         (WebKit::TiledDrawingArea::removeTile):
1957         * WebProcess/WebPage/TiledDrawingArea.h:
1958         * WebProcess/WebPage/qt/TiledDrawingAreaQt.cpp: Removed.
1959
1960 2011-08-24  Michael Saboff  <msaboff@apple.com>
1961
1962         Improper comment in CoreIPC/ArgumentEncoder.cpp from 66464
1963         https://bugs.webkit.org/show_bug.cgi?id=66912
1964
1965         Updated the comment in ArgumentEncoder::grow to reflect that system malloc
1966         currently checks to see if a MADV_FREE_REUSABLE will fail before calling it.
1967
1968         Reviewed by Mark Rowe.
1969
1970         * Platform/CoreIPC/ArgumentEncoder.cpp:
1971         (CoreIPC::ArgumentEncoder::grow):
1972
1973 2011-08-24  Anders Carlsson  <andersca@apple.com>
1974
1975         Rename -[WKTextInputWindowController keyboardInputSourceChanged] to unmarkText to indicate what the method does
1976         https://bugs.webkit.org/show_bug.cgi?id=66883
1977
1978         Reviewed by Beth Dakin.
1979
1980         * UIProcess/API/mac/WKTextInputWindowController.h:
1981         * UIProcess/API/mac/WKTextInputWindowController.mm:
1982         (-[WKTextInputPanel _unmarkText]):
1983         (-[WKTextInputWindowController unmarkText]):
1984         * UIProcess/API/mac/WKView.mm:
1985         (-[WKView _pluginFocusOrWindowFocusChanged:pluginComplexTextInputIdentifier:]):
1986
1987 2011-08-24  Oliver Hunt  <oliver@apple.com>
1988
1989         JSNPObject and JSNPMethod create their structure in their constructors
1990         https://bugs.webkit.org/show_bug.cgi?id=66879
1991
1992         Reviewed by Anders Carlsson.
1993
1994         It's not safe to create the Structure for an object inside its constructor
1995         so we hoist construction out into their ::create methods and move the methods
1996         into the cpp file.
1997
1998         * WebProcess/Plugins/Netscape/JSNPMethod.cpp:
1999         (WebKit::JSNPMethod::JSNPMethod):
2000         (WebKit::JSNPMethod::create):
2001         * WebProcess/Plugins/Netscape/JSNPMethod.h:
2002         (WebKit::JSNPMethod::create):
2003         * WebProcess/Plugins/Netscape/JSNPObject.cpp:
2004         (WebKit::JSNPObject::JSNPObject):
2005         (WebKit::JSNPObject::create):
2006         * WebProcess/Plugins/Netscape/JSNPObject.h:
2007         (WebKit::JSNPObject::create):
2008
2009 2011-08-24  Anders Carlsson  <andersca@apple.com>
2010
2011         More plug-in complex text input scaffolding
2012         https://bugs.webkit.org/show_bug.cgi?id=66865
2013
2014         Reviewed by Sam Weinig.
2015
2016         Make -[WKView _doneWithKeyEvent:eventWasHandled:] take an NSEvent * directly. Also
2017         add methods for handling plug-in text input key-down events.
2018
2019         * UIProcess/API/mac/PageClientImpl.mm:
2020         (WebKit::PageClientImpl::doneWithKeyEvent):
2021         * UIProcess/API/mac/WKView.mm:
2022         (-[WKView _tryHandlePluginComplexTextInputKeyDown:]):
2023         (-[WKView keyDown:]):
2024         (-[WKView _tryPostProcessPluginComplexTextInputKeyDown:]):
2025         (-[WKView _doneWithKeyEvent:eventWasHandled:]):
2026         * UIProcess/API/mac/WKViewInternal.h:
2027
2028 2011-08-24  Amruth Raj  <amruthraj@motorola.com>
2029
2030         [GTK] WebProcess crash on hitting assertion m_isWaitingForDidUpdate in DrawingAreaImpl
2031         https://bugs.webkit.org/show_bug.cgi?id=66640
2032
2033         Reviewed by Martin Robinson.
2034
2035         The crash happens when a new timer is created in an existing timer callback. Since 
2036         TimerBase has a single GSource* it gets overridden and the old timer can never get
2037         stopped. To handle this, keep a copy of the old timer and use it for destruction.
2038
2039         * Platform/RunLoop.h:
2040         * Platform/gtk/RunLoopGtk.cpp:
2041         (RunLoop::TimerBase::timerFiredCallback):
2042         Store the timerSource so that even if it is modified by the timer callback,
2043         it can be restored for freeing it.
2044         (RunLoop::TimerBase::start):
2045         Remove destroyNotifyCallback. Destruction is now handled in timerFiredCallback itself.
2046
2047 2011-08-23  Anders Carlsson  <andersca@apple.com>
2048
2049         Prepare WKTextInputWindowController for the new text input model
2050         https://bugs.webkit.org/show_bug.cgi?id=66826
2051
2052         Reviewed by Sam Weinig.
2053
2054         Add -[WKTextInputWindowController hasMarkedText] and make interpretKeyEvent take an
2055         additional usingLegacyCocoaTextInput flag. No functionality change.
2056
2057         * UIProcess/API/mac/WKTextInputWindowController.h:
2058         * UIProcess/API/mac/WKTextInputWindowController.mm:
2059         (-[WKTextInputPanel _interpretKeyEvent:usingLegacyCocoaTextInput:string:]):
2060         (-[WKTextInputPanel _hasMarkedText]):
2061         (-[WKTextInputWindowController hasMarkedText]):
2062         (-[WKTextInputWindowController interpretKeyEvent:usingLegacyCocoaTextInput:string:]):
2063         * UIProcess/API/mac/WKView.mm:
2064         (-[WKView keyDown:]):
2065
2066 2011-08-23  Gopal Raghavan  <gopal.1.raghavan@nokia.com>
2067
2068         [Qt] Unnecessary folders in WebKit2.
2069         https://bugs.webkit.org/show_bug.cgi?id=66583
2070
2071         Reviewed by Benjamin Poulain.
2072
2073         Remove empty autotest folders that were left over from QGraphicsWKView times.
2074
2075         * UIProcess/API/qt/tests/qgraphicswkview: Removed.
2076         * UIProcess/API/qt/tests/qwkhistory: Removed.
2077         * UIProcess/API/qt/tests/qwkpage: Removed.
2078
2079 2011-08-23  Jocelyn Turcotte  <jocelyn.turcotte@nokia.com>
2080
2081         [Qt][WK2] Fix an awful memory leak introduced in r92376.
2082         https://bugs.webkit.org/show_bug.cgi?id=65528
2083
2084         Reviewed by Benjamin Poulain.
2085
2086         The non-virtual destructor would create a leak of the tile update buffer because
2087         the NodeUpdateSetTexture's QImage member destructor wouldn't be called.
2088
2089         * UIProcess/qt/SGAgent.h:
2090         (WebKit::NodeUpdate::~NodeUpdate):
2091
2092 2011-08-23  Steve Block  <steveblock@google.com>
2093
2094         Remove all mention of removed Android files from build scripts
2095         https://bugs.webkit.org/show_bug.cgi?id=66755
2096
2097         Reviewed by Tony Gentilcore.
2098
2099         * Scripts/generate-forwarding-headers.pl:
2100
2101 2011-08-23  Benjamin Poulain  <benjamin@webkit.org>
2102
2103         [Qt][WK2] ViewportInteractionEngine: the position of the content is not corrected when scaling the page manually
2104         https://bugs.webkit.org/show_bug.cgi?id=66672
2105
2106         Reviewed by Kenneth Rohde Christiansen.
2107
2108         Add the method animateContentIntoBoundariesIfNeeded() to move the content back into both scale and position boundaries.
2109         This method is now used as the entry point for animations in order to avoid bugs regarding scale or position.
2110
2111         The existing animation methods were renamed accordingly for clarity and consistency with the updateContent methods.
2112
2113         * UIProcess/qt/ViewportInteractionEngine.cpp:
2114         (WebKit::ViewportInteractionEngine::panGestureEnded):
2115         (WebKit::ViewportInteractionEngine::pinchGestureEnded):
2116         (WebKit::ViewportInteractionEngine::animateContentIntoBoundariesIfNeeded):
2117         (WebKit::ViewportInteractionEngine::animateContentPositionIntoBoundariesIfNeeded):
2118         (WebKit::ViewportInteractionEngine::animateContentScaleIntoBoundariesIfNeeded):
2119         * UIProcess/qt/ViewportInteractionEngine.h:
2120
2121 2011-08-22  Oliver Hunt  <oliver@apple.com>
2122
2123         Delay GC triggered NP object destruction to the next runloop cycle
2124         https://bugs.webkit.org/show_bug.cgi?id=66717
2125
2126         Reviewed by Anders Carlsson.
2127
2128         Delay destruction of plugin objects caused by GC until the next
2129         runloop cycle so that they can execute JS in their finalizers.
2130         We do this using a zero delay timer coupled with a queue of
2131         objects to be finalised.
2132
2133         * WebProcess/Plugins/Netscape/JSNPObject.cpp:
2134         (WebKit::JSNPObject::releaseObject):
2135         * WebProcess/Plugins/Netscape/JSNPObject.h:
2136         * WebProcess/Plugins/Netscape/NPRuntimeObjectMap.cpp:
2137         (WebKit::NPRuntimeObjectMap::NPRuntimeObjectMap):
2138         (WebKit::NPRuntimeObjectMap::invalidate):
2139         (WebKit::NPRuntimeObjectMap::invalidateQueuedObjects):
2140         (WebKit::NPRuntimeObjectMap::addToInvalidationQueue):
2141         (WebKit::NPRuntimeObjectMap::finalize):
2142         * WebProcess/Plugins/Netscape/NPRuntimeObjectMap.h:
2143         * WebProcess/Plugins/Netscape/NPRuntimeUtilities.cpp:
2144         (WebKit::trySafeReleaseNPObject):
2145         * WebProcess/Plugins/Netscape/NPRuntimeUtilities.h:
2146
2147 2011-08-22  Anders Carlsson  <andersca@apple.com>
2148
2149         Move code from PageClientImpl::doneWithKeyEvent to WKView
2150         https://bugs.webkit.org/show_bug.cgi?id=66722
2151
2152         Reviewed by Darin Adler.
2153
2154         * UIProcess/API/mac/PageClientImpl.mm:
2155         (WebKit::PageClientImpl::doneWithKeyEvent):
2156         * UIProcess/API/mac/WKView.mm:
2157         (-[WKView _doneWithKeyEvent:WebKit::eventWasHandled:]):
2158         * UIProcess/API/mac/WKViewInternal.h:
2159
2160 2011-08-22  Anders Carlsson  <andersca@apple.com>
2161
2162         Update the text input context when the plug-in focus changes and not when the complex text input state changes
2163         https://bugs.webkit.org/show_bug.cgi?id=66716
2164
2165         Reviewed by Darin Adler.
2166
2167         * UIProcess/API/mac/WKView.mm:
2168         (-[WKView _pluginFocusOrWindowFocusChanged:pluginComplexTextInputIdentifier:]):
2169         (-[WKView _setPluginComplexTextInputState:WebKit::pluginComplexTextInputIdentifier:]):
2170
2171 2011-08-22  Michael Saboff  <msaboff@apple.com>
2172
2173         REGRESSION (r92231): Apple campus proposal PDF doesn't display in Safari
2174         https://bugs.webkit.org/show_bug.cgi?id=66464
2175
2176         Changed ArgumentEncoder to use system malloc instead of fastMalloc.
2177         FastMalloc uses madvise(MADV_FREE_REUSABLE) which is incompatible with
2178         mach message Out Of Line (OOL) messages that use MACH_MSG_VIRTUAL_COPY.
2179         The system malloc has no such limitation.
2180         Changed sendOutgoingMessage to use MACH_MSG_VIRTUAL_COPY again as it 
2181         doesn't have size limitations that MACH_MSG_PHYSICAL_COPY.
2182         
2183         Reviewed by Anders Carlsson.
2184
2185         * Platform/CoreIPC/ArgumentEncoder.cpp:
2186         (CoreIPC::ArgumentEncoder::~ArgumentEncoder):
2187         (CoreIPC::ArgumentEncoder::grow):
2188         * Platform/CoreIPC/mac/ConnectionMac.cpp:
2189         (CoreIPC::Connection::sendOutgoingMessage):
2190
2191 2011-08-22  Anders Carlsson  <andersca@apple.com>
2192
2193         Use -[NSApplication updateWindows] to update the current input context
2194         https://bugs.webkit.org/show_bug.cgi?id=66715
2195
2196         Reviewed by Alexey Proskuryakov.
2197
2198         * UIProcess/API/mac/WKView.mm:
2199         (-[WKView _setPluginComplexTextInputState:WebKit::pluginComplexTextInputIdentifier:]):
2200
2201 2011-08-22  Anders Carlsson  <andersca@apple.com>
2202
2203         The UI process should keep track of whether a plug-in has focus or not
2204         https://bugs.webkit.org/show_bug.cgi?id=66712
2205
2206         Reviewed by Darin Adler.
2207
2208         This is in preparation for implementing the updated Cocoa text input model.
2209
2210         Pipe through whether a plug-in and its containing window has focus or not, from the
2211         plug-in process and all the way to the UI process.
2212
2213         * PluginProcess/PluginControllerProxy.h:
2214         * PluginProcess/mac/PluginControllerProxyMac.mm:
2215         (WebKit::PluginControllerProxy::pluginFocusOrWindowFocusChanged):
2216         * UIProcess/API/mac/PageClientImpl.h:
2217         * UIProcess/API/mac/PageClientImpl.mm:
2218         (WebKit::PageClientImpl::pluginFocusOrWindowFocusChanged):
2219         * UIProcess/API/mac/WKView.mm:
2220         (-[WKView _pluginFocusOrWindowFocusChanged:pluginComplexTextInputIdentifier:]):
2221         * UIProcess/API/mac/WKViewInternal.h:
2222         * UIProcess/PageClient.h:
2223         * UIProcess/WebPageProxy.h:
2224         * UIProcess/WebPageProxy.messages.in:
2225         * UIProcess/mac/WebPageProxyMac.mm:
2226         (WebKit::WebPageProxy::pluginFocusOrWindowFocusChanged):
2227         * WebProcess/Plugins/Netscape/NetscapePlugin.h:
2228         * WebProcess/Plugins/Netscape/mac/NetscapePluginMac.mm:
2229         (WebKit::NetscapePlugin::platformSetFocus):
2230         (WebKit::NetscapePlugin::windowFocusChanged):
2231         (WebKit::NetscapePlugin::pluginFocusOrWindowFocusChanged):
2232         * WebProcess/Plugins/Netscape/mac/PluginProxyMac.mm:
2233         (WebKit::PluginProxy::pluginFocusOrWindowFocusChanged):
2234         * WebProcess/Plugins/PluginController.h:
2235         * WebProcess/Plugins/PluginProxy.h:
2236         * WebProcess/Plugins/PluginProxy.messages.in:
2237         * WebProcess/Plugins/PluginView.cpp:
2238         (WebKit::PluginView::pluginFocusOrWindowFocusChanged):
2239         * WebProcess/Plugins/PluginView.h:
2240
2241 2011-08-22  Anders Carlsson  <andersca@apple.com>
2242
2243         Update the current NSTextInputContext whenever the plug-in complex text input state changes
2244         https://bugs.webkit.org/show_bug.cgi?id=66709
2245
2246         Reviewed by Sam Weinig.
2247
2248         Call [NSTextInputContext currentInputContext] which will force AppKit to update the current input
2249         context. Fixes a rare case when the out-of-line editing window wouldn't appear.
2250
2251         * UIProcess/API/mac/WKView.mm:
2252         (-[WKView _setPluginComplexTextInputState:WebKit::pluginComplexTextInputIdentifier:]):
2253
2254 2011-08-19  Anders Carlsson  <andersca@apple.com>
2255
2256         Another attempt at fixing the Windows build.
2257
2258         * UIProcess/PageClient.h:
2259
2260 2011-08-19  Anders Carlsson  <andersca@apple.com>
2261
2262         Fix Windows build.
2263
2264         * WebProcess/Plugins/PluginController.h:
2265
2266 2011-08-19  Anders Carlsson  <andersca@apple.com>
2267
2268         Make the complex text input state a tri-state enum instead of a boolean
2269         https://bugs.webkit.org/show_bug.cgi?id=62245
2270
2271         Reviewed by Sam Weinig.
2272
2273         This is to prepare the infrastructure for supporting the updated Cocoa text input model for plug-ins.
2274
2275         * PluginProcess/PluginControllerProxy.cpp:
2276         * PluginProcess/PluginControllerProxy.h:
2277         * PluginProcess/mac/PluginControllerProxyMac.mm:
2278         (WebKit::PluginControllerProxy::setComplexTextInputState):
2279         (WebKit::PluginControllerProxy::compositingRenderServerPort):
2280         * Shared/Plugins/mac: Added.
2281         * Shared/Plugins/mac/PluginComplexTextInputState.h: Added.
2282         (WebKit::isValidPluginComplexTextInputState):
2283         * UIProcess/API/mac/PageClientImpl.h:
2284         * UIProcess/API/mac/PageClientImpl.mm:
2285         (WebKit::PageClientImpl::setPluginComplexTextInputState):
2286         * UIProcess/API/mac/WKView.mm:
2287         (-[WKView _setPluginComplexTextInputState:WebKit::pluginComplexTextInputIdentifier:]):
2288         * UIProcess/API/mac/WKViewInternal.h:
2289         * UIProcess/PageClient.h:
2290         * UIProcess/WebPageProxy.h:
2291         * UIProcess/WebPageProxy.messages.in:
2292         * UIProcess/mac/WebPageProxyMac.mm:
2293         (WebKit::WebPageProxy::setPluginComplexTextInputState):
2294         * WebKit2.xcodeproj/project.pbxproj:
2295         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
2296         (WebKit::NetscapePlugin::NetscapePlugin):
2297         * WebProcess/Plugins/Netscape/NetscapePlugin.h:
2298         * WebProcess/Plugins/Netscape/mac/NetscapePluginMac.mm:
2299         (WebKit::NetscapePlugin::platformSetFocus):
2300         (WebKit::NetscapePlugin::windowFocusChanged):
2301         (WebKit::NetscapePlugin::setComplexTextInputEnabled):
2302         * WebProcess/Plugins/Netscape/mac/PluginProxyMac.mm:
2303         (WebKit::PluginProxy::setComplexTextInputState):
2304         * WebProcess/Plugins/PluginController.h:
2305         * WebProcess/Plugins/PluginProxy.cpp:
2306         * WebProcess/Plugins/PluginProxy.h:
2307         * WebProcess/Plugins/PluginProxy.messages.in:
2308         * WebProcess/Plugins/PluginView.cpp:
2309         (WebKit::PluginView::~PluginView):
2310         (WebKit::PluginView::setComplexTextInputState):
2311         (WebKit::PluginView::compositingRenderServerPort):
2312         * WebProcess/Plugins/PluginView.h:
2313
2314 2011-08-19  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>
2315
2316         [Qt] [WK2] Provide API for intercept (and possible ignore) links clicked in QDesktopWebView
2317         https://bugs.webkit.org/show_bug.cgi?id=65920
2318
2319         Reviewed by Benjamin Poulain.
2320
2321         This patch makes QDesktopWebView delegate the decision of whether a navigation
2322         should proceed to a slot in QML. The user of the DesktopWebView must implement a
2323         'navigationPolicyForUrl()' if it wants to use the feature.
2324
2325         Such feature is useful for implementing opening links in "new tab" by using a
2326         specific mouse button or mouse button plus keyboard modifiers.
2327
2328         The patch introduces a internal Qt-level interface called PolicyInterface, that
2329         is used by QtWebPageProxy to delegate policy calls. A concrete implementation is
2330         provided for QDesktopWebView.
2331
2332         * Shared/qt/WebCoreArgumentCodersQt.cpp:
2333         (CoreIPC::::encode):
2334         (CoreIPC::::decode):
2335         Implement the serialization of the Request URL, which is the only data
2336         we exposing from the Request.
2337
2338         * WebKit2.pro:
2339         * UIProcess/qt/PolicyInterface.h: Added.
2340         * UIProcess/qt/QtWebPageProxy.cpp:
2341         (QtWebPageProxy::QtWebPageProxy):
2342         (QtWebPageProxy::init):
2343         * UIProcess/qt/QtWebPageProxy.h:
2344         Register a Policy Client in the WK2 C API only if there's a PolicyInterface available.
2345
2346         * UIProcess/qt/ClientImpl.h:
2347         * UIProcess/qt/ClientImpl.cpp:
2348         (toPolicyInterface):
2349         (toQtMouseButton):
2350         (toQtKeyboardModifiers):
2351         (qt_wk_decidePolicyForNavigationAction):
2352         Implement the callback for the Page Policy Client. It will translate the
2353         arguments to Qt jargon and call PolicyInterface.
2354
2355         * UIProcess/qt/qdesktopwebpageproxy.cpp:
2356         (QDesktopWebPageProxy::QDesktopWebPageProxy):
2357         * UIProcess/API/qt/qdesktopwebview.h:
2358         * UIProcess/API/qt/qdesktopwebview_p.h:
2359         * UIProcess/API/qt/qdesktopwebview.cpp:
2360         (toPolicyAction):
2361         (hasMetaMethod):
2362         (QDesktopWebViewPrivate::navigationPolicyForURL):
2363         The concrete implementation for QDesktopWebView. Its private object implements
2364         the PolicyInterface and try to call a possible function defined in QML (so return
2365         value and arguments all QVariants). If there's no such a function, returns the
2366         default UsePolicy, like if we haven't registered a PolicyClient in WK2 C API.
2367
2368         * UIProcess/API/qt/tests/qmltests/DesktopWebView/tst_navigationPolicyForUrl.qml: Added.
2369         * UIProcess/API/qt/tests/qmltests/common/test2.html: Added.
2370         * UIProcess/API/qt/tests/qmltests/qmltests.pro:
2371         Add a test for DesktopWebView QML element making use of a button and a modifier to
2372         ignore a navigation.
2373
2374         * UIProcess/qt/qtouchwebpageproxy.cpp:
2375         (QTouchWebPageProxy::QTouchWebPageProxy):
2376         For now, we don't have a PolicyInterface for QTouchWebView.
2377
2378 2011-08-18  Anders Carlsson  <andersca@apple.com>
2379
2380         WebProcess crashes during startup if libdispatch is initialized by WebProcessShim.dylib
2381         https://bugs.webkit.org/show_bug.cgi?id=66508
2382         <rdar://problem/9828476>
2383
2384         Reviewed by Mark Rowe.
2385
2386         * mac/MainMac.cpp:
2387         (closeUnusedFileDescriptors):
2388         Check if a file descriptor is a kqueue and don't close it if that is the case. While this
2389         isn't a complete fix, (it won't work if other initializers end up creating non-kqueue file descriptors)
2390         it's good enough for Snow Leopard. For Lion, we should use the new posix_spawn API that lets you whitelist
2391         file descriptors from the parent process.
2392
2393 2011-08-19  Benjamin Poulain  <benjamin@webkit.org>
2394
2395         [Qt][WK2] Add a basic engine to control the content of the viewport
2396         https://bugs.webkit.org/show_bug.cgi?id=66383
2397
2398         Reviewed by Andreas Kling.
2399
2400         Add ViewportInteractionEngine to handle the content of the viewport. The class make
2401         sure the QTouchWebPage stays in the viewport and in the boundaries.
2402
2403         * UIProcess/API/qt/qdesktopwebview.cpp:
2404         (QDesktopWebViewPrivate::loadDidCommit):
2405         * UIProcess/API/qt/qdesktopwebview_p.h:
2406         * UIProcess/API/qt/qtouchwebpage.cpp:
2407         (QTouchWebPage::QTouchWebPage): Set the transform origin to the top left so
2408         we can asume the position 0, 0 is always the top left of the page.
2409         (QTouchWebPagePrivate::_q_commitScaleChange): Make commitScaleChange a slot
2410         in order to completely decouple the ViewportInteractionEngine and the WebKit classes.
2411         * UIProcess/API/qt/qtouchwebpage.h:
2412         * UIProcess/API/qt/qtouchwebpage_p.h:
2413         * UIProcess/API/qt/qtouchwebview.cpp:
2414         (QTouchWebViewPrivate::QTouchWebViewPrivate):
2415         (QTouchWebViewPrivate::loadDidCommit):
2416         (QTouchWebViewPrivate::_q_viewportRectUpdated): Make _q_viewportRectUpdated() a slot
2417         for reducing coupling.
2418         (QTouchWebViewPrivate::updateViewportConstraints):
2419         (QTouchWebViewPrivate::setViewportArguments):
2420         (QTouchWebView::geometryChanged):
2421         * UIProcess/API/qt/qtouchwebview.h:
2422         * UIProcess/API/qt/qtouchwebview_p.h:
2423         * UIProcess/qt/ClientImpl.cpp:
2424         (qt_wk_didCommitLoadForFrame):
2425         * UIProcess/qt/QtGestureRecognizer.cpp:
2426         (WebKit::QtGestureRecognizer::QtGestureRecognizer):
2427         * UIProcess/qt/QtGestureRecognizer.h: Change the gesture recognizer to talk directly
2428         to the ViewportInteractionEngine instead of interacting through TouchViewInterface.
2429         * UIProcess/qt/QtPanGestureRecognizer.cpp:
2430         (WebKit::QtPanGestureRecognizer::QtPanGestureRecognizer):
2431         (WebKit::QtPanGestureRecognizer::recognize):
2432         * UIProcess/qt/QtPanGestureRecognizer.h:
2433         * UIProcess/qt/QtPinchGestureRecognizer.cpp:
2434         (WebKit::QtPinchGestureRecognizer::QtPinchGestureRecognizer):
2435         (WebKit::QtPinchGestureRecognizer::recognize):
2436         * UIProcess/qt/QtPinchGestureRecognizer.h:
2437         * UIProcess/qt/QtWebPageProxy.cpp:
2438         (QtWebPageProxy::loadDidCommit): Add the loadCommited callback in order
2439         to reset the viewport state when the page change.
2440         * UIProcess/qt/QtWebPageProxy.h:
2441         * UIProcess/qt/TouchViewInterface.cpp:
2442         (WebKit::TouchViewInterface::TouchViewInterface):
2443         (WebKit::TouchViewInterface::contentSizeChanged):
2444         (WebKit::TouchViewInterface::loadDidCommit):
2445         * UIProcess/qt/TouchViewInterface.h:
2446         * UIProcess/qt/ViewInterface.h:
2447         * UIProcess/qt/ViewportInteractionEngine.cpp: Added.
2448         (WebKit::visibleRectInContentCoordinate):
2449         (WebKit::contentRectInViewportCoordinate):
2450         (WebKit::ViewportUpdateGuard::ViewportUpdateGuard):
2451         (WebKit::ViewportUpdateGuard::~ViewportUpdateGuard):
2452         (WebKit::ViewportInteractionEngine::ViewportInteractionEngine):
2453         (WebKit::ViewportInteractionEngine::reset):
2454         (WebKit::ViewportInteractionEngine::setConstraints):
2455         (WebKit::ViewportInteractionEngine::panGestureStarted):
2456         (WebKit::ViewportInteractionEngine::panGestureRequestScroll):
2457         (WebKit::ViewportInteractionEngine::panGestureCancelled):
2458         (WebKit::ViewportInteractionEngine::panGestureEnded):
2459         (WebKit::ViewportInteractionEngine::pinchGestureStarted):
2460         (WebKit::ViewportInteractionEngine::pinchGestureRequestUpdate):
2461         (WebKit::ViewportInteractionEngine::pinchGestureEnded):
2462         (WebKit::ViewportInteractionEngine::contentGeometryChanged):
2463         (WebKit::ViewportInteractionEngine::contentScaleChanged):
2464         (WebKit::ViewportInteractionEngine::updateContentIfNeeded):
2465         (WebKit::ViewportInteractionEngine::updateContentScaleIfNeeded):
2466         (WebKit::ViewportInteractionEngine::updateContentPositionIfNeeded):
2467         (WebKit::ViewportInteractionEngine::animateContentPositionToBoundaries):
2468         (WebKit::ViewportInteractionEngine::animateContentScaleToBoundaries):
2469         (WebKit::ViewportInteractionEngine::scaleContent):
2470         * UIProcess/qt/ViewportInteractionEngine.h: Added.
2471         (WebKit::ViewportInteractionEngine::Constraints::Constraints):
2472         (WebKit::operator==):
2473         * UIProcess/qt/qtouchwebpageproxy.cpp:
2474         (QTouchWebPageProxy::QTouchWebPageProxy):
2475         * UIProcess/qt/qtouchwebpageproxy.h:
2476         * WebKit2.pro:
2477
2478 2011-08-19  Lars Knudsen  <lars.knudsen@nokia.com>
2479
2480         [Qt][WK2] Change the rect argument of QtWebPageProxy::paint() to const ref
2481         https://bugs.webkit.org/show_bug.cgi?id=66549
2482
2483         Reviewed by Benjamin Poulain.
2484
2485         * UIProcess/qt/QtWebPageProxy.cpp:
2486         (QtWebPageProxy::paint):
2487         * UIProcess/qt/QtWebPageProxy.h:
2488
2489 2011-08-19  MORITA Hajime  <morrita@google.com>
2490
2491         Spell-checking against execCommand() inserted HTML doesn't care word boundary.
2492         https://bugs.webkit.org/show_bug.cgi?id=65902
2493
2494         Reviewed by Ryosuke Niwa.
2495         
2496         Add exports for window.internals object.
2497
2498         * win/WebKit2.def:
2499         * win/WebKit2CFLite.def:
2500
2501 2011-08-18  Beth Dakin  <bdakin@apple.com>
2502
2503         Reviewed by Sam Weinig.
2504
2505         https://bugs.webkit.org/show_bug.cgi?id=66495
2506         Lion-specific scroller SPIs can use forward declaration instead of 
2507         WebKitSystemInterface
2508
2509         * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
2510         (InitWebCoreSystemInterface):
2511
2512 2011-08-18  Darin Adler  <darin@apple.com>
2513
2514         Made some code even more private to a particular file and class
2515         https://bugs.webkit.org/show_bug.cgi?id=66428
2516
2517         Reviewed by Anders Carlsson.
2518
2519         * UIProcess/API/mac/WKView.mm:
2520         (-[WKView _setDrawingAreaSize:]): Made this file internal.
2521         * UIProcess/API/mac/WKViewInternal.h: Removed _setDrawingAreaSize.
2522         * UIProcess/DrawingAreaProxy.h: Made sizeDidChange private.
2523
2524 2011-08-18  Amruth Raj  <amruthraj@motorola.com>
2525
2526         [GTK] [WK2] Activating sub menus cause the WebProcess to crash
2527         https://bugs.webkit.org/show_bug.cgi?id=66471
2528
2529         Reviewed by Anders Carlsson.
2530
2531         * UIProcess/gtk/WebContextMenuProxyGtk.cpp:
2532         (WebKit::WebContextMenuProxyGtk::createGtkMenu):
2533
2534 2011-08-18  Adam Roben  <aroben@apple.com>
2535
2536         Update the device scale factor when the WKView's window changes
2537
2538         Fixes <http://webkit.org/b/66412> <rdar://problem/9971958> WebKit doesn't react when a
2539         WebView is moved between windows with different backing scale factors
2540
2541         Reviewed by Anders Carlsson.
2542
2543         * UIProcess/API/mac/WKView.mm:
2544         (-[WKView viewDidMoveToWindow]): Call setDeviceScaleFactor because our new window (or no
2545         window at all) might have a different backing scale factor than the previous one.
2546         (-[WKView _deviceScaleFactor]): Moved to the new FileInternal category.
2547
2548 2011-08-18  Adam Roben  <aroben@apple.com>
2549
2550         Make WebPageProxy keep track of the current device scale factor
2551
2552         The device scale factor is no longer considered part of WebPageProxy's "view state". It now
2553         has its own setter/getter. This made the code a little simpler and more similar to the page
2554         scale factor. Each port-specific WebKit2 view is now responsible for calling
2555         WebPageProxy::setDeviceScaleFactor whenever it thinks the device scale factor might have
2556         changed.
2557
2558         Fixes <http://webkit.org/b/66466> WebKit2 requires every port-specific view to keep track of
2559         the current device scale factor
2560
2561         Reviewed by Anders Carlsson.
2562
2563         * UIProcess/API/efl/PageClientImpl.cpp:
2564         * UIProcess/API/efl/PageClientImpl.h:
2565         * UIProcess/API/gtk/PageClientImpl.h:
2566         * UIProcess/API/mac/PageClientImpl.h:
2567         * UIProcess/API/mac/PageClientImpl.mm:
2568         * UIProcess/PageClient.h:
2569         * UIProcess/qt/QtWebPageProxy.h:
2570         * UIProcess/win/WebView.h:
2571         Removed deviceScaleFactor.
2572
2573         * UIProcess/API/mac/WKView.mm:
2574         (-[WKView _deviceScaleFactor]): Added. Code came from PageClientImpl::deviceScaleFactor.
2575         (-[WKView _windowDidChangeResolution:]): Changed to call WebPageProxy::setDeviceScaleFactor.
2576
2577         * UIProcess/WebPageProxy.cpp:
2578         (WebKit::WebPageProxy::WebPageProxy): Initialize m_deviceScaleFactor.
2579         (WebKit::WebPageProxy::viewStateDidChange): Removed device-scale-factor-related code.
2580         (WebKit::WebPageProxy::setDeviceScaleFactor): Added. Records the new device scale factor and
2581         tells the DrawingAreaProxy about it if it's actually changed.
2582         (WebKit::WebPageProxy::creationParameters): Use m_deviceScaleFactor instead of calling out
2583         to the PageClient.
2584
2585         * UIProcess/WebPageProxy.h: Added m_deviceScaleFactor and setDeviceScaleFactor, which
2586         replaces the DeviceScaleFactor ViewStateFlag.
2587         (WebKit::WebPageProxy::deviceScaleFactor): Inlined this now-simple getter.
2588
2589 2011-08-17  Adam Roben  <aroben@apple.com>
2590
2591         Make WebCore keep track of the current device scale factor
2592
2593         Fixes <http://webkit.org/b/66413> WebCore requires every WebKit port to keep track of the
2594         device scale factor
2595
2596         Reviewed by Darin Adler.
2597
2598         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
2599         * WebProcess/WebCoreSupport/WebChromeClient.h:
2600         Removed deviceScaleFactor.
2601
2602         * WebProcess/WebPage/DrawingAreaImpl.cpp:
2603         (WebKit::DrawingAreaImpl::sendDidUpdateBackingStoreState):
2604         (WebKit::DrawingAreaImpl::exitAcceleratedCompositingMode):
2605         (WebKit::DrawingAreaImpl::display):
2606         * WebProcess/WebPage/FindController.cpp:
2607         (WebKit::FindController::updateFindIndicator):
2608         (WebKit::FindController::hideFindIndicator):
2609         * WebProcess/WebPage/ca/LayerTreeHostCA.cpp:
2610         (WebKit::LayerTreeHostCA::deviceScaleFactor):
2611         Changed to get the device scale factor from WebCore.
2612
2613         * WebProcess/WebPage/WebPage.cpp:
2614         (WebKit::WebPage::WebPage):
2615         (WebKit::WebPage::setDeviceScaleFactor):
2616         * WebProcess/WebPage/WebPage.h:
2617         Removed m_deviceScaleFactor. We always get the scale factor from WebCore now.
2618
2619 2011-08-17  Anders Carlsson  <andersca@apple.com>
2620
2621         Remove unused Core Animation related classes
2622         https://bugs.webkit.org/show_bug.cgi?id=66393
2623
2624         Reviewed by Darin Adler.
2625
2626         * Shared/mac/CoreAnimationRenderer.h: Removed.
2627         * Shared/mac/CoreAnimationRenderer.mm: Removed.
2628         * Shared/mac/ShareableSurface.cpp: Removed.
2629         * Shared/mac/ShareableSurface.h: Removed.
2630         * WebKit2.xcodeproj/project.pbxproj:
2631
2632 2011-08-15  Dmitry Titov  <dimich@chromium.org>
2633
2634         FrameLoaderClient::transferLoadingResourceFromPage does not have enough parameters
2635         https://bugs.webkit.org/show_bug.cgi?id=66165
2636
2637         Reviewed by Darin Fisher.
2638
2639         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
2640         (WebKit::WebFrameLoaderClient::transferLoadingResourceFromPage):
2641         * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
2642
2643 2011-08-15  Balazs Kelemen  <kbalazs@webkit.org>
2644
2645         [Qt][WK2] Unreviewed build fix after r93058.
2646
2647         * UIProcess/TiledDrawingAreaProxy.cpp:
2648         (WebKit::TiledDrawingAreaProxy::deviceScaleFactorDidChange):
2649         * UIProcess/TiledDrawingAreaProxy.h:
2650
2651 2011-08-15  Adam Roben  <aroben@apple.com>
2652
2653         Update pages' style and content scale when the window's backing scale factor changes
2654
2655         Unfortunately, I couldn't think of a way to test this in an automated fashion.
2656
2657         Fixes <http://webkit.org/b/66229> <rdar://problem/9906269> WebKit doesn't react to device
2658         scale factor changes
2659
2660         Reviewed by Simon Fraser.
2661
2662         * UIProcess/API/mac/WKView.mm:
2663         (-[WKView addWindowObserversForWindow:]):
2664         (-[WKView removeWindowObservers]):
2665         Listen for the notification that tells us the window's backing scale has changed.
2666
2667         (-[WKView _windowDidChangeResolution:]): Tell the WebPageProxy about the change.
2668
2669         * UIProcess/DrawingAreaProxy.h:
2670         * UIProcess/DrawingAreaProxyImpl.h:
2671         Added deviceScaleFactorDidChange.
2672
2673         * UIProcess/DrawingAreaProxyImpl.cpp:
2674         (WebKit::DrawingAreaProxyImpl::deviceScaleFactorDidChange): Request a new backing store
2675         since the current one is using an old device scale factor.
2676         (WebKit::DrawingAreaProxyImpl::sendUpdateBackingStoreState): Send the device scale factor
2677         along to the web process so it can render accordingly. This is how we tell the web process
2678         about device scale factor changes.
2679
2680         * UIProcess/WebPageProxy.cpp:
2681         (WebKit::WebPageProxy::viewStateDidChange): Tell the DrawingAreaProxy when the device scale
2682         factor changes.
2683         (WebKit::WebPageProxy::deviceScaleFactor): Added this simple getter that calls through to
2684         the PageClient. DrawingAreaProxy uses this function.
2685
2686         * UIProcess/WebPageProxy.h: Added new members.
2687
2688         * WebProcess/WebPage/DrawingArea.h:
2689         (WebKit::DrawingArea::updateBackingStoreState):
2690         * WebProcess/WebPage/DrawingArea.messages.in:
2691         * WebProcess/WebPage/DrawingAreaImpl.h:
2692         Send the device scale factor in the UpdateBackingStoreState message.
2693
2694         * WebProcess/WebPage/DrawingAreaImpl.cpp:
2695         (WebKit::DrawingAreaImpl::updateBackingStoreState): Tell the WebPage and LayerTreeHost about
2696         the new device scale factor.
2697
2698         * WebProcess/WebPage/LayerTreeHost.h:
2699         * WebProcess/WebPage/ca/LayerTreeHostCA.h:
2700         Added deviceScaleFactorDidChange.
2701
2702         * WebProcess/WebPage/WebPage.cpp:
2703         (WebKit::WebPage::setDeviceScaleFactor): Store the new scale factor and tell the page about
2704         it so that, e.g., scale-factor-dependent media queries will be reevaluated.
2705
2706         * WebProcess/WebPage/WebPage.h: Added setDeviceScaleFactor.
2707
2708         * WebProcess/WebPage/ca/LayerTreeHostCA.cpp:
2709         (WebKit::LayerTreeHostCA::deviceScaleFactorDidChange): Tell the layer for non-composited
2710         content about the new scale factor.
2711
2712 2011-08-15  Benjamin Poulain  <benjamin@webkit.org>
2713
2714         [Qt][WK2] Get rid of QTouchWebPagePrivate::getPageViewPrivate()
2715         https://bugs.webkit.org/show_bug.cgi?id=66222
2716
2717         Reviewed by Kenneth Rohde Christiansen.
2718
2719         The function QTouchWebPagePrivate::getPageViewPrivate() exposed
2720         the private QTouchWebPage to any object in WebKit.
2721
2722         Instead, use the friend keyword to list which objects can access
2723         the internal of QTouchWebPage.
2724
2725         * UIProcess/API/qt/qtouchwebpage.h:
2726         * UIProcess/API/qt/qtouchwebpage_p.h:
2727         * UIProcess/API/qt/qtouchwebview.cpp:
2728         (QTouchWebViewPrivate::QTouchWebViewPrivate):
2729         (QTouchWebViewPrivate::viewportRectUpdated):
2730
2731 2011-08-15  Balazs Kelemen  <kbalazs@webkit.org>
2732
2733         Unreviewed.
2734         Fix Qt-WK2 build after r93040.
2735
2736         * UIProcess/qt/QtWebPageProxy.h:
2737         (QtWebPageProxy::deviceScaleFactor):
2738
2739 2011-08-10  Adam Roben  <aroben@apple.com>
2740
2741         Clear up scale factor terminology
2742
2743         WebKit by and large deals with two scale factors: one intrinsic to the device on which the
2744         software is running, and one that is per-Page and can be controlled via API calls. This
2745         patch names the former "deviceScaleFactor" and the latter "pageScaleFactor", and makes the
2746         code use those names. It should introduce no behavior changes.
2747
2748         Fixes <http://webkit.org/b/55787> WebKit uses multiple conflicting names to refer to the
2749         device scale factor
2750
2751         Reviewed by Simon Fraser.
2752
2753         * Shared/UpdateInfo.cpp:
2754         * Shared/UpdateInfo.h:
2755         * Shared/WebPageCreationParameters.cpp:
2756         * Shared/WebPageCreationParameters.h:
2757         * UIProcess/API/C/WKPage.cpp:
2758         * UIProcess/API/efl/PageClientImpl.cpp:
2759         * UIProcess/API/efl/PageClientImpl.h:
2760         * UIProcess/API/gtk/PageClientImpl.h:
2761         * UIProcess/API/mac/PageClientImpl.h:
2762         * UIProcess/API/mac/PageClientImpl.mm:
2763         * UIProcess/BackingStore.cpp:
2764         * UIProcess/BackingStore.h:
2765         * UIProcess/DrawingAreaProxyImpl.cpp:
2766         * UIProcess/PageClient.h:
2767         * UIProcess/WebPageProxy.cpp:
2768         * UIProcess/WebPageProxy.h:
2769         * UIProcess/WebPageProxy.messages.in:
2770         * UIProcess/WebPopupMenuProxy.h:
2771         * UIProcess/gtk/WebPopupMenuProxyGtk.cpp:
2772         * UIProcess/gtk/WebPopupMenuProxyGtk.h:
2773         * UIProcess/mac/BackingStoreMac.mm:
2774         * UIProcess/mac/WebPageProxyMac.mm:
2775         * UIProcess/mac/WebPopupMenuProxyMac.h:
2776         * UIProcess/mac/WebPopupMenuProxyMac.mm:
2777         * UIProcess/qt/WebPopupMenuProxyQt.h:
2778         * UIProcess/win/WebPopupMenuProxyWin.h:
2779         * UIProcess/win/WebView.h:
2780         * WebProcess/InjectedBundle/API/c/WKBundlePage.cpp:
2781         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
2782         * WebProcess/WebCoreSupport/WebChromeClient.h:
2783         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
2784         * WebProcess/WebPage/DrawingAreaImpl.cpp:
2785         * WebProcess/WebPage/FindController.cpp:
2786         * WebProcess/WebPage/WebPage.cpp:
2787         * WebProcess/WebPage/WebPage.h:
2788         * WebProcess/WebPage/WebPage.messages.in:
2789         * WebProcess/WebPage/ca/LayerTreeHostCA.cpp:
2790         * WebProcess/WebPage/ca/LayerTreeHostCA.h:
2791
2792 2011-08-13  Sam Weinig  <sam@webkit.org>
2793
2794         Remove unused variables from WKFullScreenWindowController.h
2795         https://bugs.webkit.org/show_bug.cgi?id=66193
2796
2797         Reviewed by Dan Bernstein.
2798
2799         * UIProcess/mac/WKFullScreenWindowController.h:
2800         Remove _layerViewPlaceholder, _isWindowLoaded and _initialFrame which were not used.
2801
2802 2011-08-12  Dan Bernstein  <mitz@apple.com>
2803
2804         <rdar://problem/7337717> Add an option to automatically show tooltips (with the full text) over truncated text
2805         https://bugs.webkit.org/show_bug.cgi?id=66178
2806
2807         Reviewed by Simon Fraser.
2808
2809         * Shared/WebPreferencesStore.h:
2810         * UIProcess/API/C/WKPreferences.cpp:
2811         (WKPreferencesSetShowsToolTipOverTruncatedText): Added this setter.
2812         (WKPreferencesGetShowsToolTipOverTruncatedText): Added this getter.
2813         * UIProcess/API/C/WKPreferencesPrivate.h:
2814         * WebProcess/WebPage/WebPage.cpp:
2815         (WebKit::WebPage::updatePreferences): Handle the showsToolTipOverTruncatedText preference.
2816
2817 2011-08-12  Mark Rowe  <mrowe@apple.com>
2818
2819         Be more forward-looking in the choice of compiler.
2820
2821         Rubber-stamped by Jon Honeycutt.
2822
2823         * Configurations/CompilerVersion.xcconfig:
2824
2825 2011-08-11  Viatcheslav Ostapenko  <ostapenko.viatcheslav@nokia.com>
2826
2827         VectorArgumentCoder doesn't encode/decode enough data for more than one byte vector elements
2828         https://bugs.webkit.org/show_bug.cgi?id=66109
2829
2830         Reviewed by Anders Carlsson.
2831
2832         Multiply vector size by element size in encode/decode to get correct byte size of vector data.
2833
2834         * Platform/CoreIPC/ArgumentCoders.h:
2835
2836 2011-08-11  Nico Weber  <thakis@chromium.org>
2837
2838         Remove incorrect comment about m_wheelEventHandlerCount
2839         https://bugs.webkit.org/show_bug.cgi?id=66117
2840
2841         Reviewed by Simon Fraser.
2842
2843         From what I can tell, this number is changed only in
2844         Frame::notifyChromeClientWheelEventHandlerCountChanged(),
2845         and there it just reads the number modified in
2846         Document::didAdd/RemoveWheelEventHandler(). So this is just the number
2847         of event handlers (and not related to horizontal scrollbars), and the
2848         variable name expresses that already.
2849
2850         * UIProcess/WebPageProxy.h:
2851
2852 2011-08-11  Kenneth Rohde Christiansen  <kenneth@webkit.org>
2853
2854         [Qt/WK2] Add initial support for viewport meta tag
2855         https://bugs.webkit.org/show_bug.cgi?id=65975
2856
2857         Reviewed by Benjamin Poulain.
2858
2859         Redirect the viewport arguments through to the view.
2860
2861         * UIProcess/API/qt/qdesktopwebview.cpp:
2862         (QDesktopWebViewPrivate::didReceiveViewportArguments):
2863         * UIProcess/API/qt/qdesktopwebview_p.h:
2864         * UIProcess/API/qt/qtouchwebview.cpp:
2865         (QTouchWebView::geometryChanged):
2866         * UIProcess/qt/QtWebPageProxy.cpp:
2867         (QtWebPageProxy::setViewportArguments):
2868         * UIProcess/qt/QtWebPageProxy.h:
2869         * UIProcess/qt/TouchViewInterface.cpp:
2870         (WebKit::TouchViewInterface::updateViewportState):
2871         (WebKit::TouchViewInterface::didReceiveViewportArguments):
2872         * UIProcess/qt/TouchViewInterface.h:
2873         (WebKit::TouchViewInterface::ViewportState::ViewportState):
2874         * UIProcess/qt/ViewInterface.h:
2875         * UIProcess/qt/qtouchwebpageproxy.cpp:
2876         (QTouchWebPageProxy::QTouchWebPageProxy):
2877         * UIProcess/qt/qtouchwebpageproxy.h:
2878
2879 2011-08-10  David Hyatt  <hyatt@apple.com>
2880
2881         https://bugs.webkit.org/show_bug.cgi?id=66004
2882
2883         Removing the CSS Regions and CSS Exclusions ifdefs.
2884
2885         Reviewed by Adam Roben.
2886
2887         * Configurations/FeatureDefines.xcconfig:
2888
2889 2011-08-10  Alexey Proskuryakov  <ap@apple.com>
2890
2891         Accidentally commented out an assertion in BackingStore::incorporateUpdate
2892         https://bugs.webkit.org/show_bug.cgi?id=65989
2893
2894         Reviewed by Anders Carlsson.
2895
2896         I couldn't get this assertion to fire in quick testing, let's bring it back.
2897
2898         * UIProcess/BackingStore.cpp: (WebKit::BackingStore::incorporateUpdate):
2899
2900 2011-08-10  Lars Knudsen  <lars.knudsen@nokia.com>
2901
2902         Add device specific settings to support viewport computing
2903         https://bugs.webkit.org/show_bug.cgi?id=65984
2904
2905         Reviewed by Kenneth Rohde Christiansen.
2906
2907         Expose new viewport related WebCore settings to WebKit2.
2908
2909         * Shared/WebPreferencesStore.h:
2910         * WebProcess/WebPage/WebPage.cpp:
2911         (WebKit::WebPage::updatePreferences):
2912
2913 2011-08-09  John Sullivan  <sullivan@apple.com>
2914
2915         WKPageCopyPendingAPIRequestURL returns stale result if policy decision set to Ignore
2916         https://bugs.webkit.org/show_bug.cgi?id=65950
2917         <rdar://problem/9925931>
2918
2919         Reviewed by Anders Carlsson.
2920
2921         * UIProcess/WebPageProxy.cpp:
2922         (WebKit::WebPageProxy::receivedPolicyDecision):
2923         Call clearPendingAPIRequestURL() if the policy decision is PolicyIgnore.
2924
2925 2011-08-09  Anders Carlsson  <andersca@apple.com>
2926
2927         Add a WebKit prefix to the user default.
2928
2929         Reviewed by Dan Bernstein.
2930
2931         * UIProcess/mac/WebContextMac.mm:
2932         (WebKit::WebContext::platformInitializeWebProcess):
2933
2934 2011-08-09  Anders Carlsson  <andersca@apple.com>
2935
2936         Add a user default to disable the plug-in process message timeout
2937         https://bugs.webkit.org/show_bug.cgi?id=65945
2938
2939         Reviewed by Adam Roben.
2940
2941         * Shared/WebProcessCreationParameters.cpp:
2942         (WebKit::WebProcessCreationParameters::encode):
2943         (WebKit::WebProcessCreationParameters::decode):
2944         * Shared/WebProcessCreationParameters.h:
2945         Add a disablePluginProcessMessageTimeout member variable.
2946
2947         * UIProcess/mac/WebContextMac.mm:
2948         (WebKit::WebContext::platformInitializeWebProcess):
2949         Initialize the disablePluginProcessMessageTimeout member variable from the 
2950         "DisablePluginProcessMessageTimeout" user default.
2951
2952         * WebProcess/Plugins/PluginProcessConnection.cpp:
2953         (WebKit::defaultSyncMessageTimeout):
2954         Return NoTimeout if WebProcess::disablePluginProcessMessageTimeout returns true.
2955
2956         * WebProcess/WebProcess.cpp:
2957         (WebKit::WebProcess::WebProcess):
2958         (WebKit::WebProcess::initializeWebProcess):
2959         Initialize m_disablePluginProcessMessageTimeout.
2960         
2961         * WebProcess/WebProcess.h:
2962         (WebKit::WebProcess::disablePluginProcessMessageTimeout):
2963         Add getter.
2964
2965 2011-08-09  Mark Hahnenberg  <mhahnenberg@apple.com>
2966
2967         Add ParentClass typedef in all JSC classes
2968         https://bugs.webkit.org/show_bug.cgi?id=65731
2969
2970         Reviewed by Oliver Hunt.
2971
2972         Just added the Base typedefs in all the classes that are a subclass of JSCell 
2973         to point at their parent classes.  This is a change to support future changes to the way
2974         constructors and destructors are implemented in JS objects, among other things.
2975
2976         * WebProcess/Plugins/Netscape/JSNPMethod.h:
2977         * WebProcess/Plugins/Netscape/JSNPObject.h:
2978
2979 2011-08-08  Adrienne Walker  <enne@google.com>
2980
2981         Add testing for --force-compositing-mode to windows.internal
2982         https://bugs.webkit.org/show_bug.cgi?id=65777
2983
2984         Reviewed by Adam Barth.
2985
2986         Add exports for Document::settings().
2987
2988         * win/WebKit2.def:
2989         * win/WebKit2CFLite.def:
2990
2991 2011-08-09  Kenneth Rohde Christiansen  <kenneth@webkit.org>
2992
2993         [Qt] Redirect didFindZoomableArea thru to the view
2994         https://bugs.webkit.org/show_bug.cgi?id=65913
2995
2996         Reviewed by Andreas Kling.
2997
2998         * UIProcess/API/qt/qdesktopwebview.cpp:
2999         (QDesktopWebViewPrivate::didFindZoomableArea):
3000         * UIProcess/API/qt/qdesktopwebview_p.h:
3001         * UIProcess/qt/QtWebPageProxy.cpp:
3002         (QtWebPageProxy::didFindZoomableArea):
3003         * UIProcess/qt/QtWebPageProxy.h:
3004         * UIProcess/qt/TouchViewInterface.cpp:
3005         (WebKit::TouchViewInterface::didFindZoomableArea):
3006         * UIProcess/qt/TouchViewInterface.h:
3007         * UIProcess/qt/ViewInterface.h:
3008         * UIProcess/qt/qdesktopwebpageproxy.cpp:
3009         (QDesktopWebPageProxy::timerEvent):
3010         * UIProcess/qt/qdesktopwebpageproxy.h:
3011         * UIProcess/qt/qtouchwebpageproxy.cpp:
3012         (QTouchWebPageProxy::setContentsScale):
3013         * UIProcess/qt/qtouchwebpageproxy.h:
3014
3015 2011-08-09  Kenneth Rohde Christiansen  <kenneth@webkit.org>
3016
3017         [Qt] Vastly improve the algorithm for finding a zoomable area when doing double-tap
3018         https://bugs.webkit.org/show_bug.cgi?id=65907
3019
3020         Reviewed by Andreas Kling.
3021
3022         This is upstreaming of the algorithm we are currently using on the N9 browser
3023         and this also fixes a bug with not considering the frame positions when finding
3024         a zoomable area.
3025
3026         * UIProcess/PageClient.h:
3027         * UIProcess/WebPageProxy.cpp:
3028         (WebKit::WebPageProxy::didFindZoomableArea):
3029         * UIProcess/WebPageProxy.h:
3030         * UIProcess/WebPageProxy.messages.in:
3031         * UIProcess/qt/qdesktopwebpageproxy.cpp:
3032         (QDesktopWebPageProxy::didFindZoomableArea):
3033         * UIProcess/qt/qdesktopwebpageproxy.h:
3034         * UIProcess/qt/qtouchwebpageproxy.cpp:
3035         (QTouchWebPageProxy::didFindZoomableArea):
3036         * UIProcess/qt/qtouchwebpageproxy.h:
3037         * WebProcess/WebPage/WebPage.cpp:
3038         (WebKit::WebPage::findZoomableAreaForPoint):
3039
3040 2011-08-08  Chris Marrin  <cmarrin@apple.com>
3041
3042         Logic to compute visible display rect in GraphicsLayerCA::syncCompositingState
3043         https://bugs.webkit.org/show_bug.cgi?id=65708
3044
3045         Supply initial display rects for the full-screen case
3046
3047         Reviewed by Simon Fraser.
3048
3049         * WebProcess/FullScreen/mac/WebFullScreenManagerMac.mm:
3050         (WebKit::WebFullScreenManagerMac::setRootFullScreenLayer):
3051         (WebKit::WebFullScreenManagerMac::beginEnterFullScreenAnimation):
3052         (WebKit::WebFullScreenManagerMac::beginExitFullScreenAnimation):
3053
3054 2011-08-08  Dan Bernstein  <mitz@apple.com>
3055
3056         <rdar://problem/9652350> REGRESSION (r87755): WKView doesn't update when I drag files into a background Safari window
3057         https://bugs.webkit.org/show_bug.cgi?id=65860
3058
3059         Reviewed by Simon Fraser.
3060
3061         When layer flush scheduling is re-enabled, schedule a layer flush, just in case one was requested while
3062         scheduling was disabled. It doesn’t seem worthwhile to track whether that in fact happened, so do so
3063         unconditionally.
3064
3065         * WebProcess/WebPage/ca/mac/LayerTreeHostCAMac.mm:
3066         (WebKit::LayerTreeHostCAMac::setLayerFlushSchedulingEnabled):
3067         * WebProcess/WebPage/ca/win/LayerTreeHostCAWin.cpp:
3068         (WebKit::LayerTreeHostCAWin::setLayerFlushSchedulingEnabled):
3069
3070 2011-08-05  Pavel Feldman  <pfeldman@chromium.org>
3071
3072         Web Inspector: implement dock/undock in WebKit2 without getting into WebCore.
3073         https://bugs.webkit.org/show_bug.cgi?id=65763
3074
3075         InspectorFrontendClient.h can't have synchronous canAttachWindow() returning value
3076         since in the multiprocess environment, you can't immediately get back to it from the host.
3077
3078         r92384 introduced an unhealthy WebKit -> WebCore -> WebKit canAttach query where embedder
3079         was asking itself a question. This loop was fixed.
3080
3081         Reviewed by Yury Semikhatsky.
3082
3083         * UIProcess/WebInspectorProxy.cpp:
3084         (WebKit::WebInspectorProxy::attach):
3085         (WebKit::WebInspectorProxy::createInspectorPage):
3086         (WebKit::WebInspectorProxy::didLoadInspectorPage):
3087         (WebKit::WebInspectorProxy::shouldOpenAttached):
3088         * UIProcess/WebInspectorProxy.h:
3089         * UIProcess/WebInspectorProxy.messages.in:
3090         * UIProcess/efl/WebInspectorEfl.cpp:
3091         (WebKit::WebInspectorProxy::platformInspectedWindowHeight):
3092         * UIProcess/gtk/WebInspectorGtk.cpp:
3093         (WebKit::WebInspectorProxy::platformInspectedWindowHeight):
3094         * UIProcess/mac/WebInspectorProxyMac.mm:
3095         (WebKit::WebInspectorProxy::platformOpen):
3096         (WebKit::WebInspectorProxy::platformInspectedWindowHeight):
3097         * UIProcess/qt/WebInspectorProxyQt.cpp:
3098         (WebKit::WebInspectorProxy::platformOpen):
3099         (WebKit::WebInspectorProxy::platformInspectedWindowHeight):
3100         * UIProcess/win/WebInspectorProxyWin.cpp:
3101         (WebKit::WebInspectorProxy::platformOpen):
3102         (WebKit::WebInspectorProxy::platformInspectedWindowHeight):
3103         * WebProcess/WebPage/WebInspector.cpp:
3104         (WebKit::WebInspector::didLoadInspectorPage):
3105         * WebProcess/WebPage/WebInspector.h:
3106         * WebProcess/WebPage/WebInspector.messages.in:
3107
3108 2011-08-07  Joseph Pecoraro  <joepeck@webkit.org>
3109
3110         [QT] Possible Leaks WKRetainPtr<> should Adopt allocated Copy
3111         https://bugs.webkit.org/show_bug.cgi?id=65790
3112
3113         Reviewed by Sam Weinig.
3114
3115         Fix a leak by adopting an allocation instead of retaining it.
3116
3117         * UIProcess/qt/qwkhistory.cpp:
3118         (QWKHistoryItem::title):
3119         (QWKHistoryItem::url):
3120
3121 2011-08-06  Mark Rowe  <mrowe@apple.com>
3122
3123         Fix a memory leak found via code inspection.
3124
3125         Rubber-stamped by Dan Bernstein.
3126
3127         * WebProcess/Downloads/mac/DownloadMac.mm:
3128         (WebKit::setOriginalURLForDownload): Adopt the newly-allocated NSURL instance
3129         so that it does not leak.
3130
3131 2011-08-06  Aron Rosenberg  <arosenberg@logitech.com>
3132
3133         Reviewed by Benjamin Poulain.
3134
3135         [Qt] Fix build with Intel compiler on Windows
3136         https://bugs.webkit.org/show_bug.cgi?id=65088
3137
3138         Intel compiler needs .lib suffixes instead of .a
3139
3140         * WebKit2.pri:
3141
3142 2011-08-05  Darin Adler  <darin@apple.com>
3143
3144         Reviewed by Anders Carlsson.
3145
3146         [WebKit2] Fix code paths that can leave frame view paint behavior in the wrong state
3147         https://bugs.webkit.org/show_bug.cgi?id=63779
3148
3149         * WebProcess/Plugins/PluginView.cpp:
3150         (WebKit::PluginView::handleEvent): Unrelated cleanup. Removed unneeded local variable.
3151
3152         * WebProcess/WebPage/WebPage.cpp:
3153         (WebKit::WebPage::snapshotInViewCoordinates): Rearranged code so that the call to
3154         setPaintBehavior is after the early exit. Also got rid of unneeded save/restore since
3155         the function uses a graphics context that it then throws away.
3156         (WebKit::WebPage::scaledSnapshotInDocumentCoordinates): Ditto.
3157
3158 2011-08-04  Mark Rowe  <mrowe@apple.com>
3159
3160         Future-proof Xcode configuration settings.
3161
3162         * Configurations/Base.xcconfig:
3163         * Configurations/CompilerVersion.xcconfig:
3164         * Configurations/DebugRelease.xcconfig:
3165         * Configurations/Version.xcconfig:
3166         * Configurations/WebKit2.xcconfig:
3167
3168 2011-08-01  Brian Weinstein  <bweinstein@apple.com>
3169
3170         WebKit2: Web Inspector always starts in undocked mode
3171         https://bugs.webkit.org/show_bug.cgi?id=65493
3172         <rdar://problem/9353114>
3173         
3174         Reviewed by Adam Roben.
3175         
3176         When opening the inspector, the web process tells the UI process that the inspector page has loaded,
3177         but now will pass another bit of data, whether the inspector can start attached, so the UI process
3178         doesn't need to ask the web process to do another calculation on whether or not it can be attached.
3179         
3180         If the user prefers the inspector to start docked (this defaults to true), and there is room for the
3181         window, we send a message to the web process to try and attach the inspector. This makes sure that the
3182         inspector knows it is docked (in the web process).
3183         
3184         * UIProcess/WebInspectorProxy.cpp:
3185         (WebKit::WebInspectorProxy::attach): Update the user's docked/undocked preference if the inspector is visible
3186             when it was attached.
3187         (WebKit::WebInspectorProxy::detach): Ditto (but when it was detached).
3188         (WebKit::WebInspectorProxy::didLoadInspectorPage): If we can start docked, and the user prefers to start docked,
3189             then request the inspector be attached to the window.
3190         * UIProcess/WebInspectorProxy.h:
3191
3192         * UIProcess/mac/WebInspectorProxyMac.mm:
3193         (WebKit::WebInspectorProxy::platformOpen): Only show the window if we are going to start undocked.
3194         * UIProcess/win/WebInspectorProxyWin.cpp:
3195         (WebKit::WebInspectorProxy::platformOpen): Ditto.
3196
3197         * WebProcess/WebPage/WebInspector.cpp:
3198         (WebKit::WebInspector::didLoadInspectorPage): Pass whether or not we can attach the window.
3199         (WebKit::WebInspector::requestAttachWindow): Call through to the InspectorController to attach the inspector.
3200         (WebKit::WebInspector::canAttachWindow): Ask the InspectorController if we can attach the inspector.
3201         * WebProcess/WebPage/WebInspector.h:
3202
3203         * Shared/WebPreferencesStore.h: Add a new preference for whether or not the inspector should
3204             start attached.
3205
3206         * UIProcess/WebInspectorProxy.messages.in: When the inspector page is loaded, tell the UI Process whether
3207             we can attach the inspector without needing another message.
3208         * WebProcess/WebPage/WebInspector.messages.in: Add a new message for RequestAttachWindow
3209
3210 2011-08-02  Jocelyn Turcotte  <jocelyn.turcotte@nokia.com>
3211
3212         [Qt][WK2] Create scene graph nodes for tiles in QTouchWebView instead of using imperative painting.
3213         https://bugs.webkit.org/show_bug.cgi?id=65528
3214
3215         Reviewed by Benjamin Poulain.
3216
3217         Converts QTouchWebPage from QSGPaintedItem to a straight QSGItem.
3218         - A SGTileNode is created and added to the scene graph for each tile,
3219           positioning them relatively to the page.
3220           It's basically a QSGSimpleTextureNode with support for specifying a
3221           source rect plus for owning the QSGTexture for proper destruction on
3222           shutdown by the rendering thread.
3223         - Scale nodes are used as parent of tile nodes to revert the scaling set on the
3224           QTouchWebPage and allow us to keep using integer coordinates.
3225         - The SGAgent class is introduced to carry scene graph update request up to the
3226           updatePaintNode call of the item, which may be on the scene graph rendering thread.
3227
3228         * UIProcess/API/qt/qtouchwebpage.cpp:
3229         (QTouchWebPage::QTouchWebPage):
3230         (QTouchWebPage::updatePaintNode):
3231         Delegate scene graph updates to the SGAgent which received update requests from the tiled drawing area.
3232         (QTouchWebPage::event):
3233         (QTouchWebPage::geometryChanged):
3234         (QTouchWebPagePrivate::QTouchWebPagePrivate):
3235         * UIProcess/API/qt/qtouchwebpage.h:
3236         * UIProcess/API/qt/qtouchwebpage_p.h:
3237         * UIProcess/TiledDrawingAreaProxy.cpp:
3238         Manage the scale node in the TileSet, it will be the parent node of Tile nodes.
3239         (WebKit::TiledDrawingAreaTileSet::sgNodeID):
3240         (WebKit::TiledDrawingAreaTileSet::TiledDrawingAreaTileSet):
3241         (WebKit::TiledDrawingAreaTileSet::~TiledDrawingAreaTileSet):
3242         (WebKit::TiledDrawingAreaProxy::TiledDrawingAreaProxy):
3243         (WebKit::TiledDrawingAreaProxy::setContentsScale):
3244         (WebKit::TiledDrawingAreaProxy::createTiles):
3245         (WebKit::TiledDrawingAreaProxy::removeAllTiles):
3246         * UIProcess/TiledDrawingAreaTile.h:
3247         (WebKit::TiledDrawingAreaTile::create):
3248         * UIProcess/qt/SGAgent.cpp: Added.
3249         * UIProcess/qt/SGAgent.h: Added.
3250         * UIProcess/qt/SGTileNode.cpp: Added.
3251         * UIProcess/qt/SGTileNode.h: Added.
3252         * UIProcess/qt/TiledDrawingAreaProxyQt.cpp:
3253         Disable the paint call and update the scene graph on incorporateUpdate through the SGAgent.
3254         (WebKit::TiledDrawingAreaProxy::updateWebView):
3255         * UIProcess/qt/TiledDrawingAreaTileQt.cpp:
3256         (WebKit::TiledDrawingAreaTile::TiledDrawingAreaTile):
3257         (WebKit::TiledDrawingAreaTile::~TiledDrawingAreaTile):
3258         (WebKit::TiledDrawingAreaTile::isReadyToPaint):
3259         (WebKit::TiledDrawingAreaTile::swapBackBufferToFront):
3260         (WebKit::TiledDrawingAreaTile::paint):
3261         (WebKit::TiledDrawingAreaTile::incorporateUpdate):
3262         (WebKit::TiledDrawingAreaTile::disableUpdates):
3263         (WebKit::TiledDrawingAreaTile::setParentNodeID):
3264         * UIProcess/qt/TouchViewInterface.cpp:
3265         (WebKit::TouchViewInterface::sceneGraphAgent):
3266         (WebKit::TouchViewInterface::setViewNeedsDisplay):
3267         * UIProcess/qt/TouchViewInterface.h:
3268         * WebKit2.pro:
3269
3270 2011-08-04  Alexis Menard  <alexis.menard@openbossa.org>
3271
3272         [Qt] Make navigation actions properly usable in QML.
3273         https://bugs.webkit.org/show_bug.cgi?id=65624
3274
3275         Add a new class that is exposed in QML to control the navigation
3276         like reload/stop/back/forward. Enums are not very QML friendly,
3277         it not possible to use enums that are not declared in the same class
3278         than the object exposed in QML, therefore it makes hard the sharing
3279         between the desktop and the touch views. In addition namespaced enums are
3280         even harder to support in QML. QWebNavigationController is
3281         not really meant to be used in C++ but it is exported for convenience
3282         reason (tests and MiniBrowser) so its API is not meant to be public but
3283         exposed in QML through properties and convenience slots. The QML code to use
3284         the navigation action in QML will look like "desktopView.navigation.reload();"
3285         or "if (desktopView.navigation.reloadAction.enabled) ...".
3286
3287         Reviewed by Benjamin Poulain.
3288
3289         * UIProcess/API/qt/WKView.h: To get the forward header generated
3290         * UIProcess/API/qt/qdesktopwebview.cpp:
3291         (QDesktopWebViewPrivate::QDesktopWebViewPrivate):
3292         (QDesktopWebView::navigationController):
3293         * UIProcess/API/qt/qdesktopwebview.h:
3294         * UIProcess/API/qt/qdesktopwebview_p.h:
3295         * UIProcess/API/qt/qmlplugin/plugin.cpp:
3296         (WebKit2QmlPlugin::registerTypes):
3297         * UIProcess/API/qt/qtouchwebpage.cpp:
3298         (QTouchWebPage::navigationController):
3299         (QTouchWebPagePrivate::QTouchWebPagePrivate):
3300         * UIProcess/API/qt/qtouchwebpage.h:
3301         * UIProcess/API/qt/qtouchwebpage_p.h:
3302         * UIProcess/API/qt/qwebnavigationcontroller.cpp: Added.
3303         (QWebNavigationControllerPrivate::QWebNavigationControllerPrivate):
3304         (QWebNavigationController::QWebNavigationController):
3305         (QWebNavigationController::~QWebNavigationController):
3306         (QWebNavigationController::backAction):
3307         (QWebNavigationController::forwardAction):
3308         (QWebNavigationController::stopAction):
3309         (QWebNavigationController::reloadAction):
3310         (QWebNavigationController::navigationAction):
3311         (QWebNavigationController::back):
3312         (QWebNavigationController::forward):
3313         (QWebNavigationController::stop):
3314         (QWebNavigationController::reload):
3315         * UIProcess/API/qt/qwebnavigationcontroller.h: Added.
3316         * UIProcess/API/qt/tests/commonviewtests/webviewabstraction.cpp:
3317         (WebViewAbstraction::triggerNavigationAction):
3318         * UIProcess/API/qt/tests/qdesktopwebview/tst_qdesktopwebview.cpp:
3319         (tst_QDesktopWebView::navigationActionsStatusAtStartup):
3320         (LoadStartedCatcher::onLoadStarted):
3321         (tst_QDesktopWebView::stopActionEnabledAfterLoadStarted):
3322         * UIProcess/API/qt/tests/qtouchwebview/tst_qtouchwebview.cpp:
3323         (tst_QTouchWebView::navigationActionsStatusAtStartup):
3324         * WebKit2API.pri:
3325
3326 2011-08-03  Jeff Miller  <jeffm@apple.com>
3327
3328         Use of AVFoundation should default to off on Windows
3329         https://bugs.webkit.org/show_bug.cgi?id=65660
3330
3331         Reviewed by Darin Adler.
3332
3333         * Shared/WebPreferencesStore.h: Change default value for AVFoundationEnabled to false on Windows, it's still true on other platforms.
3334
3335 2011-08-03  Mark Rowe  <mrowe@apple.com>
3336
3337         Bring some order to FeatureDefines.xcconfig to make it easier to follow.
3338
3339         Reviewed by Sam Weinig.
3340
3341         * Configurations/FeatureDefines.xcconfig:
3342
3343 2011-08-03  Mark Rowe  <mrowe@apple.com>
3344
3345         Clean up FeatureDefines.xcconfig to remove some unnecessary conditional settings
3346
3347         Reviewed by Dave Kilzer.
3348
3349         * Configurations/FeatureDefines.xcconfig:
3350
3351 2011-08-03  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>
3352
3353         [Qt] [WK2] Improve position of context menu for QDesktopWebView
3354         https://bugs.webkit.org/show_bug.cgi?id=65635
3355
3356         Reviewed by Andreas Kling.
3357
3358         Do not assume that the QDesktopWebView takes the entire canvas when
3359         positioning the context menu.
3360
3361         * UIProcess/API/qt/qdesktopwebview.cpp:
3362         (QDesktopWebViewPrivate::showContextMenu):
3363
3364 2011-08-03  Anders Carlsson  <andersca@apple.com>
3365
3366         Fix API tests.
3367
3368         Initialize threading before trying to allocate the WebContext.
3369
3370         * UIProcess/WebContext.cpp:
3371         (WebKit::WebContext::sharedProcessContext):
3372         (WebKit::WebContext::create):
3373
3374 2011-08-03  Pavel Feldman  <pfeldman@google.com>
3375
3376         Web Inspector: [Timeline] Hover on paint events and see rect outline around that area.
3377         https://bugs.webkit.org/show_bug.cgi?id=65510
3378
3379         Reviewed by Yury Semikhatsky.
3380
3381         * WebProcess/WebCoreSupport/WebInspectorClient.cpp:
3382         (WebKit::WebInspectorClient::drawRect):
3383
3384 2011-08-02  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>
3385
3386         [Qt] [WK2] Expose web view classes to QML
3387         https://bugs.webkit.org/show_bug.cgi?id=65339
3388
3389         Reviewed by Benjamin Poulain.
3390
3391         This patch also uses QuickTest from QtDeclarative to provide the basic autotest
3392         infrastructure for the exposed elements.
3393
3394         * UIProcess/API/qt/qmlplugin/plugin.cpp: Added.
3395         (WebKit2QmlPlugin::registerTypes):
3396         * UIProcess/API/qt/qmlplugin/qmldir: Added.
3397         * UIProcess/API/qt/qmlplugin/qmlplugin.pro: Added.
3398         * UIProcess/API/qt/qtouchwebpage.h: Expose load() to QML environment.
3399         * UIProcess/API/qt/qtouchwebview.h: Since QTouchWebPage* doesn't change once set
3400         in the constructor, we mark the page property as CONSTANT. This avoid QML
3401         warnings for not having a NOTIFY signal for the property change.
3402
3403         * UIProcess/API/qt/tests/tests.pro:
3404         * UIProcess/API/qt/tests/qmltests/DesktopWebView/tst_properties.qml: Added.
3405         * UIProcess/API/qt/tests/qmltests/TouchWebView/tst_properties.qml: Added.
3406         * UIProcess/API/qt/tests/qmltests/common/test1.html: Added.
3407         * UIProcess/API/qt/tests/qmltests/qmltests.pro: Added.
3408         * UIProcess/API/qt/tests/qmltests/tst_qmltests.cpp: Added.
3409
3410 2011-08-03  Carlos Garcia Campos  <cgarcia@igalia.com>
3411
3412         [GTK] Install web and plugin processes in libexecdir instead of bindir
3413         https://bugs.webkit.org/show_bug.cgi?id=65600
3414
3415         Reviewed by Martin Robinson.
3416
3417         Launch processes from libexecdir or WEBKIT_EXEC_PATH
3418         environment variable when it's set. This variable will be used by
3419         MiniBrowser and unit tests to find processes without having to
3420         install them.
3421
3422         * GNUmakefile.am:
3423         * UIProcess/Launcher/gtk/ProcessLauncherGtk.cpp:
3424         (WebKit::ProcessLauncher::launchProcess):
3425
3426 2011-08-03  Pavel Feldman  <pfeldman@chromium.org>
3427
3428         Web Inspector: remove Node parameter from the InspectorClient::highlight
3429         https://bugs.webkit.org/show_bug.cgi?id=65549
3430
3431         Reviewed by Yury Semikhatsky.
3432
3433         * WebProcess/WebCoreSupport/WebInspectorClient.cpp:
3434         (WebKit::WebInspectorClient::highlight):
3435         * WebProcess/WebCoreSupport/WebInspectorClient.h:
3436
3437 2011-08-03  Carlos Garcia Campos  <cgarcia@igalia.com>
3438
3439         [GTK] Reorganize pkg-config files
3440         https://bugs.webkit.org/show_bug.cgi?id=65548
3441
3442         Reviewed by Martin Robinson.
3443
3444         * GNUmakefile.am: Rename pc file as webkit2gtk.pc.in. WebKit2
3445         depends on gtk3 unconditionally so we don't need to use
3446         WEBKITGTK_PC_NAME.
3447         * webkit2gtk.pc.in: Renamed from Source/WebKit2/gtk/webkit2.pc.in.
3448
3449 2011-08-01  Michael Saboff  <msaboff@apple.com>
3450
3451         Virtual copying of FastMalloc allocated memory causes madvise MADV_FREE_REUSABLE errors
3452         https://bugs.webkit.org/show_bug.cgi?id=65502
3453
3454         Reviewed by Anders Carlsson.
3455
3456         Changed OOL message to use MACH_MSG_PHYSICAL_COPY flag instead of virtual flag
3457         so that the original memory region isn't referenced by the message and ultimately
3458         the receiving process.  The additional reference caused madvise(MADV_FREE_REUSABLE)
3459         to fail when it encountered such pages.
3460
3461         * Platform/CoreIPC/mac/ConnectionMac.cpp:
3462         (CoreIPC::Connection::sendOutgoingMessage):
3463
3464 2011-07-29  Jocelyn Turcotte  <jocelyn.turcotte@nokia.com>
3465
3466         [Qt] Add QtWebProcess in PATH at runtime for WebKit2 API auto tests.
3467         https://bugs.webkit.org/show_bug.cgi?id=65378
3468
3469         Reviewed by Benjamin Poulain.
3470
3471         This prevent the runner of the tests from having to add it to PATH himself.
3472
3473         * UIProcess/API/qt/tests/commonviewtests/tst_commonviewtests.cpp:
3474         (tst_CommonViewTests::tst_CommonViewTests):
3475         * UIProcess/API/qt/tests/qdesktopwebview/tst_qdesktopwebview.cpp:
3476         (tst_QDesktopWebView::tst_QDesktopWebView):
3477         * UIProcess/API/qt/tests/qtouchwebview/tst_qtouchwebview.cpp:
3478         (tst_QTouchWebView::tst_QTouchWebView):
3479         * UIProcess/API/qt/tests/tests.pri:
3480         * UIProcess/API/qt/tests/util.cpp: Copied from Source/WebKit2/UIProcess/API/qt/tests/util.h.
3481         Move definitions to a cpp file to prevent unused static symbol warnings.
3482         (addQtWebProcessToPath):
3483         (waitForSignal):
3484         * UIProcess/API/qt/tests/util.h:
3485
3486 2011-07-12  Jocelyn Turcotte  <jocelyn.turcotte@nokia.com>
3487
3488         TiledDrawingArea: Handle update requests in the order they were received.
3489         https://bugs.webkit.org/show_bug.cgi?id=64365
3490
3491         Reviewed by Andreas Kling.
3492
3493         TiledDrawingAreaProxy::createTiles() uses the distance of tiles to the
3494         center of the viewport to decide which tile should be rendered first.
3495         This logic is useless if the requests are not handled in the same order
3496         as they were received.
3497         Now use a list instead of a map to hold pending tile update requests.
3498
3499         * WebProcess/WebPage/TiledDrawingArea.cpp:
3500         (WebKit::TiledDrawingArea::tileUpdateTimerFired):
3501         (WebKit::TiledDrawingArea::cancelTileUpdate):
3502         (WebKit::TiledDrawingArea::requestTileUpdate):
3503         * WebProcess/WebPage/TiledDrawingArea.h:
3504
3505 2011-08-02  Amruth Raj  <amruthraj@motorola.com>
3506
3507         Custom cursors cause the WebProcess to crash
3508         https://bugs.webkit.org/show_bug.cgi?id=64802
3509
3510         Reviewed by Martin Robinson.
3511
3512         * Shared/WebCoreArgumentCoders.cpp:
3513         (CoreIPC::::encode): In case of a NULL cursor image, encode a bool indicating that.
3514         (CoreIPC::::decode): Decode the image only if required.
3515
3516 2011-08-01  Scott Graham  <scottmg@chromium.org>
3517
3518         REGRESSION (r39725?): Resources removed from document can not be freed until the document is deleted
3519         https://bugs.webkit.org/show_bug.cgi?id=61006
3520
3521         Reviewed by Antti Koivisto.
3522
3523         Update exports for test harness.
3524
3525         * win/WebKit2.def:
3526         * win/WebKit2CFLite.def:
3527
3528 2011-08-01  Hayato Ito  <hayato@chromium.org>
3529
3530         Add support for getting an element in shadow root by its id into a window.internals object.
3531         https://bugs.webkit.org/show_bug.cgi?id=64587
3532
3533         Reviewed by Hajime Morita.
3534
3535         * win/WebKit2.def:
3536         * win/WebKit2CFLite.def:
3537
3538 2011-08-01  Sheriff Bot  <webkit.review.bot@gmail.com>
3539
3540         Unreviewed, rolling out r92108.
3541         http://trac.webkit.org/changeset/92108
3542         https://bugs.webkit.org/show_bug.cgi?id=65459
3543
3544         breaks SL compile (Requested by tonyg-cr on #webkit).
3545
3546         * Shared/WebCoreArgumentCoders.cpp:
3547         (CoreIPC::::encode):
3548         (CoreIPC::::decode):
3549
3550 2011-08-01  Amruth Raj  <amruthraj@motorola.com>
3551
3552         Custom cursors cause the WebProcess to crash
3553         https://bugs.webkit.org/show_bug.cgi?id=64802
3554
3555         Reviewed by Darin Adler.
3556
3557         * Shared/WebCoreArgumentCoders.cpp:
3558         (CoreIPC::::encode): In case of a NULL cursor image, encode a bool indicating that.
3559         (CoreIPC::::decode): Decode the image only if required.
3560
3561 2011-07-31  Daniel Bates  <dbates@webkit.org>
3562
3563         Try again to fix the WinCairo Debug build after r92059 ( https://bugs.webkit.org/show_bug.cgi?id=65419).
3564
3565         * win/WebKit2CFLite.def: Export symbols needed by Internals.
3566
3567 2011-07-30  Dan Bernstein  <mitz@apple.com>
3568
3569         Try to fix the Windows build after r92059.
3570
3571         * win/WebKit2.def: Export symbols needed by Internals.
3572
3573 2011-07-30  Patrick Gansterer  <paroga@webkit.org>
3574
3575         Remove inclusion of MainThread.h from Threading.h
3576         https://bugs.webkit.org/show_bug.cgi?id=65081
3577
3578         Reviewed by Darin Adler.
3579
3580         Add missing include statements for MainThread.
3581
3582         * PluginProcess/gtk/PluginProcessMainGtk.cpp:
3583         * PluginProcess/mac/PluginProcessMainMac.mm:
3584         * PluginProcess/qt/PluginProcessMainQt.cpp:
3585         * UIProcess/API/mac/WKPrintingView.mm:
3586         * UIProcess/Launcher/mac/ThreadLauncherMac.mm:
3587         * UIProcess/Launcher/qt/ThreadLauncherQt.cpp:
3588         * UIProcess/Launcher/win/ThreadLauncherWin.cpp:
3589         * UIProcess/WebContext.cpp:
3590         * WebProcess/WebPage/ca/win/LayerTreeHostCAWin.cpp:
3591         * WebProcess/efl/WebProcessMainEfl.cpp:
3592         * WebProcess/gtk/WebProcessMainGtk.cpp:
3593         * WebProcess/mac/KeychainItemShimMethods.mm:
3594         * WebProcess/mac/WebProcessMainMac.mm:
3595         * WebProcess/qt/WebProcessMainQt.cpp:
3596         * WebProcess/win/WebProcessMainWin.cpp:
3597
3598 2011-07-30  Balazs Kelemen  <kbalazs@webkit.org>
3599
3600         [Qt][WK2] Fix the build afer r92014
3601         https://bugs.webkit.org/show_bug.cgi?id=65410
3602
3603         Reviewed by Noam Rosenthal.
3604
3605         * Shared/ShareableBitmap.h:
3606         * UIProcess/qt/qdesktopwebpageproxy.cpp:
3607         (QDesktopWebPageProxy::paintContent):
3608
3609 2011-07-29  Sam Weinig  <sam@webkit.org>
3610
3611         Move Region code from WebKit2 to WebCore
3612         https://bugs.webkit.org/show_bug.cgi?id=65392
3613
3614         Reviewed by David Hyatt.
3615
3616         * CMakeLists.txt:
3617         * GNUmakefile.am:
3618         * WebKit2.pro:
3619         * WebKit2.xcodeproj/project.pbxproj:
3620         * win/WebKit2.vcproj:
3621         Update project files.
3622
3623         * Platform/Region.cpp: Removed.
3624         * Platform/Region.h: Removed.
3625         Remove Region files.
3626
3627         * UIProcess/API/gtk/WebKitWebViewBase.cpp:
3628         (webkitWebViewBaseDraw):
3629         * UIProcess/API/mac/WKView.mm:
3630         * UIProcess/DrawingAreaProxyImpl.cpp:
3631         * UIProcess/DrawingAreaProxyImpl.h:
3632         * UIProcess/qt/qdesktopwebpageproxy.cpp:
3633         * UIProcess/win/WebView.cpp:
3634         * WebProcess/WebPage/DrawingAreaImpl.h:
3635         Update for new namespace and include type.
3636
3637 2011-07-29  Anders Carlsson  <andersca@apple.com>
3638
3639         Pass the HTTP referrer header for URLs loaded by plug-ins
3640         https://bugs.webkit.org/show_bug.cgi?id=65379
3641         <rdar://problem/9822116>
3642
3643         Reviewed by Sam Weinig.
3644
3645         Set the HTTP referrer if necessary.
3646
3647         * WebProcess/Plugins/PluginView.cpp:
3648         (WebKit::PluginView::loadURL):
3649
3650 2011-07-29  Jocelyn Turcotte  <jocelyn.turcotte@nokia.com>
3651
3652         Fix the QTouchWebView in debug segfault on shutdown introduced in 91979.
3653         https://bugs.webkit.org/show_bug.cgi?id=64728
3654
3655         Reviewed by Benjamin Poulain.
3656
3657         unregisterTile is called in the tile's destructor, triggered in the TileSet's
3658         destruction, which happens in the middle of the proxy's destruction
3659         (after the m_tilesByID HashMap destruction).
3660         Detach the tiles in the proxy's destructor to make sure they can cleanup
3661         using a valid proxy.
3662
3663         * UIProcess/TiledDrawingAreaProxy.cpp:
3664         (WebKit::TiledDrawingAreaProxy::~TiledDrawingAreaProxy):
3665
3666 2011-07-29  Jocelyn Turcotte  <jocelyn.turcotte@nokia.com>
3667
3668         Fix the QTouchWebView in debug broke in 91979.
3669         https://bugs.webkit.org/show_bug.cgi?id=64728
3670
3671         Reviewed by Benjamin Poulain.
3672
3673         registerTile is called in the Tile's constructor, before adoptRef.
3674         Change the pointer parameter to use the raw type instead.
3675
3676         * UIProcess/TiledDrawingAreaProxy.cpp:
3677         (WebKit::TiledDrawingAreaProxy::registerTile):
3678         * UIProcess/TiledDrawingAreaProxy.h:
3679
3680 2011-07-29  Alexis Menard  <alexis.menard@openbossa.org>
3681
3682         [Qt] Make QDesktopWebView/QTouchWebView loadProgress property more usable in QML.
3683         https://bugs.webkit.org/show_bug.cgi?id=65315
3684
3685         Reviewed by Benjamin Poulain.
3686
3687         In order to use the loadProgress value in QML we need to make it
3688         a Q_PROPERTY, therefore we need a getter to get it.
3689
3690         * UIProcess/API/qt/qdesktopwebview.cpp:
3691         (QDesktopWebViewPrivate::didChangeLoadProgress):
3692         (QDesktopWebView::url):
3693         (QDesktopWebView::loadProgress):
3694         * UIProcess/API/qt/qdesktopwebview.h:
3695         * UIProcess/API/qt/qtouchwebpage.cpp:
3696         (QTouchWebPage::loadProgress):
3697         * UIProcess/API/qt/qtouchwebpage.h:
3698         * UIProcess/API/qt/tests/commonviewtests/tst_commonviewtests.cpp:
3699         (tst_CommonViewTests::stop):
3700         (tst_CommonViewTests::loadProgress):
3701         * UIProcess/API/qt/tests/commonviewtests/webviewabstraction.cpp:
3702         (WebViewAbstraction::WebViewAbstraction):
3703         (WebViewAbstraction::loadProgress):
3704         (WebViewAbstraction::desktopViewLoadFailed):
3705         (WebViewAbstraction::touchViewLoadProgressChanged):
3706         (WebViewAbstraction::desktopViewLoadProgressChanged):
3707         * UIProcess/API/qt/tests/commonviewtests/webviewabstraction.h:
3708         * UIProcess/qt/QtWebPageProxy.cpp:
3709         (QtWebPageProxy::QtWebPageProxy):
3710         (QtWebPageProxy::didChangeLoadProgress):
3711         * UIProcess/qt/QtWebPageProxy.h:
3712         (QtWebPageProxy::loadProgress):
3713         * UIProcess/qt/TouchViewInterface.cpp:
3714         (WebKit::TouchViewInterface::didChangeLoadProgress):
3715
3716 2011-07-27  Jocelyn Turcotte  <jocelyn.turcotte@nokia.com>
3717
3718         TiledDrawingArea: Use tile sets to paint old content while rendering for a new scale.
3719         https://bugs.webkit.org/show_bug.cgi?id=64728
3720
3721         Reviewed by Benjamin Poulain.
3722
3723         We currently delete all the tiles when setContentsScale is called. This shows a blank
3724         background to the user while the web process render tiles for the new scale.
3725
3726         This patch extracts the ownership of individual tiles from TiledDrawingAreaProxy to
3727         TiledDrawingAreaTileSet to allow the proxy to paint tiles with different scales.
3728         We can then paint the tiles we already have on top of the tiles we are rendering for
3729         the new scale until enough content is available.
3730
3731         * UIProcess/TiledDrawingAreaProxy.cpp:
3732         (WebKit::TiledDrawingAreaTileSet::tiles):
3733         (WebKit::TiledDrawingAreaTileSet::contentsScale):
3734         (WebKit::TiledDrawingAreaTileSet::TiledDrawingAreaTileSet):
3735         (WebKit::TiledDrawingAreaTileSet::mapToContents):
3736         (WebKit::TiledDrawingAreaTileSet::mapFromContents):
3737         (WebKit::TiledDrawingAreaProxy::TiledDrawingAreaProxy):
3738         (WebKit::TiledDrawingAreaProxy::registerTile):
3739         (WebKit::TiledDrawingAreaProxy::unregisterTile):
3740         Added those two methods to allow the tiles to clean
3741         themselves on destruction.
3742         (WebKit::TiledDrawingAreaProxy::requestTileUpdate):
3743         (WebKit::TiledDrawingAreaProxy::cancelTileUpdate):
3744         (WebKit::TiledDrawingAreaProxy::invalidate):
3745         (WebKit::TiledDrawingAreaProxy::updateTileBuffers):
3746         (WebKit::TiledDrawingAreaProxy::tileBufferUpdateComplete):
3747         (WebKit::TiledDrawingAreaProxy::paint):
3748         (WebKit::TiledDrawingAreaProxy::coverageRatio):
3749         (WebKit::TiledDrawingAreaProxy::setContentsScale):
3750         (WebKit::TiledDrawingAreaProxy::createTiles):
3751         (WebKit::TiledDrawingAreaProxy::resizeEdgeTiles):
3752         (WebKit::TiledDrawingAreaProxy::dropTilesOutsideRect):
3753         (WebKit::TiledDrawingAreaProxy::disableTileSetUpdates):
3754         (WebKit::TiledDrawingAreaProxy::removeAllTiles):
3755         (WebKit::TiledDrawingAreaProxy::contentsRect):
3756         (WebKit::TiledDrawingAreaProxy::visibleRect):
3757         (WebKit::TiledDrawingAreaProxy::hasPendingUpdates):
3758         * UIProcess/TiledDrawingAreaProxy.h:
3759         * UIProcess/TiledDrawingAreaTile.h:
3760         * UIProcess/qt/TiledDrawingAreaTileQt.cpp:
3761         (WebKit::TiledDrawingAreaTile::TiledDrawingAreaTile):
3762         (WebKit::TiledDrawingAreaTile::~TiledDrawingAreaTile):
3763         (WebKit::TiledDrawingAreaTile::incorporateUpdate):
3764         (WebKit::TiledDrawingAreaTile::disableUpdates):
3765         (WebKit::TiledDrawingAreaTile::updateBackBuffer):
3766
3767 2011-07-28  Tim Horton  <timothy_horton@apple.com>
3768
3769         REGRESSION (5.1): CJK input broken after clicking on Flash content
3770         <rdar://problem/9854447>
3771         https://bugs.webkit.org/show_bug.cgi?id=65349
3772
3773         Reviewed by Darin Adler.
3774
3775         After giving Flash focus on a page and then navigating away from that page
3776         using the back button, we were not getting notified to switch back to
3777         inline (non-complex) input. Now, notify the page that it can leave complex
3778         text mode when the plugin is destroyed.
3779
3780         * WebProcess/Plugins/PluginView.cpp:
3781         (WebKit::PluginView::~PluginView):
3782
3783 2011-07-28  Anders Carlsson  <andersca@apple.com>
3784
3785         Crash when trying to encode FontInfo with a null font attribute descriptor
3786         https://bugs.webkit.org/show_bug.cgi?id=65350
3787         <rdar://problem/9520670>
3788
3789         Reviewed by Darin Adler.
3790
3791         * Shared/FontInfo.cpp:
3792         (WebKit::FontInfo::encode):
3793         Encode a boolean specifying whether there's a fontAttributeDictionary member variable.
3794
3795         (WebKit::FontInfo::decode):
3796         Don't try to decode the fontAttributeDictionary member variable if none has been encoded.
3797
3798 2011-07-26  Chris Fleizach  <cfleizach@apple.com>
3799
3800         REGRESSION (Safari 5.1): JavaScript dialogs not usable with VoiceOver
3801         https://bugs.webkit.org/show_bug.cgi?id=65214
3802
3803         Reviewed by Anders Carlsson.
3804
3805         Allow the ability to spin the run loop while WebProcess is waiting for a synchronous reply.
3806         This allows it to continue to serve accessibility requests while waiting and basically
3807         restores the behavior WK1 was presenting. This patch only enables this mode when accessibility is on.
3808
3809         * Platform/CoreIPC/Connection.cpp:
3810         (CoreIPC::Connection::sendSyncMessage):
3811         (CoreIPC::Connection::waitForSyncReply):
3812         * Platform/CoreIPC/Connection.h:
3813         (CoreIPC::Connection::sendSync):
3814         * Platform/RunLoop.h:
3815         * Platform/mac/RunLoopMac.mm:
3816         (RunLoop::runForDuration):
3817         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
3818         (WebKit::WebChromeClient::runJavaScriptAlert):
3819         (WebKit::WebChromeClient::runJavaScriptConfirm):
3820         (WebKit::WebChromeClient::runJavaScriptPrompt):
3821
3822 2011-07-28  Ravi Phaneendra Kasibhatla  <ravi.kasibhatla@motorola.com>
3823
3824         Pass the key_press_event or key_release_event to parent widget when it is not handled by Web Process.
3825         (https://bugs.webkit.org/show_bug.cgi?id=64790)
3826
3827         Reviewed by Martin Robinson.
3828
3829         * Shared/NativeWebKeyboardEvent.h:
3830         (WebKit::NativeWebKeyboardEvent::nativeEvent): Return a GdkEvent* instead of const GdkEvent* (non-const).
3831         * UIProcess/API/gtk/PageClientImpl.cpp:
3832         (WebKit::PageClientImpl::doneWithKeyEvent): Implemented for GTK port. Sets flag if the keyboard event 
3833         needs to be passed to the parent widget. Invoke gtk_main_do_event() if event needs to be passed to parent.
3834         * UIProcess/API/gtk/PageClientImpl.h: Deleted obsolete functions didNotHandleKeyEvent & didNotHandleWheelEvent.
3835         * UIProcess/API/gtk/WebKitWebViewBase.cpp:
3836         (webkit_web_view_base_init): Initialize shouldForwardNextKeyEvent flag.
3837         (webkitWebViewBaseKeyPressEvent): Pass event to parent widget depending on status from doneWithKeyEvent. 
3838         (webkitWebViewBaseKeyReleaseEvent): Pass event to parent widget depending on status from doneWithKeyEvent.
3839         (webkitWebViewBaseForwardNextKeyEvent): API to set flag shouldForwardNextKeyEvent.
3840         * UIProcess/API/gtk/WebKitWebViewBasePrivate.h: Added API to set shouldForwardNextKeyEvent flag.
3841
3842 2011-07-28  Dan Bernstein  <mitz@apple.com>
3843
3844         <rdar://problem/9589433> Displaying Japanese dictionary contents in vertical orientation takes a couple of seconds
3845
3846         Reviewed by Darin Adler.
3847
3848         * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
3849         (InitWebCoreSystemInterface): Initialize wkGetVerticalGlyphsForCharacters.
3850
3851 2011-07-28  Brady Eidson  <beidson@apple.com>
3852
3853         <rdar://problem/9714337> and https://bugs.webkit.org/show_bug.cgi?id=65306
3854         WebKitInitializeStorageIfNecessary() can take awhile performing i/o, isn't necessary for every WebView
3855
3856         Reviewed by Maciej Stachowiak.
3857
3858         * WebProcess/WebProcess.cpp:
3859         (WebKit::WebProcess::initializeWebProcess): Pass a null client pointer in the new form of initializeTracker()
3860
3861 2011-07-27  Mark Hahnenberg  <mhahnenberg@apple.com>
3862
3863         Remove operator new from JSCell
3864         https://bugs.webkit.org/show_bug.cgi?id=64999
3865
3866         Reviewed by Oliver Hunt.
3867
3868         Removed the implementation of operator new in JSCell, so any further uses
3869         will not successfully link.  Also removed any remaining uses of operator new.
3870
3871         * WebProcess/Plugins/Netscape/JSNPMethod.h:
3872         (WebKit::JSNPMethod::create):
3873         * WebProcess/Plugins/Netscape/JSNPObject.cpp:
3874         (WebKit::JSNPObject::methodGetter):
3875         * WebProcess/Plugins/Netscape/JSNPObject.h:
3876         (WebKit::JSNPObject::create):
3877         * WebProcess/Plugins/Netscape/NPRuntimeObjectMap.cpp:
3878         (WebKit::NPRuntimeObjectMap::getOrCreateJSObject):
3879
3880 2011-07-27  Benjamin Poulain  <benjamin@webkit.org>
3881
3882         [WK2][Qt] Move from QGraphicsView to Qt Scene Graph
3883         https://bugs.webkit.org/show_bug.cgi?id=62969
3884
3885         Reviewed by Andreas Kling.
3886
3887         Co-authored with Simon Hausmann  <simon.hausmann@nokia.com>
3888
3889         This patch change the base of WebKit2 from QGraphicsWidget
3890         to scenegraph based items.
3891
3892         QTouchWebView becomes a QSGItem with the only role of clipping
3893         child items.
3894         QTouchWebPage becomes a QSGPaintedItem in order to render the content
3895         of the flattened page. This is a temporary work around to get
3896         something running without deep changes on the drawing area proxy.
3897
3898         QDesktopWebView become a QSGPaintedItem and behave as before
3899         regarding rendering. The drawing area proxy is used to render
3900         the full item.
3901
3902         The event delivery had to be adapted because the scenegraph does not
3903         follow regular delivery of QEvents. Instead, each event type is
3904         delivered directly to a specific virtual function.
3905         In this patch, the events are forwarded to the classic QObject::event().
3906
3907         For the features that cannot be implemented on scenegraph (tooltip, menus, etc),
3908         a temporary workaround was added: the parent canvas is used as the widget for
3909         providing the feature. This assumes the web views alone in the canvas and
3910         take its full size. This will have to be fixed in the scenegraph for us to
3911         implement those features.
3912
3913         * UIProcess/API/qt/qdesktopwebview.cpp:
3914         (QDesktopWebViewPrivate::drawingAreaSize):
3915         (QDesktopWebViewPrivate::isActive):
3916         (QDesktopWebViewPrivate::startDrag):
3917         (QDesktopWebViewPrivate::didChangeToolTip):
3918         (QDesktopWebViewPrivate::didChangeCursor):
3919         (QDesktopWebViewPrivate::showContextMenu):
3920         (QDesktopWebView::QDesktopWebView):
3921         (QDesktopWebView::init):
3922         (paintCrashedPage):
3923         (QDesktopWebView::keyPressEvent):
3924         (QDesktopWebView::keyReleaseEvent):
3925         (QDesktopWebView::inputMethodEvent):
3926         (QDesktopWebView::focusInEvent):
3927         (QDesktopWebView::focusOutEvent):
3928         (QDesktopWebView::mousePressEvent):
3929         (QDesktopWebView::mouseMoveEvent):
3930         (QDesktopWebView::mouseReleaseEvent):
3931         (QDesktopWebView::mouseDoubleClickEvent):
3932         (QDesktopWebView::wheelEvent):
3933         (QDesktopWebView::touchEvent):
3934         (QDesktopWebView::hoverEnterEvent):
3935         (QDesktopWebView::hoverMoveEvent):
3936         (QDesktopWebView::hoverLeaveEvent):
3937         (QDesktopWebView::dragMoveEvent):
3938         (QDesktopWebView::dragEnterEvent):
3939         (QDesktopWebView::dragExitEvent):
3940         (QDesktopWebView::dragDropEvent):
3941         (QDesktopWebView::geometryChanged):
3942         (QDesktopWebView::paint):
3943         (QDesktopWebView::event):
3944         * UIProcess/API/qt/qdesktopwebview.h:
3945         * UIProcess/API/qt/qtouchwebpage.cpp:
3946         (QTouchWebPage::QTouchWebPage):
3947         (QTouchWebPage::paint):
3948         (QTouchWebPage::event):
3949         (QTouchWebPage::keyPressEvent):
3950         (QTouchWebPage::keyReleaseEvent):
3951         (QTouchWebPage::inputMethodEvent):
3952         (QTouchWebPage::focusInEvent):
3953         (QTouchWebPage::focusOutEvent):
3954         (QTouchWebPage::touchEvent):
3955         (QTouchWebPage::geometryChanged):
3956         * UIProcess/API/qt/qtouchwebpage.h:
3957         * UIProcess/API/qt/qtouchwebview.cpp:
3958         (QTouchWebViewPrivate::scroll):
3959         (QTouchWebView::QTouchWebView):
3960         (QTouchWebView::geometryChanged):
3961         * UIProcess/API/qt/qtouchwebview.h:
3962         * UIProcess/API/qt/tests/tests.pri:
3963         * UIProcess/API/qt/tests/testwindow.h:
3964         (TestWindow::TestWindow):
3965         (TestWindow::resizeEvent):
3966         * UIProcess/qt/TouchViewInterface.cpp:
3967         (WebKit::TouchViewInterface::panGestureRequestScroll):
3968         (WebKit::TouchViewInterface::pinchGestureRequestUpdate):
3969         (WebKit::TouchViewInterface::drawingAreaSize):
3970         (WebKit::TouchViewInterface::contentSizeChanged):
3971         (WebKit::TouchViewInterface::isActive):
3972         * UIProcess/qt/ViewInterface.cpp: Removed.
3973         * UIProcess/qt/ViewInterface.h:
3974         * WebKit2.pro:
3975
3976 2011-07-27  Benjamin Poulain  <benjamin@webkit.org>
3977
3978         [Qt][WK2] Clean WKPageLoaderClient
3979         https://bugs.webkit.org/show_bug.cgi?id=65246
3980
3981         Reviewed by Andreas Kling.
3982
3983         Remove the empty functions from Qt's WKPageLoaderClient.
3984
3985         * UIProcess/qt/ClientImpl.cpp:
3986         (qt_wk_didSameDocumentNavigationForFrame): Move the function to
3987         have all the implementations in the same order as the definitions.
3988         * UIProcess/qt/ClientImpl.h:
3989         * UIProcess/qt/QtWebPageProxy.cpp:
3990         (QtWebPageProxy::init):
3991
3992 2011-07-27  Caio Marcelo de Oliveira Filho  <caio.oliveira@openbossa.org>
3993
3994         Fix Qt (and possibly Gtk) WebKit2 build after addition of -webkit-pictograph
3995         https://bugs.webkit.org/show_bug.cgi?id=65253
3996
3997         Reviewed by Andreas Kling.
3998
3999         The -webkit-pictograph generic family was added by bug 65197.
4000
4001         * Shared/WebPreferencesStore.h:
4002
4003 2011-07-27  Benjamin Poulain  <benjamin@webkit.org>
4004
4005         [Qt][WK2] Simplify the PageUIClient
4006         https://bugs.webkit.org/show_bug.cgi?id=65198
4007
4008         Reviewed by Andreas Kling.
4009
4010         The only function of WKPageLoaderClient with a complete implementation
4011         is qt_wk_setStatusText(). The other functions were what is left from
4012         before the refactoring of QWKPage.
4013
4014         This patch removes the unused functions to simplify the client. Since the dependency
4015         on QtWebPageProxy is removed from that client, it now calls the ViewInterface directly.
4016
4017         * UIProcess/qt/ClientImpl.cpp:
4018         (toViewInterface):
4019         (qt_wk_setStatusText):
4020         * UIProcess/qt/ClientImpl.h:
4021         * UIProcess/qt/QtWebPageProxy.cpp:
4022         (QtWebPageProxy::QtWebPageProxy):
4023         (QtWebPageProxy::init):
4024         * UIProcess/qt/QtWebPageProxy.h:
4025
4026 2011-07-26  Sadrul Habib Chowdhury  <sadrul@chromium.org>
4027
4028         Add support for download='filename' attribute in anchors.
4029         https://bugs.webkit.org/show_bug.cgi?id=64580
4030
4031         Reviewed by Adam Barth.
4032
4033         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
4034         (WebKit::WebFrameLoaderClient::startDownload):
4035         * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
4036
4037 2011-07-26  Tim Horton  <timothy_horton@apple.com>
4038
4039         Apply r40940 to WebKit2 to work around a Silverlight crash.
4040         https://bugs.webkit.org/show_bug.cgi?id=65205
4041         <rdar://problem/9058370>
4042
4043         Reviewed by Anders Carlsson.
4044
4045         * Shared/Plugins/Netscape/mac/NetscapePluginModuleMac.mm:
4046         (WebKit::NetscapePluginModule::determineQuirks):
4047         * Shared/Plugins/PluginQuirks.h:
4048         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
4049         (WebKit::NetscapePlugin::userAgent):
4050
4051 2011-07-26  Dan Bernstein  <mitz@apple.com>
4052
4053         <rdar://problem/9842889> Add a generic pictograph font family
4054         https://bugs.webkit.org/show_bug.cgi?id=65197
4055
4056         Reviewed by Anders Carlsson.
4057
4058         * Shared/WebPreferencesStore.h:
4059         * UIProcess/API/C/WKPreferences.cpp:
4060         (WKPreferencesSetPictographFontFamily): Added.
4061         (WKPreferencesCopyPictographFontFamily): Added.
4062         * UIProcess/API/C/WKPreferences.h:
4063
4064 2011-07-26  Andras Becsi  <abecsi@webkit.org>
4065
4066         [Qt] [WK2] Disable the build with Qt versions older than 5.0 
4067         https://bugs.webkit.org/show_bug.cgi?id=65189
4068
4069         Reviewed by Csaba Osztrogonác.
4070
4071         * Platform/qt/ModuleQt.cpp:
4072         (WebKit::Module::platformFunctionPointer): Fix the build for Qt5.
4073
4074 2011-07-26  Benjamin Poulain  <benjamin@webkit.org>
4075
4076         [Qt][WK2] Make the WebContextMenuProxyQt handle the full interactions between the views and the WebPageProxy
4077         https://bugs.webkit.org/show_bug.cgi?id=64739
4078
4079         Reviewed by Andreas Kling.
4080
4081         Change the WebContextMenuProxyQt to be the intermediary between the WebPageProxy and our views regarding
4082         the context menu.
4083
4084         The actions of the context menu are no longer the responsibility of QtWebPageProxy but are instead
4085         created and handled directly by the WebContextMenuProxyQt.
4086
4087         * UIProcess/qt/QtWebPageProxy.cpp:
4088         (QtWebPageProxy::createContextMenuProxy):
4089         (QtWebPageProxy::triggerAction):
4090         (QtWebPageProxy::action):
4091         * UIProcess/qt/QtWebPageProxy.h:
4092         * UIProcess/qt/WebContextMenuProxyQt.cpp:
4093         (WebKit::WebContextMenuProxyQt::WebContextMenuProxyQt):
4094         (WebKit::WebContextMenuProxyQt::create):
4095         (WebKit::WebContextMenuProxyQt::actionTriggered):
4096         (WebKit::WebContextMenuProxyQt::showContextMenu):
4097         (WebKit::WebContextMenuProxyQt::hideContextMenu):
4098         (WebKit::WebContextMenuProxyQt::createContextMenu):
4099         * UIProcess/qt/WebContextMenuProxyQt.h:
4100
4101 2011-07-26  Carlos Garcia Campos  <cgarcia@igalia.com>
4102
4103         [GTK] Remove header webkitwebviewcommon.h
4104         https://bugs.webkit.org/show_bug.cgi?id=65177
4105
4106         Reviewed by Martin Robinson.
4107
4108         * UIProcess/API/gtk/WebKitWebView.h: Add function prototypes
4109         instead of including webkitwebviewcommon.h.
4110
4111 2011-07-22  Jessie Berlin  <jberlin@apple.com>
4112
4113         [WebKit2] Changing the cookie accept policy in Private Browsing doesn’t work.
4114         https://bugs.webkit.org/show_bug.cgi?id=64997
4115
4116         Reviewed by Ada Chan.
4117
4118         * WebProcess/Cookies/mac/WebCookieManagerMac.mm:
4119         (WebKit::WebCookieManager::platformSetHTTPCookieAcceptPolicy):
4120         Set the policy on the Cookie Storage used by the Private Browsing Storage Session as well.
4121         * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
4122         (InitWebCoreSystemInterface):
4123
4124 2011-07-21  Yael Aharon  <yael.aharon@nokia.com>
4125
4126         [Qt][WK2] Code cleanup for drag-and-drop
4127         https://bugs.webkit.org/show_bug.cgi?id=64916
4128
4129         Reviewed by Andreas Kling.
4130
4131         * UIProcess/WebPageProxy.cpp:
4132         (WebKit::WebPageProxy::startDrag):
4133         Allow receiving a NULL bitmap from the web process.
4134         
4135         * UIProcess/qt/qdesktopwebpageproxy.cpp:
4136         (QDesktopWebPageProxy::handleEvent):
4137         Fix typo introduced in http://trac.webkit.org/changeset/90458.
4138         All DnD related events should be GraphicsScene events.
4139         
4140         * WebProcess/WebCoreSupport/qt/WebDragClientQt.cpp:
4141         (WebKit::convertQPixmapToShareableBitmap):
4142         Remove hack that creates a 1x1 bitmap.
4143         It is no longer needed after http://trac.webkit.org/changeset/91016.
4144         
4145         (WebKit::WebDragClient::startDrag):
4146         Allow sending a NULL bitmap to the UI process.
4147
4148 2011-07-20  Tim Horton  <timothy_horton@apple.com>
4149
4150         Scrollbar color heuristic needs to be hooked up in WebKit1
4151         https://bugs.webkit.org/show_bug.cgi?id=64220
4152         <rdar://problem/9589140>
4153
4154         Reviewed by Darin Adler.
4155
4156         Store the scroller style on ScrollableArea, and recompute it whenever
4157         the document or body element background color changes or the base background
4158         color of the scrollview changes. Also, make sure to repaint the scrollbars
4159         whenever the style changes.
4160
4161         * WebProcess/WebPage/WebFrame.cpp:
4162         (WebKit::WebFrame::getDocumentBackgroundColor):
4163
4164 2011-07-20  James Robinson  <jamesr@chromium.org>
4165
4166         Revert worker and WebKit2 runloops to use currentTime() for scheduling instead of the monotonic clock
4167         https://bugs.webkit.org/show_bug.cgi?id=64841
4168
4169         Reviewed by Mark Rowe.
4170
4171         http://trac.webkit.org/changeset/91206 converted most of WebKit's deferred work scheduling to using the
4172         monotonic clock instead of WTF::currentTime().  This broke many plugin tests on WebKit2 for reasons that are
4173         unclear.  This reverts everything except for WebCore::ThreadTimers back to the previous behavior.
4174
4175         * Platform/CoreIPC/Connection.cpp:
4176         (CoreIPC::Connection::waitForMessage):
4177         (CoreIPC::Connection::waitForSyncReply):
4178         * Platform/RunLoop.h:
4179
4180 2011-07-19  Ryosuke Niwa  <rniwa@webkit.org>
4181
4182         Build fix after r91307.
4183
4184         * Platform/Logging.h:
4185
4186 2011-07-19  Lukasz Slachciak  <lukasz.slachciak@gmail.com>
4187
4188         [GTK] [WK2] Implement missing initializeLogChannel function.
4189         https://bugs.webkit.org/show_bug.cgi?id=63381
4190
4191         Reviewed by Martin Robinson.
4192
4193         Implemented logging for GTK platform in WebKit2 - function initializeLogChannel is called for all ports,
4194         so added missing implementation. Aslo helper function added for getting channels from names.
4195
4196         * GNUmakefile.am: Added reference to new file LoggingGtk.cpp.
4197         * Platform/Logging.cpp: Logging implementation for GTK port enabled.
4198         (WebKit::getChannelFromName): Helper to connect name with WTFLogChannel.
4199         * Platform/Logging.h: New helper method added.
4200         * Platform/gtk/LoggingGtk.cpp: Added. GTK logging implementation.
4201         (WebKit::initializeLogChannel): Channel is initialized if its name is found in WEBKIT_DEBUG.
4202
4203 2011-07-19  Brian Weinstein  <bweinstein@apple.com>
4204
4205         Add back a change that was accidentally removed in r91266.
4206         
4207         Make sure to retain the WKPasteboardFilePromiseOwner before calling draggedImage because draggedImage releases
4208         its responder. Also make the comment more explicit, to keep this mistake from being made in the future.
4209         
4210         Rubber-stamped by Darin Adler.
4211
4212         * WebProcess/WebCoreSupport/mac/WebDragClientMac.mm:
4213         (WebKit::WebDragClient::dragEnded):
4214
4215 2011-07-18  Brian Weinstein  <bweinstein@apple.com>
4216
4217         Speculative fix for: Crash under WebPage::platformDragEnded when dragging on Mac
4218         https://bugs.webkit.org/show_bug.cgi?id=64766
4219         <rdar://problem/9548174>
4220
4221         Reviewed by Enrica Casucci.
4222
4223         I was unable to reproduce this bug, but Darin Adler and I discussed the probable issue. When starting the drag, we create 
4224         a WKPasteboardFilePromiseOwner, and a WKPasteboardOwner. When the drag is concluded, we call a method on the WKPasteboardFilePromiseOwner
4225         which uses the WKPasteboardOwner. However, we are not guaranteeing that the WKPasteboardOwner will be around when the 
4226         WKPasteboardFilePromiseOwner method is called.
4227         
4228         The fix is to retain both the WKPasteboardFilePromiseOwner and the WKPasteboardOwner that we need, making sure that we are keeping
4229         both objects alive.
4230         
4231         This patch also uses r91222 to replace WebPage::platformDragEnded, so WebPage doesn't need to know about the drag source.
4232
4233         * WebProcess/WebCoreSupport/WebDragClient.cpp:
4234         (WebKit::WebDragClient::dragEnded): Add a non-Mac stub method, since the Mac is the only platform that does something here.
4235         * WebProcess/WebCoreSupport/WebDragClient.h:
4236         * WebProcess/WebCoreSupport/mac/WebDragClientMac.mm:
4237         (WebKit::WebDragClient::declareAndWriteDragImage): Use member variables instead of local variables.
4238         (WebKit::WebDragClient::dragEnded): Move code from WebPageMac::platformDragEnded to here, and clear both member variables.
4239         * WebProcess/WebPage/WebPage.cpp:
4240         (WebKit::WebPage::dragEnded): Don't call platformDragEnded anymore. WebCore::DragController::dragEnded calls WebDragClient::dragEnded,
4241             which does the same thing.
4242         * WebProcess/WebPage/WebPage.h:
4243         * WebProcess/WebPage/mac/WebPageMac.mm: Remove platformDragEnded.
4244
4245 2011-07-18  Alexis Menard  <alexis.menard@openbossa.org>
4246
4247         [Qt][WK2] Make QDesktopWebView::navigationAction method usable in QML.
4248         https://bugs.webkit.org/show_bug.cgi?id=64690
4249
4250         Make the API usable with QML by declaring what's needed
4251         with the macros.
4252
4253         Reviewed by Benjamin Poulain.
4254
4255         * UIProcess/API/qt/qdesktopwebview.h:
4256
4257 2011-07-18  MORITA Hajime  <morrita@google.com>
4258
4259         [ShadowContentElement] forwarded node should be able to access its hosting content element.
4260         https://bugs.webkit.org/show_bug.cgi?id=64251
4261
4262         Reviewed by Dimitri Glazkov.
4263
4264         Exported additional symbols for window.internals object.
4265
4266         * win/WebKit2.def:
4267         * win/WebKit2CFLite.def:
4268
4269 2011-07-18  Dean Jackson  <dino@apple.com>
4270
4271         https://bugs.webkit.org/show_bug.cgi?id=64742
4272         Expose WebPreferences for media playback requiring user gestures and inline playback
4273
4274         Reviewed by Simon Fraser.
4275
4276         Two new WebPreferences: MediaPlaybackRequiresUserGesture and
4277         MediaPlaybackAllowsInline.
4278
4279         * Shared/WebPreferencesStore.h:
4280         * UIProcess/API/C/WKPreferences.cpp:
4281         (WKPreferencesSetMediaPlaybackRequiresUserGesture):
4282         (WKPreferencesGetMediaPlaybackRequiresUserGesture):
4283         (WKPreferencesSetMediaPlaybackAllowsInline):
4284         (WKPreferencesGetMediaPlaybackAllowsInline):
4285         * UIProcess/API/C/WKPreferencesPrivate.h:
4286         * WebProcess/WebPage/WebPage.cpp:
4287         (WebKit::WebPage::updatePreferences):
4288
4289 2011-07-18  James Robinson  <jamesr@chromium.org>
4290
4291         Timer scheduling should be based off the monotonic clock
4292         https://bugs.webkit.org/show_bug.cgi?id=64544
4293
4294         Reviewed by Darin Adler.
4295
4296         Converts the WebKit2 RunLoop and CoreIPC timeouts to use monotonicallyIncreasingTime().
4297
4298         * Platform/CoreIPC/Connection.cpp:
4299         (CoreIPC::Connection::waitForMessage):
4300         (CoreIPC::Connection::waitForSyncReply):
4301         * Platform/RunLoop.h:
4302
4303 2011-07-18  Anders Carlsson  <andersca@apple.com>
4304
4305         Make using lowercase parameter names for AppleConnect be a plug-in quirk
4306         https://bugs.webkit.org/show_bug.cgi?id=64638
4307
4308         Reviewed by Sam Weinig.
4309
4310         * Shared/Plugins/Netscape/mac/NetscapePluginModuleMac.mm:
4311         (WebKit::NetscapePluginModule::determineQuirks):
4312         Set the WantsLowercaseParameterNames quirk for the AppleConnect plug-in.
4313
4314         * Shared/Plugins/PluginQuirks.h:
4315         Add WantsLowercaseParameterNames quirk.
4316
4317         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
4318         (WebKit::NetscapePlugin::initialize):
4319         If the plug-in has the WantsLowercaseParameterNames quirk, convert the parameter
4320         names to lowercase.
4321
4322         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
4323         (WebKit::WebFrameLoaderClient::createPlugin):
4324         Remove the code that would convert the parameters here. Also remove the FIXME; plug-in quirks
4325         aren't really the same thing as site-specific quirks.
4326
4327 2011-07-15  Jocelyn Turcotte  <jocelyn.turcotte@nokia.com>
4328
4329         [Qt] Consider QTouchWebPage's transform when scrolling the viewport.
4330         https://bugs.webkit.org/show_bug.cgi?id=64541
4331
4332         Reviewed by Benjamin Poulain.
4333
4334         Currently the scroll deltas are given to moveBy in page coordinates
4335         which doesn't match when the page view is scalled.
4336         This patch gives the scroll delta to the viewport in it's own coordinates.
4337
4338         * UIProcess/qt/TouchViewInterface.cpp:
4339         (WebKit::TouchViewInterface::panGestureRequestScroll):
4340
4341 2011-07-15  Jocelyn Turcotte  <jocelyn.turcotte@nokia.com>
4342
4343         [Qt] Push the new viewport rect to the drawing area after committing the scale.
4344         https://bugs.webkit.org/show_bug.cgi?id=64597
4345
4346         Reviewed by Benjamin Poulain.
4347
4348         * UIProcess/qt/TouchViewInterface.cpp:
4349         (WebKit::TouchViewInterface::pinchGestureEnded):
4350
4351 2011-07-15  Jocelyn Turcotte  <jocelyn.turcotte@nokia.com>
4352
4353         [Qt] Remove the scale commit timer from QTouchWebPage.
4354         https://bugs.webkit.org/show_bug.cgi?id=64600
4355
4356         Reviewed by Benjamin Poulain.
4357
4358         Since we don't currently need unprepared page view scale changes,
4359         this timer isn't useful.
4360
4361         * UIProcess/API/qt/qtouchwebpage.cpp:
4362         (QTouchWebPage::QTouchWebPage):
4363         (QTouchWebPagePrivate::QTouchWebPagePrivate):
4364         (QTouchWebPagePrivate::commitScaleChange):
4365         * UIProcess/API/qt/qtouchwebpage.h:
4366         * UIProcess/API/qt/qtouchwebpage_p.h:
4367         * UIProcess/qt/TouchViewInterface.cpp:
4368         (WebKit::TouchViewInterface::pinchGestureStarted):
4369
4370 2011-07-15  Jocelyn Turcotte  <jocelyn.turcotte@nokia.com>
4371
4372         TiledDrawingArea: map the visibleArea rect from page to tiles coordinates.
4373         https://bugs.webkit.org/show_bug.cgi?id=64538
4374
4375         Reviewed by Benjamin Poulain.
4376
4377         TiledDrawingAreaProxy expects its coordinates to be scaled according to
4378         contentsScale. This patch keep the pushed visibleArea as page coordinates
4379         and convert it each time to scaled coordinates in case the contents scale was
4380         changed afterward.
4381         This is a regression introduced in r90750.
4382         Also:
4383         - Rename visibleArea to visibleContentRect
4384         - Remove an unnecessary mapToContents in QTouchWebPageProxy::setVisibleContentRect
4385
4386         * UIProcess/API/qt/qtouchwebpage.cpp:
4387         (QTouchWebPagePrivate::setViewportRect):
4388         * UIProcess/TiledDrawingAreaProxy.cpp:
4389         (WebKit::TiledDrawingAreaProxy::invalidate):
4390         (WebKit::TiledDrawingAreaProxy::setVisibleContentRect):
4391         (WebKit::TiledDrawingAreaProxy::createTiles):
4392         (WebKit::TiledDrawingAreaProxy::visibleRect):
4393         * UIProcess/TiledDrawingAreaProxy.h:
4394         * UIProcess/qt/qtouchwebpageproxy.cpp:
4395         (QTouchWebPageProxy::setVisibleContentRect):
4396         * UIProcess/qt/qtouchwebpageproxy.h:
4397
4398 2011-07-17  Amruth Raj  <amruthraj@motorola.com>
4399
4400         [GTK] Fix selection of elements in a multi select list and remove an unnecessary include in WorkQueue
4401         https://bugs.webkit.org/show_bug.cgi?id=64666
4402
4403         Reviewed by Martin Robinson.
4404
4405         * Platform/gtk/WorkQueueGtk.cpp: Remove an include which is no longer required
4406         * Shared/gtk/WebEventFactory.cpp:
4407         (WebKit::modifiersForEvent): Fix an incorrect ASSERT statement
4408         (WebKit::WebEventFactory::createWebMouseEvent): Call the function to determine the modifier keys
4409
4410 2011-07-17  Lukasz Slachciak  <l.slachciak@samsung.com>
4411
4412         Reviewed by Martin Robinson.
4413
4414          [GTK] [WK2] Fix for getting editor client commands.
4415          https://bugs.webkit.org/show_bug.cgi?id=63081
4416
4417          Editor client commands intepretation was incorrect. It was based on the NativeWebKeyboardEvent only.
4418          In fact EventHandler is generating interpreted events - keypress and keydown. These event types
4419          are now passed from UIProcess to WebProcess so KeyBindingTranslator can correctly find editor commands.
4420          Also build break for Debug build was fixed.
4421
4422         * UIProcess/API/gtk/PageClientImpl.cpp: KeyboardEvent type is used for KeyBindingTranslator.
4423         (WebKit::PageClientImpl::getEditorCommandsForKeyEvent): getEditorCommandsForKeyEvent now has additional
4424         parameter describing KeyboardEvent type.
4425         * UIProcess/API/gtk/PageClientImpl.h:
4426         * UIProcess/PageClient.h:
4427         * UIProcess/WebPageProxy.h:
4428         * UIProcess/WebPageProxy.messages.in:
4429         * UIProcess/gtk/WebPageProxyGtk.cpp:
4430         (WebKit::WebPageProxy::getEditorCommandsForKeyEvent): KeyboardEvent type passed to PageClient.
4431         * WebProcess/WebCoreSupport/gtk/WebEditorClientGtk.cpp:
4432         (WebKit::WebEditorClient::getEditorCommandsForKeyEvent): Sync message send with KeyboardEvent type.
4433
4434 2011-07-16  Daniel Bates  <dbates@webkit.org>
4435
4436         Fix Win Cairo Debug build after <http://trac.webkit.org/changeset/91085>.
4437
4438         Add stub implementation of scale factor overloaded ShareableBitmap::paint() for
4439         Cairo WebKit2 port after its usage in changeset <http://trac.webkit.org/changeset/91085>.
4440
4441         Also add stub implementation for GTK.
4442
4443         We'll need to actually implement this. See <https://bugs.webkit.org/show_bug.cgi?id=64664>
4444         and <https://bugs.webkit.org/show_bug.cgi?id=64665> for Cairo and GTK, respectively.
4445
4446         * Shared/cairo/ShareableBitmapCairo.cpp:
4447         (WebKit::ShareableBitmap::paint): Added scale-factor variant.
4448         * Shared/gtk/ShareableBitmapGtk.cpp:
4449         (WebKit::ShareableBitmap::paint): Added scale-factor variant.
4450
4451 2011-07-16  Daniel Bates  <dbates@webkit.org>
4452
4453         Fix Qt Linux Release build after changeset <http://trac.webkit.org/changeset/91085>
4454         (https://bugs.webkit.org/show_bug.cgi?id=64611).
4455
4456         Stub out scale factor-variant implementation of ShareableBitmap::paint().
4457         We'll need to implement this. See <https://bugs.webkit.org/show_bug.cgi?id=64663>
4458         for more details.
4459
4460         * Shared/qt/ShareableBitmapQt.cpp:
4461         (WebKit::ShareableBitmap::paint): Added scale-factor variant.
4462
4463 2011-07-16  Simon Fraser  <simon.fraser@apple.com>
4464
4465         Add code to attempt to align compositing layers to pixel boundaries when page scale changes
4466         https://bugs.webkit.org/show_bug.cgi?id=64658
4467
4468         Reviewed by Dan Bernstein.
4469         
4470         Removed implementation of pageScaleFactor() now that GraphicsLayerClient has
4471         a default implementation.
4472
4473         * WebProcess/WebPage/ca/LayerTreeHostCA.cpp:
4474         * WebProcess/WebPage/ca/LayerTreeHostCA.h:
4475
4476 2011-07-16  Daniel Bates  <dbates@webkit.org>
4477
4478         Attempt to fix the Qt Linux Release build after changeset <http://trac.webkit.org/changeset/91097>
4479         (https://bugs.webkit.org/show_bug.cgi?id=64615).
4480
4481         * UIProcess/qt/QtWebPageProxy.cpp:
4482         (QtWebPageProxy::setCursorHiddenUntilMouseMoves): Added stub method.
4483         * UIProcess/qt/QtWebPageProxy.h:
4484
4485 2011-07-15  Pratik Solanki  <psolanki@apple.com>
4486
4487         Part of https://bugs.webkit.org/show_bug.cgi?id=63674
4488         Get webkit to compile with USE(CFNETWORK) enabled on Mac
4489
4490         Reviewed by David Kilzer.
4491
4492         New WebKitSystemInterface functions for CFNetwork-based loader.
4493
4494         * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
4495         (InitWebCoreSystemInterface):
4496
4497 2011-07-15  Tim Horton  <timothy_horton@apple.com>
4498
4499         Overlay scrollbars in overflow areas no longer pulse when revealed
4500         https://bugs.webkit.org/show_bug.cgi?id=64606
4501         <rdar://problem/9390674>
4502
4503         Reviewed by Simon Fraser.
4504
4505         Ensure that the state of the scrollbar implementation is kept in sync
4506         with WebCore's internal representation. Previously, we synchronized them
4507         at paint time, causing pulsing to be skipped due to the scrollbars being
4508         disabled.
4509
4510         * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
4511         (InitWebCoreSystemInterface):
4512
4513 2011-07-15  Simon Fraser  <simon.fraser@apple.com>
4514
4515         Have GraphicsLayer pull their contentsScale, rather than pushing it onto them
4516         https://bugs.webkit.org/show_bug.cgi?id=64643
4517
4518         Reviewed by Darin Adler.
4519         
4520         Impement new GraphicsLayerClient methods related to contents scale,
4521         and don't push the scale.
4522
4523         * WebProcess/WebPage/ca/LayerTreeHostCA.cpp:
4524         (WebKit::LayerTreeHostCA::initialize):
4525         (WebKit::LayerTreeHostCA::backingScaleFactor):
4526         (WebKit::LayerTreeHostCA::pageScaleFactor):
4527         (WebKit::LayerTreeHostCA::createPageOverlayLayer):
4528         * WebProcess/WebPage/ca/LayerTreeHostCA.h:
4529         (WebKit::LayerTreeHostCA::didCommitChangesForLayer):
4530
4531 2011-07-15  Ada Chan  <adachan@apple.com>
4532
4533         Implement "Jump to Selection" in WebKit2
4534         https://bugs.webkit.org/show_bug.cgi?id=64569
4535
4536         Reviewed by Anders Carlsson.
4537
4538         * UIProcess/API/mac/WKView.mm:
4539         (-[WKView centerSelectionInVisibleArea:]): Call WebPageProxy::centerSelectionInVisibleArea().
4540         (-[WKView validateUserInterfaceItem:]): Enable the centerSelectionInVisibleArea: selector if there's a selection
4541         range or if there's an insertion point in an editable area.
4542         * WebProcess/WebPage/FindController.cpp:
4543         (WebKit::FindController::showFindIndicatorInSelection): Call updateFindIndicator() to show the find indicator.
4544         * WebProcess/WebPage/FindController.h:
4545         * WebProcess/WebPage/WebPage.cpp:
4546         (WebKit::WebPage::centerSelectionInVisibleArea): Use the selection in the focused or main frame.
4547         After scrolling the selection into view, flash the find indicator.
4548
4549 2011-07-15  Dan Bernstein  <mitz@apple.com>
4550
4551         Windows build fix.
4552
4553         * UIProcess/win/WebView.cpp:
4554
4555 2011-07-15  Dan Bernstein  <mitz@apple.com>
4556
4557         Windows build fix.
4558
4559         * UIProcess/win/WebView.h:
4560
4561 2011-07-15  Dan Bernstein  <mitz@apple.com>
4562
4563         REGRESSION: Mouse cursor doesn’t hide when full screen video HUD hides
4564         https://bugs.webkit.org/show_bug.cgi?id=64615
4565
4566         Reviewed by Anders Carlsson.
4567
4568         * UIProcess/API/efl/PageClientImpl.cpp:
4569         (WebKit::PageClientImpl::setCursorHiddenUntilMouseMoves): Added this stub.
4570         * UIProcess/API/efl/PageClientImpl.h:
4571         * UIProcess/API/gtk/PageClientImpl.cpp:
4572         (WebKit::PageClientImpl::setCursorHiddenUntilMouseMoves): Ditto.
4573         * UIProcess/API/gtk/PageClientImpl.h:
4574         * UIProcess/API/mac/PageClientImpl.h:
4575         * UIProcess/API/mac/PageClientImpl.mm:
4576         (WebKit::PageClientImpl::setCursorHiddenUntilMouseMoves): Added. Calls +[NSCursor setHiddenUntilMouseMoves:].
4577         * UIProcess/PageClient.h:
4578         * UIProcess/WebPageProxy.cpp:
4579         (WebKit::WebPageProxy::setCursorHiddenUntilMouseMoves): Added. Calls through to the PageClient.
4580         * UIProcess/WebPageProxy.h:
4581         * UIProcess/WebPageProxy.messages.in: Added SetCursorHiddenUntilMouseMoves message.
4582         * UIProcess/win/WebView.cpp:
4583         (WebKit::WebView::setCursorHiddenUntilMouseMoves): Added this stub.
4584         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
4585         (WebKit::WebChromeClient::setCursorHiddenUntilMouseMoves): Added. Sends SetCursorHiddenUntilMouseMoves message
4586         to the page proxy.
4587         * WebProcess/WebCoreSupport/WebChromeClient.h:
4588
4589 2011-07-14  Gavin Barraclough  <barraclough@apple.com>
4590
4591         https://bugs.webkit.org/show_bug.cgi?id=64250
4592         Global strict mode function leaking global object as "this".
4593
4594         Reviewed by Oliver Hunt.
4595
4596         * WebProcess/Plugins/Netscape/NPJSObject.cpp:
4597         (WebKit::NPJSObject::invoke):
4598             - Change call to pass DOM Window shell, instead of the global varaible object.
4599
4600 2011-07-15  Anders Carlsson  <andersca@apple.com>
4601
4602         Find indicator should take scale factor into account
4603         https://bugs.webkit.org/show_bug.cgi?id=64611
4604         <rdar://problem/9761020>
4605
4606         Reviewed by Sam Weinig.
4607
4608         * UIProcess/FindIndicator.cpp:
4609         (WebKit::FindIndicator::create):
4610         (WebKit::FindIndicator::FindIndicator):
4611         Keep track of the scale factor of the find indicator bitmap.
4612
4613         (WebKit::FindIndicator::draw):
4614         Pass the scale factor to ShareableBitmap::draw.
4615
4616         * UIProcess/FindIndicator.h:
4617         Add scale factor member variable.
4618
4619         * UIProcess/WebPageProxy.cpp:
4620         (WebKit::WebPageProxy::setFindIndicator):
4621         This now takes the content image scale factor.
4622
4623         * UIProcess/WebPageProxy.messages.in:
4624         Add the scale factor.
4625
4626         * WebProcess/WebPage/FindController.cpp:
4627         (WebKit::FindController::updateFindIndicator):
4628         Size the backing store correctly, and apply the scale factor to
4629         the graphics context.
4630
4631         (WebKit::FindController::hideFindIndicator):
4632         Pass the scale factor along.
4633
4634 2011-07-15  Martin Robinson  <mrobinson@igalia.com>
4635
4636         Build fixes for WebKit2. Ensure that all generated sources are
4637         on nodist primaries, that they are on forward declared variables
4638         so that BUILT_SOURCES is calculated properly and that zlib is 
4639         included during linking (for WOFF support).
4640
4641         * GNUmakefile.am:
4642
4643 2011-07-15  Kenneth Rohde Christiansen  <kenneth@webkit.org>
4644
4645         Upstream QtWebKit/N9 changes related to visibleContentRect
4646         https://bugs.webkit.org/show_bug.cgi?id=64589
4647
4648         Reviewed by Simon Hausmann.
4649
4650         Rename setActualVisibleContentRect to setFixedVisibleContentRect
4651         as that makes it more obvious that it is an override. It is also
4652         consistent with the setFixedLayout which is often used in
4653         conjunction with it.
4654
4655         * UIProcess/WebPageProxy.cpp:
4656         (WebKit::WebPageProxy::setFixedVisibleContentRect):
4657         * UIProcess/WebPageProxy.h:
4658         * UIProcess/qt/qtouchwebpageproxy.cpp:
4659         (QTouchWebPageProxy::setVisibleArea):
4660         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
4661         (WebKit::WebFrameLoaderClient::transitionToCommittedForNewPage):
4662         Only set fixedVisibleContentRect for the mainframe.
4663         * WebProcess/WebPage/WebPage.cpp:
4664         (WebKit::WebPage::setFixedVisibleContentRect):
4665         * WebProcess/WebPage/WebPage.h:
4666         * WebProcess/WebPage/WebPage.messages.in:
4667
4668 2011-07-15  Carlos Garcia Campos  <cgarcia@igalia.com>
4669
4670         Reviewed by Martin Robinson.
4671
4672         [GTK] Install a custom X error handler in plugin process
4673         https://bugs.webkit.org/show_bug.cgi?id=63248
4674
4675         Some plugins, specially flash, can cause X errors that when
4676         handled by the default X error handler (or the GDK one) abort the
4677         process. Since we don't want to crash due to buggy plugins, we
4678         install a custom error handler to show a warning when a X error
4679         happens without aborting.
4680
4681         * PluginProcess/gtk/PluginProcessMainGtk.cpp:
4682         (WebKit::webkitgtkXError):
4683         (WebKit::PluginProcessMainGtk):
4684
4685 2011-07-14  Carlos Garcia Campos  <cgarcia@igalia.com>
4686
4687         Reviewed by Anders Carlsson.
4688
4689         [UNIX] Allow sending null handles in messages
4690         https://bugs.webkit.org/show_bug.cgi?id=60621
4691
4692         Only valid file descriptors are now sent using sendmsg() control
4693         messages, and instead of sending a list of attachment sizes we now
4694         send a list of AttachmentInfo structs. AttachmentInfo contains
4695         information about the attachments including the size for
4696         MappedMemory attachmens and whether the attachment is null or not.
4697
4698         * Platform/CoreIPC/unix/ConnectionUnix.cpp:
4699         (CoreIPC::AttachmentInfo::AttachmentInfo): New class containing
4700         information about the attachments sent.
4701         (CoreIPC::AttachmentInfo::setType): Set the attachment type.
4702         (CoreIPC::AttachmentInfo::getType): Return the attachment type.
4703         (CoreIPC::AttachmentInfo::setSize): Set the size for MappedMemory attachments.
4704         (CoreIPC::AttachmentInfo::getSize): Get the size for MappedMemory attachments.
4705         (CoreIPC::AttachmentInfo::setNull): Set attachment as null, it
4706         contains an invalid file descriptor, so the receiver shouldn't
4707         expect a file desriptor for this attachment.
4708         (CoreIPC::AttachmentInfo::isNull): Return whether attachment is
4709         null, it contains an invalid file descriptor.
4710         (CoreIPC::Connection::processMessage):
4711         (CoreIPC::Connection::sendOutgoingMessage):
4712
4713 2011-07-14  Carlos Garcia Campos  <cgarcia@igalia.com>
4714
4715         Reviewed by Martin Robinson.
4716
4717         [GTK] Implement Plugin Process
4718         https://bugs.webkit.org/show_bug.cgi?id=60546
4719
4720         * GNUmakefile.am: Add new files to compilation.
4721         * PluginProcess/gtk/PluginProcessMainGtk.cpp: Added.
4722         (WebKit::PluginProcessMainGtk):
4723         * PluginProcess/gtk/PluginProcessMainGtk.h: Added.
4724         * UIProcess/Launcher/gtk/ProcessLauncherGtk.cpp:
4725         (WebKit::ProcessLauncher::launchProcess):
4726         * WebProcess/Plugins/Netscape/x11/NetscapePluginX11.cpp:
4727         (WebKit::moduleMixesGtkSymbols):
4728         * gtk/PluginMainGtk.cpp: Added.
4729         (main):
4730
4731 2011-07-14  Balazs Kelemen  <kbalazs@webkit.org> and Carlos Garcia Campos  <cgarcia@igalia.com>
4732
4733         Reviewed by Anders Carlsson.
4734
4735         Implement plugin process for UNIX platform
4736         https://bugs.webkit.org/show_bug.cgi?id=60629
4737
4738         * Platform/CoreIPC/Attachment.h:
4739         * Platform/CoreIPC/unix/AttachmentUnix.cpp:
4740         (CoreIPC::Attachment::Attachment): Add the ability to pass a
4741         socket via Attachment.
4742         * Platform/unix/SharedMemoryUnix.cpp:
4743         (WebKit::SharedMemory::Handle::encode): Remove assertions that
4744         check that the Handle is not null. In
4745         PluginProxy::geometryDidChange we pass a null Handle if we do not
4746         need to allocate a new backing store.
4747         (WebKit::SharedMemory::Handle::releaseToAttachment): Ditto.
4748         * PluginProcess/PluginProcess.cpp:
4749         (WebKit::PluginProcess::createWebProcessConnection): Use
4750         Attachment. Set up the connection with socketpair.
4751         * UIProcess/Plugins/PluginProcessProxy.cpp:
4752         (WebKit::PluginProcessProxy::pluginProcessCrashedOrFailedToLaunch):
4753         (WebKit::PluginProcessProxy::didCreateWebProcessConnection):
4754         * UIProcess/Plugins/PluginProcessProxy.h:
4755         * UIProcess/Plugins/PluginProcessProxy.messages.in:
4756         * UIProcess/WebProcessProxy.messages.in:
4757         * WebProcess/Plugins/PluginProcessConnectionManager.cpp:
4758         (WebKit::PluginProcessConnectionManager::getPluginProcessConnection):
4759         Use Attachment to pass the connection.
4760
4761 2011-07-14  Ada Chan  <adachan@apple.com>
4762
4763         Implement support to center selection on a page for WebKit2.
4764         https://bugs.webkit.org/show_bug.cgi?id=64481
4765
4766         Reviewed by Anders Carlsson.
4767
4768         * UIProcess/API/C/WKPage.cpp:
4769         (WKPageCenterSelectionInVisibleArea): Added.  Call WebPageProxy::centerSelectionInVisibleArea().
4770         * UIProcess/API/C/WKPage.h:
4771         * UIProcess/WebPageProxy.cpp:
4772         (WebKit::WebPageProxy::centerSelectionInVisibleArea): Send message to the WebProcess to center selection.
4773         * UIProcess/WebPageProxy.h:
4774         * WebProcess/WebPage/WebPage.cpp:
4775         (WebKit::WebPage::centerSelectionInVisibleArea): Get the FrameSelection from the main frame and call
4776         revealSelection() to center it.
4777         * WebProcess/WebPage/WebPage.h:
4778         * WebProcess/WebPage/WebPage.messages.in: Add the CenterSelectionInVisibleArea message.
4779
4780 2011-07-14  MORITA Hajime  <morrita@google.com>
4781
4782         Unreviewed, rolling out r90976, r90981, and r90985.
4783         http://trac.webkit.org/changeset/90976
4784         http://trac.webkit.org/changeset/90981
4785         http://trac.webkit.org/changeset/90985
4786         https://bugs.webkit.org/show_bug.cgi?id=64251
4787
4788         build break
4789
4790         * win/WebKit2.def:
4791         * win/WebKit2CFLite.def:
4792
4793 2011-07-13  MORITA Hajime <morrita@google.com>
4794
4795         Unreviewed attempt at a build fix.
4796
4797         * win/WebKit2CFLite.def:
4798
4799 2011-07-13  MORITA Hajime  <morrita@google.com>
4800
4801         [ShadowContentElement] forwarded node should be able to access its hosting content element.
4802         https://bugs.webkit.org/show_bug.cgi?id=64251
4803
4804         Reviewed by Dimitri Glazkov.
4805
4806         Exported additional symbols for window.internals object.
4807         
4808         * win/WebKit2.def:
4809
4810 2011-07-13  David Levin  <levin@chromium.org>
4811
4812         Possible race condition in ThreadIdentifierData::initializeKeyOnce and shouldCallRealDebugger.
4813         https://bugs.webkit.org/show_bug.cgi?id=64465
4814
4815         Reviewed by Dmitry Titov.
4816
4817         There isn't a good way to test this as it is very highly unlikely to occur.
4818
4819         * PluginProcess/mac/PluginProcessMac.mm:
4820         (WebKit::shouldCallRealDebugger): :Since scoped static initialization
4821         isn't thread-safe, change the initialization to be global.
4822
4823 2011-07-13  Andreas Kling  <kling@webkit.org>
4824
4825         [Qt][WK2] Remove invalid signal/slot connection in QTouchWebView.
4826         https://bugs.webkit.org/show_bug.cgi?id=64450
4827
4828         Reviewed by Benjamin Poulain.
4829
4830         The focusNextPrevChild() signal was removed, so we shouldn't try to
4831         connect to it.
4832
4833         * UIProcess/API/qt/qtouchwebpage.cpp:
4834         (QTouchWebPagePrivate::setPage):
4835
4836 2011-07-13  Andreas Kling  <kling@webkit.org>
4837
4838         [Qt][WK2] Undelayed WorkItems are leaked after execution.
4839         https://bugs.webkit.org/show_bug.cgi?id=64447
4840
4841         Reviewed by Benjamin Poulain.
4842
4843         * Platform/qt/WorkQueueQt.cpp:
4844         (WorkQueue::WorkItemQt::executeAndDelete):
4845         (WorkQueue::WorkItemQt::timerEvent):
4846         (WorkQueue::scheduleWork):
4847
4848 2011-07-12  Jocelyn Turcotte  <jocelyn.turcotte@nokia.com>
4849
4850         [Qt] Also stop the scale commit timer when commitScaleChange is called explicitly.
4851         https://bugs.webkit.org/show_bug.cgi?id=64357
4852
4853         Reviewed by Benjamin Poulain.
4854
4855         * UIProcess/API/qt/qtouchwebpage.cpp:
4856         (QTouchWebPage::timerEvent):
4857         (QTouchWebPagePrivate::commitScaleChange):
4858
4859 2011-07-12  Joseph Pecoraro  <joepeck@webkit.org>
4860
4861         ApplicationCache update should not immediately fail when reaching per-origin quota
4862         https://bugs.webkit.org/show_bug.cgi?id=64177
4863
4864         Reviewed by Alexey Proskuryakov.
4865
4866         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
4867         (WebKit::WebChromeClient::reachedApplicationCacheOriginQuota):
4868         * WebProcess/WebCoreSupport/WebChromeClient.h:
4869
4870 2011-06-22  Jer Noble  <jer.noble@apple.com>
4871
4872         Full-screen: Don't change the collectionBehavior of the WebView's NSWindow if not necessary
4873         https://bugs.webkit.org/show_bug.cgi?id=63217
4874         <rdar://problem/9660291>
4875
4876         Reviewed by Darin Adler.
4877
4878         Check to see if the NSWindow hosting the WebView is not on the active space before changing the window's
4879         collectionBehavior.
4880
4881         * UIProcess/mac/WKFullScreenWindowController.mm:
4882         (-[WKFullScreenWindowController beganExitFullScreenAnimation]):
4883
4884 2011-07-12  Andreas Kling  <kling@webkit.org>
4885
4886         [Qt][WK2] Navigation actions in incorrect state when loadStarted() is emitted.
4887         https://bugs.webkit.org/show_bug.cgi?id=64383
4888
4889         Reviewed by Kenneth Rohde Christiansen.
4890
4891         Update the navigation actions before emitting loadStarted().
4892
4893         * UIProcess/API/qt/tests/qdesktopwebview/tst_qdesktopwebview.cpp:
4894         (LoadStartedCatcher::LoadStartedCatcher):
4895         (LoadStartedCatcher::onLoadStarted):
4896         (tst_QDesktopWebView::stopActionEnabledAfterLoadStarted):
4897         * UIProcess/qt/ClientImpl.cpp:
4898         (qt_wk_didStartProvisionalLoadForFrame):
4899
4900 2011-07-12  Benjamin Poulain  <benjamin@webkit.org>
4901
4902         [Qt][WK2] Add a basic Pinch gesture recognizer for WebKit2
4903         https://bugs.webkit.org/show_bug.cgi?id=64373
4904
4905         Reviewed by Andreas Kling.
4906
4907         This patch adds QtPinchGestureRecognizer to recognize pinch gesture out of
4908         the events not handled by the WebProcess.
4909
4910         TouchViewInterface::pinchGestureRequestScale() has a basic default implementation
4911         so the feature can be tested manually.
4912
4913         * UIProcess/qt/QtGestureRecognizer.cpp:
4914         QtGestureRecognizer is the private base class for both gesture recognizer
4915         in order to be able to share some code.
4916         (WebKit::QtGestureRecognizer::QtGestureRecognizer):
4917         (WebKit::QtGestureRecognizer::reset):
4918         * UIProcess/qt/QtGestureRecognizer.h:
4919         * UIProcess/qt/QtPanGestureRecognizer.cpp:
4920         (WebKit::QtPanGestureRecognizer::QtPanGestureRecognizer):
4921         (WebKit::QtPanGestureRecognizer::reset):
4922         * UIProcess/qt/QtPanGestureRecognizer.h:
4923         * UIProcess/qt/QtPinchGestureRecognizer.cpp: Added.
4924         (WebKit::findTouchPointIndex):
4925         (WebKit::computeTouchCenter):
4926         (WebKit::QtPinchGestureRecognizer::QtPinchGestureRecognizer):
4927         (WebKit::QtPinchGestureRecognizer::recognize):
4928         (WebKit::QtPinchGestureRecognizer::reset):
4929         (WebKit::QtPinchGestureRecognizer::initializeGesture):
4930         * UIProcess/qt/QtPinchGestureRecognizer.h: Copied from Source/WebKit2/UIProcess/qt/QtPanGestureRecognizer.h.
4931         (WebKit::QtPinchGestureRecognizer::TouchPointInformation::TouchPointInformation):
4932         (WebKit::QtPinchGestureRecognizer::TouchPointInformation::isValid):
4933         * UIProcess/qt/TouchViewInterface.cpp:
4934         (WebKit::TouchViewInterface::TouchViewInterface):
4935         (WebKit::TouchViewInterface::pinchGestureStarted):
4936         (WebKit::TouchViewInterface::pinchGestureRequestScale):
4937         The scale factor reported by the recognizer to the TouchViewInterface is the total scale since the start
4938         of the gesture in order to avoid numerical instabilities.
4939         (WebKit::TouchViewInterface::pinchGestureEnded):
4940         * UIProcess/qt/TouchViewInterface.h:
4941         * UIProcess/qt/qtouchwebpageproxy.cpp:
4942         (QTouchWebPageProxy::QTouchWebPageProxy):
4943         (QTouchWebPageProxy::processDidCrash):
4944         (QTouchWebPageProxy::doneWithTouchEvent):
4945         * UIProcess/qt/qtouchwebpageproxy.h:
4946         * WebKit2.pro:
4947
4948 2011-07-12  Andreas Kling  <kling@webkit.org>
4949
4950         [Qt][WK2] Navigation actions should react to web process availability.
4951         https://bugs.webkit.org/show_bug.cgi?id=64375
4952
4953         Reviewed by Benjamin Poulain.
4954
4955         When the web process is unavailable, the reload and stop actions should
4956         behave slightly differently. Stop should always be disabled, and reload
4957         should be enabled if there's a reloadable item in the back/forward list.
4958
4959         * UIProcess/API/qt/tests/qdesktopwebview/tst_qdesktopwebview.cpp:
4960         (tst_QDesktopWebView::navigationActionEnabledStatusAtStartup):
4961         * UIProcess/API/qt/tests/qtouchwebview/tst_qtouchwebview.cpp:
4962         (tst_QTouchWebView::navigationActionEnabledStatusAtStartup):
4963         * UIProcess/qt/QtWebPageProxy.cpp:
4964         (QtWebPageProxy::updateAction):
4965         (QtWebPageProxy::didRelaunchProcess):
4966         (QtWebPageProxy::processDidCrash):
4967
4968 2011-07-12  Andreas Kling  <kling@webkit.org>
4969
4970         [Qt][WK2] QDesktopWebView crashes if resized without web process.
4971         https://bugs.webkit.org/show_bug.cgi?id=64371
4972
4973         Reviewed by Benjamin Poulain.
4974
4975         * UIProcess/qt/QtWebPageProxy.cpp:
4976         (QtWebPageProxy::paint): Remove an invalid assertion. The drawing
4977         area may be null if the web process has crashed.
4978         (QtWebPageProxy::setDrawingAreaSize): Fail silently if there is no
4979         drawing area.
4980
4981 2011-07-12  Andreas Kling  <kling@webkit.org>
4982
4983         [Qt][WK2] Add informative loadFailed() signal to web views.
4984         https://bugs.webkit.org/show_bug.cgi?id=64362
4985
4986         Reviewed by Benjamin Poulain.
4987
4988         The web views will now emit loadFailed(QWebError) when a load failure occurs.
4989
4990         The QWebError object currently contains:
4991         - Type of failure (whether it's an engine, network or protocol error.)
4992         - The failing URL.
4993         - Any error code associated with the failure.
4994
4995         * UIProcess/API/qt/qdesktopwebview.cpp:
4996         (QDesktopWebViewPrivate::loadDidFail):
4997         * UIProcess/API/qt/qdesktopwebview.h:
4998         * UIProcess/API/qt/qdesktopwebview_p.h:
4999         * UIProcess/API/qt/qtouchwebpage.h:
5000         * UIProcess/API/qt/qweberror.cpp: Added.
5001         (QWebError::QWebError):
5002         (QWebErrorPrivate::createQWebError):
5003         (QWebErrorPrivate::QWebErrorPrivate):
5004         (QWebErrorPrivate::~QWebErrorPrivate):
5005         (QWebError::type):
5006         (QWebError::errorCode):
5007         (QWebError::url):
5008         * UIProcess/API/qt/qweberror.h: Added.
5009         * UIProcess/API/qt/qweberror_p.h: Added.
5010         * UIProcess/API/qt/tests/commonviewtests/tst_commonviewtests.cpp:
5011         (tst_CommonViewTests::loadNonexistentFileUrl):
5012         * UIProcess/API/qt/tests/commonviewtests/webviewabstraction.cpp:
5013         (WebViewAbstraction::WebViewAbstraction):
5014         (WebViewAbstraction::touchViewLoadFailed):
5015         (WebViewAbstraction::desktopViewLoadFailed):
5016         * UIProcess/API/qt/tests/commonviewtests/webviewabstraction.h:
5017         * UIProcess/qt/ClientImpl.cpp:
5018         (dispatchLoadSucceeded):
5019         (dispatchLoadFailed):
5020         (qt_wk_didFailProvisionalLoadWithErrorForFrame):
5021         (qt_wk_didFinishLoadForFrame):
5022         (qt_wk_didFailLoadWithErrorForFrame):
5023         * UIProcess/qt/QtWebPageProxy.cpp:
5024         (QtWebPageProxy::loadDidFail):
5025         * UIProcess/qt/QtWebPageProxy.h:
5026         * UIProcess/qt/TouchViewInterface.cpp:
5027         (WebKit::TouchViewInterface::loadDidFail):
5028         * UIProcess/qt/TouchViewInterface.h:
5029         * UIProcess/qt/ViewInterface.h:
5030         * WebKit2API.pri:
5031
5032 2011-07-12  Jocelyn Turcotte  <jocelyn.turcotte@nokia.com>
5033
5034         [Qt] Forward the touch view scale changes to the tiled drawing area.
5035         https://bugs.webkit.org/show_bug.cgi?id=64357
5036
5037         Reviewed by Kenneth Rohde Christiansen.
5038
5039         The drawing area needs to know the new scale to render tiles accordingly.
5040
5041         * UIProcess/API/qt/qtouchwebpage.cpp:
5042         (QTouchWebPagePrivate::commitScaleChange):
5043         * UIProcess/qt/qtouchwebpageproxy.cpp:
5044         (QTouchWebPageProxy::setContentsScale):
5045         * UIProcess/qt/qtouchwebpageproxy.h:
5046         (QTouchWebPageProxy::drawingArea):
5047
5048 2011-07-12  Adam Roben  <aroben@apple.com>
5049
5050         Export some symbols needed by TestWebKitAPI
5051
5052         Part of <http://webkit.org/b/63330> Concatenating string literals and WTF::Strings using
5053         operator+ is suboptimal
5054
5055         Reviewed by Darin Adler.
5056
5057         * win/WebKit2.def:
5058
5059 2011-07-11  Hironori Bono  <hbono@chromium.org>
5060
5061         Reviewed by Adam Roben.
5062
5063         Implement layoutTestController.setTextDirection for WebKit2 and Windows.
5064         https://bugs.webkit.org/show_bug.cgi?id=61931
5065
5066         This change implements layoutTextController.setTextDirection for WebKit2
5067         and Windows so we can run a layout test added by r87770 on them. Each
5068         implementation adds a wrapper function for Editor::setBaseWritingDirection()
5069         so LayoutTestController can call it.
5070
5071         * WebProcess/InjectedBundle/API/c/WKBundleFrame.cpp: Added
5072         WKBundleFrameSetTextDirection to allow LayoutTestController to change the
5073         text direction.
5074         (WKBundleFrameSetTextDirection):
5075         * WebProcess/InjectedBundle/API/c/WKBundleFramePrivate.h: ditto.
5076         * WebProcess/WebPage/WebFrame.cpp: Added setTextDirection to allow
5077         WKBundleFrame to change the text direction.
5078         (WebKit::WebFrame::setTextDirection):
5079         * WebProcess/WebPage/WebFrame.h: ditto.
5080
5081 2011-07-11  Benjamin Poulain  <benjamin@webkit.org>
5082
5083         [Qt][WK2] Get rid of focusNextPrevChild()
5084         https://bugs.webkit.org/show_bug.cgi?id=64289
5085
5086         Reviewed by Andreas Kling.
5087
5088         Qt 5 does not use focusNextPrevChild() but uses setFocusNavigation(), and
5089         the focus is not based on QWidget.
5090
5091         We can get rid of the method since the new implementation will be totally
5092         different.
5093
5094         * UIProcess/API/qt/qtouchwebpage.cpp:
5095         * UIProcess/API/qt/qtouchwebpage.h:
5096         * UIProcess/qt/ClientImpl.cpp:
5097         (qt_wk_takeFocus):
5098         * UIProcess/qt/QtWebPageProxy.h:
5099
5100 2011-07-11  Anders Carlsson  <andersca@apple.com>
5101
5102         Implement getFormValue for WebKit2
5103         https://bugs.webkit.org/show_bug.cgi?id=64294
5104         <rdar://problem/3964087>
5105
5106         Reviewed by Kevin Decker.
5107
5108         * PluginProcess/PluginControllerProxy.cpp:
5109         (WebKit::PluginControllerProxy::getFormValue):
5110         Call Plugin::getFormValue.
5111
5112         * PluginProcess/PluginControllerProxy.messages.in:
5113         Add new GetFormValue message.
5114
5115         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
5116         (WebKit::NetscapePlugin::getFormValue):
5117         Get the form value and convert it to a String.
5118
5119         * WebProcess/Plugins/Plugin.h:
5120         Add getFormValue pure virtual member function.
5121
5122         * WebProcess/Plugins/PluginProxy.cpp:
5123         (WebKit::PluginProxy::getFormValue):
5124         Send a GetFormValue message to the plug-in process.
5125
5126         * WebProcess/Plugins/PluginView.cpp:
5127         (WebKit::PluginView::getFormValue):
5128         Call Plugin::getFormValue.
5129
5130 2011-07-11  Ada Chan  <adachan@apple.com>
5131
5132         The original request should be accessible from WebNavigationData.
5133         https://bugs.webkit.org/show_bug.cgi?id=64227
5134
5135         Reviewed by Anders Carlsson.
5136
5137         * Shared/WebNavigationDataStore.h:
5138         (WebKit::WebNavigationDataStore::encode): Handle the encoding of the original request.
5139         (WebKit::WebNavigationDataStore::decode): Handle the decoding of the original request.
5140         * UIProcess/API/C/WKNavigationData.cpp:
5141         (WKNavigationDataCopyOriginalRequest): 
5142         * UIProcess/API/C/WKNavigationData.h:
5143         * UIProcess/WebNavigationData.h:
5144         (WebKit::WebNavigationData::originalRequest):
5145         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
5146         (WebKit::WebFrameLoaderClient::updateGlobalHistory): Store the original request in the WebNavigationDataStore.
5147
5148 2011-07-11  Benjamin Poulain  <benjamin@webkit.org>
5149
5150         [Qt][WK2] Forward the viewport visible area from the view instead of inferring it from the TiledDrawingAreaProxy
5151         https://bugs.webkit.org/show_bug.cgi?id=64275
5152
5153         Reviewed by Simon Hausmann.
5154
5155         This patch refactors the way the viewport visible area is handled.
5156         Previously, the TiledDrawingAreaProxy would ask for the visible rect
5157         when painting or updating. This is reversed with this patch, and the viewport
5158         informs the page of any change in the view area.
5159
5160         With this change, the TiledDrawingAreaProxy does not need to know about QTouchWebPage,
5161         and can use the TouchViewInterface directly.
5162
5163         * UIProcess/API/qt/qtouchwebpage.cpp:
5164         (QTouchWebPagePrivate::setViewportRect):
5165         * UIProcess/API/qt/qtouchwebpage.h:
5166         * UIProcess/API/qt/qtouchwebpage_p.h:
5167         * UIProcess/API/qt/qtouchwebview.cpp:
5168         (QTouchWebViewPrivate::scroll):
5169         (QTouchWebViewPrivate::viewportRectUpdated):
5170         (QTouchWebView::resizeEvent):
5171         * UIProcess/API/qt/qtouchwebview.h:
5172         * UIProcess/API/qt/qtouchwebview_p.h:
5173         * UIProcess/PageClient.h:
5174         * UIProcess/TiledDrawingAreaProxy.cpp:
5175         (WebKit::TiledDrawingAreaProxy::invalidate):
5176         (WebKit::TiledDrawingAreaProxy::paint):
5177         (WebKit::TiledDrawingAreaProxy::setVisibleArea):
5178         (WebKit::TiledDrawingAreaProxy::createTiles):
5179         * UIProcess/TiledDrawingAreaProxy.h:
5180         * UIProcess/WebPageProxy.h:
5181         * UIProcess/qt/QtWebPageProxy.cpp:
5182         * UIProcess/qt/QtWebPageProxy.h:
5183         * UIProcess/qt/TiledDrawingAreaProxyQt.cpp:
5184         (WebKit::TiledDrawingAreaProxy::updateWebView):
5185         * UIProcess/qt/TouchViewInterface.cpp:
5186         (WebKit::TouchViewInterface::contentSizeChanged):
5187         * UIProcess/qt/TouchViewInterface.h:
5188         * UIProcess/qt/WebPageProxyQt.cpp:
5189         * UIProcess/qt/qtouchwebpageproxy.cpp:
5190         (QTouchWebPageProxy::createDrawingAreaProxy):
5191         (QTouchWebPageProxy::setVisibleArea):
5192         * UIProcess/qt/qtouchwebpageproxy.h:
5193
5194 2011-07-11  Andreas Kling  <kling@webkit.org>
5195
5196         [Qt][WK2] Move zoomable-area-for-point functionality to QTouchWebPageProxy
5197         https://bugs.webkit.org/show_bug.cgi?id=64273
5198
5199         Reviewed by Kenneth Rohde Christiansen.
5200
5201         * UIProcess/qt/QtWebPageProxy.cpp:
5202         * UIProcess/qt/QtWebPageProxy.h:
5203         * UIProcess/qt/qdesktopwebpageproxy.cpp:
5204         (QDesktopWebPageProxy::didFindZoomableArea):
5205         * UIProcess/qt/qdesktopwebpageproxy.h:
5206         * UIProcess/qt/qtouchwebpageproxy.cpp:
5207         (QTouchWebPageProxy::findZoomableAreaForPoint):
5208         (QTouchWebPageProxy::didFindZoomableArea):
5209         * UIProcess/qt/qtouchwebpageproxy.h:
5210
5211 2011-07-10  Anders Carlsson  <andersca@apple.com>
5212
5213         WebKit2 is leaking NSCursors created by leakNamedCursor
5214         https://bugs.webkit.org/show_bug.cgi?id=64241
5215         <rdar://problem/9507151>
5216
5217         Reviewed by Oliver Hunt.
5218
5219         * Shared/WebCoreArgumentCoders.cpp:
5220         (CoreIPC::::decode):
5221         When decoding a cursor of a known type, make sure to eagerly create the platform cursor
5222         for the cursor singleton. This way we avoid re-creating new NSCursor objects over and over for
5223         standard cursors.
5224
5225 2011-07-10  Benjamin Poulain  <benjamin@webkit.org>
5226
5227         [Qt][WK2] Move setResizesToContentsUsingLayoutSize() to the touch specific page proxy
5228         https://bugs.webkit.org/show_bug.cgi?id=64238
5229
5230         Reviewed by Andreas Kling.
5231
5232         The method is specific to the touch view, so it should be in QTouchWebPageProxy instead
5233         of QtWebPageProxy.
5234
5235         * UIProcess/qt/QtWebPageProxy.cpp:
5236         * UIProcess/qt/QtWebPageProxy.h:
5237         * UIProcess/qt/qtouchwebpageproxy.cpp:
5238         (QTouchWebPageProxy::setResizesToContentsUsingLayoutSize):
5239         * UIProcess/qt/qtouchwebpageproxy.h:
5240
5241 2011-07-09  Noel Gordon  <noel.gordon@gmail.com>
5242
5243         Reviewed by Adam Roben.
5244
5245         [WebKit2] Forward focus events to windowless plugins on the windows port.
5246         https://bugs.webkit.org/show_bug.cgi?id=63251
5247
5248         No new tests. Covered by existing tests: plugins/mouse-events.html and
5249         plugins/keyboard-events.html.
5250
5251         * WebProcess/Plugins/Netscape/win/NetscapePluginWin.cpp:
5252         (WebKit::NetscapePlugin::platformSetFocus):
5253
5254 2011-07-08  Andreas Kling  <kling@webkit.org>
5255
5256         [Qt][WK2] Views should expose QActions for basic navigation.
5257         https://bugs.webkit.org/show_bug.cgi?id=64174
5258
5259         Add navigationAction() methods to the views to provide default
5260         QActions for Back, Forward, Stop and Reload.
5261
5262         Reviewed by Benjamin Poulain.
5263
5264         * UIProcess/API/qt/WKView.h:
5265         * UIProcess/API/qt/qdesktopwebview.cpp:
5266         (QDesktopWebView::navigationAction):
5267         * UIProcess/API/qt/qdesktopwebview.h:
5268         * UIProcess/API/qt/qtouchwebpage.cpp:
5269         (QTouchWebPage::navigationAction):
5270         * UIProcess/API/qt/qtouchwebpage.h:
5271         * UIProcess/API/qt/qwebkittypes.h: Added.
5272         * UIProcess/API/qt/tests/commonviewtests/tst_commonviewtests.cpp:
5273         (tst_CommonViewTests::backAndForward):
5274         (tst_CommonViewTests::reload):
5275         (tst_CommonViewTests::stop):
5276         * UIProcess/API/qt/tests/commonviewtests/webviewabstraction.cpp:
5277         (WebViewAbstraction::triggerNavigationAction):
5278         * UIProcess/API/qt/tests/commonviewtests/webviewabstraction.h:
5279         * UIProcess/API/qt/tests/html/basic_page2.html: Added.
5280         * UIProcess/qt/QtWebPageProxy.cpp:
5281         (QtWebPageProxy::navigationAction):
5282         * UIProcess/qt/QtWebPageProxy.h:
5283         * WebKit2API.pri:
5284
5285 2011-07-08  Benjamin Poulain  <benjamin@webkit.org>
5286
5287         [Qt][WK2] Get rid of the check for TILED_BACKING_STORE in Qt
5288         https://bugs.webkit.org/show_bug.cgi?id=64175
5289
5290         Reviewed by Kenneth Rohde Christiansen.
5291
5292         Qt no longer supports building WebKit2 without TILED_BACKING_STORE.
5293
5294         * UIProcess/API/qt/qtouchwebpage.cpp:
5295         (QTouchWebPagePrivate::onScaleChanged):
5296         * UIProcess/qt/QtWebPageProxy.cpp:
5297         (QtWebPageProxy::setResizesToContentsUsingLayoutSize):
5298         * UIProcess/qt/TiledDrawingAreaProxyQt.cpp:
5299         * UIProcess/qt/TiledDrawingAreaTileQt.cpp:
5300         * WebProcess/WebPage/qt/TiledDrawingAreaQt.cpp:
5301
5302 2011-07-08  Benjamin Poulain  <benjamin@webkit.org>
5303
5304         [WK2] Do not forward touch events to the web process when it does not need them
5305         https://bugs.webkit.org/show_bug.cgi?id=64164
5306
5307         Reviewed by Kenneth Rohde Christiansen.
5308
5309         The call to ChromeClient::needTouchEvent() is now forwarded to the WebPageProxy
5310         to change the way events are delivered.
5311
5312         When the WebPage does not need touch events, and there is no queued touch events,
5313         the incoming events just bounce back through PageClient::doneWithTouchEvent().
5314
5315         In the case when new events come to WebPageProxy and there are still touch events
5316         incoming from the WebProcess, the new events are deferred with the corresponding
5317         pending touch events.
5318         Deferring the new events iafter the corresponding forwarded event ensure
5319         the delivery is always done in order when PageClient::doneWithTouchEvent()
5320         is called.
5321
5322         * UIProcess/WebPageProxy.cpp:
5323         (WebKit::WebPageProxy::WebPageProxy):
5324         (WebKit::WebPageProxy::handleTouchEvent):
5325         (WebKit::WebPageProxy::needTouchEvents):
5326         (WebKit::WebPageProxy::didReceiveEvent):
5327         (WebKit::WebPageProxy::processDidCrash):
5328         * UIProcess/WebPageProxy.h:
5329         (WebKit::QueuedTouchEvents:::forwardedEvent):
5330         * UIProcess/WebPageProxy.messages.in:
5331         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
5332         (WebKit::WebChromeClient::needTouchEvents):
5333
5334 2011-07-08  Benjamin Poulain  <benjamin@webkit.org>
5335
5336         [Qt][WK2] Add basic support for panning gestures to the QTouchWebView
5337         https://bugs.webkit.org/show_bug.cgi?id=64105
5338
5339         Reviewed by Kenneth Rohde Christiansen.
5340
5341         This patch adds basic support for the panning gesture on the UI process side.
5342
5343         The events coming back from the WebProcess are processed through
5344         the QtPanGestureRecognizer to recognize the pan gesture. When the
5345         gesture is recognized, the actions are performed on the view through
5346         the TouchViewInterface.
5347
5348         Currently, the viewport just move the page around without limit.
5349         This will be improved when a physics engine is integrated.
5350
5351         * UIProcess/API/qt/qtouchwebview.cpp:
5352         (QTouchWebViewPrivate::scroll):
5353         * UIProcess/API/qt/qtouchwebview.h:
5354         * UIProcess/API/qt/qtouchwebview_p.h:
5355         * UIProcess/qt/QtPanGestureRecognizer.cpp: Added.
5356         (WebKit::QtPanGestureRecognizer::QtPanGestureRecognizer):
5357         (WebKit::QtPanGestureRecognizer::recognize):
5358         (WebKit::QtPanGestureRecognizer::reset):
5359         * UIProcess/qt/QtPanGestureRecognizer.h: Added.
5360         * UIProcess/qt/TouchViewInterface.cpp:
5361         (WebKit::TouchViewInterface::panGestureStarted):
5362         (WebKit::TouchViewInterface::panGestureRequestScroll):
5363         (WebKit::TouchViewInterface::panGestureEnded):
5364         (WebKit::TouchViewInterface::panGestureCancelled):
5365         * UIProcess/qt/TouchViewInterface.h:
5366         * UIProcess/qt/qtouchwebpageproxy.cpp:
5367         (QTouchWebPageProxy::QTouchWebPageProxy):
5368         (QTouchWebPageProxy::processDidCrash):
5369         (QTouchWebPageProxy::doneWithTouchEvent):
5370         * UIProcess/qt/qtouchwebpageproxy.h:
5371         * WebKit2.pro:
5372
5373 2011-07-07  Andreas Kling  <kling@webkit.org>
5374
5375         [Qt][WK2] Remove Symbian code.
5376         https://bugs.webkit.org/show_bug.cgi?id=64101
5377
5378         Reviewed by Benjamin Poulain.
5379
5380         * DerivedSources.pro:
5381         * Platform/CoreIPC/Attachment.h:
5382         * Platform/CoreIPC/Connection.h:
5383         * Platform/SharedMemory.h:
5384         * Platform/qt/SharedMemorySymbian.cpp: Removed.
5385         * UIProcess/API/qt/tests/tests.pri:
5386         * UIProcess/Launcher/qt/ProcessLauncherQt.cpp:
5387         * WebKit2.pri:
5388         * WebKit2.pro:
5389         * WebProcess.pro:
5390         * config.h:
5391
5392 2011-07-07  Andreas Kling  <kling@webkit.org>
5393
5394         [Qt][WK2] Don't support ridiculous matrix of QT_NO_FEATURE combinations.
5395         https://bugs.webkit.org/show_bug.cgi?id=64099
5396
5397         Reviewed by Benjamin Poulain.
5398
5399         * Shared/qt/WebEventFactoryQt.cpp:
5400         (WebKit::WebEventFactory::createWebWheelEvent):
5401         * UIProcess/API/qt/qdesktopwebview_p.h:
5402         * UIProcess/qt/QtWebPageProxy.cpp:
5403         (QtWebPageProxy::QtWebPageProxy):
5404         (QtWebPageProxy::setCursor):
5405         (QtWebPageProxy::registerEditCommand):
5406         (QtWebPageProxy::clearAllEditCommands):
5407         (QtWebPageProxy::canUndoRedo):
5408         (QtWebPageProxy::executeUndoRedo):
5409         (QtWebPageProxy::updateAction):
5410         (QtWebPageProxy::webActionTriggered):
5411         (QtWebPageProxy::triggerAction):
5412         (QtWebPageProxy::action):
5413         * UIProcess/qt/QtWebPageProxy.h:
5414         * UIProcess/qt/TouchViewInterface.cpp:
5415         (WebKit::TouchViewInterface::didChangeCursor):
5416         * UIProcess/qt/TouchViewInterface.h:
5417         * UIProcess/qt/ViewInterface.h:
5418         * UIProcess/qt/WebUndoCommandQt.cpp:
5419         (WebUndoCommandQt::WebUndoCommandQt):
5420         * UIProcess/qt/WebUndoCommandQt.h:
5421         * WebProcess/WebCoreSupport/qt/WebDragClientQt.cpp:
5422         (WebKit::WebDragClient::startDrag):
5423
5424 2011-07-07  Andreas Kling  <kling@webkit.org>
5425
5426         [Qt][WK2] Views should know about WebProcess crash/relaunch.
5427         https://bugs.webkit.org/show_bug.cgi?id=64093
5428
5429         Reviewed by Benjamin Poulain.
5430
5431         Add processDidCrash() and didRelaunchProcess() to ViewInterface.
5432
5433         QDesktopWebView now displays a simple sad smiley ":(" when the
5434         web process crashes.
5435
5436         * UIProcess/API/qt/qdesktopwebview.cpp:
5437         (QDesktopWebViewPrivate::QDesktopWebViewPrivate):
5438         (paintCrashedPage):
5439         (QDesktopWebView::paint):
5440         (QDesktopWebViewPrivate::processDidCrash):
5441         (QDesktopWebViewPrivate::didRelaunchProcess):
5442         * UIProcess/API/qt/qdesktopwebview_p.h:
5443         * UIProcess/qt/QtWebPageProxy.cpp:
5444         (QtWebPageProxy::QtWebPageProxy):
5445         (QtWebPageProxy::didRelaunchProcess):
5446         (QtWebPageProxy::processDidCrash):
5447         * UIProcess/qt/QtWebPageProxy.h:
5448         * UIProcess/qt/TouchViewInterface.cpp:
5449         (WebKit::TouchViewInterface::showContextMenu):
5450         (WebKit::TouchViewInterface::hideContextMenu):
5451         (WebKit::TouchViewInterface::processDidCrash):
5452         (WebKit::TouchViewInterface::didRelaunchProcess):
5453         * UIProcess/qt/TouchViewInterface.h:
5454         * UIProcess/qt/ViewInterface.h:
5455
5456 2011-07-07  Benjamin Poulain  <benjamin@webkit.org>
5457
5458         [Qt] [WK2] Improve the handling of touch events to use them as main input
5459         https://bugs.webkit.org/show_bug.cgi?id=63991
5460
5461         Reviewed by Kenneth Rohde Christiansen.
5462
5463         Promote touch event for use as primary input.
5464
5465         The touch events now use the responsiveness timer like the other input events.
5466
5467         The touch events also have a callback to the UI signaling if the event was used
5468         or not: PageClient::doneWithTouchEvent().
5469         This is similar to what is done with key events (PageClient::doneWithKeyEvent()).
5470
5471         * Shared/NativeWebTouchEvent.h: Copied from Source/WebKit2/Shared/qt/WebEventFactoryQt.h.
5472         (WebKit::NativeWebTouchEvent::nativeEvent):
5473         * Shared/qt/NativeWebTouchEventQt.cpp: Copied from Source/WebKit2/Shared/qt/WebEventFactoryQt.h.
5474         (WebKit::NativeWebTouchEvent::NativeWebTouchEvent):
5475         * Shared/qt/WebEventFactoryQt.cpp:
5476         (WebKit::webEventTypeForEvent):
5477         (WebKit::WebEventFactory::createWebTouchEvent):
5478         * Shared/qt/WebEventFactoryQt.h:
5479         * UIProcess/PageClient.h:
5480         * UIProcess/WebPageProxy.cpp:
5481         (WebKit::WebPageProxy::handleTouchEvent):
5482         (WebKit::WebPageProxy::didReceiveEvent):
5483         * UIProcess/WebPageProxy.h:
5484         * UIProcess/qt/qdesktopwebpageproxy.cpp:
5485         (QDesktopWebPageProxy::doneWithTouchEvent):
5486         * UIProcess/qt/qdesktopwebpageproxy.h:
5487         * UIProcess/qt/qtouchwebpageproxy.cpp:
5488         (QTouchWebPageProxy::doneWithTouchEvent):
5489         (QTouchWebPageProxy::touchEvent):
5490         * UIProcess/qt/qtouchwebpageproxy.h:
5491         * WebKit2.pro:
5492
5493 2011-07-06  Andreas Kling  <kling@webkit.org>
5494
5495         [Qt][WK2] Split Qt API into two different web views (touch and desktop)
5496         https://bugs.webkit.org/show_bug.cgi?id=63950
5497
5498         Co-authored with Benjamin Poulain <benjamin@webkit.org>.
5499
5500         Reviewed by Kenneth Rohde Christiansen.
5501
5502         Replace the QGraphicsWKView/QWKPage mess with QDesktopWebView and QTouchWebView.
5503
5504         QDesktopWebView is a traditional web view, similar to QGraphicsWebView. It will
5505         will have the expected "desktop" behavior for things like subframes and
5506         fixed-position elements.
5507
5508         QTouchWebView is intended for use on touch devices, and will manage the viewport,
5509         gestures, tiled rendering, and other things that the user should never have to
5510         worry about. It will use "resize to contents" and frame flattening by default.
5511
5512         API-wise, the biggest difference between the two is that QTouchWebView is really
5513         a viewport that contains a QTouchWebPage. These are decoupled for flexibility in
5514         UI design. This decoupling is not necessary for the desktop use-case, and so
5515         QDesktopWebView is the only class we need.
5516
5517         Much of the Qt/WebKit2 API has been removed (snapshots, history, preferences..)
5518         but will be re-added incrementally in a way that fits the new API vision.
5519
5520         * UIProcess/API/qt/WKView.h:
5521         * UIProcess/API/qt/qdesktopwebview.cpp: Added.
5522         (QDesktopWebViewPrivate::QDesktopWebViewPrivate):
5523         (QDesktopWebViewPrivate::setViewNeedsDisplay):
5524         (QDesktopWebViewPrivate::drawingAreaSize):
5525         (QDesktopWebViewPrivate::contentSizeChanged):
5526         (QDesktopWebViewPrivate::isActive):
5527         (QDesktopWebViewPrivate::hasFocus):
5528         (QDesktopWebViewPrivate::isVisible):
5529         (QDesktopWebViewPrivate::startDrag):
5530         (QDesktopWebViewPrivate::didChangeUrl):
5531         (QDesktopWebViewPrivate::didChangeTitle):
5532         (QDesktopWebViewPrivate::didChangeToolTip):
5533         (QDesktopWebViewPrivate::didChangeStatusText):
5534         (QDesktopWebViewPrivate::didChangeCursor):
5535         (QDesktopWebViewPrivate::loadDidBegin):
5536         (QDesktopWebViewPrivate::loadDidSucceed):
5537         (QDesktopWebViewPrivate::didChangeLoadProgress):
5538         (QDesktopWebViewPrivate::showContextMenu):
5539         (QDesktopWebViewPrivate::hideContextMenu):
5540         (QDesktopWebView::QDesktopWebView):
5541         (QDesktopWebView::init):
5542         (QDesktopWebView::~QDesktopWebView):
5543         (QDesktopWebView::load):
5544         (QDesktopWebView::url):
5545         (QDesktopWebView::title):
5546         (QDesktopWebView::resizeEvent):
5547         (QDesktopWebView::paint):
5548         (QDesktopWebView::event):
5549         (QDesktopWebView::pageRef):
5550         * UIProcess/API/qt/qdesktopwebview.h: Added.
5551         * UIProcess/API/qt/qdesktopwebview_p.h: Added.
5552         * UIProcess/API/qt/qgraphicswkview.cpp: Removed.
5553         * UIProcess/API/qt/qgraphicswkview.h: Removed.
5554         * UIProcess/API/qt/qtouchwebpage.cpp: Added.
5555         (QTouchWebPage::QTouchWebPage):
5556         (QTouchWebPage::~QTouchWebPage):
5557         (QTouchWebPage::paint):
5558         (QTouchWebPage::load):
5559         (QTouchWebPage::url):
5560         (QTouchWebPage::title):
5561         (QTouchWebPage::focusNextPrevChildCallback):
5562         (QTouchWebPage::focusNextPrevChild):
5563         (QTouchWebPage::event):
5564         (QTouchWebPage::timerEvent):
5565         (QTouchWebPage::resizeEvent):
5566         (QTouchWebPagePrivate::QTouchWebPagePrivate):
5567         (QTouchWebPage::visibleRect):
5568         (QTouchWebPagePrivate::prepareScaleChange):
5569         (QTouchWebPagePrivate::commitScaleChange):
5570         (QTouchWebPagePrivate::onScaleChanged):
5571         (QTouchWebPagePrivate::setPage):
5572         * UIProcess/API/qt/qtouchwebpage.h: Added.
5573         * UIProcess/API/qt/qtouchwebpage_p.h: Added.
5574         (QTouchWebPagePrivate::getPageViewPrivate):
5575         * UIProcess/API/qt/qtouchwebview.cpp: Added.
5576         (QTouchWebViewPrivate::QTouchWebViewPrivate):
5577         (QTouchWebView::QTouchWebView):
5578         (QTouchWebView::~QTouchWebView):
5579         (QTouchWebView::page):
5580         * UIProcess/API/qt/qtouchwebview.h: Added.
5581         * UIProcess/API/qt/qtouchwebview_p.h: Added.
5582         * UIProcess/API/qt/qwkpage.cpp: Removed.
5583         * UIProcess/API/qt/qwkpage.h: Removed.
5584         * UIProcess/API/qt/tests/commonviewtests/commonviewtests.pro: Added.
5585         * UIProcess/API/qt/tests/commonviewtests/tst_commonviewtests.cpp: Added.
5586         (tst_CommonViewTests::init):
5587         (tst_CommonViewTests::cleanup):
5588         (tst_CommonViewTests::baseUrl):
5589         (tst_CommonViewTests::loadEmptyUrl):
5590         (tst_CommonViewTests::loadEmptyPageViewVisible):
5591         (tst_CommonViewTests::loadEmptyPageViewHidden):
5592         (tst_CommonViewTests::show):
5593         * UIProcess/API/qt/tests/commonviewtests/webviewabstraction.cpp: Added.
5594         (WebViewAbstraction::WebViewAbstraction):
5595         (WebViewAbstraction::show):
5596         (WebViewAbstraction::hide):
5597         (WebViewAbstraction::load):
5598         (WebViewAbstraction::url):
5599         (WebViewAbstraction::touchViewLoadStarted):
5600         (WebViewAbstraction::desktopViewLoadStarted):
5601         (WebViewAbstraction::touchViewLoadSucceeded):
5602         (WebViewAbstraction::desktopViewLoadSucceeded):
5603         (WebViewAbstraction::touchWebView):
5604         (WebViewAbstraction::desktopWebView):
5605         * UIProcess/API/qt/tests/commonviewtests/webviewabstraction.h: Copied from Source/WebKit2/UIProcess/API/qt/tests/qwkpage/tst_qwkpage.cpp.
5606         * UIProcess/API/qt/tests/html/a.htm: Removed.
5607         * UIProcess/API/qt/tests/html/b.htm: Removed.
5608         * UIProcess/API/qt/tests/html/c.htm: Removed.
5609         * UIProcess/API/qt/tests/html/d.htm: Removed.
5610         * UIProcess/API/qt/tests/qdesktopwebview/qdesktopwebview.pro: Renamed from Source/WebKit2/UIProcess/API/qt/tests/qgraphicswkview/qgraphicswkview.pro.
5611         * UIProcess/API/qt/tests/qdesktopwebview/tst_qdesktopwebview.cpp: Renamed from Source/WebKit2/UIProcess/API/qt/tests/qwkpage/tst_qwkpage.cpp.
5612         (tst_QDesktopWebView::init):
5613         (tst_QDesktopWebView::cleanup):
5614         (tst_QDesktopWebView::webView):
5615         * UIProcess/API/qt/tests/qgraphicswkview/tst_qgraphicswkview.cpp: Removed.
5616         * UIProcess/API/qt/tests/qtouchwebview/qtouchwebview.pro: Renamed from Source/WebKit2/UIProcess/API/qt/tests/qwkhistory/qwkhistory.pro.
5617         * UIProcess/API/qt/tests/qtouchwebview/tst_qtouchwebview.cpp: Added.
5618         (tst_QTouchWebView::tst_QTouchWebView):
5619         (tst_QTouchWebView::init):
5620         (tst_QTouchWebView::cleanup):
5621         (tst_QTouchWebView::webView):
5622         (tst_QTouchWebView::accessPage):
5623         * UIProcess/API/qt/tests/qwkhistory/tst_qwkhistory.cpp: Removed.
5624         * UIProcess/API/qt/tests/qwkpage/qwkpage.pro: Removed.
5625         * UIProcess/API/qt/tests/tests.pro:
5626         * UIProcess/API/qt/tests/testwindow.h: Added.
5627         (TestWindow::TestWindow):
5628         (TestWindow::resizeEvent):
5629         * UIProcess/TiledDrawingAreaProxy.cpp:
5630         * UIProcess/TiledDrawingAreaProxy.h:
5631         * UIProcess/WebFullScreenManagerProxy.h:
5632         * UIProcess/qt/ClientImpl.cpp: Renamed from Source/WebKit2/UIProcess/API/qt/ClientImpl.cpp.
5633         (toQWKContext):
5634         (toQtWebPageProxy):
5635         (loadFinished):
5636         (qt_wk_didStartProvisionalLoadForFrame):
5637         (qt_wk_didReceiveServerRedirectForProvisionalLoadForFrame):
5638         (qt_wk_didFailProvisionalLoadWithErrorForFrame):
5639         (qt_wk_didCommitLoadForFrame):
5640         (qt_wk_didFinishDocumentLoadForFrame):
5641         (qt_wk_didFinishLoadForFrame):
5642         (qt_wk_didFailLoadWithErrorForFrame):
5643         (qt_wk_didReceiveTitleForFrame):
5644         (qt_wk_didFirstLayoutForFrame):
5645         (qt_wk_didRemoveFrameFromHierarchy):
5646         (qt_wk_didFirstVisuallyNonEmptyLayoutForFrame):
5647         (qt_wk_didStartProgress):
5648         (qt_wk_didChangeProgress):
5649         (qt_wk_didFinishProgress):
5650         (qt_wk_didBecomeUnresponsive):
5651         (qt_wk_didBecomeResponsive):
5652         (qt_wk_createNewPage):
5653         (qt_wk_showPage):
5654         (qt_wk_close):
5655         (qt_wk_takeFocus):
5656         (qt_wk_runJavaScriptAlert):
5657         (qt_wk_setStatusText):
5658         (qt_wk_didSameDocumentNavigationForFrame):
5659         (qt_wk_didChangeIconForPageURL):
5660         (qt_wk_didRemoveAllIcons):
5661         * UIProcess/qt/ClientImpl.h: Renamed from Source/WebKit2/UIProcess/API/qt/ClientImpl.h.
5662         * UIProcess/qt/QtWebPageProxy.cpp: Added.
5663         (defaultWKContext):
5664         (contextMenuActionForWebAction):
5665         (dragOperationToDropActions):
5666         (dropActionToDragOperation):
5667         (QtWebPageProxy::QtWebPageProxy):
5668         (QtWebPageProxy::init):
5669         (QtWebPageProxy::~QtWebPageProxy):
5670         (QtWebPageProxy::handleEvent):
5671         (QtWebPageProxy::handleKeyPressEvent):
5672         (QtWebPageProxy::handleKeyReleaseEvent):
5673         (QtWebPageProxy::handleFocusInEvent):
5674         (QtWebPageProxy::handleFocusOutEvent):
5675         (QtWebPageProxy::setCursor):
5676         (QtWebPageProxy::setViewNeedsDisplay):
5677         (QtWebPageProxy::displayView):
5678         (QtWebPageProxy::scrollView):
5679         (QtWebPageProxy::viewSize):
5680         (QtWebPageProxy::isViewWindowActive):
5681         (QtWebPageProxy::isViewFocused):
5682         (QtWebPageProxy::isViewVisible):
5683         (QtWebPageProxy::isViewInWindow):
5684         (QtWebPageProxy::enterAcceleratedCompositingMode):
5685         (QtWebPageProxy::exitAcceleratedCompositingMode):
5686         (QtWebPageProxy::pageDidRequestScroll):
5687         (QtWebPageProxy::didChangeContentsSize):
5688         (QtWebPageProxy::toolTipChanged):
5689         (QtWebPageProxy::registerEditCommand):
5690         (QtWebPageProxy::clearAllEditCommands):
5691         (QtWebPageProxy::canUndoRedo):
5692         (QtWebPageProxy::executeUndoRedo):
5693         (QtWebPageProxy::convertToDeviceSpace):
5694         (QtWebPageProxy::screenToWindow):
5695         (QtWebPageProxy::windowToScreen):
5696         (QtWebPageProxy::convertToUserSpace):
5697         (QtWebPageProxy::selectionChanged):
5698         (QtWebPageProxy::doneWithKeyEvent):
5699         (QtWebPageProxy::createPopupMenuProxy):
5700         (QtWebPageProxy::createContextMenuProxy):
5701         (QtWebPageProxy::setFindIndicator):
5702         (QtWebPageProxy::didCommitLoadForMainFrame):
5703         (QtWebPageProxy::didFinishLoadingDataForCustomRepresentation):
5704         (QtWebPageProxy::flashBackingStoreUpdates):
5705         (QtWebPageProxy::pageRef):
5706         (QtWebPageProxy::didChangeUrl):
5707         (QtWebPageProxy::didChangeTitle):
5708         (QtWebPageProxy::didChangeStatusText):
5709         (QtWebPageProxy::showContextMenu):
5710         (QtWebPageProxy::hideContextMenu):
5711         (QtWebPageProxy::loadDidBegin):
5712         (QtWebPageProxy::loadDidSucceed):
5713         (QtWebPageProxy::didChangeLoadProgress):
5714         (QtWebPageProxy::paint):
5715         (QtWebPageProxy::updateAction):
5716         (QtWebPageProxy::updateNavigationActions):
5717         (QtWebPageProxy::webActionTriggered):
5718         (QtWebPageProxy::didRelaunchProcess):
5719         (QtWebPageProxy::processDidCrash):
5720         (QtWebPageProxy::setActualVisibleContentsRect):
5721         (QtWebPageProxy::preferences):
5722         (QtWebPageProxy::setCreateNewPageFunction):
5723         (QtWebPageProxy::setCustomUserAgent):
5724         (QtWebPageProxy::customUserAgent):
5725         (QtWebPageProxy::load):
5726         (QtWebPageProxy::url):
5727         (QtWebPageProxy::title):
5728         (QtWebPageProxy::setDrawingAreaSize):
5729         (QtWebPageProxy::textZoomFactor):
5730         (QtWebPageProxy::setTextZoomFactor):
5731         (QtWebPageProxy::pageZoomFactor):
5732         (QtWebPageProxy::setPageZoomFactor):
5733         (QtWebPageProxy::setPageAndTextZoomFactors):
5734         (QtWebPageProxy::history):
5735         (QtWebPageProxy::setResizesToContentsUsingLayoutSize):
5736         (QtWebPageProxy::triggerAction):
5737         (QtWebPageProxy::action):
5738         (QtWebPageProxy::findZoomableAreaForPoint):
5739         (QtWebPageProxy::didFindZoomableArea):
5740         (QtWebPageProxy::startDrag):
5741         (QtWebPageProxy::viewportVisibleRect):
5742         (QtWebPageProxy::isConnectedToEngine):
5743         (QtWebPageProxy::setPageIsVisible):
5744         * UIProcess/qt/QtWebPageProxy.h: Renamed from Source/WebKit2/UIProcess/API/qt/qwkpage_p.h.
5745         (QtWebPageProxy::pageClosed):
5746         (QtWebPageProxy::customRepresentationZoomFactor):
5747         (QtWebPageProxy::setCustomRepresentationZoomFactor):
5748         (QtWebPageProxy::didChangeScrollbarsForMainFrame):
5749         (QtWebPageProxy::findStringInCustomRepresentation):
5750         (QtWebPageProxy::countStringMatchesInCustomRepresentation):
5751         (QtWebPageProxy::userSpaceScaleFactor):
5752         (QtWebPageProxy::createNewPageFunction):
5753         * UIProcess/qt/TiledDrawingAreaProxyQt.cpp:
5754         (WebKit::TiledDrawingAreaProxy::page):
5755         * UIProcess/qt/TouchViewInterface.cpp: Added.
5756         (WebKit::TouchViewInterface::TouchViewInterface):
5757         (WebKit::TouchViewInterface::setViewNeedsDisplay):
5758         (WebKit::TouchViewInterface::drawingAreaSize):
5759         (WebKit::TouchViewInterface::contentSizeChanged):
5760         (WebKit::TouchViewInterface::isActive):
5761         (WebKit::TouchViewInterface::hasFocus):
5762         (WebKit::TouchViewInterface::isVisible):
5763         (WebKit::TouchViewInterface::startDrag):
5764         (WebKit::TouchViewInterface::didChangeUrl):
5765         (WebKit::TouchViewInterface::didChangeTitle):
5766         (WebKit::TouchViewInterface::didChangeToolTip):
5767         (WebKit::TouchViewInterface::didChangeStatusText):
5768         (WebKit::TouchViewInterface::didChangeCursor):
5769         (WebKit::TouchViewInterface::loadDidBegin):
5770         (WebKit::TouchViewInterface::loadDidSucceed):
5771         (WebKit::TouchViewInterface::didChangeLoadProgress):
5772         (WebKit::TouchViewInterface::showContextMenu):
5773         (WebKit::TouchViewInterface::hideContextMenu):
5774         * UIProcess/qt/TouchViewInterface.h: Added.
5775         (WebKit::TouchViewInterface::pageView):
5776         * UIProcess/qt/ViewInterface.cpp: Added.
5777         (WebKit::ViewInterface::ownerWidget):
5778         * UIProcess/qt/ViewInterface.h: Added.
5779         * UIProcess/qt/WebContextMenuProxyQt.cpp:
5780         (WebKit::webActionForContextMenuAction):
5781         (WebKit::WebContextMenuProxyQt::WebContextMenuProxyQt):
5782         (WebKit::WebContextMenuProxyQt::create):
5783         (WebKit::WebContextMenuProxyQt::showContextMenu):
5784         (WebKit::WebContextMenuProxyQt::hideContextMenu):
5785         (WebKit::WebContextMenuProxyQt::createContextMenu):
5786         * UIProcess/qt/WebContextMenuProxyQt.h:
5787         * UIProcess/qt/qdesktopwebpageproxy.cpp: Added.
5788         (dragOperationToDropAction):
5789         (QDesktopWebPageProxy::QDesktopWebPageProxy):
5790         (QDesktopWebPageProxy::createDrawingAreaProxy):
5791         (QDesktopWebPageProxy::paintContent):
5792         (QDesktopWebPageProxy::setViewportArguments):
5793         (QDesktopWebPageProxy::handleEvent):
5794         (QDesktopWebPageProxy::handleMouseMoveEvent):
5795         (QDesktopWebPageProxy::handleMousePressEvent):
5796         (QDesktopWebPageProxy::handleMouseReleaseEvent):
5797         (QDesktopWebPageProxy::handleMouseDoubleClickEvent):
5798         (QDesktopWebPageProxy::handleWheelEvent):
5799         (QDesktopWebPageProxy::handleHoverMoveEvent):
5800         (QDesktopWebPageProxy::handleDragEnterEvent):
5801         (QDesktopWebPageProxy::handleDragLeaveEvent):
5802         (QDesktopWebPageProxy::handleDragMoveEvent):
5803         (QDesktopWebPageProxy::handleDropEvent):
5804         (QDesktopWebPageProxy::timerEvent):
5805         * UIProcess/qt/qdesktopwebpageproxy.h: Added.
5806         * UIProcess/qt/qtouchwebpageproxy.cpp: Added.
5807         (QTouchWebPageProxy::QTouchWebPageProxy):
5808         (QTouchWebPageProxy::createDrawingAreaProxy):
5809         (QTouchWebPageProxy::paintContent):
5810         (QTouchWebPageProxy::setViewportArguments):
5811         (QTouchWebPageProxy::handleEvent):
5812         (QTouchWebPageProxy::touchEvent):
5813         * UIProcess/qt/qtouchwebpageproxy.h: Added.
5814         (QTouchWebPageProxy::touchViewInterface):
5815         (QTouchWebPageProxy::pageView):
5816         * UIProcess/qt/qwkcontext.cpp: Renamed from Source/WebKit2/UIProcess/API/qt/qwkcontext.cpp.
5817         (initializePlatformStrategiesIfNeeded):
5818         (QWKContextPrivate::QWKContextPrivate):
5819         (QWKContextPrivate::~QWKContextPrivate):
5820         (QWKContext::QWKContext):
5821         (QWKContext::~QWKContext):
5822         (QWKContext::setIconDatabasePath):
5823         (QWKContext::iconForPageURL):
5824         * UIProcess/qt/qwkcontext.h: Renamed from Source/WebKit2/UIProcess/API/qt/qwkcontext.h.
5825         * UIProcess/qt/qwkcontext_p.h: Renamed from Source/WebKit2/UIProcess/API/qt/qwkcontext_p.h.
5826         * UIProcess/qt/qwkhistory.cpp: Renamed from Source/WebKit2/UIProcess/API/qt/qwkhistory.cpp.
5827         (QWKHistoryItemPrivate::QWKHistoryItemPrivate):
5828         (QWKHistoryItemPrivate::~QWKHistoryItemPrivate):
5829         (QWKHistoryItem::QWKHistoryItem):
5830         (QWKHistoryItem::QWKHistoryItem::operator=):
5831         (QWKHistoryItem::~QWKHistoryItem):
5832         (QWKHistoryItem::title):
5833         (QWKHistoryItem::url):
5834         (QWKHistoryPrivate::QWKHistoryPrivate):
5835         (QWKHistoryPrivate::createHistory):
5836         (QWKHistoryPrivate::~QWKHistoryPrivate):
5837         (QWKHistory::QWKHistory):
5838         (QWKHistory::~QWKHistory):
5839         (QWKHistory::backListCount):
5840         (QWKHistory::forwardListCount):
5841         (QWKHistory::count):
5842         (QWKHistory::currentItem):
5843         (QWKHistory::backItem):
5844         (QWKHistory::forwardItem):
5845         (QWKHistory::itemAt):
5846         (QWKHistory::goToItemAt):
5847         (QWKHistory::backItems):
5848         (QWKHistory::forwardItems):
5849         * UIProcess/qt/qwkhistory.h: Renamed from Source/WebKit2/UIProcess/API/qt/qwkhistory.h.
5850         * UIProcess/qt/qwkhistory_p.h: Renamed from Source/WebKit2/UIProcess/API/qt/qwkhistory_p.h.
5851         * UIProcess/qt/qwkpreferences.cpp: Renamed from Source/WebKit2/UIProcess/API/qt/qwkpreferences.cpp.
5852         (QWKPreferencesPrivate::createPreferences):
5853         (QWKPreferencesPrivate::createSharedPreferences):
5854         (QWKPreferences::sharedPreferences):
5855         (QWKPreferences::QWKPreferences):
5856         (QWKPreferences::~QWKPreferences):
5857         (QWKPreferences::setFontFamily):
5858         (QWKPreferences::fontFamily):
5859         (QWKPreferences::testAttribute):
5860         (QWKPreferences::setAttribute):
5861         (QWKPreferences::setFontSize):
5862         (QWKPreferences::fontSize):
5863         * UIProcess/qt/qwkpreferences.h: Renamed from Source/WebKit2/UIProcess/API/qt/qwkpreferences.h.
5864         * UIProcess/qt/qwkpreferences_p.h: Renamed from Source/WebKit2/UIProcess/API/qt/qwkpreferences_p.h.
5865         * WebKit2.pro:
5866         * WebKit2API.pri:
5867         * WebProcess/WebPage/TiledDrawingArea.cpp:
5868         * WebProcess/WebPage/TiledDrawingArea.h:
5869
5870 2011-07-05  Jeff Miller  <jeffm@apple.com>
5871
5872         Add WKPageCopyStandardUserAgentWithApplicationName
5873         https://bugs.webkit.org/show_bug.cgi?id=63953
5874
5875         Reviewed by Adam Roben.
5876
5877          * UIProcess/API/C/WKPage.cpp:
5878         (WKPageCopyStandardUserAgentWithApplicationName): Added.
5879         * UIProcess/API/C/WKPagePrivate.h: Added WKPageCopyStandardUserAgentWithApplicationName().
5880
5881         * UIProcess/WebPageProxy.h: Make standardUserAgent() public.
5882
5883 2011-07-05  Vsevolod Vlasov  <vsevik@chromium.org>
5884
5885         Web Inspector: Show content for plugin requests in network panel.
5886         https://bugs.webkit.org/show_bug.cgi?id=30080
5887
5888         Added win symbols for new window.internals methods.
5889
5890         Reviewed by Pavel Feldman.
5891
5892         * win/WebKit2.def:
5893         * win/WebKit2CFLite.def:
5894
5895 2011-07-04  Sheriff Bot  <webkit.review.bot@gmail.com>
5896
5897         Unreviewed, rolling out r90373.
5898         http://trac.webkit.org/changeset/90373
5899         https://bugs.webkit.org/show_bug.cgi?id=63917
5900
5901         Breaks Qt Linux Release minimal (Requested by vsevik on
5902         #webkit).
5903
5904         * win/WebKit2.def:
5905         * win/WebKit2CFLite.def:
5906
5907 2011-07-04  Vsevolod Vlasov  <vsevik@chromium.org>
5908
5909         Web Inspector: Show content for plugin requests in network panel.
5910         https://bugs.webkit.org/show_bug.cgi?id=30080
5911
5912         Reviewed by Pavel Feldman.
5913
5914         * win/WebKit2.def:
5915         * win/WebKit2CFLite.def:
5916
5917 2011-07-04  Anders Carlsson  <andersca@apple.com>
5918
5919         NP_RemoveProperty is not called back by Safari when delete npObject.prop is encountered in JavaScript
5920         https://bugs.webkit.org/show_bug.cgi?id=63915
5921         <rdar://problem/7124300>
5922
5923         Reviewed by Sam Weinig.
5924
5925         * WebProcess/Plugins/Netscape/JSNPObject.cpp:
5926         (WebKit::JSNPObject::deleteProperty):
5927         Call NP_RemoveProperty on the NPObject.
5928
5929         * WebProcess/Plugins/Netscape/JSNPObject.h:
5930         Add deleteProperty.
5931
5932 2011-06-23  Robert Hogan  <robert@webkit.org>
5933
5934         Reviewed by Simon Hausmann.
5935
5936         [Qt] Windowless Plugins : <input> cursor blinks even after transferring focus to plugin
5937         https://bugs.webkit.org/show_bug.cgi?id=30355
5938
5939         PluginView needs to use page->focusController()->setFocusedNode() when focusing a plugin
5940         in order to clear the FrameSelection in the currently focused node. In its platform-specific
5941         code Chromium already does this (WebPluginContainerImpl.cpp).
5942
5943         * WebProcess/Plugins/PluginView.cpp:
5944         (WebCore::PluginView::focusPluginElement): Using FocusController::setFocusedNode() makes
5945                                                    the call to FocusController:setFocusedFrame() redundant, since the
5946                                                    former calls it.
5947
5948 2011-07-02  Anders Carlsson  <andersca@apple.com>
5949
5950         Have another go at fixing the Windows build.
5951
5952         * WebProcess/Plugins/Netscape/NetscapePlugin.h:
5953         * WebProcess/Plugins/Netscape/win/NetscapePluginWin.cpp:
5954         (WebKit::NetscapePlugin::containingWindow):
5955         (WebKit::NetscapePlugin::platformHandleMouseEnterEvent):
5956         (WebKit::NetscapePlugin::platformHandleMouseLeaveEvent):
5957
5958 2011-07-02  Anders Carlsson  <andersca@apple.com>
5959
5960         Null out the plug-in controller after destroying the plug-in.
5961         https://bugs.webkit.org/show_bug.cgi?id=63869
5962
5963         Reviewed by Maciej Stachowiak.
5964
5965         * PluginProcess/PluginControllerProxy.cpp:
5966         (WebKit::PluginControllerProxy::destroy):
5967         Call destroyPlugin.
5968
5969         * WebProcess/Plugins/Plugin.cpp:
5970         (WebKit::Plugin::destroyPlugin):
5971         Call destroy and null out the plug-in controller.
5972
5973         * WebProcess/Plugins/Plugin.h:
5974         Add destroyPlugin, make destroy private.
5975
5976         * WebProcess/Plugins/PluginView.cpp:
5977         (WebKit::PluginView::~PluginView):
5978         Call destroyPlugin.
5979
5980 2011-07-02  Anders Carlsson  <andersca@apple.com>
5981
5982         Fix Windows build for real.
5983
5984         * WebProcess/Plugins/Netscape/win/NetscapePluginWin.cpp:
5985         (WebKit::NetscapePlugin::containingWindow):
5986         (WebKit::NetscapePlugin::scheduleWindowedGeometryUpdate):
5987         (WebKit::NetscapePlugin::platformPaint):
5988         (WebKit::NetscapePlugin::platformHandleMouseEvent):
5989
5990 2011-07-02  Anders Carlsson  <andersca@apple.com>
5991
5992         Implement NPN_PluginThreadAsyncCall
5993         https://bugs.webkit.org/show_bug.cgi?id=63868
5994
5995         Reviewed by Dan Bernstein.
5996
5997         * WebProcess/Plugins/Netscape/NetscapeBrowserFuncs.cpp:
5998         (WebKit::NPN_PluginThreadAsyncCall):
5999         Call NetscapePlugin::pluginThreadAsyncCall.
6000
6001         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
6002         (WebKit::NetscapePlugin::pluginThreadAsyncCall):
6003         Schedule a work item to call the function on the main run loop.
6004
6005         (WebKit::NetscapePlugin::handlePluginThreadAsyncCall):
6006         If the plug-in is still running, run the function.
6007
6008         * WebProcess/Plugins/Netscape/NetscapePlugin.h:
6009         Add new member function.
6010
6011         * WebProcess/Plugins/Plugin.h:
6012         Make plug-in inherit from ThreadSafeRefCounted since plug-ins can potentially
6013         ref the plug-in from other threads.
6014
6015 2011-07-02  Anders Carlsson  <andersca@apple.com>
6016
6017         Fix Windows build.
6018
6019         * WebProcess/Plugins/Netscape/win/NetscapePluginWin.cpp:
6020         (WebKit::NetscapePlugin::containingWindow):
6021         (WebKit::NetscapePlugin::scheduleWindowedGeometryUpdate):
6022         (WebKit::NetscapePlugin::platformPaint):
6023         (WebKit::NetscapePlugin::platformHandleMouseEvent):
6024         (WebKit::NetscapePlugin::platformHandleMouseEnterEvent):
6025         (WebKit::NetscapePlugin::platformHandleMouseLeaveEvent):
6026
6027 2011-07-02  Anders Carlsson  <andersca@apple.com>
6028
6029         Move the plug-in controller member variable up to the shared Plugin base class
6030         https://bugs.webkit.org/show_bug.cgi?id=63867
6031
6032         Reviewed by Sam Weinig.
6033
6034         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
6035         (WebKit::NetscapePlugin::NetscapePlugin):
6036         Remove m_pluginController.
6037
6038         (WebKit::NetscapePlugin::invalidate):
6039         (WebKit::NetscapePlugin::userAgent):
6040         (WebKit::NetscapePlugin::loadURL):
6041         (WebKit::NetscapePlugin::setStatusbarText):
6042         (WebKit::NetscapePlugin::evaluate):
6043         (WebKit::NetscapePlugin::isPrivateBrowsingEnabled):
6044         (WebKit::NetscapePlugin::windowScriptNPObject):
6045         (WebKit::NetscapePlugin::pluginElementNPObject):
6046         (WebKit::NetscapePlugin::tryToShortCircuitInvoke):
6047         (WebKit::NetscapePlugin::cancelStreamLoad):
6048         (WebKit::NetscapePlugin::isAcceleratedCompositingEnabled):
6049         (WebKit::NetscapePlugin::proxiesForURL):
6050         (WebKit::NetscapePlugin::cookiesForURL):
6051         (WebKit::NetscapePlugin::setCookiesForURL):
6052         (WebKit::NetscapePlugin::getAuthenticationInfo):
6053         Use controller() instead of m_pluginController.
6054
6055         (WebKit::NetscapePlugin::initialize):
6056         This doesn't take a PluginController parameter anymore.
6057
6058         (WebKit::NetscapePlugin::destroy):
6059         No need to null out the plug-in controller.
6060
6061         * WebProcess/Plugins/Netscape/NetscapePlugin.h:
6062         Remove m_pluginController member variable.
6063
6064         * WebProcess/Plugins/Netscape/mac/NetscapePluginMac.mm:
6065         (WebKit::NetscapePlugin::compositingRenderServerPort):
6066         (WebKit::NetscapePlugin::platformSetFocus):
6067         (WebKit::NetscapePlugin::windowFocusChanged):
6068         Use controller() instead of m_pluginController.
6069         
6070         * WebProcess/Plugins/Plugin.cpp:
6071         (WebKit::Plugin::Plugin):
6072         Initialize m_pluginController.
6073
6074         (WebKit::Plugin::initialize):
6075         New function that initializes the plug-in controller and then calls the real
6076         virtual initialize member function.
6077
6078         * WebProcess/Plugins/Plugin.h:
6079         Add m_pluginController member variable and a new initialize virtual member function that doesn't take a
6080         PluginController parameter. Make the "old" initialize member function set up the plug-in controller.
6081
6082         (WebKit::Plugin::controller):
6083         This is now a simple getter.
6084
6085         * WebProcess/Plugins/PluginProxy.cpp:
6086         (WebKit::PluginProxy::PluginProxy):
6087         Remove m_pluginController.
6088
6089         (WebKit::PluginProxy::pluginProcessCrashed):
6090         Use controller(), remove a bogus null check.
6091
6092         (WebKit::PluginProxy::initialize):
6093         This doesn't take a PluginController parameter now.
6094
6095         (WebKit::PluginProxy::destroy):
6096         No need to null out the plug-in controller member variable.
6097
6098         (WebKit::PluginProxy::loadURL):
6099         (WebKit::PluginProxy::proxiesForURL):
6100         (WebKit::PluginProxy::cookiesForURL):
6101         (WebKit::PluginProxy::setCookiesForURL):
6102         (WebKit::PluginProxy::getAuthenticationInfo):
6103         (WebKit::PluginProxy::windowNPObjectID):
6104         (WebKit::PluginProxy::getPluginElementNPObject):
6105         (WebKit::PluginProxy::evaluate):
6106         (WebKit::PluginProxy::cancelStreamLoad):
6107         (WebKit::PluginProxy::cancelManualStreamLoad):
6108         (WebKit::PluginProxy::setStatusbarText):
6109         (WebKit::PluginProxy::setComplexTextInputEnabled):
6110         (WebKit::PluginProxy::update):
6111         Use controller() instead of m_pluginController.
6112         
6113         * WebProcess/Plugins/PluginProxy.h:
6114         Remove m_pluginController.
6115
6116 2011-07-01  Darin Adler  <darin@apple.com>
6117
6118         Consider backing scale factor when setting up graphics layers
6119         https://bugs.webkit.org/show_bug.cgi?id=63848
6120
6121         Reviewed by Simon Fraser.
6122
6123         * WebProcess/WebPage/ca/LayerTreeHostCA.cpp:
6124         (WebKit::LayerTreeHostCA::initialize): Set contents scale on the
6125         non-composited content layer based on the backing scale factor.
6126         (WebKit::LayerTreeHostCA::createPageOverlayLayer): Set contents
6127         scale on the page overlay layer based on the backing scale factor.
6128
6129 2011-06-30  Brian Weinstein  <bweinstein@apple.com>
6130
6131         Reviewed by Darin Adler.
6132
6133         WebKit2: DidFinishLoadForFrame is never called on iframes when loads are 
6134         cancelled by willSendRequest
6135         https://bugs.webkit.org/show_bug.cgi?id=63753
6136         
6137         When deciding a policy for a null request, call the callback that was passed
6138         to WebKit2 and say that we used the loader.
6139
6140         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
6141         (WebKit::WebFrameLoaderClient::dispatchDecidePolicyForResponse):
6142
6143 2011-07-01  Balazs Kelemen  <kbalazs@webkit.org>
6144
6145         Reviewed by Andreas Kling.
6146
6147         [X11][WK2] plugins/mouse-evets-fixedpos.html is failing because of broken event propagation
6148         https://bugs.webkit.org/show_bug.cgi?id=63239
6149
6150         * WebProcess/Plugins/Netscape/x11/NetscapePluginX11.cpp:
6151         Revert the return value of NPP_HandleEvent because the plugin function
6152         returns with 0 if it handled the event.
6153         (WebKit::NetscapePlugin::platformHandleMouseEvent):
6154         (WebKit::NetscapePlugin::platformHandleWheelEvent):
6155         (WebKit::NetscapePlugin::platformHandleMouseEnterEvent):
6156         (WebKit::NetscapePlugin::platformHandleMouseLeaveEvent):
6157         (WebKit::NetscapePlugin::platformHandleKeyboardEvent):
6158
6159 2011-07-01  Mark Rowe  <mrowe@apple.com>
6160
6161         Unreviewed due to fixing of a broken world.
6162
6163         REGRESSION (r90163): WebKit2 bot is failing 100% of the tests.
6164
6165         r90163 bumped the version of the WKBundlePageLoaderClient passed in by WebKitTestRunner from 0 to 1.
6166         This made it run in to the ad-hoc client version checking implemented directly in WKBundlePageSetPageLoaderClient,
6167         resulting in no client being set. After r90162 the ad-hoc checking is not necessary as the APIClient
6168         template takes care of the relevant version checks.
6169
6170         * Shared/APIClient.h:
6171         (WebKit::APIClient::initialize): Fix a bug I noticed along the way: don't attempt to copy anything if
6172         the client version is newer than what we support. This matches the behavior of the ad-hoc version checking.
6173         * UIProcess/API/C/WKContext.cpp:
6174         (WKContextSetInjectedBundleClient): Drop the ad-hoc version checking.
6175         (WKContextSetHistoryClient): Ditto.
6176         (WKContextSetDownloadClient): Ditto.
6177         * UIProcess/API/C/WKCookieManager.cpp:
6178         (WKCookieManagerSetClient): Ditto.
6179         * UIProcess/API/C/WKGeolocationManager.cpp:
6180         (WKGeolocationManagerSetProvider): Ditto.
6181         * UIProcess/API/C/WKIconDatabase.cpp:
6182         (WKIconDatabaseSetIconDatabaseClient): Ditto.
6183         * UIProcess/API/C/WKPage.cpp:
6184         (WKPageSetPageContextMenuClient): Ditto.
6185         (WKPageSetPageFindClient): Ditto.
6186         (WKPageSetPageFormClient): Ditto.
6187         (WKPageSetPageLoaderClient): Ditto.
6188         (WKPageSetPagePolicyClient): Ditto.
6189         (WKPageSetPageResourceLoadClient): Ditto.
6190         (WKPageSetPageUIClient): Ditto.
6191         * WebProcess/InjectedBundle/API/c/WKBundle.cpp:
6192         (WKBundleSetClient): Ditto.
6193         * WebProcess/InjectedBundle/API/c/WKBundlePage.cpp:
6194         (WKBundlePageSetContextMenuClient): Ditto.
6195         (WKBundlePageSetEditorClient): Ditto.
6196         (WKBundlePageSetFormClient): Ditto.
6197         (WKBundlePageSetPageLoaderClient): Ditto.
6198         (WKBundlePageSetResourceLoadClient): Ditto.
6199         (WKBundlePageSetPolicyClient): Ditto.
6200         (WKBundlePageSetUIClient): Ditto.
6201         (WKBundlePageSetFullScreenClient): Ditto.
6202
6203 2011-06-30  Darin Adler  <darin@apple.com>
6204
6205         Reviewed by Anders Carlsson.
6206
6207         [WebKit2] Consider scale factor when allocating backing store
6208         https://bugs.webkit.org/show_bug.cgi?id=63766
6209
6210         This is the first step in considering scale factor. It considers
6211         scale factor for the primary backing store, not graphics layers,
6212         and for CG only.
6213
6214         * Platform/cg/CGUtilities.cpp:
6215         (WebKit::paintImage): Added a scale factor argument.
6216         (WebKit::paintBitmapContext): Pass 1 for scale factor.
6217         * Platform/cg/CGUtilities.h: Updated for above.
6218
6219         * Shared/ShareableBitmap.h: Added an overload of paint that can handle
6220         a scale factor.
6221
6222         * Shared/UpdateInfo.cpp:
6223         (WebKit::UpdateInfo::encode): Encode scale factor.
6224         (WebKit::UpdateInfo::decode): Decode scale factor.
6225         * Shared/UpdateInfo.h: Added scale factor.
6226
6227         * Shared/cg/ShareableBitmapCG.cpp:
6228         (WebKit::ShareableBitmap::paint): Added the overload that can handle
6229         a scale factor.
6230
6231         * UIProcess/BackingStore.cpp:
6232         (WebKit::BackingStore::create): Take a scale factor.
6233         (WebKit::BackingStore::BackingStore): Store the scale factor.
6234         (WebKit::BackingStore::incorporateUpdate): Consider the scale factor
6235         when asserting the size is correct.
6236
6237         * UIProcess/BackingStore.h: Add a scale factor.
6238
6239         * UIProcess/DrawingAreaProxyImpl.cpp:
6240         (WebKit::DrawingAreaProxyImpl::didUpdateBackingStoreState): Check the
6241         scale factor too when deciding whether to reuse a backing store.
6242         (WebKit::DrawingAreaProxyImpl::incorporateUpdate): Pass in the scale
6243         factor when creating a backing store.
6244
6245         * UIProcess/mac/BackingStoreMac.mm:
6246         (WebKit::BackingStore::incorporateUpdate): Take the scale factor into
6247         account when painting.
6248
6249         * WebProcess/WebPage/DrawingAreaImpl.cpp:
6250         (WebKit::DrawingAreaImpl::sendDidUpdateBackingStoreState): Put the
6251         scale factor into the UpdateInfo.
6252         (WebKit::DrawingAreaImpl::exitAcceleratedCompositingMode): Ditto.
6253         (WebKit::DrawingAreaImpl::display): Take the scale factor into account
6254         when allocating the bitmap and creating a graphics context for it.
6255
6256 2011-06-30  Mark Rowe  <mrowe@apple.com>
6257
6258         Fix the Windows build.
6259
6260         * UIProcess/API/C/win/WKTextChecker.h:
6261         * UIProcess/API/C/win/WKView.h:
6262         * UIProcess/win/WebTextCheckerClient.h:
6263         * UIProcess/win/WebUndoClient.h:
6264
6265 2011-06-30  Mark Rowe  <mrowe@apple.com>
6266
6267         Reviewed by Anders Carlsson.
6268
6269         Teach APIClient to correctly handle multiple versions of a client interface.
6270
6271         If a client struct is not the current version then we can't copy it via assignment
6272         since that will read past the end of the smaller, older struct. To deal with this
6273         APIClient needs to be aware of the sizes of the older client version structs so that
6274         it can copy only the appropriate amount of the struct.
6275         
6276         * Shared/APIClient.h:
6277         (WebKit::APIClient::initialize): Assign through to our client if the new in client is the
6278         latest version. If an older client version was passed then we zero out our client and memcpy
6279         the appropriate number of bytes in to it. This ensures that any new members in the client
6280         are initialized to 0.
6281         * Shared/APIClientTraits.cpp:
6282         * Shared/APIClientTraits.h: Client interfaces are the size of their struct unless otherwise stated.
6283         * WebKit2.xcodeproj/project.pbxproj:
6284         * WebProcess/InjectedBundle/API/c/WKBundlePage.h: Bump the version and add comments indicating
6285         which components belong to which versions.
6286
6287 2011-06-30  Mark Rowe  <mrowe@apple.com>
6288
6289         Reviewed by Anders Carlsson.
6290
6291         Make the APIClient template aware of the latest client interface version number.
6292
6293         This will be used in an upcoming patch.
6294
6295         * Shared/APIClient.h:
6296         * UIProcess/WebContextInjectedBundleClient.h:
6297         * UIProcess/WebCookieManagerProxyClient.h:
6298         * UIProcess/WebDatabaseManagerProxyClient.h:
6299         * UIProcess/WebDownloadClient.h:
6300         * UIProcess/WebFindClient.h:
6301         * UIProcess/WebFormClient.h:
6302         * UIProcess/WebGeolocationProvider.h:
6303         * UIProcess/WebHistoryClient.h:
6304         * UIProcess/WebIconDatabaseClient.h:
6305         * UIProcess/WebLoaderClient.h:
6306         * UIProcess/WebPageContextMenuClient.h:
6307         * UIProcess/WebPolicyClient.h:
6308         * UIProcess/WebResourceLoadClient.h:
6309         * UIProcess/WebUIClient.h:
6310         * WebProcess/InjectedBundle/InjectedBundleClient.h:
6311         * WebProcess/InjectedBundle/InjectedBundlePageContextMenuClient.h:
6312         * WebProcess/InjectedBundle/InjectedBundlePageEditorClient.h:
6313         * WebProcess/InjectedBundle/InjectedBundlePageFormClient.h:
6314         * WebProcess/InjectedBundle/InjectedBundlePageFullScreenClient.h:
6315         * WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.h:
6316         * WebProcess/InjectedBundle/InjectedBundlePagePolicyClient.h:
6317         * WebProcess/InjectedBundle/InjectedBundlePageResourceLoadClient.h:
6318         * WebProcess/InjectedBundle/InjectedBundlePageUIClient.h:
6319
6320 2011-06-30  Mark Rowe  <mrowe@apple.com>
6321
6322         Reviewed by Anders Carlsson.
6323
6324         WebKit2 client interfaces should have constant declaring latest version.
6325
6326         * UIProcess/API/C/WKContext.h:
6327         * UIProcess/API/C/WKCookieManager.h:
6328         * UIProcess/API/C/WKDatabaseManager.h:
6329         * UIProcess/API/C/WKGeolocationManager.h:
6330         * UIProcess/API/C/WKIconDatabase.h:
6331         * UIProcess/API/C/WKPage.h:
6332         * WebProcess/InjectedBundle/API/c/WKBundle.h:
6333         * WebProcess/InjectedBundle/API/c/WKBundlePage.h:
6334         * WebProcess/InjectedBundle/API/c/WKBundlePageOverlay.h:
6335
6336 2011-06-30  Anders Carlsson  <andersca@apple.com>
6337
6338         Build fix.
6339
6340         * UIProcess/win/WebPopupMenuProxyWin.h:
6341         (WebKit::WebPopupMenuProxyWin::enclosingScrollableArea):
6342
6343 2011-06-30  Martin Robinson  <mrobinson@igalia.com>
6344
6345         Reviewed by Anders Carlsson.
6346
6347         [GTK] Crash observed with nspluginwrapper and flash
6348         https://bugs.webkit.org/show_bug.cgi?id=62249
6349
6350         * WebProcess/Plugins/Netscape/NetscapeBrowserFuncs.cpp:
6351         (WebKit::NPN_InvalidateRect): Guard against null instances here.
6352
6353 2011-06-30  Mark Rowe  <mrowe@apple.com>
6354
6355         Reviewed by Anders Carlsson.
6356
6357         Reinstate WKSecurityOriginGetHost and WKSecurityOriginGetProtocol as wrappers around the correctly-named functions.
6358
6359         They're needed for ABI compatibility.
6360
6361         * Shared/API/c/WKSecurityOrigin.cpp:
6362         (WKSecurityOriginGetHost):
6363         (WKSecurityOriginGetProtocol):
6364
6365 2011-06-29  Darin Adler  <darin@apple.com>
6366
6367         Reviewed by Dan Bernstein.
6368
6369         [Mac] Use system cursors instead of custom bitmaps where possible
6370         https://bugs.webkit.org/show_bug.cgi?id=63679
6371
6372         * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
6373         (InitWebCoreSystemInterface): Added WKCursor.
6374
6375 2011-06-29  Darin Adler  <darin@apple.com>
6376
6377         Reviewed by Anders Carlsson.
6378
6379         [WebKit2] Crash loading page that adds/removes frame in DOMContentLoaded/loaded
6380         https://bugs.webkit.org/show_bug.cgi?id=63483
6381
6382         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
6383         (WebKit::WebFrameLoaderClient::createFrame): Added a check for null when creating
6384         a frame. Also added a check that was in the WebKit1 code, but not here. Strangely,
6385         the comment from the second check was still here, but not the code.
6386
6387 2011-06-28  Chang Shu  <cshu@webkit.org>
6388
6389         Reviewed by Andreas Kling.
6390
6391         [Qt][WK2] Random crashes in fast/frames/ tests
6392         https://bugs.webkit.org/show_bug.cgi?id=63459
6393
6394         Investigation on the crashes has revealed that sometimes, a frame could
6395         have been destroyed before it is removed from the hierachy in Qt WebKit2 UI process.
6396         The root cause lies in the fact that the order of the two contiguous asynchronous
6397         messages may not be respected on the receiving side. And it is Qt's implementation,
6398         which uses QTimer::startTimer(0), that causes the reverse order. This patch replaces
6399         the timer approach with QMetaObject::invokeMethod approach and no crash happens afterwards.
6400
6401         * Platform/qt/WorkQueueQt.cpp:
6402         (WorkQueue::scheduleWork):
6403
6404 2011-06-28  Balazs Kelemen  <kbalazs@webkit.org>
6405
6406         Reviewed by Kenneth Rohde Christiansen.
6407
6408         [X11][WK2] X error with plugin tests
6409         https://bugs.webkit.org/show_bug.cgi?id=63520
6410
6411         * WebProcess/Plugins/Netscape/x11/NetscapePluginX11.cpp:
6412         Never create a pixmap with (0,0) dimensions.
6413         (WebKit::NetscapePlugin::platformGeometryDidChange):
6414         (WebKit::NetscapePlugin::platformPaint):
6415
6416 2011-06-28  Balazs Kelemen  <kbalazs@webkit.org>
6417
6418         Reviewed by Kenneth Rohde Christiansen.
6419
6420         [X11][WK2] plugins/plugin-javascript-access fails
6421         https://bugs.webkit.org/show_bug.cgi?id=63464
6422
6423         * Shared/Plugins/Netscape/x11/NetscapePluginModuleX11.cpp:
6424         (WebKit::NetscapePluginModule::getPluginInfo):
6425         Determine the name of the plugin.
6426
6427 2011-06-27  Yuta Kitamura  <yutak@chromium.org>
6428
6429         Reviewed by Alexey Proskuryakov.
6430
6431         [WebKit2] Add hixie76WebSocketProtocolEnabled flag to WebPreferences
6432         https://bugs.webkit.org/show_bug.cgi?id=63447
6433
6434         Make a new flag added in WebCore::Settings (useHixie76WebSocketProtocol)
6435         switchable from WebPage and WebPreferences.
6436
6437         * Shared/WebPreferencesStore.h:
6438         * UIProcess/API/C/WKPreferences.cpp:
6439         (WKPreferencesSetHixie76WebSocketProtocolEnabled):
6440         (WKPreferencesGetHixie76WebSocketProtocolEnabled):
6441         * UIProcess/API/C/WKPreferencesPrivate.h:
6442         * WebProcess/WebPage/WebPage.cpp:
6443         (WebKit::WebPage::updatePreferences):
6444
6445 2011-06-27  Jeff Miller  <jeffm@apple.com>
6446
6447         Reviewed by Oliver Hunt.
6448
6449         Web process always pauses on launch
6450         https://bugs.webkit.org/show_bug.cgi?id=63487
6451         
6452         In the absence of the WEBKIT2_PAUSE_WEB_PROCESS_ON_LAUNCH environment variable, only pause the web process on
6453         launch if the shift, control, and alt keys are all held down. This regressed in r89685, which always caused the
6454         web process to pause if the shift and alt keys were not held down.
6455
6456         * WebProcess/WebKitMain.cpp:
6457         (pauseProcessIfNeeded): Add some parentheses.
6458
6459 2011-06-27  Huang Dongsung  <luxtella@company100.net>
6460
6461         Reviewed by Kenneth Rohde Christiansen.
6462
6463         TiledBackingStore endlessly creates and destroys tiles due to an off-by-one
6464         error.
6465         https://bugs.webkit.org/show_bug.cgi?id=62422
6466
6467         REGRESSION(r77286): Remove bottomRight().
6468         REGRESSION(r77312): Change the logic to get the bottom right point.
6469         REGRESSION(r77928): Cause off-by-one error in TiledBackingStore.
6470         REGRESSION(r78783): Cause off-by-one error in TiledDrawingAreaProxy.
6471         REGRESSION(r78785): Cause off-by-one error in TiledDrawingAreaProxy.
6472
6473         If the viewport width equals the contents width, especially in the mobile
6474         device, TiledBackingStore endlessly creates and deletes the rightmost
6475         column and bottom row of tiles.
6476         In the detail, dropTilesOutsideRect() in TiledBackingStore::createTiles()
6477         deletes tiles and setTile(coordinate, Tile::create(this, coordinate)) creates
6478         tiles infinitely.
6479         Modified TiledDrawingAreaProxy also.
6480
6481         * UIProcess/TiledDrawingAreaProxy.cpp:
6482         (WebKit::innerBottomRight):
6483         (WebKit::TiledDrawingAreaProxy::invalidate):
6484         (WebKit::TiledDrawingAreaProxy::paint):
6485         (WebKit::TiledDrawingAreaProxy::createTiles):
6486
6487 2011-06-26  Mark Rowe  <mrowe@apple.com>
6488
6489         Reviewed by Dan Bernstein.
6490
6491         Use a separate file name for Lion's WebKitSystemInterface.
6492
6493         * Configurations/DebugRelease.xcconfig:
6494
6495 2011-06-26  Mark Rowe  <mrowe@apple.com>
6496
6497         Rubber-stamped by Maciej Stachowiak.
6498
6499         <rdar://problem/9679221&9679235> Work around an issue with sandbox.h.
6500
6501         * WebProcess/mac/WebProcessMac.mm:
6502
6503 2011-06-26  Anders Carlsson  <andersca@apple.com>
6504
6505         Reviewed by Dan Bernstein.
6506
6507         Don't use a Mutex for protecting access to the connection queue clients
6508         https://bugs.webkit.org/show_bug.cgi?id=63403
6509
6510         Make sure to only access the queue client vector from the connection work queue.
6511         This gets rid of a lock and ensures that adding/removing clients from callbacks works correctly.
6512
6513         * Platform/CoreIPC/Connection.cpp:
6514         (CoreIPC::Connection::addQueueClient):
6515         (CoreIPC::Connection::removeQueueClient):
6516         (CoreIPC::Connection::addQueueClientOnWorkQueue):
6517         (CoreIPC::Connection::removeQueueClientOnWorkQueue):
6518         (CoreIPC::Connection::processIncomingMessage):
6519         * Platform/CoreIPC/Connection.h:
6520
6521 2011-06-25  Brent Fulgham  <bfulgham@webkit.org>
6522
6523         Unreviewed build correction after r89426.
6524
6525         * Shared/API/c/cairo/WKImageCairo.h: Declare cairo type
6526           as struct (in keeping with other declarations).
6527         * win/WebKit2.vcproj: Add new WKImageCairo.cpp file to
6528           WinCairo build.
6529
6530 2011-06-25  Brent Fulgham  <bfulgham@webkit.org>
6531
6532         Unreviewed build correction after r89503.
6533         See http://trac.webkit.org/changeset/89503. The modifications
6534         to the WebKit2.def need to be mirrored in WebKit2CFLite.def.
6535
6536         * win/WebKit2CFLite.def: Add new exported symbol for isPreloaded.
6537
6538 2011-06-24  Brent Fulgham  <bfulgham@webkit.org>
6539
6540         Unreviewed build correction after r89426.
6541         See http://trac.webkit.org/changeset/89426. The new WebKit2
6542         header file (WKImageCairo.h) is needed.
6543
6544         * win/WebKit2Generated.make: Make sure to copy the WKImageCairo.h
6545         header file to the WebKit2 API directory after building.
6546
6547 2011-06-24  Anders Carlsson  <andersca@apple.com>
6548
6549         Reviewed by John Sullivan.
6550
6551         Drag-and-drop tab in same window makes web process falsely report unresponsiveness
6552         https://bugs.webkit.org/show_bug.cgi?id=63369
6553         <rdar://problem/9673120>
6554
6555         If the view becomes invisible, stop the responsiveness timer, because we might not get any
6556         messages that will cause it to stop (such as painting notifications since we don't paint
6557         when we're not visible).
6558
6559         * UIProcess/WebPageProxy.cpp:
6560         (WebKit::WebPageProxy::viewStateDidChange):
6561
6562 2011-06-24  Anders Carlsson  <andersca@apple.com>
6563
6564         Reviewed by Kevin Decker.
6565
6566         Not possible for plug-ins to override the internal PDF viewer
6567         https://bugs.webkit.org/show_bug.cgi?id=63356
6568         <rdar://problem/9673382>
6569
6570         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
6571         (WebKit::WebFrameLoaderClient::transitionToCommittedFromCachedFrame):
6572         (WebKit::WebFrameLoaderClient::transitionToCommittedForNewPage):
6573         Pass the entire resource response to shouldUseCustomRepresentationForResponse.
6574
6575         * WebProcess/WebProcess.cpp:
6576         (WebKit::canPluginHandleResponse):
6577         Ask for the plug-in path for a plug-in that can handle the given resource response.
6578         If we fail to send the message, or if the path comes back empty, we assume that there's no plug-in
6579         that can handle it.
6580
6581         (WebKit::WebProcess::shouldUseCustomRepresentationForResponse):
6582         If the response MIME type is in the m_mimeTypesWithCustomRepresentations map, check if there's
6583         a plug-in that can handle the given response. If that is the case, it should have precedence over
6584         the custom representation.
6585
6586         * WebProcess/WebProcess.h:
6587         Rename shouldUseCustomRepresentationForMIMEType to shouldUseCustomRepresentationForResponse.
6588
6589 2011-06-24  Adam Roben  <aroben@apple.com>
6590
6591         Mac build fix after r89685
6592
6593         * WebProcess/WebKitMain.cpp: Make a Windows-only #include really be Windows-only.
6594
6595 2011-06-24  Adam Roben  <aroben@apple.com>
6596
6597         Make the web process pause dialog look better on Vista/7 and robust against executable
6598         renames
6599
6600         Fixes <http://webkit.org/b/63335> Web process pause dialog looks bad on Vista/7
6601
6602         Reviewed by Brian Weinstein.
6603
6604         * WebProcess/WebKitMain.cpp:
6605         (pauseProcessIfNeeded): Moved code to show the pause dialog here from WebKitMain. We now
6606         fetch the executable name using ::GetModuleFileNameW instead of hard-coding it. The string
6607         we pass to ::MessageBoxW no longer has embedded newlines, which improves its appearance on
6608         Vista/7 (which were doing their own wrapping in addition to our newlines). Appearance is
6609         different but fine on XP. Note that the message text now contains the "[_debug].exe" suffix when
6610         referring to the process; that is different from before but seems fine.
6611         (WebKitMain): Call the new function.
6612
6613 2011-06-24  Dominic Cooney  <dominicc@chromium.org>
6614
6615         Reviewed by Dimitri Glazkov.
6616
6617         Convert shadow DOM-related tests to use window.internals
6618         https://bugs.webkit.org/show_bug.cgi?id=61671
6619
6620         Remove shadow DOM-related methods from WebKit2 API. These are not
6621         required any more.
6622
6623         * WebProcess/InjectedBundle/API/c/WKBundleNodeHandle.cpp:
6624         * WebProcess/InjectedBundle/API/c/WKBundleNodeHandlePrivate.h:
6625         * WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.cpp:
6626         * WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.h:
6627         * win/WebKit2.def: Re-exports for symbols used by WebCoreTestSupport.
6628         * win/WebKit2CFLite.def: Same for Cairo.
6629
6630 2011-06-24  Carlos Garcia Campos  <cgarcia@igalia.com>
6631
6632         Reviewed by Martin Robinson.
6633
6634         [X11] Do not call NPP_SetWindow with a null window handle on destroy
6635         https://bugs.webkit.org/show_bug.cgi?id=62981
6636
6637         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
6638         (WebKit::NetscapePlugin::destroy):
6639
6640 2011-06-23 Jamie Cooley  <james.cooley@nokia.com>
6641
6642         Reviewed by Andreas Kling.
6643
6644         [Qt][WK2] Qt port needs load-from-history implementation
6645         https://bugs.webkit.org/show_bug.cgi?id=57784
6646  
6647         Created "random access" BackForwardHistory public API method,
6648         QWKHistory::goToItemAt(int)
6649
6650         * UIProcess/API/qt/qwkhistory.cpp:
6651         (QWKHistoryItem::QWKHistoryItem::itemRef):
6652         Added access method to fetch WKBackForwardListRef
6653
6654         (QWKHistoryPrivate::QWKHistoryPrivate):
6655         (QWKHistoryPrivate::createHistory):
6656         Updated createHistory method and QWKHistoryPrivate constructor to take a pointer
6657         to the owning QWKPage in addition to the WebBackForwardList. This will be saved so that the
6658         new API can ask the page to load a HistoryItem.
6659
6660         (QWKHistory::goToItemAt):
6661         New Public API. Like QWKHistory::itemAt, callee gives an integer.
6662         <0 means jump back to that item, 0 means the current item, >0 means jump forwards.
6663         If an out-of-range index is given, the function silently fails.
6664         This will invoke WKPageGoToBackForwardListItem.
6665
6666         * UIProcess/API/qt/qwkhistory.h:
6667         * UIProcess/API/qt/qwkhistory_p.h:
6668         * UIProcess/API/qt/qwkpage.cpp:
6669         (QWKPagePrivate::QWKPagePrivate):
6670         Update instantiation of QWKHistory to include QWKPage.
6671
6672         * UIProcess/API/qt/tests/qwkhistory/tst_qwkhistory.cpp:
6673         (tst_QWKHistory::historyForwardBackTest_data):
6674         (tst_QWKHistory::historyForwardBackTest):
6675         Add test content for the new API
6676
6677 2011-06-23  Yael Aharon  <yael.aharon@nokia.com>
6678
6679         Reviewed by Andreas Kling.
6680
6681         [Qt] [WK2] Add drag and drop support
6682         https://bugs.webkit.org/show_bug.cgi?id=62838
6683
6684         Added missing pieces to add support for DnD in QtWebKit.
6685
6686         * Shared/qt/ArgumentCodersQt.cpp: Added.
6687         (CoreIPC::::encode):
6688         (CoreIPC::::decode):
6689         * Shared/qt/ArgumentCodersQt.h: Added.
6690         Encode DragData so that we can transfer the QMimeData between the
6691         WebProcess and the UI Process.
6692         I encode the DragData and not QMimeData directly because we don't
6693         have an associated QMimeData for each message.
6694
6695         * UIProcess/API/qt/qgraphicswkview.cpp:
6696         (QGraphicsWKView::init):
6697         (QGraphicsWKView::dragEnterEvent):
6698         (QGraphicsWKView::dragLeaveEvent):
6699         (QGraphicsWKView::dragMoveEvent):
6700         (QGraphicsWKView::dropEvent):
6701         * UIProcess/API/qt/qgraphicswkview.h:
6702         * UIProcess/API/qt/qwkpage.cpp:
6703         (dropActionToDragOperation):
6704         (dragOperationToDropAction):
6705         (dragOperationToDropActions):
6706         (QWKPagePrivate::dragEnterEvent):
6707         (QWKPagePrivate::dragLeaveEvent):
6708         (QWKPagePrivate::dragMoveEvent):
6709         (QWKPagePrivate::dropEvent):
6710         (QWKPagePrivate::startDrag):
6711
6712         Send drag-and-drop related events to WebKit.
6713
6714         * UIProcess/API/qt/qwkpage_p.h:
6715         * UIProcess/PageClient.h:
6716         * UIProcess/WebPageProxy.cpp:
6717         (WebKit::WebPageProxy::performDragControllerAction):
6718         (WebKit::WebPageProxy::startDrag):
6719         * UIProcess/WebPageProxy.h:
6720
6721          Start the HTML5 drag operation from the UI process, because QDrag
6722          needs a handle to the QWidget under the mouse.
6723
6724         * UIProcess/WebPageProxy.messages.in:
6725
6726         Add message type that takes DragData as a parameter.
6727
6728         * WebKit2.pro:
6729         * WebProcess/WebCoreSupport/WebDragClient.cpp:
6730         * WebProcess/WebCoreSupport/qt/WebDragClientQt.cpp: Added.
6731         (WebKit::convertImageToBitmap):
6732         (WebKit::WebDragClient::startDrag):
6733
6734         Send a message to the UI process to start the HTML5 drag operation.
6735
6736         * WebProcess/WebPage/WebPage.cpp:
6737         (WebKit::WebPage::performDragControllerAction):
6738         * WebProcess/WebPage/WebPage.h:
6739         * WebProcess/WebPage/WebPage.messages.in:
6740
6741         Add message type that takes DragData as a parameter.
6742
6743 2011-06-23  Carlos Garcia Campos  <cgarcia@igalia.com>
6744
6745         Reviewed by Martin Robinson.
6746
6747         [UNIX] Fix compile warnings in NetscapePluginX11.cpp
6748         https://bugs.webkit.org/show_bug.cgi?id=63249
6749
6750         * WebProcess/Plugins/Netscape/x11/NetscapePluginX11.cpp:
6751         (WebKit::setXButtonEventFields):
6752         (WebKit::NetscapePlugin::platformHandleMouseEvent):
6753
6754 2011-06-22  Carlos Garcia Campos  <cgarcia@igalia.com>
6755
6756         Reviewed by Martin Robinson.
6757
6758         [UNIX] Increment/decrement module load conter in NetscapePluginModule::getPluginInfo()
6759         https://bugs.webkit.org/show_bug.cgi?id=63150
6760
6761         Since the method is static, we are using
6762         NetscapePluginModule::getOrCreate() to get the module. If it's
6763         created, the load counter is 0, so that when module is deleted,
6764         shutdown() hasn't been called and the destructor crashes in the
6765         assert that checks the module has been removed from the
6766         initialized module list. We should increment the load counter, and
6767         decrement it before getPluginInfo() returns, so that
6768         decrementLoadCount() will call shutdown() if counter is 0 and the
6769         module will be deleted from the list.
6770
6771         * Shared/Plugins/Netscape/x11/NetscapePluginModuleX11.cpp:
6772         (WebKit::NetscapePluginModule::getPluginInfo):
6773
6774 2011-06-22  Carlos Garcia Campos  <cgarcia@igalia.com>
6775
6776         Reviewed by Martin Robinson.
6777
6778         [UNIX] Check for npp directly when getting X display in NetscapeBrowserFuncs
6779         https://bugs.webkit.org/show_bug.cgi?id=63149
6780
6781         NetscapePlugin::fromNPP() shouldn't be called with a null npp, it
6782         contains an assert that make it crash when building with debug enabled.
6783
6784         * WebProcess/Plugins/Netscape/NetscapeBrowserFuncs.cpp:
6785         (WebKit::NPN_GetValue):
6786
6787 2011-06-22  Nate Chapin  <japhet@chromium.org>
6788
6789         Reviewed by Adam Barth.
6790
6791         Add win symbols for new window.internals functionality.
6792         https://bugs.webkit.org/show_bug.cgi?id=62066
6793
6794         * win/WebKit2.def:
6795
6796 2011-06-22  Balazs Kelemen  <kbalazs@webkit.org>
6797
6798         Reviewed by Andreas Kling.
6799
6800         [Qt][WK2] Set up plugin tests
6801         https://bugs.webkit.org/show_bug.cgi?id=63066
6802
6803         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
6804         (WebKit::WebFrameLoaderClient::createPlugin):
6805         Force windowless mode for the test plugin because we
6806         don't support windowed plugins yet.
6807
6808 2011-06-22  Geoffrey Garen  <ggaren@apple.com>
6809
6810         Reviewed by Oliver Hunt.
6811
6812         Removed unnecessary #include <stdio.h>.
6813
6814         * PluginProcess/mac/PluginProcessMainMac.mm:
6815         * Shared/WebMemorySampler.cpp:
6816         * UIProcess/WebFrameProxy.cpp:
6817         * UIProcess/WebProcessProxy.cpp:
6818         * WebProcess/InjectedBundle/mac/InjectedBundleMac.cpp:
6819         * WebProcess/mac/WebProcessMac.mm: Added #include back to places where it
6820         was needed.
6821
6822 2011-06-22  Balazs Kelemen  <kbalazs@webkit.org>
6823
6824         Unreviewed build fix after r89461.
6825
6826         * WebProcess/Plugins/Netscape/x11/NetscapePluginX11.cpp:
6827         (WebKit::NetscapePlugin::platformSetFocus):
6828         Forgot to name the parameter, fix it.
6829
6830 2011-06-22  Balazs Kelemen  <kbalazs@webkit.org>
6831
6832         Reviewed by Darin Adler.
6833
6834         [X11][WK2] Implement NetscapePlugin::platformSetFocus
6835         https://bugs.webkit.org/show_bug.cgi?id=63154
6836
6837         * WebProcess/Plugins/Netscape/x11/NetscapePluginX11.cpp:
6838         (WebKit::NetscapePlugin::platformSetFocus):
6839         Implement focus setting based on the WebKit1 path.
6840
6841 2011-06-22  Eunmi Lee  <eunmi15.lee@samsung.com>
6842
6843         Reviewed by Martin Robinson.
6844
6845         Change GtkWidgetBackingStore.h to WidgetBackingStore.h in order to use in the EFL port.
6846         https://bugs.webkit.org/show_bug.cgi?id=62848
6847
6848         Change GtkWidgetBackingStore to WidgetBackingStore in the BackingStore.h and
6849         gtk/BackingStoreGtk.cpp.
6850
6851         * UIProcess/BackingStore.h:
6852         * UIProcess/gtk/BackingStoreGtk.cpp:
6853         (WebKit::BackingStore::incorporateUpdate):
6854
6855 2011-06-22  Adam Roben  <aroben@apple.com>
6856
6857         Don't use an alpha channel when drawing the web page on Windows
6858
6859         We never use the alpha channel in the end anyway (because we never render into a layered
6860         window, which is the only kind of window that supports alpha). And using an alpha channel is
6861         tricky to get right since GDI doesn't support alpha (and often writes 0x0 into the alpha
6862         channel).
6863
6864         Fixes <http://webkit.org/b/63075> <rdar://problem/9648113> REGRESSION (r88978): Text inside
6865         form controls looks really awful on Windows XP
6866
6867         Reviewed by Anders Carlsson.
6868
6869         * WebProcess/WebPage/win/DrawingAreaImplWin.cpp:
6870         (WebKit::DrawingAreaImpl::createGraphicsContext): Specify false for the hasAlpha parameter
6871         to the GraphicsContext constructor.
6872
6873 2011-06-22  Carlos Garcia Campos  <cgarcia@igalia.com>
6874
6875         Reviewed by Martin Robinson.
6876
6877         [GTK] Remove Connection::setShouldCloseConnectionOnProcessTermination()
6878         https://bugs.webkit.org/show_bug.cgi?id=61627
6879
6880         Don't use Connection::setShouldCloseConnectionOnProcessTermination() for the
6881         GTK port, when the process finishes the connection is closed and
6882         the other process is already notified. We still need to monitor
6883         the child process so that it doesn't become a zombie when it dntabi
6884
6885         * Platform/CoreIPC/Connection.h:
6886         * Platform/CoreIPC/unix/ConnectionUnix.cpp:
6887         * UIProcess/Launcher/gtk/ProcessLauncherGtk.cpp:
6888         (WebKit::childFinishedFunction):
6889         (WebKit::ProcessLauncher::launchProcess):
6890         * UIProcess/WebProcessProxy.cpp:
6891         (WebKit::WebProcessProxy::didFinishLaunching):
6892
6893 2011-06-20  Dimitri Glazkov  <dglazkov@chromium.org>
6894
6895         Reviewed by Kent Tamura.
6896
6897         FileChooser should be only created when we need to choose files.
6898         https://bugs.webkit.org/show_bug.cgi?id=63039
6899
6900         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
6901         (WebKit::WebChromeClient::runOpenPanel): Changed to use settings.
6902
6903 2011-06-22  Martin Robinson  <mrobinson@igalia.com>
6904
6905         Reviewed by Adam Roben.
6906
6907         [GTK] Implement pixel dump support for WebKitTestRunner
6908         https://bugs.webkit.org/show_bug.cgi?id=58242
6909
6910         * GNUmakefile.am: Added new Cairo specific image handling files to the build.
6911         * Shared/API/c/cairo/WKImageCairo.cpp: Copied from Source/WebKit2/Shared/cairo/ShareableBitmapCairo.cpp.
6912         (WKImageCreateCairoSurface): Added
6913         (WKImageCreateFromCairoSurface): Added
6914         * Shared/API/c/cairo/WKImageCairo.h: Copied from Source/WebKit2/Shared/cairo/ShareableBitmapCairo.cpp.
6915
6916 2011-06-21  MORITA Hajime  <morrita@google.com>
6917
6918         Unreviewed, rolling out r89401 and r89403.
6919         http://trac.webkit.org/changeset/89401
6920         http://trac.webkit.org/changeset/89403
6921         https://bugs.webkit.org/show_bug.cgi?id=62970
6922
6923         Breaks mac build and mistakenly enables the spellcheck API
6924
6925         * Configurations/FeatureDefines.xcconfig:
6926
6927 2011-06-20  MORITA Hajime  <morrita@google.com>
6928
6929         Reviewed by Kent Tamura.
6930
6931         Spellcheck API should be build-able.
6932         https://bugs.webkit.org/show_bug.cgi?id=62970
6933
6934         No new tests, changing only build related files
6935
6936         * Configurations/FeatureDefines.xcconfig:
6937
6938 2011-06-21  Jer Noble  <jer.noble@apple.com>
6939
6940         Reviewed by Simon Fraser.
6941
6942         REGRESSION: Fullscreen videos are broken (affects embedded vimeo, vimeo.com, and apple.com)
6943         https://bugs.webkit.org/show_bug.cgi?id=63098
6944         <rdar://problem/9645393>
6945
6946         Force a repaint after completing entering full-screen mode only after the notification 
6947         is sent for the QTMovie to tear down its layer.  Then, the QTMovie will build up its
6948         layer again during the repaint.
6949
6950         * WebProcess/FullScreen/mac/WebFullScreenManagerMac.mm:
6951         (WebKit::WebFullScreenManagerMac::setRootFullScreenLayer):
6952
6953 2011-06-21  Yael Aharon  <yael.aharon@nokia.com>
6954
6955         Reviewed by Kenneth Rohde Christiansen.
6956
6957         [Qt] Add an internal API for accessing the QGraphicsView.
6958         https://bugs.webkit.org/show_bug.cgi?id=63095
6959
6960         * UIProcess/API/qt/qwkpage.cpp:
6961         (QWKPagePrivate::ownerWidget):
6962         * UIProcess/API/qt/qwkpage_p.h:
6963
6964 2011-06-21  Lukasz Slachciak  <l.slachciak@samsung.com>
6965
6966         Reviewed by Sam Weinig.
6967
6968         [GTK] [WK2] WebKit2 build break fixes.
6969         https://bugs.webkit.org/show_bug.cgi?id=62950
6970
6971         When building WebKit2 for GTK there are few build breaks connected with missing include files.
6972
6973         * Platform/unix/SharedMemoryUnix.cpp:
6974         * Shared/gtk/WebCoreArgumentCodersGtk.cpp:
6975         * UIProcess/API/gtk/PageClientImpl.cpp:
6976
6977 2011-06-20  Martin Robinson  <mrobinson@igalia.com>
6978
6979         Reviewed by Eric Seidel.
6980
6981         [GTK] [WebKit2] Disable GDK double buffering
6982         https://bugs.webkit.org/show_bug.cgi?id=62770
6983
6984         Explicitly disable GDK double-buffering when instantiating
6985         a WebKit2 view widget. This prevents one extra pixmap copy.
6986
6987         * UIProcess/API/gtk/WebKitWebViewBase.cpp:
6988         (webkit_web_view_base_init):
6989
6990 2011-06-20  Carlos Garcia Campos  <cgarcia@igalia.com>
6991
6992         Reviewed by Martin Robinson.
6993
6994         [UNIX] Don't use WebCore::PluginPackage to get plugin information
6995         https://bugs.webkit.org/show_bug.cgi?id=62899
6996
6997         The problem is that both PluginPackage in WebCore and
6998         NetscapePluginModule in webkit2 install their own netscape browser
6999         functions and that can cause conflicts in some situations.
7000
7001         * Shared/Plugins/Netscape/NetscapePluginModule.h: Add helper
7002         function to set plugin mime type descriptions.
7003         * Shared/Plugins/Netscape/x11/NetscapePluginModuleX11.cpp:
7004         (WebKit::NetscapePluginModule::setMIMEDescription): Helper
7005         function to set plugin mime type descriptions.
7006         (WebKit::NetscapePluginModule::getPluginInfo): Use
7007         NetscapePluginModule instead of PluginPackage.
7008         * UIProcess/Plugins/unix/PluginInfoStoreUnix.cpp: Remove unneeded
7009         header include.
7010         * WebProcess/Plugins/Netscape/NetscapeBrowserFuncs.cpp:
7011         (WebKit::NPN_GetValue): Do not try to get the XDisplay if the
7012         plugin doesn't have a view. It fixes a crash with flash plugin and
7013         matches WebCore.
7014
7015 2011-06-20  Carlos Garcia Campos  <cgarcia@igalia.com>
7016
7017         Reviewed by Xan Lopez.
7018
7019         [GTK] Split libWebCore into two libWebCore and libWebCoreGtk
7020         https://bugs.webkit.org/show_bug.cgi?id=60539
7021
7022         * GNUmakefile.am: Link to libWebCoreGtk.la too.
7023
7024 2011-06-19  MORITA Hajime <morrita@google.com>
7025
7026         Unreviewed wincairo build fix.
7027
7028         * win/WebKit2CFLite.def:
7029
7030 2011-06-19  MORITA Hajime  <morrita@google.com>
7031
7032         Reviewed by Dimitri Glazkov.
7033
7034         The internals object should have createShadowContentElement()
7035         https://bugs.webkit.org/show_bug.cgi?id=62432
7036
7037         * win/WebKit2.def: Added some more symbols necessary for
7038         window.internals to function to the global symbol list.
7039
7040 2011-06-18  Dimitri Glazkov  <dglazkov@chromium.org>
7041
7042         Reviewed by Darin Adler.
7043
7044         Separate concerns of loading file icons and choosing files.
7045         https://bugs.webkit.org/show_bug.cgi?id=62931
7046
7047         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
7048         (WebKit::WebChromeClient::loadIconForFiles): Renamed.
7049         * WebProcess/WebCoreSupport/WebChromeClient.h:
7050
7051 2011-06-18  Eunmi Lee  <eunmi15.lee@samsung.com>
7052
7053         Reviewed by Sam Weinig.
7054
7055         [EFL][WK2] add WebKit2 EFL port's NativeWebMouseEvent, NativeWebWheelEvent and NativeWebKeyboardEvent
7056         https://bugs.webkit.org/show_bug.cgi?id=61993
7057
7058         Add native mouse and keyboard event classes to convert EFL's events to NativeWebEvent.
7059
7060         * Shared/NativeWebKeyboardEvent.h:
7061         (WebKit::NativeWebKeyboardEvent::nativeEvent):
7062         * Shared/NativeWebMouseEvent.h:
7063         (WebKit::NativeWebMouseEvent::nativeEvent):
7064         * Shared/NativeWebWheelEvent.h:
7065         (WebKit::NativeWebWheelEvent::nativeEvent):
7066         * Shared/efl/NativeWebKeyboardEventEfl.cpp: Added.
7067         (WebKit::NativeWebKeyboardEvent::NativeWebKeyboardEvent):
7068         * Shared/efl/NativeWebMouseEventEfl.cpp: Added.
7069         (WebKit::NativeWebMouseEvent::NativeWebMouseEvent):
7070         * Shared/efl/NativeWebWheelEventEfl.cpp: Added.
7071         (WebKit::NativeWebWheelEvent::NativeWebWheelEvent):
7072         * Shared/efl/WebEventFactory.cpp: Added.
7073         (WebKit::modifiersForEvent):
7074         (WebKit::buttonForEvent):
7075         (WebKit::clickCountForEvent):
7076         (WebKit::WebEventFactory::createWebMouseEvent):
7077         (WebKit::WebEventFactory::createWebWheelEvent):
7078         (WebKit::WebEventFactory::createWebKeyboardEvent):
7079         * Shared/efl/WebEventFactory.h: Added.
7080
7081 2011-06-18  Eunmi Lee  <eunmi15.lee@samsung.com>
7082
7083         Reviewed by Sam Weinig.
7084
7085         [EFL][WK2] Add missing functions of EFL port's PageClientImpl
7086         https://bugs.webkit.org/show_bug.cgi?id=62711
7087
7088         Three functions are added in the PageClient.h, so add them to the EFL's PageClientImpl.
7089
7090         * UIProcess/API/efl/PageClientImpl.cpp:
7091         (WebKit::PageClientImpl::screenToWindow):
7092         (WebKit::PageClientImpl::enterAcceleratedCompositingMode):
7093         (WebKit::PageClientImpl::exitAcceleratedCompositingMode):
7094         * UIProcess/API/efl/PageClientImpl.h:
7095
7096 2011-06-17  Brent Fulgham  <bfulgham@webkit.org>
7097
7098         [WinCairo] Unreviewed build fix after r89060 and r89161.
7099
7100         * Shared/win/WebCoreArgumentCodersWin.cpp: WinCairo build fixes
7101           (1) Include proper header files for WinCairo build
7102           (2) Exclude unused namespace declaration
7103
7104 2011-06-17  Anders Carlsson  <andersca@apple.com>
7105
7106         Reviewed by Sam Weinig.
7107
7108         Remove unused ArgumentEncoder and ArgumentDecoder functions
7109         https://bugs.webkit.org/show_bug.cgi?id=62909
7110
7111         * Platform/CoreIPC/ArgumentDecoder.cpp:
7112         * Platform/CoreIPC/ArgumentDecoder.h:
7113         * Platform/CoreIPC/ArgumentEncoder.cpp:
7114         * Platform/CoreIPC/ArgumentEncoder.h:
7115         
7116         * Shared/win/PlatformCertificateInfo.cpp:
7117         (WebKit::PlatformCertificateInfo::encode):
7118         (WebKit::PlatformCertificateInfo::decode):
7119         Replace calls to encodeBytes/decodeBytes with
7120         encodeVariableLengthByteArray/decodeVariableLengthByteArray.
7121
7122 2011-06-17  Anders Carlsson  <andersca@apple.com>
7123
7124         Yet another Qt build fix attempt.
7125
7126         * UIProcess/API/qt/ClientImpl.cpp:
7127         * UIProcess/API/qt/qgraphicswkview.cpp:
7128         * UIProcess/API/qt/qwkpage.cpp:
7129         * UIProcess/API/qt/qwkpage_p.h:
7130
7131 2011-06-17  Anders Carlsson  <andersca@apple.com>
7132
7133         Another attempt at fixing the Qt build.
7134
7135         * UIProcess/API/qt/ClientImpl.cpp:
7136         * UIProcess/API/qt/qgraphicswkview.cpp:
7137         * UIProcess/API/qt/qwkcontext.cpp:
7138
7139 2011-06-17  Anders Carlsson  <andersca@apple.com>
7140
7141         Fix Qt build.
7142
7143         * WebProcess/ResourceCache/WebResourceCacheManager.cpp:
7144
7145 2011-06-17  Anders Carlsson  <andersca@apple.com>
7146
7147         Windows build fix.
7148
7149         * UIProcess/win/WebView.cpp:
7150
7151 2011-06-17  Anders Carlsson  <andersca@apple.com>
7152
7153         Reviewed by Sam Weinig.
7154
7155         Move the remaining WebCore argument coders to the .cpp file
7156         https://bugs.webkit.org/show_bug.cgi?id=62874
7157
7158         Also add includes that other files need that used to be provided by WebCoreArgumentCoders.h,
7159         and get rid of the LAZY_NATIVE_CURSOR #if check because all WebKit2 platforms now support it.
7160         
7161         * Shared/ContextMenuState.h:
7162         * Shared/WebCoreArgumentCoders.cpp:
7163         (CoreIPC::::encode):
7164         (CoreIPC::::decode):
7165         * Shared/WebCoreArgumentCoders.h:
7166         * Shared/gtk/WebCoreArgumentCodersGtk.cpp:
7167         * Shared/mac/WebCoreArgumentCodersMac.mm:
7168         * Shared/qt/WebCoreArgumentCodersQt.cpp:
7169         * UIProcess/API/mac/PDFViewController.mm:
7170         * UIProcess/PageClient.h:
7171         * UIProcess/WebIconDatabase.cpp:
7172         * UIProcess/WebPageProxy.cpp:
7173         * UIProcess/WebPageProxy.h:
7174         * UIProcess/mac/WKFullScreenWindowController.mm:
7175
7176 2011-06-17  Chang Shu  <cshu@webkit.org>
7177
7178         Reviewed by Anders Carlsson.
7179
7180         [Qt] [WK2] Debug info leaks to stdout from plugins in Qt WebKit2 layout tests
7181         https://bugs.webkit.org/show_bug.cgi?id=61940
7182
7183         Tempararily supress stdout during getPluginInfo during which debug info was leaked out.
7184
7185         * Shared/Plugins/Netscape/x11/NetscapePluginModuleX11.cpp:
7186         (WebKit::StdoutRedirect::StdoutRedirect):
7187         (WebKit::StdoutRedirect::~StdoutRedirect):
7188         (WebKit::NetscapePluginModule::getPluginInfo):
7189
7190 2011-06-17  Anders Carlsson  <andersca@apple.com>
7191
7192         Reviewed by Andreas Kling.
7193
7194         Remove WebCore:: qualifier from names in WebPageProxy.
7195
7196         * UIProcess/WebPageProxy.cpp:
7197         (WebKit::WebPageProxy::dragEntered):
7198         (WebKit::WebPageProxy::dragUpdated):
7199         (WebKit::WebPageProxy::dragExited):
7200         (WebKit::WebPageProxy::performDrag):
7201         (WebKit::WebPageProxy::performDragControllerAction):
7202         (WebKit::WebPageProxy::dragEnded):
7203         (WebKit::WebPageProxy::setResizesToContentsUsingLayoutSize):
7204         (WebKit::WebPageProxy::unableToImplementPolicy):
7205         (WebKit::WebPageProxy::didChangeContentsSize):
7206         (WebKit::WebPageProxy::didFindZoomableArea):
7207         (WebKit::WebPageProxy::findZoomableAreaForPoint):
7208         (WebKit::WebPageProxy::setComposition):
7209         (WebKit::WebPageProxy::checkTextOfParagraph):
7210         (WebKit::WebPageProxy::checkGrammarOfString):
7211         (WebKit::WebPageProxy::setCursor):
7212         (WebKit::WebPageProxy::computedPagesCallback):
7213         (WebKit::WebPageProxy::canAuthenticateAgainstProtectionSpaceInFrame):
7214         (WebKit::WebPageProxy::didReceiveAuthenticationChallenge):
7215         (WebKit::WebPageProxy::showCorrectionPanel):
7216         (WebKit::WebPageProxy::dismissCorrectionPanel):
7217         (WebKit::WebPageProxy::dismissCorrectionPanelSoon):
7218         (WebKit::WebPageProxy::recordAutocorrectionResponse):
7219
7220 2011-06-17  Anders Carlsson  <andersca@apple.com>
7221
7222         Reviewed by Darin Adler.
7223
7224         Fix message generator to include headers for all types
7225         https://bugs.webkit.org/show_bug.cgi?id=62870
7226
7227         Previously, if we found an argument coder header for a type, we'd assume
7228         that that header includes the necessary headers for the type.
7229
7230         * Scripts/webkit2/messages.py:
7231         * Scripts/webkit2/messages_unittest.py:
7232
7233 2011-06-17  Chang Shu  <cshu@webkit.org>
7234
7235         Reviewed by Andreas Kling.
7236
7237         [Qt] [WK2] Support undo/redo in MiniBrowser
7238         https://bugs.webkit.org/show_bug.cgi?id=62809
7239
7240         * UIProcess/API/qt/qwkpage.cpp:
7241         (QWKPage::action):
7242         * UIProcess/API/qt/qwkpage.h:
7243
7244 2011-06-17  Carlos Garcia Campos  <cgarcia@igalia.com>
7245
7246         Unreviewed. Fix WebKit2 GTK build after r89060.
7247
7248         * Shared/gtk/WebCoreArgumentCodersGtk.cpp:
7249         (CoreIPC::::encode):
7250
7251 2011-06-16  Anders Carlsson  <andersca@apple.com>
7252
7253         Reviewed by Sam Weinig.
7254
7255         Get rid of CoreIPC::In and CoreIPC::Out from some argument coders
7256         https://bugs.webkit.org/show_bug.cgi?id=62832
7257
7258         * Shared/OriginAndDatabases.cpp:
7259         (WebKit::OriginAndDatabases::encode):
7260         (WebKit::OriginAndDatabases::decode):
7261         * Shared/SecurityOriginData.cpp:
7262         (WebKit::SecurityOriginData::encode):
7263         (WebKit::SecurityOriginData::decode):
7264         * Shared/WebKeyboardEvent.cpp:
7265         (WebKit::WebKeyboardEvent::encode):
7266         (WebKit::WebKeyboardEvent::decode):
7267         * Shared/WebOpenPanelParameters.cpp:
7268         (WebKit::WebOpenPanelParameters::Data::encode):
7269         (WebKit::WebOpenPanelParameters::Data::decode):
7270         * Shared/WebPreferencesStore.cpp:
7271         (WebKit::WebPreferencesStore::encode):
7272         (WebKit::WebPreferencesStore::decode):
7273
7274 2011-06-16  Anders Carlsson  <andersca@apple.com>
7275
7276         Reviewed by Sam Weinig.
7277
7278         Cleanup ResourceRequest, ResourceResponse and ResourceError argument coders
7279         https://bugs.webkit.org/show_bug.cgi?id=62803
7280
7281         Get rid of the free encode/decode functions and move the template specializations to their
7282         respective implementation files instead.
7283
7284         * Shared/WebCoreArgumentCoders.h:
7285         * Shared/gtk/WebCoreArgumentCodersGtk.cpp:
7286         (CoreIPC::::encode):
7287         (CoreIPC::::decode):
7288         * Shared/mac/WebCoreArgumentCodersMac.mm:
7289         (CoreIPC::::encode):
7290         (CoreIPC::::decode):
7291         * Shared/qt/WebCoreArgumentCodersQt.cpp:
7292         (CoreIPC::::encode):
7293         (CoreIPC::::decode):
7294         * Shared/win/WebCoreArgumentCodersWin.cpp:
7295         (CoreIPC::::encode):
7296         (CoreIPC::::decode):
7297
7298 2011-06-16  Chang Shu  <cshu@webkit.org>
7299
7300         Reviewed by Sam Weinig.
7301
7302         [Qt] [WK2] Qt WebKit2 needs undo/redo support
7303         https://bugs.webkit.org/show_bug.cgi?id=62637
7304
7305         Implement undo/redo support for document.execCommand().
7306
7307         * UIProcess/API/qt/qwkpage.cpp:
7308         (QWKPagePrivate::QWKPagePrivate):
7309         (QWKPagePrivate::~QWKPagePrivate):
7310         (QWKPagePrivate::registerEditCommand):
7311         (QWKPagePrivate::clearAllEditCommands):
7312         (QWKPagePrivate::canUndoRedo):
7313         (QWKPagePrivate::executeUndoRedo):
7314         * UIProcess/API/qt/qwkpage_p.h:
7315         * UIProcess/qt/WebUndoCommandQt.cpp: Added.
7316         (WebUndoCommandQt::WebUndoCommandQt):
7317         (WebUndoCommandQt::~WebUndoCommandQt):
7318         (WebUndoCommandQt::redo):
7319         (WebUndoCommandQt::undo):
7320         * UIProcess/qt/WebUndoCommandQt.h: Added.
7321         (WebUndoCommandQt::inUndoRedo):
7322         * WebKit2.pro:
7323
7324 2011-06-16  Anders Carlsson  <andersca@apple.com>
7325
7326         Fix build.
7327
7328         * Shared/WebCoreArgumentCoders.cpp:
7329         * Shared/WebCoreArgumentCoders.h:
7330
7331 2011-06-15  Anders Carlsson  <andersca@apple.com>
7332
7333         Reviewed by Sam Weinig.
7334
7335         Move more argument coders to WebCoreArgumentCoders and clean up the animation coders
7336         https://bugs.webkit.org/show_bug.cgi?id=62760
7337
7338         * Shared/WebCoreArgumentCoders.cpp:
7339         (CoreIPC::::encode):
7340         (CoreIPC::::decode):
7341         (CoreIPC::encodeOperation):
7342         (CoreIPC::decodeOperation):
7343         (CoreIPC::encodeBoolAndValue):
7344         (CoreIPC::encodeBoolAndEnumValue):
7345         (CoreIPC::decodeBoolAndValue):
7346         (CoreIPC::decodeBoolAndEnumValue):
7347         * Shared/WebCoreArgumentCoders.h:
7348         * Shared/mac/ArgumentCodersMac.h:
7349         * Shared/mac/ArgumentCodersMac.mm:
7350         * Shared/mac/WebCoreArgumentCodersMac.mm:
7351         (CoreIPC::::encode):
7352         (CoreIPC::::decode):
7353
7354 2011-06-16  Sangyong Park  <sy302.park@gmail.com>
7355
7356         Reviewed by Martin Robinson.
7357
7358         [GTK] Implement ResourceRequest and ResourceResponse encoder/decoder
7359         https://bugs.webkit.org/show_bug.cgi?id=55934
7360
7361         * Shared/gtk/WebCoreArgumentCodersGtk.cpp:
7362         (CoreIPC::encodeResourceRequest):
7363         (CoreIPC::decodeResourceRequest):
7364         (CoreIPC::encodeResourceResponse):
7365         (CoreIPC::decodeResourceResponse):
7366
7367 2011-06-16  Carlos Garcia Campos  <cgarcia@igalia.com>
7368
7369         Reviewed by Xan Lopez.
7370
7371         [GTK] Remove support for GTK+2 in WebKit2
7372         https://bugs.webkit.org/show_bug.cgi?id=62794
7373
7374         * UIProcess/API/gtk/WebKitWebViewBase.cpp:
7375         (webkitWebViewBaseRealize):
7376         (webkitWebViewBaseDraw):
7377         (webkitWebViewBaseQueryTooltip):
7378         (webkit_web_view_base_class_init):
7379         (webkitWebViewBaseSetTooltipText):
7380         * UIProcess/gtk/WebContextMenuProxyGtk.cpp:
7381         (WebKit::WebContextMenuProxyGtk::menuPositionFunction):
7382         * WebProcess/Plugins/Netscape/x11/NetscapePluginX11.cpp:
7383         (WebKit::moduleMixesGtkSymbols):
7384
7385 2011-06-15  Adam Barth  <abarth@webkit.org>
7386
7387         Reviewed by Eric Seidel.
7388
7389         Remove ScriptController::setAllowPopupsFromPlugin
7390         https://bugs.webkit.org/show_bug.cgi?id=62706
7391
7392         * WebProcess/Plugins/PluginView.cpp:
7393         (WebKit::PluginView::performJavaScriptURLRequest):
7394         (WebKit::PluginView::evaluate):
7395
7396 2011-06-15  Ryuan Choi  <ryuan.choi@samsung.com>
7397
7398         Rubber stamped by Eric Seidel.
7399
7400         [CMAKE][WK2] Add an option to build webkit2.
7401         https://bugs.webkit.org/show_bug.cgi?id=62260
7402
7403         Add script to build WebKit2 using CMake.
7404
7405         * CMakeLists.txt: Added.
7406
7407 2011-06-15  John Sullivan  <sullivan@apple.com>
7408
7409         Reviewed by Sam Weinig.
7410
7411         WKSecurityOriginGetProtocol and WKSecurityOriginGetHost are named wrong because they return copied strings
7412         <https://bugs.webkit.org/show_bug.cgi?id=62763>
7413         <rdar://problem/9618071>
7414
7415         * Shared/API/c/WKSecurityOrigin.cpp:
7416         (WKSecurityOriginCopyProtocol):
7417         Renamed to use "Copy" instead of "Get" because it returns a copy.
7418         (WKSecurityOriginCopyHost):
7419         Ditto.
7420
7421         * Shared/API/c/WKSecurityOrigin.h:
7422         Updated declarations.
7423
7424 2011-06-14  Jon Honeycutt  <jhoneycutt@apple.com>
7425
7426         REGRESSION(78201): Windowless Flash plug-ins are transparent on some sites
7427         https://bugs.webkit.org/show_bug.cgi?id=62690
7428         <rdar://problem/9512026>
7429
7430         Reviewed by Ada Chan.
7431
7432         The bug arises when mixing CoreGraphics and GDI. When we create a Windows
7433         bitmap for a windowless plug-in to draw into, we first fill it with "clear",
7434         or all 0s. If the plug-in uses GDI to draw, the GDI calls will ignore the
7435         alpha channel, and if we then use CG to blend this bitmap onto the
7436         GraphicsContext for the rest of the page, CG will treat the 0-filled
7437         alpha channel as being transparent.
7438
7439         To fix this, on Windows, use a GDI-backed GraphicsContext to paint the
7440         page in the WebProcess, and use GDI to blit from the UpdateInfo to the
7441         backing store in the UI process.
7442
7443         * Platform/SharedMemory.h:
7444         (WebKit::SharedMemory::handle):
7445         Return the handle for the memory.
7446
7447         * Shared/ShareableBitmap.h:
7448         Declared windowsContext() to return a HDC with the bitmap selected into it.
7449         Added members to store the HDC and the HBITMAP.
7450
7451         * Shared/win/ShareableBitmapWin.cpp: Added.
7452         (WebKit::ShareableBitmap::windowsContext):
7453         Get the screen DC, and create a compatible DC from it. Create a DIB
7454         section backed by the shared memory, select it into the context, and
7455         return it.
7456
7457         * UIProcess/win/BackingStoreWin.cpp:
7458         (WebKit::BackingStore::incorporateUpdate):
7459         Use GDI to blit from the update info's bitmap into the backing store bitmap.
7460
7461         * WebProcess/WebPage/DrawingAreaImpl.cpp:
7462         (WebKit::DrawingAreaImpl::createGraphicsContext):
7463         Return a GraphicsContext from the ShareableBitmap.
7464         (WebKit::DrawingAreaImpl::display):
7465         Call createGraphicsContext(), and pass the ShareableBitmap.
7466
7467         * WebProcess/WebPage/DrawingAreaImpl.h:
7468         Declare createGraphicsContext(), which on Windows will create a GDI-backed
7469         GraphicsContext.
7470
7471         * WebProcess/WebPage/win/DrawingAreaImplWin.cpp: Added.
7472         (WebKit::DrawingAreaImpl::createGraphicsContext):
7473         Get a Windows context for the bitmap, and create and return a new
7474         GraphicsContext using the DC.
7475
7476         * win/WebKit2.vcproj:
7477         Added new files.
7478
7479 2011-06-15  Anders Carlsson  <andersca@apple.com>
7480
7481         Reviewed by Sam Weinig.
7482
7483         Move more argument coders to WebCoreArgumentCoders.cpp
7484         https://bugs.webkit.org/show_bug.cgi?id=62755
7485
7486         * Shared/WebCoreArgumentCoders.cpp:
7487         (CoreIPC::::decode):
7488         (CoreIPC::::encode):
7489         (CoreIPC::encodeImage):
7490         (CoreIPC::decodeImage):
7491         * Shared/WebCoreArgumentCoders.h:
7492
7493 2011-06-15  Anders Carlsson  <andersca@apple.com>
7494
7495         Reviewed by Darin Adler.
7496
7497         Add ShareableBitmap::createImage and get rid of WebCoreArgumentCodersCG.cpp
7498         https://bugs.webkit.org/show_bug.cgi?id=62742
7499
7500         * Shared/ShareableBitmap.h:
7501         Move createImage out of the #if PLATFORM(QT) section.
7502
7503         * Shared/WebCoreArgumentCoders.cpp:
7504         (CoreIPC::decodeImage):
7505         Call ShareableBitmap::createImage.
7506
7507         * Shared/WebCoreArgumentCoders.h:
7508         remove createImage function declaration.
7509
7510         * Shared/cairo/ShareableBitmapCairo.cpp:
7511         (WebKit::ShareableBitmap::createImage):
7512         Add implementation.
7513
7514         * Shared/cg/ShareableBitmapCG.cpp:
7515         (WebKit::ShareableBitmap::createGraphicsContext):
7516         (WebKit::ShareableBitmap::createImage):
7517         Move createImage implementation from WebCoreArgumentCodersCG.cpp here.
7518
7519         * WebKit2.xcodeproj/project.pbxproj:
7520         * win/WebKit2.vcproj:
7521         Update projects.
7522
7523 2011-06-15  Anders Carlsson  <andersca@apple.com>
7524
7525         Reviewed by Alexey Proskuryakov.
7526
7527         Move some argument coders to WebCoreArgumentCoders.cpp
7528         https://bugs.webkit.org/show_bug.cgi?id=62739
7529
7530         * GNUmakefile.am:
7531         * Shared/WebCoreArgumentCoders.cpp:
7532         (CoreIPC::::encode):
7533         (CoreIPC::::decode):
7534         * Shared/WebCoreArgumentCoders.h:
7535         * WebKit2.pro:
7536
7537 2011-06-15  Anders Carlsson  <andersca@apple.com>
7538
7539         Reviewed by Sam Weinig.
7540
7541         Fix possible null dereference in webSecKeychainItemCreateFromContentOnMainThread
7542         https://bugs.webkit.org/show_bug.cgi?id=62736
7543         <rdar://problem/9601595>
7544
7545         * WebProcess/mac/KeychainItemShimMethods.mm:
7546         (WebKit::webSecKeychainItemCreateFromContentOnMainThread):
7547         SecKeychainItemCreateFromContent can potentially return a null keychain item, so add a null check before trying to retain it.
7548
7549 2011-06-15  Anders Carlsson  <andersca@apple.com>
7550
7551         Reviewed by Dan Bernstein.
7552
7553         Ignore responsiveness timer callbacks on closed pages
7554         https://bugs.webkit.org/show_bug.cgi?id=62735
7555         <rdar://problem/9511295>
7556
7557         * UIProcess/WebPageProxy.cpp:
7558         (WebKit::WebPageProxy::close):
7559         Use nullptr instead of clear.
7560
7561         (WebKit::WebPageProxy::processDidBecomeUnresponsive):
7562         Return early if the page isn't valid.
7563
7564         (WebKit::WebPageProxy::processDidBecomeResponsive):
7565         Ditto.
7566
7567         (WebKit::WebPageProxy::updateBackingStoreDiscardableState):
7568         Assert that the page is valid.
7569
7570 2011-06-15  Sheriff Bot  <webkit.review.bot@gmail.com>
7571
7572         Unreviewed, rolling out r88907.
7573         http://trac.webkit.org/changeset/88907
7574         https://bugs.webkit.org/show_bug.cgi?id=62732
7575
7576         See comment #15 by Nikolas Zimmermann on bug 62527 regarding
7577         the deprecation of makeString() (Requested by acidx on
7578         #webkit).
7579
7580         * UIProcess/efl/WebPageProxyEfl.cpp:
7581         (WebKit::WebPageProxy::standardUserAgent):
7582
7583 2011-06-15  Csaba Osztrogonác  <ossy@webkit.org>
7584
7585         [Qt][WK2] Unreviewed rolling out r88799, because it made web process crash.
7586
7587         * Scripts/webkit2/messages.py:
7588         * Shared/LayerTreeContext.h:
7589         * Shared/qt/LayerTreeContextQt.cpp:
7590         (WebKit::LayerTreeContext::LayerTreeContext):
7591         (WebKit::LayerTreeContext::~LayerTreeContext):
7592         (WebKit::LayerTreeContext::encode):
7593         (WebKit::LayerTreeContext::decode):
7594         (WebKit::LayerTreeContext::isEmpty):
7595         (WebKit::operator==):
7596         * UIProcess/DrawingAreaProxy.h:
7597         * UIProcess/DrawingAreaProxy.messages.in:
7598         * WebKit2.pro:
7599         * WebProcess/WebCoreSupport/WebGraphicsLayer.cpp:
7600         (WebCore::collectCompositingInfoForThisLayer):
7601         * WebProcess/WebPage/LayerTreeHost.cpp:
7602         (WebKit::LayerTreeHost::create):
7603         * WebProcess/WebPage/qt/LayerTreeHostQt.cpp:
7604         * WebProcess/WebPage/qt/LayerTreeHostQt.h: Removed.
7605
7606 2011-06-14  Eunmi Lee  <eunmi15.lee@samsung.com>
7607
7608         Reviewed by Sam Weinig.
7609
7610         [EFL][WK2] Change string operation to makeString()
7611         https://bugs.webkit.org/show_bug.cgi?id=62527
7612
7613         Use makeString() because it is better than creating individual strings and concatenating them.
7614
7615         * UIProcess/efl/WebPageProxyEfl.cpp:
7616         (WebKit::WebPageProxy::standardUserAgent):
7617
7618 2011-06-14  Sam Weinig  <sam@webkit.org>
7619
7620         Reviewed by Simon Fraser.
7621
7622         Follow up for Callers should be robust against WebImage::create() returning an image with a null snapshot
7623         https://bugs.webkit.org/show_bug.cgi?id=62666
7624
7625         * Shared/API/c/cg/WKImageCG.cpp:
7626         (WKImageCreateCGImage):
7627         (WKImageCreateFromCGImage):
7628         Don't null check the arguments (as per our API design) or the direct result of WebImage::create.
7629
7630         * Shared/UserMessageCoders.h:
7631         (WebKit::UserMessageEncoder::baseEncode):
7632         Remove redundant check and make not being able to create a handle the same
7633         as not being backed by shareable memory.
7634
7635 2011-06-14  John Sullivan  <sullivan@apple.com>
7636
7637         Reviewed by Ada Chan.
7638
7639         <https://bugs.webkit.org/show_bug.cgi?id=62693>
7640         <rdar://problem/9601436>
7641         windowsKeyCodeForKeyEvent should be robust against NSFlagsChanged events
7642
7643         * Shared/mac/WebEventFactory.mm:
7644         (WebKit::windowsKeyCodeForKeyEvent):
7645         Explicitly check for NSFlagsChanged before calling -charactersIgnoringModifiers, since
7646         charactersIgnoringModifiers throws an exception for NSFlagsChanged events.
7647
7648 2011-06-14  Anders Carlsson  <andersca@apple.com>
7649
7650         Reviewed by Sam Weinig.
7651
7652         Use new byte array encoding/decoding functions for WTF argument coders
7653         https://bugs.webkit.org/show_bug.cgi?id=62682
7654
7655         * Platform/CoreIPC/ArgumentCoders.cpp:
7656         (CoreIPC::::encode):
7657         (CoreIPC::::decode):
7658         Use the new functions for the string argument coders.
7659         
7660         * Platform/CoreIPC/ArgumentCoders.h:
7661         (CoreIPC::SimpleArgumentCoder::encode):
7662         (CoreIPC::SimpleArgumentCoder::decode):
7663         Use the new functions to avoid encoding/decoding the size when it's known at decode time.
7664
7665         * Platform/CoreIPC/ArgumentDecoder.cpp:
7666         (CoreIPC::roundUpToAlignment):
7667         Assert that the alignment is a power of 2.
7668
7669         (CoreIPC::decodeFixedLengthData):
7670         Alignment comes before the size.
7671
7672         * UIProcess/cf/WebBackForwardListCF.cpp:
7673         (WebKit::WebBackForwardList::createCFDictionaryRepresentation):
7674         Add a FIXME about now using the internal CoreIPC encoding format here.
7675
7676         * UIProcess/cf/WebPageProxyCF.cpp:
7677         Bump the current session state data version number.
7678
7679 2011-06-14  No'am Rosenthal  <noam.rosenthal@nokia.com>
7680
7681         Reviewed by Kenneth Rohde Christiansen.
7682
7683         [Qt] Implement accelerated compositing on WK2 Qt port
7684         https://bugs.webkit.org/show_bug.cgi?id=56935
7685
7686         Expose viewportVisibleRect(), so that we can detect which parts of a texture actually
7687         need to be uploaded.
7688
7689         Together with Viatcheslav Ostapenko.
7690
7691         * UIProcess/API/qt/qwkpage.cpp:
7692         (QWKPagePrivate::viewportVisibleRect):
7693         * UIProcess/API/qt/qwkpage_p.h:
7694         * UIProcess/PageClient.h:
7695         * UIProcess/WebPageProxy.h:
7696         * UIProcess/qt/WebPageProxyQt.cpp:
7697         (WebKit::WebPageProxy::viewportVisibleRect):
7698
7699 2011-06-14  Anders Carlsson  <andersca@apple.com>
7700
7701         Reviewed by Sam Weinig.
7702
7703         Start using the new encode/decode functions
7704         https://bugs.webkit.org/show_bug.cgi?id=62676
7705
7706         * Platform/CoreIPC/DataReference.cpp:
7707         (CoreIPC::DataReference::encode):
7708         Use encodeVariableLengthByteArray.
7709
7710         * Shared/UserMessageCoders.h:
7711         (WebKit::UserMessageEncoder::baseEncode):
7712         Use encodeVariableLengthByteArray and the new dataReference accessors.
7713
7714         (WebKit::UserMessageDecoder::baseDecode):
7715         Use decodeVariableLengthByteArray.
7716  
7717         * Shared/WebData.h:
7718         (WebKit::WebData::dataReference):
7719         Return a reference to the data.
7720
7721         * Shared/WebSerializedScriptValue.h:
7722         (WebKit::WebSerializedScriptValue::dataReference):
7723         Ditto.
7724
7725         * Shared/cf/ArgumentCodersCF.cpp:
7726         (CoreIPC::encode):
7727         Use encodeVariableLengthByteArray.
7728
7729         * Shared/mac/SandboxExtensionMac.mm:
7730         (WebKit::SandboxExtension::Handle::encode):
7731         Use encodeVariableLengthByteArray.
7732
7733         * WebProcess/WebPage/DecoderAdapter.cpp:
7734         (WebKit::DecoderAdapter::decodeBytes):
7735         Use decodeVariableLengthByteArray.
7736
7737         * WebProcess/WebPage/EncoderAdapter.cpp:
7738         (WebKit::EncoderAdapter::dataReference):
7739         Rename data() to dataReference() to indicate that it returns a reference to the data.
7740
7741         (WebKit::EncoderAdapter::encodeBytes):
7742         Use encodeVariableLengthByteArray.
7743
7744 2011-06-14  Anders Carlsson  <andersca@apple.com>
7745
7746         Reviewed by Sam Weinig.
7747
7748         Add encodeVariableLengthByteArray and decodeVariableLengthByteArray
7749         https://bugs.webkit.org/show_bug.cgi?id=62674
7750
7751         Rename the ArgumentDecoder::decodeBytes overload that takes a DataReference to
7752         decodeVariableLengthByteArray, to match the added encodeVariableLengthByteArray.
7753
7754         * Platform/CoreIPC/ArgumentDecoder.cpp:
7755         (CoreIPC::ArgumentDecoder::decodeVariableLengthByteArray):
7756         * Platform/CoreIPC/ArgumentDecoder.h:
7757         * Platform/CoreIPC/ArgumentEncoder.cpp:
7758         (CoreIPC::ArgumentEncoder::encodeFixedLengthData):
7759         (CoreIPC::ArgumentEncoder::encodeVariableLengthByteArray):
7760         * Platform/CoreIPC/ArgumentEncoder.h:
7761         * Platform/CoreIPC/DataReference.cpp:
7762         (CoreIPC::DataReference::decode):
7763         * Shared/mac/SandboxExtensionMac.mm:
7764         (WebKit::SandboxExtension::Handle::decode):
7765
7766 2011-06-14  Anders Carlsson  <andersca@apple.com>
7767
7768         Reviewed by Sam Weinig.
7769
7770         Add functions for converting between DataReferences and vectors
7771         https://bugs.webkit.org/show_bug.cgi?id=62671
7772
7773         * Platform/CoreIPC/DataReference.h:
7774         (CoreIPC::DataReference::DataReference):
7775         New implicit constructor that takes a vector.
7776
7777         (CoreIPC::DataReference::vector):
7778         New function that returns a new vector.
7779
7780         * Shared/WebBackForwardListItem.cpp:
7781         (WebKit::WebBackForwardListItem::encode):
7782         Use implicit constructor.
7783
7784         * WebProcess/WebPage/WebPage.cpp:
7785         (WebKit::WebPage::runJavaScriptInMainFrame):
7786         Ditto.
7787
7788 2011-06-14  John Sullivan  <sullivan@apple.com>
7789
7790         Reviewed by Dan Bernstein.
7791
7792         <https://bugs.webkit.org/show_bug.cgi?id=62666>
7793         <rdar://problem/9606676>
7794         Callers should be robust against WebImage::create() returning an image with a null snapshot
7795
7796         * Shared/API/c/cg/WKImageCG.cpp:
7797         (WKImageCreateCGImage):
7798         Return 0 if no bitmap was created.
7799         (WKImageCreateFromCGImage):
7800         Ditto.
7801         
7802         * Shared/UserMessageCoders.h:
7803         (WebKit::UserMessageEncoder::baseEncode):
7804         Check for null before dereferencing image->bitmap() in two places.
7805         
7806         * WebProcess/WebPage/WebPage.cpp:
7807         (WebKit::WebPage::snapshotInViewCoordinates):
7808         Return 0 if no bitmap was created.
7809         (WebKit::WebPage::scaledSnapshotInDocumentCoordinates):
7810         Ditto.
7811         (WebKit::WebPage::createSnapshotOfVisibleContent):
7812         Bail out if no bitmap was created.
7813
7814 2011-06-14  Anders Carlsson  <andersca@apple.com>
7815
7816         Reviewed by Darin Adler.
7817
7818         Add functions for encoding/decoding data with a known size and alignment
7819         https://bugs.webkit.org/show_bug.cgi?id=62663
7820
7821         * Platform/CoreIPC/ArgumentDecoder.cpp:
7822         (CoreIPC::ArgumentDecoder::decodeFixedLengthData):
7823         * Platform/CoreIPC/ArgumentDecoder.h:
7824         * Platform/CoreIPC/ArgumentEncoder.cpp:
7825         (CoreIPC::ArgumentEncoder::encodeFixedLengthData):
7826         (CoreIPC::ArgumentEncoder::encodeVariableLengthData):
7827         * Platform/CoreIPC/ArgumentEncoder.h:
7828
7829 2011-06-14  Anders Carlsson  <andersca@apple.com>
7830
7831         Reviewed by Sam Weinig.
7832
7833         Move string ArgumentCoder template specializations out into a .cpp file
7834         https://bugs.webkit.org/show_bug.cgi?id=62660
7835
7836         * GNUmakefile.am:
7837         * Platform/CoreIPC/ArgumentCoders.cpp: Added.
7838         (CoreIPC::::encode):
7839         (CoreIPC::::decode):
7840         * Platform/CoreIPC/ArgumentCoders.h:
7841         * WebKit2.pro:
7842         * WebKit2.xcodeproj/project.pbxproj:
7843         * win/WebKit2.vcproj:
7844
7845 2011-06-14  Anders Carlsson  <andersca@apple.com>
7846
7847         Reviewed by Sam Weinig.
7848
7849         Remove PluginInfoStore::Plugin typedef
7850         https://bugs.webkit.org/show_bug.cgi?id=62657
7851
7852         * UIProcess/Plugins/PluginInfoStore.h:
7853         * UIProcess/Plugins/win/PluginInfoStoreWin.cpp:
7854         (WebKit::PluginInfoStore::getPluginInfo):
7855         (WebKit::PluginInfoStore::shouldUsePlugin):
7856
7857 2011-06-14  Anders Carlsson  <andersca@apple.com>
7858
7859         Reviewed by Sam Weinig.
7860
7861         Create the PluginModuleInfo class and reverse the typedef so that PluginInfoStore::Plugin is now a typedef
7862         https://bugs.webkit.org/show_bug.cgi?id=62654
7863
7864         * UIProcess/Plugins/PluginInfoStore.cpp:
7865         (WebKit::PluginInfoStore::loadPluginsIfNecessary):
7866         (WebKit::PluginInfoStore::loadPlugin):
7867         (WebKit::PluginInfoStore::findPluginForMIMEType):
7868         (WebKit::PluginInfoStore::findPluginForExtension):
7869         (WebKit::PluginInfoStore::findPlugin):
7870         (WebKit::PluginInfoStore::infoForPluginWithPath):
7871         * UIProcess/Plugins/PluginInfoStore.h:
7872         * UIProcess/Plugins/PluginProcessManager.cpp:
7873         (WebKit::PluginProcessManager::getPluginProcessConnection):
7874         * UIProcess/Plugins/PluginProcessProxy.cpp:
7875         (WebKit::PluginProcessProxy::PluginProcessProxy):
7876         * UIProcess/Plugins/WebPluginSiteDataManager.cpp:
7877         (WebKit::WebPluginSiteDataManager::getSitesWithData):
7878         (WebKit::WebPluginSiteDataManager::clearSiteData):
7879         * UIProcess/Plugins/mac/PluginInfoStoreMac.mm:
7880         (WebKit::PluginInfoStore::getPluginInfo):
7881         (WebKit::PluginInfoStore::shouldUsePlugin):
7882         * UIProcess/Plugins/unix/PluginInfoStoreUnix.cpp:
7883         (WebKit::PluginInfoStore::getPluginInfo):
7884         (WebKit::PluginInfoStore::shouldUsePlugin):
7885         * UIProcess/Plugins/win/PluginInfoStoreWin.cpp:
7886         (WebKit::isOldWindowsMediaPlayerPlugin):
7887         (WebKit::isNewWindowsMediaPlayerPlugin):
7888         (WebKit::PluginInfoStore::shouldUsePlugin):
7889
7890 2011-06-14  Stephanie Lewis  <slewis@apple.com>
7891
7892         Rubber stamped by Oliver Hunt.
7893
7894         <rdar://problem/9511169>
7895         Update order files.
7896
7897         * mac/WebKit2.order:
7898
7899 2011-06-14  Anders Carlsson  <andersca@apple.com>
7900
7901         Reviewed by Dan Bernstein.
7902
7903         Start replacing PluginInfoStore::Plugin with PluginModuleInfo
7904         https://bugs.webkit.org/show_bug.cgi?id=62651
7905
7906         * UIProcess/Plugins/PluginInfoStore.cpp:
7907         (WebKit::PluginInfoStore::plugins):
7908         (WebKit::PluginInfoStore::findPluginForMIMEType):
7909         (WebKit::PluginInfoStore::findPluginForExtension):
7910         (WebKit::PluginInfoStore::infoForPluginWithPath):
7911         * UIProcess/Plugins/PluginInfoStore.h:
7912         * UIProcess/Plugins/PluginProcessManager.cpp:
7913         (WebKit::PluginProcessManager::getPluginProcessConnection):
7914         (WebKit::PluginProcessManager::getSitesWithData):
7915         (WebKit::PluginProcessManager::clearSiteData):
7916         (WebKit::PluginProcessManager::getOrCreatePluginProcess):
7917         * UIProcess/Plugins/PluginProcessManager.h:
7918         * UIProcess/Plugins/PluginProcessProxy.cpp:
7919         (WebKit::PluginProcessProxy::create):
7920         * UIProcess/Plugins/PluginProcessProxy.h:
7921         (WebKit::PluginProcessProxy::pluginInfo):
7922         * UIProcess/Plugins/mac/PluginProcessProxyMac.mm:
7923         (WebKit::PluginProcessProxy::pluginNeedsExecutableHeap):
7924         (WebKit::PluginProcessProxy::createPropertyListFile):
7925
7926 2011-06-14  Anders Carlsson  <andersca@apple.com>
7927
7928         Reviewed by Darin Adler.
7929
7930         Add PluginModuleInfo header and prepare for renaming of PluginInfoStore::Plugin to PluginModuleInfo
7931         https://bugs.webkit.org/show_bug.cgi?id=62647
7932
7933         Make PluginModuleInfo a typedef of PluginInfoStore::Plugin for now; eventually it should be its own class,
7934         and PluginInfoStore::Plugin should go away.
7935
7936         * GNUmakefile.am:
7937         * Shared/Plugins/Netscape/NetscapePluginModule.h:
7938         * Shared/Plugins/Netscape/mac/NetscapePluginModuleMac.mm:
7939         (WebKit::getPluginArchitecture):
7940         (WebKit::getMIMETypesFromPluginBundle):
7941         (WebKit::getPluginInfoFromPropertyLists):
7942         (WebKit::getPluginInfoFromCarbonResources):
7943         (WebKit::NetscapePluginModule::getPluginInfo):
7944         (WebKit::NetscapePluginModule::determineQuirks):
7945         * Shared/Plugins/PluginModuleInfo.cpp: Added.
7946         * Shared/Plugins/PluginModuleInfo.h: Added.
7947         * WebKit2.pro:
7948         * WebKit2.xcodeproj/project.pbxproj:
7949         * win/WebKit2.vcproj:
7950
7951 2011-06-14  Carlos Garcia Campos  <cgarcia@igalia.com>
7952
7953         Reviewed by Martin Robinson.
7954
7955         [GTK] Move the code to show the context menu from WebKitWebViewBase to WebContextMenuProxyGtk
7956         https://bugs.webkit.org/show_bug.cgi?id=62627
7957
7958         * UIProcess/API/gtk/WebKitWebViewBase.cpp:
7959         * UIProcess/API/gtk/WebKitWebViewBasePrivate.h:
7960         * UIProcess/gtk/WebContextMenuProxyGtk.cpp:
7961         (WebKit::WebContextMenuProxyGtk::showContextMenu):
7962         (WebKit::WebContextMenuProxyGtk::hideContextMenu):
7963         (WebKit::WebContextMenuProxyGtk::WebContextMenuProxyGtk):
7964         (WebKit::WebContextMenuProxyGtk::~WebContextMenuProxyGtk):
7965         (WebKit::WebContextMenuProxyGtk::menuPositionFunction):
7966         * UIProcess/gtk/WebContextMenuProxyGtk.h:
7967
7968 2011-06-14  Carlos Garcia Campos  <cgarcia@igalia.com>
7969
7970         Reviewed by Martin Robinson.
7971
7972         [GTK] Rename convertWidgetRectToScreenRect() to convertWidgetPointToScreenPoint()
7973         https://bugs.webkit.org/show_bug.cgi?id=62626
7974
7975         * UIProcess/API/gtk/PageClientImpl.cpp:
7976         (WebKit::PageClientImpl::screenToWindow): Implement this method
7977         using convertWidgetPointToScreenPoint().
7978         (WebKit::PageClientImpl::windowToScreen): Update to use
7979         convertWidgetPointToScreenPoint().
7980         * UIProcess/gtk/WebPopupMenuProxyGtk.cpp:
7981         (WebKit::WebPopupMenuProxyGtk::showPopupMenu): Use
7982         convertWidgetPointToScreenPoint().
7983
7984 2011-06-14  Carlos Garcia Campos  <cgarcia@igalia.com>
7985
7986         Reviewed by Martin Robinson.
7987
7988         [GTK] Support authentication dialogs in WebKit2
7989         https://bugs.webkit.org/show_bug.cgi?id=62366
7990
7991         Add a new soup feature to show an authentication dialog when it
7992         gets a 401 HTTP response.
7993
7994         * GNUmakefile.am: Add new files to compilation.
7995         * WebProcess/gtk/WebAuthDialog.cpp: Added.
7996         (web_auth_dialog_class_init):
7997         (web_auth_dialog_init):
7998         (sessionAuthenticate):
7999         (attach):
8000         (detach):
8001         (webAuthDialogSessionFeatureInit):
8002         * WebProcess/gtk/WebAuthDialog.h: Added.
8003         * WebProcess/gtk/WebProcessMainGtk.cpp:
8004         (WebKit::WebProcessMainGtk):
8005
8006 2011-06-14  No'am Rosenthal  <noam.rosenthal@nokia.com> and Viatcheslav Ostapenko <ostapenko.viatcheslav@nokia.com>
8007
8008         Reviewed by Kenneth Rohde Christiansen.
8009
8010         [Qt] Implement accelerated compositing on WK2 Qt port
8011         https://bugs.webkit.org/show_bug.cgi?id=56935
8012
8013         Implementing LayerTreeHost and LayerTreeContext and LayerTreeHost for Qt.
8014         Add the necessary plumbing to make the LayerTreeHost work with Qt, based on the original Mac
8015         implementation (the code is nearly identical). This includes creating the right layers for the
8016         overlay and for the non-composited content, and passing the root layer to the UI process.
8017
8018         Also, since LayerTreeHostQt is compiled, we have to add some of the rest of the existing patches,
8019         namely the new messages: syncCompositingLayers and updateCompositingLayerContent, and create a
8020         stub implementation for them in DrawingAreaProxy.
8021
8022         Note that this is not activated yet, until we enable accelerated compositing in the settings and
8023         create the right GraphicsLayer.
8024
8025         * Scripts/webkit2/messages.py:
8026         * Shared/LayerTreeContext.h:
8027         * Shared/qt/LayerTreeContextQt.cpp:
8028         (WebKit::LayerTreeContext::LayerTreeContext):
8029         (WebKit::LayerTreeContext::~LayerTreeContext):
8030         (WebKit::LayerTreeContext::encode):
8031         (WebKit::LayerTreeContext::decode):
8032         (WebKit::LayerTreeContext::isEmpty):
8033         (WebKit::operator==):
8034         * UIProcess/DrawingAreaProxy.h:
8035         (WebKit::DrawingAreaProxy::syncCompositingLayers):
8036         (WebKit::DrawingAreaProxy::updateCompositingLayerContent):
8037         * UIProcess/DrawingAreaProxy.messages.in:
8038         * WebKit2.pro:
8039         * WebProcess/WebCoreSupport/WebGraphicsLayer.cpp:
8040         (WebCore::collectCompositingInfoForThisLayer):
8041         * WebProcess/WebPage/LayerTreeHost.cpp:
8042         (WebKit::LayerTreeHost::create):
8043         * WebProcess/WebPage/qt/LayerTreeHostQt.cpp:
8044         (WebKit::LayerTreeHostQt::create):
8045         (WebKit::LayerTreeHostQt::~LayerTreeHostQt):
8046         (WebKit::LayerTreeHostQt::LayerTreeHostQt):
8047         (WebKit::LayerTreeHostQt::setLayerFlushSchedulingEnabled):
8048         (WebKit::LayerTreeHostQt::scheduleLayerFlush):
8049         (WebKit::LayerTreeHostQt::cancelPendingLayerFlush):
8050         (WebKit::LayerTreeHostQt::setShouldNotifyAfterNextScheduledLayerFlush):
8051         (WebKit::LayerTreeHostQt::setRootCompositingLayer):
8052         (WebKit::LayerTreeHostQt::invalidate):
8053         (WebKit::LayerTreeHostQt::setNonCompositedContentsNeedDisplay):
8054         (WebKit::LayerTreeHostQt::scrollNonCompositedContents):
8055         (WebKit::LayerTreeHostQt::forceRepaint):
8056         (WebKit::LayerTreeHostQt::sizeDidChange):
8057         (WebKit::LayerTreeHostQt::didInstallPageOverlay):
8058         (WebKit::LayerTreeHostQt::didUninstallPageOverlay):
8059         (WebKit::LayerTreeHostQt::setPageOverlayNeedsDisplay):
8060         (WebKit::LayerTreeHostQt::flushPendingLayerChanges):
8061         (WebKit::LayerTreeHostQt::performScheduledLayerFlush):
8062         (WebKit::LayerTreeHostQt::layerFlushTimerFired):
8063         (WebKit::LayerTreeHostQt::createPageOverlayLayer):
8064         (WebKit::LayerTreeHostQt::destroyPageOverlayLayer):
8065         (WebKit::LayerTreeHostQt::notifyAnimationStarted):
8066         (WebKit::LayerTreeHostQt::notifySyncRequired):
8067         (WebKit::LayerTreeHostQt::paintContents):
8068         (WebKit::LayerTreeHostQt::showDebugBorders):
8069         (WebKit::LayerTreeHostQt::showRepaintCounter):
8070         (WebKit::LayerTreeHost::supportsAcceleratedCompositing):
8071         * WebProcess/WebPage/qt/LayerTreeHostQt.h: Added.
8072         (WebKit::LayerTreeHostQt::layerTreeContext):
8073         (WebKit::LayerTreeHostQt::pauseRendering):
8074         (WebKit::LayerTreeHostQt::resumeRendering):
8075
8076 2011-06-14  Noam Rosenthal  <noam.rosenthal@nokia.com>
8077
8078         Reviewed by Kenneth Rohde Christiansen.
8079
8080         [Qt] Implement accelerated compositing on WK2 Qt port
8081         https://bugs.webkit.org/show_bug.cgi?id=56935
8082
8083         Add a createImage() function to ShareableBitmap, for now ifdef'ed to Qt only.
8084         This allows us to support directly composited images across the WebKit2 processes.
8085
8086         Together with Viatcheslav Ostapenko.
8087
8088         * Shared/ShareableBitmap.h:
8089         * Shared/qt/ShareableBitmapQt.cpp:
8090         (WebKit::ShareableBitmap::createQImage):
8091         (WebKit::ShareableBitmap::createImage):
8092
8093 2011-06-13  Anders Carlsson  <andersca@apple.com>
8094
8095         Reviewed by Sam Weinig.
8096
8097         Crash when trying to use Netflix Watch Instantly with Silverlight 3
8098         https://bugs.webkit.org/show_bug.cgi?id=62611
8099         <rdar://problem/9058370>
8100
8101         * Shared/Plugins/Netscape/mac/NetscapePluginModuleMac.mm:
8102         (WebKit::NetscapePluginModule::getPluginInfo):
8103         Get the plug-in version string instead of the version number.
8104
8105         (WebKit::PluginVersion::isValid):
8106         (WebKit::PluginVersion::PluginVersion):
8107         (WebKit::PluginVersion::parse):
8108         (WebKit::PluginVersion::isLessThan):
8109         Add a new PluginVersion class that represents a plug-in version. The idea is
8110         that this class be made cross platform.
8111
8112         (WebKit::NetscapePluginModule::determineQuirks):
8113         Add the ReturnsNonRetainedScriptableNPObject quirk for versions of Silverlight less than 4.
8114
8115         * Shared/Plugins/PluginQuirks.h:
8116         Add the ReturnsNonRetainedScriptableNPObject quirk.
8117
8118         * UIProcess/Plugins/PluginInfoStore.h:
8119         Use a version string. Eventually this should hold the PluginVersion class we added.
8120
8121         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
8122         (WebKit::NetscapePlugin::pluginScriptableNPObject):
8123         If the plug-in has the ReturnsNonRetainedScriptableNPObject quirk, do an extra retain.
8124
8125 2011-06-13  Ryuan Choi  <ryuan.choi@samsung.com>
8126
8127         Reviewed by Kenneth Rohde Christiansen.
8128
8129         [EFL][WK2] Add dummy files at below of WebProcess.
8130         https://bugs.webkit.org/show_bug.cgi?id=62445
8131
8132         Add Efl related directory and files in WebKit2/WebProcess/.
8133
8134         * WebProcess/Cookies/efl/WebCookieManagerEfl.cpp: Added.
8135         (WebKit::WebCookieManager::platformSetHTTPCookieAcceptPolicy):
8136         (WebKit::WebCookieManager::platformGetHTTPCookieAcceptPolicy):
8137         * WebProcess/InjectedBundle/efl/InjectedBundleEfl.cpp: Added.
8138         (WebKit::InjectedBundle::load):
8139         (WebKit::InjectedBundle::activateMacFontAscentHack):
8140         * WebProcess/WebPage/efl/WebInspectorEfl.cpp: Added.
8141         (WebKit::WebInspector::localizedStringsURL):
8142         * WebProcess/WebPage/efl/WebPageEfl.cpp: Added.
8143         (WebKit::WebPage::platformInitialize):
8144         (WebKit::WebPage::platformPreferencesDidChange):
8145         (WebKit::scroll):
8146         (WebKit::WebPage::performDefaultBehaviorForKeyEvent):
8147         (WebKit::WebPage::platformHasLocalDataForURL):
8148         (WebKit::WebPage::cachedResponseMIMETypeForURL):
8149         (WebKit::WebPage::platformCanHandleRequest):
8150         (WebKit::WebPage::cachedSuggestedFilenameForURL):
8151         (WebKit::WebPage::cachedResponseDataForURL):
8152         * WebProcess/efl/WebProcessEfl.cpp: Added.
8153         (WebKit::WebProcess::platformSetCacheModel):
8154         (WebKit::WebProcess::platformClearResourceCaches):
8155         (WebKit::WebProcess::platformInitializeWebProcess):
8156         (WebKit::WebProcess::platformTerminate):
8157         * WebProcess/efl/WebProcessMainEfl.cpp: Added.
8158         (WebKit::WebProcessMainEfl):
8159         * WebProcess/efl/WebProcessMainEfl.h: Added.
8160         * efl/MainEfl.cpp: Added.
8161         (main):
8162
8163 2011-06-13  Eunmi Lee  <eunmi15.lee@samsung.com>
8164
8165         Reviewed by Eric Seidel.
8166
8167         [EFL][WK2] Add initial WebInspectorEfl.cpp for webkit2 efl port
8168         https://bugs.webkit.org/show_bug.cgi?id=62524
8169
8170         * UIProcess/efl/WebInspectorEfl.cpp: Added.
8171         (WebKit::WebInspectorProxy::platformCreateInspectorPage):
8172         (WebKit::WebInspectorProxy::platformOpen):
8173         (WebKit::WebInspectorProxy::platformDidClose):
8174         (WebKit::WebInspectorProxy::platformBringToFront):
8175         (WebKit::WebInspectorProxy::platformInspectedURLChanged):
8176         (WebKit::WebInspectorProxy::inspectorPageURL):
8177         (WebKit::WebInspectorProxy::platformAttach):
8178         (WebKit::WebInspectorProxy::platformDetach):
8179         (WebKit::WebInspectorProxy::platformSetAttachedWindowHeight):
8180
8181 2011-06-13  Eunmi Lee  <eunmi15.lee@samsung.com>
8182
8183         Reviewed by Eric Seidel.
8184
8185         [EFL][WK2] Add initial TextCheckerEfl.cpp for webkit2 efl port
8186         https://bugs.webkit.org/show_bug.cgi?id=62438
8187
8188         * UIProcess/efl/TextCheckerEfl.cpp: Added.
8189         (WebKit::TextChecker::state):
8190         (WebKit::TextChecker::isContinuousSpellCheckingAllowed):
8191         (WebKit::TextChecker::setContinuousSpellCheckingEnabled):
8192         (WebKit::TextChecker::setGrammarCheckingEnabled):
8193         (WebKit::TextChecker::uniqueSpellDocumentTag):
8194         (WebKit::TextChecker::closeSpellDocumentWithTag):
8195         (WebKit::TextChecker::checkSpellingOfString):
8196         (WebKit::TextChecker::checkGrammarOfString):
8197         (WebKit::TextChecker::spellingUIIsShowing):
8198         (WebKit::TextChecker::toggleSpellingUIIsShowing):
8199         (WebKit::TextChecker::updateSpellingUIWithMisspelledWord):
8200         (WebKit::TextChecker::updateSpellingUIWithGrammarString):
8201         (WebKit::TextChecker::getGuessesForWord):
8202         (WebKit::TextChecker::learnWord):
8203         (WebKit::TextChecker::ignoreWord):
8204
8205 2011-06-13  Sangyong Park  <sy302.park@gmail.com>
8206
8207         Reviewed by Eric Seidel.
8208
8209         implement to handle wheel event of plugin on x11
8210         https://bugs.webkit.org/show_bug.cgi?id=62522
8211
8212         Implement platformHandleWheelEvent() in NetscapePluginX11.cpp
8213         for to handle wheel event on plugins
8214
8215         * WebProcess/Plugins/Netscape/x11/NetscapePluginX11.cpp:
8216         (WebKit::setCommonMouseEventFields): add template argument to support WebWheelEvent
8217         (WebKit::setXButtonEventFieldsByWebWheelEvent): initialize XButtonEvent by WebWheelEvent
8218         (WebKit::NetscapePlugin::platformHandleWheelEvent): handle wheel event on plugin
8219
8220 2011-06-13  Eunmi Lee  <eunmi15.lee@samsung.com>
8221
8222         Reviewed by Eric Seidel.
8223
8224         [EFL][WK2] Add initial WebContextEfl.cpp for webkit2 efl port
8225         https://bugs.webkit.org/show_bug.cgi?id=62523
8226
8227         * UIProcess/efl/WebContextEfl.cpp: Added.
8228         (WebKit::WebContext::applicationCacheDirectory):
8229         (WebKit::WebContext::platformInitializeWebProcess):
8230         (WebKit::WebContext::platformInvalidateContext):
8231         (WebKit::WebContext::platformDefaultDatabaseDirectory):
8232         (WebKit::WebContext::platformDefaultIconDatabasePath):
8233         (WebKit::WebContext::platformDefaultLocalStorageDirectory):
8234
8235 2011-06-13  Noam Rosenthal  <noam.rosenthal@nokia.com>
8236
8237         Unreviewed fix - removed parts of r88659 that were committed by mistake.
8238
8239         The patch accidentally included parts that weren't supposed to be there, namely the whole
8240         code was duplicated. This patch rectifies that and brings it to the original reviewed code.
8241
8242         * WebProcess/WebCoreSupport/WebGraphicsLayer.cpp:
8243         * WebProcess/WebCoreSupport/WebGraphicsLayer.h:
8244
8245 2011-06-13  Anders Carlsson  <andersca@apple.com>
8246
8247         Reviewed by Dan Bernstein.
8248
8249         BankID plug-in isn't instantiated correctly
8250         https://bugs.webkit.org/show_bug.cgi?id=62588
8251         <rdar://problem/9586600>
8252
8253         * Shared/Plugins/Netscape/mac/NetscapePluginModuleMac.mm:
8254         (WebKit::NetscapePluginModule::determineQuirks):
8255         The BankID plug-in uses the QuickDraw drawing model but doesn't draw anything so we can
8256         use the half-baked QuickDraw support.
8257
8258         * WebProcess/Plugins/PluginProcessConnection.cpp:
8259         (WebKit::defaultSyncMessageTimeout):
8260         Don't use a sync message timeout for the BankID plug-in since it sends synchronous Apple Events
8261         and we don't want the plug-in to die while it's waiting for a reply.
8262
8263 2011-06-13  Chris Fleizach  <cfleizach@apple.com>
8264
8265         Reviewed by Darin Adler.
8266
8267         kAXTextMarkerForPositionParametrizedAttribute does not work correctly in WK2
8268         https://bugs.webkit.org/show_bug.cgi?id=62547
8269
8270         Implement the missing screenToWindow method for WK2.
8271
8272         * UIProcess/API/gtk/PageClientImpl.cpp:
8273         (WebKit::PageClientImpl::screenToWindow):
8274         * UIProcess/API/gtk/PageClientImpl.h:
8275         * UIProcess/API/mac/PageClientImpl.h:
8276         * UIProcess/API/mac/PageClientImpl.mm:
8277         (WebKit::PageClientImpl::screenToWindow):
8278         * UIProcess/API/qt/qwkpage.cpp:
8279         (QWKPagePrivate::screenToWindow):
8280         * UIProcess/API/qt/qwkpage_p.h:
8281         * UIProcess/PageClient.h:
8282         * UIProcess/WebPageProxy.cpp:
8283         (WebKit::WebPageProxy::screenToWindow):
8284         * UIProcess/WebPageProxy.h:
8285         * UIProcess/WebPageProxy.messages.in:
8286         * UIProcess/win/WebView.cpp:
8287         (WebKit::WebView::screenToWindow):
8288         * UIProcess/win/WebView.h:
8289         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
8290         (WebKit::WebChromeClient::screenToWindow):
8291         * WebProcess/WebPage/WebPage.cpp:
8292         (WebKit::WebPage::screenToWindow):
8293         * WebProcess/WebPage/WebPage.h:
8294
8295 2011-06-13  Sam Weinig  <sam@webkit.org>
8296
8297         Reviewed by Darin Adler.
8298
8299         REGRESSION (81679-81939): In Safari, Dictionary look up (tap or Ctrl-Cmd-D) doesn't work if you have clicked on a word and not moved the mouse
8300         <rdar://problem/9580237> 
8301
8302         * WebProcess/WebPage/mac/WebPageMac.mm:
8303         (WebKit::shouldUseSelection):
8304         Return early if the selection we are using is not a range.
8305
8306 2011-06-13  Tony Chang  <tony@chromium.org>
8307
8308         Reviewed by Dimitri Glazkov.
8309
8310         rename ENABLE_NEW_FLEXBOX to ENABLE_CSS3_FLEXBOX
8311         https://bugs.webkit.org/show_bug.cgi?id=62578
8312
8313         * Configurations/FeatureDefines.xcconfig:
8314
8315 2011-06-13  No'am Rosenthal  <noam.rosenthal@nokia.com>
8316
8317         Reviewed by Kenneth Rohde Christiansen.
8318
8319         [Qt] Implement accelerated compositing on WK2 Qt port
8320         https://bugs.webkit.org/show_bug.cgi?id=56935
8321
8322         Added WebGraphicsLayer, a subclass of WebCore::GraphicsLayer that serializes the state of the layer
8323         tree to the UI process WebLayerTreeInfo.
8324         For now this patch doesn't serialize the animation information, a feature that will be upstreamed later on.
8325
8326         Together with Viatcheslav Ostapenko.
8327
8328         * WebProcess/WebCoreSupport/WebGraphicsLayer.cpp: Added.
8329         * WebProcess/WebCoreSupport/WebGraphicsLayer.h: Added.
8330
8331 2011-06-13  No'am Rosenthal  <noam.rosenthal@nokia.com>
8332
8333         Reviewed by Kenneth Rohde Christiansen.
8334
8335         [Qt] Implement accelerated compositing on WK2 Qt port
8336         https://bugs.webkit.org/show_bug.cgi?id=56935
8337
8338         Added WebLayerTreeInfo: a set of structures that can serialize a tree of GraphicsLayers
8339         across to the UI process.
8340
8341         Together with Viatcheslav Ostapenko.
8342
8343         * Scripts/webkit2/messages.py:
8344         * Shared/WebLayerTreeInfo.cpp: Added.
8345         * Shared/WebLayerTreeInfo.h: Added.
8346
8347 2011-06-11  Jer Noble  <jer.noble@apple.com>
8348
8349         Reviewed by Anders Carlsson.
8350
8351         Avoid flashing when exiting full-screen mode.
8352         https://bugs.webkit.org/show_bug.cgi?id=62338
8353
8354         Instead of making a round-trip between processes by calling forceRepaint
8355         and waiting for a callback, instead make a WebProcess-side call to
8356         forceRepaintWithoutCallback before sending the ExitAcceleratedCompositingMode
8357         message to the WebFullScreenControllerProxy. This also means we can get rid of
8358         the dragImage creation and display.
8359
8360         Because this redraw will happen during the current run-loop instead of a future
8361         one, make sure the background color has been set before the redraw in 
8362         didEnterFullScreen().
8363
8364         Wait to hide the full-screen window until after we have received the 
8365         ExitAcceleratedCompositingMode message.  By this time, repaint will have already
8366         completed.
8367
8368         * UIProcess/mac/WKFullScreenWindowController.h:
8369         * UIProcess/mac/WKFullScreenWindowController.mm:
8370         (-[WKFullScreenWindowController finishedEnterFullScreenAnimation:]): Disable
8371             screen updates, to be re-enabled during exitAcceleratedCompositingMode.
8372         (-[WKFullScreenWindowController finishedExitFullScreenAnimation:]): Don't hide
8373             the full-screen window here; wait for exitAcceleratedCompositing instead.
8374         (-[WKFullScreenWindowController exitAcceleratedCompositingMode]): Collapse 
8375             the redrawCompleted method into this one.
8376         (-[WKFullScreenWindowController close]): Remove the reference to 
8377             exitCompositedModeRepaintCompleted.
8378         * WebProcess/FullScreen/WebFullScreenManager.cpp:
8379         (WebKit::WebFullScreenManager::didEnterFullScreen): Set the full screen
8380             background color first.
8381         * WebProcess/FullScreen/mac/WebFullScreenManagerMac.mm:
8382         (WebKit::WebFullScreenManagerMac::setRootFullScreenLayer): Repaint before
8383             sending the ExitAcceleratedCompositingMode message. 
8384
8385 2011-06-13  Tony Chang  <tony@chromium.org>
8386
8387         Reviewed by Adam Barth.
8388
8389         rename ENABLE_FLEXBOX to ENABLE_NEW_FLEXBOX
8390         https://bugs.webkit.org/show_bug.cgi?id=62545
8391
8392         * Configurations/FeatureDefines.xcconfig:
8393
8394 2011-06-13  Anders Carlsson  <andersca@apple.com>
8395
8396         Reviewed by Dan Bernstein.
8397
8398         Don't access freed memory in the UI process when a plug-in process crashes
8399         https://bugs.webkit.org/show_bug.cgi?id=62548
8400         <rdar://problem/9599243>
8401
8402         Call pluginProcessCrashedOrFailedToLaunch after sending messages to all processes about the plug-in crash,
8403         otherwise we'll try to dereference m_pluginInfo.path after the PluginProcessProxy object has been deleted.
8404
8405         * UIProcess/Plugins/PluginProcessProxy.cpp:
8406         (WebKit::PluginProcessProxy::didClose):
8407
8408 2011-06-13  Carlos Garcia Campos  <cgarcia@igalia.com>
8409
8410         Reviewed by Martin Robinson.
8411
8412         [GTK] Fix a crash when drawing area has been deleted
8413         https://bugs.webkit.org/show_bug.cgi?id=62541
8414
8415         Check whether WebPageProxy::drawingArea() returns a valid pointer
8416         before using it, it might be null, for example, when the web
8417         process crashes.
8418
8419         * UIProcess/API/gtk/WebKitWebViewBase.cpp:
8420         (callDrawingAreaPaintMethod):
8421         (webkitWebViewBaseSizeAllocate):
8422
8423 2011-06-13  Eunmi Lee  <eunmi15.lee@samsung.com>
8424
8425         Reviewed by Kenneth Rohde Christiansen.
8426
8427         [EFL][WK2] Minor fix: fix coding style and remove unnecessary codes for WebKit2 efl port's PageClientImpl
8428         https://bugs.webkit.org/show_bug.cgi?id=62429
8429
8430         * UIProcess/API/efl/PageClientImpl.cpp:
8431         (WebKit::PageClientImpl::scrollView):
8432         (WebKit::PageClientImpl::setCursor):
8433         (WebKit::PageClientImpl::windowToScreen):
8434         (WebKit::PageClientImpl::doneWithKeyEvent):
8435         (WebKit::PageClientImpl::setFindIndicator):
8436         (WebKit::PageClientImpl::didCommitLoadForMainFrame):
8437         (WebKit::PageClientImpl::didFinishLoadingDataForCustomRepresentation):
8438         (WebKit::PageClientImpl::findStringInCustomRepresentation):
8439         (WebKit::PageClientImpl::countStringMatchesInCustomRepresentation):
8440         * UIProcess/API/efl/PageClientImpl.h:
8441
8442 2011-06-13  Eunmi Lee  <eunmi15.lee@samsung.com>
8443
8444         Reviewed by Kenneth Rohde Christiansen.
8445
8446         [EFL][WK2] Add initial WebPreferencesEfl.cpp for webkit2 efl port
8447         https://bugs.webkit.org/show_bug.cgi?id=62525
8448
8449         * UIProcess/efl/WebPreferencesEfl.cpp: Added.
8450         (WebKit::WebPreferences::platformInitializeStore):
8451         (WebKit::WebPreferences::platformUpdateStringValueForKey):
8452         (WebKit::WebPreferences::platformUpdateBoolValueForKey):
8453         (WebKit::WebPreferences::platformUpdateUInt32ValueForKey):
8454         (WebKit::WebPreferences::platformUpdateDoubleValueForKey):
8455
8456 2011-06-13  Carlos Garcia Campos  <cgarcia@igalia.com>
8457
8458         Reviewed by Martin Robinson.
8459
8460         [GTK] Add context menu support for Webkit2
8461         https://bugs.webkit.org/show_bug.cgi?id=54827
8462
8463         * GNUmakefile.am: Add new files to compilation.
8464         * UIProcess/API/gtk/PageClientImpl.cpp:
8465         (WebKit::PageClientImpl::createContextMenuProxy): Create a context
8466         menu proxy.
8467         * UIProcess/API/gtk/WebKitWebViewBase.cpp:
8468         (globalPointForClientPoint): Function copied from webkit1 to
8469         convert a point in widget coordinates to global coordinates.
8470         (popupMenuPositionFunction):
8471         (webkitWebViewBaseShowContextMenu): Show the given context menu at
8472         the given position.
8473         * UIProcess/API/gtk/WebKitWebViewBasePrivate.h:
8474         * UIProcess/gtk/WebContextMenuProxyGtk.cpp: Added.
8475         (WebKit::contextMenuItemActivatedCallback):
8476         (WebKit::WebContextMenuProxyGtk::createGtkMenu):
8477         (WebKit::WebContextMenuProxyGtk::showContextMenu):
8478         (WebKit::WebContextMenuProxyGtk::hideContextMenu):
8479         (WebKit::WebContextMenuProxyGtk::WebContextMenuProxyGtk):
8480         (WebKit::WebContextMenuProxyGtk::~WebContextMenuProxyGtk):
8481         * UIProcess/gtk/WebContextMenuProxyGtk.h: Copied from Source/WebKit2/UIProcess/API/gtk/WebKitWebViewBasePrivate.h.
8482         (WebKit::WebContextMenuProxyGtk::create):
8483
8484 2011-06-13  Carlos Garcia Campos  <cgarcia@igalia.com>
8485
8486         Reviewed by Martin Robinson.
8487
8488         [GTK] Export an API similar to WebKit1
8489         https://bugs.webkit.org/show_bug.cgi?id=57820
8490
8491         Add first implementation of WebKitWebView, a class with the same
8492         API than webkit1, that wraps the C API to provide a high level
8493         WebKit2 API for GTK port.
8494
8495         * GNUmakefile.am: Add new files to compilation.
8496         * UIProcess/API/gtk/WebKitWebView.cpp: Added.
8497         (webkit_web_view_init):
8498         (webkit_web_view_class_init):
8499         (webkit_web_view_new):
8500         (webkit_web_view_load_uri):
8501         (webkit_web_view_go_back):
8502         (webkit_web_view_go_forward):
8503         * UIProcess/API/gtk/WebKitWebView.h: Added.
8504         * UIProcess/API/gtk/WebKitWebViewBase.cpp:
8505         (webkitWebViewBaseCreate):
8506         (webkitWebViewBaseCreateWebPage):
8507         * UIProcess/API/gtk/WebKitWebViewBasePrivate.h:
8508         * UIProcess/API/gtk/webkit/webkit.h: Added.
8509
8510 2011-06-12  Adam Barth  <abarth@webkit.org>
8511
8512         Reviewed by Alexey Proskuryakov.
8513
8514         Rename FrameLoaderClient::interruptForPolicyChangeError to use the past tense
8515         https://bugs.webkit.org/show_bug.cgi?id=62516
8516
8517         * WebProcess/WebCoreSupport/WebErrors.h:
8518         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
8519         (WebKit::WebFrameLoaderClient::interruptedForPolicyChangeError):
8520         * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
8521         * WebProcess/WebCoreSupport/efl/WebErrorsEfl.cpp:
8522         (WebKit::interruptedForPolicyChangeError):
8523         * WebProcess/WebCoreSupport/gtk/WebErrorsGtk.cpp:
8524         (WebKit::interruptedForPolicyChangeError):
8525         * WebProcess/WebCoreSupport/mac/WebErrorsMac.mm:
8526         (WebKit::interruptedForPolicyChangeError):
8527         * WebProcess/WebCoreSupport/qt/WebErrorsQt.cpp:
8528         (WebKit::interruptedForPolicyChangeError):
8529         * WebProcess/WebCoreSupport/win/WebErrorsWin.cpp:
8530         (WebKit::interruptedForPolicyChangeError):
8531
8532 2011-06-12  Adam Barth  <abarth@webkit.org>
8533
8534         Reviewed by Eric Seidel.
8535
8536         Remove FrameLoader::isProcessingUserGesture
8537         https://bugs.webkit.org/show_bug.cgi?id=62519
8538
8539         Instead of asking the gesture indicator directly, ask the
8540         ScriptController, like everyone else.  The gesture indicator is just
8541         one of the piece of information we use to determine whether we're
8542         processing a user gesture.
8543
8544         * WebProcess/InjectedBundle/InjectedBundle.cpp:
8545         (WebKit::InjectedBundle::isProcessingUserGesture):
8546
8547 2011-06-12  Adam Barth  <abarth@webkit.org>
8548
8549         Reviewed by Alexey Proskuryakov.
8550
8551         Remove trival "forward-to-client" member functions from FrameLoader
8552         https://bugs.webkit.org/show_bug.cgi?id=62510
8553
8554         * WebProcess/WebCoreSupport/mac/WebFrameNetworkingContext.mm:
8555         (WebKit::WebFrameNetworkingContext::blockedError):
8556
8557 2011-06-11  Stephanie Lewis  <slewis@apple.com>
8558
8559         Reviewed by Sam Weinig.
8560
8561         https://bugs.webkit.org/show_bug.cgi?id=62480
8562         part of <rdar://problem/8675177>
8563         Add API to launch the WebProcess.  Launching it earlier can save time 
8564         when loading the first page.
8565
8566         * UIProcess/API/C/WKContext.cpp:
8567         (WKContextWarmInitialProcess):
8568         * UIProcess/API/C/WKContextPrivate.h:
8569         * UIProcess/WebContext.cpp:
8570         (WebKit::WebContext::warmInitialProcess):
8571         * UIProcess/WebContext.h:
8572
8573 2011-06-09  Jer Noble  <jer.noble@apple.com>
8574
8575         Reviewed by Darin Adler.
8576
8577         AVPlayerLayer is adding a "fade" animation during Safari full-screen
8578         https://bugs.webkit.org/show_bug.cgi?id=62433
8579
8580         CoreAnimation will add default animations when certain properties are changed, unless
8581         those changes are wrapped in a CATransaction which has had its disableActions property set
8582         to true.  Wrap each of these three property changes in a CATransaction and disable its actions,
8583         so that the default "fade" animation is not created in response.
8584
8585         * UIProcess/mac/WKFullScreenWindowController.mm:
8586         (-[WKFullScreenWindowController enterFullScreen:]): Wrap with CATransaction.
8587         (-[WKFullScreenWindowController _swapView:with:]): Ditto:
8588         * WebProcess/FullScreen/mac/WebFullScreenManagerMac.mm:
8589         (WebKit::WebFullScreenManagerMac::setRootFullScreenLayer): Ditto.
8590
8591 2011-06-10  Anders Carlsson  <andersca@apple.com>
8592
8593         Reviewed by Sam Weinig.
8594
8595         REGRESSION (WebKit2): window.showModalDialog() broken
8596         https://bugs.webkit.org/show_bug.cgi?id=62496
8597         <rdar://problem/9581492>
8598
8599         If dispatching a message ends up creating a nested run loop, some incoming messages can end up not being
8600         delivered until we exit from the run loop.
8601
8602         Fix this by using a Deque instead of a Vector for incoming messages, and get one message at a time and then
8603         dispatch it. That prevents us from having any lingering messages lying around in stack allocated space.
8604
8605         * Platform/CoreIPC/Connection.cpp:
8606         (CoreIPC::Connection::waitForMessage):
8607         (CoreIPC::Connection::dispatchMessages):
8608         * Platform/CoreIPC/Connection.h:
8609
8610 2011-06-10  Sam Weinig  <sam@webkit.org>
8611
8612         Reviewed by Anders Carlsson.
8613
8614         Unresponsive cursor is shown when displaying a modal dialog
8615         Part of <rdar://problem/9581492>
8616         https://bugs.webkit.org/show_bug.cgi?id=62494
8617
8618         * UIProcess/WebPageProxy.cpp:
8619         (WebKit::WebPageProxy::runModal):
8620         * UIProcess/WebPageProxy.h:
8621         Stop the responsiveness timer when calling out to show a modal dialog.
8622
8623 2011-06-10  Tony Chang  <tony@chromium.org>
8624
8625         Reviewed by Ojan Vafai.
8626
8627         add a compile guard ENABLE(FLEXBOX)
8628         https://bugs.webkit.org/show_bug.cgi?id=62049
8629
8630         * Configurations/FeatureDefines.xcconfig:
8631
8632 2011-06-10  Ryuan Choi  <ryuan.choi@samsung.com>
8633
8634         Reviewed by Kenneth Rohde Christiansen.
8635
8636         [EFL][WK2] Add dummy files in WebProcess/WebCoreSupport/efl
8637         https://bugs.webkit.org/show_bug.cgi?id=62346
8638
8639         Add WebProcess/WebCoreSupport/efl directory and files.
8640
8641         * WebProcess/WebCoreSupport/efl/WebContextMenuClientEfl.cpp: Added.
8642         (WebKit::WebContextMenuClient::lookUpInDictionary):
8643         (WebKit::WebContextMenuClient::isSpeaking):
8644         (WebKit::WebContextMenuClient::speak):
8645         (WebKit::WebContextMenuClient::stopSpeaking):
8646         * WebProcess/WebCoreSupport/efl/WebEditorClientEfl.cpp: Added.
8647         (WebKit::WebEditorClient::handleKeyboardEvent):
8648         (WebKit::WebEditorClient::handleInputMethodKeydown):
8649         * WebProcess/WebCoreSupport/efl/WebErrorsEfl.cpp: Added.
8650         (WebKit::cancelledError):
8651         (WebKit::blockedError):
8652         (WebKit::cannotShowURLError):
8653         (WebKit::interruptForPolicyChangeError):
8654         (WebKit::cannotShowMIMETypeError):
8655         (WebKit::fileDoesNotExistError):
8656         (WebKit::pluginWillHandleLoadError):
8657         * WebProcess/WebCoreSupport/efl/WebFrameNetworkingContext.h: Added.
8658         (WebFrameNetworkingContext::create):
8659         (WebFrameNetworkingContext::WebFrameNetworkingContext):
8660         * WebProcess/WebCoreSupport/efl/WebPopupMenuEfl.cpp: Added.
8661         (WebKit::WebPopupMenu::setUpPlatformData):
8662
8663 2011-06-09  Andreas Kling  <kling@webkit.org>
8664
8665         Reviewed by Darin Adler.
8666
8667         WebKit2: Remove unused function CoreIPC::Connection::deprecatedWaitFor().
8668         https://bugs.webkit.org/show_bug.cgi?id=62386
8669
8670         * Platform/CoreIPC/Connection.h:
8671
8672 2011-06-09  Andreas Kling  <kling@webkit.org>
8673
8674         Reviewed by Anders Carlsson.
8675
8676         [Qt][WK2] Remove usage of deprecated CoreIPC functions.
8677         https://bugs.webkit.org/show_bug.cgi?id=62290
8678
8679         Use the new DrawingArea{,Proxy}.messages.in approach to CoreIPC in TiledDrawingArea.
8680         The TiledDrawingArea{,Proxy}-specific messages were moved up into DrawingArea{,Proxy}
8681         and guarded by ENABLE(TILED_BACKING_STORE).
8682
8683         * Shared/CoreIPCSupport/DrawingAreaMessageKinds.h: Removed.
8684         * Shared/CoreIPCSupport/DrawingAreaProxyMessageKinds.h: Removed.
8685
8686         * GNUmakefile.am:
8687         * WebKit2.pro:
8688         * WebKit2.xcodeproj/project.pbxproj:
8689         * win/WebKit2.vcproj: Prune deleted files from build system.
8690
8691         * Platform/CoreIPC/MessageID.h: Remove legacy DrawingArea message ID's.
8692
8693         * UIProcess/API/qt/qgraphicswkview.cpp:
8694         (QGraphicsWKViewPrivate::commitScale): No longer waits for all tile updates to complete,
8695         this will be addressed by the soon-to-be-upstreamed TileSet mechanism.
8696
8697         * UIProcess/DrawingAreaProxy.messages.in:
8698         * UIProcess/DrawingAreaProxy.h:
8699         (WebKit::DrawingAreaProxy::didSetSize):
8700         (WebKit::DrawingAreaProxy::invalidate):
8701         (WebKit::DrawingAreaProxy::snapshotTaken):
8702         (WebKit::DrawingAreaProxy::tileUpdated):
8703         (WebKit::DrawingAreaProxy::allTileUpdatesProcessed): Added IPC calls used by
8704         TiledDrawingAreaProxy to DrawingAreaProxy.
8705
8706         * WebProcess/WebPage/DrawingArea.messages.in:
8707         * WebProcess/WebPage/DrawingArea.h:
8708         (WebKit::DrawingArea::setSize):
8709         (WebKit::DrawingArea::cancelTileUpdate):
8710         (WebKit::DrawingArea::requestTileUpdate):
8711         (WebKit::DrawingArea::takeSnapshot): Added IPC calls used by TiledDrawingArea
8712         to DrawingArea.
8713
8714         * UIProcess/DrawingAreaProxyImpl.h:
8715         * UIProcess/DrawingAreaProxyImpl.cpp: Remove the now-unneeded didReceiveMessage()
8716         and didReceiveSyncMessage().
8717
8718         * WebProcess/WebPage/DrawingAreaImpl.cpp:
8719         * WebProcess/WebPage/DrawingAreaImpl.h: Remove the now-unneeded didReceiveMessage().
8720
8721         * UIProcess/TiledDrawingAreaProxy.h:
8722         * UIProcess/TiledDrawingAreaProxy.cpp:
8723         (WebKit::TiledDrawingAreaProxy::sizeDidChange):
8724         (WebKit::TiledDrawingAreaProxy::tileUpdated):
8725         (WebKit::TiledDrawingAreaProxy::allTileUpdatesProcessed): Split didReceiveMessage()
8726         into functions.
8727
8728         (WebKit::TiledDrawingAreaProxy::removeTile):
8729         (WebKit::TiledDrawingAreaProxy::requestTileUpdate):
8730         (WebKit::TiledDrawingAreaProxy::setPageIsVisible):
8731         (WebKit::TiledDrawingAreaProxy::takeSnapshot): Use new-style IPC.
8732
8733         * WebProcess/WebPage/TiledDrawingArea.cpp:
8734         (WebKit::TiledDrawingArea::setSize):
8735         (WebKit::TiledDrawingArea::cancelTileUpdate):
8736         (WebKit::TiledDrawingArea::requestTileUpdate):
8737         (WebKit::TiledDrawingArea::takeSnapshot): Split didReceiveMessage() into functions.
8738
8739         (WebKit::TiledDrawingArea::display):
8740         (WebKit::TiledDrawingArea::updateTile):
8741         (WebKit::TiledDrawingArea::tileUpdateTimerFired): Use new-style IPC.
8742
8743         * UIProcess/WebPageProxy.cpp:
8744         (WebKit::WebPageProxy::didReceiveMessage): Remove handling of
8745         CoreIPC::MessageClassDrawingAreaProxyLegacy.
8746
8747         * WebProcess/WebPage/WebPage.cpp:
8748         (WebKit::WebPage::didReceiveMessage): Remove handling of
8749         CoreIPC::MessageClassDrawingAreaLegacy.
8750
8751         * UIProcess/qt/TiledDrawingAreaProxyQt.cpp: Remove unneeded includes.
8752
8753         * WebProcess/WebPage/TiledDrawingArea.h: Remove didReceiveMessage() and make
8754         CoreIPC message handlers explicitly virtual.
8755
8756 2011-06-09  Andreas Kling  <kling@webkit.org>
8757
8758         Reviewed by Anders Carlsson.
8759
8760         WebKit2: Generate correct header conditionals in message receivers.
8761         https://bugs.webkit.org/show_bug.cgi?id=62379
8762
8763         Given a *.messages.in file like this:
8764
8765         Foo(AwesomeObject o)
8766         #if ENABLE(ESOTERIC_FEATURE)
8767         Bar(AwesomeObject o)
8768         #endif
8769
8770         messages.py would include AwesomeObject.h only #if ENABLE(ESOTERIC_FEATURE).
8771         This breaks the build on platforms without that defined.
8772
8773         Furthermore, if two messages guarded by different conditionals both pull in the same
8774         header, only the last conditional will be applied, for example:
8775
8776         #if ENABLE(ESOTERIC_FEATURE)
8777         Foo(AwesomeObject o)
8778         #endif
8779         #if ENABLE(MYSTERIOUS_FEATURE)
8780         Bar(AwesomeObject o)
8781         #endif
8782
8783         Would include AwesomeObject.h #if ENABLE(MYSTERIOUS_FEATURE) when it really should
8784         check #if ENABLE(ESOTERIC_FEATURE) || ENABLE(MYSTERIOUS_FEATURE).
8785
8786         Change the generator to consider all conditionals for a given header file.
8787         Also consider conditionals for reply parameters.
8788
8789         * Scripts/webkit2/messages.py:
8790         * Scripts/webkit2/messages_unittest.py:
8791
8792 2011-06-09  Eunmi Lee  <eunmi15.lee@samsung.com>
8793
8794         Reviewed by Kenneth Rohde Christiansen.
8795
8796         [EFL][WK2] Add PageClientImpl and WebPageProxyEfl for efl port
8797         https://bugs.webkit.org/show_bug.cgi?id=62363
8798
8799         * UIProcess/API/efl/PageClientImpl.cpp: Added.
8800         (WebKit::PageClientImpl::PageClientImpl):
8801         (WebKit::PageClientImpl::~PageClientImpl):
8802         (WebKit::PageClientImpl::createDrawingAreaProxy):
8803         (WebKit::PageClientImpl::setViewNeedsDisplay):
8804         (WebKit::PageClientImpl::displayView):
8805         (WebKit::PageClientImpl::scrollView):
8806         (WebKit::PageClientImpl::viewSize):
8807         (WebKit::PageClientImpl::isViewWindowActive):
8808         (WebKit::PageClientImpl::isViewFocused):
8809         (WebKit::PageClientImpl::isViewVisible):
8810         (WebKit::PageClientImpl::isViewInWindow):
8811         (WebKit::PageClientImpl::processDidCrash):
8812         (WebKit::PageClientImpl::didRelaunchProcess):
8813         (WebKit::PageClientImpl::pageClosed):
8814         (WebKit::PageClientImpl::toolTipChanged):
8815         (WebKit::PageClientImpl::setCursor):
8816         (WebKit::PageClientImpl::setViewportArguments):
8817         (WebKit::PageClientImpl::registerEditCommand):
8818         (WebKit::PageClientImpl::clearAllEditCommands):
8819         (WebKit::PageClientImpl::canUndoRedo):
8820         (WebKit::PageClientImpl::executeUndoRedo):
8821         (WebKit::PageClientImpl::convertToDeviceSpace):
8822         (WebKit::PageClientImpl::convertToUserSpace):
8823         (WebKit::PageClientImpl::windowToScreen):
8824         (WebKit::PageClientImpl::doneWithKeyEvent):
8825         (WebKit::PageClientImpl::createPopupMenuProxy):
8826         (WebKit::PageClientImpl::createContextMenuProxy):
8827         (WebKit::PageClientImpl::setFindIndicator):
8828         (WebKit::PageClientImpl::didChangeScrollbarsForMainFrame):
8829         (WebKit::PageClientImpl::didCommitLoadForMainFrame):
8830         (WebKit::PageClientImpl::didFinishLoadingDataForCustomRepresentation):
8831         (WebKit::PageClientImpl::customRepresentationZoomFactor):
8832         (WebKit::PageClientImpl::setCustomRepresentationZoomFactor):
8833         (WebKit::PageClientImpl::flashBackingStoreUpdates):
8834         (WebKit::PageClientImpl::findStringInCustomRepresentation):
8835         (WebKit::PageClientImpl::countStringMatchesInCustomRepresentation):
8836         (WebKit::PageClientImpl::userSpaceScaleFactor):
8837         * UIProcess/API/efl/PageClientImpl.h: Added.
8838         (WebKit::PageClientImpl::create):
8839         (WebKit::PageClientImpl::viewObject):
8840         (WebKit::PageClientImpl::page):
8841         * UIProcess/WebPageProxy.h:
8842         * UIProcess/efl/WebPageProxyEfl.cpp: Added.
8843         (WebKit::WebPageProxy::viewObject):
8844         (WebKit::WebPageProxy::standardUserAgent):
8845         (WebKit::WebPageProxy::getEditorCommandsForKeyEvent):
8846         (WebKit::WebPageProxy::saveRecentSearches):
8847         (WebKit::WebPageProxy::loadRecentSearches):
8848
8849 2011-06-08  John Sullivan  <sullivan@apple.com>
8850
8851         Reviewed by Darin Adler.
8852
8853         <https://bugs.webkit.org/show_bug.cgi?id=62332>
8854         <rdar://problem/9355199>
8855         [WKView _setDragImage:at:linkDrag:] can crash if WKView is dealloc'ed during drag
8856
8857         * UIProcess/API/mac/WKView.mm:
8858         (-[WKView _resendKeyDownEvent:]):
8859         Renamed self-protecting RetainPtr from "protect" to "protector" so it's a noun.
8860         (-[WKView _setDragImage:at:linkDrag:]):
8861         Added a self-protecting RetainPtr.
8862
8863 2011-06-08  No'am Rosenthal  <noam.rosenthal@nokia.com>
8864
8865         Reviewed by Kenneth Rohde Christiansen.
8866
8867         WebKit2: Enable serializing of data types needed for cross-process accelerated compositing
8868         https://bugs.webkit.org/show_bug.cgi?id=61694
8869
8870         Add an ArgumentCoder for FloatPoint3D.
8871
8872         Together with Viatcheslav Ostapenko.
8873
8874         * Scripts/webkit2/messages.py:
8875         * Shared/WebCoreArgumentCoders.h:
8876
8877 2011-06-08  No'am Rosenthal  <noam.rosenthal@nokia.com>
8878
8879          Reviewed by Kenneth Rohde Christiansen.
8880
8881          WebKit2: Enable serializing of data types needed for cross-process accelerated compositing
8882          https://bugs.webkit.org/show_bug.cgi?id=61694
8883
8884          Add ArgumentCoders for TransformOperation, including all the subclasses,
8885          and TransformOperations.
8886
8887          * Scripts/webkit2/messages.py:
8888          * Shared/WebCoreArgumentCoders.h:
8889
8890 2011-06-08  Yael Aharon  <yael.aharon@nokia.com>
8891
8892         Reviewed by Andreas Kling.
8893
8894         [Qt] Build fix for building QtWebKit inside of Qt.
8895         https://bugs.webkit.org/show_bug.cgi?id=62280
8896
8897         Remove CONFIG=staticlib, because it causes the configure script to add -lwebkit2
8898         into QtWebKit.prl.
8899
8900         * WebKit2.pri:
8901
8902 2011-06-07  Tim Horton  <timothy_horton@apple.com>
8903
8904         Reviewed by Alexey Proskuryakov.
8905
8906         Use correct CFURLStorageSessionRef definition on Snow Leopard
8907         https://bugs.webkit.org/show_bug.cgi?id=62223
8908
8909         * PluginProcess/mac/PluginProcessShim.mm:
8910
8911 2011-06-07  John Sullivan  <sullivan@apple.com>
8912
8913         Reviewed by Darin Adler.
8914
8915         <https://bugs.webkit.org/show_bug.cgi?id=62248>
8916         <rdar://problem/9568516>
8917         WKResponderChainSink mechanism isn't robust against some types of responder chain manipulation
8918
8919         * UIProcess/API/mac/WKView.mm:
8920         (-[WKResponderChainSink detach]):
8921         This method formerly blindly assumed that since -initWithResponderChain: put self at the
8922         end of the responder chain, after _lastResponderInChain, then self is still at the end
8923         of the responder chain and still immediately after _lastResponderInChain. Made this function
8924         robust against some kinds of responder chain manipulations, though it can't be robust against
8925         some other kinds (e.g., manipulations that removed self from this chain and put it into some
8926         other chain).
8927
8928 2011-06-07  Sam Weinig  <sam@webkit.org>
8929
8930         Reviewed by Anders Carlsson.
8931
8932         Remove repeated IPC traffic from SetRenderTreeSize message
8933         https://bugs.webkit.org/show_bug.cgi?id=62244
8934
8935         * WebProcess/InjectedBundle/API/c/WKBundlePage.h:
8936         Add didLayoutForFrame callback.
8937
8938         * WebProcess/InjectedBundle/API/c/WKBundlePage.cpp:
8939         (WKBundlePageGetRenderTreeSize):
8940         * WebProcess/InjectedBundle/API/c/WKBundlePagePrivate.h:
8941         Add render tree size getter in WebProcess.
8942
8943         * WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.cpp:
8944         (WebKit::InjectedBundlePageLoaderClient::didLayoutForFrame):
8945         * WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.h:
8946         Added.
8947
8948         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
8949         * WebProcess/WebCoreSupport/WebChromeClient.h:
8950         Removed setRenderTreeSize.
8951
8952         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
8953         (WebKit::WebFrameLoaderClient::dispatchDidLayout):
8954         * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
8955         Call the new didLayoutForFrame client function.
8956
8957         * WebProcess/WebPage/WebPage.cpp:
8958         (WebKit::WebPage::renderTreeSize):
8959         * WebProcess/WebPage/WebPage.h:
8960         Add iterative implementation to compute the total size of the render tree
8961         for a page.
8962
8963 2011-06-07  Zalan Bujtas  <zbujtas@gmail.com>
8964
8965         Reviewed by Andreas Kling.
8966
8967         TiledDrawingArea: Delay serving tile requests when the drawing area is suspended.
8968
8969         Do not paint tiles when painting is disabled (suspended) on the web process side.
8970         Buffer up the tile requests and paint them, when the drawing area gets resumed.
8971         On the UI process side, do not block on tile updates, when the tiled area is
8972         not visible (painting is disabled on the web process side).
8973
8974         * UIProcess/TiledDrawingAreaProxy.cpp:
8975         (WebKit::TiledDrawingAreaProxy::waitUntilUpdatesComplete):
8976         * WebProcess/WebPage/TiledDrawingArea.cpp:
8977         (WebKit::TiledDrawingArea::suspendPainting):
8978         (WebKit::TiledDrawingArea::resumePainting):
8979         (WebKit::TiledDrawingArea::scheduleTileUpdate):
8980         (WebKit::TiledDrawingArea::tileUpdateTimerFired):
8981         (WebKit::TiledDrawingArea::didReceiveMessage):
8982         * WebProcess/WebPage/TiledDrawingArea.h:
8983
8984 2011-06-07  Sheriff Bot  <webkit.review.bot@gmail.com>
8985
8986         Unreviewed, rolling out r88259 and r88263.
8987         http://trac.webkit.org/changeset/88259
8988         http://trac.webkit.org/changeset/88263
8989         https://bugs.webkit.org/show_bug.cgi?id=62228
8990
8991         broke builds (Requested by rniwa on #webkit).
8992
8993         * PluginProcess/mac/PluginProcessShim.mm:
8994
8995 2011-06-07  Tim Horton  <timothy_horton@apple.com>
8996
8997         Reviewed by Alexey Proskuryakov.
8998
8999         Use correct CFURLStorageSessionRef definition on Snow Leopard
9000         https://bugs.webkit.org/show_bug.cgi?id=62223
9001
9002         * PluginProcess/mac/PluginProcessShim.mm:
9003
9004 2011-06-07  Carlos Garcia Campos  <cgarcia@igalia.com>
9005
9006         Reviewed by Martin Robinson.
9007
9008         [GTK] Move moduleMixesGtkSymbols() from PluginPackage to PluginView
9009         https://bugs.webkit.org/show_bug.cgi?id=62200
9010
9011         In WebKit2 PluginPackage is used by the UI process to load plugins
9012         in order to get information about them, but it doesn't use any GTK
9013         symbol. So the UI process should be able to load plugins even when
9014         building with GTK3, but we should not allow the plugin view to use
9015         the plugin if it mixes GTK2 and GTK3 symbols.
9016
9017         * WebProcess/Plugins/Netscape/x11/NetscapePluginX11.cpp:
9018         (WebKit::moduleMixesGtkSymbols):
9019         (WebKit::NetscapePlugin::platformPostInitialize): Check whether
9020         the module is mixing GTK+ 2 and GTK+ 3 symbols.
9021
9022 2011-06-06  Sheriff Bot  <webkit.review.bot@gmail.com>
9023
9024         Unreviewed, rolling out r88222.
9025         http://trac.webkit.org/changeset/88222
9026         https://bugs.webkit.org/show_bug.cgi?id=62192
9027
9028         Broke compile on Mac (Requested by abarth on #webkit).
9029
9030         * Scripts/webkit2/messages.py:
9031         * Shared/WebCoreArgumentCoders.h:
9032
9033 2011-06-06  Noam Rosenthal  <noam.rosenthal@nokia.com>
9034
9035         Reviewed by Kenneth Rohde Christiansen.
9036
9037         WebKit2: Enable serializing of data types needed for cross-process accelerated compositing
9038         https://bugs.webkit.org/show_bug.cgi?id=61694
9039
9040         Add ArgumentCoders for TransformOperation, including all the subclasses,
9041         and TransformOperations.
9042
9043         * Scripts/webkit2/messages.py:
9044         * Shared/WebCoreArgumentCoders.h:
9045
9046 2011-06-06  John Sullivan  <sullivan@apple.com>
9047
9048         Reviewed by Dan Bernstein.
9049
9050         <https://bugs.webkit.org/show_bug.cgi?id=62165>
9051         <rdar://problem/9555835>
9052         WebKit2 find-on-page callback doesn’t handle kWKMoreThanMaximumMatchCount on PDF pages
9053
9054         * UIProcess/API/mac/PDFViewController.mm:
9055         (WebKit::PDFViewController::findString):
9056         Return kWKMoreThanMaximumMatchCount when appropriate, a la FindController::countStringMatches().
9057         Also, skip counting all the matches if maxMatchCount is 0, to avoid (perhaps slowly) computing a
9058         number that would be ignored.
9059
9060 2011-06-06  Carlos Garcia Campos  <cgarcia@igalia.com>
9061
9062         Reviewed by Anders Carlsson.
9063
9064         Do not use NPRuntimeObjectMap in NetscapePlugin::setException when plug-in is running out of process
9065         https://bugs.webkit.org/show_bug.cgi?id=62124
9066
9067         * WebProcess/Plugins/Netscape/NetscapePlugin.cpp:
9068         (WebKit::NetscapePlugin::setException):
9069
9070 2011-06-06  Dominic Cooney  <dominicc@chromium.org>
9071
9072         Unreviewed WinCairo build fix after r88159.
9073
9074         * win/WebKit2CFLite.def: Export symbols for WebCoreTestSupport.
9075
9076 2011-06-04  Dominic Cooney  <dominicc@chromium.org>
9077
9078         Reviewed by Dimitri Glazkov.
9079
9080         Re-export JSC and WebCore symbols required by WebCoreTestSupport.
9081         https://bugs.webkit.org/show_bug.cgi?id=61076
9082
9083         * win/WebKit2.def:
9084
9085 2011-06-06  Alexandru Chiculita  <achicu@adobe.com>
9086
9087         Reviewed by Kent Tamura.
9088
9089         Add ENABLE_CSS_EXCLUSIONS support for build-webkit script
9090         https://bugs.webkit.org/show_bug.cgi?id=61628
9091
9092         * Configurations/FeatureDefines.xcconfig:
9093
9094 2011-06-06  Mihnea Ovidenie  <mihnea@adobe.com>
9095
9096         Reviewed by Kent Tamura.
9097
9098         Add ENABLE(CSS_REGIONS) guard for CSS Regions support
9099         https://bugs.webkit.org/show_bug.cgi?id=61631
9100
9101         * Configurations/FeatureDefines.xcconfig:
9102
9103 2011-06-06  Carlos Garcia Campos  <cgarcia@igalia.com>
9104
9105         Reviewed by Anders Carlsson.
9106
9107         [UNIX] SOCK_DGRAM sockets are not notified when the other end closes the connection
9108         https://bugs.webkit.org/show_bug.cgi?id=61538
9109
9110         Use SOCK_STREAM instead of SOCK_DGRAM sockets. Rework the message
9111         receiver code to support stream sockets, since it requires to
9112         handle message boundaries. The same code works for DGRAM sockets,
9113         so this change shouldn't break other ports using DGRAM.
9114
9115         * Platform/CoreIPC/Connection.h:
9116         * Platform/CoreIPC/unix/ConnectionUnix.cpp:
9117         (CoreIPC::Connection::platformInitialize):
9118         (CoreIPC::Connection::processMessage): Process messages from data
9119         already received.
9120         (CoreIPC::readBytesFromSocket): Read from socket using recvmsg().
9121         (CoreIPC::Connection::readyReadHandler):
9122         * UIProcess/Launcher/gtk/ProcessLauncherGtk.cpp:
9123         (WebKit::ProcessLauncher::launchProcess): Use SOCK_DGRAM in
9124         socketpair().
9125
9126 == Rolled over to ChangeLog-2011-06-04 ==