Retry snapshots if they are too empty
[WebKit-https.git] / Source / WebKit2 / ChangeLog
1 2012-12-06  Jon Lee  <jonlee@apple.com>
2
3         Retry snapshots if they are too empty
4         https://bugs.webkit.org/show_bug.cgi?id=104174
5         <rdar://problem/12820146>
6
7         Reviewed by Simon Fraser.
8
9         * WebProcess/Plugins/PluginView.h: Add a new variable that keeps track of the number of times we've
10         retried to come up with a snapshot.
11         * WebProcess/Plugins/PluginView.cpp:
12         (WebKit::PluginView::PluginView): Initialize the count to 0.
13         (WebKit::isAlmostSolidColor): Figure out if the image is almost a solid color by overlaying
14         a grid of dots, and calculate the differences among them. If the average color difference is greater than
15         a threshold, we consider it to have meaningful content. For now we expect a minimum size and a specific
16         bitmap image format, otherwise we return early.
17         (WebKit::PluginView::pluginSnapshotTimerFired): If we have a snapshot image to look at, and if it is
18         evaluated to be too empty, then try again.
19
20 2012-12-06  Tony Chang  <tony@chromium.org>
21
22         Unreviewed, Apple Win Debug build fix.
23
24         * win/WebKit2.def.in: Add 2 symbols that are needed by the debug build.
25
26 2012-12-06  Alexey Proskuryakov  <ap@apple.com>
27
28         Track private browsing session in network process
29         https://bugs.webkit.org/show_bug.cgi?id=104281
30
31         Reviewed by Jessie Berlin.
32
33         Added ensure/destroy messages that match what's done in WebProcess. Also similarly,
34         ensuring a private session may happen on demand if network process has been restarted
35         after a crash, or if private browsing is enabled via a persistent preference.
36
37         Eventually, we should find a way to share code between WebFrameNetworkingContext
38         and RemoteNetworkingContext.
39
40         * NetworkProcess/NetworkProcess.cpp:
41         (WebKit::NetworkProcess::initializeNetworkProcess):
42         (WebKit::NetworkProcess::ensurePrivateBrowsingSession):
43         (WebKit::NetworkProcess::destroyPrivateBrowsingSession):
44         * NetworkProcess/NetworkProcess.h:
45         * NetworkProcess/NetworkProcess.messages.in:
46         * NetworkProcess/mac/RemoteNetworkingContext.h:
47         (RemoteNetworkingContext):
48         * NetworkProcess/mac/RemoteNetworkingContext.mm:
49         (WebKit::privateBrowsingStorageSessionIdentifierBase):
50         (WebKit::RemoteNetworkingContext::setPrivateBrowsingStorageSessionIdentifierBase):
51         (WebKit::RemoteNetworkingContext::ensurePrivateBrowsingSession):
52         (WebKit::RemoteNetworkingContext::destroyPrivateBrowsingSession):
53         * Shared/Network/NetworkProcessCreationParameters.cpp:
54         (WebKit::NetworkProcessCreationParameters::encode):
55         (WebKit::NetworkProcessCreationParameters::decode):
56         * Shared/Network/NetworkProcessCreationParameters.h:
57         (NetworkProcessCreationParameters):
58         * UIProcess/Network/mac/NetworkProcessProxyMac.mm:
59         (WebKit::NetworkProcessProxy::platformInitializeNetworkProcess):
60         * WebProcess/WebCoreSupport/mac/WebFrameNetworkingContext.mm:
61         (WebKit::WebFrameNetworkingContext::ensurePrivateBrowsingSession):
62         * WebProcess/WebProcess.cpp:
63         (WebKit::WebProcess::initializeWebProcess):
64
65 2012-12-06  Laszlo Gombos  <l.gombos@samsung.com>
66
67         [EFL] Remove ENABLE_GLIB_SUPPORT CMake variable
68         https://bugs.webkit.org/show_bug.cgi?id=104278
69
70         Reviewed by Brent Fulgham.
71
72         The guards are not required as it is always set for EFL.
73
74         * PlatformEfl.cmake:
75         * UIProcess/Plugins/unix/PluginProcessProxyUnix.cpp:
76         (WebKit::PluginProcessProxy::scanPlugin):
77         * WebProcess/efl/WebProcessMainEfl.cpp:
78         (WebKit::WebProcessMainEfl):
79
80 2012-12-06  Tony Chang  <tony@chromium.org>
81
82         REGRESSION(r135082): Restore the ability to insert author level style sheets from script
83         https://bugs.webkit.org/show_bug.cgi?id=104042
84
85         Reviewed by Antti Koivisto.
86
87         Update exports for Internals.cpp.
88
89         * win/WebKit2.def.in:
90
91 2012-12-06  Andras Becsi  <andras.becsi@digia.com>
92
93         [Qt][WK2] Fix QWebKitTest's notification of device pixel ratio change
94         https://bugs.webkit.org/show_bug.cgi?id=104269
95
96         Unreviewed, trivialy fixing last minute change.
97
98         Move signal emission to the correct place.
99
100         * UIProcess/API/qt/qquickwebview.cpp:
101         (QQuickWebViewFlickablePrivate::onComponentComplete):
102         * UIProcess/qt/PageViewportControllerClientQt.cpp:
103         (WebKit::PageViewportControllerClientQt::PageViewportControllerClientQt):
104
105 2012-12-06  Andras Becsi  <andras.becsi@digia.com>
106
107         [Qt][WK2] Fix QWebKitTest's notification of device pixel ratio change
108         https://bugs.webkit.org/show_bug.cgi?id=104269
109
110         Reviewed by Kenneth Rohde Christiansen.
111
112         Since the ViewportInfoItem of MiniBrowser is created before the
113         WebView finishes construction, thus before the viewport controller
114         has been instantiated, the shown device pixel ratio was incorrect.
115         Additionally QWebKitTest's notification signal was also not emitted
116         when the value changed.
117
118         * UIProcess/API/qt/qquickwebview.cpp:
119         (QQuickWebViewPrivate::QQuickWebViewPrivate):
120         * UIProcess/qt/PageViewportControllerClientQt.cpp:
121         (WebKit::PageViewportControllerClientQt::PageViewportControllerClientQt):
122
123 2012-12-06  Sheriff Bot  <webkit.review.bot@gmail.com>
124
125         Unreviewed, rolling out r136788.
126         http://trac.webkit.org/changeset/136788
127         https://bugs.webkit.org/show_bug.cgi?id=104260
128
129         Asserts on EFL WebKit2 Debug bot (Requested by yael on
130         #webkit).
131
132         * UIProcess/CoordinatedGraphics/LayerTreeRenderer.cpp:
133         (WebKit::LayerTreeRenderer::setLayerState):
134         (WebKit::LayerTreeRenderer::setRootLayerID):
135         * WebProcess/WebPage/CoordinatedGraphics/LayerTreeCoordinator.cpp:
136         (WebKit::LayerTreeCoordinator::LayerTreeCoordinator):
137         (WebKit::LayerTreeCoordinator::flushPendingLayerChanges):
138         * WebProcess/WebPage/CoordinatedGraphics/LayerTreeCoordinator.h:
139         (LayerTreeCoordinator):
140
141 2012-12-06  Sheriff Bot  <webkit.review.bot@gmail.com>
142
143         Unreviewed, rolling out r136795.
144         http://trac.webkit.org/changeset/136795
145         https://bugs.webkit.org/show_bug.cgi?id=104257
146
147         Asserts on EFL WebKit2 Debug bot (Requested by yael on
148         #webkit).
149
150         * UIProcess/CoordinatedGraphics/LayerTreeRenderer.cpp:
151         (WebKit::LayerTreeRenderer::setRootLayerID):
152
153 2012-12-06  Shinya Kawanaka  <shinyak@chromium.org>
154
155         Internals.getElementByIdInShadowRoot is nonsense now.
156         https://bugs.webkit.org/show_bug.cgi?id=104241
157
158         Reviewed by Kent Tamura.
159
160         * win/WebKit2.def.in:
161
162 2012-12-06  Christophe Dumez  <christophe.dumez@intel.com>
163
164         [EFL][WK2] Context clients should unregister themselves when destroyed
165         https://bugs.webkit.org/show_bug.cgi?id=104113
166
167         Reviewed by Kenneth Rohde Christiansen.
168
169         Make sure the context clients (History and Download clients)
170         unregister themselves when destroyed to make sure their
171         callback functions are never called after the client objects
172         have been destroyed (i.e. when the parent Ewk_Context has
173         been destroyed).
174
175         This addresses crashing issues after a Ewk_Context object
176         gets unref'd and destroyed.
177
178         * UIProcess/efl/ContextHistoryClientEfl.cpp:
179         (WebKit::ContextHistoryClientEfl::ContextHistoryClientEfl):
180         (WebKit):
181         (WebKit::ContextHistoryClientEfl::~ContextHistoryClientEfl):
182         * UIProcess/efl/ContextHistoryClientEfl.h:
183         (ContextHistoryClientEfl):
184         * UIProcess/efl/DownloadManagerEfl.cpp:
185         (WebKit::DownloadManagerEfl::~DownloadManagerEfl):
186         (WebKit):
187         * UIProcess/efl/DownloadManagerEfl.h:
188         (DownloadManagerEfl):
189
190 2012-12-05  Huang Dongsung  <luxtella@company100.net>
191
192         Coordinated Graphics: Reorder messages to LayerTreeCoordinatorProxy
193         https://bugs.webkit.org/show_bug.cgi?id=103843
194
195         Reviewed by Noam Rosenthal.
196
197         Clarify LayerTreeRenderer::setRootLayerID() can be called only once during its
198         lifecycle. LayerTreeRenderer, LayerTreeCoordinator and LayerTreeCoordinatorProxy
199         have the same lifecycle to WebPage and the root layer is reused even if loading
200         new page, so it is impossible to call LayerTreeRenderer::setRootLayerID() more
201         than twice.
202
203         * UIProcess/CoordinatedGraphics/LayerTreeRenderer.cpp:
204         (WebKit::LayerTreeRenderer::setRootLayerID):
205
206 2012-12-05  Brent Fulgham  <bfulgham@webkit.org>
207
208         [Windows, WinCairo] Regenerate .def files on changes
209         https://bugs.webkit.org/show_bug.cgi?id=104136
210
211         Reviewed by Tim Horton.
212
213         The new .def file generator is not regenerating the link
214         export definitions once it creates the definition file
215         the first time. You must clean the build directory for
216         new symbols to be added (or removed).
217
218         * win/WebKit2.vcproj: Change the WebKit2.def file reference to
219           point to the generated version of the file.
220         * win/WebKit2ExportGenerator.vcproj: Add WebKit2.def.in as a source
221           file that participates in the build so that Visual Studio knows
222           to build the project when the file changes.
223         * win/WebKit2ExportGeneratorBuildCmd.cmd: Added. Refactor build
224           command into its own shell script.
225         * win/WebKit2ExportGeneratorPostBuild.cmd: Call new BuildCmd script.
226         * win/WebKit2ExportGeneratorPreBuild.cmd: Delete the old generator
227           and definition files to ensure a clean build.
228
229 2012-12-05  Halton Huo  <halton.huo@intel.com>
230
231         [CMake] Unify coding style for CMake files
232         https://bugs.webkit.org/show_bug.cgi?id=103605
233
234         Reviewed by Laszlo Gombos.
235
236         Update cmake files(.cmake, CMakeLists.txt) with following style rules:
237         1. Indentation
238         1.1 Use spaces, not tabs.
239         1.2 Four spaces as indent.
240         2. Spacing
241         2.1 Place one space between control statements and their parentheses.
242             For eg, if (), else (), elseif (), endif (), foreach (),
243             endforeach (), while (), endwhile (), break ().
244         2.2 Do not place spaces between function and macro statements and
245             their parentheses. For eg, macro(), endmacro(), function(),
246             endfunction().
247         2.3 Do not place spaces between a command or function or macro and its
248             parentheses, or between a parenthesis and its content. For eg,
249             message("testing") not message( "testing") or message ("testing" )
250         2.4 No space at line ending.
251         3. Lowercase when call commands macros and functions. For eg,
252            add_executable() not ADD_EXECUTABLE(), set() not SET().
253
254         * CMakeLists.txt:
255         * PlatformEfl.cmake:
256         * win/WebKit2ExportGenerator.vcproj:
257         * win/WebKit2ExportGeneratorCommon.vsprops:
258
259 2012-12-05  Huang Dongsung  <luxtella@company100.net>
260
261         Coordinated Graphics: Reorder messages to LayerTreeCoordinatorProxy
262         https://bugs.webkit.org/show_bug.cgi?id=103843
263
264         Reviewed by Noam Rosenthal.
265
266         Send SetRootCompositingLayer message to the UI process in the
267         constructor instead of sending it on the first flush.
268
269         This is in preparation for refactoring TextureMapper to work in an actor
270         model (http://webkit.org/b/103854).
271
272         * UIProcess/CoordinatedGraphics/LayerTreeRenderer.cpp:
273         (WebKit::LayerTreeRenderer::setLayerState):
274         (WebKit::LayerTreeRenderer::setRootLayerID):
275         * WebProcess/WebPage/CoordinatedGraphics/LayerTreeCoordinator.cpp:
276         (WebKit::LayerTreeCoordinator::LayerTreeCoordinator):
277         (WebKit::LayerTreeCoordinator::initializeRootCompositingLayer):
278         (WebKit):
279         (WebKit::LayerTreeCoordinator::flushPendingLayerChanges):
280         * WebProcess/WebPage/CoordinatedGraphics/LayerTreeCoordinator.h:
281         (LayerTreeCoordinator):
282
283 2012-12-05  Jinwoo Song  <jinwoo7.song@samsung.com>
284
285         [EFL][WK2] Don't use the C API internally in ewk_cookie_manager
286         https://bugs.webkit.org/show_bug.cgi?id=103243
287
288         Reviewed by Gyuyoung Kim.
289
290         Used the C++ classes directly instead of the C API wrappers
291         to avoid a lot of toImpl/toAPI casts.
292
293         * UIProcess/API/efl/ewk_context.cpp:
294         (EwkContext::cookieManager):
295         * UIProcess/API/efl/ewk_cookie_manager.cpp:
296         (EwkCookieManager::EwkCookieManager):
297         (EwkCookieManager::~EwkCookieManager):
298         (EwkCookieManager::setPersistentStorage):
299         (EwkCookieManager::setHTTPAcceptPolicy):
300         (EwkCookieManager::clearHostnameCookies):
301         (EwkCookieManager::clearAllCookies):
302         (EwkCookieManager::watchChanges):
303         (EwkCookieManager::getHostNamesWithCookies):
304         (EwkCookieManager::getHTTPAcceptPolicy):
305         * UIProcess/API/efl/ewk_cookie_manager_private.h:
306         (EwkCookieManager::create):
307         (EwkCookieManager):
308
309 2012-12-05  No'am Rosenthal  <noam@webkit.org>
310
311         Coordinated Graphics: Enable support for setContentsToBackgroundColor
312         https://bugs.webkit.org/show_bug.cgi?id=104128
313
314         Reviewed by Kenneth Rohde Christiansen.
315
316         Enable setContentsToBackgroundColor in CoordinatedGraphicsLayer, and pass it through to the UI process.
317
318         * Shared/WebLayerTreeInfo.h:
319         (WebLayerInfo):
320         * UIProcess/CoordinatedGraphics/LayerTreeRenderer.cpp:
321         (WebKit::LayerTreeRenderer::setLayerState):
322         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedGraphicsLayer.cpp:
323         (WebCore::CoordinatedGraphicsLayer::setContentsToBackgroundColor):
324         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedGraphicsLayer.h:
325         (CoordinatedGraphicsLayer):
326
327 2012-12-05  Alexey Proskuryakov  <ap@apple.com>
328
329         <rdar://problem/12809890> Should allow sandbox lookup of com.apple.tccd
330
331         Reviewed by Beth Dakin and Dan Bernstein.
332
333         * WebProcess/com.apple.WebProcess.sb.in:
334
335 2012-12-05  Alexey Proskuryakov  <ap@apple.com>
336
337         [WK2] Would like to queue messages while NetworkProcess is launching
338         https://bugs.webkit.org/show_bug.cgi?id=104143
339
340         Reviewed by Anders Carlsson.
341
342         Factored out process launching and message sending code to a ChildProcessProxy class.
343         Process closing and crashing code should be moved once we better understand common
344         requirements for the processes.
345
346         * CMakeLists.txt:
347         * GNUmakefile.list.am:
348         * Target.pri:
349         * WebKit2.xcodeproj/project.pbxproj:
350         * win/WebKit2.vcproj:
351         Added ChildProcessProxy files.
352
353         * Shared/ChildProcessProxy.cpp: Added.
354         (WebKit::ChildProcessProxy::ChildProcessProxy):
355         (WebKit::ChildProcessProxy::~ChildProcessProxy):
356         (WebKit::ChildProcessProxy::fromConnection):
357         (WebKit::ChildProcessProxy::connect):
358         (WebKit::ChildProcessProxy::terminate):
359         (WebKit::ChildProcessProxy::sendMessage):
360         (WebKit::ChildProcessProxy::isLaunching):
361         (WebKit::ChildProcessProxy::didFinishLaunching):
362         (WebKit::ChildProcessProxy::clearConnection):
363         * Shared/ChildProcessProxy.h: Added.
364         (WebKit::ChildProcessProxy::connection):
365         (WebKit::ChildProcessProxy::isValid):
366         (WebKit::ChildProcessProxy::canSendMessage):
367         (WebKit::ChildProcessProxy::processIdentifier):
368         (WebKit::ChildProcessProxy::send):
369         (WebKit::ChildProcessProxy::sendSync):
370         Moved code from WebProcessProxy. Every ChildProcessProxy is a connection client,
371         but every one is a connection queue client, so that latter is passed as an argument.
372
373         * UIProcess/Network/NetworkProcessProxy.h:
374         * UIProcess/Network/NetworkProcessProxy.cpp:
375         Removed unused syncMessageSendTimedOut(), thank you OVERRIDE.
376
377         * UIProcess/Network/NetworkProcessProxy.cpp:
378         (WebKit::NetworkProcessProxy::NetworkProcessProxy):
379         (WebKit::NetworkProcessProxy::getLaunchOptions):
380         (WebKit::NetworkProcessProxy::~NetworkProcessProxy):
381         (WebKit::NetworkProcessProxy::getNetworkProcessConnection):
382         (WebKit::NetworkProcessProxy::didFinishLaunching):
383         * UIProcess/Network/NetworkProcessProxy.h:
384         * UIProcess/Network/mac/NetworkProcessProxyMac.mm:
385         (WebKit::NetworkProcessProxy::setApplicationIsOccluded):
386         * UIProcess/WebProcessProxy.cpp:
387         (WebKit::WebProcessProxy::WebProcessProxy):
388         (WebKit::WebProcessProxy::~WebProcessProxy):
389         (WebKit::WebProcessProxy::getLaunchOptions):
390         (WebKit::WebProcessProxy::disconnect):
391         (WebKit::WebProcessProxy::didFinishLaunching):
392         Use shared code.
393
394         * UIProcess/WebProcessProxy.h: (WebKit::WebProcessProxy::fromConnection):
395         NetworkProcess inherits from conneciton client privately, so we need to do most
396         of the work in ClientProcessProxy, and further upcast here.
397
398         * UIProcess/efl/WebProcessProxyEfl.cpp:
399         (WebKit::WebProcessProxy::platformGetLaunchOptions):
400         * UIProcess/gtk/WebProcessProxyGtk.cpp:
401         (WebKit::WebProcessProxy::platformGetLaunchOptions):
402         * UIProcess/mac/WebProcessProxyMac.mm:
403         (WebKit::WebProcessProxy::platformGetLaunchOptions):
404         * UIProcess/qt/WebProcessProxyQt.cpp:
405         (WebKit::WebProcessProxy::platformGetLaunchOptions):
406         * UIProcess/win/WebProcessProxyWin.cpp:
407         (WebKit::WebProcessProxy::platformGetLaunchOptions):
408         Updated for renaming, platformConnect -> platformGetLaunchOptions().
409
410 2012-12-05  Kiran Muppala  <cmuppala@apple.com>
411
412         WebKit2 child processes need to initialize timer coalescing policy on Mac.
413         https://bugs.webkit.org/show_bug.cgi?id=103613
414
415         Reviewed by Mark Rowe.
416
417         Set timer coalescing policy of WebKit2 child processes to that of visible applications
418         until they can manage the policy based on UI process visibility.
419
420         * Shared/mac/ChildProcessMac.mm:
421         (WebKit::initializeTimerCoalescingPolicy): Set task_latency and task_throughput QOS tiers as appropriate
422         for visible applications.
423         (WebKit::ChildProcess::platformInitialize): Add call to initializeTimerCoalescingPolicy.
424
425 2012-12-05  Anders Carlsson  <andersca@apple.com>
426
427         Connection::waitForMessage shouldn't use the message ID
428         https://bugs.webkit.org/show_bug.cgi?id=104157
429
430         Reviewed by Andreas Kling.
431
432         Pass the message receiver name and message name to waitForMessage and use them for lookups instead of
433         the message ID.
434
435         * Platform/CoreIPC/Connection.cpp:
436         (CoreIPC::Connection::createSyncMessageEncoder):
437         (CoreIPC::Connection::waitForMessage):
438         (CoreIPC::Connection::processIncomingMessage):
439         * Platform/CoreIPC/Connection.h:
440         (CoreIPC::Connection::waitForAndDispatchImmediately):
441
442 2012-12-05  Jae Hyun Park  <jae.park@company100.net>
443
444         Coordinated Graphics: Move AreaAllocator and UpdateAtlas to CoordinatedGraphics
445         https://bugs.webkit.org/show_bug.cgi?id=103864
446
447         Reviewed by Noam Rosenthal.
448
449         AreaAllocator and UpdateAtlas are only used for Coordinated Graphics.
450         So, these should be moved to CoordinatedGraphics to clarify the code.
451
452         No new test, because no change of behavior.
453
454         * CMakeLists.txt:
455         * Target.pri:
456         * WebProcess/WebPage/CoordinatedGraphics/AreaAllocator.cpp: Renamed from Source/WebKit2/WebProcess/WebPage/AreaAllocator.cpp.
457         (WebKit):
458         (WebKit::AreaAllocator::AreaAllocator):
459         (WebKit::AreaAllocator::~AreaAllocator):
460         (WebKit::AreaAllocator::expand):
461         (WebKit::AreaAllocator::expandBy):
462         (WebKit::AreaAllocator::release):
463         (WebKit::AreaAllocator::overhead):
464         (WebKit::AreaAllocator::roundAllocation):
465         (WebKit::GeneralAreaAllocator::GeneralAreaAllocator):
466         (WebKit::GeneralAreaAllocator::~GeneralAreaAllocator):
467         (WebKit::GeneralAreaAllocator::freeNode):
468         (WebKit::GeneralAreaAllocator::expand):
469         (WebKit::fitsWithin):
470         (WebKit::GeneralAreaAllocator::allocate):
471         (WebKit::GeneralAreaAllocator::allocateFromNode):
472         (WebKit::GeneralAreaAllocator::splitNode):
473         (WebKit::GeneralAreaAllocator::updateLargestFree):
474         (WebKit::GeneralAreaAllocator::release):
475         (WebKit::GeneralAreaAllocator::overhead):
476         * WebProcess/WebPage/CoordinatedGraphics/AreaAllocator.h: Renamed from Source/WebKit2/WebProcess/WebPage/AreaAllocator.h.
477         (WebCore::nextPowerOfTwo):
478         (WebCore):
479         (WebKit):
480         (AreaAllocator):
481         (WebKit::AreaAllocator::size):
482         (WebKit::AreaAllocator::minimumAllocation):
483         (WebKit::AreaAllocator::setMinimumAllocation):
484         (WebKit::AreaAllocator::margin):
485         (WebKit::AreaAllocator::setMargin):
486         (GeneralAreaAllocator):
487         (Node):
488         * WebProcess/WebPage/CoordinatedGraphics/UpdateAtlas.cpp: Renamed from Source/WebKit2/WebProcess/WebPage/UpdateAtlas.cpp.
489         (WebKit):
490         (WebKit::UpdateAtlas::UpdateAtlas):
491         (WebKit::UpdateAtlas::~UpdateAtlas):
492         (WebKit::UpdateAtlas::buildLayoutIfNeeded):
493         (WebKit::UpdateAtlas::didSwapBuffers):
494         (WebKit::UpdateAtlas::beginPaintingOnAvailableBuffer):
495         * WebProcess/WebPage/CoordinatedGraphics/UpdateAtlas.h: Renamed from Source/WebKit2/WebProcess/WebPage/UpdateAtlas.h.
496         (WebCore):
497         (WebKit):
498         (UpdateAtlasClient):
499         (UpdateAtlas):
500         (WebKit::UpdateAtlas::size):
501         (WebKit::UpdateAtlas::flags):
502         (WebKit::UpdateAtlas::addTimeInactive):
503         (WebKit::UpdateAtlas::isInactive):
504         (WebKit::UpdateAtlas::isInUse):
505
506 2012-12-05  Michael Brüning  <michael.bruning@digia.com>
507
508         Fix compilation for Qt5.0.0 stable branch.
509         https://bugs.webkit.org/show_bug.cgi?id=103870
510
511         Reviewed by Simon Hausmann.
512
513         QWindow::pos() and QQuickItem::pos() have been renamed to position().
514         Patch by Lars Knoll <lars.knoll@digia.com>
515
516         * UIProcess/qt/PageViewportControllerClientQt.cpp:
517         (WebKit::PageViewportControllerClientQt::setContentRectVisiblePositionAtScale):
518         (WebKit::PageViewportControllerClientQt::setViewportPosition):
519
520 2012-12-05  Christophe Dumez  <christophe.dumez@intel.com>
521
522         [EFL][WK2] EWK2UnitTestBase.ewk_favicon_database_async_icon_get is crashing with new Ewk_Context
523         https://bugs.webkit.org/show_bug.cgi?id=104110
524
525         Reviewed by Laszlo Gombos.
526
527         Unregister the WKFaviconDatabase client in EwkFaviconDatabase
528         destructor to avoid crashing if the callbacks get called
529         after the EwkFaviconDatabase object has been destroyed (i.e.
530         the parent EwkContext object was destroyed).
531
532         * UIProcess/API/efl/ewk_favicon_database.cpp:
533         (EwkFaviconDatabase::~EwkFaviconDatabase):
534
535 2012-12-05  Andras Becsi  <andras.becsi@digia.com>
536
537         [Qt][WK2] REGRESSION(r135399): It made qmltests::DoubleTapToZoom::test_double_zoomInAndBack() API test fail
538         https://bugs.webkit.org/show_bug.cgi?id=103889
539
540         Reviewed by Jocelyn Turcotte.
541
542         The client should always be notified in PageViewportController::didChangeViewportAttributes
543         about the changed attributes not only if the minimum scale changed. This ensures that these
544         changes are propagated to QWebKitTest and the zoom stack of double-tap-to-zoom is reset correctly.
545         Also increase precision of scale comparisons since the current value resulted in flakyness in
546         scale related API tests.
547
548         * UIProcess/PageViewportController.cpp:
549         (WebKit::PageViewportController::didChangeViewportAttributes):
550         (WebKit::PageViewportController::updateMinimumScaleToFit):
551
552 2012-12-05  Christophe Dumez  <christophe.dumez@intel.com>
553
554         [CoordinatedGraphics] Use unsigned integers for CoordinatedTile IDs
555         https://bugs.webkit.org/show_bug.cgi?id=103816
556
557         Reviewed by Jocelyn Turcotte.
558
559         Use unsigned integer for CoordinatedTile identifier type.
560         CoordinatedTile was previously using signed integers for
561         its identifier which is unsafe because the generated ID
562         will overflow at some point and the C and C++ language
563         standards say that overflow of a signed value is undefined
564         behaviour.
565
566         * UIProcess/CoordinatedGraphics/CoordinatedBackingStore.cpp:
567         (WebKit::CoordinatedBackingStore::createTile):
568         (WebKit::CoordinatedBackingStore::removeTile):
569         (WebKit::CoordinatedBackingStore::removeAllTiles):
570         (WebKit::CoordinatedBackingStore::updateTile):
571         (WebKit::CoordinatedBackingStore::texture):
572         (WebKit::CoordinatedBackingStore::paintToTextureMapper):
573         (WebKit::CoordinatedBackingStore::commitTileOperations):
574         * UIProcess/CoordinatedGraphics/CoordinatedBackingStore.h:
575         (CoordinatedBackingStore):
576         * UIProcess/CoordinatedGraphics/LayerTreeCoordinatorProxy.cpp:
577         (WebKit::LayerTreeCoordinatorProxy::createTileForLayer):
578         (WebKit::LayerTreeCoordinatorProxy::updateTileForLayer):
579         (WebKit::LayerTreeCoordinatorProxy::removeTileForLayer):
580         * UIProcess/CoordinatedGraphics/LayerTreeCoordinatorProxy.h:
581         (LayerTreeCoordinatorProxy):
582         * UIProcess/CoordinatedGraphics/LayerTreeCoordinatorProxy.messages.in:
583         * UIProcess/CoordinatedGraphics/LayerTreeRenderer.cpp:
584         (WebKit::LayerTreeRenderer::createTile):
585         (WebKit::LayerTreeRenderer::removeTile):
586         (WebKit::LayerTreeRenderer::updateTile):
587         * UIProcess/CoordinatedGraphics/LayerTreeRenderer.h:
588         (LayerTreeRenderer):
589         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedGraphicsLayer.cpp:
590         (WebCore::CoordinatedGraphicsLayer::createTile):
591         (WebCore::CoordinatedGraphicsLayer::updateTile):
592         (WebCore::CoordinatedGraphicsLayer::removeTile):
593         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedGraphicsLayer.h:
594         (CoordinatedGraphicsLayerClient):
595         (CoordinatedGraphicsLayer):
596         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedTile.cpp:
597         (WebKit):
598         (WebKit::CoordinatedTile::CoordinatedTile):
599         (WebKit::CoordinatedTile::~CoordinatedTile):
600         (WebKit::CoordinatedTile::updateBackBuffer):
601         (WebKit::CoordinatedTile::isReadyToPaint):
602         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedTile.h:
603         (CoordinatedTile):
604         (CoordinatedTileClient):
605         * WebProcess/WebPage/CoordinatedGraphics/LayerTreeCoordinator.cpp:
606         (WebKit::LayerTreeCoordinator::createTile):
607         (WebKit::LayerTreeCoordinator::updateTile):
608         (WebKit::LayerTreeCoordinator::removeTile):
609         * WebProcess/WebPage/CoordinatedGraphics/LayerTreeCoordinator.h:
610         (LayerTreeCoordinator):
611
612 2012-12-05  Yuni Jeong  <yhnet.jung@samsung.com>
613
614         [EFL][WK2] Add APIs to get/set private browsing.
615         https://bugs.webkit.org/show_bug.cgi?id=102052
616
617         Reviewed by Gyuyoung Kim.
618
619         Private Browsing allows a user to browse the Internet without saving any information about which sites and pages a user has visited.
620
621         * UIProcess/API/efl/ewk_settings.cpp:
622         (ewk_settings_private_browsing_enabled_set):
623         (ewk_settings_private_browsing_enabled_get):
624         * UIProcess/API/efl/ewk_settings.h:
625         * UIProcess/API/efl/tests/test_ewk2_settings.cpp:
626         (TEST_F):
627
628 2012-12-05  Joaquim Rocha  <jrocha@igalia.com>
629
630         URL schemes registered as local, no access, display isolated and as CORS enabled are not registered again after a web process crash
631         https://bugs.webkit.org/show_bug.cgi?id=104013
632
633         Reviewed by Darin Adler.
634
635         * WebProcess/WebProcess.cpp:
636         (WebKit::WebProcess::initializeWebProcess): Iterate through the schemes stored in
637         urlSchemesRegisteredAsLocal, urlSchemesRegisteredAsNoAccess,
638         urlSchemesRegisteredAsDisplayIsolated and urlSchemesRegisteredAsCORSEnabled and
639         call the respective (already existing) methods for registering them.
640
641 2012-12-04  Yuni Jeong  <yhnet.jung@samsung.com>
642
643         [EFL][WK2] Add APIs to get/set default font size.
644         https://bugs.webkit.org/show_bug.cgi?id=101921
645
646         Reviewed by Gyuyoung Kim.
647
648         Add setting APIs for default font size and a unit test.
649
650         * UIProcess/API/efl/ewk_settings.cpp:
651         (ewk_settings_default_font_size_set):
652         (ewk_settings_default_font_size_get):
653         * UIProcess/API/efl/ewk_settings.h:
654         * UIProcess/API/efl/tests/test_ewk2_settings.cpp:
655         (TEST_F):
656
657 2012-12-04  Anders Carlsson  <andersca@apple.com>
658
659         Remove #ifs that are always true
660         https://bugs.webkit.org/show_bug.cgi?id=104080
661
662         Reviewed by Andreas Kling.
663
664         __MAC_OS_X_VERSION_MIN_REQUIRED >= 1070 is always true, so remove all the #ifs.
665
666         * PluginProcess/mac/PluginProcessMac.mm:
667         (WebKit::initializeSandbox):
668         (WebKit::PluginProcess::platformInitialize):
669         * Shared/DictionaryPopupInfo.cpp:
670         (WebKit::DictionaryPopupInfo::encode):
671         (WebKit::DictionaryPopupInfo::decode):
672         * Shared/DictionaryPopupInfo.h:
673         * Shared/mac/WebEventFactory.mm:
674         (WebKit::phaseForEvent):
675         (WebKit::momentumPhaseForEvent):
676         * SharedWorkerProcess/mac/SharedWorkerProcessMac.mm:
677         (WebKit::initializeSandbox):
678         (WebKit::SharedWorkerProcess::platformInitialize):
679         * UIProcess/API/mac/PDFViewController.mm:
680         (WebKit::PDFViewScrollView_scrollWheel):
681         (WebKit::PDFViewController::pdfKitBundle):
682         * UIProcess/API/mac/PageClientImpl.mm:
683         (WebKit::PageClientImpl::didPerformDictionaryLookup):
684         (WebKit::PageClientImpl::dismissDictionaryLookupPanel):
685         (WebKit::PageClientImpl::recordAutocorrectionResponse):
686         (WebKit::PageClientImpl::recommendedScrollbarStyleDidChange):
687         * UIProcess/API/mac/WKView.mm:
688         (-[WKView displayIfNeeded]):
689         (-[WKView draggingUpdated:]):
690         (-[WKView viewDidMoveToWindow]):
691         (-[WKView _intrinsicDeviceScaleFactor]):
692         (-[WKView _cacheWindowBottomCornerRect]):
693         (-[WKView initWithFrame:contextRef:pageGroupRef:relatedToPage:]):
694         (+[WKView hideWordDefinitionWindow]):
695         * UIProcess/Launcher/mac/EnvironmentVariables.cpp:
696         * UIProcess/Launcher/mac/EnvironmentVariables.h:
697         (EnvironmentVariables):
698         * UIProcess/Launcher/mac/ProcessLauncherMac.mm:
699         (WebKit::addDYLDEnvironmentAdditions):
700         (WebKit::createWebProcessServiceForWebKitDevelopment):
701         (WebKit):
702         (WebKit::tryPreexistingProcess):
703         (WebKit::createProcess):
704         (WebKit::ProcessLauncher::launchProcess):
705         * UIProcess/Plugins/mac/PluginInfoStoreMac.mm:
706         (WebKit::PluginInfoStore::shouldUsePlugin):
707         (WebKit::PluginInfoStore::reactivateInactivePlugin):
708         * UIProcess/Plugins/mac/PluginProcessProxyMac.mm:
709         (WebKit::PluginProcessProxy::platformInitializePluginProcess):
710         * UIProcess/WebPageProxy.cpp:
711         (WebKit::WebPageProxy::didCommitLoadForFrame):
712         (WebKit::WebPageProxy::pageDidScroll):
713         (WebKit::WebPageProxy::processDidCrash):
714         (WebKit::WebPageProxy::recordAutocorrectionResponse):
715         (WebKit::WebPageProxy::handleAlternativeTextUIResult):
716         * UIProcess/WebPageProxy.h:
717         (WebPageProxy):
718         * UIProcess/WebPageProxy.messages.in:
719         * UIProcess/mac/TextCheckerMac.mm:
720         (WebKit::initializeState):
721         (WebKit::TextChecker::getGuessesForWord):
722         * UIProcess/mac/WKFullScreenWindowController.mm:
723         (convertRectToScreen):
724         * UIProcess/mac/WebContextMac.mm:
725         (WebKit::WebContext::platformInitializeWebProcess):
726         * WebKit2Prefix.h:
727         * WebProcess/Plugins/Netscape/NetscapeBrowserFuncs.cpp:
728         (WebKit::NPN_GetValue):
729         * WebProcess/Plugins/Netscape/mac/NetscapeSandboxFunctions.mm:
730         * WebProcess/WebCoreSupport/WebEditorClient.cpp:
731         (WebKit::WebEditorClient::shouldEraseMarkersAfterChangeSelection):
732         * WebProcess/WebCoreSupport/WebEditorClient.h:
733         * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
734         (InitWebCoreSystemInterface):
735         * WebProcess/WebPage/WebPage.cpp:
736         (WebKit):
737         * WebProcess/WebPage/WebPage.h:
738         (WebPage):
739         * WebProcess/WebPage/WebPage.messages.in:
740         * WebProcess/WebPage/mac/WebPageMac.mm:
741         (WebKit::WebPage::performDictionaryLookupAtLocation):
742         (WebKit::WebPage::performDictionaryLookupForSelection):
743         (WebKit::WebPage::performDictionaryLookupForRange):
744         * WebProcess/mac/SecItemShimMethods.mm:
745         * WebProcess/mac/WebProcessMac.mm:
746         (WebKit::WebProcess::secItemResponse):
747         * WebProcess/mac/WebProcessMainMac.mm:
748         (WebKit::WebProcessMain):
749         * WebProcessService/WebProcessServiceMain.mm:
750         (main):
751         * WebProcessServiceForWebKitDevelopment/WebProcessServiceForWebKitDevelopmentMain.mm:
752         (WebProcessServiceForWebKitDevelopmentEventHandler):
753         (main):
754
755 2012-12-04  Anders Carlsson  <andersca@apple.com>
756
757         Remove more Snow Leopard only code
758         https://bugs.webkit.org/show_bug.cgi?id=104079
759
760         Reviewed by Andreas Kling.
761
762         All of the SecKeychainItem code was Snow Leopard only.
763
764         * Shared/mac/SecKeychainItemRequestData.cpp: Removed.
765         * Shared/mac/SecKeychainItemRequestData.h: Removed.
766         * Shared/mac/SecKeychainItemResponseData.cpp: Removed.
767         * Shared/mac/SecKeychainItemResponseData.h: Removed.
768         * UIProcess/Launcher/mac/DynamicLinkerEnvironmentExtractor.h:
769         * UIProcess/Launcher/mac/DynamicLinkerEnvironmentExtractor.mm:
770         * UIProcess/WebProcessProxy.h:
771         (WebProcessProxy):
772         * UIProcess/WebProcessProxy.messages.in:
773         * UIProcess/mac/WebProcessProxyMac.mm:
774         * WebKit2.xcodeproj/project.pbxproj:
775         * WebProcess/WebProcess.h:
776         * WebProcess/WebProcess.messages.in:
777         * WebProcess/mac/KeychainItemShimMethods.h: Removed.
778         * WebProcess/mac/KeychainItemShimMethods.mm: Removed.
779         * WebProcess/mac/WebProcessMac.mm:
780         (WebKit::WebProcess::initializeShim):
781         * WebProcess/mac/WebProcessShim.mm:
782
783 2012-12-04  Anders Carlsson  <andersca@apple.com>
784
785         Remove PageClient::didChangeScrollbarsForMainFrame
786         https://bugs.webkit.org/show_bug.cgi?id=104077
787
788         Reviewed by Andreas Kling.
789
790         The aforementioned function was only used to implement some Snow Leopard specific behavior that we no longer support.
791
792         * UIProcess/API/gtk/PageClientImpl.cpp:
793         * UIProcess/API/gtk/PageClientImpl.h:
794         (PageClientImpl):
795         * UIProcess/API/mac/PageClientImpl.h:
796         (PageClientImpl):
797         * UIProcess/API/mac/PageClientImpl.mm:
798         * UIProcess/API/mac/WKView.mm:
799         (-[WKView viewWillMoveToWindow:]):
800         * UIProcess/API/mac/WKViewInternal.h:
801         * UIProcess/API/qt/raw/qrawwebview_p_p.h:
802         * UIProcess/PageClient.h:
803         (PageClient):
804         * UIProcess/WebPageProxy.cpp:
805         (WebKit::WebPageProxy::didChangeScrollbarsForMainFrame):
806         * UIProcess/efl/PageClientBase.cpp:
807         (WebKit):
808         * UIProcess/efl/PageClientBase.h:
809         (PageClientBase):
810         * UIProcess/qt/QtPageClient.h:
811         * UIProcess/win/WebView.cpp:
812         * UIProcess/win/WebView.h:
813         (WebView):
814
815 2012-12-04  Andy Estes  <aestes@apple.com>
816
817         [WebKit2] WKWebProcessPlugInBrowserContextControllers should be treated as type WKBrowsingContextControllerType for encoding purposes
818         https://bugs.webkit.org/show_bug.cgi?id=104063
819
820         Reviewed by Sam Weinig.
821
822         Objective-C message graphs can include browsing context controller
823         objects, which are decoded as WKWebProcessPlugInBrowserContextControllers
824         in the web process plug-in and as WKBrowsingContextControllers in the UI
825         process. Ensure we correctly encode WKWebProcessPlugInBrowserContextControllers
826         by treating them as type WKBrowsingContextControllerType.
827
828         * Shared/mac/ObjCObjectGraphCoders.mm:
829         (WebKit::typeFromObject):
830
831 2012-12-04  Simon Fraser  <simon.fraser@apple.com>
832
833         Show a mini visualizer for the tile cache tiles
834         https://bugs.webkit.org/show_bug.cgi?id=104053
835
836         Reviewed by Beth Dakin.
837
838         Plumb through a preference that controls the visibility of a tiled
839         scrolling indicator, and parent that layer in the TiledCoreAnimationDrawingArea.
840
841         * Shared/WebPreferencesStore.h:
842         * UIProcess/API/C/WKPreferences.cpp:
843         (WKPreferencesSetTiledScrollingIndicatorVisible):
844         (WKPreferencesGetTiledScrollingIndicatorVisible):
845         * UIProcess/API/C/WKPreferencesPrivate.h:
846         * WebProcess/WebPage/WebPage.cpp:
847         (WebKit::WebPage::updatePreferences):
848         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.h:
849         (TiledCoreAnimationDrawingArea):
850         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
851         (WebKit::TiledCoreAnimationDrawingArea::updatePreferences):
852         (WebKit::TiledCoreAnimationDrawingArea::setRootCompositingLayer):
853         (WebKit::TiledCoreAnimationDrawingArea::mainFrameTiledBacking):
854         (WebKit::TiledCoreAnimationDrawingArea::updateDebugInfoLayer):
855
856 2012-12-04  Anders Carlsson  <andersca@apple.com>
857
858         Set the visible process name before entering the sandbox
859         https://bugs.webkit.org/show_bug.cgi?id=104030
860         <rdar://problem/12800317>
861
862         Reviewed by Sam Weinig.
863
864         Pass the UI process name along as a process initialization parameter so we can set it
865         before entering the sandbox. Remove the UI process name from WebProcessCreationParameters.
866
867         * Shared/WebProcessCreationParameters.cpp:
868         (WebKit::WebProcessCreationParameters::encode):
869         (WebKit::WebProcessCreationParameters::decode):
870         * Shared/WebProcessCreationParameters.h:
871         (WebProcessCreationParameters):
872         * UIProcess/Launcher/mac/ProcessLauncherMac.mm:
873         (WebKit::connectToWebProcessServiceForWebKitDevelopment):
874         (WebKit::createWebProcessService):
875         (WebKit::createProcess):
876         * UIProcess/mac/WebContextMac.mm:
877         (WebKit::WebContext::platformInitializeWebProcess):
878         * WebProcess/mac/WebProcessInitialization.h:
879         (WebProcessInitializationParameters):
880         * WebProcess/mac/WebProcessInitialization.mm:
881         (WebKit::initializeWebProcess):
882         * WebProcess/mac/WebProcessMac.mm:
883         (WebKit::WebProcess::platformInitializeWebProcess):
884         * WebProcess/mac/WebProcessMainMac.mm:
885         (WebKit::WebProcessMain):
886         * WebProcess/mac/WebProcessServiceEntryPoints.h:
887         * WebProcess/mac/WebProcessServiceEntryPoints.mm:
888         (WebKit::WebProcessServiceEventHandler):
889         (initializeWebProcessForWebProcessServiceForWebKitDevelopment):
890         * WebProcessServiceForWebKitDevelopment/WebProcessServiceForWebKitDevelopmentMain.mm:
891         (WebProcessServiceForWebKitDevelopmentEventHandler):
892
893 2012-12-03  Alexey Proskuryakov  <ap@apple.com>
894
895         [WK2] Track private browsing session explicitly
896         <rdar://problem/12714532>
897         https://bugs.webkit.org/show_bug.cgi?id=103953
898
899         Reviewed by Jessie Berlin.
900
901         * Shared/WebProcessCreationParameters.cpp: (WebKit::WebProcessCreationParameters::encode):
902         Fixed a confusing ifdef - this code is inside PLATFORM(WIN), so PLATFORM(MAC)
903         makes no sense.
904
905         * UIProcess/API/C/WKPreferences.cpp: (WKPreferencesSetPrivateBrowsingEnabled):
906         This is the only place in WK2 where we can learn that private browsing got disabled -
907         no other functions are called when there are no pages open.
908
909         * UIProcess/WebContext.h:
910         * UIProcess/WebContext.cpp:
911         (WebKit::WebContext::willStartUsingPrivateBrowsing):
912         (WebKit::WebContext::willStopUsingPrivateBrowsing):
913         Count the number of API calls. We only implement a single shared private browsing
914         session, not one per page group as API implies. When private browsing gets disabled,
915         we want to destroy its session.
916
917         * WebProcess/WebPage/WebPage.cpp: (WebKit::WebPage::updatePreferences):
918         Ensure a private browsing session if the current page needs it.
919
920         * WebProcess/WebProcess.h:
921         * WebProcess/WebProcess.messages.in:
922         * WebProcess/WebProcess.cpp:
923         (WebKit::WebProcess::ensurePrivateBrowsingSession):
924         (WebKit::WebProcess::destroyPrivateBrowsingSession):
925         Call through to WebFrameNetworkingContext.
926
927 2012-12-04  Yuni Jeong  <yhnet.jung@samsung.com>
928
929         [EFL][WK2] Add APIs to toggle plug-ins support.
930         https://bugs.webkit.org/show_bug.cgi?id=101920
931
932         Reviewed by Gyuyoung Kim.
933
934         Add setting APIs to toggle plug-ins support and add corresponding API tests.
935
936         * UIProcess/API/efl/ewk_settings.cpp:
937         (ewk_settings_plugins_enabled_set):
938         (ewk_settings_plugins_enabled_get):
939         * UIProcess/API/efl/ewk_settings.h:
940         * UIProcess/API/efl/tests/test_ewk2_settings.cpp:
941         (TEST_F):
942
943 2012-12-04  Andras Becsi  <andras.becsi@digia.com>
944
945         [Qt][WK2] Do not override previously set flags of QQuickWebView when enabling drag&drop
946         https://bugs.webkit.org/show_bug.cgi?id=103901
947
948         Reviewed by Jocelyn Turcotte.
949
950         Setting the specific flag instead of resetting all the flags
951         when enabling QQuickItem::ItemAcceptsDrops.
952         This fixes clipping of the contents of QQuickWebView.
953
954         * UIProcess/API/qt/qquickwebview.cpp:
955         (QQuickWebViewPrivate::initialize):
956
957 2012-12-04  Carlos Garcia Campos  <cgarcia@igalia.com>
958
959         [GTK] Avoid unnecessary heap allocations during drag and drop operations
960         https://bugs.webkit.org/show_bug.cgi?id=87938
961
962         Reviewed by Martin Robinson.
963
964         * UIProcess/API/gtk/WebKitWebViewBase.cpp:
965         (webkitWebViewBaseDragDataReceived): Create DragData for the given
966         DataObjectGtk in the stack.
967         (webkitWebViewBaseDragMotion): Ditto.
968         (webkitWebViewBaseDragDrop): Ditto.
969
970 2012-12-04  Jaehun Lim  <ljaehun.lim@samsung.com>
971
972         [EFL][WK2] Use consistent class names inside Ewk classes
973         https://bugs.webkit.org/show_bug.cgi?id=103015
974
975         Reviewed by Gyuyoung Kim.
976
977         WebKit EFL doesn't use '_' in class names.
978         This patch removes the remaining uses of '_' inside Ewk classes.
979
980         * UIProcess/API/efl/EwkViewImpl.cpp:
981         (EwkViewImpl::EwkViewImpl):
982         (EwkViewImpl::~EwkViewImpl):
983         (EwkViewImpl::informIconChange):
984         (EwkViewImpl::requestColorPicker):
985         (EwkViewImpl::requestPopupMenu):
986         * UIProcess/API/efl/ewk_back_forward_list.cpp:
987         (EwkBackForwardList::nextItem):
988         (EwkBackForwardList::previousItem):
989         (EwkBackForwardList::currentItem):
990         (EwkBackForwardList::itemAt):
991         (EwkBackForwardList::getFromCacheOrCreate):
992         (EwkBackForwardList::createEinaList):
993         * UIProcess/API/efl/ewk_back_forward_list_private.h:
994         (EwkBackForwardList):
995         * UIProcess/API/efl/ewk_context.cpp:
996         (EwkContext::EwkContext):
997         (EwkContext::cookieManager):
998         (EwkContext::databaseManager):
999         (EwkContext::ensureFaviconDatabase):
1000         (EwkContext::faviconDatabase):
1001         (EwkContext::storageManager):
1002         * UIProcess/API/efl/ewk_context_private.h:
1003         (EwkContext):
1004         * UIProcess/API/efl/ewk_cookie_manager.cpp:
1005         (EwkCookieManager::cookiesDidChange):
1006         (getAcceptPolicyCallback):
1007         (getHostnamesWithCookiesCallback):
1008         * UIProcess/API/efl/ewk_cookie_manager_private.h:
1009         (EwkCookieManager::create):
1010         * UIProcess/API/efl/ewk_database_manager.cpp:
1011         (EwkDatabaseManager::createOriginList):
1012         (getDatabaseOriginsCallback):
1013         * UIProcess/API/efl/ewk_database_manager_private.h:
1014         (EwkDatabaseManager):
1015         * UIProcess/API/efl/ewk_favicon_database.cpp:
1016         (EwkFaviconDatabase::didChangeIconForPageURL):
1017         (EwkFaviconDatabase::iconDataReadyForPageURL):
1018         * UIProcess/API/efl/ewk_popup_menu.cpp:
1019         (EwkPopupMenu::EwkPopupMenu):
1020         (EwkPopupMenu::~EwkPopupMenu):
1021         * UIProcess/API/efl/ewk_storage_manager.cpp:
1022         (EwkStorageManager::createOriginList):
1023         (getStorageOriginsCallback):
1024         * UIProcess/API/efl/ewk_storage_manager_private.h:
1025         (EwkStorageManager):
1026
1027 2012-12-03  Huang Dongsung  <luxtella@company100.net>
1028
1029         Coordinated Graphics: Reorder messages to LayerTreeCoordinatorProxy
1030         https://bugs.webkit.org/show_bug.cgi?id=103843
1031
1032         Reviewed by Noam Rosenthal.
1033
1034         Remove updateViewport() in LayerTreeCoordinatorProxy::setRootCompositingLayer()
1035         because LayerTreeCoordinatorProxy::didRenderFrame() is always called after
1036         setting the root layer. There is no behaviour changes because setting the root
1037         layer isn't actually applied to TextureMapperLayer until DidRenderFrame message
1038         is received.
1039
1040         This is in preparation for refactoring TextureMapper to work in an actor
1041         model (http://webkit.org/b/103854).
1042
1043         * UIProcess/CoordinatedGraphics/LayerTreeCoordinatorProxy.cpp:
1044         (WebKit::LayerTreeCoordinatorProxy::setRootCompositingLayer):
1045         * WebProcess/WebPage/CoordinatedGraphics/LayerTreeCoordinator.cpp:
1046         (WebKit::LayerTreeCoordinator::flushPendingLayerChanges):
1047
1048 2012-12-03  Anders Carlsson  <andersca@apple.com>
1049
1050         Make it easier to add more web process initialization parameters
1051         https://bugs.webkit.org/show_bug.cgi?id=103942
1052
1053         Reviewed by Andreas Kling.
1054
1055         Add a WebProcessInitializationParameters struct to make it easier to add more initialization
1056         parameters in the future. Also, fix naming and spelling errors.
1057
1058         * WebProcess/mac/WebProcessInitialization.h:
1059         (WebProcessInitializationParameters):
1060         (WebKit):
1061         * WebProcess/mac/WebProcessInitialization.mm:
1062         (WebKit::initializeWebProcess):
1063         * WebProcess/mac/WebProcessMainMac.mm:
1064         (WebKit::WebProcessMain):
1065         * WebProcess/mac/WebProcessServiceEntryPoints.h:
1066         * WebProcess/mac/WebProcessServiceEntryPoints.mm:
1067         (WebKit::WebProcessServiceEventHandler):
1068         (webProcessServiceMain):
1069         (initializeWebProcessForWebProcessServiceForWebKitDevelopment):
1070         * WebProcessService/WebProcessServiceMain.mm:
1071         (main):
1072         * WebProcessServiceForWebKitDevelopment/WebProcessServiceForWebKitDevelopmentMain.mm:
1073         (WebProcessServiceForWebKitDevelopmentEventHandler):
1074
1075 2012-12-03  Tim Horton  <timothy_horton@apple.com>
1076
1077         PDFPlugin: <embed> and <object> PDFs affect their parent frame's page scale
1078         https://bugs.webkit.org/show_bug.cgi?id=103286
1079         <rdar://problem/12752315>
1080
1081         Reviewed by Dan Bernstein.
1082
1083         Style fixes after http://trac.webkit.org/changeset/136316.
1084
1085         * WebProcess/Plugins/PDF/PDFPlugin.mm:
1086         (WebKit::PDFPlugin::isFullFramePlugin):
1087
1088 2012-12-03  Alexis Menard  <alexis@webkit.org>
1089
1090         [Mac] Enable CSS3 background-position offset by default.
1091         https://bugs.webkit.org/show_bug.cgi?id=103905
1092
1093         Reviewed by Simon Fraser.
1094
1095         Turn the flag on by default.
1096
1097         * Configurations/FeatureDefines.xcconfig:
1098
1099 2012-12-03  Ryuan Choi  <ryuan.choi@samsung.com>
1100
1101         [EFL][WK2] Add contents,size,changed signal to the ewk_view API
1102         https://bugs.webkit.org/show_bug.cgi?id=103094
1103
1104         Reviewed by Kenneth Rohde Christiansen.
1105
1106         This patch emits signal to let applications know contents size.
1107         Applications can use this signal to give some additional behavior such as
1108         minimap, external scroll for quick movement.
1109
1110         * UIProcess/API/efl/EwkViewCallbacks.h: Added contents,size,changed signal.
1111         * UIProcess/API/efl/EwkViewImpl.cpp: Removed dead code.
1112         * UIProcess/API/efl/EwkViewImpl.h: Ditto.
1113         (EwkViewImpl):
1114         * UIProcess/API/efl/ewk_view.h: Added test case.
1115         * UIProcess/API/efl/tests/test_ewk2_view.cpp:
1116         (onContentsSizeChanged):
1117         (TEST_F):
1118         * UIProcess/efl/PageClientDefaultImpl.cpp: Emitted contents,size,changed signal.
1119         (WebKit::PageClientDefaultImpl::didChangeContentsSize):
1120         * UIProcess/efl/PageClientLegacyImpl.cpp: Ditto.
1121         (WebKit::PageClientLegacyImpl::didChangeContentsSize):
1122         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
1123         (WebKit::WebChromeClient::contentsSizeChanged):
1124         Sended DidChangeContentsSize message although TILED_BACKINGSTORE is disabled.
1125
1126 2012-12-03  Csaba Osztrogonác  <ossy@webkit.org>
1127
1128         Unreviewed fix after r136292 to make GIT-SVN repositories happy.
1129
1130         * win/WebKit2ExportGenerator.vcproj: Added property svn:eol-style.
1131         * win/WebKit2ExportGeneratorCommon.vsprops: Added property svn:eol-style.
1132         * win/WebKit2ExportGeneratorDebug.vsprops: Added property svn:eol-style.
1133         * win/WebKit2ExportGeneratorDebugAll.vsprops: Added property svn:eol-style.
1134         * win/WebKit2ExportGeneratorDebugCairoCFLite.vsprops: Added property svn:eol-style.
1135         * win/WebKit2ExportGeneratorPostBuild.cmd: Added property svn:eol-style.
1136         * win/WebKit2ExportGeneratorPreBuild.cmd: Added property svn:eol-style.
1137         * win/WebKit2ExportGeneratorProduction.vsprops: Added property svn:eol-style.
1138         * win/WebKit2ExportGeneratorRelease.vsprops: Added property svn:eol-style.
1139         * win/WebKit2ExportGeneratorReleaseCairoCFLite.vsprops: Added property svn:eol-style.
1140
1141 2012-12-03  Michael Brüning  <michael.bruning@digia.com>
1142
1143         [Qt][WK2] New resize tests fail
1144         https://bugs.webkit.org/show_bug.cgi?id=103875
1145
1146         Reviewed by Jocelyn Turcotte.
1147
1148         Removes reference to unused viewportSpy, adds clearing the sizeSpy to the init method instead.   
1149
1150         * UIProcess/API/qt/tests/qmltests/WebView/tst_resize.qml:
1151
1152 2012-12-03  Joaquim Rocha  <jrocha@igalia.com>
1153
1154         [GTK] Custom URI schemes stop working on Epiphany using WebKit2 after killing the web process
1155         https://bugs.webkit.org/show_bug.cgi?id=103729
1156
1157         Reviewed by Carlos Garcia Campos.
1158
1159         When a URI scheme is registered and the WebProcess is killed,
1160         those schemes would not work anymore after the process is relaunched.
1161
1162         This was observed in Epiphany and possibly affects any port that
1163         uses libsoup.
1164
1165         * Shared/WebProcessCreationParameters.cpp:
1166         (WebKit::WebProcessCreationParameters::encode): Encode the registered URI schemes.
1167         (WebKit::WebProcessCreationParameters::decode): Decode the registered URI schemes.
1168         * Shared/WebProcessCreationParameters.h: Add the urlSchemesRegistered Vector to hold the registered URI schemes.
1169         (WebProcessCreationParameters):
1170         * UIProcess/efl/WebContextEfl.cpp:
1171         (WebKit::WebContext::platformInitializeWebProcess): Assign the parameters.urlSchemesRegistered from the URI schemes
1172         registered in the WebSoupRequestManagerProxy and removed the notImplemented() call.
1173         * UIProcess/gtk/WebContextGtk.cpp:
1174         (WebKit::WebContext::platformInitializeWebProcess): Assign the parameters.urlSchemesRegistered from the URI schemes
1175         registered in the WebSoupRequestManagerProxy.
1176         * UIProcess/soup/WebSoupRequestManagerProxy.cpp:
1177         (WebKit::WebSoupRequestManagerProxy::registerURIScheme): Add the given scheme to the m_registeredURISchemes Vector.
1178         * UIProcess/soup/WebSoupRequestManagerProxy.h:
1179         (WebKit::WebSoupRequestManagerProxy::registeredURISchemes): Return the m_registeredURISchemes.
1180         (WebSoupRequestManagerProxy): Define the m_registeredURISchemes to hold the schemes that are registered.
1181         * WebProcess/soup/WebProcessSoup.cpp:
1182         (WebKit::WebProcess::platformInitializeWebProcess): Call m_soupRequestManager.registerURIScheme for each URI scheme
1183         found in the parameters.
1184         * WebProcess/soup/WebSoupRequestManager.h: Make registerURIScheme public.
1185         (WebSoupRequestManager):
1186
1187 2012-12-03  Mikhail Pozdnyakov  <mikhail.pozdnyakov@intel.com>
1188
1189         CSS Device Adaptation: window.innerWidth returns wrong value if CSS viewport descriptors are applied
1190         https://bugs.webkit.org/show_bug.cgi?id=103737
1191
1192         Reviewed by Kenneth Rohde Christiansen.
1193
1194         ViewportStyleResolver used frame view visibleContentRect size as initial viewport size.
1195         This however caused a problem when page enabled/disabled CSS stylesheets, having viewport
1196         descriptors. Viewport descriptors from new stylesheet were applied to the visibleContentRect
1197         affected already by the viewport descriptors from the previous stylesheet.
1198
1199         New 'initialViewportSize' property (http://dev.w3.org/csswg/css-device-adapt/#initial-viewport)
1200         was added to frame view so that viewport descriptors can always be applied to the reliable
1201         viewport size.
1202
1203         Both newly added 'initialViewportSize' property and 'fixedVisibleContentRect' property
1204         are assigned appropriately now in WebPage::sendViewportAttributesChanged().
1205
1206         * WebProcess/WebPage/WebPage.cpp:
1207         (WebKit::WebPage::sendViewportAttributesChanged):
1208
1209 2012-12-02  Huang Dongsung  <luxtella@company100.net>
1210
1211         Coordinated Graphics: Reorder messages to LayerTreeCoordinatorProxy
1212         https://bugs.webkit.org/show_bug.cgi?id=103843
1213
1214         Reviewed by Noam Rosenthal.
1215
1216         Send messages to the UI process by the tree order.
1217         This is in preparation for refactoring TextureMapper to work in an actor
1218         model (http://webkit.org/b/103854).
1219
1220         * WebProcess/WebPage/CoordinatedGraphics/LayerTreeCoordinator.cpp:
1221         (WebKit::LayerTreeCoordinator::flushPendingLayerChanges):
1222
1223 2012-12-02  Ryuan Choi  <ryuan.choi@gmail.com>
1224
1225         [EFL][WK2] Update comments of header files which mentions deprecated API
1226         https://bugs.webkit.org/show_bug.cgi?id=103718
1227
1228         Reviewed by Gyuyoung Kim.
1229
1230         Updated comments which mentions XXX_unref() which was replaced to ewk_object_unref()
1231
1232         * UIProcess/API/efl/ewk_context.h:
1233         * UIProcess/API/efl/ewk_database_manager.h:
1234         * UIProcess/API/efl/ewk_storage_manager.h:
1235
1236 2012-12-02  Huang Dongsung  <luxtella@company100.net>
1237
1238         REGRESSION(r134376): ASSERT(!m_mainBackingStore) hits in CoordinatedGraphicsLayer::syncImageBacking().
1239         https://bugs.webkit.org/show_bug.cgi?id=103845
1240
1241         Reviewed by Noam Rosenthal.
1242
1243         flushCompositingStateForThisLayerOnly() calls syncImageBacking() before calling
1244         updateContentBuffers(). It means there can be the moment that
1245         CoordinatedGraphicsLayer has m_mainBackingStore although
1246         shouldHaveBackingStore() return false.
1247         This patch changes syncImageBacking() to check shouldHaveBackingStore() instead
1248         of m_mainBackingStore.
1249
1250         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedGraphicsLayer.cpp:
1251         (WebCore::CoordinatedGraphicsLayer::syncImageBacking):
1252         (WebCore::CoordinatedGraphicsLayer::adjustContentsScale):
1253         (WebCore::CoordinatedGraphicsLayer::updateContentBuffers):
1254         (WebCore::CoordinatedGraphicsLayer::shouldHaveBackingStore):
1255         (WebCore):
1256         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedGraphicsLayer.h:
1257         (CoordinatedGraphicsLayer):
1258
1259 2012-12-02  Seokju Kwon  <seokju.kwon@gmail.com>
1260
1261         Rename WebSocketServerGtk.cpp as WebSocketServerSoup.cpp
1262         https://bugs.webkit.org/show_bug.cgi?id=103743
1263
1264         Reviewed by Gustavo Noronha Silva.
1265
1266         EFL port is using a GSocket based implementation as well.
1267         WebSocketServerSoup can be used together.
1268
1269         * GNUmakefile.list.am:
1270         * UIProcess/InspectorServer/soup/WebSocketServerSoup.cpp: Renamed from Source/WebKit2/UIProcess/InspectorServer/gtk/WebSocketServerGtk.cpp.
1271         (WebKit):
1272         (WebKit::connectionCallback):
1273         (WebKit::WebSocketServer::platformInitialize):
1274         (WebKit::WebSocketServer::platformListen):
1275         (WebKit::WebSocketServer::platformClose):
1276
1277 2012-12-02  Christophe Dumez  <christophe.dumez@intel.com>
1278
1279         [CoordinatedGraphics] LayerTreeRenderer::removeImageBacking() calls HashMap::find() twice
1280         https://bugs.webkit.org/show_bug.cgi?id=103815
1281
1282         Reviewed by Noam Rosenthal.
1283
1284         Call HashMap::take() in LayerTreeRenderer::removeImageBacking()
1285         to avoid calling HashMap::find() twice. find() was called once
1286         explicitly to get an iterator and a second time to remove the
1287         value from the value from the HashMap. We could have used
1288         remove(iterator) instead of remove(key) but using take() results
1289         in simpler code.
1290
1291         * UIProcess/CoordinatedGraphics/LayerTreeRenderer.cpp:
1292         (WebKit::LayerTreeRenderer::removeImageBacking):
1293
1294 2012-12-02  Huang Dongsung  <luxtella@company100.net>
1295
1296         Coordinated Graphics: Images disappear randomly
1297         https://bugs.webkit.org/show_bug.cgi?id=103522
1298
1299         Reviewed by Kenneth Rohde Christiansen.
1300
1301         Currently, we delete layers before synchronizing layer states of layers. It
1302         causes flash. This patch deletes layers after the synchronization.
1303
1304         In addiation, this patch removes updateViewport() in
1305         LayerTreeCoordinatorProxy::deleteCompositingLayer() because
1306         LayerTreeCoordinatorProxy::didRenderFrame() is always called after
1307         deleting layers.
1308
1309         * UIProcess/CoordinatedGraphics/LayerTreeCoordinatorProxy.cpp:
1310         (WebKit::LayerTreeCoordinatorProxy::deleteCompositingLayer):
1311         * WebProcess/WebPage/CoordinatedGraphics/LayerTreeCoordinator.cpp:
1312         (WebKit::LayerTreeCoordinator::flushPendingLayerChanges):
1313
1314 2012-12-02  Brent Fulgham  <bfulgham@webkit.org>
1315
1316         [Windows, WinCairo] Revise export definitions to match mac.
1317         https://bugs.webkit.org/show_bug.cgi?id=103687
1318
1319         Reviewed by Tim Horton.
1320
1321         Update export definition files to use the same feature exclusion
1322         macros as other generated ports.
1323
1324         * win/WebKit2.def.in: Added additional build macro guards.
1325
1326 2012-12-02  No'am Rosenthal  <noam@webkit.org>
1327
1328         [CoordinatedGraphics] Crash in TextureMapperLayer::setBackingStore()
1329         https://bugs.webkit.org/show_bug.cgi?id=103714
1330
1331         Reviewed by Kenneth Rohde Christiansen.
1332
1333         Remove a layer from the m_pendingSyncBackingStores map when it is deleted.
1334
1335         * UIProcess/CoordinatedGraphics/LayerTreeRenderer.cpp:
1336         (WebKit::LayerTreeRenderer::deleteLayer):
1337
1338 2012-12-02  Yael Aharon  <yael.aharon@intel.com>
1339
1340         [EFL][WK2] MiniBrowser should have a legacy mode
1341         https://bugs.webkit.org/show_bug.cgi?id=103679
1342
1343         Reviewed by Kenneth Rohde Christiansen.
1344
1345         We need a way to create a web view in legacy mode, while still using the default context.
1346         WKViewCreate creates a legacy view, so change it to create a default context if a context
1347         was not passed.
1348
1349         * UIProcess/API/efl/ewk_view.cpp:
1350         (ewk_view_base_add):
1351
1352 2012-12-01  Tim Horton  <timothy_horton@apple.com>
1353
1354         PDFPlugin: Support PDF form editing in <iframe>s
1355         https://bugs.webkit.org/show_bug.cgi?id=103287
1356         <rdar://problem/10326917>
1357
1358         Reviewed by Dan Bernstein.
1359
1360         PDFPlugin form editing depends on having a Document that has the same
1361         size and position as the plugin; this is true not only in the full-main-frame
1362         case, but also in the <iframe> case. Therefore, we can enable form editing
1363         for <iframe> PDFPlugins.
1364
1365         * WebProcess/Plugins/PDF/PDFPlugin.mm:
1366         (WebKit::PDFPlugin::supportsForms): Support form editing whenever
1367         our Document's widget is our PluginView (which will only be true in the
1368         full-main-frame or <iframe> case).
1369
1370 2012-12-01  Tim Horton  <timothy_horton@apple.com>
1371
1372         PDFPlugin: <embed> and <object> PDFs affect their parent frame's page scale
1373         https://bugs.webkit.org/show_bug.cgi?id=103286
1374         <rdar://problem/12752315>
1375
1376         Reviewed by Dan Bernstein.
1377
1378         Detecting whether or not a PDFPlugin is a full-page plugin or not is not
1379         as simple as checking isMainFrame(), because <embed> and <object> will
1380         cause PDFPlugin to live in the main frame, while still not being full-page.
1381         We also have to check that the main frame's document is a PluginDocument,
1382         and whether that PluginDocument's PluginWidget is our PDFPlugin's PluginView.
1383
1384         * WebProcess/Plugins/PDF/PDFPlugin.h:
1385         (PDFPlugin): Add isFullFramePlugin.
1386         * WebProcess/Plugins/PDF/PDFPlugin.mm:
1387         (WebKit::PDFPlugin::isFullFramePlugin): Check whether the main frame is
1388         backed by a PluginDocument, and that that PluginDocument corresponds
1389         to this PDFPlugin.
1390         (WebKit::PDFPlugin::handlesPageScaleFactor): Use isFullFramePlugin.
1391         (WebKit::PDFPlugin::supportsForms): Use isFullFramePlugin.
1392
1393 2012-12-01  Tim Horton  <timothy_horton@apple.com>
1394
1395         [wk2] Use spoolRect instead of snapshots for print preview
1396         https://bugs.webkit.org/show_bug.cgi?id=103798
1397         <rdar://problem/12686749>
1398
1399         Reviewed by Sam Weinig.
1400
1401         Revert to using spoolRect instead of snapshotting for printing; this was a bogus
1402         change I made in http://trac.webkit.org/changeset/133935 which was irrelevant to
1403         the core of that change, and incorrectly disregards the Frame parameter passed to
1404         beginPrinting, instead using the WebPage's current Frame.
1405
1406         * WebProcess/WebPage/WebPage.cpp:
1407         (WebKit::WebPage::drawRectToImage):
1408
1409 2012-11-30  Anders Carlsson  <andersca@apple.com>
1410
1411         Always listen for the DidFirstLayout layout milestone
1412         https://bugs.webkit.org/show_bug.cgi?id=103795
1413         <rdar://problem/12790268>
1414
1415         Reviewed by Dan Bernstein.
1416
1417         The DidFirstLayout layout milestone is used to determine when to unfreeze the layer tree, so we always want to listen for it.
1418
1419         * WebProcess/WebPage/WebPage.cpp:
1420         (WebKit::WebPage::WebPage):
1421
1422 2012-11-30  Pierre Rossi  <pierre.rossi@gmail.com>
1423
1424         [Qt] Unreviewed speculative Mac build fix after r136232
1425
1426         cleanup an oversight from r136235
1427
1428         * PluginProcess.pro: s/webkit/webkitwidgets/
1429
1430 2012-11-30  Brent Fulgham  <bfulgham@webkit.org>
1431
1432         [Windows, WinCairo] Generate library export symbol file.
1433         https://bugs.webkit.org/show_bug.cgi?id=103687
1434
1435         Reviewed by Tim Horton.
1436
1437         Generate the export definition file based on the compile options
1438         and port settings. Get rid of the old hand-written file, and use
1439         a revised master input file that allows using conditional
1440         settings to generate the output, much like the Mac and other
1441         ports do.
1442
1443         * win/WebKit2.def: Removed.
1444         * win/WebKit2.def.in: Added.
1445         * win/WebKit2Apple.vsprops:
1446         * win/WebKit2CFLite.def: Removed.
1447         * win/WebKit2CFLite.vsprops:
1448         * win/WebKit2Common.vsprops:
1449         * win/WebKit2ExportGenerator.vcproj: Added.
1450         * win/WebKit2ExportGeneratorCommon.vsprops: Added.
1451         * win/WebKit2ExportGeneratorDebug.vsprops: Added.
1452         * win/WebKit2ExportGeneratorDebugAll.vsprops: Added.
1453         * win/WebKit2ExportGeneratorDebugCairoCFLite.vsprops: Added.
1454         * win/WebKit2ExportGeneratorPostBuild.cmd: Added.
1455         * win/WebKit2ExportGeneratorPreBuild.cmd: Added.
1456         * win/WebKit2ExportGeneratorProduction.vsprops: Added.
1457         * win/WebKit2ExportGeneratorRelease.vsprops: Added.
1458         * win/WebKit2ExportGeneratorReleaseCairoCFLite.vsprops: Added.
1459
1460 2012-11-30  Tim Horton  <timothy_horton@apple.com>
1461
1462         (Simple)PDFPlugin: Support conversion of PostScript documents
1463         https://bugs.webkit.org/show_bug.cgi?id=103289
1464         <rdar://problem/10235708>
1465
1466         Reviewed by Dan Bernstein.
1467
1468         SimplePDFPlugin (and PDFPlugin) should support converting PostScript files
1469         to PDF before handing them off to their respective backends.
1470
1471         As PDFPlugin inherits from SimplePDFPlugin, it gets the new functionality automatically.
1472
1473         * WebProcess/Plugins/PDF/SimplePDFPlugin.h: Add convertPostScriptDataIfNeeded(), and m_isPostScript.
1474         * WebProcess/Plugins/PDF/SimplePDFPlugin.mm:
1475         (WebKit::SimplePDFPlugin::pluginInfo): SimplePDFPlugin should claim to support PDF and PostScript.
1476         (WebKit::convertPostScriptDataSourceToPDF): PS->PDF conversion code, copied from PDFViewController (which I intend to remove).
1477         (WebKit::SimplePDFPlugin::convertPostScriptDataIfNeeded): Check if the loaded data represents a PS file; if so, convert it.
1478         (WebKit::SimplePDFPlugin::streamDidReceiveResponse): Check if the loaded data is of MIME type application/postscript, and store that in m_isPostScript.
1479         (WebKit::SimplePDFPlugin::streamDidFinishLoading): Call convertPostScriptDataIfNeeded when we finish loading.
1480         (WebKit::SimplePDFPlugin::manualStreamDidReceiveResponse): Ditto from streamDidReceiveResponse.
1481         (WebKit::SimplePDFPlugin::manualStreamDidFinishLoading): Ditto from streamDidFinishLoading.
1482         * WebProcess/WebPage/WebPage.cpp:
1483         (WebKit::WebPage::createPlugin): Use (Simple)PDFPlugin for PostScript files too.
1484
1485 2012-11-30  Tim Horton  <timothy_horton@apple.com>
1486
1487         PDFPlugin: "Show Definition" context menu item should be implemented
1488         https://bugs.webkit.org/show_bug.cgi?id=103389
1489         <rdar://problem/12710751>
1490
1491         Reviewed by Dan Bernstein.
1492
1493         Call existing dictionary popup code when the context menu "Show Definition" item is selected.
1494
1495         * WebProcess/Plugins/PDF/PDFPlugin.h:
1496         (PDFPlugin): Add showDefinitionForAttributedString and convertFromPDFViewToRootView.
1497         * WebProcess/Plugins/PDF/PDFPlugin.mm:
1498         (-[WKPDFLayerControllerDelegate showDefinitionForAttributedString:atPoint:]): Forward this call to PDFPlugin.
1499         (WebKit::PDFPlugin::showDefinitionForAttributedString): Create a DictionaryPopupInfo with the necessary information.
1500         Ask WebPageProxy to show the dictionary popup.
1501         (WebKit::PDFPlugin::convertFromPDFViewToRootView): Convert a point from PDFLayerController space to the root view space.
1502
1503 2012-11-30  Simon Hausmann  <simon.hausmann@digia.com>
1504
1505         Unreviewed trivial Qt build fix:
1506
1507         Always link against WebProcess against QT += webkit and use webkitwidgets only if available.
1508
1509         * WebProcess.pro:
1510
1511 2012-11-30  Simon Hausmann  <simon.hausmann@digia.com>, Pierre Rossi  <pierre.rossi@digia.com>
1512
1513         [Qt] Separate Qt WebKit into Qt WebKit and Qt WebKit Widgets
1514         https://bugs.webkit.org/show_bug.cgi?id=99314
1515
1516         Reviewed by Tor Arne Vestbø.
1517
1518         This big change separates QtWebKit into QtWebKit and QtWebKitWidgets as
1519         shared libraries.
1520
1521         It's a big refactoring that mostly involves moving WebCore dependent
1522         code into QtWebKit and accessing it through exported QWebFrameAdapter
1523         and QWebPageAdapter classes.
1524
1525
1526         * UIProcess/API/qt/tests/inspectorserver/inspectorserver.pro:
1527         * UIProcess/API/qt/tests/publicapi/publicapi.pro:
1528         * UIProcess/API/qt/tests/qmltests/DesktopBehavior.pro:
1529         * UIProcess/API/qt/tests/qmltests/WebView.pro:
1530         * UIProcess/API/qt/tests/qquickwebview/qquickwebview.pro:
1531         * UIProcess/API/qt/tests/qrawwebview/qrawwebview.pro:
1532         * UIProcess/API/qt/tests/tests.pri:
1533
1534 2012-11-30  Joone Hur  <joone.hur@intel.com>
1535
1536         [EFL]Drawing artifacts while resizing the view
1537         https://bugs.webkit.org/show_bug.cgi?id=101288
1538
1539         Reviewed by Kenneth Rohde Christiansen.
1540
1541         An Evas GL surface is recreated when the window is resized, but the update of the surface is 
1542         asynchronously done, which gives Evas a chance of painting the empty surface on the screen.
1543         As a result, the flickering problem happens while resizing the view.
1544         So this patch allows to create an Evas GL surface synchronously with the update of the surface.
1545
1546         * UIProcess/API/efl/EwkViewImpl.cpp:
1547         (EwkViewImpl::EwkViewImpl): Set m_pendingSurfaceResize to false.
1548         (EwkViewImpl::displayTimerFired): Create an Evas GL surface.
1549         * UIProcess/API/efl/EwkViewImpl.h:
1550         (EwkViewImpl::setNeedsSurfaceResize): Added.
1551         (EwkViewImpl):
1552         * UIProcess/API/efl/ewk_view.cpp:
1553         (_ewk_view_smart_calculate): Set m_pendingSurfaceResize to true.
1554
1555 2012-11-30  Mikhail Pozdnyakov  <mikhail.pozdnyakov@intel.com>
1556
1557         [WK2] TiledBackingStore: Frame view re-layouts with wrong Fixed Visible Content Rect.
1558         https://bugs.webkit.org/show_bug.cgi?id=103428
1559
1560         Reviewed by Kenneth Rohde Christiansen.
1561
1562         Set now appropriate fixed visible content rect before layout when viewport
1563         attributes change.
1564
1565         * UIProcess/PageViewportController.cpp:
1566         (WebKit::PageViewportController::syncVisibleContents):
1567         (WebKit::PageViewportController::didChangeViewportAttributes):
1568         * WebProcess/WebPage/WebPage.cpp:
1569         (WebKit::WebPage::sendViewportAttributesChanged):
1570
1571 2012-11-30  Sudarsana Nagineni  <sudarsana.nagineni@intel.com>
1572
1573         [EFL] Gardening after r136031 and r136142
1574         https://bugs.webkit.org/show_bug.cgi?id=103734
1575
1576         Unreviewed, API test EWK2UnitTestBase.ewk_view_setting_encoding_custom
1577         is asserting after r136031. So, disabling the test until bug 103732 is
1578         fixed.
1579
1580         * UIProcess/API/efl/tests/test_ewk2_view.cpp:
1581         (TEST_F):
1582
1583 2012-11-30  Zeno Albisser  <zeno@webkit.org>
1584
1585         [Qt] Enable WebGL by default.
1586         https://bugs.webkit.org/show_bug.cgi?id=103731
1587
1588         Reviewed by Simon Hausmann.
1589
1590         * UIProcess/API/qt/qquickwebview.cpp:
1591         (QQuickWebViewPrivate::initialize):
1592
1593 2012-11-30  Mihai Maerean  <mmaerean@adobe.com>
1594
1595         [CSSRegions] when WebKit uses V8, there should be a single variable to store if the CSS Regions feature is enabled
1596         https://bugs.webkit.org/show_bug.cgi?id=101192
1597
1598         Reviewed by Hajime Morita.
1599
1600         Removed the CSS Regions flag in Settings and switched to using the new flag I have added in RuntimeEnabledFeatures.
1601
1602         Tests: No new tests because there is no functional change.
1603
1604         * WebProcess/InjectedBundle/InjectedBundle.cpp:
1605         (WebKit::InjectedBundle::overrideBoolPreferenceForTestRunner):
1606         (WebKit::InjectedBundle::setCSSRegionsEnabled):
1607         (WebKit):
1608         * WebProcess/InjectedBundle/InjectedBundle.h:
1609         (InjectedBundle):
1610         * WebProcess/WebPage/WebPage.cpp:
1611         (WebKit::WebPage::updatePreferences):
1612
1613 2012-11-29  Tim Horton  <timothy_horton@apple.com>
1614
1615         PDFPlugin: Only plain text can be copied out of PDFs
1616         https://bugs.webkit.org/show_bug.cgi?id=103591
1617         <rdar://problem/12555161>
1618
1619         Reviewed by Alexey Proskuryakov.
1620
1621         Don't write zero-length data to the pasteboard, just skip the item.
1622
1623         As mentioned in the comment, we don't expect this to come up, and would like to know if it does,
1624         so we assert that it doesn't happen in debug builds.
1625
1626         * WebProcess/Plugins/PDF/PDFPlugin.mm:
1627         (WebKit::PDFPlugin::writeItemsToPasteboard):
1628
1629 2012-11-29  Martin Robinson  <mrobinson@igalia.com>
1630
1631         [GTK] [WebKit2] WebKitWebViewBase creates a GL context for the redirected XComposite window crashing WebKit in Xvfb
1632         https://bugs.webkit.org/show_bug.cgi?id=103476
1633
1634         Reviewed by Alejandro G. Castro.
1635
1636         Create the RedirectedXCompositeWindow with an argument specifying that it
1637         should never have a GLContext backing it.
1638
1639         * UIProcess/API/gtk/WebKitWebViewBase.cpp:
1640         (_WebKitWebViewBasePrivate::_WebKitWebViewBasePrivate):
1641
1642 2012-11-29  Rafael Weinstein  <rafaelw@chromium.org>
1643
1644         [HTMLTemplateElement] Add feature flag
1645         https://bugs.webkit.org/show_bug.cgi?id=103694
1646
1647         Reviewed by Adam Barth.
1648
1649         This flag will guard the implementation of the HTMLTemplateElement.
1650         http://dvcs.w3.org/hg/webcomponents/raw-file/tip/spec/templates/index.html
1651
1652         * Configurations/FeatureDefines.xcconfig:
1653
1654 2012-11-29  Alexey Proskuryakov  <ap@apple.com>
1655
1656         [WK2] Forward cookie jar calls to NetworkProcess
1657         https://bugs.webkit.org/show_bug.cgi?id=103457
1658
1659         Reviewed by Darin Adler.
1660
1661         * NetworkProcess/NetworkConnectionToWebProcess.messages.in:
1662         Added messages to maniputate CookieJar in network process.
1663
1664         * NetworkProcess/NetworkConnectionToWebProcess.h:
1665         * NetworkProcess/NetworkConnectionToWebProcess.cpp: Removed unnecessary WebCore:: prefixes,
1666         this file has a using direcive.
1667         (WebKit::NetworkConnectionToWebProcess::cookiesForDOM):
1668         (WebKit::NetworkConnectionToWebProcess::setCookiesFromDOM):
1669         (WebKit::NetworkConnectionToWebProcess::cookiesEnabled):
1670         (WebKit::NetworkConnectionToWebProcess::cookieRequestHeaderFieldValue):
1671         (WebKit::NetworkConnectionToWebProcess::getRawCookies):
1672         (WebKit::NetworkConnectionToWebProcess::deleteCookie):
1673         (WebKit::NetworkConnectionToWebProcess::getHostnamesWithCookies):
1674         (WebKit::NetworkConnectionToWebProcess::deleteCookiesForHostname):
1675         (WebKit::NetworkConnectionToWebProcess::deleteAllCookies):
1676         Added implementations that use PlatformCookieJar in the network process.
1677
1678         * Scripts/webkit2/messages.py: (struct_or_class):
1679         * Shared/WebCoreArgumentCoders.h:
1680         * Shared/WebCoreArgumentCoders.cpp:
1681         (CoreIPC::::encode):
1682         (CoreIPC::::decode):
1683         Added support for Cookie.
1684         
1685         * WebProcess/WebCoreSupport/WebPlatformStrategies.h:
1686         * WebProcess/WebCoreSupport/WebPlatformStrategies.cpp:
1687         (WebKit::WebPlatformStrategies::cookiesForDOM):
1688         (WebKit::WebPlatformStrategies::setCookiesFromDOM):
1689         (WebKit::WebPlatformStrategies::cookiesEnabled):
1690         (WebKit::WebPlatformStrategies::cookieRequestHeaderFieldValue):
1691         (WebKit::WebPlatformStrategies::getRawCookies):
1692         (WebKit::WebPlatformStrategies::deleteCookie):
1693         (WebKit::WebPlatformStrategies::getHostnamesWithCookies):
1694         (WebKit::WebPlatformStrategies::deleteCookiesForHostname):
1695         (WebKit::WebPlatformStrategies::deleteAllCookies):
1696         When using the network process, forward cookie calls to it.
1697
1698 2012-11-29  Kiran Muppala  <cmuppala@apple.com>
1699
1700         Instantiate snapshot plugins in a PluginProcess with muted audio
1701         https://bugs.webkit.org/show_bug.cgi?id=101536
1702
1703         Reviewed by Anders Carlsson.
1704
1705         Plugins created for generation of a snapshot should be instantiated in a separate process with
1706         muted audio so that any sound generated during the snapshot process is not audible to the user.
1707
1708         * Configurations/WebKit2.xcconfig: Add CoreAudio to the list of linked frameworks.
1709         * PluginProcess/PluginProcess.h: Add PluginProcess::Type enum with values for regular and
1710         snapshot process types. Provide DefaultHash and IsInteger template specializations for the enum
1711         so that PluginProcessConnectionManager can store it in a HashMap.
1712         * PluginProcess/mac/PluginProcessMac.mm:
1713         (WebKit::muteAudio):
1714         (WebKit::PluginProcess::platformInitialize): Mute audio if the process creation parameters indicate
1715         that the plugin process type is snapshot process.
1716         * Shared/Plugins/PluginProcessCreationParameters.cpp:
1717         (WebKit::PluginProcessCreationParameters::encode):
1718         (WebKit::PluginProcessCreationParameters::decode):
1719         * Shared/Plugins/PluginProcessCreationParameters.h: Add processType process creation parameter.
1720         * UIProcess/Plugins/PluginProcessManager.cpp:
1721         (WebKit::PluginProcessManager::getPluginProcessConnection): Add process type parameter.
1722         (WebKit::PluginProcessManager::getSitesWithData): Forward message to regular plugin process only.
1723         (WebKit::PluginProcessManager::clearSiteData): Forward message to regular plugin process only.
1724         (WebKit::PluginProcessManager::pluginProcessWithPath): Add process type parameter.
1725         (WebKit::PluginProcessManager::getOrCreatePluginProcess): Ditto.
1726         * UIProcess/Plugins/PluginProcessManager.h:
1727         * UIProcess/Plugins/PluginProcessProxy.cpp:
1728         (WebKit::PluginProcessProxy::create): Add process type parameter.
1729         (WebKit::PluginProcessProxy::PluginProcessProxy): Ditto.
1730         (WebKit::PluginProcessProxy::didClose): Include process type with the plugin process crashed message.
1731         (WebKit::PluginProcessProxy::didFinishLaunching): Set process type process creation parameter.
1732         * UIProcess/Plugins/PluginProcessProxy.h:
1733         (WebKit::PluginProcessProxy::processType):
1734         * UIProcess/WebProcessProxy.cpp:
1735         (WebKit::WebProcessProxy::getPluginProcessConnection): Pass along process type parameter to
1736         PluginProcessManager.
1737         * UIProcess/WebProcessProxy.h:
1738         (WebProcessProxy):
1739         * UIProcess/WebProcessProxy.messages.in: Add process type parameter to GetPluginProcessConnection message.
1740         * WebProcess/Plugins/PluginProcessConnection.cpp:
1741         (WebKit::PluginProcessConnection::PluginProcessConnection): Add process type parameter.
1742         * WebProcess/Plugins/PluginProcessConnection.h:
1743         (WebKit::PluginProcessConnection::create): Ditto.
1744         (WebKit::PluginProcessConnection::processType): Ditto.
1745         * WebProcess/Plugins/PluginProcessConnectionManager.cpp:
1746         (WebKit::PluginProcessConnectionManager::getPluginProcessConnection): Add process type parameter.
1747         (WebKit::PluginProcessConnectionManager::removePluginProcessConnection): Use process type in addition to
1748         plugin path to find the connection to remove.
1749         (WebKit::PluginProcessConnectionManager::pluginProcessCrashed): Add process type parameter.
1750         * WebProcess/Plugins/PluginProcessConnectionManager.h:
1751         * WebProcess/Plugins/PluginProxy.cpp:
1752         (WebKit::PluginProxy::create): Ditto.
1753         (WebKit::PluginProxy::PluginProxy): Ditto.
1754         (WebKit::PluginProxy::initialize): Add process type parameter in call to
1755         PluginProcessConnectionManager::getPluginProcessConnection.
1756         * WebProcess/Plugins/PluginProxy.h:
1757         * WebProcess/WebPage/WebPage.cpp:
1758         (WebKit::WebPage::createPlugin): Determine process type based on display state of plugin element and
1759         pass it to PluginProxy::create.
1760         * WebProcess/WebProcess.cpp:
1761         (WebKit::WebProcess::pluginProcessCrashed): Pass along process type parameter to
1762         PluginProcessConnectionManager.
1763         * WebProcess/WebProcess.h:
1764         * WebProcess/WebProcess.messages.in: Add process type parameter to PluginProcessCrashed message.
1765
1766 2012-11-29  Anders Carlsson  <andersca@apple.com>
1767
1768         Initialize m_xpcConnection to null if the identifier doesn't have an XPC connection
1769         https://bugs.webkit.org/show_bug.cgi?id=103689
1770
1771         Reviewed by Darin Adler.
1772
1773         * Platform/CoreIPC/mac/ConnectionMac.cpp:
1774         (CoreIPC::Connection::platformInitialize):
1775
1776 2012-11-29  Christophe Dumez  <christophe.dumez@intel.com>
1777
1778         [CoordinatedGraphics] Use OwnPtr for LayerMap's layers in LayerTreeRenderer
1779         https://bugs.webkit.org/show_bug.cgi?id=103650
1780
1781         Reviewed by Noam Rosenthal.
1782
1783         We currently store raw pointers to WebCore::GraphicsLayer in the LayerMap
1784         meaning that we need to delete them manually. This patch leverages smart
1785         pointers and stores layers as OwnPtr in the LayerMap so that the layers
1786         are owned by the HashMap and we don't have to handle memory manually.
1787
1788         * UIProcess/CoordinatedGraphics/LayerTreeRenderer.cpp:
1789         (WebKit::LayerTreeRenderer::adjustPositionForFixedLayers):
1790         (WebKit::LayerTreeRenderer::setLayerChildren):
1791         (WebKit::LayerTreeRenderer::deleteLayer):
1792         (WebKit::LayerTreeRenderer::ensureLayer):
1793         * UIProcess/CoordinatedGraphics/LayerTreeRenderer.h:
1794
1795 2012-11-29  Anders Carlsson  <andersca@apple.com>
1796
1797         Add a minimumLayoutWidth WKView property
1798         https://bugs.webkit.org/show_bug.cgi?id=103660
1799         <rdar://problem/11791729>
1800
1801         Reviewed by Beth Dakin.
1802
1803         When minimumLayoutWidth is set to a positive value, the WKView will update its intrinsic content size given the layout width.
1804
1805         * UIProcess/API/mac/PageClientImpl.h:
1806         * UIProcess/API/mac/PageClientImpl.mm:
1807         (WebKit::PageClientImpl::intrinsicContentSizeDidChange):
1808         Call the WKView.
1809
1810         * UIProcess/API/mac/WKView.mm:
1811         (-[WKView intrinsicContentSize]):
1812         Override the intrinsicContentSize getter.
1813
1814         (-[WKView _setIntrinsicContentSize:]):
1815         Update the intrinsic content size and mark it as invalid.
1816
1817         (-[WKView initWithFrame:contextRef:pageGroupRef:relatedToPage:]):
1818         By default, the WKView should have no intrinsic size.
1819
1820         (-[WKView minimumLayoutWidth]):
1821         (-[WKView setMinimumLayoutWidth:]):
1822         Call through to the WebPageProxy object.
1823
1824         * UIProcess/API/mac/WKViewPrivate.h:
1825         Add the SPI here.
1826
1827         * UIProcess/DrawingAreaProxy.h:
1828         (WebKit::DrawingAreaProxy::minimumLayoutWidthDidChange):
1829         (WebKit::DrawingAreaProxy::didUpdateGeometry):
1830         (WebKit::DrawingAreaProxy::intrinsicContentSizeDidChange):
1831         Add empty stubs.
1832
1833         * UIProcess/DrawingAreaProxy.messages.in:
1834         Update the DidUpdateGeometry signature and add IntrinsicContentSizeDidChange.
1835
1836         * UIProcess/WebPageProxy.cpp:
1837         (WebKit::WebPageProxy::WebPageProxy):
1838         Initialize the minimum layout width.
1839
1840         (WebKit::WebPageProxy::setMinimumLayoutWidth):
1841         Update the minimum layout width and call the drawing area proxy.
1842
1843         * UIProcess/WebPageProxy.h:
1844         (WebKit::WebPageProxy::minimumLayoutWidth):
1845         Add getter.
1846
1847         * UIProcess/mac/TiledCoreAnimationDrawingAreaProxy.h:
1848         (TiledCoreAnimationDrawingAreaProxy):
1849         * UIProcess/mac/TiledCoreAnimationDrawingAreaProxy.mm:
1850         (WebKit::TiledCoreAnimationDrawingAreaProxy::minimumLayoutWidthDidChange):
1851         Update the geometry if needed.
1852
1853         (WebKit::TiledCoreAnimationDrawingAreaProxy::didUpdateGeometry):
1854         Update the intrinsic content size.
1855
1856         (WebKit::TiledCoreAnimationDrawingAreaProxy::intrinsicContentSizeDidChange):
1857         Call through to WebPageProxy::intrinsicContentSizeDidChange.
1858
1859         (WebKit::TiledCoreAnimationDrawingAreaProxy::sendUpdateGeometry):
1860         Pass along the minimum layout width.
1861
1862         * UIProcess/mac/WebPageProxyMac.mm:
1863         (WebKit::WebPageProxy::intrinsicContentSizeDidChange):
1864         Call through to the page client.
1865
1866         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
1867         (WebKit::WebChromeClient::contentsSizeChanged):
1868         Call DrawingArea::mainFrameContentSizeChanged.
1869
1870         * WebProcess/WebPage/DrawingArea.h:
1871         (WebKit::DrawingArea::mainFrameContentSizeChanged):
1872         Add empty stub.
1873
1874         (WebKit::DrawingArea::updateGeometry):
1875         Update signature.
1876
1877         * WebProcess/WebPage/DrawingArea.messages.in:
1878         Add minimumLayoutWidth to UpdateGeometry.
1879
1880         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.h:
1881         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
1882         (WebKit::TiledCoreAnimationDrawingArea::mainFrameContentSizeChanged):
1883         If the content size change is not coming from updateGeometry, send an InstrinsicContentSizeDidChange message.
1884
1885         (WebKit::TiledCoreAnimationDrawingArea::updateGeometry):
1886         If m_minimumLayoutWidth is positive, do an initial layout pass to figure out the height of the page and then do another
1887         layout with the viewport set to that height.
1888
1889 2012-11-29  Anders Carlsson  <andersca@apple.com>
1890
1891         CoreIPC::Connection should retain its xpc_connection_t
1892         https://bugs.webkit.org/show_bug.cgi?id=103671
1893         <rdar://problem/12717331>
1894
1895         Reviewed by Beth Dakin.
1896
1897         * Platform/CoreIPC/mac/ConnectionMac.cpp:
1898         (CoreIPC::Connection::platformInitialize):
1899         Retain the xpc_connection_t object here to balance the xpc_object_release in platformInvalidate.
1900
1901 2012-11-29  Brent Fulgham  <bfulgham@webkit.org>
1902
1903         [Windows, WinCairo] Unreviewed build fix.  Build was failing
1904         because the export definition file included a debug-only
1905         symbol.  It's not needed and shouldn't be included for export.
1906
1907         * win/WebKit2.def: Don't require notSolidColor to be exported.
1908         * win/WebKit2CFLite.def: Ditto.
1909
1910 2012-11-29  Tim Horton  <timothy_horton@apple.com>
1911
1912         PDFPlugin: Only plain text can be copied out of PDFs
1913         https://bugs.webkit.org/show_bug.cgi?id=103591
1914         <rdar://problem/12555161>
1915
1916         Reviewed by Alexey Proskuryakov.
1917
1918         Enable rich data to be copied from PDFKit to the pasteboard.
1919
1920         * WebProcess/Plugins/PDF/PDFPlugin.h:
1921         (PDFPlugin): Add writeItemsToPasteboard.
1922         * WebProcess/Plugins/PDF/PDFPlugin.mm:
1923         (-[WKPDFLayerControllerDelegate writeItemsToPasteboard:withTypes:]): Move implementation to PDFPlugin.
1924         (WebKit::PDFPlugin::writeItemsToPasteboard): Don't round-trip through WebCore for pasteboard operations,
1925         use WebContext directly. This provides a simple way to hand over a buffer for complex pasteboard types
1926         (RTF, HTML, etc.). Use this interface for arbitrary non-plain-text pasteboard data that PDFKit hands us.
1927
1928 2012-11-29  Martin Robinson  <mrobinson@igalia.com>
1929
1930         [GTK] [WebKit2] Embed the HTTP authentication dialog into the WebView
1931         https://bugs.webkit.org/show_bug.cgi?id=103277
1932
1933         Reviewed by Carlos Garcia Campos.
1934
1935         Embed the WebKit2 HTTP authentication dialog into the WebView. Add the dialog as a child
1936         of the WebKitWebViewBase container (like the web inspector).
1937
1938         We do not yet properly handle pages that require authentication for more than one resource.
1939         As that is an uncommon situation, it will be handled in another patch.
1940
1941         * UIProcess/API/gtk/WebKit2GtkAuthenticationDialog.cpp:
1942         (WebKit::drawSignal): We have to override the draw signal of the dialog to draw
1943         a GtkWindow background on the widget. This is required because the widget doesn't
1944         have a real GtkWindow to draw its background.
1945         (WebKit::loadChangedSignal): When a new load starts in the WebView destroy the dialog. This
1946         is so that the dialog doesn't stick around when the user chooses to navigate away from the
1947         page requiring authentication.
1948         (WebKit::WebKit2GtkAuthenticationDialog::WebKit2GtkAuthenticationDialog): Create an eventbox
1949         and frame to hold the dialog contents. Also append the 'background' widget class to the
1950         event box, so that it can draw a GtkWindow background in the draw signal handler.
1951         (WebKit::WebKit2GtkAuthenticationDialog::~WebKit2GtkAuthenticationDialog): Disconnect the
1952         load status changed signal handler.
1953         (WebKit::WebKit2GtkAuthenticationDialog::show): When it's time to show the dialog, add it to
1954         WebKitWebViewBase.
1955         * UIProcess/API/gtk/WebKit2GtkAuthenticationDialog.h: Add some new methods for handling the
1956         embedded dialog.
1957         * UIProcess/API/gtk/WebKitLoaderClient.cpp:
1958         (didReceiveAuthenticationChallengeInFrame): Collapse the creation of the dialog into one line.
1959         * UIProcess/API/gtk/WebKitWebViewBase.cpp:
1960         (_WebKitWebViewBasePrivate): Add the dialog as a property of the private structure.
1961         (webkitWebViewChildIsInternalWidget): Added this helper used for determining when a child widget
1962         is "internal" (ie the web inspector or the authentication dialog).
1963         (webkitWebViewBaseContainerAdd): Only add non-internal widgets to the children map.
1964         (webkitWebViewBaseAddAuthenticationDialog): Added.
1965         (webkitWebViewBaseAddWebInspector): Added this more-foolproof method of adding a web inspector
1966         to the WebView. This also aligns it with the way the authentication dialog is added.
1967         (webkitWebViewBaseContainerRemove): When removing the authentication dialog, zero out the
1968         field in the private structure.
1969         (webkitWebViewBaseContainerForall): Add support for the authentication dialog here too.
1970         (webkitWebViewBaseChildMoveResize): Don't pass on move_resize events to internal children.
1971         (webkit_web_view_base_init): Zero out the authentication dialog member on init.
1972         (webkitWebViewBaseDraw): If the authentication dialog is active, draw a shadow over web content.
1973         (resizeWebKitWebViewBaseFromAllocation): Make the authentication dialog centered in the view.
1974         (webkitWebViewBaseKeyPressEvent): Pass on key events to the authentication dialog if active.
1975         (webkitWebViewBaseButtonPressEvent): If the authentication dialog is active don't pass button events
1976         to web content.
1977         (webkitWebViewBaseButtonReleaseEvent):  Ditto.
1978         (webkitWebViewBaseScrollEvent): Ditto.
1979         (webkitWebViewBaseMotionNotifyEvent): Ditto.
1980         (webkitWebViewBaseFocus): Pass on focus events to the authentication dialog so that tabbing between
1981         elements in the dialog works correctly.
1982         (webkit_web_view_base_class_init): Hook up the focus event.
1983         * UIProcess/API/gtk/WebKitWebViewBasePrivate.h: Add new methods for adding the authentication dialog
1984         and the web inspector.
1985         * UIProcess/gtk/WebInspectorProxyGtk.cpp:
1986         (WebKit::WebInspectorProxy::createInspectorWindow): Use the new method for adding the web inspector.
1987
1988 2012-11-29  Andrei Bucur  <abucur@adobe.com>
1989
1990         Fix the build after r136095
1991         https://bugs.webkit.org/show_bug.cgi?id=103629
1992
1993         Unreviewed.
1994
1995         Add a static_cast to fix the build.
1996
1997         * Shared/mac/ObjCObjectGraphCoders.mm:
1998         (WebKit::ObjCObjectGraphEncoder::baseEncode):
1999
2000 2012-11-29  Christophe Dumez  <christophe.dumez@intel.com>
2001
2002         [CoordinatedGraphics] Have LayerTreeRenderer::ensureLayer() return the layer
2003         https://bugs.webkit.org/show_bug.cgi?id=103645
2004
2005         Reviewed by Noam Rosenthal.
2006
2007         The current LayerTreeRenderer code keep calling ensureLayer() and then
2008         LayerMap::find() to retrieve the layer. Since ensureLayer() already has
2009         a pointer to the layer, we can simply have the function return it.
2010         This is slightly more efficient and it makes the code a bit simpler.
2011
2012         * UIProcess/CoordinatedGraphics/LayerTreeRenderer.cpp:
2013         (WebKit::LayerTreeRenderer::setLayerChildren):
2014         (WebKit::LayerTreeRenderer::setLayerFilters):
2015         (WebKit::LayerTreeRenderer::setLayerState):
2016         (WebKit::LayerTreeRenderer::ensureLayer):
2017         * UIProcess/CoordinatedGraphics/LayerTreeRenderer.h:
2018
2019 2012-11-29  Mikhail Pozdnyakov  <mikhail.pozdnyakov@intel.com>
2020
2021         [WK2] TiledBackingStore: User events are sent to web page before it is shown
2022         https://bugs.webkit.org/show_bug.cgi?id=101753
2023
2024         Reviewed by Jocelyn Turcotte.
2025
2026         User events are suppressed on WEB process side while drawing area is frozen.
2027
2028         * WebProcess/WebPage/WebPage.cpp:
2029         (WebKit::WebPage::mouseEvent):
2030         (WebKit::WebPage::wheelEvent):
2031         (WebKit::WebPage::keyEvent):
2032         (WebKit::WebPage::gestureEvent):
2033         (WebKit::WebPage::touchEvent):
2034         (WebKit::WebPage::sendIfEventCannotBeHandled):
2035         (WebKit):
2036         (WebKit::WebPage::didCompletePageTransition):
2037         * WebProcess/WebPage/WebPage.h:
2038         (WebPage):
2039
2040 2012-11-29  Allan Sandfeld Jensen  <allan.jensen@digia.com>
2041
2042         Possible to resize out of bounds 
2043         https://bugs.webkit.org/show_bug.cgi?id=103521
2044
2045         Reviewed by Jocelyn Turcotte.
2046
2047         Enforce the viewportBounds after resize, and ensure a user fitted page remains
2048         fit on viewport resize, but not on content growth.
2049
2050         * UIProcess/API/qt/tests/qmltests/WebView/tst_resize.qml: Added.
2051         * UIProcess/PageViewportController.cpp:
2052         (WebKit::PageViewportController::didChangeContentsSize):
2053         (WebKit::PageViewportController::didChangeViewportAttributes):
2054         (WebKit::PageViewportController::updateMinimumScaleToFit):
2055         * UIProcess/PageViewportController.h:
2056         (PageViewportController):
2057
2058 2012-11-29  Michael Brüning  <michael.bruning@digia.com>
2059
2060         [Qt][WK2] Commit the preedit string in the input method when focus is about to be moved.
2061         https://bugs.webkit.org/show_bug.cgi?id=97774
2062
2063         Reviewed by Kenneth Rohde Christiansen.
2064
2065         Implements the handler for willSetInputMethodState in WebKit2 in Qt.
2066         This is needed to tell the input method instance in Qt to commit its
2067         preedit content when the focus has moved to another node to prevent a
2068         bug where the old preedit string was kept as the preedit string and
2069         the editor moved focus back to the old node when continuing to enter
2070         text via the input method.
2071
2072         This behavior is analog to the behavior of the QtQuick text input
2073         elements.
2074
2075         * UIProcess/API/qt/raw/qrawwebview.cpp:
2076         (QRawWebViewPrivate::handleWillSetInputMethodState):
2077         * UIProcess/API/qt/raw/qrawwebview_p_p.h:
2078         (QRawWebViewPrivate):
2079         * UIProcess/PageClient.h:
2080         (PageClient):
2081         * UIProcess/WebPageProxy.h:
2082         (WebPageProxy):
2083         * UIProcess/WebPageProxy.messages.in:
2084         * UIProcess/qt/QtPageClient.cpp:
2085         (WebKit::QtPageClient::handleWillSetInputMethodState):
2086         (WebKit):
2087         * UIProcess/qt/QtPageClient.h:
2088         (QtPageClient):
2089         * UIProcess/qt/QtWebPageEventHandler.cpp:
2090         (WebKit::QtWebPageEventHandler::handleWillSetInputMethodState):
2091         (WebKit):
2092         * UIProcess/qt/QtWebPageEventHandler.h:
2093         (QtWebPageEventHandler):
2094         * UIProcess/qt/WebPageProxyQt.cpp:
2095         (WebKit::WebPageProxy::willSetInputMethodState):
2096         (WebKit):
2097         * WebProcess/WebCoreSupport/WebEditorClient.cpp:
2098         (WebKit::WebEditorClient::willSetInputMethodState):
2099
2100 2012-11-28  Jocelyn Turcotte  <jocelyn.turcotte@digia.com>
2101
2102         [Qt] The WebView should be flickable only using touch events
2103         https://bugs.webkit.org/show_bug.cgi?id=100964
2104
2105         Reviewed by Kenneth Rohde Christiansen.
2106
2107         Let a user interacting with the WebView using a mouse the same way that a
2108         desktop browser would.
2109         This allows normal behaviors like text selecting, hover events, mouse cursors
2110         as well as avoid touch highlighting and touch adjustment.
2111
2112         To do so we let all mouse events to be handled by the page directly instead
2113         of sending them to QtWebPageEventHandler. Since unhandled mouse events aren't
2114         pushed back to the PageClient like touch events does, this have the intended
2115         behavior of not letting mouse events affect QQuickFlickable.
2116
2117         * UIProcess/API/qt/qquickwebview.cpp:
2118         * UIProcess/API/qt/qquickwebview_p_p.h:
2119         (QQuickWebViewFlickablePrivate):
2120
2121 2012-11-29  Andras Becsi  <andras.becsi@digia.com>
2122
2123         [Qt] Fix installation of QtWebProcess binary
2124         https://bugs.webkit.org/show_bug.cgi?id=101735
2125
2126         Reviewed by Simon Hausmann.
2127
2128         If available use QLibraryInfo::LibraryExecutablesPath to find
2129         the web process and the plugin process and deploy both helper
2130         processes to QT_INSTALL_LIBEXECS.
2131
2132         The effective fallback used to find the helper processes becomes:
2133             1. Application directory
2134             2. Qt library executables directory (QLibraryInfo::LibraryExecutablesPath)
2135             3. Qt binaries directory (QLibraryInfo::BinariesPath)
2136             4. No absolute path used
2137
2138         * PluginProcess.pro:
2139         * Shared/qt/ProcessExecutablePathQt.cpp:
2140         (WebKit::executablePath):
2141         * WebProcess.pro:
2142
2143 2012-11-28  Ryuan Choi  <ryuan.choi@gmail.com>
2144
2145         [EFL] Generate big_button_theme.edj
2146         https://bugs.webkit.org/show_bug.cgi?id=103511
2147
2148         Reviewed by Gyuyoung Kim.
2149
2150         * UIProcess/API/efl/tests/UnitTestUtils/EWK2UnitTestEnvironment.cpp:
2151         (EWK2UnitTest::EWK2UnitTestEnvironment::pathForTheme):
2152         (EWK2UnitTest):
2153         * UIProcess/API/efl/tests/UnitTestUtils/EWK2UnitTestEnvironment.h:
2154         (EWK2UnitTestEnvironment):
2155         * UIProcess/API/efl/tests/resources/big_button_theme.edj: Removed.
2156         * UIProcess/API/efl/tests/test_ewk2_view.cpp: Modified to use generated big_button_theme.edj
2157         (TEST_F):
2158
2159 2012-11-28  Sheriff Bot  <webkit.review.bot@gmail.com>
2160
2161         Unreviewed, rolling out r135973.
2162         http://trac.webkit.org/changeset/135973
2163         https://bugs.webkit.org/show_bug.cgi?id=103604
2164
2165         It made API test crash on EFL bots (Requested by gyuyoung on
2166         #webkit).
2167
2168         * UIProcess/API/efl/ewk_view.cpp:
2169         (createEwkView):
2170
2171 2012-11-28  Michael Pruett  <michael@68k.org>
2172
2173         IndexedDB: Remove duplicate toWireString() and createFromWire() methods in JSC SerializedScriptValue
2174         https://bugs.webkit.org/show_bug.cgi?id=103554
2175
2176         Reviewed by Kentaro Hara.
2177
2178         In r135022, duplicate createFromWire() and toWireString() methods
2179         were added to the JSC version of SerializedScriptValue. In
2180         order to allow the JSC SerializedScriptValue to compile when
2181         ENABLE(INDEXED_DATABASE) is turned on, these new methods have
2182         been removed and the old methods have been moved outside the
2183         ENABLE(INDEXED_DATABASE) guard.
2184
2185         * win/WebKit2.def:
2186         * win/WebKit2CFLite.def:
2187
2188 2012-11-28  Sam Weinig  <sam@webkit.org>
2189
2190         Fix 32bit build.
2191
2192         * Shared/mac/ObjCObjectGraphCoders.mm:
2193         (WebKit::WebContextObjCObjectGraphDecoderImpl::decode):
2194         (WebKit::InjectedBundleObjCObjectGraphDecoderImpl::decode):
2195
2196 2012-11-28  Sam Weinig  <sam@webkit.org>
2197
2198         Add an objc object graph wrapper and coder for WKConnection message bodies
2199         https://bugs.webkit.org/show_bug.cgi?id=103589
2200
2201         Reviewed by Anders Carlsson.
2202
2203         Adds a new type of UserMessageCoder for objc object graphs that allows encoding/decoding
2204         WKBrowsingContextController across the wire.
2205
2206         * Shared/APIClient.h:
2207         (APIClient):
2208         (WebKit::APIClient::client):
2209         Add accessor for the ClientInterface.
2210
2211         * Shared/APIObject.h:
2212         Add new TypeObjCObjectGraph type.
2213
2214         * Shared/mac/ObjCObjectGraph.h: Added.
2215         (ObjCObjectGraph):
2216         (WebKit::ObjCObjectGraph::create):
2217         (WebKit::ObjCObjectGraph::root):
2218         (WebKit::ObjCObjectGraph::ObjCObjectGraph):
2219         (WebKit::ObjCObjectGraph::type):
2220         * Shared/mac/ObjCObjectGraph.mm: Added.
2221         Wraps 
2222
2223         * Shared/mac/ObjCObjectGraphCoders.h: Added.
2224         (WebContextObjCObjectGraphEncoder):
2225         (WebContextObjCObjectGraphDecoder):
2226         (InjectedBundleObjCObjectGraphEncoder):
2227         (InjectedBundleObjCObjectGraphDecoder):
2228         * Shared/mac/ObjCObjectGraphCoders.mm: Added.
2229         (WebKit::typeFromObject):
2230         (ObjCObjectGraphEncoder):
2231         (WebKit::ObjCObjectGraphEncoder::baseEncode):
2232         (WebKit::ObjCObjectGraphEncoder::ObjCObjectGraphEncoder):
2233         (ObjCObjectGraphDecoder):
2234         (WebKit::ObjCObjectGraphDecoder::baseDecode):
2235         (WebKit::ObjCObjectGraphDecoder::ObjCObjectGraphDecoder):
2236         (WebContextObjCObjectGraphEncoderImpl):
2237         (WebKit::WebContextObjCObjectGraphEncoderImpl::WebContextObjCObjectGraphEncoderImpl):
2238         (WebKit::WebContextObjCObjectGraphEncoderImpl::encode):
2239         (WebContextObjCObjectGraphDecoderImpl):
2240         (WebKit::WebContextObjCObjectGraphDecoderImpl::WebContextObjCObjectGraphDecoderImpl):
2241         (WebKit::WebContextObjCObjectGraphDecoderImpl::decode):
2242         (InjectedBundleObjCObjectGraphEncoderImpl):
2243         (WebKit::InjectedBundleObjCObjectGraphEncoderImpl::InjectedBundleObjCObjectGraphEncoderImpl):
2244         (WebKit::InjectedBundleObjCObjectGraphEncoderImpl::encode):
2245         (InjectedBundleObjCObjectGraphDecoderImpl):
2246         (WebKit::InjectedBundleObjCObjectGraphDecoderImpl::InjectedBundleObjCObjectGraphDecoderImpl):
2247         (WebKit::InjectedBundleObjCObjectGraphDecoderImpl::decode):
2248         (WebKit::WebContextObjCObjectGraphEncoder::WebContextObjCObjectGraphEncoder):
2249         (WebKit::WebContextObjCObjectGraphEncoder::encode):
2250         (WebKit::WebContextObjCObjectGraphDecoder::WebContextObjCObjectGraphDecoder):
2251         (WebKit::WebContextObjCObjectGraphDecoder::decode):
2252         (WebKit::InjectedBundleObjCObjectGraphEncoder::InjectedBundleObjCObjectGraphEncoder):
2253         (WebKit::InjectedBundleObjCObjectGraphEncoder::encode):
2254         (WebKit::InjectedBundleObjCObjectGraphDecoder::InjectedBundleObjCObjectGraphDecoder):
2255         (WebKit::InjectedBundleObjCObjectGraphDecoder::decode):
2256         Added.
2257
2258         * UIProcess/API/mac/WKBrowsingContextController.mm:
2259         (+[WKBrowsingContextController _browsingContextControllerForPageRef:]):
2260         * UIProcess/API/mac/WKBrowsingContextControllerInternal.h:
2261         Expose the accessor to get the WKPageRef from a WKBrowsingContextController and add a 
2262         new method to get a WKBrowsingContextController from a WKPageRef.
2263
2264         * UIProcess/API/mac/WKConnection.mm:
2265         (-[WKConnection sendMessageWithName:body:]):
2266         (didReceiveMessage):
2267         Switch WKConnection to use ObjCObjectGraph to encode the messageBody.
2268
2269         * UIProcess/WebContextUserMessageCoders.h:
2270         (WebKit::WebContextUserMessageEncoder::encode):
2271         (WebKit::WebContextUserMessageDecoder::decode):
2272         * WebProcess/InjectedBundle/InjectedBundleUserMessageCoders.h:
2273         (WebKit::InjectedBundleUserMessageEncoder::encode):
2274         (WebKit::InjectedBundleUserMessageDecoder::decode):
2275         Proxy to ObjCObjectGraph coders when user message encoding/decoding ObjCObjectGraph APIObjects.
2276
2277         * WebProcess/InjectedBundle/API/mac/WKWebProcessPlugIn.mm:
2278         (-[WKWebProcessPlugInController _browserContextControllerForBundlePageRef:]):
2279         * WebProcess/InjectedBundle/API/mac/WKWebProcessPlugInInternal.h:
2280         Add method to get WKWebProcessPlugInController from the WKBundlePageRef.
2281
2282         * WebKit2.xcodeproj/project.pbxproj:
2283         Add new files.
2284
2285 2012-11-28  Sergio Villar Senin  <svillar@igalia.com>
2286
2287         [WK2][Qt] Add drag&drop support to Flickable webView
2288         https://bugs.webkit.org/show_bug.cgi?id=100778
2289
2290         Reviewed by Jocelyn Turcotte.
2291
2292         Enable the ItemAcceptsDrops flag in the flickable WebView. This
2293         will allow the WebView to receive drag&drop events.
2294
2295         * UIProcess/API/qt/qquickwebview.cpp:
2296         (QQuickWebViewPrivate::initialize):
2297
2298 2012-11-28  Shinya Kawanaka  <shinyak@chromium.org>
2299
2300         [Shadow] Move Distribution stuffs from ShadowRoot
2301         https://bugs.webkit.org/show_bug.cgi?id=103481
2302
2303         Reviewed by Hajime Morita.
2304
2305         * win/WebKit2.def:
2306         * win/WebKit2CFLite.def:
2307
2308 2012-11-28  Tim Horton  <timothy_horton@apple.com>
2309
2310         [mac] Dictionary lookup bubble loses intrarange formatting
2311         https://bugs.webkit.org/show_bug.cgi?id=103496
2312         <rdar://problem/12762172>
2313
2314         Reviewed by Alexey Proskuryakov.
2315
2316         Pass an NSAttributedString (made via WebHTMLConverter on the WebProcess side) through
2317         when showing dictionary popups, so that we preserve more formatting in the yellow dictionary
2318         highlight. Also, remove the fontInfo member from DictionaryPopupInfo, since we don't need it anymore.
2319
2320         * Shared/DictionaryPopupInfo.cpp:
2321         (WebKit::DictionaryPopupInfo::encode): Don't encode the now-removed fontInfo member.
2322         (WebKit::DictionaryPopupInfo::decode): Don't decode the now-removed fontInfo member.
2323         * Shared/DictionaryPopupInfo.h: Remove the fontInfo member.
2324         * UIProcess/API/mac/PageClientImpl.h:
2325         (PageClientImpl): didPerformDictionaryLookup should take an AttributedString instead of a plain String, and
2326         no longer needs to take the page scale factor.
2327         * UIProcess/API/mac/PageClientImpl.mm:
2328         (WebKit::PageClientImpl::didPerformDictionaryLookup): Use the AttributedString we're handed from the WebProcess
2329         instead of constructing one ourselves; this way, we have all the attributes instead of just a single font.
2330         * UIProcess/PageClient.h:
2331         (PageClient): didPerformDictionaryLookup should take an AttributedString instead of a plain String.
2332         * UIProcess/WebPageProxy.h:
2333         (WebPageProxy): didPerformDictionaryLookup should take an AttributedString instead of a plain String.
2334         * UIProcess/WebPageProxy.messages.in: DidPerformDictionaryLookup should take an AttributedString instead of a plain String.
2335         * UIProcess/mac/WebPageProxyMac.mm:
2336         (WebKit::WebPageProxy::didPerformDictionaryLookup): didPerformDictionaryLookup should take an AttributedString instead of a plain String.
2337         * WebProcess/WebPage/mac/WebPageMac.mm:
2338         (WebKit::WebPage::performDictionaryLookupForRange): performDictionaryLookupForRange should hand WebPageProxy an AttributedString
2339         constructed via WebHTMLConverter instead of a plain text string paired with a single font descriptor.
2340         Also, scale the size of every font attribute by the current pageScaleFactor.
2341
2342 2012-11-28  peavo@outlook.com  <peavo@outlook.com>
2343
2344         [WinCairo] Crash when requesting favicon.
2345         https://bugs.webkit.org/show_bug.cgi?id=102689
2346
2347         Reviewed by Brent Fulgham.
2348
2349         * win/WebKit2CFLite.def: Link fixes.
2350         * win/WebKit2.def: Link fixes.
2351
2352 2012-11-28  Christophe Dumez  <christophe.dumez@intel.com>
2353
2354         Regression(r135962): m_pendingSyncBackingStores needs to be cleared in LayerTreeRenderer::purgeGLResources()
2355         https://bugs.webkit.org/show_bug.cgi?id=103527
2356
2357         Reviewed by Jocelyn Turcotte.
2358
2359         Make sure m_pendingSyncBackingStores is cleared in
2360         LayerTreeRenderer::purgeGLResources() to avoid trying to assign
2361         backing store to layers after everything has been invalidated.
2362
2363         * UIProcess/CoordinatedGraphics/LayerTreeRenderer.cpp:
2364         (WebKit::LayerTreeRenderer::purgeGLResources):
2365
2366 2012-11-28  Christophe Dumez  <christophe.dumez@intel.com>
2367
2368         Regression(r135962): ASSERTION FAILED: !m_pedningSyncBackingStores.contains(layer)
2369         https://bugs.webkit.org/show_bug.cgi?id=103498
2370
2371         Reviewed by Kenneth Rohde Christiansen.
2372
2373         We hit the !m_pedningSyncBackingStores.contains(layer) assertion
2374         in LayerTreeRenderer when 2 asynchronous backing store operations
2375         are pending. The current code checks if the layer already has a
2376         backing store in its guard but this is insufficient as it is not
2377         checking the m_pendingSyncBackingStores hash for pending backing
2378         store changes.
2379
2380         In this patch, we improve the guards in createBackingStoreIfNeeded()
2381         and removeBackingStoreIfNeeded() to check not only if the layer has
2382         already a backing store but also check m_pendingSyncBackingStores
2383         for pending changes. This is safer and it allows for optimizations
2384         in the cases where we have both a removal and a creation pending.
2385         In those cases, we can simply cancel the pending operation instead
2386         of queueing a new one.
2387
2388         * UIProcess/CoordinatedGraphics/LayerTreeRenderer.cpp:
2389         (WebKit::LayerTreeRenderer::getBackingStore):
2390         (WebKit::LayerTreeRenderer::createBackingStoreIfNeeded):
2391         (WebKit::LayerTreeRenderer::removeBackingStoreIfNeeded):
2392         (WebKit::LayerTreeRenderer::commitPendingBackingStoreOperations):
2393         * UIProcess/CoordinatedGraphics/LayerTreeRenderer.h:
2394
2395 2012-11-28  Kenneth Rohde Christiansen  <kenneth@webkit.org>
2396
2397         [EFL][WK2] MiniBrowser rendering should not get blurry when scrolled down with different scale values
2398         https://bugs.webkit.org/show_bug.cgi?id=103079
2399
2400         Reviewed by Simon Hausmann.
2401
2402         The problem was caused because we moved the page inside our viewport
2403         in non-discrete units.
2404
2405         Now instead of changing the content visible in our viewport by
2406         applying scale, and then transforming the CSS offset, we now first
2407         discretely position the page in UI coordinates.
2408
2409         This patch also removes some dead code.
2410
2411         * UIProcess/API/efl/EwkViewImpl.cpp:
2412         (EwkViewImpl::transformFromScene):
2413         (EwkViewImpl::displayTimerFired):
2414
2415            Transform according to the page position.
2416
2417         * UIProcess/API/efl/EwkViewImpl.h:
2418         (EwkViewImpl::setPagePosition): Now stores a float.
2419         (EwkViewImpl::discretePagePosition): Returns the discrete page position.
2420         (EwkViewImpl):
2421         * UIProcess/efl/PageClientLegacyImpl.cpp:
2422         (WebKit::PageClientLegacyImpl::updateViewportSize):
2423         (WebKit::PageClientLegacyImpl::pageDidRequestScroll):
2424         * UIProcess/efl/PageViewportControllerClientEfl.cpp:
2425         (WebKit::PageViewportControllerClientEfl::PageViewportControllerClientEfl):
2426         (WebKit::PageViewportControllerClientEfl::setViewportPosition): Convert to page position.
2427         (WebKit::PageViewportControllerClientEfl::setContentsScale):
2428         (WebKit::PageViewportControllerClientEfl::didResumeContent):
2429         * UIProcess/efl/PageViewportControllerClientEfl.h:
2430         (WebKit::PageViewportControllerClientEfl::scaleFactor): Use the value
2431         from the view directly.
2432         (WebKit::PageViewportControllerClientEfl::contentPosition):
2433         (PageViewportControllerClientEfl):
2434
2435 2012-11-28  Mikhail Pozdnyakov  <mikhail.pozdnyakov@intel.com>
2436
2437         [EFL][WK2][AC] No need to export GL properties from EwkViewImpl class
2438         https://bugs.webkit.org/show_bug.cgi?id=103505
2439
2440         Reviewed by Kenneth Rohde Christiansen.
2441
2442         No need to export GL data members from EwkViewImpl class, 
2443         those are internal implementation objects not used by anyone outside the class.
2444
2445         * UIProcess/API/efl/EwkViewImpl.cpp:
2446         (EwkViewImpl::displayTimerFired):
2447         (EwkViewImpl::createGLSurface):
2448         * UIProcess/API/efl/EwkViewImpl.h:
2449         (EwkViewImpl):
2450         (EwkViewImpl::evasGLContext):
2451         (EwkViewImpl::evasGLSurface):
2452
2453 2012-11-28  Joone Hur  <joone.hur@intel.com>
2454
2455         [EFL][WK2][AC] Clear the viewport with white color
2456         https://bugs.webkit.org/show_bug.cgi?id=103495
2457
2458         When initializing a GL surface, we should clear the buffer with white color.
2459
2460         Reviewed by Kenneth Rohde Christiansen.
2461
2462         * UIProcess/API/efl/EwkViewImpl.cpp:
2463         (EwkViewImpl::createGLSurface):
2464
2465 2012-11-27  Jinwoo Song  <jinwoo7.song@samsung.com>
2466
2467         [EFL][WK2] Duplicated WebPageGroup initialization
2468         https://bugs.webkit.org/show_bug.cgi?id=103229
2469
2470         Reviewed by Gyuyoung Kim.
2471
2472         WebPageGroup does not need to be created in creating EwkView when the pageGroupRef is 0
2473         because the default WebPageGroup(m_defaultPageGroup) is created in WebContext constructor.
2474
2475         As a side effect on the duplicated initialization, pageGroupID increases even when the EwkView
2476         is created with default context.
2477
2478         * UIProcess/API/efl/ewk_view.cpp:
2479         (createEwkView):
2480
2481 2012-11-27  Huang Dongsung  <luxtella@company100.net>
2482
2483         REGRESSION(r135620): ASSERT(m_state.drawsContent && m_state.contentsVisible && !m_size.isEmpty()) hits in TextureMapperLayer::paintSelf().
2484         https://bugs.webkit.org/show_bug.cgi?id=103171
2485
2486         Reviewed by Noam Rosenthal.
2487
2488         Ensure that TextureMapperLayer has a backing store when the layer has
2489         drawsContent and contentsVisible properties and the size of the layer is not
2490         empty.
2491
2492         LayerTreeRenderer::setLayerState() must not set a backing store to
2493         TextureMapperLayer because setLayerState() just changes states of
2494         GraphicsLayerTextureMapper instead of TextureMapperLayer.
2495
2496         Now LayerTreeRenderer::flushLayerChanges() sets a backing store as well as layer
2497         states to TextureMapperLayer.
2498
2499         * UIProcess/CoordinatedGraphics/LayerTreeRenderer.cpp:
2500         (WebKit::LayerTreeRenderer::getBackingStore):
2501         (WebKit::LayerTreeRenderer::prepareContentBackingStore):
2502         (WebKit::LayerTreeRenderer::createBackingStoreIfNeeded):
2503         (WebKit::LayerTreeRenderer::removeBackingStoreIfNeeded):
2504         (WebKit::LayerTreeRenderer::commitPendingBackingStoreOperations):
2505         (WebKit::LayerTreeRenderer::flushLayerChanges):
2506         * UIProcess/CoordinatedGraphics/LayerTreeRenderer.h:
2507         (WebCore):
2508
2509 2012-11-27  Tim Horton  <timothy_horton@apple.com>
2510
2511         PDFPlugin: Should not be able to edit read-only text annotations
2512         https://bugs.webkit.org/show_bug.cgi?id=103387
2513         <rdar://problem/12752313>
2514
2515         Reviewed by Alexey Proskuryakov.
2516
2517         Don't allow read-only annotations to become active.
2518
2519         * WebKit2.xcodeproj/project.pbxproj: Add PDFAnnotationTextWidgetDetails.h.
2520         * WebProcess/Plugins/PDF/PDFAnnotationTextWidgetDetails.h: Added.
2521         * WebProcess/Plugins/PDF/PDFPlugin.mm:
2522         (WebKit::PDFPlugin::setActiveAnnotation): Bail if the annotation is read-only.
2523         * WebProcess/Plugins/PDF/PDFPluginTextAnnotation.mm: Move PDFAnnotationTextWidget details category to PDFAnnotationTextWidgetDetails.h
2524
2525 2012-11-27  Huang Dongsung  <luxtella@company100.net>
2526
2527         Coordinated Graphics: Refactor code managing a backing store in LayerTreeRenderer.
2528         https://bugs.webkit.org/show_bug.cgi?id=103298
2529
2530         Reviewed by Noam Rosenthal.
2531
2532         This patch makes LayerTreeRenderer assign a content backing store to
2533         TextureMapperLayer only in setLayerState(). Currently, createTile() can assign
2534         the backing store to TextureMapperLayer and it can break the invariant condition
2535         of TextureMapperLayer: TextureMapperLayer can have its own backing store only if
2536         the layer has following conditions: drawsContent, contentsVisible and non empty
2537         size.
2538
2539         In addition, the modified code about creating and removing a backing store
2540         matches the same purpose code of CoordinatedGraphicsLayer and
2541         GraphicsLayerTextureMapepr.
2542
2543         * UIProcess/CoordinatedGraphics/CoordinatedBackingStore.cpp:
2544         * UIProcess/CoordinatedGraphics/CoordinatedBackingStore.h:
2545         (CoordinatedBackingStore):
2546         * UIProcess/CoordinatedGraphics/LayerTreeRenderer.cpp:
2547         (WebKit::layerShouldHaveBackingStore):
2548         (WebKit):
2549         (WebKit::LayerTreeRenderer::setLayerState):
2550         (WebKit::LayerTreeRenderer::getBackingStore):
2551         (WebKit::LayerTreeRenderer::prepareContentBackingStore):
2552         (WebKit::LayerTreeRenderer::createBackingStoreIfNeeded):
2553         (WebKit::LayerTreeRenderer::removeBackingStore):
2554         (WebKit::LayerTreeRenderer::resetBackingStoreSizeToLayerSize):
2555         (WebKit::LayerTreeRenderer::createTile):
2556         (WebKit::LayerTreeRenderer::removeTile):
2557         (WebKit::LayerTreeRenderer::updateTile):
2558         * UIProcess/CoordinatedGraphics/LayerTreeRenderer.h:
2559         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedGraphicsLayer.cpp:
2560         (WebCore::CoordinatedGraphicsLayer::adjustContentsScale):
2561             This method does not create a backing store anymore because flushCompositingStateForThisLayerOnly()
2562             can create a backing store if needed. Moreover, we must sync a layer state prior to creating a backing store
2563             after this patch, because LayerTreeRenderer::createTile() does not create a backing store anymore.
2564
2565 2012-11-27  James Simonsen  <simonjam@chromium.org>
2566
2567         Consolidate FrameLoader::load() into one function taking a FrameLoadRequest
2568         https://bugs.webkit.org/show_bug.cgi?id=102151
2569
2570         Reviewed by Adam Barth.
2571
2572         * WebProcess/Plugins/PluginView.cpp:
2573         (WebKit::PluginView::performFrameLoadURLRequest):
2574         * WebProcess/WebPage/WebPage.cpp:
2575         (WebKit::WebPage::loadURLRequest):
2576         (WebKit::WebPage::loadData):
2577
2578 2012-10-22  Jer Noble  <jer.noble@apple.com>
2579
2580         [WK2] [Mac] WebKit Full Screen API should use NSWindow full screen API.
2581         https://bugs.webkit.org/show_bug.cgi?id=100025
2582
2583         Reviewed by Dan Bernstein.
2584
2585         Use the NSWindow full screen API when taking the WebView full screen. To facility the case where the browser window is already
2586         in full screen mode, no longer hide the browser window when entering full screen. Instead, provide a placeholder view with 
2587         instructions to click the placeholder to exit full screen.
2588
2589         * UIProcess/mac/WKFullScreenWindowController.h:
2590         * UIProcess/mac/WKFullScreenWindowController.mm:
2591         (-[WKFullScreenWindowController init]): Set self as the window's delegate; enable window's full screen action.
2592         (-[WKFullScreenWindowController dealloc]): Clear our window's delegate.
2593         (-[WKFullScreenWindowController applicationDidChangeScreenParameters:]): Remove reference to _updateWindowAndDockForFullScreen.
2594         (-[WKFullScreenWindowController enterFullScreen:]):  Ditto. Create a WKFullScreenPlaceholderView instead of generic NSImageView.
2595         (-[WKFullScreenWindowController beganEnterFullScreenWithInitialFrame:finalFrame:]): Ditto. Call NSWindow enterFullScreen: API.
2596         (-[WKFullScreenWindowController finishedEnterFullScreenAnimation:]): Show the warning view.
2597         (-[WKFullScreenWindowController exitFullScreen]): Hide the warning view.
2598         (-[WKFullScreenWindowController beganExitFullScreenWithInitialFrame:finalFrame:]): Add special case where we are exiting
2599             from full screen mode when the full screen window is not on screen.
2600         (-[WKFullScreenWindowController finishedExitFullScreenAnimation:]): Remove reference to _updateMenuAndDockForFullScreen.
2601         (-[WKFullScreenWindowController customWindowsToEnterFullScreenForWindow:]): Added. Return the background window and the full screen window.
2602         (-[WKFullScreenWindowController customWindowsToExitFullScreenForWindow:]): Ditto.
2603         (-[WKFullScreenWindowController window:startCustomAnimationToEnterFullScreenWithDuration:]): Added. Call through to _startEnterFullScreenAnimationWithDuration:
2604         (-[WKFullScreenWindowController window:startCustomAnimationToExitFullScreenWithDuration:]): Added. Call through to _startExitFullScreenAnimationWithDuration:
2605
2606 2012-11-27  Yael Aharon  <yael.aharon@intel.com>
2607
2608         [EFL][WK2] 3D pixel tests are failing
2609         https://bugs.webkit.org/show_bug.cgi?id=102833
2610
2611         Reviewed by Kenneth Rohde Christiansen.
2612
2613         Added an API for generating a snapshot, to be used from WebKitTestRunner.
2614
2615         * PlatformEfl.cmake:
2616         * UIProcess/API/C/efl/WKView.cpp:
2617         (WKViewGetSnapshot):
2618         * UIProcess/API/C/efl/WKView.h:
2619         * UIProcess/API/efl/EwkViewImpl.cpp:
2620         (EwkViewImpl::onFaviconChanged):
2621         (EwkViewImpl::takeSnapshot):
2622         * UIProcess/API/efl/EwkViewImpl.h:
2623         (EwkViewImpl):
2624         * UIProcess/API/efl/SnapshotImageGL.cpp: Added.
2625         (getImageFromCurrentTexture):
2626         * UIProcess/API/efl/SnapshotImageGL.h: Added.
2627
2628 2012-11-27  Tim Horton  <timothy_horton@apple.com>
2629
2630         PDFPlugin: Page scale factor should affect subframe PDFs
2631         https://bugs.webkit.org/show_bug.cgi?id=103291
2632         <rdar://problem/12555249>
2633
2634         Reviewed by Darin Adler.
2635
2636         For subframe PDFs, hand PDFKit the pageScaleFactor for the parent page
2637         so it can scale its drawing appropriately.
2638
2639         * WebProcess/Plugins/PDF/PDFPlugin.h: Add updatePageAndDeviceScaleFactors.
2640         * WebProcess/Plugins/PDF/PDFPlugin.mm:
2641         (WebKit::PDFPlugin::pdfDocumentDidLoad): Call updatePageAndDeviceScaleFactors
2642         instead of manually updating PDFLayerController's device scale factor.
2643         (WebKit::PDFPlugin::updatePageAndDeviceScaleFactors): Hand PDFLayerController
2644         the "underlying" (non-zoom) content scale, which is the product of the
2645         device scale and the page scale.
2646         (WebKit::PDFPlugin::contentsScaleFactorChanged): Use updatePageAndDeviceScaleFactors.
2647         (WebKit::PDFPlugin::geometryDidChange): Use updatePageAndDeviceScaleFactors to keep
2648         PDFLayerController's notion of the page scale up to date when the plugin's
2649         geometry changes.
2650
2651 2012-11-27  Tim Horton  <timothy_horton@apple.com>
2652
2653         PDFPlugin: Scroll bars do not grow on hover
2654         https://bugs.webkit.org/show_bug.cgi?id=103382
2655         <rdar://problem/12555262>
2656
2657         Reviewed by Beth Dakin.
2658
2659         PDFPlugin needs to forward relevant mouse events to the scrollbars.
2660         In addition, it needs to implement currentMousePosition so ScrollableArea and friends
2661         can find the mouse position at arbitrary times.
2662
2663         I also took this opportunity to factor some coordinate space conversion functions out.
2664
2665         * WebProcess/Plugins/PDF/PDFPlugin.h:
2666         (WebKit::PDFPlugin::currentMousePosition): Added. Return the last mouse position in our coordinate space.
2667         (WebKit::PDFPlugin::convertFromRootViewToPlugin): Added.
2668         (WebKit::PDFPlugin::convertFromPluginToPDFView): Added.
2669         (PDFPlugin):
2670         * WebProcess/Plugins/PDF/PDFPlugin.mm:
2671         (WebKit::PDFPlugin::convertFromRootViewToPlugin): Convert a point from content space to plugin space, via the transform we get in geometryDidChange.
2672         (WebKit::PDFPlugin::convertFromPluginToPDFView): Convert a point from plugin space to PDFLayerController's flipped coordinate space.
2673         (WebKit::PDFPlugin::geometryDidChange): Use convertFromPluginToPDFView.
2674         (WebKit::PDFPlugin::nsEventForWebMouseEvent): Cache the mouse position in plugin space instead of PDFLayerController space. Use our new conversion functions.
2675         (WebKit::PDFPlugin::handleMouseEvent): Forward relevant mouse events to scrollbars:
2676         Determine which scrollbar the mouse is over now, and which it was previously over, and use that to:
2677         If the mouse is moved over a scrollbar, send mouseEntered to the scrollbar.
2678         If the mouse is moved out of a scrollbar, send mouseExited to the scrollbar.
2679         If the mouse is currently over a scrollbar, send mouseMoved/Up/Down to the scrollbar instead of PDFLayerController.
2680         If the mouse is currently over the scroll corner, bail, because nobody should get those events.
2681
2682 2012-11-27  Dan Bernstein  <mitz@apple.com>
2683
2684         Entering Tab View after a bunch of YouTube pages were opened in background tabs makes all of them start playing simultaneously
2685         https://bugs.webkit.org/show_bug.cgi?id=103358
2686
2687         Reviewed by Adele Peterson.
2688
2689         To fix this, this patch adds WKPageSetMayStartMediaWhenInWindow(), which allows the client to
2690         prevent media from starting automatically when the view is put in a window.
2691
2692         * Shared/WebPageCreationParameters.cpp:
2693         (WebKit::WebPageCreationParameters::encode): Encode mayStartMediaWhenInWindow.
2694         (WebKit::WebPageCreationParameters::decode): Decode mayStartMediaWhenInWindow.
2695         * Shared/WebPageCreationParameters.h:
2696         (WebPageCreationParameters): Added boolean member mayStartMediaWhenInWindow.
2697         * UIProcess/API/C/WKPage.cpp:
2698         (WKPageSetMayStartMediaWhenInWindow): Added. Calls through to WebPageProxy.
2699         * UIProcess/API/C/WKPagePrivate.h: Declared WKPageSetMayStartMediaWhenInWindow.
2700         * UIProcess/WebPageProxy.cpp:
2701         (WebKit::WebPageProxy::WebPageProxy): Added initializiation of m_mayStartMediaWhenInWindow
2702         to true, the value matching the current behavior.
2703         (WebKit::WebPageProxy::setMayStartMediaWhenInWindow): Added. Updates
2704         m_mayStartMediaWhenInWindow and sends a message to the Web process to do the same.
2705         (WebKit::WebPageProxy::creationParameters): Changed to set mayStartMediaWhenInWindow in the
2706         process creation parameters.
2707         * UIProcess/WebPageProxy.h:
2708         (WebPageProxy): Declared setMayStartMediaWhenInWindow() and added member variable
2709         m_mayStartMediaWhenInWindow.
2710         * WebProcess/WebPage/WebPage.cpp:
2711         (WebKit::WebPage::WebPage): Initialized m_mayStartMediaWhenInWindow from the creation
2712         parameters.
2713         (WebKit::WebPage::setIsInWindow): Made starting of media upon being added to a window
2714         conditional on m_mayStartMediaWhenInWindow.
2715         (WebKit::WebPage::setMayStartMediaWhenInWindow): Added. Sets m_mayStartMediaWhenInWindow. If
2716         already in a window when changing from false to true, starts m_setCanStartMediaTimer.
2717         * WebProcess/WebPage/WebPage.h:
2718         (WebPage): Declared setMayStartMediaWhenInWindow() and added member variable m_mayStartMediaWhenInWindow.
2719         * WebProcess/WebPage/WebPage.messages.in: Added SetMayStartMediaWhenInWindow.
2720
2721 2012-11-27  Pratik Solanki  <psolanki@apple.com>
2722
2723         objc/objc-runtime.h does not exist on all PLATFORM(MAC)
2724         https://bugs.webkit.org/show_bug.cgi?id=101780
2725
2726         Reviewed by Brent Fulgham.
2727
2728         Clean up header includes so we don't include objc/objc-runtime.h.
2729
2730         * PluginProcess/mac/PluginProcessShim.mm:
2731         * UIProcess/API/mac/PDFViewController.mm:
2732
2733 2012-11-27  Alexey Proskuryakov  <ap@apple.com>
2734
2735         [WK2] WebPageProxy::relatedPages() cannot assume that this page is known to process
2736         https://bugs.webkit.org/show_bug.cgi?id=103433
2737         <rdar://problem/12543513>
2738
2739         Reviewed by Jessie Berlin.
2740
2741         * UIProcess/WebPageProxy.cpp: (WebKit::WebPageProxy::relatedPages): Removed an incorrect
2742         assertion, and modified code to not rely on its condition being true.
2743
2744 2012-11-27  Mikhail Pozdnyakov  <mikhail.pozdnyakov@intel.com>
2745
2746         [EFL][Qt][WK2] Tiles not always painted
2747         https://bugs.webkit.org/show_bug.cgi?id=103271
2748
2749         Reviewed by Kenneth Rohde Christiansen.
2750
2751         The problem turned up because visible content was synchromized before the new fixed
2752         layout size had been applied in the web process.
2753
2754         * UIProcess/PageViewportController.cpp:
2755         (WebKit::PageViewportController::didChangeViewportSize):
2756         (WebKit::PageViewportController::didChangeViewportAttributes):
2757
2758 2012-11-27  Yael Aharon  <yael.aharon@intel.com>
2759
2760         [EFL] Graphics layer edges are sometimes very pixelated
2761         https://bugs.webkit.org/show_bug.cgi?id=103302
2762
2763         Reviewed by Kenneth Rohde Christiansen.
2764
2765         The call setEnableEdgeDistanceAntialiasing(true) was lost in the refactoring of
2766         http://trac.webkit.org/changeset/135401.
2767
2768         * UIProcess/CoordinatedGraphics/LayerTreeRenderer.cpp:
2769         (WebKit::LayerTreeRenderer::paintToCurrentGLContext):
2770
2771 2012-11-27  KwangYong Choi  <ky0.choi@samsung.com>
2772
2773         [X11] Allow empty plugin name and description during scan plugin
2774         https://bugs.webkit.org/show_bug.cgi?id=103234
2775
2776         Reviewed by Simon Hausmann.
2777
2778         Empty entries should be allowed when split the output string of scan plugin
2779         because the plugin name and the description can be empty string.
2780
2781         * UIProcess/Plugins/qt/PluginProcessProxyQt.cpp:
2782         (WebKit::PluginProcessProxy::scanPlugin):
2783         * UIProcess/Plugins/unix/PluginProcessProxyUnix.cpp:
2784         (WebKit::PluginProcessProxy::scanPlugin):
2785
2786 2012-11-27  Sheriff Bot  <webkit.review.bot@gmail.com>
2787
2788         Unreviewed, rolling out r135819.
2789         http://trac.webkit.org/changeset/135819
2790         https://bugs.webkit.org/show_bug.cgi?id=103388
2791
2792         It broke many tests on Qt and EFL WK2 platforms (Requested by
2793         Ossy on #webkit).
2794
2795         * Shared/WebPageCreationParameters.cpp:
2796         (WebKit::WebPageCreationParameters::encode):
2797         (WebKit::WebPageCreationParameters::decode):
2798         * Shared/WebPageCreationParameters.h:
2799         (WebPageCreationParameters):
2800         * UIProcess/API/C/WKPage.cpp:
2801         (WKPageCopyRelatedPages):
2802         * UIProcess/API/C/WKPagePrivate.h:
2803         * UIProcess/WebPageProxy.cpp:
2804         (WebKit::WebPageProxy::WebPageProxy):
2805         (WebKit::WebPageProxy::creationParameters):
2806         * UIProcess/WebPageProxy.h:
2807         (WebPageProxy):
2808         * WebProcess/WebPage/WebPage.cpp:
2809         (WebKit::WebPage::WebPage):
2810         (WebKit::WebPage::setIsInWindow):
2811         * WebProcess/WebPage/WebPage.h:
2812         (WebPage):
2813         * WebProcess/WebPage/WebPage.messages.in:
2814
2815 2012-11-27  Kyungjin Kim  <gen.kim@samsung.com>
2816
2817         [WK2] Expose Accelerated2dCanvas flag set and get in WebKit2
2818         https://bugs.webkit.org/show_bug.cgi?id=103008
2819
2820         Reviewed by Gyuyoung Kim.
2821
2822         Fix API names in WKPreferences from 2d to 2D.
2823
2824         * UIProcess/API/C/WKPreferences.cpp:
2825         (WKPreferencesSetAccelerated2DCanvasEnabled):
2826         (WKPreferencesGetAccelerated2DCanvasEnabled):
2827         * UIProcess/API/C/WKPreferencesPrivate.h:
2828
2829 2012-11-27  Sheriff Bot  <webkit.review.bot@gmail.com>
2830
2831         Unreviewed, rolling out r135786.
2832         http://trac.webkit.org/changeset/135786
2833         https://bugs.webkit.org/show_bug.cgi?id=103379
2834
2835         It made 3 plugin tests timeout on several platforms (Requested
2836         by Ossy on #webkit).
2837
2838         * WebProcess/Plugins/PluginView.cpp:
2839         (WebKit::PluginView::performFrameLoadURLRequest):
2840         * WebProcess/WebPage/WebPage.cpp:
2841         (WebKit::WebPage::loadURLRequest):
2842         (WebKit::WebPage::loadData):
2843         (WebKit::WebPage::linkClicked):
2844
2845 2012-11-27  Huang Dongsung  <luxtella@company100.net>
2846
2847         Coordinated Graphics: Remove the maskTarget member of CoordinatedGraphicsLayer.
2848         https://bugs.webkit.org/show_bug.cgi?id=103297
2849
2850         Reviewed by Noam Rosenthal.
2851
2852         Remove the maskTarget member of CoordinatedGraphicsLayer, which is not used.
2853
2854         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedGraphicsLayer.cpp:
2855         (WebCore::CoordinatedGraphicsLayer::CoordinatedGraphicsLayer):
2856         (WebCore::CoordinatedGraphicsLayer::setMaskLayer):
2857         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedGraphicsLayer.h:
2858         (CoordinatedGraphicsLayer):
2859
2860 2012-11-26  Sheriff Bot  <webkit.review.bot@gmail.com>
2861
2862         Unreviewed, rolling out r135822.
2863         http://trac.webkit.org/changeset/135822
2864         https://bugs.webkit.org/show_bug.cgi?id=103369
2865
2866         Undo the revert of r135818, since that change does not affect
2867         code used by Chromium (Requested by apavlov on #webkit).
2868
2869         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedGraphicsLayer.cpp:
2870         (WebCore::CoordinatedGraphicsLayer::setContentsVisible):
2871         (WebCore::CoordinatedGraphicsLayer::setMaskLayer):
2872
2873 2012-11-26  Sheriff Bot  <webkit.review.bot@gmail.com>
2874
2875         Unreviewed, rolling out r135818.
2876         http://trac.webkit.org/changeset/135818
2877         https://bugs.webkit.org/show_bug.cgi?id=103368
2878
2879         platform/chromium/virtual/threaded/compositing/visibility
2880         /visibility-simple-webgl-layer.html crash on Mountain Lion
2881         (Requested by apavlov on #webkit).
2882
2883         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedGraphicsLayer.cpp:
2884         (WebCore::CoordinatedGraphicsLayer::setContentsVisible):
2885         (WebCore::CoordinatedGraphicsLayer::setMaskLayer):
2886
2887 2012-11-26  Dan Bernstein  <mitz@apple.com>
2888
2889         <rdar://problem/11931191> Entering Tab View after a bunch of YouTube pages were opened in background tabs makes all of them start playing simultaneously
2890         https://bugs.webkit.org/show_bug.cgi?id=103358
2891
2892         Reviewed by Adele Peterson.
2893
2894         To fix this, this patch adds WKPageSetMayStartMediaWhenInWindow(), which allows the client to
2895         prevent media from starting automatically when the view is put in a window.
2896
2897         * Shared/WebPageCreationParameters.cpp:
2898         (WebKit::WebPageCreationParameters::encode): Encode mayStartMediaWhenInWindow.
2899         (WebKit::WebPageCreationParameters::decode): Decode mayStartMediaWhenInWindow.
2900         * Shared/WebPageCreationParameters.h:
2901         (WebPageCreationParameters): Added boolean member mayStartMediaWhenInWindow.
2902         * UIProcess/API/C/WKPage.cpp:
2903         (WKPageSetMayStartMediaWhenInWindow): Added. Calls through to WebPageProxy.
2904         * UIProcess/API/C/WKPagePrivate.h: Declared WKPageSetMayStartMediaWhenInWindow.
2905         * UIProcess/WebPageProxy.cpp:
2906         (WebKit::WebPageProxy::WebPageProxy): Added initializiation of m_mayStartMediaWhenInWindow
2907         to true, the value matching the current behavior.
2908         (WebKit::WebPageProxy::setMayStartMediaWhenInWindow): Added. Updates
2909         m_mayStartMediaWhenInWindow and sends a message to the Web process to do the same.
2910         (WebKit::WebPageProxy::creationParameters): Changed to set mayStartMediaWhenInWindow in the
2911         process creation parameters.
2912         * UIProcess/WebPageProxy.h:
2913         (WebPageProxy): Declared setMayStartMediaWhenInWindow() and added member variable
2914         m_mayStartMediaWhenInWindow.
2915         * WebProcess/WebPage/WebPage.cpp:
2916         (WebKit::WebPage::WebPage): Initialized m_mayStartMediaWhenInWindow from the creation
2917         parameters.
2918         (WebKit::WebPage::setIsInWindow): Made starting of media upon being added to a window
2919         conditional on m_mayStartMediaWhenInWindow.
2920         (WebKit::WebPage::setMayStartMediaWhenInWindow): Added. Sets m_mayStartMediaWhenInWindow. If
2921         already in a window when changing from false to true, starts m_setCanStartMediaTimer.
2922         * WebProcess/WebPage/WebPage.h:
2923         (WebPage): Declared setMayStartMediaWhenInWindow() and added member variable m_mayStartMediaWhenInWindow.
2924         * WebProcess/WebPage/WebPage.messages.in: Added SetMayStartMediaWhenInWindow.
2925
2926 2012-11-26  Huang Dongsung  <luxtella@company100.net>
2927
2928         Coordinated Graphics: Set visibility to a mask layer in GraphicsLayer::setContentsVisible().
2929         https://bugs.webkit.org/show_bug.cgi?id=103297
2930
2931         Reviewed by Noam Rosenthal.
2932
2933         GraphicsLayerTextureMapper and CoordinatedGraphicsLayer set the visibility of a
2934         mask layer in setContentsVisible() and setMaskLayer() like setting a size.
2935         This patch is needed because RenderLayerBacking does not set the visibility to a
2936         mask layer like the size.
2937
2938         This patch does not change user experience because an invisible layer is not
2939         rendered although the mask layer is rendered. In that sense, it is an
2940         optimization patch.
2941
2942         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedGraphicsLayer.cpp:
2943         (WebCore::CoordinatedGraphicsLayer::setContentsVisible):
2944         (WebCore::CoordinatedGraphicsLayer::setMaskLayer):
2945
2946 2012-11-26  Kyungjin Kim  <gen.kim@samsung.com>
2947
2948         [WK2] Expose Accelerated2dCanvas flag set and get in WebKit2
2949         https://bugs.webkit.org/show_bug.cgi?id=103008
2950
2951         Reviewed by Gyuyoung Kim.
2952
2953         Add setting APIs for accelerated 2d canvas in WebKit2.
2954
2955         * Shared/WebPreferencesStore.h:
2956         (WebKit):
2957         * UIProcess/API/C/WKPreferences.cpp:
2958         (WKPreferencesSetAccelerated2dCanvasEnabled):
2959         (WKPreferencesGetAccelerated2dCanvasEnabled):
2960         * UIProcess/API/C/WKPreferencesPrivate.h:
2961         * WebProcess/WebPage/WebPage.cpp:
2962         (WebKit::WebPage::updatePreferences):
2963
2964 2012-11-26  Tim Horton  <timothy_horton@apple.com>
2965
2966         Ensure that plugins are initialized before using handleEditingCommand/isEditingCommandEnabled/shouldAllowScripting
2967         https://bugs.webkit.org/show_bug.cgi?id=103288
2968
2969         Reviewed by Dan Bernstein.
2970
2971         Other PluginView methods that use m_plugin null-check m_plugin and check
2972         that the plugin has finished initializing before using it. These three
2973         should do the same thing.
2974
2975         * WebProcess/Plugins/PluginView.cpp:
2976         (WebKit::PluginView::handleEditingCommand):
2977         (WebKit::PluginView::isEditingCommandEnabled):
2978         (WebKit::PluginView::shouldAllowScripting):
2979
2980 2012-11-26  Tim Horton  <timothy_horton@apple.com>
2981
2982         PDFPlugin: Subframe PDF context menus are in the wrong place
2983         https://bugs.webkit.org/show_bug.cgi?id=103284
2984         <rdar://problem/12727972>
2985
2986         Reviewed by Dan Bernstein.
2987
2988         Event position is in window coordinates, not content coordinates.
2989         Since we have no windowToScreen(), use windowToContents and contentsToScreen
2990         to get to screen coordinate space, which WKPopupContextMenu wants.
2991
2992         * WebProcess/Plugins/PDF/PDFPlugin.mm:
2993         (WebKit::PDFPlugin::handleContextMenuEvent):
2994
2995 2012-11-26  Tim Horton  <timothy_horton@apple.com>
2996
2997         PDFPlugin: Ctrl-click opens a link in a PDF in addition to context menu
2998         https://bugs.webkit.org/show_bug.cgi?id=103282
2999         <rdar://problem/12710892>
3000
3001         Reviewed by Dan Bernstein.
3002
3003         Don't send standard mouse events to PDFKit if a click will also show/hide the context menu.
3004
3005         * WebProcess/Plugins/PDF/PDFPlugin.mm:
3006         (WebKit::PDFPlugin::handleMouseEvent):
3007
3008 2012-11-26  Ryuan Choi  <ryuan.choi@gmail.com>
3009
3010         [EFL] Unreviewed build fix after r135767 without Tiled Backing Store
3011         https://bugs.webkit.org/show_bug.cgi?id=103320
3012
3013         Unreviewed build fix.
3014
3015         * WebProcess/Plugins/Plugin.cpp:
3016         * WebProcess/Plugins/Plugin.h:
3017         (WebCore):
3018
3019 2012-11-26  James Simonsen  <simonjam@chromium.org>
3020
3021         Consolidate FrameLoader::load() into one function taking a FrameLoadRequest
3022         https://bugs.webkit.org/show_bug.cgi?id=102151
3023
3024         Reviewed by Adam Barth.
3025
3026         * WebProcess/Plugins/PluginView.cpp:
3027         (WebKit::PluginView::performFrameLoadURLRequest):
3028         * WebProcess/WebPage/WebPage.cpp:
3029         (WebKit::WebPage::loadURLRequest):
3030         (WebKit::WebPage::loadData):
3031
3032 2012-11-26  Jon Lee  <jonlee@apple.com>
3033
3034         Pass clicks through to the restarted plugin
3035         https://bugs.webkit.org/show_bug.cgi?id=102150
3036         <rdar://problem/12695575>
3037
3038         Reviewed by Simon Fraser.
3039
3040         Expose convertToRootView() as a public function for all plugins. It converts the click point
3041         from local plugin coordinates to root view coordinates. When the events are sent to the
3042         plugin, the coordinate gets converted back to the local reference frame.
3043         * WebProcess/Plugins/Plugin.cpp:
3044         (WebKit::Plugin::convertToRootView): Default implementation should not be reached.
3045         * WebProcess/Plugins/Plugin.h: Promote convertToRootView() from NetscapePlugin.h.
3046         * WebProcess/Plugins/Netscape/NetscapePlugin.h: An implementation already existed. Make the
3047         method virtual.
3048         * WebProcess/Plugins/PluginProxy.h:
3049         * WebProcess/Plugins/PluginProxy.cpp:
3050         (WebKit::PluginProxy::convertToRootView): Apply the transform to the provided point to return
3051         a point in root view coordinates.
3052
3053         Change the threshold state to PlayingWithPendingMouseClick instead of Playing, since that is
3054         the earliest state where the plugin is playing.
3055         * WebProcess/Plugins/PluginView.cpp: Give the snapshot a little more time to generate.
3056         (WebKit::PluginView::didInitializePlugin): When the plugin has initialized, tell the plugin
3057         element to dispatch the pending mouse click.
3058         (WebKit::PluginView::paint):
3059         (WebKit::PluginView::createWebEvent): Helper function to convert a WebCore mouse event to a
3060         WebMouseEvent.
3061         (WebKit::PluginView::handleEvent): If the event is simulated, there is no source event from
3062         the UI process. So we fabricate one based on the simulated event.
3063         (WebKit::PluginView::invalidateRect):
3064         (WebKit::PluginView::isAcceleratedCompositingEnabled):
3065         * WebProcess/Plugins/PluginView.h:
3066
3067 2012-11-26  Kalev Lember  <kalevlember@gmail.com>
3068
3069         [GTK] Explicitly link against librt
3070         https://bugs.webkit.org/show_bug.cgi?id=103194
3071
3072         Reviewed by Martin Robinson.
3073
3074         Fixes broken build with undefined references to shm_open / shm_unlink
3075         symbols. SharedMemoryUnix.cpp uses these so we need to link with -lrt.
3076
3077         * GNUmakefile.am:
3078
3079 2012-11-26  Christophe Dumez  <christophe.dumez@intel.com>
3080
3081         [EFL][WK2] Add setting to enable / disable HTML5 local storage functionality
3082         https://bugs.webkit.org/show_bug.cgi?id=103224
3083
3084         Reviewed by Laszlo Gombos.
3085
3086         Add API to ewk_settings to enable / disable the HTML5
3087         local storage functionality. The functionality is
3088         enabled by default.
3089
3090         * UIProcess/API/efl/ewk_settings.cpp:
3091         (ewk_settings_local_storage_enabled_set):
3092         (ewk_settings_local_storage_enabled_get):
3093         * UIProcess/API/efl/ewk_settings.h:
3094         * UIProcess/API/efl/tests/test_ewk2_settings.cpp:
3095         (TEST_F): Add API test for ewk_settings_local_storage_enabled_get / set.
3096
3097 2012-11-26  Rafael Brandao  <rafael.lobo@openbossa.org>
3098
3099         [CoordinatedGraphics] Access to LayerTreeRenderer::m_renderQueue should be thread safe
3100         https://bugs.webkit.org/show_bug.cgi?id=101341
3101
3102         Reviewed by Noam Rosenthal.
3103
3104         * UIProcess/CoordinatedGraphics/LayerTreeRenderer.cpp:
3105         (WebKit::LayerTreeRenderer::syncRemoteContent): The previous swap already clears the
3106         vector on m_renderQueue. It is also done in a thread-safe way, so clearing it afterward
3107         can be harmful as we've already released the lock.
3108
3109 2012-11-26  Jaehun Lim  <ljaehun.lim@samsung.com>
3110
3111         Text Autosizing: Add Text Autosizing APIs for WK2
3112         https://bugs.webkit.org/show_bug.cgi?id=100633
3113
3114         Reviewed by Sam Weinig.
3115
3116         Implement basic Text Autosizing APIs for WK2.
3117         Text Autosizing is a useful feature for mobile browsers. It adjusts the font size
3118         of text in wide columns, and makes text more legible.
3119         This patch adds setting APIs for Text Autosizing in WK2.
3120
3121         * Shared/WebPreferencesStore.h:
3122         (WebKit):
3123         * UIProcess/API/C/WKPreferences.cpp:
3124         (WKPreferencesSetTextAutosizingEnabled):
3125         (WKPreferencesGetTextAutosizingEnabled):
3126         * UIProcess/API/C/WKPreferences.h:
3127         * WebProcess/WebPage/WebPage.cpp:
3128         (WebKit::WebPage::updatePreferences):
3129
3130 2012-11-26  Pierre Rossi  <pierre.rossi@gmail.com>
3131
3132         [Qt] REGRESSION(r135575): It made all tests assert
3133         https://bugs.webkit.org/show_bug.cgi?id=103169
3134
3135         Reviewed by Simon Hausmann.
3136
3137         This fixes another regression introduced in r135515:
3138         initializeWebKitQt shouldn't implicitely call initializeWebCoreQt
3139         since it can be called from WebKit2 to initialize QStyle for testing.
3140         This would then lead to things such as PlatformStrategies being
3141         initialized twice.
3142
3143         * qt/MainQt.cpp: No need to initialize anything if we're not using QStyle.
3144         (WebKit):
3145         (main):
3146
3147 2012-11-26  Huang Dongsung  <luxtella@company100.net>
3148
3149         REGRESSION(134142): ASSERT(!m_size.isZero()) hits in CoordinatedBackingStore::paintToTextureMapper().
3150         https://bugs.webkit.org/show_bug.cgi?id=103217
3151
3152         Reviewed by Noam Rosenthal.
3153
3154         It is possible for CoordinatedBackingStore of directed composited image to not
3155         have tiles, because CoordinatedImageBacking does not create tiles when the image
3156         is invisible.
3157
3158         * UIProcess/CoordinatedGraphics/CoordinatedBackingStore.cpp:
3159         (WebKit::CoordinatedBackingStore::paintToTextureMapper):
3160
3161 2012-11-25  Mikhail Pozdnyakov  <mikhail.pozdnyakov@intel.com>
3162
3163         [WK2] TiledBackingStore: page contents is scaled wrongly
3164         https://bugs.webkit.org/show_bug.cgi?id=103090
3165
3166         Reviewed by Kenneth Rohde Christiansen.
3167
3168         Before this change the page contents scaling in PageViewportController was
3169         defined all the times by m_rawAttributes.initialScale. If initial scale had not
3170         been specified in the viewport meta tag it was set to m_minimumScaleToFit inside
3171         PageViewportController::didChangeViewportAttributes().
3172
3173         The problem was that m_minimumScaleToFit could have wrong value as contents size
3174         might have not be updated by the time PageViewportController::didChangeViewportAttributes()
3175         was invoked.
3176
3177         The solution is to use m_minimumScaleToFit for contents scaling if initial scale
3178         is not specified in the viewport meta tag, as it is updated all the time. 
3179         Also a flag m_initiallyFitToViewport is added to PageViewportController to detect
3180         whether m_minimumScaleToFit should be used for scaling.
3181
3182         * UIProcess/PageViewportController.cpp:
3183         (WebKit::PageViewportController::PageViewportController):
3184         (WebKit::PageViewportController::didChangeContentsSize):
3185         (WebKit::PageViewportController::pageTransitionViewportReady):
3186         (WebKit::PageViewportController::didChangeViewportAttributes):
3187         * UIProcess/PageViewportController.h:
3188         (PageViewportController):
3189
3190 2012-11-24  Mikhail Pozdnyakov  <mikhail.pozdnyakov@intel.com>
3191
3192         [EFL][WK2] Stop the mess with DECLARE_EWK_VIEW_CALLBACK arg type definition
3193         https://bugs.webkit.org/show_bug.cgi?id=103187
3194
3195         Reviewed by Kenneth Rohde Christiansen.
3196
3197         Now the client should pass to DECLARE_EWK_VIEW_CALLBACK macro exacly the 
3198         same arg type s/he wants to have in the Ewk_View callback.
3199
3200         * UIProcess/API/efl/EwkViewCallbacks.h:
3201         (EvasObjectHolder):
3202         (EwkViewCallbacks::EvasObjectHolder::EvasObjectHolder):
3203         (EwkViewCallbacks):
3204
3205 2012-11-24  Mikhail Pozdnyakov  <mikhail.pozdnyakov@intel.com>
3206
3207         [EFL][WK2] Check errors in EwkView callbacks usage at compile time
3208         https://bugs.webkit.org/show_bug.cgi?id=103177
3209
3210         Reviewed by Kenneth Rohde Christiansen.
3211
3212         Errors in EwkView callbacks usage are now checked at compile time.
3213
3214         * UIProcess/API/efl/EwkViewCallbacks.h:
3215         (CallBack):
3216         (EwkViewCallbacks::CallBack::CallBack):
3217         (EwkViewCallbacks::CallBack::call):
3218
3219 2012-11-23  Sheriff Bot  <webkit.review.bot@gmail.com>
3220
3221         Unreviewed, rolling out r135575.
3222         http://trac.webkit.org/changeset/135575
3223         https://bugs.webkit.org/show_bug.cgi?id=103169
3224
3225         It made all tests assert (Requested by Ossy on #webkit).
3226
3227         * qt/MainQt.cpp:
3228         (WebKit):
3229         (main):
3230
3231 2012-11-23  Alexis Menard  <alexis@webkit.org>
3232
3233         [CSS3 Backgrounds and Borders] Implement new CSS3 background-position parsing.
3234         https://bugs.webkit.org/show_bug.cgi?id=102104
3235
3236         Reviewed by Julien Chaffraix.
3237
3238         Protect the new feature behind a feature flag.
3239
3240         * Configurations/FeatureDefines.xcconfig:
3241
3242 2012-11-23  Huang Dongsung  <luxtella@company100.net>
3243
3244         Coordinated Graphics: Match the behavior of selfOrAncestorHaveNonAffineTransforms() to its name.
3245         https://bugs.webkit.org/show_bug.cgi?id=103097
3246
3247         Reviewed by Noam Rosenthal.
3248
3249         CoordinatedGraphicsLayer::selfOrAncestorHaveNonAffineTransforms() does
3250         not check its ancestor. This patch makes this method check its ancestor
3251         to match its name.
3252
3253         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedGraphicsLayer.cpp:
3254         (WebCore::CoordinatedGraphicsLayer::selfOrAncestorHaveNonAffineTransforms):
3255
3256 2012-11-23  Huang Dongsung  <luxtella@company100.net>
3257
3258         Coordinated Graphics: LayerTreeRenderer::removeTile() does not remove tiles actually.
3259         https://bugs.webkit.org/show_bug.cgi?id=103030
3260
3261         Reviewed by Noam Rosenthal.
3262
3263         LayerTreeRenderer::removeTile() must add a backing store into
3264         m_backingStoresWithPendingBuffers. Otherwise, tiles are not removed.
3265
3266         * UIProcess/CoordinatedGraphics/LayerTreeRenderer.cpp:
3267         (WebKit::LayerTreeRenderer::removeTile):
3268
3269 2012-11-23  Huang Dongsung  <luxtella@company100.net>
3270
3271         [TexMap] Remove dependency of TextureMapperLayer on GraphicsLayerTextureMapper.
3272         https://bugs.webkit.org/show_bug.cgi?id=103046
3273
3274         Reviewed by Noam Rosenthal.
3275
3276         This patch makes GraphicsLayerTextureMapper create its own backing
3277         store. However, LayerTreeRenderer also creates its own backing store. So
3278         when LayerTreeRenderer uses GraphicsLayerTextureMapper,
3279         LayerTreeRenderer needs GraphicsLayerTextureMapper to not create its own
3280         backing store.
3281
3282         * UIProcess/CoordinatedGraphics/LayerTreeRenderer.cpp:
3283         (WebKit::LayerTreeRenderer::createLayer):
3284         (WebKit::LayerTreeRenderer::getBackingStore):
3285
3286 2012-11-23  Huang Dongsung  <luxtella@company100.net>
3287
3288         REGRESSION(r135486): ASSERT(isMainThread()) hit in LayerTreeRenderer::setActive(bool)
3289         https://bugs.webkit.org/show_bug.cgi?id=103077
3290
3291         Reviewed by Noam Rosenthal.
3292
3293         Currently, the painting thread uses purgeGLResources() and setActive().
3294         QQuickWebPage::updatePaintNode() indirectly calls both methods after
3295         locking the main thread.
3296
3297         This patch changes two points.
3298         1. Remove ASSERT(isMainThread()) in methods that the painting thread can
3299         call.
3300         2. Make purgeGLResources() and setActive() call methods of
3301         LayerTreeCoordinatorProxy via dispatchOnMainThread().
3302
3303         * UIProcess/CoordinatedGraphics/LayerTreeRenderer.cpp:
3304         (WebKit::LayerTreeRenderer::LayerTreeRenderer):
3305         (WebKit::LayerTreeRenderer::renderNextFrame):
3306         (WebKit::LayerTreeRenderer::purgeGLResources):
3307         (WebKit):
3308         (WebKit::LayerTreeRenderer::purgeBackingStores):
3309         (WebKit::LayerTreeRenderer::setActive):
3310         * UIProcess/CoordinatedGraphics/LayerTreeRenderer.h:
3311         (LayerTreeRenderer):
3312
3313 2012-11-23  Christophe Dumez  <christophe.dumez@intel.com>
3314
3315         [EFL][WK2][AC] EwkViewImpl::transformToScreen() does not retrieve the Ecore_X_Window properly
3316         https://bugs.webkit.org/show_bug.cgi?id=103133
3317
3318         Reviewed by Kenneth Rohde Christiansen.
3319
3320         If accelerated compositing is enabled, EwkViewImpl::transformToScreen() should
3321         attempt to retrieve the Ecore_X_Window using ecore_evas_gl_x11_window_get() first
3322         and only fall back to ecore_evas_software_x11_window_get().
3323
3324         * UIProcess/API/efl/EwkViewImpl.cpp:
3325         (EwkViewImpl::transformToScreen):
3326
3327 2012-11-23  Wojciech Bielawski  <w.bielawski@samsung.com>
3328
3329         [WK2][WKTR] WebKitTestRunner needs eventSender.contextClick()
3330         https://bugs.webkit.org/show_bug.cgi?id=86881
3331
3332         Reviewed by Kenneth Rohde Christiansen.
3333
3334         InjectedBundle API extended to retrieve contextMenu entries names.
3335         WebContextMenu exteded with function to retrieve menu items.
3336         This API is required by layout tests.
3337         Common code in WebContextMenu.cpp moved to separate method menuItemsWithUserData().
3338         Behaviour of dependend methods is unchanged.
3339
3340         * WebProcess/InjectedBundle/API/c/WKBundlePage.cpp:
3341         (WKBundlePageGetContextMenuEntriesNames):
3342         * WebProcess/InjectedBundle/API/c/WKBundlePage.h:
3343         * WebProcess/WebPage/WebContextMenu.cpp:
3344         (WebKit::WebContextMenu::items):
3345         (WebKit):
3346         * WebProcess/WebPage/WebContextMenu.h:
3347         (WebContextMenu):
3348
3349 2012-11-22  Pierre Rossi  <pierre.rossi@gmail.com>
3350
3351         [Qt] Avoid initializing PlatformStrategies twice.
3352
3353         Rubber-stamped by Simon Hausmann.
3354
3355         This fixes another regression introduced in r135515:
3356         initializeWebKitQt shouldn't implicitely call initializeWebCoreQt
3357         since it can be called from WebKit2 to initialize QStyle for testing.
3358         This would then lead to things such as PlatformStrategies being
3359         initialized twice.
3360
3361         * qt/MainQt.cpp: No need to initialize anything if we're not using QStyle.
3362         (WebKit):
3363         (main):
3364
3365 2012-11-22  Carlos Garcia Campos  <cgarcia@igalia.com>
3366
3367         [GTK] Use custom private macros to define GObjects
3368         https://bugs.webkit.org/show_bug.cgi?id=99705
3369
3370         Reviewed by Martin Robinson.
3371
3372         Add WEBKIT_DEFINE_TYPE macros, similar and compatible with
3373         G_DEFINE_TYPE macros, to define GObject types. These macros also
3374         define the init and finalize functions reducing the GObject
3375         boilerplate and hiding the placement new syntax that causes some
3376         confusion. The patch replaces the use of G_DEFINE_TYPE macros by
3377         WEBKIT_DEFINE_TYPE ones and removes the init and finalize
3378         implementations, moving custom code when needed to the private
3379         struct constructor/destructor or constructed/dispose virtual
3380         methods when appropriate.
3381
3382         * UIProcess/API/gtk/WebKitBackForwardList.cpp:
3383         * UIProcess/API/gtk/WebKitBackForwardListItem.cpp:
3384         (webkit_back_forward_list_item_class_init):
3385         * UIProcess/API/gtk/WebKitContextMenu.cpp:
3386         (webkitContextMenuDispose):
3387         (webkit_context_menu_class_init):
3388         * UIProcess/API/gtk/WebKitContextMenuItem.cpp:
3389         (_WebKitContextMenuItemPrivate::~_WebKitContextMenuItemPrivate):
3390         (_WebKitContextMenuItemPrivate):
3391         (webkit_context_menu_item_class_init):
3392         * UIProcess/API/gtk/WebKitCookieManager.cpp:
3393         (_WebKitCookieManagerPrivate::~_WebKitCookieManagerPrivate):
3394         (_WebKitCookieManagerPrivate):
3395         * UIProcess/API/gtk/WebKitDownload.cpp:
3396         (webkit_download_class_init):
3397         * UIProcess/API/gtk/WebKitFaviconDatabase.cpp:
3398         (webkit_favicon_database_class_init):
3399         * UIProcess/API/gtk/WebKitFileChooserRequest.cpp:
3400         (webkitFileChooserRequestDispose):
3401         (webkit_file_chooser_request_class_init):
3402         * UIProcess/API/gtk/WebKitFindController.cpp:
3403         (webkit_find_controller_class_init):
3404         * UIProcess/API/gtk/WebKitFormSubmissionRequest.cpp:
3405         (webkitFormSubmissionRequestDispose):
3406         (webkit_form_submission_request_class_init):
3407         * UIProcess/API/gtk/WebKitGeolocationPermissionRequest.cpp:
3408         (webkitGeolocationPermissionRequestDispose):
3409         (webkit_geolocation_permission_request_class_init):
3410         * UIProcess/API/gtk/WebKitHitTestResult.cpp:
3411         (webkit_hit_test_result_class_init):
3412         * UIProcess/API/gtk/WebKitNavigationPolicyDecision.cpp:
3413         (webkit_navigation_policy_decision_class_init):
3414         * UIProcess/API/gtk/WebKitPlugin.cpp:
3415         (_WebKitPluginPrivate::~_WebKitPluginPrivate):
3416         (_WebKitPluginPrivate):
3417         (webkit_plugin_class_init):
3418         * UIProcess/API/gtk/WebKitPolicyDecision.cpp:
3419         (webkitPolicyDecisionDispose):
3420         (webkit_policy_decision_class_init):
3421         (webkit_policy_decision_use):
3422         (webkit_policy_decision_ignore):
3423         (webkit_policy_decision_download):
3424         * UIProcess/API/gtk/WebKitPrintOperation.cpp:
3425         (_WebKitPrintOperationPrivate::~_WebKitPrintOperationPrivate):
3426         (_WebKitPrintOperationPrivate):
3427         (webkit_print_operation_class_init):
3428         * UIProcess/API/gtk/WebKitPrivate.h:
3429         * UIProcess/API/gtk/WebKitResponsePolicyDecision.cpp:
3430         (webkit_response_policy_decision_class_init):
3431         * UIProcess/API/gtk/WebKitSecurityManager.cpp:
3432         (webkit_security_manager_class_init):
3433         * UIProcess/API/gtk/WebKitSettings.cpp:
3434         (_WebKitSettingsPrivate::_WebKitSettingsPrivate):
3435         (_WebKitSettingsPrivate):
3436         (webkit_settings_class_init):
3437         * UIProcess/API/gtk/WebKitURIRequest.cpp:
3438         (webkit_uri_request_class_init):
3439         * UIProcess/API/gtk/WebKitURIResponse.cpp:
3440         (webkit_uri_response_class_init):
3441         * UIProcess/API/gtk/WebKitURISchemeRequest.cpp:
3442         (webkit_uri_scheme_request_class_init):
3443         * UIProcess/API/gtk/WebKitWebContext.cpp:
3444         * UIProcess/API/gtk/WebKitWebInspector.cpp:
3445         (_WebKitWebInspectorPrivate::~_WebKitWebInspectorPrivate):
3446         (_WebKitWebInspectorPrivate):
3447         (webkit_web_inspector_class_init):
3448         * UIProcess/API/gtk/WebKitWebResource.cpp:
3449         (webkit_web_resource_class_init):
3450         * UIProcess/API/gtk/WebKitWebView.cpp:
3451         (_WebKitWebViewPrivate::~_WebKitWebViewPrivate):