Use the Cookie Storage from the Private Browsing Storage Session directly
[WebKit-https.git] / Source / WebKit2 / ChangeLog
1 2011-03-09  Jessie Berlin  <jberlin@apple.com>
2
3         Reviewed by Adam Roben.
4
5         Use the Cookie Storage from the Private Browsing Storage Session directly
6         https://bugs.webkit.org/show_bug.cgi?id=55986
7
8         * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
9         (InitWebCoreSystemInterface):
10
11 2011-03-09  Alejandro G. Castro  <alex@igalia.com>
12
13         Fix compilation after r80596, add soup Download stubs.
14
15         * GNUmakefile.am:
16         * WebProcess/Downloads/soup/DownloadSoup.cpp: Added.
17         (WebKit::Download::start):
18         (WebKit::Download::startWithHandle):
19         (WebKit::Download::cancel):
20         (WebKit::Download::platformInvalidate):
21         (WebKit::Download::didDecideDestination):
22         (WebKit::Download::platformDidFinish):
23
24 2011-03-09  Alejandro G. Castro  <alex@igalia.com>
25
26         Fix GTK+ compilation after r80619. Add WebFullScreenManager.
27
28         * GNUmakefile.am:
29
30 2011-03-08  Jer Noble  <jer.noble@apple.com>
31
32         Reviewed by Sam Weinig.
33
34         WebKit2: Plumb through the FULLSCREEN_API Chrome client calls
35         https://bugs.webkit.org/show_bug.cgi?id=55273
36
37         The FULLSCREEN_API Chrome client calls need to be plumbed through from the 
38         WebProcess to the UIProcess.  To do this, WebFullScreenManager (and Proxy)
39         classes have been added to WebPage.
40
41         * DerivedSources.make: Added rules necessary to build DerivedSources for new .in files.
42         * DerivedSources.pro: Ditto.
43         * Platform/CoreIPC/MessageID.h: Added message types for WebFullScreenManager.
44         * Shared/API/c/WKBase.h: Added WKFullScreenManagerRef.
45         * Shared/APIObject.h: Added APIType for WebFullScreenManager.
46         * UIProcess/WebFullScreenManagerProxy.cpp: Added.
47         * UIProcess/WebFullScreenManagerProxy.h: Added.
48         * UIProcess/WebFullScreenManagerProxy.messages.in: Added.
49         * UIProcess/WebPageProxy.cpp:
50         (WebKit::WebPageProxy::close): Invalidate and clear m_fullScreenManager.
51         (WebKit::WebPageProxy::processDidCrash): Ditto.
52         (WebKit::WebPageProxy::didReceiveMessage): Pass messages on to WebFullScreenManagerProxy.
53         (WebKit::WebPageProxy::didReceiveSyncMessage): Ditto.
54         (WebKit::WebPageProxy::fullScreenManager): Added. Lazy instantiation of m_fullScreenManager.
55         * UIProcess/WebPageProxy.h:
56         * UIProcess/WebPageProxy.messages.in:
57         * UIProcess/WebUIClient.cpp:
58         * UIProcess/WebUIClient.h:
59         * WebKit2.xcodeproj/project.pbxproj: Added references to new classes in project file.
60         * WebKit2.pro: Ditto.
61         * win/WebKit2.vcproj: Ditto.
62         * WebKit2.pri: Added new directories to include file path.
63         * win/WebKit2Common.vsprops: Ditto.
64         * WebProcess/FullScreen/WebFullScreenManager.cpp: Added.
65         * WebProcess/FullScreen/WebFullScreenManager.h: Added.
66         * WebProcess/FullScreen/WebFullScreenManager.messages.in: Added.
67         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
68         (WebKit::WebChromeClient::supportsFullScreenForElement): Pass through to WebFullScreenManager.
69         (WebKit::WebChromeClient::enterFullScreenForElement): Ditto.
70         (WebKit::WebChromeClient::exitFullScreenForElement): Ditto.
71         * WebProcess/WebPage/WebPage.cpp:
72         (WebKit::WebPage::close): Invalidate and clear m_fullScreenManager.
73         (WebKit::WebPage::fullScreenManager): Lazy instantiation of m_fullScreenManager.
74         (WebKit::WebPage::didReceiveMessage): Pass messages through to WebFullScreenManager.
75         * WebProcess/WebPage/WebPage.h:
76
77 2011-03-08  Jer Noble  <jer.noble@apple.com>
78
79         Reviewed by Sam Weinig.
80
81         WebKit2: Plumb through the "supportsFullScreen" preference.
82         https://bugs.webkit.org/show_bug.cgi?id=55261
83
84         The "supportsFullScreen" preference needs to be plumbed through from
85         the UIProcess to the WebProcess.
86
87         * Shared/WebPreferencesStore.h: Add a new macro entry.
88         * UIProcess/API/C/WKPreferences.cpp: Implement preferences getter and setter.
89         (WKPreferencesSetFullScreenEnabled):
90         (WKPreferencesGetFullScreenEnabled):
91         * UIProcess/API/C/WKPreferences.h:
92         * WebProcess/WebPage/WebPage.cpp:
93         (WebKit::WebPage::updatePreferences): Sync the fullScreenEnabled setting through to
94             the settings object.
95
96 2011-03-08  Jeff Miller  <jeffm@apple.com>
97
98         Reviewed by Adele Peterson.
99
100         WebKit2: Implement Windows glue for Undo/Redo
101         https://bugs.webkit.org/show_bug.cgi?id=55961
102         
103         Expose Undo/Redo infrastructure through WKView on Windows by
104         adding an undo client as well as APIs to reapply and unapply
105         an edit command.
106
107         * UIProcess/API/C/win/WKView.cpp:
108         (WKViewSetViewUndoClient): Added.
109         (WKViewReapplyEditCommand): Added.
110         (WKViewUnapplyEditCommand): Added.
111         * UIProcess/API/C/win/WKView.h: Added WKViewUndoClient, WKViewSetViewUndoClient(), and WKViewUnapplyEditCommand().
112         * UIProcess/WebPageProxy.cpp:
113         (WebKit::WebPageProxy::isValidEditCommand): Added, used to validated an edit command from a WKView API.
114         * UIProcess/WebPageProxy.h: Added isValidEditCommand().
115         * UIProcess/win/WebUndoClient.cpp: Added, APIClient for WKViewUndoClient. 
116         (WebKit::WebUndoClient::registerEditCommand): Added.
117         (WebKit::WebUndoClient::clearAllEditCommands): Added.
118         * UIProcess/win/WebUndoClient.h: Added, APIClient for WKViewUndoClient.
119         * UIProcess/win/WebView.cpp:
120         (WebKit::WebView::initializeUndoClient): Added.
121         (WebKit::WebView::close): Clear out undo client.
122         (WebKit::WebView::registerEditCommand): Implemented to call through to WKViewUndoClient.
123         (WebKit::WebView::clearAllEditCommands): Implmented to call through to WKViewUndoClient.
124         (WebKit::WebView::reapplyEditCommand): Added.
125         (WebKit::WebView::unapplyEditCommand): Added.
126         * UIProcess/win/WebView.h: Added undo client support.
127         * win/WebKit2.vcproj: Added WebUndoClient.cpp and WebUndoClient.h.
128
129 2011-03-08  Jeff Miller  <jeffm@apple.com>
130
131         Reviewed by Sam Weinig.
132
133         WebKit2: Expose WebEditCommandProxy in the C API on Windows
134         https://bugs.webkit.org/show_bug.cgi?id=55962
135         
136         Make WebEditCommandProxy a subclass of APIObject, and define
137         WKEditCommandRef as the type that will be exposed through the C API.
138
139         * Shared/API/c/win/WKBaseWin.h: Add WKEditCommandRef.
140         * Shared/APIObject.h: Add platform-specific TypeEditCommandProxy.
141         * UIProcess/API/C/win/WKAPICastWin.h: Add API mapping for WKEditCommandRef.
142         * UIProcess/WebEditCommandProxy.h: Subclass WebEditCommandProxy from APIObject.
143         (WebKit::WebEditCommandProxy::type): Added.
144
145 2011-03-08  Jeff Miller  <jeffm@apple.com>
146
147         Reviewed by Oliver Hunt.
148
149         WebKit2: Redo is broken
150         https://bugs.webkit.org/show_bug.cgi?id=55978
151         
152         WebEditCommandProxy::unapply() and WebEditCommandProxy::reapply() were registering the wrong edit command when an undo or redo happens.
153         For example, when we unapply(), we should register a Redo command, not an Undo command.
154
155         * UIProcess/WebEditCommandProxy.cpp:
156         (WebKit::WebEditCommandProxy::unapply): Register a Redo command, not an Undo command.
157         (WebKit::WebEditCommandProxy::reapply): Register an Undo command, not a Redo command.
158
159 2011-03-08  Brent Fulgham  <bfulgham@webkit.org>
160
161         Reviewed by Adam Roben.
162
163         https://bugs.webkit.org/show_bug.cgi?id=55977
164         Refine CF/CFNet distinctions for better code sharing.
165         1. Rename Downloads/cf/win/DownloadCFNetWin.cpp to DownloadCFWin.cpp
166            since it does not use any CFNETWORK features.
167         2. Create new cfnet directory.
168         3. Move Downloads/cf/DownloadCFNet.cpp to Downloads/cfnet
169         4. Update project file.
170
171         * WebProcess/Downloads/cf/DownloadCFNet.cpp: Removed.
172         * WebProcess/Downloads/cf/win/DownloadCFNetWin.cpp: Removed.
173         * WebProcess/Downloads/cf/win/DownloadCFWin.cpp: Copied from WebProcess/Downloads/cf/win/DownloadCFNetWin.cpp.
174         * WebProcess/Downloads/cfnet: Added.
175         * WebProcess/Downloads/cfnet/DownloadCFNet.cpp: Copied from WebProcess/Downloads/cf/DownloadCFNet.cpp.
176         * win/WebKit2.vcproj:
177
178 2011-03-08  Mark Rowe  <mrowe@apple.com>
179
180         Reviewed by Brady Eidson.
181
182         <http://webkit.org/b/55976> Provisional URL should be loaded when restoring session state even if there are back / forward list entries.
183
184         * UIProcess/cf/WebPageProxyCF.cpp:
185         (WebKit::WebPageProxy::restoreFromSessionStateData): If there's a provisional URL that we will load then restore the session state
186         without navigating to the current item.
187         * WebProcess/WebPage/WebPage.messages.in: Expose the ability to restore the session state without navigating to the current item.
188
189 2011-03-08  Brent Fulgham  <bfulgham@webkit.org>
190
191         Reviewed by Anders Carlsson.
192
193         https://bugs.webkit.org/show_bug.cgi?id=55956
194         WebKit2 Changes to correct WinCairo port build
195
196         * Shared/LayerTreeContext.h: Don't exclude CoreIPC declarations for non-accelerated
197           compositing case.
198         * UIProcess/DrawingAreaProxy.h: Add "stdint.h" include needed for Cairo build.
199         * UIProcess/DrawingAreaProxyImpl.cpp: Exclude accelerated compositing code for
200           WinCairo build.
201         (WebKit::DrawingAreaProxyImpl::~DrawingAreaProxyImpl):
202         (WebKit::DrawingAreaProxyImpl::didUpdateBackingStoreState):
203         (WebKit::DrawingAreaProxyImpl::enterAcceleratedCompositingMode):
204         (WebKit::DrawingAreaProxyImpl::exitAcceleratedCompositingMode):
205         (WebKit::DrawingAreaProxyImpl::sendUpdateBackingStoreState):
206         (WebKit::DrawingAreaProxyImpl::waitForAndDispatchDidUpdateBackingStoreState):
207         * UIProcess/DrawingAreaProxyImpl.h: Exclude declarations for code only used when
208           accelerated compositing is enabled.
209         (WebKit::DrawingAreaProxyImpl::isInAcceleratedCompositingMode):
210         * UIProcess/win/WebView.cpp: Protect CG-specific drawing code.
211         (WebKit::WebView::setFindIndicator):
212         * WebProcess/Downloads/Download.h: Allow CFLite implentation to share overwrite flag,
213           as well as destination and bundle paths.
214         * WebProcess/Downloads/curl/DownloadCurl.cpp: Remove stub (to share CFNet implementation
215           of file handling.  This will be moved to a common area in a future patch.)
216         * WebProcess/WebPage/DrawingAreaImpl.cpp: Exclude accelerated-compositing paths.
217         (WebKit::DrawingAreaImpl::layerHostDidFlushLayers):
218         (WebKit::DrawingAreaImpl::sendDidUpdateBackingStoreState):
219         (WebKit::DrawingAreaImpl::exitAcceleratedCompositingMode):
220         * WebProcess/WebPage/WebPage.cpp: Protect CG-specific drawing code.
221         (WebKit::WebPage::drawRectToPDF):
222         (WebKit::WebPage::drawPagesToPDF):
223         * win/WebKit2.vcproj: Exclude unused LayerTreeContext from WinCairo
224
225 2011-03-08  Ivan Krstić  <ike@apple.com>
226
227         Reviewed by Sam Weinig.
228
229         Re-fix: can't paste from 3rd party text editor into WebKit2 window
230         <rdar://problem/8978624>
231
232         * WebProcess/com.apple.WebProcess.sb:
233
234 2011-03-08  Martin Robinson  <mrobinson@igalia.com>
235
236         Fix the WebKit2 compilation after r80578.
237
238         * UIProcess/gtk/WebView.cpp:
239         (WebKit::WebView::setFocus): Added.
240         * UIProcess/gtk/WebView.h:
241
242 2011-03-08  Jessie Berlin  <jberlin@apple.com>
243
244         Reviewed by Anders Carlsson.
245
246         Crash in CFNetwork visiting google.com
247         https://bugs.webkit.org/show_bug.cgi?id=55958
248
249         * Shared/API/c/cf/WKURLResponseCF.cpp:
250         (WKURLResponseCopyCFURLResponse):
251         If the response to copy is null, return 0;
252
253 2011-03-08  John Sullivan  <sullivan@apple.com>
254
255         Reverted the patch for https://bugs.webkit.org/show_bug.cgi?id=55940
256         
257         The patch was insufficient, and it wasn't useful for the intended client use either.
258
259         * WebProcess/InjectedBundle/API/c/WKBundlePage.h:
260         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
261         (WebKit::WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
262
263 2011-03-08  Alejandro G. Castro  <alex@igalia.com>
264
265         Unreviewed, fixed GTK+ compilation after r80569.
266
267         * UIProcess/gtk/WebView.cpp:
268         (WebKit::WebView::windowToScreen):
269         * UIProcess/gtk/WebView.h:
270
271 2011-03-08  Chris Fleizach  <cfleizach@apple.com>
272
273         Reviewed by Sam Weinig.
274
275         WK2: Cannot set focus on an element when focus is outside of WKView
276         https://bugs.webkit.org/show_bug.cgi?id=55281
277
278         * UIProcess/API/mac/PageClientImpl.h:
279         * UIProcess/API/mac/PageClientImpl.mm:
280         (WebKit::PageClientImpl::setFocus):
281         * UIProcess/API/qt/qwkpage_p.h:
282         (QWKPagePrivate::setFocus):
283         * UIProcess/PageClient.h:
284         * UIProcess/WebPageProxy.cpp:
285         (WebKit::WebPageProxy::setFocus):
286         * UIProcess/WebPageProxy.h:
287         * UIProcess/WebPageProxy.messages.in:
288         * UIProcess/win/WebView.h:
289         (WebKit::WebView::setFocus):
290         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
291         (WebKit::WebChromeClient::focus):
292         (WebKit::WebChromeClient::unfocus):
293
294 2011-03-08  Jeff Miller  <jeffm@apple.com>
295
296         Unreviewed, fix last change so WKBaseWin.h is in alphabetical order in the project XML.
297
298         * win/WebKit2.vcproj: Move WKBaseWin.h to be in alphabetical order.
299
300 2011-03-08  Jeff Miller  <jeffm@apple.com>
301
302         Reviewed by Darin Adler.
303
304         Remove Source/WebKit2/UIProcess/API/C/win/WKBaseWin.h
305         https://bugs.webkit.org/show_bug.cgi?id=55952
306
307         * UIProcess/API/C/win/WKBaseWin.h: Removed.
308         * win/WebKit2.vcproj: Refer to the Shared version of WKBaseWin.h instead of the one in UIProcess.
309
310 2011-03-08  Alejandro G. Castro  <alex@igalia.com>
311
312         Reviewed by Martin Robinson.
313
314         [GTK] Add new files to compilation after r77974
315         https://bugs.webkit.org/show_bug.cgi?id=54076
316
317         The commit added new code to allow passing context to policy
318         delegate methods, we also added dummy ResourceRequest and
319         ResourceResponse decoders until we implement them.
320
321         * GNUmakefile.am:
322         * Shared/gtk/WebCoreArgumentCodersGtk.cpp:
323         (CoreIPC::decodeResourceRequest):
324         (CoreIPC::decodeResourceResponse):
325
326 2011-03-08  Chris Fleizach  <cfleizach@apple.com>
327
328         Reviewed by Darin Adler.
329
330         AX: Webkit2 not sending UAZoomFocusChanged notifications
331         https://bugs.webkit.org/show_bug.cgi?id=55916
332
333         Needed to implement the windowToScreen() method so that the right frame
334         could be calculated to send for zoom focus changes.
335
336         * UIProcess/API/mac/PageClientImpl.h:
337         * UIProcess/API/mac/PageClientImpl.mm:
338         (WebKit::PageClientImpl::windowToScreen):
339         * UIProcess/API/qt/qwkpage.cpp:
340         (QWKPagePrivate::windowToScreen):
341         * UIProcess/API/qt/qwkpage_p.h:
342         * UIProcess/PageClient.h:
343         * UIProcess/WebPageProxy.cpp:
344         (WebKit::WebPageProxy::windowToScreen):
345         * UIProcess/WebPageProxy.h:
346         * UIProcess/WebPageProxy.messages.in:
347         * UIProcess/win/WebView.cpp:
348         (WebKit::WebView::windowToScreen):
349         * UIProcess/win/WebView.h:
350         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
351         (WebKit::WebChromeClient::windowToScreen):
352         * WebProcess/WebPage/WebPage.cpp:
353         (WebKit::WebPage::windowToScreen):
354         * WebProcess/WebPage/WebPage.h:
355
356 2011-03-08  John Sullivan  <sullivan@apple.com>
357
358         Reviewed by Darin Adler.
359
360         https://bugs.webkit.org/show_bug.cgi?id=55940
361         WebKit2 should support Ignore policy from injected bundle client
362
363         * WebProcess/InjectedBundle/API/c/WKBundlePage.h:
364         Added WKBundlePagePolicyActionIgnore.
365         
366         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
367         (WebKit::WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
368         If the injected bundle client returns WKBundlePagePolicyActionIgnore, convert it
369         to the loader's PolicyIgnore.
370
371 2011-03-08  Laszlo Gombos  <laszlo.1.gombos@nokia.com>
372
373         Reviewed by Kenneth Rohde Christiansen.
374
375         [Qt] [Symbian] [WK2] Fix building WebKit 2 API tests
376         https://bugs.webkit.org/show_bug.cgi?id=55876
377
378         Make sure TESTS_SOURCE_DIR is set for Symbian the same way
379         as it is for WK1.
380
381         * UIProcess/API/qt/tests/qgraphicswkview/tst_qgraphicswkview.cpp:
382         (tst_QGraphicsWKView::loadEmptyPage):
383         * UIProcess/API/qt/tests/tests.pri:
384
385 2011-03-07  Damian Kaleta  <dkaleta@apple.com>
386
387         Reviewed by Anders Carlsson.
388
389         QuickTime plugin should opt in to a 32-bit non-executable heap
390         https://bugs.webkit.org/show_bug.cgi?id=55704
391         <rdar://problem/8105706>
392
393         * UIProcess/Plugins/PluginProcessProxy.cpp:
394         (WebKit::pluginNeedsExecutableHeap): Decides per plugin if it should opt-in to a 32-bit non-executable heap.
395         By default it should opt-out.
396         (WebKit::PluginProcessProxy::PluginProcessProxy):
397
398 2011-03-07  Sam Weinig  <sam@webkit.org>
399
400         Reviewed by Anders Carlsson.
401
402         Add unableToImplementPolicy callback for WebKit2 policy client
403         <rdar://problem/9071902>
404         https://bugs.webkit.org/show_bug.cgi?id=55884
405
406         * UIProcess/API/C/WKPage.h:
407         * UIProcess/WebPageProxy.cpp:
408         (WebKit::WebPageProxy::unableToImplementPolicy):
409         * UIProcess/WebPageProxy.h:
410         * UIProcess/WebPageProxy.messages.in:
411         * UIProcess/WebPolicyClient.cpp:
412         (WebKit::WebPolicyClient::unableToImplementPolicy):
413         * UIProcess/WebPolicyClient.h:
414         * WebProcess/InjectedBundle/API/c/WKBundlePage.h:
415         * WebProcess/InjectedBundle/InjectedBundlePagePolicyClient.cpp:
416         (WebKit::InjectedBundlePagePolicyClient::unableToImplementPolicy):
417         * WebProcess/InjectedBundle/InjectedBundlePagePolicyClient.h:
418         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
419         (WebKit::WebFrameLoaderClient::dispatchUnableToImplementPolicy):
420         Pipe unableToImplementPolicy through both the bundle and the main WebKit2 API.
421
422 2011-03-07  Sam Weinig  <sam@webkit.org>
423
424         Reviewed by Anders Carlsson.
425
426         Replace WebKit2's decidePolicyForMIMEType with decidePolicyForResponse
427         https://bugs.webkit.org/show_bug.cgi?id=55827
428
429         - Renamed FrameLoaderClient::dispatchDecidePolicyForMIMEType to dispatchDecidePolicyForResponse
430           and pass the entire response, instead of just the MIMEType.
431         - Updated both UIProcess API and bundle API to also be based on the whole response, not just the
432           MIMEType.
433
434         * UIProcess/API/C/WKPage.h:
435         * UIProcess/WebPageProxy.cpp:
436         (WebKit::WebPageProxy::decidePolicyForResponse):
437         * UIProcess/WebPageProxy.h:
438         * UIProcess/WebPageProxy.messages.in:
439         * UIProcess/WebPolicyClient.cpp:
440         (WebKit::WebPolicyClient::decidePolicyForResponse):
441         * UIProcess/WebPolicyClient.h:
442         * WebProcess/InjectedBundle/API/c/WKBundlePage.h:
443         * WebProcess/InjectedBundle/InjectedBundlePagePolicyClient.cpp:
444         (WebKit::InjectedBundlePagePolicyClient::decidePolicyForResponse):
445         * WebProcess/InjectedBundle/InjectedBundlePagePolicyClient.h:
446         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
447         (WebKit::WebFrameLoaderClient::dispatchDecidePolicyForResponse):
448         * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
449
450 2011-03-06  Jessie Berlin  <jberlin@apple.com>
451
452         Reviewed by Sam Weinig.
453
454         WebKit2: Use CFNetwork Sessions API.
455         https://bugs.webkit.org/show_bug.cgi?id=55435.
456
457         When Private Browsing is enabled, use cookies from a in-memory cookie storage based on the
458         Private Browsing Storage Session.
459
460         * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
461         (InitWebCoreSystemInterface):
462         Add support for using the new WKSI functions in WebCore.
463
464 2011-03-06  Oleg Romashin  <romaxa@gmail.com>
465
466         Reviewed by Kenneth Rohde Christiansen.
467
468         [Qt][WK2] Make Qt port compiling with ENABLE_PLUGIN_PROCESS=1, part1
469         Adding dummy Qt files for Plugin Process implementation,
470         Adding missing sources into Qt pro files
471         https://bugs.webkit.org/show_bug.cgi?id=55719
472
473         * DerivedSources.pro:
474         * PluginProcess/qt: Added.
475         * PluginProcess/qt/PluginControllerProxyQt.cpp: Added.
476         (WebKit::PluginControllerProxy::platformInitialize):
477         (WebKit::PluginControllerProxy::platformDestroy):
478         (WebKit::PluginControllerProxy::platformGeometryDidChange):
479         * PluginProcess/qt/PluginProcessMainQt.cpp: Added.
480         (WebKit::PluginProcessMain):
481         * PluginProcess/qt/PluginProcessQt.cpp: Added.
482         (WebKit::PluginProcess::platformInitialize):
483         * UIProcess/Plugins/qt/PluginProcessProxyQt.cpp: Added.
484         (WebKit::PluginProcessProxy::platformInitializePluginProcess):
485         * WebKit2.pri:
486         * WebKit2.pro:
487         * WebKit2API.pri:
488         * WebProcess/Plugins/Netscape/qt/PluginProxyQt.cpp: Added.
489         (WebKit::PluginProxy::needsBackingStore):
490
491 2011-03-05  Sam Weinig  <sam@webkit.org>
492
493         Reviewed by Dan Bernstein.
494
495         Remove unneeded onPageClose function from DrawingArea
496         https://bugs.webkit.org/show_bug.cgi?id=55836
497
498         * WebProcess/WebPage/DrawingArea.h:
499         Remove empty function.
500
501         * WebProcess/WebPage/WebPage.cpp:
502         (WebKit::WebPage::close):
503         Remove only called
504
505 2011-03-04  Jon Honeycutt  <jhoneycutt@apple.com>
506
507         WK2 Mac build fix.
508
509         * UIProcess/API/C/WKPage.cpp:
510         (WKPageComputePagesForPrinting):
511         (WKPageBeginPrinting):
512
513         * UIProcess/API/C/WKPagePrivate.h:
514
515 2011-03-04  Jon Honeycutt  <jhoneycutt@apple.com>
516
517         WK2 Mac build fix.
518
519         * UIProcess/API/C/WKPagePrivate.h:
520
521 2011-03-04  Jon Honeycutt  <jhoneycutt@apple.com>
522
523         WK2 needs printing support on Windows
524         https://bugs.webkit.org/show_bug.cgi?id=55800
525         <rdar://problem/8903808>
526
527         Reviewed by Darin Adler.
528
529         * UIProcess/API/C/WKPage.cpp:
530         (ComputedPagesContext::ComputedPagesContext):
531         (computedPagesCallback):
532         From the Vector of WebCore::IntRects, build up a Vector of WKRects.
533         Call the callback, passing these rects and the scale factor.
534         (printInfoFromWKPrintInfo):
535         Return a PrintInfo structure from the WKPrintInfo.
536         (WKPageComputePagesForPrinting):
537         Call WebPageProxy::computePagesForPrinting(). Pass
538         computedPagesCallback as the callback function, so that we can
539         translate the WebCore rect type to WKRect before calling the caller's
540         callback function.
541         (WKPageBeginPrinting):
542         Call WebPageProxy::beginPrinting().
543         (WKPageDrawPagesToPDF):
544         Call WebPageProxy::drawPagesToPDF().
545
546         * UIProcess/API/C/WKPagePrivate.h:
547         Declare the WKPrintInfo type and new functions.
548
549         * UIProcess/WebPageProxy.cpp:
550         Compile this code on Windows.
551
552         * UIProcess/WebPageProxy.h:
553         Ditto.
554
555         * UIProcess/win/WebView.cpp:
556         (WebKit::WebView::paint):
557         We're painting the window; leave printing mode.
558
559         * WebProcess/WebPage/WebPage.cpp:
560         Compile this code on Windows.
561
562         * WebProcess/WebPage/WebPage.h:
563         Ditto.
564
565         * WebProcess/WebPage/WebPage.messages.in:
566         Ditto.
567
568 2011-03-04  Steve Falkenburg  <sfalken@apple.com>
569
570         Reviewed by Darin Adler.
571
572         Adopt VersionStamper tool for Windows WebKit DLLs
573         https://bugs.webkit.org/show_bug.cgi?id=55784
574         <rdar://problem/9021320>
575
576         We now use a tool to stamp the version number onto the Apple WebKit DLLs
577         during the post-build step.
578
579         Fetch the WebKit version from a string resource instead of the version resource.
580
581         * UIProcess/win/WebPageProxyWin.cpp:
582         (WebKit::userVisibleWebKitVersionString): Fetch version from a string resource.
583         * win/WebKit2.rc: Removed version, added stringtable.
584         * win/WebKit2WebProcess.rc: Removed.
585         * win/WebKit2WebProcess.vcproj:
586         * win/WebKit2WebProcessPostBuild.cmd: Don't run autoversion script. It isn't used in this project.
587         * win/WebKit2WebProcessPreBuild.cmd: Stamp version.
588         * win/WebKitPostBuild.cmd: Stamp version.
589
590 2011-03-04  Jeff Miller  <jeffm@apple.com>
591
592         Reviewed by Darin Adler.
593
594         Add WKPageValidateCommand()
595         https://bugs.webkit.org/show_bug.cgi?id=55793
596         
597         On the Mac, validation of edit menu commands is handled within WebKit2 in WKView.mm.
598         However, on Windows we need to do this in the client, so expose this functionality
599         in the API via WKPageValidateCommand().
600         
601         Change the Mac implementation to call WebPageProxy::validateCommand() with a callback
602         to match this new API, so it no longer has to go through PageClient to get notified
603         when a command is validated.  This makes PageClient::setEditCommandState() obsolete,
604         so I removed the stub implementations in qt and gtk as well.
605
606         * UIProcess/API/C/WKPage.cpp:
607         (WKPageValidateCommand): Added.
608         * UIProcess/API/C/WKPage.h: Added WKPageValidateCommand().
609         * UIProcess/API/mac/PageClientImpl.h: Removed setEditCommandState().
610         * UIProcess/API/mac/PageClientImpl.mm: Removed setEditCommandState().
611         * UIProcess/API/mac/WKView.mm:
612         (validateCommandCallback): Added.
613         (-[WKView validateUserInterfaceItem:]): Pass callback to validateCommand().
614         * UIProcess/API/qt/qwkpage.cpp: Removed setEditCommandState().
615         * UIProcess/API/qt/qwkpage_p.h: Removed setEditCommandState().
616         * UIProcess/PageClient.h: Removed setEditCommandState().
617         * UIProcess/WebPageProxy.cpp: Removed didValidateCommand().
618         (WebKit::WebPageProxy::validateCommand): This now takes a callback.
619         (WebKit::WebPageProxy::validateCommandCallback): Added.
620         (WebKit::WebPageProxy::processDidCrash): Invalidate m_validateCommandCallbacks.
621         * UIProcess/WebPageProxy.h: Removed didValidateCommand(), validateCommand() now takes a callback.
622         (WebKit::ValidateCommandCallback::create): Added.
623         (WebKit::ValidateCommandCallback::~ValidateCommandCallback): Added.
624         (WebKit::ValidateCommandCallback::performCallbackWithReturnValue): Added.
625         (WebKit::ValidateCommandCallback::invalidate): Added.
626         (WebKit::ValidateCommandCallback::ValidateCommandCallback): Added.
627         * UIProcess/WebPageProxy.messages.in: Removed DidValidateCommand, added ValidateCommandCallback.
628         * UIProcess/gtk/WebView.cpp: Removed setEditCommandState().
629         * UIProcess/gtk/WebView.h: Removed setEditCommandState().
630         * UIProcess/win/WebView.cpp: Removed setEditCommandState().
631         * UIProcess/win/WebView.h: Removed setEditCommandState().
632         * WebProcess/WebPage/WebPage.cpp:
633         (WebKit::WebPage::validateCommand): This now takes a callbackID.
634         * WebProcess/WebPage/WebPage.h: validateCommand now takes a callbackID.
635         * WebProcess/WebPage/WebPage.messages.in: ValidateCommand now takes a callbackID.
636
637 2011-03-04  Brian Weinstein  <bweinstein@apple.com>
638
639         Reviewed by Darin Adler.
640
641         Reference-counting for WKBundlePageResourceLoadClient::willSendRequestForFrame seems unclear/wrong
642         https://bugs.webkit.org/show_bug.cgi?id=53919
643         <rdar://problem/8966020>
644         
645         Adopt the result of m_client.willSendRequestForFrame (which will be leaked by the client).
646
647         * WebProcess/InjectedBundle/InjectedBundlePageResourceLoadClient.cpp:
648         (WebKit::InjectedBundlePageResourceLoadClient::willSendRequestForFrame):
649
650 2011-03-04  Darin Adler  <darin@apple.com>
651
652         Reviewed by Mark Rowe.
653
654         WebKit2 session state should include even loads too new to be in the back/forward list
655         https://bugs.webkit.org/show_bug.cgi?id=55781
656         part of <rdar://problem/8968847>
657
658         * UIProcess/cf/WebPageProxyCF.cpp:
659         (WebKit::WebPageProxy::sessionStateData): Save URLs that are early enough in the loading
660         process to not be included in the back/forward list yet: The pending API request URL and
661         the provisional URL.
662         (WebKit::WebPageProxy::restoreFromSessionStateData): Call loadURL if the back/forward
663         list is not restored and a URL is present. Later we can improve the way we handle the
664         case where we have both a back/forward list and a URL.
665
666 2011-03-04  Jessie Berlin  <jberlin@apple.com>
667
668         Reviewed by Darin Adler.
669
670         WebKit2: Use CFNetwork Sessions API.
671         https://bugs.webkit.org/show_bug.cgi?id=55435.
672
673         Add in the CFURLSTORAGESESSIONS guards that I incorrectly left out because the code was
674         contained within guards that made USE(CFURLSTORAGESESSIONS) always be true.
675
676         * UIProcess/mac/WebContextMac.mm:
677         (WebKit::WebContext::platformInitializeWebProcess):
678         * UIProcess/win/WebContextWin.cpp:
679         (WebKit::WebContext::platformInitializeWebProcess):
680
681 2011-03-04  Jessie Berlin  <jberlin@apple.com>
682
683         Reviewed by Maciej Stachowiak.
684
685         WebKit2: Use CFNetwork Sessions API.
686         https://bugs.webkit.org/show_bug.cgi?id=55435.
687
688         When Private Browsing is enabled, get the cached url response from the cache associated with
689         the Private Browsing Storage Session.
690
691         * WebProcess/WebPage/mac/WebPageMac.mm:
692         (WebKit::WebPage::platformHasLocalDataForURL):
693         If Private Browsing is enabled, call into WKSI to get the response.
694         (WebKit::WebPage::cachedResponseMIMETypeForURL):
695         Ditto.
696         * WebProcess/WebPage/win/WebPageWin.cpp:
697         (WebKit::WebPage::platformHasLocalDataForURL):
698         If Private Browsing is enabled, call into WKSI to get the CFURLCacheRef.
699         (WebKit::WebPage::cachedResponseMIMETypeForURL):
700         Ditto.
701
702 2011-03-04  Jeff Miller  <jeffm@apple.com>
703
704         Reviewed by Darin Adler.
705
706         Move WKViewExecuteCommand() to WKPageExecuteCommand()
707         https://bugs.webkit.org/show_bug.cgi?id=55744
708         
709         Executing a command operates on a page, so it makes more sense for it to be in WKPage.
710         This also makes it available on all platforms, not just Windows.
711
712         * UIProcess/API/C/WKPage.cpp:
713         (WKPageExecuteCommand): Added.
714         * UIProcess/API/C/WKPage.h: Add WKPageExecuteCommand().
715         * UIProcess/API/C/win/WKView.cpp: Remove WKViewExecuteCommand().
716         * UIProcess/API/C/win/WKView.h: Remove WKViewExecuteCommand().
717
718 2011-03-04  Dan Bernstein  <mitz@apple.com>
719
720         LLVM Compiler build fix.
721
722         * WebProcess/WebPage/WebPage.cpp:
723         (WebKit::WebPage::runJavaScriptInMainFrame):
724
725 2011-03-03  Timothy Hatcher  <timothy@apple.com>
726
727         Make the WKPageRunJavaScriptFunction callback take a WKSerializedScriptValueRef.
728
729         https://webkit.org/b/55623
730
731         Reviewed by Darin Adler.
732
733         * UIProcess/API/C/WKPage.cpp:
734         (WKPageRunJavaScriptInMainFrame): Use ScriptValueCallback.
735         (callRunJavaScriptBlockAndRelease): Use WKSerializedScriptValueRef.
736         * UIProcess/API/C/WKPage.h: Use WKSerializedScriptValueRef.
737         * UIProcess/WebPageProxy.cpp:
738         (WebKit::WebPageProxy::close): Call invalidateCallbackMap for m_scriptValueCallbacks.
739         (WebKit::WebPageProxy::runJavaScriptInMainFrame): Take a ScriptValueCallback.
740         (WebKit::WebPageProxy::scriptValueCallback): Added. Create a WebSerializedScriptValue
741         from the DataReference before calling the callback.
742         (WebKit::WebPageProxy::processDidCrash): Call invalidateCallbackMap for m_scriptValueCallbacks.
743         * UIProcess/WebPageProxy.h: Added ScriptValueCallback and m_scriptValueCallbacks.
744         * UIProcess/WebPageProxy.messages.in: Added ScriptValueCallback.
745         * WebProcess/WebPage/WebPage.cpp:
746         (WebKit::WebPage::runJavaScriptInMainFrame): Create a DataReference from a WebCore::SerializedScriptValue.
747         And use ScriptValueCallback to send the message back.
748
749 2011-03-03  Brian Weinstein  <bweinstein@apple.com>
750
751         Reviewed by Adam Roben.
752
753         Cleanup from https://bugs.webkit.org/show_bug.cgi?id=55427.
754         
755         Call WebCore::startObservingCookieChanges and WebCore::stopObservingCookieChanges
756         on all platforms, and stub the functions on platforms that don't implement them.
757
758         * WebProcess/Cookies/WebCookieManager.cpp:
759         (WebKit::WebCookieManager::startObservingCookieChanges):
760         (WebKit::WebCookieManager::stopObservingCookieChanges):
761
762 2011-03-03  Jeff Miller  <jeffm@apple.com>
763
764         Reviewed by Darin Adler.
765
766         Refactor classes in GenericCallback.h
767         https://bugs.webkit.org/show_bug.cgi?id=55732
768         
769         Since we're going to need to add additional callback classes, make a CallbackBase class that manages
770         the context and the callback ID.  The existing callback classes (VoidCallback, GenericCallback, and
771         ComputedPagesCallback) now all derive from CallbackBase.
772         
773         Fix bug in VoidCallback where we meant to implement the destructor, but we were implementing the default
774         constructor instead (we forgot the leading ~).
775  
776         * UIProcess/GenericCallback.h:
777         (WebKit::CallbackBase::~CallbackBase):
778         (WebKit::CallbackBase::callbackID):
779         (WebKit::CallbackBase::CallbackBase):
780         (WebKit::CallbackBase::context):
781         (WebKit::CallbackBase::generateCallbackID):
782         (WebKit::VoidCallback::~VoidCallback):
783         (WebKit::VoidCallback::performCallback):
784         (WebKit::VoidCallback::invalidate):
785         (WebKit::VoidCallback::VoidCallback):
786         (WebKit::GenericCallback::create):
787         (WebKit::GenericCallback::~GenericCallback):
788         (WebKit::GenericCallback::performCallbackWithReturnValue):
789         (WebKit::GenericCallback::invalidate):
790         (WebKit::GenericCallback::GenericCallback):
791         (WebKit::ComputedPagesCallback::create):
792         (WebKit::ComputedPagesCallback::~ComputedPagesCallback):
793         (WebKit::ComputedPagesCallback::performCallbackWithReturnValue):
794         (WebKit::ComputedPagesCallback::invalidate):
795         (WebKit::ComputedPagesCallback::ComputedPagesCallback):
796
797 2011-03-03  Adam Roben  <aroben@apple.com>
798
799         Don't assume the web process has had a chance to paint before the view has to paint
800
801         Fixes <http://webkit.org/b/55739> REGRESSION (r80307): Lots of tests crashing in
802         BackingStore::paint
803
804         Reviewed by Anders Carlsson.
805
806         * UIProcess/DrawingAreaProxyImpl.cpp:
807         (WebKit::DrawingAreaProxyImpl::paint): Bail if the web process hasn't had a chance to paint
808         yet.
809
810 2011-03-03  Adam Roben  <aroben@apple.com>
811
812         Throw away DrawingAreaProxyImpl's backing store after not painting for 5 seconds
813
814         The intent is to save memory for views that aren't painting.
815
816         Fixes <http://webkit.org/b/51262> <rdar://problem/8782537> WebPageProxy should delete its
817         backing store after not painting for a while
818
819         Reviewed by Anders Carlsson.
820
821         * UIProcess/DrawingAreaProxyImpl.cpp:
822         (WebKit::DrawingAreaProxyImpl::DrawingAreaProxyImpl): Initialize our timer.
823         (WebKit::DrawingAreaProxyImpl::paint): Don't bail if we don't have a backing store (but do
824         bail if we're in accelerated compositing mode); we might have thrown it away to save memory
825         but now are being asked to paint by the view. The existing code in this function will handle
826         getting a new backing store if possible by blocking for a little while to try to receive a
827         DidUpdateBackingStoreState message. Added an assertion that we do have a backing store if we
828         don't have any outstanding UpdateBackingStoreState requests. After painting, call
829         discardBackingStoreSoon to update our timer.
830         (WebKit::DrawingAreaProxyImpl::discardBackingStoreSoon): Set the timer for 5 seconds in the
831         future.
832         (WebKit::DrawingAreaProxyImpl::discardBackingStore): Throw away the backing store, and tell
833         the web process we'll need a full backing store update on the next paint.
834
835         * UIProcess/DrawingAreaProxyImpl.h: Added m_discardBackingStoreTimer.
836
837 2011-03-03  Adam Roben  <aroben@apple.com>
838
839         Add a way to tell the web process to perform a full backing store update on its next paint
840
841         Messages::DrawingArea::UpdateBackingStoreState now takes a boolean specifying whether the
842         full backing store update should happen immediately or should be deferred until the next
843         paint or compositing mode change occurs. The deferred update isn't used yet, but will be
844         used when we start throwing away backing stores to save memory.
845
846         Fixes <http://webkit.org/b/55730> UI process needs a way to tell the web process its backing
847         store needs a full update on the next paint
848
849         Reviewed by Anders Carlsson.
850
851         * UIProcess/DrawingAreaProxyImpl.cpp:
852         (WebKit::DrawingAreaProxyImpl::paint): If we have an outstanding backing store state change
853         request, tell the web process to perform the backing store update right away, in case we
854         previously told it it could defer the update.
855         (WebKit::DrawingAreaProxyImpl::sizeDidChange): Specify that we need an immediate backing
856         store update.
857         (WebKit::DrawingAreaProxyImpl::didUpdateBackingStoreState): We can no longer assert that we
858         were waiting for a DidUpdateBackingStoreState message when we receive one, as it's possible
859         for the web process to decide to send us this message on its own (if we asked it to do a
860         deferred backing store update and then it needed to paint some part of the page). Specify
861         that we need an immediate backing store update if the web process hasn't updated to our
862         latest state, as we're about to draw potentially out-of-date bits to the screen and want to
863         get the right bits as soon as possible. Also added a FIXME about a potential optimization.
864         (WebKit::DrawingAreaProxyImpl::backingStoreStateDidChange): Added a RespondImmediatelyOrNot
865         parameter, which is just passed through to sendUpdateBackingStoreState.
866         (WebKit::DrawingAreaProxyImpl::sendUpdateBackingStoreState): Added a RespondImmediatelyOrNot
867         parameter that is used to specify to the web process whether to perform the full backing
868         store update immediately. We now only wait for a DidUpdateBackingStoreState message (and
869         thus suppress any more UpdateBackingStoreState messages until one is received) when we ask
870         the web process for an immediate response; otherwise we could end up accidentally calling
871         waitForAndDispatchDidUpdateBackingStoreState when the web process hasn't been told to send
872         us such a message.
873
874         * UIProcess/DrawingAreaProxyImpl.h: Added RespondImmediatelyOrNot.
875
876         * WebProcess/WebPage/DrawingArea.h:
877         (WebKit::DrawingArea::updateBackingStoreState): Added respondImmediately argument.
878
879         * WebProcess/WebPage/DrawingArea.messages.in: Added respondImmediately argument to
880         UpdateBackingStoreState message.
881
882         * WebProcess/WebPage/DrawingAreaImpl.cpp:
883         (WebKit::DrawingAreaImpl::DrawingAreaImpl): Initialize new member that's used to track
884         whether we should send a DidUpdateBackingStoreState message instead of an Update or
885         compositing mode change message. This will be set to true when a deferred backing store
886         update is pending.
887         (WebKit::DrawingAreaImpl::layerHostDidFlushLayers): If a deferred update is pending, send a
888         DidUpdateBackingStoreState message instead of a compositing mode change message.
889         (WebKit::DrawingAreaImpl::updateBackingStoreState): Added respondImmediately argument. If
890         we've already been told about this state ID (as can happen when the UI process decides it
891         needs an immediate update to a state that it previously requested a deferred update to),
892         don't bother updating the page's size, etc. In addition, if we've already sent a
893         DidUpdateBackingStoreState message for this state, we don't have to do anything at all.
894         Moved code to send the DidUpdateBackingStoreState message from here...
895         (WebKit::DrawingAreaImpl::sendDidUpdateBackingStoreState): ...to here.
896         (WebKit::DrawingAreaImpl::exitAcceleratedCompositingMode): Always update our dirty region,
897         even if painting is suspended or we're in the process of updating the backing store state.
898         It causes no harm and simplifies the code. If a deferred update is pending, send a
899         DidUpdateBackingStoreState message instead of a compositing mode change message. Also
900         removed a redundant if.
901         (WebKit::DrawingAreaImpl::display): Added an assertion that this isn't called while updating
902         backing store state, as otherwise we might end up sending two DidUpdateBackingStoreState
903         messages. If a deferred update is pending, send a DidUpdateBackingStoreState message instead
904         of an Update message.
905
906         * WebProcess/WebPage/DrawingAreaImpl.h: Updated updateBackingStoreState to match the base
907         class. Added sendDidUpdateBackingStoreState and m_shouldSendDidUpdateBackingStoreState.
908
909 2011-03-03  Andy Estes  <aestes@apple.com>
910
911         Reviewed by Darin Adler.
912
913         When displaying the missing plug-in sheet, pass the 'pluginspage'
914         attribute to the UI process.
915         https://bugs.webkit.org/show_bug.cgi?id=55553
916
917         * UIProcess/API/C/WKPage.h: Add pluginsPageURL as the third argument to
918         missingPluginButtonClicked.
919         * UIProcess/WebPageProxy.cpp:
920         (WebKit::WebPageProxy::missingPluginButtonClicked): Ditto.
921         * UIProcess/WebPageProxy.h: Ditto.
922         * UIProcess/WebPageProxy.messages.in: Ditto.
923         * UIProcess/WebUIClient.cpp:
924         (WebKit::WebUIClient::missingPluginButtonClicked): Ditto.
925         * UIProcess/WebUIClient.h: Ditto.
926         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
927         (WebKit::WebChromeClient::missingPluginButtonClicked): Get the value of
928         pluginspageAttr.
929
930 2011-03-03  Alexey Proskuryakov  <ap@apple.com>
931
932         Suggested by Dan Bernstein.
933
934         Move "const" around "NSString *", so that it suddenly begins to make sense.
935
936         * WebProcess/mac/FullKeyboardAccessWatcher.mm:
937
938 2011-03-03  Jeff Miller  <jeffm@apple.com>
939
940         Reviewed by Anders Carlsson.
941
942         WebKit2: Add WKViewRef API for executing edit commands
943         https://bugs.webkit.org/show_bug.cgi?id=49829
944
945         Added WKViewExecuteCommand() and documented some of the WebCore EditorCommand strings.
946
947         * UIProcess/API/C/win/WKView.cpp:
948         (WKViewExecuteCommand): Added.
949         * UIProcess/API/C/win/WKView.h: Added WKViewExecuteCommand() and comment block with WebCore EditorCommand strings.
950
951 2011-03-03  Jessie Berlin  <jberlin@apple.com>
952
953         Reviewed by Adam Roben.
954
955         WebKit2: Use CFNetwork Sessions API.
956         https://bugs.webkit.org/show_bug.cgi?id=55435
957
958         Set the Private Browsing Storage Session on requests when Private Browsing is enabled.
959
960         * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
961         (InitWebCoreSystemInterface):
962         Support using WKCopyRequestWithStorageSession in WebCore.
963
964 2011-03-03  Adam Roben  <aroben@apple.com>
965
966         Don't try to paint outside the page's bounds
967
968         When the page is resized smaller, we would allocate a ShareableBitmap at the old, larger
969         size, even though we only needed to paint at the new, smaller size.
970
971         The assertion added in this patch will fire during the WebKit2/ResizeViewWhileHidden API
972         test if this fix gets broken in the future.
973
974         Fixes <http://webkit.org/b/55715> DrawingAreaImpl allocates more memory than necessary when
975         the page is resized smaller
976
977         Reviewed by Anders Carlsson.
978
979         * WebProcess/WebPage/DrawingAreaImpl.cpp:
980         (WebKit::DrawingAreaImpl::updateBackingStoreState): Update our dirty region even if painting
981         is suspended (but still refrain from updating it when in accelerated compositing mode).
982         Rather than unite our existing dirty region with the page's new bounds, overwrite our dirty
983         region with the page's new bounds. This prevents us from accumulating a dirty region that is
984         larger than the page in the case where the page is being resized smaller.
985         (WebKit::DrawingAreaImpl::display): Added an assertion that we're not trying to paint
986         outside of the page's bounds.
987
988 2011-03-03  Maciej Stachowiak  <mjs@apple.com>
989
990         Reviewed by Brady Eidson.
991
992         WebProcess is calling CFURLCacheRemoveAllCachedResponses when loading, results in origin-load for all resources
993         https://bugs.webkit.org/show_bug.cgi?id=55701
994         <rdar://problem/9074017>
995
996         * Shared/WebProcessCreationParameters.cpp:
997         (WebKit::WebProcessCreationParameters::WebProcessCreationParameters): Initialize cache-clearing
998         flag parameters to false.
999         (WebKit::WebProcessCreationParameters::encode): Serialize them properly.
1000         (WebKit::WebProcessCreationParameters::decode): And deserialize.
1001
1002 2011-03-03  Alexey Proskuryakov  <ap@apple.com>
1003
1004         Reviewed by Darin Adler.
1005
1006         REGRESSION (WebKit2): Tab keys no longer observe Full Keyboard Access
1007         https://bugs.webkit.org/show_bug.cgi?id=55633
1008         <rdar://problem/8963023>
1009
1010         * WebKit2.xcodeproj/project.pbxproj:
1011         * WebProcess/mac/FullKeyboardAccessWatcher.h: Added.
1012         * WebProcess/mac/FullKeyboardAccessWatcher.mm: Added.
1013         (-[FullKeyboardAccessWatcher retrieveKeyboardUIModeFromPreferences:]):
1014         (-[FullKeyboardAccessWatcher init]):
1015         (+[FullKeyboardAccessWatcher fullKeyboardAccessEnabled]):
1016         Get the current state of full keyboard access, listening for change notifications.
1017
1018         * WebProcess/WebProcess.h:  Added fullKeyboardAccessEnabled().
1019
1020         * WebProcess/WebProcess.cpp: (WebKit::WebProcess::fullKeyboardAccessEnabled):
1021         WebKit1 also doesn't implement this on platforms other than Mac.
1022
1023         * WebProcess/mac/WebProcessMac.mm: (WebKit::WebProcess::fullKeyboardAccessEnabled):
1024         Just ask FullKeyboardAccessWatcher.
1025
1026         * WebProcess/WebCoreSupport/WebChromeClient.cpp: (WebKit::WebChromeClient::keyboardUIMode):
1027         * WebProcess/WebCoreSupport/WebChromeClient.h:
1028         Added keyboardUIMode(), removed tabsToLinks().
1029
1030         * WebProcess/WebPage/WebPage.cpp: (WebKit::WebPage::keyboardUIMode):
1031         * WebProcess/WebPage/WebPage.h:
1032         Generate keyboard UI mode from tabToLinks preference and current state of FKA.
1033
1034 2011-03-03  Sam Weinig  <sam@webkit.org>
1035
1036         Reviewed by Anders Carlsson.
1037
1038         Give the Bundle's policy client the option of deciding the policy
1039         https://bugs.webkit.org/show_bug.cgi?id=55699
1040
1041         * WebProcess/InjectedBundle/API/c/WKBundlePage.h:
1042         Add WKBundlePagePolicyAction enum and make it the return value of
1043         the WKBundlePagePolicyClient functions.
1044
1045         * WebProcess/InjectedBundle/InjectedBundlePagePolicyClient.cpp:
1046         (WebKit::InjectedBundlePagePolicyClient::decidePolicyForNavigationAction):
1047         (WebKit::InjectedBundlePagePolicyClient::decidePolicyForNewWindowAction):
1048         (WebKit::InjectedBundlePagePolicyClient::decidePolicyForMIMEType):
1049         * WebProcess/InjectedBundle/InjectedBundlePagePolicyClient.h:
1050         Pass the return value back to the caller. For unimplemented functions, return WKBundlePagePolicyActionPassThrough.
1051
1052         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
1053         (WebKit::WebFrameLoaderClient::dispatchDecidePolicyForMIMEType):
1054         (WebKit::WebFrameLoaderClient::dispatchDecidePolicyForNewWindowAction):
1055         (WebKit::WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
1056         Call the policy function early if the bundle handles it.
1057
1058 2011-03-02  Brian Weinstein  <bweinstein@apple.com>
1059
1060         Reviewed by Adam Roben.
1061
1062         Rest of WebKit2: Need a way to send notifications to client when cookies change
1063         https://bugs.webkit.org/show_bug.cgi?id=55427
1064         <rdar://problem/9056027>
1065         
1066         This patch adds the communication from the WebProcess <-> UIProcess about starting/stopping
1067         listening for cookies changing, and adds a mechanism for the WebProcess to notify the UIProcess
1068         when the cookies have changed. The WebProcess sends a message to the UIProcess when the cookies
1069         change, and the UIProcess passes this along to the WebCookieManagerProxyClient.
1070
1071         * UIProcess/API/C/WKCookieManager.cpp:
1072         (WKCookieManagerSetClient): Call through to WebCookieManagerProxy.
1073         (WKCookieManagerStartObservingCookieChanges): Ditto.
1074         (WKCookieManagerStopObservingCookieChanges): Ditto.
1075
1076         * UIProcess/API/C/WKCookieManager.h: Add new functions and a WKCookieManagerClient
1077             which is responsible for cookiesDidChange.
1078
1079         * UIProcess/WebCookieManagerProxy.cpp:
1080         (WebKit::WebCookieManagerProxy::initializeClient):
1081         (WebKit::WebCookieManagerProxy::startObservingCookieChanges): Send the message down to the web process.
1082         (WebKit::WebCookieManagerProxy::stopObservingCookieChanges): Ditto.
1083         (WebKit::WebCookieManagerProxy::cookiesDidChange): Tell the WKCookieManagerClient the cookies were
1084             modified.
1085         * UIProcess/WebCookieManagerProxy.h:
1086         * UIProcess/WebCookieManagerProxy.messages.in: Add new messages.
1087
1088         * UIProcess/WebCookieManagerProxyClient.cpp: Added.
1089         (WebKit::WebCookieManagerProxyClient::cookiesDidChange): Calls through to the client saying that
1090             cookies changed.
1091         * UIProcess/WebCookieManagerProxyClient.h: Added.
1092     
1093         * WebProcess/Cookies/WebCookieManager.cpp:
1094         (WebKit::WebCookieManager::startObservingCookieChanges): Call through to WebCore::startObservingCookieChanges
1095             (on platforms that support it).
1096         (WebKit::WebCookieManager::stopObservingCookieChanges): Ditto (for stopObservingCookieChanges).
1097         (WebKit::WebCookieManager::dispatchDidModifyCookies): Send a message to the UI process that cookies changed.
1098         * WebProcess/Cookies/WebCookieManager.h:
1099         * WebProcess/Cookies/WebCookieManager.messages.in:
1100         
1101         Add new files.
1102         * WebKit2.pro:
1103         * WebKit2.xcodeproj/project.pbxproj:
1104         * GNUmakefile.am:
1105         * win/WebKit2.vcproj:
1106
1107 2011-03-03  Anders Carlsson  <andersca@apple.com>
1108
1109         Reviewed by Darin Adler.
1110
1111         Remove CanRunBeforeUnloadConfirmPanel sync message
1112         https://bugs.webkit.org/show_bug.cgi?id=55689
1113
1114         * Shared/WebPageCreationParameters.cpp:
1115         (WebKit::WebPageCreationParameters::encode):
1116         (WebKit::WebPageCreationParameters::decode):
1117         Encode and decode canRunBeforeUnloadConfirmPanel, as well as canRunModal, which wasn't
1118         being encoded/decoded.
1119
1120         * Shared/WebPageCreationParameters.h:
1121         Add canRunBeforeUnloadConfirmPanel.
1122
1123         * UIProcess/WebPageProxy.cpp:
1124         (WebKit::WebPageProxy::initializeUIClient):
1125         Send SetCanRunBeforeUnloadConfirmPanel and SetCanRunModal messages.
1126
1127         (WebKit::WebPageProxy::creationParameters):
1128         Initialize parameters.canRunBeforeUnloadConfirmPanel.
1129
1130         * UIProcess/WebPageProxy.messages.in:
1131         Remove CanRunBeforeUnloadConfirmPanel message.
1132
1133         * UIProcess/WebUIClient.cpp:
1134         (WebKit::WebUIClient::canRunBeforeUnloadConfirmPanel):
1135         * UIProcess/WebUIClient.h:
1136         Make canRunBeforeUnloadConfirmPanel const.
1137
1138         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
1139         (WebKit::WebChromeClient::canRunBeforeUnloadConfirmPanel):
1140         Ask the web page instead of sending a synchronous message.
1141
1142         * WebProcess/WebPage/WebPage.cpp:
1143         (WebKit::WebPage::WebPage):
1144         Initialize m_canRunBeforeUnloadConfirmPanel.
1145
1146         * WebProcess/WebPage/WebPage.h:
1147         (WebKit::WebPage::canRunBeforeUnloadConfirmPanel):
1148         (WebKit::WebPage::setCanRunBeforeUnloadConfirmPanel):
1149         Add getter and setter for m_canRunBeforeUnloadConfirmPanel.
1150
1151         (WebKit::WebPage::setCanRunModal):
1152         Add setter for m_canRunModal.
1153
1154         * WebProcess/WebPage/WebPage.messages.in:
1155         Add SetCanRunBeforeUnloadConfirmPanel and SetCanRunModal messages.
1156
1157 2011-03-03  Adam Roben  <aroben@apple.com>
1158
1159         Create the CFBundleRef for WebKit.dll on Windows if needed
1160
1161         WebKit part of <http://webkit.org/b/55672> <rdar://problem/9080867> All inspector tests time
1162         out or crash on Windows 7 Release (WebKit2 Tests)
1163
1164         Reviewed by Darin Adler.
1165
1166         * Shared/win/WebKitBundle.cpp: Added.
1167         (WebKit::createWebKitBundle): Returns a pre-existing bundle, if possible, otherwise creates
1168         and returns a new bundle.
1169         (WebKit::webKitBundle): Creates and caches a bundle, and returns it.
1170
1171         * Shared/win/WebKitBundle.h: Added.
1172
1173         * UIProcess/win/WebInspectorProxyWin.cpp:
1174         (WebKit::WebInspectorProxy::inspectorPageURL):
1175         * WebProcess/WebPage/win/WebInspectorWin.cpp:
1176         (WebKit::WebInspector::localizedStringsURL):
1177         Changed to use webKitBundle() to ensure that the bundle has been created.
1178
1179         * win/WebKit2.vcproj: Added new files.
1180
1181 2011-03-03  Peter Kasting  <pkasting@google.com>
1182
1183         Reviewed by James Robinson.
1184
1185         Drop redundant "Windows; " from the Windows-specific User Agent string.
1186         https://bugs.webkit.org/show_bug.cgi?id=54567
1187
1188         * UIProcess/win/WebPageProxyWin.cpp:
1189         (WebKit::WebPageProxy::standardUserAgent):
1190
1191 2011-03-02  Sheriff Bot  <webkit.review.bot@gmail.com>
1192
1193         Unreviewed, rolling out r80188.
1194         http://trac.webkit.org/changeset/80188
1195         https://bugs.webkit.org/show_bug.cgi?id=55647
1196
1197         Broke the WebKit API tests. (Requested by xenon on #webkit).
1198
1199         * UIProcess/API/C/WKPage.cpp:
1200         (WKPageRunJavaScriptInMainFrame):
1201         (callRunJavaScriptBlockAndRelease):
1202         * UIProcess/API/C/WKPage.h:
1203         * UIProcess/WebPageProxy.cpp:
1204         (WebKit::WebPageProxy::close):
1205         (WebKit::WebPageProxy::runJavaScriptInMainFrame):
1206         (WebKit::WebPageProxy::processDidCrash):
1207         * UIProcess/WebPageProxy.h:
1208         * UIProcess/WebPageProxy.messages.in:
1209         * WebProcess/WebPage/WebPage.cpp:
1210         (WebKit::WebPage::runJavaScriptInMainFrame):
1211
1212 2011-03-02  Jeff Miller  <jeffm@apple.com>
1213
1214         Reviewed by Darin Adler.
1215
1216         Rename WebKit::WebPage::validateMenuItem() to validateCommand()
1217         https://bugs.webkit.org/show_bug.cgi?id=55636
1218         
1219         Since this method can validate more than menu items, validateCommand() is a better name.  Also rename various messages and WebKit::WebPageProxy::didValidateMenuItem() to didValidateCommand().
1220
1221         * UIProcess/API/mac/WKView.mm:
1222         (-[WKView validateUserInterfaceItem:]): Call validateCommand() instead of validateMenuItem().
1223         * UIProcess/WebPageProxy.cpp:
1224         (WebKit::WebPageProxy::validateCommand): Renamed from validateMenuItem().
1225         (WebKit::WebPageProxy::didValidateCommand): Renamed from didValidateMenuItem().
1226         * UIProcess/WebPageProxy.h:
1227         * UIProcess/WebPageProxy.messages.in: Renamed DidValidateMenuItem to DidValidateCommand.
1228         * WebProcess/WebPage/WebPage.cpp:
1229         (WebKit::WebPage::validateCommand): Renamed from validateMenuItem().
1230         * WebProcess/WebPage/WebPage.h:
1231         * WebProcess/WebPage/WebPage.messages.in: Renamed ValidateMenuItem to ValidateCommand.
1232
1233 2011-03-02  Anders Carlsson  <andersca@apple.com>
1234
1235         Reviewed by Sam Weinig.
1236
1237         WKPageSetMemoryCacheClientCallsEnabled doesn't persist if web process crashes
1238         https://bugs.webkit.org/show_bug.cgi?id=55635
1239
1240         * Shared/WebPageCreationParameters.cpp:
1241         (WebKit::WebPageCreationParameters::encode):
1242         (WebKit::WebPageCreationParameters::decode):
1243         Encode and decode areMemoryCacheClientCallsEnabled.
1244
1245         * Shared/WebPageCreationParameters.h:
1246         Add areMemoryCacheClientCallsEnabled member variable.
1247
1248         * UIProcess/WebPageProxy.cpp:
1249         (WebKit::WebPageProxy::WebPageProxy):
1250         Initialize m_areMemoryCacheClientCallsEnabled.
1251
1252         (WebKit::WebPageProxy::setMemoryCacheClientCallsEnabled):
1253         Update m_areMemoryCacheClientCallsEnabled. Send a message if necessary.
1254
1255         (WebKit::WebPageProxy::creationParameters):
1256         Set areMemoryCacheClientCallsEnabled.
1257
1258         * WebProcess/WebPage/WebPage.cpp:
1259         (WebKit::WebPage::WebPage):
1260         Call WebPage::setMemoryCacheMessagesEnabled.
1261
1262 2011-03-02  Timothy Hatcher  <timothy@apple.com>
1263
1264         Make the runJavaScriptInMainFrame callback send a WKSerializedScriptValueRef.
1265
1266         https://webkit.org/b/55623
1267
1268         Reviewed by Darin Adler.
1269
1270         * UIProcess/API/C/WKPage.cpp:
1271         (WKPageRunJavaScriptInMainFrame): Use ScriptValueCallback.
1272         (callRunJavaScriptBlockAndRelease): Use WKSerializedScriptValueRef.
1273         * UIProcess/API/C/WKPage.h: Use WKSerializedScriptValueRef.
1274         * UIProcess/WebPageProxy.cpp:
1275         (WebKit::WebPageProxy::close): Call invalidateCallbackMap for m_scriptValueCallbacks.
1276         (WebKit::WebPageProxy::runJavaScriptInMainFrame): Take a ScriptValueCallback.
1277         (WebKit::WebPageProxy::scriptValueCallback): Added. Create a WebSerializedScriptValue
1278         from the DataReference before calling the callback.
1279         (WebKit::WebPageProxy::processDidCrash): Call invalidateCallbackMap for m_scriptValueCallbacks.
1280         * UIProcess/WebPageProxy.h: Added ScriptValueCallback and m_scriptValueCallbacks.
1281         * UIProcess/WebPageProxy.messages.in: Added ScriptValueCallback.
1282         * WebProcess/WebPage/WebPage.cpp:
1283         (WebKit::WebPage::runJavaScriptInMainFrame): Create a DataReference from a WebCore::SerializedScriptValue.
1284         And use ScriptValueCallback to send the message back.
1285
1286 2011-03-02  Jessie Berlin  <jberlin@apple.com>
1287
1288         Reviewed by Adam Roben.
1289
1290         WebKit2: Use CFNetwork Sessions API.
1291         https://bugs.webkit.org/show_bug.cgi?id=55435
1292
1293         Add the ability to create a Private Browsing Storage Session.
1294
1295         * Shared/WebProcessCreationParameters.cpp:
1296         (WebKit::WebProcessCreationParameters::encode):
1297         Encode the UI Process bundle identifier.
1298         (WebKit::WebProcessCreationParameters::decode):
1299         Decode the UI Process bundle identifier.
1300         * Shared/WebProcessCreationParameters.h:
1301
1302         * UIProcess/mac/WebContextMac.mm:
1303         (WebKit::WebContext::platformInitializeWebProcess):
1304         Grab the bundle identifier and use it to set the WebProcessCreationParameter.
1305         * UIProcess/win/WebContextWin.cpp:
1306         (WebKit::WebContext::platformInitializeWebProcess):
1307         Ditto.
1308
1309         * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
1310         (InitWebCoreSystemInterface):
1311         Support using the wkCreatePrivateStorageSession WKSI in WebCore.
1312
1313         * WebProcess/WebProcess.cpp:
1314         (WebKit::WebProcess::initializeWebProcess):
1315         Set the base for the Private Browsing Storage Session identifier to be the bundle identifier
1316         from the UI Process so that WebKit1 would create a Private Browsing Storage Session with the
1317         same identifier as WebKit2.
1318
1319 2011-03-01  Brian Weinstein  <bweinstein@apple.com>
1320
1321         Reviewed by Adam Roben.
1322
1323         Part of WebKit2: Need a way to send notifications to client when cookies change
1324         https://bugs.webkit.org/show_bug.cgi?id=55427
1325         <rdar://problem/9056027>
1326
1327         * WebProcess/Cookies/WebCookieManager.cpp:
1328         (WebKit::WebCookieManager::dispatchDidModifyCookies): Add a stub with a FIXME to send a 
1329             message to the UI process.
1330
1331         * WebProcess/Cookies/WebCookieManager.h:
1332         * WebProcess/WebCoreSupport/WebPlatformStrategies.cpp:
1333         (WebKit::WebPlatformStrategies::createCookiesStrategy):
1334         (WebKit::WebPlatformStrategies::notifyCookiesChanged): Call WebCookieManager::dispatchDidModifyCookies.
1335         * WebProcess/WebCoreSupport/WebPlatformStrategies.h:
1336
1337 2011-03-02  Andras Becsi  <abecsi@webkit.org>
1338
1339         Reviewed by Laszlo Gombos.
1340
1341         [Qt][WK2] generate-forwarding-headers.pl should generate paths with framework names
1342         https://bugs.webkit.org/show_bug.cgi?id=55478
1343
1344         On case insensitive systems the generated forwarding headers cause build problems.
1345
1346         * Scripts/generate-forwarding-headers.pl: The generated header should
1347         also contain the framework name.
1348
1349 2011-03-01  Jeff Miller  <jeffm@apple.com>
1350
1351         Reviewed by Darin Adler.
1352
1353         Expose some selection state fields in WKPage
1354         https://bugs.webkit.org/show_bug.cgi?id=55541
1355         
1356         Added WKPageCanDelete(), WKPageHasSelectedRange(), and WKPageIsContentEditable() so we can enable some
1357         Edit menu items properly on Windows when using WebKit2.
1358
1359         * UIProcess/API/C/WKPage.cpp:
1360         (WKPageCanDelete): Added.
1361         (WKPageHasSelectedRange): Added.
1362         (WKPageIsContentEditable): Added.
1363         * UIProcess/API/C/WKPage.h: Added new functions.
1364         * UIProcess/WebPageProxy.h:
1365         (WebKit::WebPageProxy::canDelete): Added.
1366         (WebKit::WebPageProxy::hasSelectedRange): Added.
1367         (WebKit::WebPageProxy::isContentEditable): Added.
1368
1369 2011-03-01  Mark Rowe  <mrowe@apple.com>
1370
1371         Hide the typeinfo name symbols for std::exception and std::bad_alloc too.
1372
1373         * Configurations/Base.xcconfig:
1374
1375 2011-03-01  Mark Rowe  <mrowe@apple.com>
1376
1377         Reviewed by Sam Weinig.
1378
1379         Add verification scripts to WebKit2 project and fix the issues they reveal.
1380
1381         * Configurations/Base.xcconfig: Add linker flags to prevent C++ standard
1382         library functions from being exported as weak externals.
1383         * Configurations/WebKit2.xcconfig: Inherit linker flags from the project level.
1384         * Shared/WebContextMenuItem.cpp:
1385         (WebKit::WebContextMenuItem::separatorItem): Use DEFINE_STATIC_LOCAL.
1386         * UIProcess/WebPageGroup.cpp:
1387         (WebKit::webPageGroupMap): Ditto.
1388         * WebKit2.xcodeproj/project.pbxproj: Don't copy .in files in to the framework.
1389         Run verification scripts at the appropriate times.
1390         * WebProcess/WebCoreSupport/WebEditorClient.cpp:
1391         (WebKit::WebEditorClient::didBeginEditing): Use DEFINE_STATIC_LOCAL.
1392         (WebKit::WebEditorClient::respondToChangedContents): Ditto.
1393         (WebKit::WebEditorClient::respondToChangedSelection): Ditto.
1394         (WebKit::WebEditorClient::didEndEditing): Ditto.
1395         * WebProcess/WebPage/WebBackForwardListProxy.cpp:
1396         (WebKit::idToHistoryItemMap): Ditto.
1397         (WebKit::historyItemToIDMap): Ditto.
1398
1399 2011-03-01  Joseph Pecoraro  <joepeck@webkit.org>
1400
1401         Unreviewed. Roll out r80068 and r80073 due to breaking WebKit2 Qt port.
1402
1403         * UIProcess/API/qt/qwkpage.cpp:
1404         (QWKPage::viewportAttributesForSize):
1405
1406 2011-03-01  Joseph Pecoraro  <joepeck@webkit.org>
1407
1408         Unreviewed, missed updating a call to WebCore::computeViewportAttributes
1409         who's prototype changed.
1410
1411         Viewport Warning/Error Messages Are Now Inaccurate
1412         https://bugs.webkit.org/show_bug.cgi?id=53707
1413
1414         * UIProcess/API/qt/qwkpage.cpp:
1415         (QWKPage::viewportAttributesForSize): pass in a value for the document argument.
1416
1417 2011-03-01  Anders Carlsson  <andersca@apple.com>
1418
1419         Reviewed by Sam Weinig.
1420
1421         WKPluginSiteDataManagerClearAllSiteData is not working
1422         https://bugs.webkit.org/show_bug.cgi?id=55528
1423         <rdar://problem/9071823>
1424
1425         * Shared/Plugins/Netscape/NetscapePluginModule.cpp:
1426         (WebKit::NetscapePluginModule::tryGetSitesWithData):
1427         Remove version checks, checking that the function pointer is not null is enough.
1428
1429         (WebKit::NetscapePluginModule::tryClearSiteData):
1430         Remove version checks, checking that the function pointer is not null is enough.
1431         Also, correctly convert a null String to a null CString.
1432
1433 2011-03-01  Adam Roben  <aroben@apple.com>
1434
1435         Incorporate a review comment I missed in r80051
1436
1437         * Shared/Plugins/Netscape/NetscapePluginModule.cpp: Clarified error message.
1438
1439 2011-03-01  Adam Roben  <aroben@apple.com>
1440
1441         Make the PLUGIN_ARCHITECTURE() macro work with MSVC
1442
1443         Fixes <http://webkit.org/b/55513> <rdar://problem/9069189> REGRESSION (r79925): Lots of
1444         plugins tests crashing in NetscapePlugin::initialize on Windows
1445
1446         Reviewed by Anders Carlsson.
1447
1448         * Shared/Plugins/Netscape/NetscapePluginModule.cpp: Added a compile-time check to make sure
1449         PLUGIN_ARCHITECTURE() is defined for some platform.
1450
1451         * config.h: Removed the parentheses from the use of "defined" in the PLUGIN_ARCHITECTURE()
1452         macro. This matches PLATFORM(), OS(), etc., and makes the macro work on Windows. Also
1453         replaced the nonsense OS(WIN) with OS(WINDOWS).
1454
1455         * win/WebKit2.vcproj: Added config.h for editing convenience. Let VS do its thang.
1456
1457 2011-03-01  Sam Weinig  <sam@webkit.org>
1458
1459         Reviewed by Timothy Hatcher.
1460
1461         WebKit2 needs to be made localizable
1462         https://bugs.webkit.org/show_bug.cgi?id=55483
1463
1464         * PluginProcess/mac/PluginProcessMainMac.mm:
1465         * WebProcess/mac/WebProcessMainMac.mm:
1466         Set the default localization from the passed in parameter.
1467
1468         * UIProcess/Launcher/mac/ProcessLauncherMac.mm:
1469         Add the preferred localization as a parameter when launching processes
1470         so that they can set their localization to match the launching app.
1471
1472         * WebProcess/WebCoreSupport/WebPlatformStrategies.cpp:
1473         Use WebCore's localizedString function on the mac, to actually localize
1474         these strings.
1475
1476         (WebKit::WebPlatformStrategies::imageTitle):
1477         Switch to using replace, instead of concatenation, to give localizers a chance
1478         to rearrange the wording.
1479
1480 2011-03-01  Balazs Kelemen  <kbalazs@webkit.org>
1481
1482         Reviewed by Anders Carlsson.
1483
1484         [Qt][WK2] Plugin initialization
1485         https://bugs.webkit.org/show_bug.cgi?id=48127
1486
1487         Apply the quirks that are necessary for the flash plugin
1488         to not crash on X11.
1489
1490         * Platform/qt/ModuleQt.cpp:
1491         (WebKit::Module::load): Use the ResolveAllSymbols hint as we do in WebCore.
1492         * Shared/Plugins/Netscape/NetscapePluginModule.cpp:
1493         (WebKit::NetscapePluginModule::tryLoad): Call applyX11QuirksBeforeLoad
1494         if PLUGIN_ARCHITECTURE is X11.
1495         * Shared/Plugins/Netscape/NetscapePluginModule.h:
1496         * Shared/Plugins/Netscape/x11/NetscapePluginModuleX11.cpp:
1497         (WebKit::initializeGTK):  The same hack that we do in WebCore.
1498         Call gtk_init because flash don't do it for itself.
1499         (WebKit::NetscapePluginModule::applyX11QuirksBeforeLoad): Added for X11.
1500         Do the hacks that we need to do before calling NP_Initialize on the
1501         flash plugin to save it form crashing.
1502         * Shared/Plugins/PluginQuirks.h: Use PLUGIN_ARCHITECTURE macros.
1503         Added RequiresGTKToolKit quirk for X11.
1504         * WebProcess/Plugins/Netscape/NetscapeBrowserFuncs.cpp:
1505         (WebKit::NPN_GetValue): Handle the RequiresGTKToolKit quirk on X11.
1506         * WebProcess/Plugins/Netscape/NetscapePlugin.h:
1507         (WebKit::NetscapePlugin::quirks): Added getter for the PluginModule's
1508         quirks to be available in NPN_GetValue.
1509
1510 2011-03-01  Adam Roben  <aroben@apple.com>
1511
1512         Convert seconds to milliseconds before calling ::SetTimer
1513
1514         Fixes <http://webkit.org/b/55417> <rdar://problem/9065287> RunLoop::Timer fires 1000x too
1515         early on Windows
1516
1517         Reviewed by Anders Carlsson.
1518
1519         * Platform/win/RunLoopWin.cpp:
1520         (RunLoop::TimerBase::start): Convert the timeout interval to milliseconds, since that's what
1521         ::SetTimer expects.
1522
1523 2011-03-01  Andras Becsi  <abecsi@webkit.org>
1524
1525         Reviewed by Csaba Osztrogonác.
1526
1527         [Qt] Clean up the project files and move common options to WebKit.pri.
1528
1529         * WebKit2.pro: Deduplicate options.
1530
1531 2011-03-01  Juha Savolainen  <juha.savolainen@weego.fi>
1532
1533         Reviewed by Andreas Kling.
1534
1535         [Qt] WebKit2 needs to support font size changing and getting default font size
1536         https://bugs.webkit.org/show_bug.cgi?id=53671
1537
1538         Added new enum for font size type and added methods to set and get default font sizes.
1539
1540         * UIProcess/API/qt/qwkpreferences.cpp:
1541         (QWKPreferences::setFontSize): Added.
1542         (QWKPreferences::fontSize): Added.
1543         * UIProcess/API/qt/qwkpreferences.h:
1544
1545 2011-02-28  Alice Liu  <alice.liu@apple.com>
1546
1547         Reviewed by Adam Roben and Gavin Barraclough.
1548
1549         https://bugs.webkit.org/show_bug.cgi?id=54898
1550         InjectedBundleNodeHandle dies too early in WKBundleHitTestResultGetNodeHandle
1551
1552         * WebProcess/InjectedBundle/API/c/WKBundleHitTestResult.cpp:
1553         (WKBundleHitTestResultCopyNodeHandle): 
1554         Instead of .get(), call .release.leakRef() like other functions that return WKBundleNodeHandleRef.
1555         * WebProcess/InjectedBundle/API/c/WKBundleHitTestResult.h:
1556         Renamed from "get" to "copy", because it leaksRef.
1557
1558 2011-02-28  Alice Liu  <alice.liu@apple.com>
1559
1560         Reviewed by Gavin Barraclough.
1561
1562         https://bugs.webkit.org/show_bug.cgi?id=55442
1563         Webarchives don't contain subframe content
1564
1565         * WebProcess/WebPage/WebPage.cpp:
1566         (WebKit::WebPage::getWebArchiveOfFrame):
1567         Pass the frame's document instead of just the frame, to use a different LegacyWebArchive::create function.
1568
1569 2011-02-28  Benjamin Poulain  <benjamin.poulain@nokia.com>
1570
1571         Reviewed by Kenneth Rohde Christiansen.
1572
1573         [Qt][WK2] Add a way to test the WebKit 2 APIs
1574         https://bugs.webkit.org/show_bug.cgi?id=55408
1575
1576         Add an initial test for the WebKit 2 APIs of Qt.
1577
1578         * UIProcess/API/qt/tests/html/basic_page.html: Added.
1579         * UIProcess/API/qt/tests/qgraphicswkview/qgraphicswkview.pro: Added.
1580         * UIProcess/API/qt/tests/qgraphicswkview/tst_qgraphicswkview.cpp: Added.
1581         (View::View):
1582         (View::resizeEvent):
1583         (tst_QGraphicsWKView::init):
1584         (tst_QGraphicsWKView::cleanup):
1585         (tst_QGraphicsWKView::loadEmptyPage):
1586         * UIProcess/API/qt/tests/tests.pri: Added.
1587         * UIProcess/API/qt/tests/tests.pro: Added.
1588         * UIProcess/API/qt/tests/util.h: Added.
1589         (waitForSignal):
1590
1591 2011-02-28  Anders Carlsson  <andersca@apple.com>
1592
1593         Fix clang build.
1594
1595         * UIProcess/API/mac/FindIndicatorWindow.mm:
1596         * UIProcess/ChunkedUpdateDrawingAreaProxy.cpp:
1597         (WebKit::ChunkedUpdateDrawingAreaProxy::deprecatedUpdate):
1598         (WebKit::ChunkedUpdateDrawingAreaProxy::didReceiveMessage):
1599         * UIProcess/ChunkedUpdateDrawingAreaProxy.h:
1600         * WebProcess/WebPage/ChunkedUpdateDrawingArea.cpp:
1601         (WebKit::ChunkedUpdateDrawingArea::deprecatedResumePainting):
1602         (WebKit::ChunkedUpdateDrawingArea::didReceiveMessage):
1603         * WebProcess/WebPage/ChunkedUpdateDrawingArea.h:
1604
1605 2011-02-28  Dan Bernstein  <mitz@apple.com>
1606
1607         Rubber-stamped by Anders Carlsson.
1608
1609         Do not copy config.h into WebKit2.
1610
1611         * WebKit2.xcodeproj/project.pbxproj:
1612
1613 2011-02-28  Dan Bernstein  <mitz@apple.com>
1614
1615         LLVM Compiler build fix.
1616
1617         * Scripts/webkit2/messages.py:
1618         * UIProcess/WebPageProxy.h:
1619
1620 2011-02-28  Anders Carlsson  <andersca@apple.com>
1621
1622         Reviewed by Dan Bernstein, Sam Weinig, Alexey Proskuryakov and Darin Adler.
1623
1624         Open PDF in Preview doesn't work
1625         https://bugs.webkit.org/show_bug.cgi?id=55400
1626         <rdar://problem/8750353>
1627
1628         * UIProcess/API/mac/PDFViewController.mm:
1629         (-[WKPDFView initWithFrame:PDFViewController:]):
1630         Set the WKPDFView as the delegate of itself.
1631
1632         (-[WKPDFView PDFViewOpenPDFInNativeApplication:]):
1633         Call PDFViewController::openPDFInFinder.
1634
1635         (WebKit::PDFViewController::PDFViewController):
1636         Initialize m_hasWrittenPDFToDisk to false.
1637
1638         (WebKit::PDFViewController::openPDFInFinder):
1639         Write the PDF to disk if needed and then open it using -[NSWorkspace openFile:].
1640         
1641         (WebKit::temporaryPDFDirectoryPath):
1642         Create a directory to put PDFs in.
1643
1644         (WebKit::PDFViewController::pathToPDFOnDisk):
1645         Return a path to a (non-existent) file in the temporary PDF directory.
1646
1647 2011-02-28  Alexey Proskuryakov  <ap@apple.com>
1648
1649         Reviewed by Dan Bernstein.
1650
1651         Frequent crashes in CFURLCache code on Snow Leopard
1652         https://bugs.webkit.org/show_bug.cgi?id=55412
1653         <rdar://problem/9063922>
1654
1655         CString is evil, it has two lengths which can be different - specifically, fileSystemRepresentation()
1656         creates a string with maximum possible buffer size. A path with garbage at the end confused
1657         CFURLCache into corrupting its data structures.
1658
1659         * Shared/WebProcessCreationParameters.h: Added a FIXME about merging Mac and Windows code.
1660         This problem wouldn't have occured if we didn't use CString in the first place.
1661
1662         * UIProcess/mac/WebContextMac.mm: (WebKit::WebContext::platformInitializeWebProcess):
1663         Added an assertion matching Windows behavior (seems likely that NSURLCache also wouldn't
1664         have liked trailing slash).
1665
1666         * UIProcess/win/WebContextWin.cpp: (WebKit::WebContext::platformInitializeWebProcess):
1667         Made slash removal conditional for robustness.
1668
1669         * WebProcess/mac/WebProcessMac.mm: (WebKit::WebProcess::platformInitializeWebProcess):
1670         Use actual string length, not CString::length().
1671
1672 2011-02-28  Balazs Kelemen  <kbalazs@webkit.org>
1673
1674         Reviewed by Anders Carlsson.
1675
1676         [Qt][WK2] Plugin initialization
1677         https://bugs.webkit.org/show_bug.cgi?id=48127
1678
1679         Specialize the way of initializing the plugin for X11.
1680         Introduce PLUGIN_ARCHITECTURE macros to allow code sharing
1681         across platforms.
1682
1683         * Shared/Plugins/Netscape/NetscapePluginModule.cpp:
1684         (WebKit::NetscapePluginModule::tryLoad):
1685         * config.h:
1686
1687 2011-02-28  Sam Weinig  <sam@webkit.org>
1688
1689         Reviewed by Brady Eidson.
1690
1691         WK2 Context Menus - Implement LookUpInDictionary
1692         https://bugs.webkit.org/show_bug.cgi?id=55405
1693
1694         * Shared/DictionaryPopupInfo.cpp:
1695         (WebKit::DictionaryPopupInfo::encode):
1696         (WebKit::DictionaryPopupInfo::decode):
1697         * Shared/DictionaryPopupInfo.h:
1698         Add type to differentiate between HotKey and ContextMenu triggered
1699         dictionary popups. This is necessary since HotKey triggered ones want
1700         to override the style to always be overlay.
1701
1702         * UIProcess/API/mac/PageClientImpl.mm:
1703         (WebKit::PageClientImpl::didPerformDictionaryLookup):
1704         Only force the overlay style for HotKey triggered dictionary lookups.
1705
1706         * WebProcess/WebPage/WebPage.h:
1707         * WebProcess/WebPage/mac/WebPageMac.mm:
1708         (WebKit::WebPage::performDictionaryLookupAtLocation):
1709         (WebKit::WebPage::performDictionaryLookupForRange):
1710         Factor out shared functionality into performDictionaryLookupForRange.
1711
1712         * WebProcess/WebCoreSupport/mac/WebContextMenuClientMac.mm:
1713         (WebKit::WebContextMenuClient::lookUpInDictionary):
1714         Get selected range and call newly factored out performDictionaryLookupForRange.
1715
1716 2011-02-28  Anders Carlsson  <andersca@apple.com>
1717
1718         Reviewed by Dan Bernstein.
1719
1720         PDFViewController should hold a reference to the PDF data
1721         https://bugs.webkit.org/show_bug.cgi?id=55394
1722
1723         * UIProcess/API/mac/PDFViewController.h:
1724         * UIProcess/API/mac/PDFViewController.mm:
1725         (WebKit::PDFViewController::setPDFDocumentData):
1726
1727 2011-02-28  Sam Weinig  <sam@webkit.org>
1728
1729         Reviewed by Darin Adler.
1730
1731         Size of text in popup menu doesn't match size of text in <select> itself in WebKit2
1732         https://bugs.webkit.org/show_bug.cgi?id=48234
1733
1734         * Shared/TextInfo.cpp: Removed.
1735         * Shared/TextInfo.h: Removed.
1736         Replace this with the more appropriately DictionaryPopupInfo.
1737
1738         * Shared/DictionaryPopupInfo.cpp: Copied from Source/WebKit2/Shared/TextInfo.cpp.
1739         (WebKit::DictionaryPopupInfo::encode):
1740         (WebKit::DictionaryPopupInfo::decode):
1741         * Shared/DictionaryPopupInfo.h: Copied from Source/WebKit2/Shared/TextInfo.h.
1742         (WebKit::DictionaryPopupInfo::DictionaryPopupInfo):
1743         Replace individual font related fields with FontInfo.
1744
1745         * Shared/FontInfo.cpp: Added.
1746         (WebKit::FontInfo::FontInfo):
1747         (WebKit::FontInfo::encode):
1748         (WebKit::FontInfo::decode):
1749         * Shared/FontInfo.h: Added.
1750         Add class to encapsulate passing a font description over the wire.
1751
1752         * Shared/PlatformPopupMenuData.cpp:
1753         (WebKit::PlatformPopupMenuData::encode):
1754         (WebKit::PlatformPopupMenuData::decode):
1755         * Shared/PlatformPopupMenuData.h:
1756         Add FontInfo as extra data for the Mac.
1757
1758         * UIProcess/API/mac/PageClientImpl.h:
1759         * UIProcess/API/mac/PageClientImpl.mm:
1760         (WebKit::PageClientImpl::didPerformDictionaryLookup):
1761         * UIProcess/PageClient.h:
1762         Add scaleFactor and use it to construct a font at the right size.
1763
1764         * UIProcess/WebPageProxy.cpp:
1765         (WebKit::WebPageProxy::showPopupMenu):
1766         (WebKit::WebPageProxy::didPerformDictionaryLookup):
1767         * UIProcess/WebPageProxy.h:
1768         * UIProcess/WebPageProxy.messages.in:
1769         * UIProcess/WebPopupMenuProxy.h:
1770         * UIProcess/mac/WebPopupMenuProxyMac.h:
1771         (WebKit::WebPopupMenuProxyMac::create):
1772         * UIProcess/mac/WebPopupMenuProxyMac.mm:
1773         (WebKit::WebPopupMenuProxyMac::WebPopupMenuProxyMac):
1774         (WebKit::WebPopupMenuProxyMac::populate):
1775         (WebKit::WebPopupMenuProxyMac::showPopupMenu):
1776         * UIProcess/qt/WebPopupMenuProxyQt.cpp:
1777         (WebKit::WebPopupMenuProxyQt::showPopupMenu):
1778         * UIProcess/qt/WebPopupMenuProxyQt.h:
1779         * UIProcess/win/WebPopupMenuProxyWin.cpp:
1780         (WebKit::WebPopupMenuProxyWin::showPopupMenu):
1781         * UIProcess/win/WebPopupMenuProxyWin.h:
1782         * WebProcess/WebCoreSupport/mac/WebPopupMenuMac.mm:
1783         (WebKit::WebPopupMenu::setUpPlatformData):
1784         * WebProcess/WebPage/mac/WebPageMac.mm:
1785         (WebKit::WebPage::performDictionaryLookupAtLocation):
1786         Pass scale factor through and rename TextInfo -> DictionaryPopupInfo.
1787
1788         * WebKit2.pro:
1789         * WebKit2.xcodeproj/project.pbxproj:
1790         * win/WebKit2.vcproj:
1791         Add new files.
1792
1793 2011-02-28  Adam Roben  <aroben@apple.com>
1794
1795         One more rename as a followup to r79868
1796
1797         Rubber-stamped by Anders Carlsson.
1798
1799         * UIProcess/DrawingAreaProxyImpl.cpp:
1800         * UIProcess/DrawingAreaProxyImpl.h:
1801         Rename stateDidChange to backingStoreStateDidChange.
1802
1803 2011-02-28  Adam Roben  <aroben@apple.com>
1804
1805         Rename DrawingArea[Proxy]Impl's "state ID" concept to "backing store state ID"
1806
1807         Rubber-stamped (and suggested) by Anders Carlsson.
1808
1809         * UIProcess/DrawingAreaProxy.h:
1810         * UIProcess/DrawingAreaProxy.messages.in:
1811         * UIProcess/DrawingAreaProxyImpl.cpp:
1812         * UIProcess/DrawingAreaProxyImpl.h:
1813         * WebProcess/WebPage/DrawingArea.h:
1814         * WebProcess/WebPage/DrawingArea.messages.in:
1815         * WebProcess/WebPage/DrawingAreaImpl.cpp:
1816         * WebProcess/WebPage/DrawingAreaImpl.h:
1817         Perform the rename.
1818
1819 2011-02-28  Adam Roben  <aroben@apple.com>
1820
1821         Decouple state changes from sending of UpdateState messages in DrawingAreaProxyImpl
1822
1823         The new DrawingAreaProxyImpl::stateDidChange function should be called whenever
1824         DrawingAreaProxyImpl's state changes in a way that will require allocating a new backing
1825         store. (Currently, this is just when the size changes.) This function will sometimes (but
1826         not always, as when we're waiting for a DidUpdateState message) send an UpdateState message
1827         to the web process. This means it's now possible for the state IDs sent in consecutive
1828         UpdateState messages to increase by more than one, but that's OK.
1829
1830         This should cause no change in behavior.
1831
1832         Fixes <http://webkit.org/b/55382> DrawingAreaProxyImpl's state ID should be updated whenever
1833         its state changes, not just when we send an UpdateState message
1834
1835         Reviewed by Anders Carlsson.
1836
1837         * UIProcess/DrawingAreaProxyImpl.cpp:
1838         (WebKit::DrawingAreaProxyImpl::DrawingAreaProxyImpl): Updated for rename.
1839         (WebKit::DrawingAreaProxyImpl::sizeDidChange): Changed to call stateDidChange.
1840         (WebKit::DrawingAreaProxyImpl::didUpdateState): Updated for rename, and changed to call
1841         sendUpdateState whenever our state has changed for any reason since the last UpdateState
1842         message was sent.
1843         (WebKit::DrawingAreaProxyImpl::stateDidChange): Added. Increments m_nextStateID and calls
1844         through to sendUpdateState.
1845         (WebKit::DrawingAreaProxyImpl::sendUpdateState): Updated for rename, moved incrementing of
1846         the state ID we send to the web process from here to stateDidChange, and added an assertion.
1847
1848         * UIProcess/DrawingAreaProxyImpl.h: Renamed m_requestedStateID to m_nextStateID, and updated
1849         the comment explaining its meaning.
1850
1851 2011-02-28  Adam Roben  <aroben@apple.com>
1852
1853         Pass the right dirty rect to Plugin::paint
1854
1855         A typo in r79040 broke this. Much of this patch is just support for testing the fix.
1856
1857         Fixes <http://webkit.org/b/55365> <rdar://problem/9031089> REGRESSION (r79040): WebKit2:
1858         Large portions of pages with plugins paint black
1859
1860         Reviewed by Anders Carlsson.
1861
1862         * WebProcess/Plugins/PluginView.cpp:
1863         (WebKit::PluginView::paint): Pass the dirty rect we calculated earlier to Plugin::paint,
1864         rather than just passing along the dirty rect that was passed into this function. This is
1865         the bug fix.
1866
1867         * WebProcess/InjectedBundle/API/c/WKBundlePage.cpp:
1868         (WKBundlePageForceRepaint):
1869         * WebProcess/InjectedBundle/API/c/WKBundlePagePrivate.h:
1870         Added new SPI. Just calls through to WebPage::forceRepaintWithoutCallback.
1871
1872         * WebProcess/WebPage/WebPage.cpp:
1873         (WebKit::WebPage::forceRepaintWithoutCallback): Moved code to force a repaint here...
1874         (WebKit::WebPage::forceRepaint): ...from here.
1875
1876         * WebProcess/WebPage/WebPage.h: Added forceRepaintWithoutCallback.
1877
1878 2011-02-27  Sam Weinig  <sam@webkit.org>
1879
1880         Reviewed by Dan Bernstein.
1881
1882         Force dictionary popup to use overlay type
1883         <rdar://problem/9052483>
1884         https://bugs.webkit.org/show_bug.cgi?id=55337
1885
1886         * UIProcess/API/mac/PageClientImpl.mm:
1887         (WebKit::PageClientImpl::didPerformDictionaryLookup): As this is only
1888         used for the hot key version of the dictionary popup, force the overlay
1889         style.
1890
1891 2011-02-27  Benjamin Poulain  <benjamin.poulain@nokia.com>
1892
1893         Reviewed by Kenneth Rohde Christiansen.
1894
1895         [Qt] [WK2] QGraphicsWKView::showContextMenu() should be public
1896         https://bugs.webkit.org/show_bug.cgi?id=55330
1897
1898         Move QGraphicsWKView::showContextMenu() to the public API. Add documentation
1899         on its use.
1900
1901         * UIProcess/API/qt/qgraphicswkview.cpp:
1902         * UIProcess/API/qt/qgraphicswkview.h:
1903
1904 2011-02-27  Alejandro G. Castro  <alex@igalia.com>
1905
1906         Unreviewed, fixed GTK compilation after r79806.
1907
1908         * UIProcess/gtk/WebView.cpp:
1909         (WebKit::WebView::didFinishLoadingDataForCustomRepresentation):
1910         * UIProcess/gtk/WebView.h:
1911
1912 2011-02-26  Anders Carlsson  <andersca@apple.com>
1913
1914         Reviewed by Dan Bernstein.
1915
1916         Asynchronous response to FramePolicyListener is not finishing the load
1917         https://bugs.webkit.org/show_bug.cgi?id=55305
1918         <rdar://problem/9044356>
1919
1920         Always initialize the receivedPolicyAction reply parameter.
1921
1922         * UIProcess/WebPageProxy.cpp:
1923         (WebKit::WebPageProxy::decidePolicyForNavigationAction):
1924         (WebKit::WebPageProxy::decidePolicyForMIMEType):
1925
1926 2011-02-26  Anders Carlsson  <andersca@apple.com>
1927
1928         Reviewed by Sam Weinig.
1929
1930         DidFinishLoadingDataForCustomRepresentation should pass along the suggested filename
1931         https://bugs.webkit.org/show_bug.cgi?id=55304
1932
1933         * UIProcess/API/mac/PDFViewController.h:
1934         * UIProcess/API/mac/PDFViewController.mm:
1935         (WebKit::PDFViewController::setPDFDocumentData):
1936         * UIProcess/API/mac/PageClientImpl.h:
1937         * UIProcess/API/mac/PageClientImpl.mm:
1938         (WebKit::PageClientImpl::didFinishLoadingDataForCustomRepresentation):
1939         * UIProcess/API/mac/WKView.mm:
1940         (-[WKView _didFinishLoadingDataForCustomRepresentationWithSuggestedFilename:dataReference:CoreIPC::]):
1941         * UIProcess/API/mac/WKViewInternal.h:
1942         * UIProcess/API/qt/qwkpage.cpp:
1943         (QWKPagePrivate::didFinishLoadingDataForCustomRepresentation):
1944         * UIProcess/API/qt/qwkpage_p.h:
1945         * UIProcess/PageClient.h:
1946         * UIProcess/WebPageProxy.cpp:
1947         (WebKit::WebPageProxy::didFinishLoadingDataForCustomRepresentation):
1948         * UIProcess/WebPageProxy.h:
1949         * UIProcess/WebPageProxy.messages.in:
1950         * UIProcess/win/WebView.cpp:
1951         (WebKit::WebView::didFinishLoadingDataForCustomRepresentation):
1952         * UIProcess/win/WebView.h:
1953         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
1954         (WebKit::WebFrameLoaderClient::finishedLoading):
1955
1956 2011-02-26  Anders Carlsson  <andersca@apple.com>
1957
1958         Reviewed by Oliver Hunt.
1959
1960         DrawingArea should not be reference counted
1961         https://bugs.webkit.org/show_bug.cgi?id=55284
1962
1963         * Shared/DrawingAreaInfo.h:
1964         * Shared/WebPageCreationParameters.cpp:
1965         (WebKit::WebPageCreationParameters::encode):
1966         (WebKit::WebPageCreationParameters::decode):
1967         * Shared/WebPageCreationParameters.h:
1968         * UIProcess/ChunkedUpdateDrawingAreaProxy.cpp:
1969         (WebKit::ChunkedUpdateDrawingAreaProxy::ChunkedUpdateDrawingAreaProxy):
1970         (WebKit::ChunkedUpdateDrawingAreaProxy::setPageIsVisible):
1971         (WebKit::ChunkedUpdateDrawingAreaProxy::update):
1972         (WebKit::ChunkedUpdateDrawingAreaProxy::sendSetSize):
1973         * UIProcess/ChunkedUpdateDrawingAreaProxy.h:
1974         * UIProcess/DrawingAreaProxy.cpp:
1975         (WebKit::DrawingAreaProxy::DrawingAreaProxy):
1976         * UIProcess/DrawingAreaProxy.h:
1977         (WebKit::DrawingAreaProxy::type):
1978         * UIProcess/DrawingAreaProxyImpl.cpp:
1979         (WebKit::DrawingAreaProxyImpl::DrawingAreaProxyImpl):
1980         * UIProcess/DrawingAreaProxyImpl.h:
1981         * UIProcess/TiledDrawingAreaProxy.cpp:
1982         (WebKit::TiledDrawingAreaProxy::TiledDrawingAreaProxy):
1983         * UIProcess/TiledDrawingAreaProxy.h:
1984         * UIProcess/WebPageProxy.cpp:
1985         (WebKit::WebPageProxy::didReceiveSyncMessage):
1986         (WebKit::WebPageProxy::creationParameters):
1987         * WebProcess/Geolocation/GeolocationPermissionRequestManager.cpp:
1988         * WebProcess/WebPage/ChunkedUpdateDrawingArea.cpp:
1989         (WebKit::ChunkedUpdateDrawingArea::ChunkedUpdateDrawingArea):
1990         (WebKit::ChunkedUpdateDrawingArea::display):
1991         (WebKit::ChunkedUpdateDrawingArea::setSize):
1992         (WebKit::ChunkedUpdateDrawingArea::didReceiveMessage):
1993         * WebProcess/WebPage/ChunkedUpdateDrawingArea.h:
1994         * WebProcess/WebPage/DrawingArea.cpp:
1995         (WebKit::DrawingArea::create):
1996         (WebKit::DrawingArea::DrawingArea):
1997         * WebProcess/WebPage/DrawingArea.h:
1998         * WebProcess/WebPage/DrawingAreaImpl.cpp:
1999         (WebKit::DrawingAreaImpl::create):
2000         (WebKit::DrawingAreaImpl::DrawingAreaImpl):
2001         * WebProcess/WebPage/DrawingAreaImpl.h:
2002         * WebProcess/WebPage/TiledDrawingArea.cpp:
2003         (WebKit::TiledDrawingArea::TiledDrawingArea):
2004         * WebProcess/WebPage/TiledDrawingArea.h:
2005         * WebProcess/WebPage/WebPage.cpp:
2006         (WebKit::WebPage::drawRect):
2007         * WebProcess/WebPage/WebPage.h:
2008
2009 2011-02-26  Vsevolod Vlasov  <vsevik@chromium.org>
2010
2011         Reviewed by Pavel Feldman.
2012
2013         DumpRenderTree should reset frame opener between tests.
2014         https://bugs.webkit.org/show_bug.cgi?id=54874
2015
2016         Added clearOpener method to WKBundleWebFramePrivate.
2017
2018         * WebProcess/InjectedBundle/API/c/WKBundleFrame.cpp:
2019         (WKBundleFrameClearOpener):
2020         * WebProcess/InjectedBundle/API/c/WKBundleFramePrivate.h:
2021
2022 2011-02-26  Yael Aharon  <yael.aharon@nokia.com>
2023
2024         Reviewed by Andreas Kling.
2025
2026         [Qt] Fix the focus in MiniBrowser.
2027         https://bugs.webkit.org/show_bug.cgi?id=55288
2028
2029         Implement basic functionality for focus in QWKPagePrivate.
2030
2031         * UIProcess/API/qt/qwkpage.cpp:
2032         (QWKPagePrivate::isViewWindowActive):
2033         (QWKPagePrivate::isViewFocused):
2034         (QWKPagePrivate::isViewVisible):
2035
2036 2011-02-26  Sheriff Bot  <webkit.review.bot@gmail.com>
2037
2038         Unreviewed, rolling out r79764.
2039         http://trac.webkit.org/changeset/79764
2040         https://bugs.webkit.org/show_bug.cgi?id=55295
2041
2042         "broke Chromium builds" (Requested by rniwa on #webkit).
2043
2044         * WebProcess/InjectedBundle/API/c/WKBundleFrame.cpp:
2045         * WebProcess/InjectedBundle/API/c/WKBundleFramePrivate.h:
2046
2047 2011-02-26  Vsevolod Vlasov  <vsevik@chromium.org>
2048
2049         Reviewed by Pavel Feldman.
2050
2051         DumpRenderTree should reset frame opener between tests.
2052         https://bugs.webkit.org/show_bug.cgi?id=54874
2053
2054         Added clearOpener method to WKBundleWebFramePrivate.
2055
2056         * WebProcess/InjectedBundle/API/c/WKBundleFrame.cpp:
2057         (WKBundleFrameClearOpener):
2058         * WebProcess/InjectedBundle/API/c/WKBundleFramePrivate.h:
2059
2060 2011-02-25  Anders Carlsson  <andersca@apple.com>
2061
2062         Reviewed by Darin Adler.
2063
2064         Plug-in process crashes when using GuardMalloc
2065         https://bugs.webkit.org/show_bug.cgi?id=55279
2066         <rdar://problem/9044618>
2067
2068         Update m_environmentPointer after copying the environment variables.
2069         
2070         * UIProcess/Launcher/mac/ProcessLauncherMac.mm:
2071         (WebKit::EnvironmentVariables::copyEnvironmentVariables):
2072
2073 2011-02-25  Darin Adler  <darin@apple.com>
2074
2075         * UIProcess/Launcher/mac/ProcessLauncherMac.mm:
2076         (WebKit::ProcessLauncher::launchProcess): Fixed backwards logic from last change.
2077
2078 2011-02-25  Darin Adler  <darin@apple.com>
2079
2080         Reviewed by Mark Rowe.
2081
2082         * UIProcess/Launcher/mac/ProcessLauncherMac.mm:
2083         (WebKit::ProcessLauncher::launchProcess): Fixed performance problem in production
2084         builds by only setting DYLD_FRAMEWORK_PATH in engineering configurations.
2085
2086 2011-02-25  Darin Adler  <darin@apple.com>
2087
2088         Reviewed by Anders Carlsson.
2089
2090         <rdar://problem/8036034> WebKit2 should work even if DYLD_FRAMEWORK_PATH is not set
2091
2092         * UIProcess/Launcher/mac/ProcessLauncherMac.mm:
2093         (WebKit::EnvironmentVariables::~EnvironmentVariables): Use fastFree, not delete, on
2094         the strings here because they are allocated with fastMalloc, not new.
2095         (WebKit::EnvironmentVariables::set): Use const more.
2096         (WebKit::EnvironmentVariables::get): Ditto.
2097         (WebKit::EnvironmentVariables::appendValue): Ditto.
2098         (WebKit::EnvironmentVariables::valueIfVariableHasName): Ditto. Also fix mistake
2099         where this would match if the name matched only a prefix of the environment variable's
2100         name. We want to match the whole name, so we need to use memcmp, not strncmp.
2101         (WebKit::EnvironmentVariables::createStringForVariable): Use const more.
2102         (WebKit::ProcessLauncher::launchProcess): Use clearer name, frameworkExecutablePath,
2103         for what was called bundlePath before. Append the frameworks path to DYLD_FRAMEWORK_PATH,
2104         ensuring we can pick up other frameworks from the same directory in the web process.
2105         Use a const_cast instead of a C-style cast.
2106
2107 2011-02-25  Chris Fleizach  <cfleizach@apple.com>
2108
2109         Reviewed by Anders Carlsson.
2110
2111         AX: WK2: AXApplication not returning the AXFocusedUIElement within the web area
2112         https://bugs.webkit.org/show_bug.cgi?id=55277
2113
2114         * UIProcess/API/mac/WKView.mm:
2115         (-[WKView accessibilityFocusedUIElement]):
2116
2117 2011-02-25  Alexey Proskuryakov  <ap@apple.com>
2118
2119         Reviewed by Anders Carlsson.
2120
2121         https://bugs.webkit.org/show_bug.cgi?id=55276
2122         WebPage::close() accesses "this" after it is destroyed.
2123
2124         This was making many tests crash with GuardMalloc.
2125
2126         * WebProcess/WebPage/WebPage.cpp: (WebKit::WebPage::close): Access "this" before it can be
2127         destroyed, not after.
2128
2129 2011-02-25  Balazs Kelemen  <kbalazs@webkit.org>
2130
2131         Unreviewed.
2132         Add missing sources to WebKit2API.pri.
2133
2134         * WebKit2API.pri:
2135
2136 2011-02-25  Anders Carlsson  <andersca@apple.com>
2137
2138         Reviewed by Darin Adler.
2139
2140         A WKView without a window will cause CG errors in the console
2141         https://bugs.webkit.org/show_bug.cgi?id=55264
2142         <rdar://problem/9044281>
2143
2144         Check that the window has a valid window number before trying to get its graphics context.
2145
2146         * UIProcess/API/mac/PageClientImpl.mm:
2147         (WebKit::PageClientImpl::containingWindowGraphicsContext):
2148
2149 2011-02-25  Brian Weinstein  <bweinstein@apple.com>
2150
2151         Reviewed by Brady Eidson and looked over by Jessie Berlin.
2152
2153         WebKit2: Need a way to manage cookies from the web process
2154         https://bugs.webkit.org/show_bug.cgi?id=55086
2155         
2156         Call through to WebCore::CookieJar in our WebCookieManager functions.
2157
2158         * WebProcess/Cookies/WebCookieManager.cpp:
2159         (WebKit::WebCookieManager::getHostnamesWithCookies):
2160         (WebKit::WebCookieManager::deleteCookiesForHostname):
2161         (WebKit::WebCookieManager::deleteAllCookies):
2162
2163 2011-02-25  Anders Carlsson  <andersca@apple.com>
2164
2165         Reviewed by Sam Weinig.
2166
2167         Option-clicking on links doesn't download them due to sandbox violation
2168         https://bugs.webkit.org/show_bug.cgi?id=55250
2169         <rdar://problem/9018359>
2170
2171         The change to make DecidePolicyForNavigationAction sync didn't handle the case when the
2172         decided policy was "Download". Fix this by passing along the download ID back to the web process.
2173
2174         * Platform/CoreIPC/HandleMessage.h:
2175         (CoreIPC::callMemberFunction):
2176         Add new overload.
2177
2178         * UIProcess/WebPageProxy.cpp:
2179         (WebKit::WebPageProxy::WebPageProxy):
2180         Initialize m_syncNavigationActionPolicyDownloadID.
2181
2182         (WebKit::WebPageProxy::receivedPolicyDecision):
2183         Set m_syncNavigationActionPolicyDownloadID to the download ID.
2184
2185         (WebKit::WebPageProxy::decidePolicyForNavigationAction):
2186         Return the m_syncNavigationActionPolicyDownloadID.
2187
2188         * UIProcess/WebPageProxy.h:
2189         * UIProcess/WebPageProxy.messages.in:
2190         Add a DownloadID reply parameter.
2191
2192         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
2193         (WebKit::WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
2194         Don't pass a zero download ID to didReceivePolicyDecision.
2195
2196 2011-02-25  Amruth Raj  <amruthraj@motorola.com> and Ravi Phaneendra Kasibhatla  <ravi.kasibhatla@motorola.com> and Alejandro G. Castro  <alex@igalia.com>
2197
2198         Reviewed by Martin Robinson.
2199
2200         [GTK] Implement WebContext and NativeKeyboardEvent classes for WebKit2
2201         https://bugs.webkit.org/show_bug.cgi?id=48510
2202
2203         * GNUmakefile.am:
2204         * Shared/NativeWebKeyboardEvent.h: Added the GTK event attribute
2205         and constructors, in our case we need it because we use a pointer
2206         and copy the event.
2207         (WebKit::NativeWebKeyboardEvent::nativeEvent):
2208         * Shared/gtk/NativeWebKeyboardEventGtk.cpp: Added.
2209         (WebKit::NativeWebKeyboardEvent::NativeWebKeyboardEvent): We need
2210         to copy the event in the constructor to avoid two references to
2211         the same event.
2212         * Shared/gtk/WebEventFactory.cpp: Changed the prototype of the
2213         functions to add const, we need it for the NativeWebKeyboardEvent
2214         constructor.
2215         (WebKit::modifiersForEvent):
2216         (WebKit::WebEventFactory::createWebKeyboardEvent):
2217         * UIProcess/gtk/WebContextGtk.cpp: Added. Stubbed implementation
2218         for GTK port. Yet to implement.
2219         (WebKit::WebContext::applicationCacheDirectory):
2220         (WebKit::WebContext::platformInitializeWebProcess):
2221         (WebKit::WebContext::platformDefaultDatabaseDirectory):
2222         * UIProcess/gtk/WebView.cpp:
2223         (WebKit::WebView::handleKeyboardEvent):
2224
2225 2011-02-25  Anders Carlsson  <andersca@apple.com>
2226
2227         Reviewed by Sam Weinig.
2228
2229         Get rid of more old accelerated compositing code
2230         https://bugs.webkit.org/show_bug.cgi?id=55235
2231
2232         * Shared/CoreIPCSupport/DrawingAreaProxyMessageKinds.h:
2233         * UIProcess/ChunkedUpdateDrawingAreaProxy.h:
2234         * UIProcess/DrawingAreaProxy.h:
2235         * UIProcess/DrawingAreaProxyImpl.cpp:
2236         * UIProcess/DrawingAreaProxyImpl.h:
2237         * WebProcess/WebPage/ChunkedUpdateDrawingArea.h:
2238         * WebProcess/WebPage/DrawingArea.h:
2239         * WebProcess/WebPage/DrawingAreaImpl.cpp:
2240         * WebProcess/WebPage/DrawingAreaImpl.h:
2241
2242 2011-02-25  Andras Becsi  <abecsi@webkit.org>
2243
2244         Reviewed by Csaba Osztrogonác.
2245
2246         [Qt] Make the WebKit2 build system less confusing for non-Qt developers
2247         https://bugs.webkit.org/show_bug.cgi?id=55213
2248
2249         * WebKit2API.pri: Added.
2250
2251 2011-02-25  Amruth Raj  <amruthraj@motorola.com> and Ravi Phaneendra Kasibhatla  <ravi.kasibhatla@motorola.com> and Alejandro G. Castro  <alex@igalia.com>
2252
2253         Reviewed by Martin Robinson.
2254
2255         [GTK] Implement WebView and WebKitWebView classes for WebKit2
2256         https://bugs.webkit.org/show_bug.cgi?id=48509
2257
2258         * GNUmakefile.am:
2259         * UIProcess/API/C/gtk/WKView.cpp:
2260         * UIProcess/API/C/gtk/WKView.h: Removed gdkrectangle from
2261         constructor.
2262         * UIProcess/gtk/WebViewWidget.cpp: Added. The GObject interface
2263         for WebView. The GObject is the GtkWidget handle which is used by
2264         WebView class for GTK port.
2265         * UIProcess/gtk/WebViewWidget.h: Added. The GObject interface
2266         declarations for GtkWidget handle for GTK port.
2267         * UIProcess/gtk/WebView.cpp: Added. The native GtkWidget handle
2268         for GTK port which is associated with each WKViewRef.
2269         * UIProcess/gtk/WebView.h: Added. Class which implements the
2270         PageClient interface. It is a wrapper over the native GtkWidget
2271         handle associated with each WKViewRef for GTK port.
2272
2273 2011-02-25  Alejandro G. Castro  <alex@igalia.com>
2274
2275         Fix GTK compilation after r79654.
2276
2277         * GNUmakefile.am:
2278
2279 2011-02-24  Brian Weinstein  <bweinstein@apple.com>
2280
2281         Qt build fix.
2282
2283         * WebKit2.pri:
2284
2285 2011-02-24  Brady Eidson  <beidson@apple.com>
2286
2287         Reviewed by Sam Weinig and looked over by Brian Weinstein.
2288
2289         Part of <rdar://problem/8762095> and https://bugs.webkit.org/show_bug.cgi?id=55172
2290         Need WebKit2 API to view/manage origins with LocalStorage.
2291
2292         Project file stuff:
2293         * GNUmakefile.am:
2294         * WebKit2.pri:
2295         * WebKit2.pro:
2296         * WebKit2.xcodeproj/project.pbxproj:
2297         * win/WebKit2.vcproj:
2298         * win/WebKit2Common.vsprops:
2299         * win/WebKit2Generated.make:
2300
2301         WK2 derived sources and API stuff:
2302         * DerivedSources.make:
2303         * DerivedSources.pro:
2304         * Platform/CoreIPC/MessageID.h:
2305         * Shared/API/c/WKBase.h:
2306         * Shared/APIObject.h:
2307         * UIProcess/API/C/WKAPICast.h:
2308
2309         Add an KeyValueStorageManager to the context and invalidate it at the appropriate times:
2310         * UIProcess/WebContext.cpp:
2311         (WebKit::WebContext::WebContext):
2312         (WebKit::WebContext::~WebContext):
2313         (WebKit::WebContext::disconnectProcess):
2314         (WebKit::WebContext::didReceiveMessage):
2315         * UIProcess/WebContext.h:
2316         (WebKit::WebContext::keyValueStorageManagerProxy):
2317
2318         Add API to get the KeyValueStorageManager for a context:
2319         * UIProcess/API/C/WKContext.cpp:
2320         (WKContextGetKeyValueStorageManager):
2321         * UIProcess/API/C/WKContext.h:
2322
2323         Route messages to the right place:
2324         * UIProcess/WebProcessProxy.cpp:
2325         (WebKit::WebProcessProxy::didReceiveMessage):
2326         * WebProcess/WebProcess.cpp:
2327         (WebKit::WebProcess::didReceiveMessage):
2328
2329         Add the API object, which wraps to WebKeyValueStorageManagerProxy:
2330         * UIProcess/API/C/WKKeyValueStorageManager.cpp: Added.
2331         (WKKeyValueStorageManagerGetTypeID):
2332         (WKKeyValueStorageManagerGetKeyValueStorageOrigins):
2333         (WKKeyValueStorageManagerDeleteEntriesForOrigin):
2334         (WKKeyValueStorageManagerDeleteAllEntries):
2335         * UIProcess/API/C/WKKeyValueStorageManager.h: Added.
2336
2337         The UIProcess implementation of the manager to send messages to the WebProcess and pipe a callback back up to the client:
2338         * UIProcess/WebKeyValueStorageManagerProxy.cpp: Added.
2339         (WebKit::WebKeyValueStorageManagerProxy::create):
2340         (WebKit::WebKeyValueStorageManagerProxy::WebKeyValueStorageManagerProxy):
2341         (WebKit::WebKeyValueStorageManagerProxy::~WebKeyValueStorageManagerProxy):
2342         (WebKit::WebKeyValueStorageManagerProxy::invalidate):
2343         (WebKit::WebKeyValueStorageManagerProxy::didReceiveMessage):
2344         (WebKit::WebKeyValueStorageManagerProxy::getKeyValueStorageOrigins):
2345         (WebKit::WebKeyValueStorageManagerProxy::didGetKeyValueStorageOrigins):
2346         (WebKit::WebKeyValueStorageManagerProxy::deleteEntriesForOrigin):
2347         (WebKit::WebKeyValueStorageManagerProxy::deleteAllEntries):
2348         * UIProcess/WebKeyValueStorageManagerProxy.h: Added.
2349         (WebKit::WebKeyValueStorageManagerProxy::clearContext):
2350         (WebKit::WebKeyValueStorageManagerProxy::type):
2351         * UIProcess/WebKeyValueStorageManagerProxy.messages.in: Added.
2352
2353         The WebProcess implementation to response to UIProcess messages and actually do the dirty-work in WebCore:
2354         * WebProcess/KeyValueStorage: Added.
2355         * WebProcess/KeyValueStorage/WebKeyValueStorageManager.cpp: Added.
2356         (WebKit::WebKeyValueStorageManager::shared):
2357         (WebKit::WebKeyValueStorageManager::WebKeyValueStorageManager):
2358         (WebKit::WebKeyValueStorageManager::didReceiveMessage):
2359         (WebKit::WebKeyValueStorageManager::getKeyValueStorageOrigins):
2360         (WebKit::WebKeyValueStorageManager::deleteEntriesForOrigin):
2361         (WebKit::WebKeyValueStorageManager::deleteAllEntries):
2362         * WebProcess/KeyValueStorage/WebKeyValueStorageManager.h: Added.
2363         * WebProcess/KeyValueStorage/WebKeyValueStorageManager.messages.in: Added.
2364
2365 2011-02-24  Darin Adler  <darin@apple.com>
2366
2367         Reviewed by Anders Carlsson.
2368
2369         WebKit2: Image-based cursors do not work
2370         https://bugs.webkit.org/show_bug.cgi?id=55184
2371
2372         * Shared/ShareableBitmap.h: Added releaseData function
2373         declaration. This is only defined for CG, but we can declare
2374         it without defining it on non-CG platforms without causing problems.
2375
2376         * Shared/WebCoreArgumentCoders.cpp: Added.
2377         (CoreIPC::encodeImage): Added. For use in the Cursor argument coder.
2378         (CoreIPC::decodeImage): Ditto.
2379
2380         * Shared/WebCoreArgumentCoders.h: Added code to the Cursor encoder
2381         and decoder to handle image-based cursors, using the new encodeImage
2382         and decodeImage functions.
2383
2384         * Shared/cg/ShareableBitmapCG.cpp:
2385         (WebKit::ShareableBitmap::releaseData): Added.
2386         (WebKit::ShareableBitmap::createGraphicsContext): Use
2387         CGBitmapContextCreateWithData instead of CGBitmapContextCreate,
2388         to guarantee we outlast the CGBitmapContext we create.
2389         (WebKit::ShareableBitmap::paint): Got rid of unnneeded local variable.
2390
2391         * Shared/cg/WebCoreArgumentCodersCG.cpp: Added.
2392         (CoreIPC::createImage): Added. For use by CoreIPC::decodeImage.
2393
2394         * WebKit2.xcodeproj/project.pbxproj: Added WebCoreArgumentCoders.cpp
2395         and WebCoreArgumentCodersCG.cpp.
2396         * win/WebKit2.vcproj: Ditto.
2397
2398 2011-02-24  Anders Carlsson  <andersca@apple.com>
2399
2400         Reviewed by Dan Bernstein.
2401
2402         Crash when trying to send a sync message on an invalid connection
2403         https://bugs.webkit.org/show_bug.cgi?id=55190
2404         <rdar://problem/9035806>
2405
2406         * Platform/CoreIPC/Connection.cpp:
2407         (CoreIPC::Connection::sendSyncMessage):
2408         Don't try to call a client function if isValid() returns false since the client
2409         will be null in that case.
2410
2411 2011-02-24  Anders Carlsson  <andersca@apple.com>
2412
2413         Reviewed by Dan Bernstein.
2414
2415         Remove the layer backed drawing area
2416         https://bugs.webkit.org/show_bug.cgi?id=55174
2417
2418         * GNUmakefile.am:
2419         * Shared/DrawingAreaInfo.h:
2420         * UIProcess/API/mac/WKView.mm:
2421         * UIProcess/LayerBackedDrawingAreaProxy.cpp: Removed.
2422         * UIProcess/LayerBackedDrawingAreaProxy.h: Removed.
2423         * UIProcess/mac/LayerBackedDrawingAreaProxyMac.mm: Removed.
2424         * UIProcess/win/LayerBackedDrawingAreaProxyWin.cpp: Removed.
2425         * UIProcess/win/WebView.cpp:
2426         * WebKit2.xcodeproj/project.pbxproj:
2427         * WebProcess/WebPage/DrawingArea.cpp:
2428         (WebKit::DrawingArea::create):
2429         * WebProcess/WebPage/LayerBackedDrawingArea.cpp: Removed.
2430         * WebProcess/WebPage/LayerBackedDrawingArea.h: Removed.
2431         * WebProcess/WebPage/mac/LayerBackedDrawingAreaMac.mm: Removed.
2432         * WebProcess/WebPage/win/LayerBackedDrawingAreaWin.cpp: Removed.
2433         * win/WebKit2.vcproj:
2434
2435 2011-02-24  Mike Thole  <mthole@apple.com>
2436
2437         Reviewed by Sam Weinig.
2438
2439         WK2: Add ability to get document node for a WKBundleNodeHandle
2440         https://bugs.webkit.org/post_bug.cgi
2441
2442         * WebProcess/InjectedBundle/API/c/WKBundleNodeHandle.cpp:
2443         (WKBundleNodeHandleCopyDocument):
2444         * WebProcess/InjectedBundle/API/c/WKBundleNodeHandlePrivate.h:
2445         * WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.cpp:
2446         (WebKit::InjectedBundleNodeHandle::document):
2447         * WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.h:
2448
2449 2011-02-24  Brady Eidson  <beidson@apple.com>
2450
2451         Reviewed by Adam Roben and looked at by Brian Weinstein.
2452
2453         https://bugs.webkit.org/show_bug.cgi?id=55165
2454         Can call CF API with a null CFArray in WebResourceCacheManager
2455
2456         * WebProcess/ResourceCache/WebResourceCacheManager.cpp:
2457         (WebKit::WebResourceCacheManager::getCacheOrigins): cfURLCacheHostNames() can return a null CFArrayRef, 
2458           so the call to CFArrayGetCount must be null checked.
2459
2460 2011-02-24  Anders Carlsson  <andersca@apple.com>
2461
2462         Reviewed by Simon Fraser.
2463
2464         ASSERTION FAILED: !isInAcceleratedCompositingMode() when entering accelerated compositing early
2465         https://bugs.webkit.org/show_bug.cgi?id=55162
2466         <rdar://problem/9048523>
2467
2468         * WebProcess/WebPage/DrawingAreaImpl.cpp:
2469         (WebKit::DrawingAreaImpl::updateState):
2470         Call setShouldNotifyAfterNextScheduledLayerFlush(false) so the web process process won't send an
2471         EnterAcceleratedCompositingMode message.
2472
2473         (WebKit::DrawingAreaImpl::enterAcceleratedCompositingMode):
2474         setShouldNotifyAfterNextScheduledLayerFlush now takes a boolean.
2475
2476         * WebProcess/WebPage/LayerTreeHost.h:
2477         * WebProcess/WebPage/mac/LayerTreeHostMac.h:
2478         * WebProcess/WebPage/mac/LayerTreeHostMac.mm:
2479         (WebKit::LayerTreeHostMac::setShouldNotifyAfterNextScheduledLayerFlush):
2480         Make this take a boolean.
2481
2482 2011-02-24  Peter Kasting  <pkasting@google.com>
2483
2484         Reviewed by Eric Seidel.
2485
2486         Drop the "U; " encryption level from the User Agent string.
2487         https://bugs.webkit.org/show_bug.cgi?id=54566
2488
2489         * UIProcess/gtk/WebPageProxyGtk.cpp:
2490         (WebKit::WebPageProxy::standardUserAgent):
2491         * UIProcess/mac/WebPageProxyMac.mm:
2492         (WebKit::WebPageProxy::standardUserAgent):
2493         * UIProcess/qt/WebPageProxyQt.cpp:
2494         (WebKit::WebPageProxy::standardUserAgent):
2495         * UIProcess/win/WebPageProxyWin.cpp:
2496         (WebKit::WebPageProxy::standardUserAgent):
2497
2498 2011-02-24  Andrew Wilson  <atwilson@chromium.org>
2499
2500         Unreviewed, rolling out r79570.
2501         http://trac.webkit.org/changeset/79570
2502         https://bugs.webkit.org/show_bug.cgi?id=54874
2503
2504         Breaks chromium build because glue/mocks/mock_web_frame.h/cc
2505         was not updated
2506
2507         * WebProcess/InjectedBundle/API/c/WKBundleFrame.cpp:
2508         * WebProcess/InjectedBundle/API/c/WKBundleFramePrivate.h:
2509
2510 2011-02-23  Brian Weinstein  <bweinstein@apple.com>
2511
2512         Reviewed by Adam Roben and looked over by Jessie Berlin.
2513
2514         Part of WebKit2: Need a way to manage cookies from the web process
2515         https://bugs.webkit.org/show_bug.cgi?id=55086
2516         
2517         This patch adds the plumbing and classes that are needed to manage cookies from the web process.
2518         The functions that the API calls are currently stubs, but will be implemented in a follow-up patch.
2519
2520         Project file changes.
2521         * DerivedSources.make:
2522         * DerivedSources.pro:
2523         * GNUmakefile.am:
2524         * WebKit2.pri:
2525         * WebKit2.pro:
2526         * WebKit2.xcodeproj/project.pbxproj:
2527         * win/WebKit2.vcproj:
2528         * win/WebKit2Common.vsprops:
2529         * win/WebKit2Generated.make:
2530
2531         Add some needed plumbing for WebCookieManager{Proxy}.
2532         * Platform/CoreIPC/MessageID.h:
2533         * Shared/API/c/WKBase.h:
2534         * Shared/APIObject.h:
2535         * UIProcess/API/C/WKAPICast.h:
2536
2537         * UIProcess/API/C/WKContext.cpp:
2538         (WKContextGetCookieManager): Gets the cookie manager proxy.
2539         * UIProcess/API/C/WKContext.h:
2540         * UIProcess/API/C/WKCookieManager.cpp: Added.
2541         (WKCookieManagerGetTypeID):
2542         (WKCookieManagerGetHostnamesWithCookies): Calls through to WebCookieManagerProxy.
2543         (WKCookieManagerDeleteCookiesForHostname): Ditto.
2544         (WKCookieManagerDeleteAllCookies): Ditto.
2545         * UIProcess/API/C/WKCookieManager.h: Added.
2546
2547         * UIProcess/WebProcessProxy.cpp:
2548         (WebKit::WebProcessProxy::didReceiveMessage): Add a case for the cookie manager.
2549         * UIProcess/WebContext.cpp:
2550         (WebKit::WebContext::WebContext): Initialize the cookie manager.
2551         (WebKit::WebContext::~WebContext): Invalidate the cookie manager.
2552         (WebKit::WebContext::disconnectProcess): Ditto.
2553         (WebKit::WebContext::didReceiveMessage): Add a case for the cookie manager.
2554         * UIProcess/WebContext.h:
2555         (WebKit::WebContext::cookieManagerProxy): Returns the cookie manager.
2556         * WebProcess/WebProcess.cpp:
2557         (WebKit::WebProcess::didReceiveMessage): Add a case for the cookie manager.
2558
2559         * UIProcess/WebCookieManagerProxy.cpp: Added.
2560         (WebKit::WebCookieManagerProxy::create):
2561         (WebKit::WebCookieManagerProxy::WebCookieManagerProxy):
2562         (WebKit::WebCookieManagerProxy::~WebCookieManagerProxy):
2563         (WebKit::WebCookieManagerProxy::invalidate):
2564         (WebKit::WebCookieManagerProxy::didReceiveMessage): 
2565         (WebKit::WebCookieManagerProxy::getHostnamesWithCookies): Call through to the web process to get hostnames with cookies.
2566         (WebKit::WebCookieManagerProxy::didGetHostnamesWithCookies): Call the callback we were passed in getHostnamesWithCookies.
2567         (WebKit::WebCookieManagerProxy::deleteCookiesForHostname): Call through to the web process to delete cookies
2568             for the origin.
2569         (WebKit::WebCookieManagerProxy::deleteAllCookies): Call through to the web process to delete all cookies.
2570         * UIProcess/WebCookieManagerProxy.h: Added.
2571         (WebKit::WebCookieManagerProxy::clearContext):
2572         (WebKit::WebCookieManagerProxy::type):
2573         * UIProcess/WebCookieManagerProxy.messages.in: Added.
2574
2575         * WebProcess/Cookies: Added.
2576         * WebProcess/Cookies/WebCookieManager.cpp: Added.
2577         (WebKit::WebCookieManager::shared):
2578         (WebKit::WebCookieManager::WebCookieManager):
2579         (WebKit::WebCookieManager::didReceiveMessage): Call through to didReceiveWebCookieManagerMessage.
2580         (WebKit::WebCookieManager::getHostnamesWithCookies): Build an array from a HashSet (that isn't filled yet), and 
2581             convert that HashSet to a Vector to send to the UI process.
2582         (WebKit::WebCookieManager::deleteCookiesForHostname): Added a stub.
2583         (WebKit::WebCookieManager::deleteAllCookies): Ditto.
2584         * WebProcess/Cookies/WebCookieManager.h: Added.
2585         * WebProcess/Cookies/WebCookieManager.messages.in: Added.
2586
2587 2011-02-24   Amruth Raj  <amruthraj@motorola.com> and Ravi Phaneendra Kasibhatla  <ravi.kasibhatla@motorola.com> and Alejandro G. Castro  <alex@igalia.com>
2588
2589         Reviewed by Martin Robinson.
2590
2591         [GTK] Implement WebEventFactory, WebErrors classes for WebKit2
2592         https://bugs.webkit.org/show_bug.cgi?id=48510
2593
2594         * GNUmakefile.am:
2595         * Shared/gtk/WebEventFactory.cpp: Added. implementation for
2596         WebMouseEvent, WebWheelEvent, WebKeyboardEvent.
2597         * Shared/gtk/WebEventFactory.h: Added.
2598         * WebProcess/WebCoreSupport/gtk/WebErrorsGtk.cpp: Added. Stubbed
2599         implementation for GTK port.
2600
2601 2011-02-24  Vsevolod Vlasov  <vsevik@chromium.org>
2602
2603         Reviewed by Alexey Proskuryakov.
2604
2605         DumpRenderTree should reset frame opener between tests.
2606         https://bugs.webkit.org/show_bug.cgi?id=54874
2607
2608         Added clearOpener method to WKBundleWebFramePrivate.
2609
2610         * WebProcess/InjectedBundle/API/c/WKBundleFrame.cpp:
2611         (WKBundleFrameClearOpener):
2612         * WebProcess/InjectedBundle/API/c/WKBundleFramePrivate.h:
2613
2614 2011-02-24  Benjamin Poulain  <benjamin.poulain@nokia.com>
2615
2616         Reviewed by Eric Seidel.
2617
2618         Support building WebKit with Python 3
2619         https://bugs.webkit.org/show_bug.cgi?id=55038
2620
2621         Update the generator scripts to support Python 3.
2622
2623         * Scripts/generate-message-receiver.py: print is a function in Python 3, write the output to
2624         sys.stdout to be compatible with Python 2 and 3.
2625         * Scripts/generate-messages-header.py:
2626         * Scripts/webkit2/messages.py: dist.iteritems does not exist in Python 3, fallback
2627           to dict.items which is common to Python 2 and 3.
2628
2629 2011-02-24  Andras Becsi  <abecsi@webkit.org>
2630
2631         Reviewed by Laszlo Gombos.
2632
2633         [Qt] MinGW build fails to link
2634         https://bugs.webkit.org/show_bug.cgi?id=55050
2635
2636         Prepend the libraries of subcomponents instead of appending them
2637         to fix the library order according to the dependency of the libraries
2638
2639         * WebKit2.pri:
2640
2641 2011-02-24  Andras Becsi  <abecsi@webkit.org>
2642
2643         Reviewed by Csaba Osztrogonác.
2644
2645         [Qt] REGRESSION(69304): WKNativeEvent.h forwarding header is always regenerated
2646         https://bugs.webkit.org/show_bug.cgi?id=47589
2647
2648         In case of file name clashes only generate forwarding header for the current platform.
2649
2650         * Scripts/generate-forwarding-headers.pl:
2651
2652 2011-02-23  Anders Carlsson  <andersca@apple.com>
2653
2654         Reviewed by Sam Weinig.
2655
2656         Remove some of the old accelerated compositing code
2657         https://bugs.webkit.org/show_bug.cgi?id=55084
2658
2659         * UIProcess/API/mac/PageClientImpl.h:
2660         * UIProcess/API/mac/PageClientImpl.mm:
2661         (WebKit::PageClientImpl::exitAcceleratedCompositingMode):
2662         * UIProcess/API/mac/WKView.mm:
2663         * UIProcess/API/mac/WKViewInternal.h:
2664         * UIProcess/API/qt/qwkpage_p.h:
2665         * UIProcess/PageClient.h:
2666         * UIProcess/WebPageProxy.cpp:
2667         (WebKit::WebPageProxy::exitAcceleratedCompositingMode):
2668         * UIProcess/WebPageProxy.h:
2669         * UIProcess/WebPageProxy.messages.in:
2670         * UIProcess/mac/LayerBackedDrawingAreaProxyMac.mm:
2671         (WebKit::LayerBackedDrawingAreaProxy::attachCompositingContext):
2672         (WebKit::LayerBackedDrawingAreaProxy::detachCompositingContext):
2673         * UIProcess/win/WebView.cpp:
2674         * UIProcess/win/WebView.h:
2675         * WebProcess/WebPage/WebPage.cpp:
2676         (WebKit::WebPage::enterAcceleratedCompositingMode):
2677         (WebKit::WebPage::exitAcceleratedCompositingMode):
2678         * WebProcess/WebPage/WebPage.h:
2679
2680 2011-02-23  Enrica Casucci  <enrica@apple.com>
2681
2682         Reverting an unintentional change that was part of http://trac.webkit.org/changeset/79494.
2683         Unreviewed.
2684
2685         * WebProcess/WebPage/mac/WebPageMac.mm:
2686         (WebKit::WebPage::interceptEditingKeyboardEvent):
2687
2688 2011-02-18  Enrica Casucci  <enrica@apple.com>
2689
2690         Reviewed by Adam Roben.
2691
2692         Mac OS X Services are not available for selected text in WebKit2 windows.
2693         https://bugs.webkit.org/show_bug.cgi?id=54777
2694         <rdar://problem/8666428>
2695         
2696         This patch adds support for Mac OS X Services in WebKit2 windows.
2697         In WKView we now call registerServicesMenuSendTypes providing the
2698         pasteboard types supported by WebKit and we also implement the two
2699         protocol methods required to validate the send type and write the
2700         content to the pasteboard. Unfortunately, AppKit expects the content
2701         to be available in the pasteboard upon return from writeSelectionToPasteboard and
2702         this is the reason why the call to the WebProcess is synchronous.
2703
2704         * Shared/SelectionState.h:
2705         (WebKit::SelectionState::SelectionState): Extended to include
2706         isContentRichlyEditable
2707         * Shared/mac/PasteboardTypes.h:
2708         * Shared/mac/PasteboardTypes.mm:
2709         (WebKit::PasteboardTypes::forSelection): Added.
2710         * UIProcess/API/mac/WKView.mm:
2711         (-[WKView initWithFrame:contextRef:pageGroupRef:]): Added call
2712         to registerServicesMenuSendTypes.
2713         (-[WKView writeSelectionToPasteboard:types:]): Added.
2714         (-[WKView validRequestorForSendType:returnType:]): Added.
2715         * UIProcess/WebPageProxy.cpp:
2716         (WebKit::WebPageProxy::writeSelectionToPasteboard):
2717         * UIProcess/WebPageProxy.h:
2718         * WebProcess/WebCoreSupport/WebEditorClient.cpp:
2719         (WebKit::WebEditorClient::respondToChangedSelection): Modified to
2720         support the new SelectionState value.
2721         * WebProcess/WebPage/WebPage.h:
2722         * WebProcess/WebPage/WebPage.messages.in:
2723         * WebProcess/WebPage/mac/WebPageMac.mm:
2724         (WebKit::WebPage::writeSelectionToPasteboard): Added synchronous
2725         message to write the selected content to the pasteboard.
2726
2727 2011-02-23  Anders Carlsson  <andersca@apple.com>
2728
2729         Reviewed by Sam Weinig.
2730
2731         Add a ShareableBitmap::create overload that takes an existing SharedMemory object
2732         https://bugs.webkit.org/show_bug.cgi?id=55081
2733
2734         * Shared/ShareableBitmap.cpp:
2735         (WebKit::ShareableBitmap::createShareable):
2736         (WebKit::ShareableBitmap::create):
2737         * Shared/ShareableBitmap.h:
2738
2739 2011-02-23  Anders Carlsson  <andersca@apple.com>
2740
2741         Reviewed by Dan Bernstein.
2742
2743         Web Inspector toolbar looks bad in WebKit2
2744         https://bugs.webkit.org/show_bug.cgi?id=55076
2745         <rdar://problem/8866258>
2746
2747         * UIProcess/API/mac/WKView.mm:
2748         (-[WKView mouseDownCanMoveWindow]):
2749         Return NO from mouseDownCanMoveWindow to prevent drags in the (now transparent) inspector WKView
2750         from dragging the window around.
2751
2752         * UIProcess/mac/WebInspectorProxyMac.mm:
2753         (WebKit::WebInspectorProxy::platformCreateInspectorPage):
2754         Call [WKView setDrawsBackground:NO].
2755
2756 2011-02-23  Sam Weinig  <sam@webkit.org>
2757
2758         Reviewed by Anders Carlsson.
2759
2760         Remove WKPageForceRepaintWithInvalidation and instead make WKPageForceRepaint
2761         always dirty the entire page.
2762
2763         * Shared/ForceRepaintFlags.h: Removed.
2764         * UIProcess/API/C/WKPage.cpp:
2765         (WKPageForceRepaint):
2766         * UIProcess/API/C/WKPage.h:
2767         * UIProcess/WebPageProxy.cpp:
2768         (WebKit::WebPageProxy::forceRepaint):
2769         * UIProcess/WebPageProxy.h:
2770         * WebKit2.pro:
2771         * WebKit2.xcodeproj/project.pbxproj:
2772         * WebProcess/WebPage/DrawingAreaImpl.cpp:
2773         (WebKit::DrawingAreaImpl::forceRepaint):
2774         * WebProcess/WebPage/WebPage.cpp:
2775         (WebKit::WebPage::forceRepaint):
2776         * WebProcess/WebPage/WebPage.h:
2777         * WebProcess/WebPage/WebPage.messages.in:
2778         * win/WebKit2.vcproj:
2779
2780 2011-02-23  Anders Carlsson  <andersca@apple.com>
2781
2782         Reviewed by Sam Weinig.
2783
2784         Race condition when creating and destroying pages quickly
2785         https://bugs.webkit.org/show_bug.cgi?id=55061
2786         <rdar://problem/8708435>
2787
2788         When the last page in a web process is closed, the web process would
2789         previously terminate, even if the UI process had created a new page
2790         (the CreateNewPage message just wouldn't have reached the web process yet).
2791
2792         Fix this by adding a ShouldTerminate message that the web process sends when it's
2793         about to terminate. If the UI process has any pending pages, downloads etc. it will
2794         prevent the web process from terminating. Otherwise, it will immmediately disconnect
2795         the WebPageProxy so that creating a page after that will launch a new web process.
2796
2797         * UIProcess/Plugins/WebPluginSiteDataManager.cpp:
2798         (WebKit::WebPluginSiteDataManager::shouldTerminate):
2799         * UIProcess/Plugins/WebPluginSiteDataManager.h:
2800         * UIProcess/WebContext.cpp:
2801         (WebKit::WebContext::shouldTerminate):
2802         (WebKit::WebContext::disconnectProcess):
2803         * UIProcess/WebContext.h:
2804         * UIProcess/WebProcessProxy.cpp:
2805         (WebKit::WebProcessProxy::disconnect):
2806         (WebKit::WebProcessProxy::didReceiveSyncMessage):
2807         (WebKit::WebProcessProxy::didClose):
2808         (WebKit::WebProcessProxy::shouldTerminate):
2809         * UIProcess/WebProcessProxy.h:
2810         * UIProcess/WebProcessProxy.messages.in:
2811         * WebProcess/WebProcess.cpp:
2812         (WebKit::WebProcess::terminateIfPossible):
2813
2814 2011-02-23  Mike Thole  <mthole@apple.com>
2815
2816         Reviewed by Darin Adler.
2817
2818         WKBundleNavigationAction.h should be exposed as a public header
2819         https://bugs.webkit.org/show_bug.cgi?id=55059
2820
2821         * WebKit2.xcodeproj/project.pbxproj:
2822         Changed WKBundleNavigationAction.h from 'project' to 'public'.
2823
2824 2011-02-23  Siddharth Mathur  <siddharth.mathur@nokia.com>
2825
2826         Reviewed by Laszlo Gombos.
2827
2828         [Qt] Make sure Symbian binary UIDs are unique
2829
2830         * WebProcess.pro: Resolve the UID collision with QtTestBrowser.pro
2831         by changing the UID.
2832
2833 2011-02-23  Siddharth Mathur  <siddharth.mathur@nokia.com>
2834
2835         Reviewed by Laszlo Gombos.
2836
2837         [Qt] Fix the Symbian build after r79334
2838         https://bugs.webkit.org/show_bug.cgi?id=55044
2839
2840         * WebKit2.pri: Copy the rules from JavaScriptCore.pri for
2841         defineTest().
2842
2843         Remove addWebKit2LibWholeArchive as it is no longer needed.
2844
2845 2011-02-23  Alejandro G. Castro  <alex@igalia.com>
2846
2847         Unreviewed, fixed GTK WebKit2 compilation after r79366.
2848
2849         * GNUmakefile.am:
2850
2851 2011-02-23  Patrick Gansterer  <paroga@webkit.org>
2852
2853         Reviewed by Darin Adler.
2854
2855         Rename PLATFORM(CF) to USE(CF)
2856         https://bugs.webkit.org/show_bug.cgi?id=53540
2857
2858         * UIProcess/WebBackForwardList.h:
2859         * UIProcess/WebPageProxy.cpp:
2860         * WebProcess/WebCoreSupport/WebPlatformStrategies.cpp:
2861         (WebKit::formatLocalizedString):
2862
2863 2011-02-23  Benjamin Poulain  <benjamin.poulain@nokia.com>
2864
2865         Reviewed by Andreas Kling.
2866
2867         [Qt] [WK2] When the context menu is empty, we should still send the signal QWKPage::showContextMenu()
2868         https://bugs.webkit.org/show_bug.cgi?id=54996
2869
2870         Send the signal QWKPage::showContextMenu() with an empty menu even if the content menu generated
2871         is empty/contain only disabled elements.
2872
2873         * UIProcess/API/qt/qgraphicswkview.cpp:
2874         (QGraphicsWKView::showContextMenu):
2875         * UIProcess/qt/WebContextMenuProxyQt.cpp:
2876         (WebKit::WebContextMenuProxyQt::showContextMenu):
2877
2878 2011-02-22  Dan Bernstein  <mitz@apple.com>
2879
2880         LLVM Compiler build fix.
2881
2882         * Scripts/webkit2/messages.py:
2883         * WebProcess/ApplicationCache/WebApplicationCacheManager.h:
2884
2885 2011-02-22  Laszlo Gombos  <laszlo.1.gombos@nokia.com>
2886
2887         Reviewed by Alexey Proskuryakov.
2888
2889         Drop the language tag part from the User Agent string
2890         https://bugs.webkit.org/show_bug.cgi?id=54560
2891
2892         * UIProcess/gtk/WebPageProxyGtk.cpp:
2893         (WebKit::WebPageProxy::standardUserAgent):
2894
2895         * UIProcess/mac/WebPageProxyMac.mm:
2896         (WebKit::WebPageProxy::standardUserAgent):
2897
2898         * UIProcess/qt/WebPageProxyQt.cpp:
2899         (WebKit::WebPageProxy::standardUserAgent):
2900
2901         * UIProcess/win/WebPageProxyWin.cpp:
2902         (WebKit::WebPageProxy::standardUserAgent): Drop the language tag
2903         part and fix style.
2904
2905 2011-02-22  Sam Weinig  <sam@webkit.org>
2906
2907         Reviewed by Anders Carlsson.
2908
2909         Add WebKit2 API to force a repaint with an invalidation
2910         https://bugs.webkit.org/show_bug.cgi?id=55015
2911
2912         * Shared/ForceRepaintFlags.h: Added.
2913         * UIProcess/API/C/WKPage.cpp:
2914         (WKPageForceRepaint):
2915         (WKPageForceRepaintWithInvalidation):
2916         * UIProcess/API/C/WKPage.h:
2917         Add WKPageForceRepaintWithInvalidation which does the same thing WKPageForceRepaint
2918         but also calls setNeedsDisplay on the entire bounds of the page.
2919
2920         * UIProcess/WebPageProxy.cpp:
2921         (WebKit::WebPageProxy::forceRepaint):
2922         * UIProcess/WebPageProxy.h:
2923         * WebProcess/WebPage/WebPage.cpp:
2924         (WebKit::WebPage::forceRepaint):
2925         * WebProcess/WebPage/WebPage.h:
2926         * WebProcess/WebPage/WebPage.messages.in:
2927         Pipe the flag down to the WebProcess.
2928
2929         * WebKit2.pro:
2930         * WebKit2.xcodeproj/project.pbxproj:
2931         * win/WebKit2.vcproj:
2932         Add ForceRepaintFlags.h.
2933
2934 2011-02-22  Simon Fraser  <simon.fraser@apple.com>
2935
2936         Reviewed by Dan Bernstein.
2937
2938         <rdar://problem/9039670>
2939         
2940         Make sure that we set the accelerateDrawing property on the LayerTreeHosts's
2941         non-composited content layer if the preference is set.
2942
2943         * WebProcess/WebPage/mac/LayerTreeHostMac.mm:
2944         (WebKit::LayerTreeHostMac::LayerTreeHostMac):
2945
2946 2011-02-22  Brady Eidson  <beidson@apple.com>
2947
2948         Fix it Windows-style.
2949
2950         * WebProcess/WebProcess.cpp:
2951         (WebKit::WebProcess::getSitesWithPluginData):
2952         (WebKit::WebProcess::clearPluginSiteData):
2953
2954 2011-02-22  Anders Carlsson  <andersca@apple.com>
2955
2956         Reviewed by Dan Bernstein.
2957
2958         Rename WebProcess::shutdownIfPossible to WebProcess::terminateIfPossible
2959         https://bugs.webkit.org/show_bug.cgi?id=55008
2960
2961         * WebProcess/Downloads/DownloadManager.cpp:
2962         (WebKit::DownloadManager::downloadFinished):
2963         * WebProcess/WebProcess.cpp:
2964         (WebKit::WebProcess::removeWebPage):
2965         (WebKit::WebProcess::terminateIfPossible):
2966         (WebKit::WebProcess::getSitesWithPluginData):
2967         * WebProcess/WebProcess.h:
2968         * WebProcess/gtk/WebProcessGtk.cpp:
2969         (WebKit::WebProcess::platformTerminate):
2970         * WebProcess/mac/WebProcessMac.mm:
2971         (WebKit::WebProcess::platformTerminate):
2972         * WebProcess/qt/WebProcessQt.cpp:
2973         (WebKit::WebProcess::platformTerminate):
2974         * WebProcess/win/WebProcessWin.cpp:
2975         (WebKit::WebProcess::platformTerminate):
2976
2977 2011-02-22  Brady Eidson  <beidson@apple.com>
2978
2979         Windows build-fix attempt.
2980
2981         * win/WebKit2Generated.make:
2982
2983 2011-02-22  Csaba Osztrogonác  <ossy@webkit.org>
2984
2985         Unreviewed.
2986
2987         <rdar://problem/8762042> and  https://bugs.webkit.org/show_bug.cgi?id=54514
2988         API to view and delete Application Cache data by origin.
2989
2990         [Qt][WK2] Buildfix after r79364.
2991
2992         * DerivedSources.pro:
2993         * WebKit2.pri:
2994
2995 2011-02-22  Brady Eidson  <beidson@apple.com>
2996
2997         Reviewed by Anders Carlsson and looked over by Brian Weinstein.
2998
2999         <rdar://problem/8762042> and https://bugs.webkit.org/show_bug.cgi?id=54514
3000         API to view and delete Application Cache data by origin.
3001
3002         I couldn't help myself - I also re-alphabetized WebResourceCacheManager in many places where
3003         it's sorting was wrong due to a last minute name change.
3004
3005         Project file changes:
3006         * GNUmakefile.am:
3007         * win/WebKit2.vcproj:
3008         * win/WebKit2Common.vsprops:
3009         * win/WebKit2Generated.make:
3010         * WebKit2.pro:
3011         * WebKit2.xcodeproj/project.pbxproj:
3012
3013         WK2 build-system and API paperwork:
3014         * DerivedSources.make:
3015         * Platform/CoreIPC/MessageID.h:
3016         * Shared/API/c/WKBase.h:
3017         * Shared/APIObject.h:
3018         * UIProcess/API/C/WKAPICast.h:
3019
3020         Add a helper to perform an ArrayCallback with a Vector of SecurityOriginDatas:
3021         * Shared/SecurityOriginData.cpp:
3022         (WebKit::performAPICallbackWithSecurityOriginDataVector):
3023         * Shared/SecurityOriginData.h:
3024         * UIProcess/WebResourceCacheManagerProxy.cpp:
3025         (WebKit::WebResourceCacheManagerProxy::didGetCacheOrigins): Use performAPICallbackWithSecurityOriginDataVector here.
3026
3027         Add an ApplicationCacheManagerProxy to the context and invalidate it at the appropriate times:
3028         * UIProcess/WebContext.cpp:
3029         (WebKit::WebContext::WebContext):
3030         (WebKit::WebContext::~WebContext):
3031         (WebKit::WebContext::processDidClose):
3032         (WebKit::WebContext::didReceiveMessage): Route messages to the right proxy.
3033         * UIProcess/WebContext.h:
3034         (WebKit::WebContext::applicationCacheManagerProxy):
3035         (WebKit::WebContext::resourceCacheManagerProxy):
3036
3037         Add API to get the ApplicationCacheManager for a context:
3038         * UIProcess/API/C/WKContext.cpp:
3039         (WKContextGetApplicationCacheManager):
3040         (WKContextGetResourceCacheManager):
3041         * UIProcess/API/C/WKContext.h:
3042
3043         Route messages to the right place:
3044         * UIProcess/WebProcessProxy.cpp:
3045         (WebKit::WebProcessProxy::didReceiveMessage):
3046         * WebProcess/WebProcess.cpp:
3047         (WebKit::WebProcess::didReceiveMessage):
3048
3049         Add the API object, which wraps to WebApplicationCacheManagerProxy:
3050         * UIProcess/API/C/WKApplicationCacheManager.cpp: Added.
3051         (WKApplicationCacheManagerGetTypeID):
3052         (WKApplicationCacheManagerGetApplicationCacheOrigins):
3053         (WKApplicationCacheManagerDeleteEntriesForOrigin):
3054         (WKApplicationCacheManagerDeleteAllEntries):
3055         * UIProcess/API/C/WKApplicationCacheManager.h: Added.
3056
3057         The UIProcess implementation of the manager to send messages to the WebProcess and pipe a callback back up to the client:
3058         * UIProcess/WebApplicationCacheManagerProxy.cpp: Added.
3059         (WebKit::WebApplicationCacheManagerProxy::create):
3060         (WebKit::WebApplicationCacheManagerProxy::WebApplicationCacheManagerProxy):
3061         (WebKit::WebApplicationCacheManagerProxy::~WebApplicationCacheManagerProxy):
3062         (WebKit::WebApplicationCacheManagerProxy::invalidate):
3063         (WebKit::WebApplicationCacheManagerProxy::didReceiveMessage):
3064         (WebKit::WebApplicationCacheManagerProxy::getApplicationCacheOrigins):
3065         (WebKit::WebApplicationCacheManagerProxy::didGetApplicationCacheOrigins): Use performAPICallbackWithSecurityOriginDataVector here.
3066         (WebKit::WebApplicationCacheManagerProxy::deleteEntriesForOrigin):
3067         (WebKit::WebApplicationCacheManagerProxy::deleteAllEntries):
3068         * UIProcess/WebApplicationCacheManagerProxy.h: Added.
3069         (WebKit::WebApplicationCacheManagerProxy::clearContext):
3070         (WebKit::WebApplicationCacheManagerProxy::type):
3071         * UIProcess/WebApplicationCacheManagerProxy.messages.in: Added.
3072
3073         The WebProcess implementation to response to UIProcess messages and actually do the dirty-work in WebCore:
3074         * WebProcess/ApplicationCache: Added.
3075         * WebProcess/ApplicationCache/WebApplicationCacheManager.cpp: Added.
3076         (WebKit::WebApplicationCacheManager::shared):
3077         (WebKit::WebApplicationCacheManager::WebApplicationCacheManager):
3078         (WebKit::WebApplicationCacheManager::didReceiveMessage):
3079         (WebKit::WebApplicationCacheManager::getApplicationCacheOrigins):
3080         (WebKit::WebApplicationCacheManager::deleteEntriesForOrigin):
3081         (WebKit::WebApplicationCacheManager::deleteAllEntries):
3082         * WebProcess/ApplicationCache/WebApplicationCacheManager.h: Added.
3083         * WebProcess/ApplicationCache/WebApplicationCacheManager.messages.in: Added.
3084
3085 2011-02-22  Anders Carlsson  <andersca@apple.com>
3086
3087         Reviewed by Sam Weinig.
3088
3089         Get rid of WebProcessManager
3090         https://bugs.webkit.org/show_bug.cgi?id=55001
3091
3092         WebProcessManager had become a stupid map of WebContext > WebProcess relations,
3093         which isn't really useful since the WebContext already knows about its process.
3094
3095         * Shared/WebURLRequest.cpp:
3096         * UIProcess/API/mac/WKView.mm:
3097         * UIProcess/WebContext.cpp:
3098         (WebKit::WebContext::~WebContext):
3099         (WebKit::WebContext::ensureWebProcess):
3100         (WebKit::WebContext::processDidFinishLaunching):
3101         * UIProcess/WebProcessManager.cpp: Removed.
3102         * UIProcess/WebProcessManager.h: Removed.
3103         * UIProcess/WebProcessProxy.cpp:
3104         (WebKit::WebProcessProxy::didClose):
3105         * WebKit2.pro:
3106         * WebKit2.xcodeproj/project.pbxproj:
3107         * win/WebKit2.vcproj:
3108
3109 2011-02-22  Anders Carlsson  <andersca@apple.com>
3110
3111         Reviewed by Darin Adler.
3112
3113         Get rid of WebProcessManager::getAllWebProcessContexts
3114         https://bugs.webkit.org/show_bug.cgi?id=55000
3115
3116         * Shared/WebURLRequest.cpp:
3117         (WebKit::WebURLRequest::setDefaultTimeoutInterval):
3118         Call WebContext::allContexts instead.
3119
3120         * UIProcess/WebContext.cpp:
3121         * UIProcess/WebContext.h:
3122         Add a vector of WebContext objects. Update it when creating and destroying contexts.
3123
3124         * UIProcess/WebProcessManager.cpp:
3125         * UIProcess/WebProcessManager.h:
3126         Remove WebProcessManager::getAllWebProcessContexts.
3127
3128 2011-02-22  Sam Weinig  <sam@webkit.org>
3129
3130         Reviewed by Anders Carlsson.
3131
3132         Re-add early bail out in dispatchDecidePolicyForNavigationAction with prevents
3133         a crash running fast/loader/empty-embed-src-attribute.html. This matches a 
3134         bail out in the default policy delegate in WebKit1.
3135
3136         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
3137         (WebKit::WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
3138
3139 2011-02-22  Anders Carlsson  <andersca@apple.com>
3140
3141         Reviewed by Dan Bernstein.
3142
3143         Grammar correction from Spelling & Grammar window doesn't work
3144         https://bugs.webkit.org/show_bug.cgi?id=54982
3145         <rdar://problem/8940918>
3146
3147         * UIProcess/API/mac/WKView.mm:
3148         (-[WKView isGrammarCheckingEnabled]):
3149         (-[WKView setGrammarCheckingEnabled:]):
3150         Call down to the text checker.
3151
3152         * UIProcess/TextChecker.h:
3153         Add updateSpellingUIWithGrammarString.
3154
3155         * UIProcess/WebPageProxy.cpp:
3156         (WebKit::WebPageProxy::updateSpellingUIWithGrammarString):
3157         Call TextChecker::updateSpellingUIWithGrammarString.
3158
3159         * UIProcess/WebPageProxy.messages.in:
3160         Add UpdateSpellingUIWithGrammarString message.
3161
3162         * UIProcess/gtk/TextCheckerGtk.cpp:
3163         (WebKit::TextChecker::updateSpellingUIWithGrammarString):
3164         * UIProcess/qt/TextCheckerQt.cpp:
3165         (WebKit::TextChecker::updateSpellingUIWithGrammarString):
3166         * UIProcess/win/TextCheckerWin.cpp:
3167         (WebKit::TextChecker::updateSpellingUIWithGrammarString):
3168         Add stubs.
3169
3170         * UIProcess/mac/TextCheckerMac.mm:
3171         (WebKit::TextChecker::updateSpellingUIWithGrammarString):
3172         Update the spelling panel.
3173
3174         * WebProcess/WebCoreSupport/WebEditorClient.cpp:
3175         (WebKit::WebEditorClient::updateSpellingUIWithGrammarString):
3176         Send an UpdateSpellingUIWithGrammarString message to the UI process.
3177
3178 2011-02-22  Balazs Kelemen  <kbalazs@webkit.org>
3179
3180         Reviewed by Anders Carlsson.
3181
3182         notImplemented() should behave identical in WebCore and WebKit2
3183         https://bugs.webkit.org/show_bug.cgi?id=54449
3184
3185         Use NotImplemented.h from WebCore. Initialize logging channels.
3186         Remove the WebKit2 concept of notImplemented().
3187
3188         * Platform/gtk/SharedMemoryGtk.cpp:
3189         * Platform/gtk/WorkQueueGtk.cpp:
3190         * Platform/qt/WorkQueueQt.cpp:
3191         * Platform/win/WorkQueueWin.cpp:
3192         * Shared/NotImplemented.h: Removed.
3193         * Shared/Plugins/NPIdentifierData.cpp:
3194         * Shared/Plugins/NPRemoteObjectMap.cpp:
3195         * Shared/Plugins/NPVariantData.cpp:
3196         * Shared/cairo/ShareableBitmapCairo.cpp:
3197         * Shared/gtk/ShareableBitmapGtk.cpp:
3198         * Shared/gtk/WebCoreArgumentCodersGtk.cpp:
3199         * Shared/qt/WebCoreArgumentCodersQt.cpp:
3200         * Shared/win/LayerTreeContextWin.cpp:
3201         * UIProcess/API/mac/PageClientImpl.mm:
3202         * UIProcess/API/qt/qwkpage.cpp:
3203         * UIProcess/Launcher/gtk/ThreadLauncherGtk.cpp:
3204         * UIProcess/Launcher/qt/ProcessLauncherQt.cpp:
3205         * UIProcess/Plugins/gtk/PluginInfoStoreGtk.cpp:
3206         * UIProcess/WebContext.cpp:
3207         (WebKit::WebContext::WebContext):
3208         * UIProcess/WebInspectorProxy.cpp:
3209         * UIProcess/gtk/TextCheckerGtk.cpp:
3210         * UIProcess/gtk/WebInspectorGtk.cpp:
3211         * UIProcess/gtk/WebPreferencesGtk.cpp:
3212         * UIProcess/qt/TextCheckerQt.cpp:
3213         * UIProcess/qt/WebInspectorProxyQt.cpp:
3214         * UIProcess/win/TextCheckerWin.cpp:
3215         * UIProcess/win/WebContextMenuProxyWin.cpp:
3216         * WebKit2.pro:
3217         * WebKit2.xcodeproj/project.pbxproj:
3218         * WebProcess/Downloads/cf/DownloadCFNet.cpp:
3219         * WebProcess/Downloads/curl/DownloadCurl.cpp:
3220         * WebProcess/Downloads/mac/DownloadMac.mm:
3221         * WebProcess/Downloads/qt/DownloadQt.cpp:
3222         * WebProcess/InjectedBundle/gtk/InjectedBundleGtk.cpp:
3223         * WebProcess/Plugins/Netscape/JSNPMethod.cpp:
3224         * WebProcess/Plugins/Netscape/NPJSObject.cpp:
3225         * WebProcess/Plugins/Netscape/NPRuntimeObjectMap.cpp:
3226         * WebProcess/Plugins/Netscape/NetscapeBrowserFuncs.cpp:
3227         * WebProcess/Plugins/Netscape/gtk/NetscapePluginGtk.cpp:
3228         * WebProcess/Plugins/Netscape/qt/NetscapePluginQt.cpp:
3229         * WebProcess/Plugins/Netscape/win/NetscapePluginWin.cpp:
3230         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
3231         * WebProcess/WebCoreSupport/WebContextMenuClient.cpp:
3232         * WebProcess/WebCoreSupport/WebDragClient.cpp:
3233         * WebProcess/WebCoreSupport/WebEditorClient.cpp:
3234         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
3235         * WebProcess/WebCoreSupport/WebInspectorClient.cpp:
3236         * WebProcess/WebCoreSupport/WebInspectorFrontendClient.cpp:
3237         * WebProcess/WebCoreSupport/WebPlatformStrategies.cpp:
3238         * WebProcess/WebCoreSupport/gtk/WebContextMenuClientGtk.cpp:
3239         * WebProcess/WebCoreSupport/gtk/WebPopupMenuGtk.cpp:
3240         * WebProcess/WebCoreSupport/mac/WebContextMenuClientMac.mm:
3241         * WebProcess/WebCoreSupport/mac/WebEditorClientMac.mm:
3242         * WebProcess/WebCoreSupport/qt/WebContextMenuClientQt.cpp:
3243         * WebProcess/WebPage/gtk/WebInspectorGtk.cpp:
3244         * WebProcess/WebPage/qt/WebInspectorQt.cpp:
3245         * WebProcess/WebProcess.cpp:
3246         (WebKit::WebProcess::WebProcess):
3247         * WebProcess/gtk/WebProcessGtk.cpp:
3248         * config.h:
3249         * win/WebKit2.vcproj:
3250
3251 2011-02-22  Brian Weinstein  <bweinstein@apple.com>
3252
3253         Rubber-stamped by Brady Eidson.
3254
3255         Invalidate the WebResourceCacheManagerProxy in WebContext::processDidClose.
3256
3257         * UIProcess/WebContext.cpp:
3258         (WebKit::WebContext::processDidClose):
3259
3260 2011-02-21  Adam Roben  <aroben@apple.com>
3261
3262         Make DrawingAreaProxyImpl keep track of the most recent state ID it sent to the web process
3263
3264         This will be useful for sending repeated messages for the same state ID to the web process.
3265         We don't do this currently, but will need to if we're asked to paint after we've thrown away
3266         our backing store to save memory.
3267
3268         Fixes <http://webkit.org/b/54916> DrawingAreaProxyImpl should keep track of the state ID it
3269         last sent to the web process
3270
3271         Reviewed by Anders Carlsson.
3272
3273         * UIProcess/DrawingAreaProxyImpl.cpp:
3274         (WebKit::DrawingAreaProxyImpl::DrawingAreaProxyImpl): Initialize m_requestedStateID, and
3275         reordered member initialization to match the new declaration order.
3276         (WebKit::DrawingAreaProxyImpl::didUpdateState): Added an assertion that the stateID we got
3277         from the web process is no newer than the most recent one we requested.
3278         (WebKit::DrawingAreaProxyImpl::sendUpdateState): Changed to increment and send
3279         m_requestedStateID instead of a new global stateID.
3280
3281         * UIProcess/DrawingAreaProxyImpl.h: Added m_requestedStateID, and moved the state IDs before
3282         other data members. Also beefed the comment explaining m_currentStateID.
3283
3284 2011-02-22  Andras Becsi  <abecsi@webkit.org>
3285
3286         Reviewed by Laszlo Gombos.
3287
3288         [Qt] Redesign the build system
3289         https://bugs.webkit.org/show_bug.cgi?id=51339
3290
3291         Part 2.
3292
3293         Build WebCore as a static library, compile the WebKit API and WebKit2 API
3294         in a final step and link to WebKit2, WebCore and JSC libraries to fix
3295         linking issues resulting from stripped away symbols.
3296
3297         * WebKit2.pri: Add include paths.
3298         * WebKit2.pro: Move include paths to WebKit2.pri and move
3299         the API source to WebKit/qt/QtWebKit.pro
3300
3301 2011-02-22  Benjamin Poulain  <benjamin.poulain@nokia.com>
3302
3303         Reviewed by Kenneth Rohde Christiansen.
3304
3305         [Qt] [WK2] Improve the memory handling of the context menu for WebKit 2
3306         https://bugs.webkit.org/show_bug.cgi?id=54902
3307
3308         Refactor the context menu handling of Qt to make it simpler to manage memory.
3309
3310         WebContextMenuProxyQt uses smart pointer for all the references to menu so
3311         there is no need to delete it explicitely.
3312
3313         Passing the QMenu from QWKPage to the client of the signal now uses a QSharedPointer so
3314         the client can choose to handle the memory, but there is no leak if it does not.
3315
3316         * UIProcess/API/qt/qgraphicswkview.cpp:
3317         (QGraphicsWKView::QGraphicsWKView):
3318         (QGraphicsWKView::showContextMenu):
3319         * UIProcess/API/qt/qgraphicswkview.h:
3320         * UIProcess/API/qt/qwkpage.h:
3321         * UIProcess/qt/WebContextMenuProxyQt.cpp:
3322         (WebKit::WebContextMenuProxyQt::showContextMenu):
3323         (WebKit::WebContextMenuProxyQt::createContextMenu):
3324         * UIProcess/qt/WebContextMenuProxyQt.h:
3325
3326 2011-02-22  Philippe Normand  <pnormand@igalia.com>
3327
3328         Reviewed by Xan Lopez.
3329
3330         [GTK] make distcheck fails
3331         https://bugs.webkit.org/show_bug.cgi?id=54943
3332
3333         Removed reference to NotImplemented.h which was removed.
3334
3335         * GNUmakefile.am:
3336
3337 2011-02-22  Kimmo Kinnunen  <kimmo.t.kinnunen@nokia.com>
3338
3339         Reviewed by Kenneth Rohde Christiansen.
3340
3341         [Qt] QtWebProcess should be installed with 'make install'
3342         https://bugs.webkit.org/show_bug.cgi?id=44100
3343
3344         Follow the standard in other project files and allow install
3345         location to be changed with INSTALL_BINS variable.
3346
3347         * WebProcess.pro: Install QtWebProcess.
3348
3349 2011-02-22  Sheriff Bot  <webkit.review.bot@gmail.com>
3350
3351         Unreviewed, rolling out r79296.
3352         http://trac.webkit.org/changeset/79296
3353         https://bugs.webkit.org/show_bug.cgi?id=54941
3354
3355         Breaks compilation on SnowLeapard Intel Release (Requested by
3356         kbalazs_ on #webkit).
3357
3358         * Platform/gtk/SharedMemoryGtk.cpp:
3359         * Platform/gtk/WorkQueueGtk.cpp:
3360         * Platform/qt/WorkQueueQt.cpp:
3361         * Platform/win/WorkQueueWin.cpp:
3362         * Shared/NotImplemented.h: Copied from Source/WebKit2/WebProcess/InjectedBundle/gtk/InjectedBundleGtk.cpp.
3363         * Shared/Plugins/NPIdentifierData.cpp:
3364         * Shared/Plugins/NPRemoteObjectMap.cpp:
3365         * Shared/Plugins/NPVariantData.cpp:
3366         * Shared/cairo/ShareableBitmapCairo.cpp:
3367         * Shared/gtk/ShareableBitmapGtk.cpp:
3368         * Shared/gtk/WebCoreArgumentCodersGtk.cpp:
3369         * Shared/qt/WebCoreArgumentCodersQt.cpp:
3370         * Shared/win/LayerTreeContextWin.cpp:
3371         * UIProcess/API/mac/PageClientImpl.mm:
3372         * UIProcess/API/qt/qwkpage.cpp:
3373         * UIProcess/Launcher/gtk/ThreadLauncherGtk.cpp:
3374         * UIProcess/Launcher/qt/ProcessLauncherQt.cpp:
3375         * UIProcess/Plugins/gtk/PluginInfoStoreGtk.cpp:
3376         * UIProcess/WebContext.cpp:
3377         (WebKit::WebContext::WebContext):
3378         * UIProcess/WebInspectorProxy.cpp:
3379         * UIProcess/gtk/TextCheckerGtk.cpp:
3380         * UIProcess/gtk/WebInspectorGtk.cpp:
3381         * UIProcess/gtk/WebPreferencesGtk.cpp:
3382         * UIProcess/qt/TextCheckerQt.cpp:
3383         * UIProcess/qt/WebInspectorProxyQt.cpp:
3384         * UIProcess/win/TextCheckerWin.cpp:
3385         * UIProcess/win/WebContextMenuProxyWin.cpp:
3386         * WebKit2.pro:
3387         * WebKit2.xcodeproj/project.pbxproj:
3388         * WebProcess/Downloads/cf/DownloadCFNet.cpp:
3389         * WebProcess/Downloads/curl/DownloadCurl.cpp:
3390         * WebProcess/Downloads/mac/DownloadMac.mm:
3391         * WebProcess/Downloads/qt/DownloadQt.cpp:
3392         * WebProcess/InjectedBundle/gtk/InjectedBundleGtk.cpp:
3393         * WebProcess/Plugins/Netscape/JSNPMethod.cpp:
3394         * WebProcess/Plugins/Netscape/NPJSObject.cpp:
3395         * WebProcess/Plugins/Netscape/NPRuntimeObjectMap.cpp:
3396         * WebProcess/Plugins/Netscape/NetscapeBrowserFuncs.cpp:
3397         * WebProcess/Plugins/Netscape/gtk/NetscapePluginGtk.cpp:
3398         * WebProcess/Plugins/Netscape/qt/NetscapePluginQt.cpp:
3399         * WebProcess/Plugins/Netscape/win/NetscapePluginWin.cpp:
3400         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
3401         * WebProcess/WebCoreSupport/WebContextMenuClient.cpp:
3402         * WebProcess/WebCoreSupport/WebDragClient.cpp:
3403         * WebProcess/WebCoreSupport/WebEditorClient.cpp:
3404         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
3405         * WebProcess/WebCoreSupport/WebInspectorClient.cpp:
3406         * WebProcess/WebCoreSupport/WebInspectorFrontendClient.cpp:
3407         * WebProcess/WebCoreSupport/WebPlatformStrategies.cpp:
3408         * WebProcess/WebCoreSupport/gtk/WebContextMenuClientGtk.cpp:
3409         * WebProcess/WebCoreSupport/gtk/WebPopupMenuGtk.cpp:
3410         * WebProcess/WebCoreSupport/mac/WebContextMenuClientMac.mm:
3411         * WebProcess/WebCoreSupport/mac/WebEditorClientMac.mm:
3412         * WebProcess/WebCoreSupport/qt/WebContextMenuClientQt.cpp:
3413         * WebProcess/WebPage/gtk/WebInspectorGtk.cpp:
3414         * WebProcess/WebPage/qt/WebInspectorQt.cpp:
3415         * WebProcess/WebProcess.cpp:
3416         (WebKit::WebProcess::WebProcess):
3417         * WebProcess/gtk/WebProcessGtk.cpp:
3418         * config.h:
3419         * win/WebKit2.vcproj:
3420
3421 2011-02-16  Balazs Kelemen  <kbalazs@webkit.org>
3422
3423         Reviewed by Anders Carlsson.
3424
3425         notImplemented() should behave identical in WebCore and WebKit2
3426         https://bugs.webkit.org/show_bug.cgi?id=54449
3427
3428         Use NotImplemented.h from WebCore. Initialize logging channels.
3429         Remove the WebKit2 concept of notImplemented().
3430
3431         * Platform/gtk/SharedMemoryGtk.cpp:
3432         * Platform/gtk/WorkQueueGtk.cpp:
3433         * Platform/qt/WorkQueueQt.cpp:
3434         * Platform/win/WorkQueueWin.cpp:
3435         * Shared/NotImplemented.h: Removed.
3436         * Shared/Plugins/NPIdentifierData.cpp:
3437         * Shared/Plugins/NPRemoteObjectMap.cpp:
3438         * Shared/Plugins/NPVariantData.cpp:
3439         * Shared/cairo/ShareableBitmapCairo.cpp:
3440         * Shared/gtk/ShareableBitmapGtk.cpp:
3441         * Shared/gtk/WebCoreArgumentCodersGtk.cpp:
3442         * Shared/qt/WebCoreArgumentCodersQt.cpp:
3443         * Shared/win/LayerTreeContextWin.cpp:
3444         * UIProcess/API/qt/qwkpage.cpp:
3445         * UIProcess/Launcher/gtk/ThreadLauncherGtk.cpp:
3446         * UIProcess/Launcher/qt/ProcessLauncherQt.cpp:
3447         * UIProcess/Plugins/gtk/PluginInfoStoreGtk.cpp:
3448         * UIProcess/WebContext.cpp:
3449         (WebKit::WebContext::WebContext):
3450         * UIProcess/WebInspectorProxy.cpp:
3451         * UIProcess/gtk/TextCheckerGtk.cpp:
3452         * UIProcess/gtk/WebInspectorGtk.cpp:
3453         * UIProcess/gtk/WebPreferencesGtk.cpp:
3454         * UIProcess/qt/TextCheckerQt.cpp:
3455         * UIProcess/qt/WebInspectorProxyQt.cpp:
3456         * UIProcess/win/TextCheckerWin.cpp:
3457         * UIProcess/win/WebContextMenuProxyWin.cpp:
3458         * WebKit2.pro:
3459         * WebProcess/Downloads/cf/DownloadCFNet.cpp:
3460         * WebProcess/Downloads/curl/DownloadCurl.cpp:
3461         * WebProcess/Downloads/mac/DownloadMac.mm:
3462         * WebProcess/Downloads/qt/DownloadQt.cpp:
3463         * WebProcess/InjectedBundle/gtk/InjectedBundleGtk.cpp:
3464         * WebProcess/Plugins/Netscape/JSNPMethod.cpp:
3465         * WebProcess/Plugins/Netscape/NPJSObject.cpp:
3466         * WebProcess/Plugins/Netscape/NPRuntimeObjectMap.cpp:
3467         * WebProcess/Plugins/Netscape/NetscapeBrowserFuncs.cpp:
3468         * WebProcess/Plugins/Netscape/gtk/NetscapePluginGtk.cpp:
3469         * WebProcess/Plugins/Netscape/qt/NetscapePluginQt.cpp:
3470         * WebProcess/Plugins/Netscape/win/NetscapePluginWin.cpp:
3471         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
3472         * WebProcess/WebCoreSupport/WebContextMenuClient.cpp:
3473         * WebProcess/WebCoreSupport/WebDragClient.cpp:
3474         * WebProcess/WebCoreSupport/WebEditorClient.cpp:
3475         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
3476         * WebProcess/WebCoreSupport/WebInspectorClient.cpp:
3477         * WebProcess/WebCoreSupport/WebInspectorFrontendClient.cpp:
3478         * WebProcess/WebCoreSupport/WebPlatformStrategies.cpp:
3479         * WebProcess/WebCoreSupport/gtk/WebContextMenuClientGtk.cpp:
3480         * WebProcess/WebCoreSupport/gtk/WebPopupMenuGtk.cpp:
3481         * WebProcess/WebCoreSupport/mac/WebContextMenuClientMac.mm:
3482         * WebProcess/WebCoreSupport/mac/WebEditorClientMac.mm:
3483         * WebProcess/WebCoreSupport/qt/WebContextMenuClientQt.cpp:
3484         * WebProcess/WebPage/gtk/WebInspectorGtk.cpp:
3485         * WebProcess/WebPage/qt/WebInspectorQt.cpp: