a20ad0213ea256a3bd156b4b231b2db33c71c7a7
[WebKit-https.git] / Source / WebKit2 / ChangeLog
1 2013-07-01  Tim Horton  <timothy_horton@apple.com>
2
3         [wk2] TiledCoreAnimationDrawingArea should support scrolling its exposed rect
4         https://bugs.webkit.org/show_bug.cgi?id=118173
5         <rdar://problem/14301166>
6
7         Reviewed by Anders Carlsson.
8
9         Offset the exposed rect passed from the WKView by the main frame's current scroll position
10         before sending it to our TiledBackings, so that it is in the same coordinate space as their
11         ordinary visibleRects.
12
13         This has the side effect of making clips-to-exposed-rect testable (though useless) in Safari.
14
15         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.h:
16         Add updateScrolledExposedRect() and m_scrolledExposedRect.
17
18         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
19         (WebKit::TiledCoreAnimationDrawingArea::scroll):
20         Call updateScrolledExposedRect when the main frame scrolls.
21
22         (WebKit::TiledCoreAnimationDrawingArea::setExposedRect):
23         Remove a FIXME about this change.
24         Call updateScrolledExposedRect instead of passing down the unscrolled rect.
25
26         (WebKit::TiledCoreAnimationDrawingArea::setClipsToExposedRect):
27         Call updateScrolledExposedRect, because that method will short-circuit if
28         setClipsToExposedRect is false, so we need to update here for correctness
29         if we get a setExposedRect(), setClipsToExposedRect(true) pair.
30
31         (WebKit::TiledCoreAnimationDrawingArea::updateScrolledExposedRect):
32         Update m_scrolledExposedRect and propagate it to our TiledBackings.
33
34         (WebKit::TiledCoreAnimationDrawingArea::flushLayers):
35         (WebKit::TiledCoreAnimationDrawingArea::setRootCompositingLayer):
36         (WebKit::TiledCoreAnimationDrawingArea::createPageOverlayLayer):
37         (WebKit::TiledCoreAnimationDrawingArea::didCommitChangesForLayer):
38         Use the scrolled exposed rect.
39
40 2013-07-01  Ada Chan  <adachan@apple.com>
41
42         Properly hide the header and footer banners if they are set to null.
43         https://bugs.webkit.org/show_bug.cgi?id=118219
44
45         Reviewed by Beth Dakin.
46         
47         Call Page::addFooterWithHeight(0) to remove the parent layer that hosts the banner when
48         the footer banner is detached. Similarly for the header banner.
49
50         * WebProcess/WebPage/mac/PageBannerMac.mm:
51         (WebKit::PageBanner::detachFromPage):
52
53 2013-07-01  Jochen Eisinger  <jochen@chromium.org>
54
55         Remove support for consumable user gestures
56         https://bugs.webkit.org/show_bug.cgi?id=118247
57
58         Reviewed by Geoffrey Garen.
59
60         * WebProcess/Notifications/WebNotificationManager.cpp:
61         (WebKit::WebNotificationManager::didClickNotification):
62         * WebProcess/Plugins/PluginView.cpp:
63         (WebKit::PluginView::performFrameLoadURLRequest):
64         (WebKit::PluginView::evaluate):
65         * WebProcess/WebCoreSupport/WebContextMenuClient.cpp:
66         (WebKit::WebContextMenuClient::searchWithGoogle):
67
68 2013-06-27  Jer Noble  <jer.noble@apple.com>
69
70         Audio in apps which embed WebViews is corrupted.
71         https://bugs.webkit.org/show_bug.cgi?id=118163
72
73         Reviewed by Maciej Stachowiak.
74
75         Expose the WebCore lowPowerVideoAudioBufferSizeEnabled setting to WebKit2 clients.
76
77         * Shared/WebPreferencesStore.h:
78         * WebProcess/WebPage/WebPage.cpp:
79         (WebKit::WebPage::updatePreferences):
80
81 2013-07-01  Sam Weinig  <sam@webkit.org>
82
83         WKPageLoadDataWithUserData neglects to set the base URL that is passed in
84         <rdar://problem/14306784>
85         https://bugs.webkit.org/show_bug.cgi?id=118256
86
87         Reviewed by Anders Carlsson.
88
89         * WebProcess/WebPage/WebPage.cpp:
90         (WebKit::WebPage::loadData):
91         Pass the baseURL, not blankURL(), and remove an unnecessary multiplication by sizeof(uint8_t) which is always 1.
92
93 2013-07-01  Kangil Han  <kangil.han@samsung.com>
94
95         Adopt toHTMLTextAreaElement for code cleanup
96         https://bugs.webkit.org/show_bug.cgi?id=118226
97
98         Reviewed by Andreas Kling.
99
100         To enhance readability, this patch adopts toHTMLTextAreaElement.
101         This also helps out to reduce duplicated use of static_cast.
102
103         * WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.cpp:
104         (WebKit::InjectedBundleNodeHandle::htmlTextAreaElementLastChangeWasUserEdit):
105         * WebProcess/Plugins/PDF/PDFPluginTextAnnotation.mm:
106         (WebKit::PDFPluginTextAnnotation::createAnnotationElement):
107         * WebProcess/WebCoreSupport/WebEditorClient.cpp:
108         (WebKit::WebEditorClient::textDidChangeInTextArea):
109         * WebProcess/WebPage/WebFrame.cpp:
110         (WebKit::WebFrame::containsAnyFormControls):
111
112 2013-06-28  Andreas Kling  <akling@apple.com>
113
114         Fix Windows builds after deprecatedCharactersWithNullTermination() removal.
115
116         * Platform/CoreIPC/win/ConnectionWin.cpp:
117         (CoreIPC::Connection::createServerAndClientIdentifiers):
118
119 2013-06-28  Tim Horton  <timothy_horton@apple.com>
120
121         [wk2] WKView shouldn't force scrolling off if shouldClipToVisibleRect is set
122         https://bugs.webkit.org/show_bug.cgi?id=118174
123         <rdar://problem/14301175>
124
125         Reviewed by Anders Carlsson.
126
127         * UIProcess/API/mac/WKView.mm:
128         (-[WKView _updateViewExposedRect]):
129         Pass whether or not clips-to-visibleRect is enabled down to the WebPageProxy.
130
131         (-[WKView setMinimumSizeForAutoLayout:]):
132         Disable scrolling when using autolayout instead of when using clips-to-visibleRect.
133
134         (-[WKView setShouldClipToVisibleRect:]):
135         Clipping to the WKView's visibleRect does not strictly require scrolling to be disabled,
136         and in fact there are cases (RTL/TB pagination) where we *must* scroll, even when the view
137         is big enough to fit the content (the case clip-to-visibleRect was added for).
138
139         * UIProcess/WebPageProxy.cpp:
140         (WebKit::WebPageProxy::WebPageProxy):
141         * UIProcess/WebPageProxy.h:
142         * UIProcess/mac/WebPageProxyMac.mm:
143         (WebKit::WebPageProxy::viewExposedRectChanged):
144         (WebKit::WebPageProxy::exposedRectChangedTimerFired):
145         Keep track of and forward to the drawing area whether or not clips-to-visibleRect is enabled.
146
147         * WebProcess/WebPage/DrawingArea.h:
148         (WebKit::DrawingArea::setClipsToExposedRect): Added.
149         (WebKit::DrawingArea::didChangeScrollOffsetForAnyFrame): Added a missing space.
150
151         * WebProcess/WebPage/WebPage.cpp:
152         (WebKit::WebPage::viewExposedRectChanged):
153         * WebProcess/WebPage/WebPage.h:
154         * WebProcess/WebPage/WebPage.messages.in:
155         Forward clips-to-visibleRect enabled state to the drawing area.
156
157         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.h:
158         Add storage for m_clipsToExposedRect.
159
160         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
161         (WebKit::TiledCoreAnimationDrawingArea::TiledCoreAnimationDrawingArea):
162         (WebKit::TiledCoreAnimationDrawingArea::flushLayers):
163         (WebKit::TiledCoreAnimationDrawingArea::setClipsToExposedRect):
164         (WebKit::TiledCoreAnimationDrawingArea::updateMainFrameClipsToExposedRect):
165         (WebKit::TiledCoreAnimationDrawingArea::createPageOverlayLayer):
166         (WebKit::TiledCoreAnimationDrawingArea::didCommitChangesForLayer):
167         Check m_clipsToExposedRect instead of the main-frame's isScrollable() to determine
168         whether we should tell our TiledBackings to clip to the exposed rect we provide.
169
170         We don't need to listen to mainFrameScrollabilityChanged anymore.
171
172 2013-06-28  Gavin Barraclough  <barraclough@apple.com>
173
174         Stale occlusion state after moving page back into window
175         https://bugs.webkit.org/show_bug.cgi?id=118202
176
177         Reviewed by Anders Carlsson.
178         
179         We need to update the occlusion state when the page goes back into the window.
180
181         * UIProcess/API/mac/WKView.mm:
182         (-[WKView viewDidMoveToWindow]):
183             - update occlusion state.
184
185 2013-06-28  Gwang Yoon Hwang  <ryumiel@company100.net>
186
187         Coordinated Graphics: Separate CoordinatedLayerTreeHost into CoordinatedLayerTreeHost and CompositingCoordinator
188         https://bugs.webkit.org/show_bug.cgi?id=104360
189
190         Reviewed by Noam Rosenthal.
191
192         The CoordinatedLayerTreeHost has too many responsibilities. It
193         implements LayerTreeHost, GraphicsLayerClient,
194         CoordinatedGraphicsLayerClient, CoordinatedImageBacking::Client,
195         UpdateAtlas::Client, GraphicsLayerFactory and
196         WebCustomFilterProgramProxyClient.
197
198         This refactoring reduces the responsibilities of CoordinatedLayerTreeHost.
199
200         This patch introduces a new class called CompositingCoordinator, which
201         takes the responsibility of managing compositing resources in
202         WebProcess.
203
204         CoordinatedLayerTreeHost is responsible only for the scheduling and
205         IPC-specific stuff, which are relevant only for WebKit2.
206
207         No new tests, covered by existing tests.
208
209         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.cpp:
210         (WebKit::CoordinatedLayerTreeHost::~CoordinatedLayerTreeHost):
211         (WebKit::CoordinatedLayerTreeHost::CoordinatedLayerTreeHost):
212         (WebKit::CoordinatedLayerTreeHost::setRootCompositingLayer):
213         (WebKit::CoordinatedLayerTreeHost::invalidate):
214         (WebKit::CoordinatedLayerTreeHost::forceRepaint):
215         (WebKit::CoordinatedLayerTreeHost::sizeDidChange):
216         (WebKit::CoordinatedLayerTreeHost::setVisibleContentsRect):
217         (WebKit::CoordinatedLayerTreeHost::renderNextFrame):
218         (WebKit::CoordinatedLayerTreeHost::purgeBackingStores):
219         (WebKit::CoordinatedLayerTreeHost::willSyncLayerState):
220         (WebKit::CoordinatedLayerTreeHost::prepareCustomFilterProxiesForAnimations):
221         (WebKit::CoordinatedLayerTreeHost::checkCustomFilterProgramProxies):
222         (WebKit::CoordinatedLayerTreeHost::removeCustomFilterProgramProxy):
223         (WebKit::CoordinatedLayerTreeHost::didFlushRootLayer):
224         (WebKit::CoordinatedLayerTreeHost::performScheduledLayerFlush):
225         (WebKit::CoordinatedLayerTreeHost::createPageOverlayLayer):
226         (WebKit::CoordinatedLayerTreeHost::paintLayerContents):
227         (WebKit::CoordinatedLayerTreeHost::commitSceneState):
228         (WebKit::CoordinatedLayerTreeHost::deviceOrPageScaleFactorChanged):
229         (WebKit::CoordinatedLayerTreeHost::graphicsLayerFactory):
230         (WebKit::CoordinatedLayerTreeHost::scheduleAnimation):
231         (WebKit::CoordinatedLayerTreeHost::commitScrollOffset):
232         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.h:
233         * WebProcess/WebPage/LayerTreeHost.h:
234
235 2013-06-28  Anders Carlsson  <andersca@apple.com>
236
237         Make the UI process run the Java Updater
238         https://bugs.webkit.org/show_bug.cgi?id=118197
239         <rdar://problem/14255677>
240
241         Reviewed by Sam Weinig.
242
243         Patch the relevant NSWorkspace method and pipe through the request to launch the Java updater to the UI process.
244
245         * PluginProcess/PluginProcess.h:
246         * PluginProcess/mac/PluginProcessMac.mm:
247         (WebKit::replacedNSWorkspace_launchApplicationAtURL_options_configuration_error):
248         (WebKit::initializeCocoaOverrides):
249         (WebKit::PluginProcess::launchApplicationAtURL):
250         * UIProcess/Plugins/PluginProcessProxy.h:
251         * UIProcess/Plugins/PluginProcessProxy.messages.in:
252         * UIProcess/Plugins/mac/PluginProcessProxyMac.mm:
253         (WebKit::isJavaUpdaterURL):
254         (WebKit::shouldLaunchApplicationAtURL):
255         (WebKit::PluginProcessProxy::launchApplicationAtURL):
256
257 2013-06-28  Tim Horton  <timothy_horton@apple.com>
258
259         WARN_UNUSED_RESULT can't be used in API headers, but WKBundlePageExtendIncrementalRenderingSuppression tries to
260         https://bugs.webkit.org/show_bug.cgi?id=118196
261         <rdar://problem/14303613>
262
263         Reviewed by Anders Carlsson.
264
265         * WebProcess/InjectedBundle/API/c/WKBundlePagePrivate.h:
266
267 2013-06-28  Andreas Kling  <akling@apple.com>
268
269         Don't fire process-became-responsive callback when disconnecting it.
270         <http://webkit.org/b/118166>
271
272         Reviewed by Anders Carlsson.
273
274         When disconnecting from a web process, call ResponsivenessTimer::invalidate() instead of
275         stop() to avoid firing the didBecomeResponsive() callback.
276
277         This lets the UI process react faster to actually unresponsive processes.
278
279         * UIProcess/WebProcessProxy.cpp:
280         (WebKit::WebProcessProxy::disconnect):
281
282 2013-06-28  Sergio Villar Senin  <svillar@igalia.com>
283
284         [WK2][GTK] 100% CPU usage rendering a page with animations
285         https://bugs.webkit.org/show_bug.cgi?id=117703
286
287         Reviewed by Martin Robinson.
288
289         Unconditionally update the value of m_lastFlushTime in
290         ::flushAndRenderLayers. By doing that we avoid a neverending
291         sequence of layer flushes that happened when m_lastFlushTime==0
292         and flushPendingLayerChanges() was false. In that situation the
293         value m_lastFlushTime was never updated so a new flush was always
294         rescheduled.
295
296         * WebProcess/WebPage/gtk/LayerTreeHostGtk.cpp:
297         (WebKit::LayerTreeHostGtk::flushAndRenderLayers):
298
299 2013-06-28  Andres Gomez  <agomez@igalia.com>
300
301         [GTK] MiniBrowser doesn't solve the saving location when there are no XDG settings
302         https://bugs.webkit.org/show_bug.cgi?id=117538
303
304         Reviewed by Carlos Garcia Campos.
305
306         If the XDG specification is not working for the "Downloads"
307         directory, let's use HOME as fallback.
308
309         * UIProcess/API/gtk/WebKitDownload.cpp:
310         (webkitDownloadDecideDestination):
311
312 2013-06-28  Dariusz Frankiewicz  <d.frankiewic@samsung.com>
313
314         [EFL][WK2] Add spellcheck API tests in unit tests.
315         https://bugs.webkit.org/show_bug.cgi?id=118123
316
317         Reviewed by Christophe Dumez.
318
319         According to discussion in bug https://bugs.webkit.org/show_bug.cgi?id=113742
320         we're moving spelling tests from layout tests to unit tests.
321
322         * UIProcess/API/efl/tests/resources/spelling_selection_tests.html: Added.
323         New file is needed to make tests, with and without spellcheck attribute.
324         File contains basic site with content editable fields and buttons which select
325         different parts of misspelled words.
326
327         * UIProcess/API/efl/tests/test_ewk2_text_checker.cpp:
328         (countContextMenuItems):
329         Added method used to count number of items in context menu.
330
331 2013-06-27  Kangil Han  <kangil.han@samsung.com>
332
333         Adopt is/toHTMLInputElement for code cleanup
334         https://bugs.webkit.org/show_bug.cgi?id=118130
335
336         Reviewed by Antti Koivisto.
337
338         To enhance readability, this patch adopts is/toHTMLInputElement.
339         This also helps out to reduce duplicated use of static_cast.
340
341         * WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.cpp:
342         (WebKit::InjectedBundleNodeHandle::setHTMLInputElementValueForUser):
343         (WebKit::InjectedBundleNodeHandle::isHTMLInputElementAutofilled):
344         (WebKit::InjectedBundleNodeHandle::setHTMLInputElementAutofilled):
345         (WebKit::InjectedBundleNodeHandle::htmlInputElementLastChangeWasUserEdit):
346         * WebProcess/Plugins/PDF/PDFPluginTextAnnotation.mm:
347         (WebKit::PDFPluginTextAnnotation::createAnnotationElement):
348         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
349         (WebKit::WebChromeClient::focusedNodeChanged):
350         * WebProcess/WebCoreSupport/WebEditorClient.cpp:
351         (WebKit::WebEditorClient::textFieldDidBeginEditing):
352         (WebKit::WebEditorClient::textFieldDidEndEditing):
353         (WebKit::WebEditorClient::textDidChangeInTextField):
354         (WebKit::WebEditorClient::doTextFieldCommandFromEvent):
355         (WebKit::WebEditorClient::textWillBeDeletedInTextField):
356         * WebProcess/WebPage/WebFrame.cpp:
357         (WebKit::WebFrame::containsAnyFormControls):
358         * WebProcess/WebPage/WebPage.cpp:
359         (WebKit::WebPage::editorState):
360
361 2013-06-27  Eunmi Lee  <eunmi15.lee@samsung.com>
362
363         [EFL][WK2] Add WK2 C API to handle touch events.
364         https://bugs.webkit.org/show_bug.cgi?id=108915
365
366         Reviewed by Gyuyoung Kim.
367
368         Touch events for our target platforms differ (XInput2, Wayland, Tizen) so
369         for the EFL port we want to be able to feed events manually.
370
371         To keep our current API for desktop EFL/Enlightenment working, we convert
372         our currently limited EFL events to the new EFL specific C EwkTouchPoint
373         and EwkTouchEvent type.
374
375         EwkTouchPoint and EwkTouchEvent are exposed as WKTouchPointRef and
376         WKTouchEventRef, so they are opaque in the applications.
377
378         The WKViewSendTouchEvent can be used for any use-case (platform/product)
379         not involving the EFL events.
380
381         At the same time we make sure to avoid using WK2 internals in our EFL API
382         implementation.
383
384         * PlatformEfl.cmake:
385         * Shared/API/c/efl/WKBaseEfl.h:
386         * Shared/APIObject.h:
387         * Shared/NativeWebTouchEvent.h:
388         (WebKit::NativeWebTouchEvent::nativeEvent):
389         * Shared/efl/NativeWebTouchEventEfl.cpp:
390         (WebKit::NativeWebTouchEvent::NativeWebTouchEvent):
391         * Shared/efl/WebEventFactory.cpp:
392         (WebKit::toWebPlatformTouchPointState):
393         (WebKit::toWebEventType):
394         (WebKit::toWebEventModifiers):
395         (WebKit::WebEventFactory::createWebTouchEvent):
396         * Shared/efl/WebEventFactory.h:
397         * UIProcess/API/C/efl/WKAPICastEfl.h:
398         * UIProcess/API/C/efl/WKEventEfl.cpp: Added.
399         (WKTouchPointCreate):
400         (WKTouchEventCreate):
401         * UIProcess/API/C/efl/WKEventEfl.h: Added.
402         * UIProcess/API/C/efl/WKViewEfl.cpp:
403         (WKViewSendTouchEvent):
404         * UIProcess/API/C/efl/WKViewEfl.h:
405         * UIProcess/API/efl/EwkView.cpp:
406         (toWKTouchPointState):
407         (toWKEventModifiers):
408         (EwkView::feedTouchEvent):
409         (EwkView::feedTouchEvents):
410         * UIProcess/efl/EwkTouchEvent.cpp: Added.
411         (WebKit::EwkTouchEvent::EwkTouchEvent):
412         * UIProcess/efl/EwkTouchEvent.h: Added.
413         (WebKit::EwkTouchEvent::create):
414         (WebKit::EwkTouchEvent::eventType):
415         (WebKit::EwkTouchEvent::touchPoints):
416         (WebKit::EwkTouchEvent::modifiers):
417         (WebKit::EwkTouchEvent::timestamp):
418         (WebKit::EwkTouchEvent::type):
419         * UIProcess/efl/EwkTouchPoint.cpp: Added.
420         (WebKit::EwkTouchPoint::EwkTouchPoint):
421         * UIProcess/efl/EwkTouchPoint.h: Added.
422         (WebKit::EwkTouchPoint::create):
423         (WebKit::EwkTouchPoint::id):
424         (WebKit::EwkTouchPoint::state):
425         (WebKit::EwkTouchPoint::screenPosition):
426         (WebKit::EwkTouchPoint::position):
427         (WebKit::EwkTouchPoint::radius):
428         (WebKit::EwkTouchPoint::rotationAngle):
429         (WebKit::EwkTouchPoint::forceFactor):
430         (WebKit::EwkTouchPoint::type):
431         * UIProcess/efl/WebViewEfl.cpp:
432         (WebKit::WebViewEfl::sendTouchEvent):
433         * UIProcess/efl/WebViewEfl.h:
434
435 2013-06-27  Csaba Osztrogonác  <ossy@webkit.org>
436
437         Fix cast-align warnings in WebKit2/Platform/CoreIPC
438         https://bugs.webkit.org/show_bug.cgi?id=117987
439
440         Reviewed by Rob Buis, WK2 signed-off by Anders Carlsson.
441
442         * Platform/CoreIPC/ArgumentDecoder.cpp:
443         (CoreIPC::ArgumentDecoder::decode):
444         * Platform/CoreIPC/ArgumentEncoder.cpp:
445         (CoreIPC::ArgumentEncoder::encode):
446
447 2013-06-27  Commit Queue  <commit-queue@webkit.org>
448
449         Unreviewed, rolling out r152074.
450         http://trac.webkit.org/changeset/152074
451         https://bugs.webkit.org/show_bug.cgi?id=118137
452
453         It caused lots of layout and API test crash on Qt Wk2.
454         (Requested by kadam on #webkit).
455
456         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.cpp:
457         (WebKit::CoordinatedLayerTreeHost::~CoordinatedLayerTreeHost):
458         (WebKit::CoordinatedLayerTreeHost::CoordinatedLayerTreeHost):
459         (WebKit::CoordinatedLayerTreeHost::setRootCompositingLayer):
460         (WebKit::CoordinatedLayerTreeHost::invalidate):
461         (WebKit::CoordinatedLayerTreeHost::forceRepaint):
462         (WebKit::CoordinatedLayerTreeHost::sizeDidChange):
463         (WebKit::CoordinatedLayerTreeHost::flushPendingLayerChanges):
464         (WebKit::CoordinatedLayerTreeHost::clearPendingStateChanges):
465         (WebKit::CoordinatedLayerTreeHost::initializeRootCompositingLayerIfNeeded):
466         (WebKit::CoordinatedLayerTreeHost::syncLayerState):
467         (WebKit::CoordinatedLayerTreeHost::prepareCustomFilterProxiesIfNeeded):
468         (WebKit::CoordinatedLayerTreeHost::checkCustomFilterProgramProxies):
469         (WebKit::CoordinatedLayerTreeHost::removeCustomFilterProgramProxy):
470         (WebKit::CoordinatedLayerTreeHost::detachLayer):
471         (WebKit::CoordinatedLayerTreeHost::performScheduledLayerFlush):
472         (WebKit::CoordinatedLayerTreeHost::syncDisplayState):
473         (WebKit::CoordinatedLayerTreeHost::didPerformScheduledLayerFlush):
474         (WebKit::CoordinatedLayerTreeHost::createPageOverlayLayer):
475         (WebKit::CoordinatedLayerTreeHost::createImageBackingIfNeeded):
476         (WebKit::CoordinatedLayerTreeHost::createImageBacking):
477         (WebKit::CoordinatedLayerTreeHost::updateImageBacking):
478         (WebKit::CoordinatedLayerTreeHost::clearImageBackingContents):
479         (WebKit::CoordinatedLayerTreeHost::removeImageBacking):
480         (WebKit::CoordinatedLayerTreeHost::flushPendingImageBackingChanges):
481         (WebKit::CoordinatedLayerTreeHost::notifyAnimationStarted):
482         (WebKit::CoordinatedLayerTreeHost::notifyFlushRequired):
483         (WebKit::CoordinatedLayerTreeHost::paintContents):
484         (WebKit::CoordinatedLayerTreeHost::createGraphicsLayer):
485         (WebKit::CoordinatedLayerTreeHost::deviceScaleFactor):
486         (WebKit::CoordinatedLayerTreeHost::pageScaleFactor):
487         (WebKit::CoordinatedLayerTreeHost::createUpdateAtlas):
488         (WebKit::CoordinatedLayerTreeHost::removeUpdateAtlas):
489         (WebKit::CoordinatedLayerTreeHost::visibleContentsRect):
490         (WebKit::CoordinatedLayerTreeHost::mainContentsLayer):
491         (WebKit::CoordinatedLayerTreeHost::setVisibleContentsRect):
492         (WebKit::CoordinatedLayerTreeHost::deviceOrPageScaleFactorChanged):
493         (WebKit::CoordinatedLayerTreeHost::graphicsLayerFactory):
494         (WebKit::CoordinatedLayerTreeHost::scheduleAnimation):
495         (WebKit::CoordinatedLayerTreeHost::renderNextFrame):
496         (WebKit::CoordinatedLayerTreeHost::purgeBackingStores):
497         (WebKit::CoordinatedLayerTreeHost::paintToSurface):
498         (WebKit::CoordinatedLayerTreeHost::scheduleReleaseInactiveAtlases):
499         (WebKit::CoordinatedLayerTreeHost::releaseInactiveAtlasesTimerFired):
500         (WebKit::CoordinatedLayerTreeHost::commitScrollOffset):
501         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.h:
502         * WebProcess/WebPage/LayerTreeHost.h:
503         (WebKit::LayerTreeHost::setVisibleContentsRect):
504         (WebKit::LayerTreeHost::renderNextFrame):
505         (WebKit::LayerTreeHost::purgeBackingStores):
506
507 2013-06-27  Xabier Rodriguez Calvar  <calvaris@igalia.com>
508
509         Fixing some compiler warnings
510         https://bugs.webkit.org/show_bug.cgi?id=117791
511
512         Reviewed by Martin Robinson.
513
514         * UIProcess/API/gtk/tests/WebExtensionTest.cpp: Properly
515         initialized GDBusInterfaceVTable.
516         * WebProcess/InjectedBundle/API/gtk/WebKitWebPage.cpp:
517         (webkitWebPageCreate): Added missing fields to the
518         WKBundlePageLoaderClient.
519
520 2013-06-27  Iago Toral Quiroga  <itoral@igalia.com>
521
522         Use consistent file names for WidgetBackingStoreGtkX11 class
523         https://bugs.webkit.org/show_bug.cgi?id=118124
524
525         Reviewed by Carlos Garcia Campos.
526
527         * UIProcess/cairo/BackingStoreCairo.cpp:
528
529 2013-06-27  Alberto Garcia  <agarcia@igalia.com>
530
531         [GTK] [WK2] Check value of WEBKIT_INJECTED_BUNDLE_PATH
532         https://bugs.webkit.org/show_bug.cgi?id=118055
533
534         Reviewed by Carlos Garcia Campos.
535
536         If the directory pointed at by WEBKIT_INJECTED_BUNDLE_PATH does
537         not exist, fall back to the system directory.
538
539         This makes MiniBrowser work outside the build tree.
540
541         * UIProcess/API/gtk/WebKitWebContext.cpp:
542         (injectedBundleDirectory):
543
544 2013-06-26  Simon Cooper  <scooper@apple.com>
545
546         Sometimes the Flash Player plugin cannot make outgoing connections
547         https://bugs.webkit.org/show_bug.cgi?id=118110
548         <rdar://problem/14270933>
549
550         Reviewed by Alexey Proskuryakov.
551
552         Allow outgoing and incoming UDP data. Tidy up the QuickTime
553         profile as it gets the UDP ability from the common profile.
554
555         * Resources/PlugInSandboxProfiles/com.apple.QuickTime Plugin.plugin.sb:
556         * Resources/PlugInSandboxProfiles/com.apple.WebKit.plugin-common.sb:
557
558 2013-06-26  Simon Cooper  <scooper@apple.com>
559
560         Flash Player: deny ipc-posix-sem 59918130
561         https://bugs.webkit.org/show_bug.cgi?id=118107
562         <rdar://problem/14271105>
563
564         Reviewed by Alexey Proskuryakov.
565
566         Allow same-sandbox scoped semaphores on Mavericks. Permit the
567         named semaphore for older releases.
568
569         * Resources/PlugInSandboxProfiles/com.macromedia.Flash Player.plugin.sb:
570
571 2013-06-26  Gwang Yoon Hwang  <ryumiel@company100.net>
572
573         Coordinated Graphics: Separate CoordinatedLayerTreeHost into CoordinatedLayerTreeHost and CompositingCoordinator
574         https://bugs.webkit.org/show_bug.cgi?id=104360
575
576         Reviewed by Noam Rosenthal.
577
578         The CoordinatedLayerTreeHost has too many responsibilities. It
579         implements LayerTreeHost, GraphicsLayerClient,
580         CoordinatedGraphicsLayerClient, CoordinatedImageBacking::Client,
581         UpdateAtlas::Client, GraphicsLayerFactory and
582         WebCustomFilterProgramProxyClient.
583
584         This refactoring reduces the responsibilities of CoordinatedLayerTreeHost.
585
586         This patch introduces a new class called CompositingCoordinator, which
587         takes the responsibility of managing compositing resources in
588         WebProcess.
589
590         CoordinatedLayerTreeHost is responsible only for the scheduling and
591         IPC-specific stuff, which are relevant only for WebKit2.
592
593         No new tests, covered by existing tests.
594
595         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.cpp:
596         (WebKit::CoordinatedLayerTreeHost::~CoordinatedLayerTreeHost):
597         (WebKit::CoordinatedLayerTreeHost::CoordinatedLayerTreeHost):
598         (WebKit::CoordinatedLayerTreeHost::setRootCompositingLayer):
599         (WebKit::CoordinatedLayerTreeHost::invalidate):
600         (WebKit::CoordinatedLayerTreeHost::forceRepaint):
601         (WebKit::CoordinatedLayerTreeHost::sizeDidChange):
602         (WebKit::CoordinatedLayerTreeHost::setVisibleContentsRect):
603         (WebKit::CoordinatedLayerTreeHost::renderNextFrame):
604         (WebKit::CoordinatedLayerTreeHost::purgeBackingStores):
605         (WebKit::CoordinatedLayerTreeHost::willSyncLayerState):
606         (WebKit::CoordinatedLayerTreeHost::prepareCustomFilterProxiesForAnimations):
607         (WebKit::CoordinatedLayerTreeHost::checkCustomFilterProgramProxies):
608         (WebKit::CoordinatedLayerTreeHost::removeCustomFilterProgramProxy):
609         (WebKit::CoordinatedLayerTreeHost::didFlushRootLayer):
610         (WebKit::CoordinatedLayerTreeHost::performScheduledLayerFlush):
611         (WebKit::CoordinatedLayerTreeHost::createPageOverlayLayer):
612         (WebKit::CoordinatedLayerTreeHost::paintLayerContents):
613         (WebKit::CoordinatedLayerTreeHost::commitSceneState):
614         (WebKit::CoordinatedLayerTreeHost::deviceOrPageScaleFactorChanged):
615         (WebKit::CoordinatedLayerTreeHost::graphicsLayerFactory):
616         (WebKit::CoordinatedLayerTreeHost::scheduleAnimation):
617         (WebKit::CoordinatedLayerTreeHost::commitScrollOffset):
618         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.h:
619         * WebProcess/WebPage/LayerTreeHost.h:
620
621 2013-06-26  Simon Cooper  <scooper@apple.com>
622
623         Silverlight deny ipc-posix-sem LC_Mutex playing Amazon Prime videos
624         https://bugs.webkit.org/show_bug.cgi?id=118102
625         <rdar://problem/14194077>
626
627         Reviewed by Alexey Proskuryakov.
628
629         Allow same-sandbox scoped semaphores on Mavericks. Permit the
630         named semaphore for older releases.
631
632         * Resources/PlugInSandboxProfiles/com.microsoft.SilverlightPlugin.sb:
633
634 2013-06-26  Simon Cooper  <scooper@apple.com>
635
636         Update ColorSync shared memory names in plug-in sandbox profile
637         https://bugs.webkit.org/show_bug.cgi?id=118099
638
639         Reviewed by Alexey Proskuryakov.
640
641         Update the common profile to use the names used in Mavericks
642
643         * Resources/PlugInSandboxProfiles/com.apple.WebKit.plugin-common.sb:
644
645 2013-06-26  Anders Carlsson  <andersca@apple.com>
646
647         Deprecate StringImpl::charactersWithNullTermination
648         https://bugs.webkit.org/show_bug.cgi?id=118108
649
650         Reviewed by Beth Dakin.
651
652         Rename calls to charactersWithNullTermination to deprecatedCharactersWithNullTermination.
653
654         * Platform/CoreIPC/win/ConnectionWin.cpp:
655         (CoreIPC::Connection::createServerAndClientIdentifiers):
656
657 2013-06-26  Simon Cooper  <scooper@apple.com>
658
659         QuickTime plug-in cannot update com.apple.quicktime.plugin.preferences.plist file
660         https://bugs.webkit.org/show_bug.cgi?id=118098
661         <rdar://problem/13888138>
662
663         Reviewed by Alexey Proskuryakov.
664
665         Allow the preference file to be written
666
667         * Resources/PlugInSandboxProfiles/com.apple.QuickTime Plugin.plugin.sb:
668
669 2013-06-24  Simon Cooper  <scooper@apple.com>
670
671         Silverlight triggers sandbox violations: deny network-bind 0.0.0.0:0
672         https://bugs.webkit.org/show_bug.cgi?id=117966
673         <rdar://problem/13927918>
674
675         Reviewed by Sam Weinig.
676
677         Allow assigning (via bind) an ephemeral port before connecting
678
679         * Resources/PlugInSandboxProfiles/com.apple.QuickTime Plugin.plugin.sb:
680         * Resources/PlugInSandboxProfiles/com.macromedia.Flash Player.plugin.sb:
681         * Resources/PlugInSandboxProfiles/com.microsoft.SilverlightPlugin.sb:
682         * Resources/PlugInSandboxProfiles/com.oracle.java.JavaAppletPlugin.sb:
683
684 2013-06-24  Simon Cooper  <scooper@apple.com>
685
686         PluginProcess deny file-read-data /Network/Library under addVolumeTracker
687         https://bugs.webkit.org/show_bug.cgi?id=117965
688         <rdar://problem/14121247>
689
690         Reviewed by Alexey Proskuryakov.
691
692         Silently deny reading /Network/Applications and 
693         /Network/Library.
694
695         * Resources/PlugInSandboxProfiles/com.apple.WebKit.plugin-common.sb:
696
697 2013-06-24  Kangil Han  <kangil.han@samsung.com>
698
699         Adopt is/toHTMLFormElement for code cleanup
700         https://bugs.webkit.org/show_bug.cgi?id=117937
701
702         Reviewed by Andreas Kling.
703
704         This refers to http://src.chromium.org/viewvc/blink?view=revision&revision=152859
705
706         To enhance readibility, this patch adopts is/toHTMLFormElement.
707         This also helps out to reduce duplicated use of static_cast.
708
709         * WebProcess/WebPage/WebFrame.cpp:
710         (WebKit::WebFrame::containsAnyFormElements):
711
712 2013-06-24  Simon Cooper  <scooper@apple.com>
713
714         deny file-read-data /Library/CoreMediaIO/Plug-Ins/DAL
715         https://bugs.webkit.org/show_bug.cgi?id=117964
716         <rdar://problem/14036864>
717
718         Reviewed by Alexey Proskuryakov.
719
720         Permit reading of the /Library/CoreMediaIO/Plug-Ins/DAL
721         subdirectory.
722
723         * Resources/PlugInSandboxProfiles/com.apple.WebKit.plugin-common.sb:
724
725 2013-06-24  Simon Cooper  <scooper@apple.com>
726
727         Repeating sandbox violations when playing Amazon Prime videos with Flash
728         https://bugs.webkit.org/show_bug.cgi?id=117953
729         <rdar://problem/14193693>
730
731         Reviewed by Alexey Proskuryakov.
732
733         Add some missing "standard" files for network service lookups
734
735         * Resources/PlugInSandboxProfiles/com.apple.WebKit.plugin-common.sb:
736
737 2013-06-24  Simon Cooper  <scooper@apple.com>
738
739         Plug-in sandbox violations attempting to access com.apple.CoreGraphics.plist
740         https://bugs.webkit.org/show_bug.cgi?id=117963
741         <rdar://problem/14084234>
742
743         Reviewed by Alexey Proskuryakov.
744
745         Permit the reading of the com.apple.CoreGraphics preference file
746
747         * Resources/PlugInSandboxProfiles/com.apple.WebKit.plugin-common.sb:
748
749 2013-06-24  Simon Cooper  <scooper@apple.com>
750
751         com.oracle.javadeployment.plist is not correctly specified in the JavaApplet plugin profile
752         https://bugs.webkit.org/show_bug.cgi?id=117961
753         <rdar://problem/14223823>
754
755         Reviewed by Alexey Proskuryakov.
756
757         Remove the trailing extraneous .plist from the preference file rule
758
759         * Resources/PlugInSandboxProfiles/com.oracle.java.JavaAppletPlugin.sb:
760
761 2013-06-24  Simon Cooper  <scooper@apple.com>
762
763         PluginProcess sandbox violations on com.apple.networkConnect.plist when resetting Safari
764         https://bugs.webkit.org/show_bug.cgi?id=117958
765         <rdar://problem/13938149>
766
767         Reviewed by Alexey Proskuryakov.
768
769         Allow reading the com.apple.networkConnect plist.
770
771         * Resources/PlugInSandboxProfiles/com.apple.ist.ds.appleconnect.webplugin.sb:
772
773 2013-06-24  Simon Cooper  <scooper@apple.com>
774
775         Java sandbox violation ipc-posix-shm-read-data /tmp/com.apple.csseed.67
776         https://bugs.webkit.org/show_bug.cgi?id=117954
777         <rdar://problem/14166577>
778
779         Reviewed by Alexey Proskuryakov.
780
781         Permit read access to this shared memory segment
782
783         * Resources/PlugInSandboxProfiles/com.apple.WebKit.plugin-common.sb:
784
785 2013-06-24  Simon Cooper  <scooper@apple.com>
786
787         Plugin Sandbox violation in /Library/Audio/Sounds/Banks
788         https://bugs.webkit.org/show_bug.cgi?id=117957
789         <rdar://problem/14163582>
790
791         Reviewed by Alexey Proskuryakov.
792
793         Permit read access to subdirectories under /Library/Audio/Sounds
794
795         * Resources/PlugInSandboxProfiles/com.apple.WebKit.plugin-common.sb:
796
797 2013-06-24  Nick Diego Yamane  <nick.yamane@openbossa.org>
798
799         Make sure m_iconDatabaseImpl is not null before closing it
800         https://bugs.webkit.org/show_bug.cgi?id=117943
801
802         Reviewed by Simon Fraser.
803
804         Since r150474 WebIconDatabase is closed unconditionally in
805         TestController destructor, in that case WebKitTestRunner crashes
806         when no icon database path is set. This misbehavior was observed in
807         ports such as efl and nix.
808         In this patch, WebIconDatabase::close() calls m_iconDatabaseImpl->close()
809         only if m_iconDatabaseImpl is not null, as it's already being done in other
810         WebIconDatabase's methods, such as isOpen().
811
812         * UIProcess/WebIconDatabase.cpp:
813         (WebKit::WebIconDatabase::close):
814
815 2013-06-24  Ruth Fong  <ruth_fong@apple.com>
816
817         Expose the mediaHasAudio() function in WK2
818         https://bugs.webkit.org/show_bug.cgi?id=117946
819         <rdar://problem/14250527>
820
821         Reviewed by Beth Dakin.
822
823         Exposes the WebCore::HTMLMediaElement::mediaHasAudio() function
824         in WK2.
825
826         * WebProcess/InjectedBundle/API/c/WKBundleHitTestResult.cpp:
827         (WKBundleHitTestResultMediaHasAudio): Added.
828         * WebProcess/InjectedBundle/API/c/WKBundleHitTestResult.h:
829         * WebProcess/InjectedBundle/InjectedBundleHitTestResult.cpp:
830         (WebKit::InjectedBundleHitTestResult::mediaHasAudio): Added.
831         * WebProcess/InjectedBundle/InjectedBundleHitTestResult.h:
832
833 2013-06-24  Anders Carlsson  <andersca@apple.com>
834
835         REGRESSION (r147591): can't type in Adobe Connect
836         https://bugs.webkit.org/show_bug.cgi?id=117947
837         <rdar://problem/14223539>
838
839         Reviewed by Andreas Kling.
840
841         With the change in r147591, it is now possible for a plug-in element to be focused before the plug-in
842         starts. Handle this by focusing the plug-in right after it's started if necessary.
843
844         * WebProcess/Plugins/PluginView.cpp:
845         (WebKit::PluginView::didInitializePlugin):
846
847 2013-06-24  Simon Fraser  <simon.fraser@apple.com>
848
849         Move displayID stuff from Widget to Chrome
850         https://bugs.webkit.org/show_bug.cgi?id=117944
851
852         Reviewed by Anders Carlsson.
853
854         In r151877 I polluted Widget with displayID-related stuff. This would
855         be better on HostWindow, so move it there. This is a net code reduction,
856         and eliminates PlatformScreenMac.h, and the NSScreen category.
857
858         * WebProcess/WebPage/WebPage.cpp:
859         (WebKit::WebPage::windowScreenDidChange): Go via chrome().
860
861 2013-06-24  Krzysztof Wolanski  <k.wolanski@samsung.com>
862
863         [EFL][WK2] Implement unit test callback: onWordGuesses.
864         https://bugs.webkit.org/show_bug.cgi?id=117794
865
866         Reviewed by Christophe Dumez.
867
868         * UIProcess/API/efl/tests/test_ewk2_text_checker.cpp:
869         (onWordGuesses):
870         Add client suggestions for the word.
871
872         (checkClientSuggestionsForWord):
873         Verify the suggestions that were given by the client.
874
875 2013-06-17  Darin Adler  <darin@apple.com>
876
877         Sort all the Xcode project files
878         https://bugs.webkit.org/show_bug.cgi?id=117696
879
880         Reviewed by Anders Carlsson.
881
882         * WebKit2.xcodeproj/project.pbxproj: Ran the sort-Xcode-project-file script.
883
884 2013-06-22  Dean Jackson  <dino@apple.com>
885
886         Slightly reduce width threshold on detection of primary snapshotted Plug-In
887         https://bugs.webkit.org/show_bug.cgi?id=117914
888         <rdar://problem/14136687>
889
890         Reviewed by Simon Fraser.
891
892         We've noticed some content that should be detected as the primary snapshotted plug-in,
893         but is just a bit smaller than our 450x300 minimum threshold. Reduce the width to 400.
894
895         * WebProcess/WebPage/WebPage.cpp: Change primarySnapshottedPlugInMinimumWidth from 450 to 400.
896
897 2013-06-22  Simon Fraser  <simon.fraser@apple.com>
898
899         screen.availWidth always returns width of primary display
900         https://bugs.webkit.org/show_bug.cgi?id=117863
901
902         Reviewed by Geoffrey Garen.
903     
904         In WebKit2, Widgets have no platformWidget, so trying to get to the
905         NSScreen via the platform widget's window never succeeded, and we always
906         fell back on getting info for the main display.
907
908         However, we were already pushing the WKView's displayID down to the
909         WebProcess for the requestAnimationFrame infrastructure, so use that.
910         
911         The WebProcess would not receive a displayID for a WKView until the window
912         was activated; fix by calling -doWindowDidChangeScreen when the view
913         moves to a window, rather than doing it from -_windowDidBecomeKey:.
914         
915         * UIProcess/API/mac/WKView.mm:
916         (-[WKView viewDidMoveToWindow]):
917         (-[WKView _windowDidBecomeKey:]):
918
919 2013-06-21  Carlos Garcia Campos  <cgarcia@igalia.com>
920
921         [GTK] Do not try to load videos in unit tests
922         https://bugs.webkit.org/show_bug.cgi?id=117866
923
924         Reviewed by Philippe Normand.
925
926         It makes the tests slower, and generates and error because we use
927         a fake src.
928
929         * UIProcess/API/gtk/tests/TestContextMenu.cpp:
930         (testContextMenuDefaultMenu): Use preload='none' in video tag.
931         * UIProcess/API/gtk/tests/TestWebKitWebView.cpp:
932         (testWebViewMouseTarget): Ditto.
933
934 2013-06-21  Christophe Dumez  <ch.dumez@sisa.samsung.com>
935
936         REGRESSION (r150663): Using webkitAudioContext in Inspector makes it undefined everywhere
937         https://bugs.webkit.org/show_bug.cgi?id=117825
938
939         Reviewed by Kentaro Hara.
940
941         Use Settings to enable Web Audio instead of RuntimeEnabledFeatures.
942
943         * WebProcess/InjectedBundle/InjectedBundle.cpp:
944         (WebKit::InjectedBundle::overrideBoolPreferenceForTestRunner):
945         * WebProcess/WebPage/WebPage.cpp:
946         (WebKit::WebPage::updatePreferences):
947
948 2013-06-21  Sergio Correia  <sergio.correia@openbossa.org>
949
950         [WK2][EFL]: Invalidate the ProcessLauncher when the process is terminated before it has finished launching
951         https://bugs.webkit.org/show_bug.cgi?id=117865
952
953         Reviewed by Christophe Dumez.
954
955         Original patch from Carlos Garcia Campos for the Gtk port.
956
957         * UIProcess/Launcher/efl/ProcessLauncherEfl.cpp:
958         (WebKit::ProcessLauncher::terminateProcess): If process is still
959         launching, just invalidate the launcher. Reset the process
960         identifier after killing the process.
961
962 2013-06-20  Carlos Garcia Campos  <cgarcia@igalia.com>
963
964         [GTK] Migrate WebKitWebResource to GTask
965         https://bugs.webkit.org/show_bug.cgi?id=117152
966
967         Reviewed by Gustavo Noronha Silva.
968
969         * UIProcess/API/gtk/WebKitWebResource.cpp:
970         (resourceDataCallback):
971         (webkit_web_resource_get_data):
972         (webkit_web_resource_get_data_finish):
973
974 2013-06-20  Sergio Correia  <sergio.correia@openbossa.org>
975
976         [WK2] Looping for EINTR on close() is incorrect for Linux, at least
977         https://bugs.webkit.org/show_bug.cgi?id=117266
978
979         Reviewed by Darin Adler.
980
981         Call closeWithRetry() to work around a difference in how the retry needs to
982         be done on Linux.
983
984         * Platform/CoreIPC/unix/AttachmentUnix.cpp:
985         (CoreIPC::Attachment::dispose):
986         * Platform/CoreIPC/unix/ConnectionUnix.cpp:
987         (CoreIPC::Connection::platformInvalidate):
988         * Platform/unix/SharedMemoryUnix.cpp:
989         (WebKit::SharedMemory::Handle::~Handle):
990         (WebKit::SharedMemory::create):
991         (WebKit::SharedMemory::~SharedMemory):
992         (WebKit::SharedMemory::createHandle):
993         * PluginProcess/PluginProcess.cpp:
994         (WebKit::PluginProcess::createWebProcessConnection):
995         * SharedWorkerProcess/SharedWorkerProcess.cpp:
996         (WebKit::SharedWorkerProcess::createWebProcessConnection):
997         * UIProcess/Launcher/qt/ProcessLauncherQt.cpp:
998         (WebKit::ProcessLauncher::launchProcess): All these places had
999         ``close-followed-by-EINTR-handling'' replaced with the new closeWithRetry()
1000         function added in this commit.
1001
1002 2013-06-20  Brady Eidson  <beidson@apple.com>
1003
1004         WebProcess hangs loading eff.org (Waiting forever on a sync XHR, NetworkProcess unable to service it).
1005         <rdar://problem/14112329> and https://bugs.webkit.org/show_bug.cgi?id=117842
1006
1007         Reviewed by Alexey Proskuryakov.
1008
1009         * NetworkProcess/HostRecord.cpp:
1010         (WebKit::removeLoaderFromQueue): Utility to clear a Loader out of a LoaderQueue.
1011         (WebKit::HostRecord::removeLoader): Use removeLoaderFromQueue, and also try to clear the loader from m_syncLoadersPending.
1012         (WebKit::HostRecord::servePendingRequestsForQueue): Small refactoring/cleanup.
1013         (WebKit::HostRecord::limitsRequests): Change so that if the number of loaders in flight is exactly equal to the limit, then
1014           allow serving a synchronous loader to go exactly one beyond the limit.
1015         * NetworkProcess/HostRecord.h:
1016
1017         Make the static maxRequestsInFlightPerHost a member of the NetworkResourceLoadScheduler, instead:
1018         * NetworkProcess/NetworkResourceLoadScheduler.cpp:
1019         (WebKit::NetworkResourceLoadScheduler::NetworkResourceLoadScheduler):
1020         (WebKit::NetworkResourceLoadScheduler::hostForURL):
1021         * NetworkProcess/NetworkResourceLoadScheduler.h:
1022
1023         * NetworkProcess/mac/NetworkResourceLoadSchedulerMac.mm:
1024         (WebKit::NetworkResourceLoadScheduler::platformInitializeMaximumHTTPConnectionCountPerHost): Tell CFNetwork to allow
1025           7 connections per host instead of 6, but tell the scheduler that 6 is still the normal limit.
1026
1027 2013-06-20  Grzegorz Czajkowski  <g.czajkowski@samsung.com>
1028
1029         [EFL][WK2] Update text checker documentation.
1030         https://bugs.webkit.org/show_bug.cgi?id=117828
1031
1032         Reviewed by Christophe Dumez.
1033
1034         * UIProcess/API/efl/ewk_text_checker.h:
1035         The client is not responsible for destroying the memory.
1036
1037 2013-06-19  Sam Weinig  <sam@webkit.org>
1038
1039         Expose plug-ins CFBundleShortVersionString in the WKPluginInformation dictionary
1040         https://bugs.webkit.org/show_bug.cgi?id=117816
1041
1042         Reviewed by Geoffrey Garen.
1043
1044         - Adds a new key for the WKPluginInformation dictionary: WKPluginInformationBundleShortVersionKey().
1045
1046         * Shared/API/c/WKPluginInformation.cpp:
1047         (WKPluginInformationBundleShortVersionKey):
1048         * Shared/API/c/WKPluginInformation.h:
1049         * Shared/Plugins/Netscape/PluginInformation.cpp:
1050         (WebKit::pluginInformationBundleShortVersionKey):
1051         * Shared/Plugins/Netscape/PluginInformation.h:
1052         * Shared/Plugins/Netscape/mac/NetscapePluginModuleMac.mm:
1053         (WebKit::NetscapePluginModule::getPluginInfo):
1054         * Shared/Plugins/Netscape/mac/PluginInformationMac.mm:
1055         (WebKit::getPlatformPluginModuleInformation):
1056         * Shared/Plugins/PluginModuleInfo.h:
1057
1058 2013-06-19  Ruth Fong  <ruth_fong@apple.com>
1059
1060         <rdar://problem/14197983> Rename functions from Bug 117667 and add safeguards for !ENABLE(VIDEO) platforms (117765)
1061         https://bugs.webkit.org/show_bug.cgi?id=117765
1062
1063         Patch by Ruth Fong <ruth_fong@apple.com>.
1064         Reviewed by Brady Eidson.
1065
1066         * WebProcess/InjectedBundle/API/c/WKBundleHitTestResult.cpp:
1067         (WKBundleHitTestResultGetMediaType): Updated to use mediaType().
1068
1069         * WebProcess/InjectedBundle/InjectedBundleHitTestResult.cpp:
1070         (WebKit::InjectedBundleHitTestResult::mediaType): Updated.
1071         Renamed getMediaType() to mediaType() and now handles !ENABLE(VIDEO) platforms.
1072
1073         * WebProcess/InjectedBundle/InjectedBundleHitTestResult.h:
1074
1075 2013-06-19  Benjamin Poulain  <bpoulain@apple.com>
1076
1077         Use the PlatformEvent timestamp when creating a DOM Event
1078         https://bugs.webkit.org/show_bug.cgi?id=117179
1079
1080         Reviewed by Darin Adler.
1081
1082         * Shared/mac/WebEventFactory.mm:
1083         (WebKit::WebEventFactory::createWebMouseEvent):
1084         (WebKit::WebEventFactory::createWebWheelEvent):
1085         (WebKit::WebEventFactory::createWebKeyboardEvent):
1086         (WebKit::WebEventFactory::createWebGestureEvent):
1087
1088 2013-06-19  Anders Carlsson  <andersca@apple.com>
1089
1090         REGRESSION: Cannot open Silverlight preferences via context menu
1091         https://bugs.webkit.org/show_bug.cgi?id=117806
1092         <rdar://problem/14166644>
1093
1094         Reviewed by Beth Dakin.
1095
1096         Hook the LSOpenCFURLRef function and make the UI process open the URL if it's the URL for the
1097         Silverlight Preferences application. This is what we do for the Flash updater.
1098
1099         * PluginProcess/PluginProcess.h:
1100         * PluginProcess/mac/PluginProcessMac.mm:
1101         (WebKit::openCFURLRef):
1102         (WebKit::initializeShim):
1103         (WebKit::PluginProcess::openURL):
1104         * PluginProcess/mac/PluginProcessShim.h:
1105         * PluginProcess/mac/PluginProcessShim.mm:
1106         (WebKit::shimLSOpenCFURLRef):
1107         * UIProcess/Plugins/PluginProcessProxy.h:
1108         * UIProcess/Plugins/PluginProcessProxy.messages.in:
1109         * UIProcess/Plugins/mac/PluginProcessProxyMac.mm:
1110         (WebKit::isSilverlightPreferencesURL):
1111         (WebKit::shouldOpenURL):
1112         (WebKit::PluginProcessProxy::openURL):
1113
1114 2013-06-19  Krzysztof Wolanski  <k.wolanski@samsung.com>
1115
1116         [EFL][WK2] Implement unit test callback: onSettingChange.
1117         https://bugs.webkit.org/show_bug.cgi?id=117728
1118
1119         Reviewed by Christophe Dumez.
1120
1121         It is finally possible to implement missing unit tests as WebKit2-EFL
1122         has delivered sub menu (r150254).
1123         Add two unit tests for checking onSettingChange callback behaviour,
1124         when toggling "Check Spelling While Typing" in context menu.
1125
1126         Changed types inside callbacksExecutionStats struct from bit field to bool,
1127         because casting from bit field to &bool is invalid (in using waitUntilTrue method).
1128
1129         * UIProcess/API/efl/tests/test_ewk2_text_checker.cpp:
1130         (resetCallbacksExecutionStats):
1131         (onSettingChange):
1132         (findContextMenuItem):
1133         Get determined option from context menu.
1134
1135         (checkCorrectnessOfSpellingItems):
1136         Changed the name of onContextMenuShow method to be consistent with new methods.
1137
1138         (toogleCheckSpellingWhileTyping):
1139         Select "Check Spelling While Typing" in context menu to test whether
1140         onSettingChange is called.
1141
1142 2013-06-19  Carlos Garcia Campos  <cgarcia@igalia.com>
1143
1144         [GTK][SOUP] Migrate SoupRequestManager to GTask
1145         https://bugs.webkit.org/show_bug.cgi?id=117157
1146
1147         Reviewed by Gustavo Noronha Silva.
1148
1149         GSimpleAsyncResult has been deprecated in favour of GTask.
1150
1151         * WebProcess/soup/WebKitSoupRequestGeneric.cpp:
1152         (webkitSoupRequestGenericSendAsync):
1153         (webkitSoupRequestGenericSendFinish):
1154         * WebProcess/soup/WebSoupRequestManager.cpp:
1155         (WebKit::WebSoupRequestAsyncData::WebSoupRequestAsyncData):
1156         (WebKit::WebSoupRequestAsyncData::releaseTask):
1157         (WebKit::WebSoupRequestManager::didHandleURIRequest):
1158         (WebKit::WebSoupRequestManager::didFailURIRequest):
1159         (WebKit::WebSoupRequestManager::send):
1160         (WebKit::WebSoupRequestManager::finish):
1161         * WebProcess/soup/WebSoupRequestManager.h:
1162
1163 2013-06-19  Carlos Garcia Campos  <cgarcia@igalia.com>
1164
1165         [GTK] Migrate WebKitFaviconDatabase to GTask
1166         https://bugs.webkit.org/show_bug.cgi?id=117156
1167
1168         Reviewed by Gustavo Noronha Silva.
1169
1170         * UIProcess/API/gtk/WebKitFaviconDatabase.cpp:
1171         (processPendingIconsForPageURL):
1172         (webkit_favicon_database_get_favicon):
1173         (webkit_favicon_database_get_favicon_finish):
1174
1175 2013-06-19  Carlos Garcia Campos  <cgarcia@igalia.com>
1176
1177         [GTK] Migrate WebKitWebView to GTask
1178         https://bugs.webkit.org/show_bug.cgi?id=117154
1179
1180         Reviewed by Gustavo Noronha Silva.
1181
1182         * UIProcess/API/gtk/WebKitWebView.cpp:
1183         (didValidateCommand):
1184         (webkit_web_view_can_execute_editing_command):
1185         (webkit_web_view_can_execute_editing_command_finish):
1186         (webkitWebViewRunJavaScriptCallback):
1187         (webkit_web_view_run_javascript):
1188         (webkit_web_view_run_javascript_finish):
1189         (resourcesStreamReadCallback):
1190         (webkit_web_view_run_javascript_from_gresource):
1191         (webkit_web_view_run_javascript_from_gresource_finish):
1192         (fileReplaceContentsCallback):
1193         (getContentsAsMHTMLDataCallback):
1194         (webkit_web_view_save):
1195         (webkit_web_view_save_finish):
1196         (webkit_web_view_save_to_file):
1197         (webkit_web_view_save_to_file_finish):
1198         (webKitWebViewDidReceiveSnapshot):
1199         (webkit_web_view_get_snapshot):
1200         (webkit_web_view_get_snapshot_finish):
1201
1202 2013-06-18  Carlos Garcia Campos  <cgarcia@igalia.com>
1203
1204         [GTK] Migrate WebKitCookieManager to GTask
1205         https://bugs.webkit.org/show_bug.cgi?id=117150
1206
1207         Reviewed by Gustavo Noronha Silva.
1208
1209         Don't use helper structs for async data since the cancellable is
1210         now accessible from the GTask.
1211
1212         * UIProcess/API/gtk/WebKitCookieManager.cpp:
1213         (webkitCookieManagerGetAcceptPolicyCallback):
1214         (webkit_cookie_manager_get_accept_policy):
1215         (webkit_cookie_manager_get_accept_policy_finish):
1216         (webkitCookieManagerGetDomainsWithCookiesCallback):
1217         (webkit_cookie_manager_get_domains_with_cookies):
1218         (webkit_cookie_manager_get_domains_with_cookies_finish):
1219
1220 2013-06-18  Roger Fong  <roger_fong@apple.com>
1221
1222         Unreviewed. Fix a typo that may be causing some test failures.
1223
1224         * WebProcess/WebCoreSupport/mac/WebFrameNetworkingContext.mm:
1225         (WebKit::WebFrameNetworkingContext::scheduledRunLoopPairs):
1226
1227 2013-06-18  Anders Carlsson  <andersca@apple.com>
1228
1229         Make it possible to set a minimum height for auto-layout
1230         https://bugs.webkit.org/show_bug.cgi?id=117758
1231         <rdar://problem/12849080>
1232
1233         Reviewed by Tim Horton.
1234
1235         Change a bunch of minimumLayoutWidth declarations to minimumLayoutSize and add a new minimumLayoutSize property.
1236         If minimumLayoutSize.height is greater than zero, use it to set the minimum layout size on the frame view.
1237
1238         * Shared/WebPageCreationParameters.cpp:
1239         (WebKit::WebPageCreationParameters::encode):
1240         (WebKit::WebPageCreationParameters::decode):
1241         * Shared/WebPageCreationParameters.h:
1242         * UIProcess/API/mac/WKView.mm:
1243         (-[WKView _setIntrinsicContentSize:]):
1244         (-[WKView minimumLayoutWidth]):
1245         (-[WKView setMinimumLayoutWidth:]):
1246         (-[WKView minimumWidthForAutoLayout]):
1247         (-[WKView setMinimumWidthForAutoLayout:]):
1248         (-[WKView minimumSizeForAutoLayout]):
1249         (-[WKView setMinimumSizeForAutoLayout:]):
1250         * UIProcess/API/mac/WKViewPrivate.h:
1251         * UIProcess/DrawingAreaProxy.h:
1252         (WebKit::DrawingAreaProxy::minimumLayoutSizeDidChange):
1253         * UIProcess/WebPageProxy.cpp:
1254         (WebKit::WebPageProxy::WebPageProxy):
1255         (WebKit::WebPageProxy::creationParameters):
1256         (WebKit::WebPageProxy::setMinimumLayoutSize):
1257         * UIProcess/WebPageProxy.h:
1258         (WebKit::WebPageProxy::minimumLayoutSize):
1259         * UIProcess/mac/TiledCoreAnimationDrawingAreaProxy.h:
1260         * UIProcess/mac/TiledCoreAnimationDrawingAreaProxy.mm:
1261         (WebKit::TiledCoreAnimationDrawingAreaProxy::TiledCoreAnimationDrawingAreaProxy):
1262         (WebKit::TiledCoreAnimationDrawingAreaProxy::minimumLayoutSizeDidChange):
1263         (WebKit::TiledCoreAnimationDrawingAreaProxy::didUpdateGeometry):
1264         (WebKit::TiledCoreAnimationDrawingAreaProxy::intrinsicContentSizeDidChange):
1265         (WebKit::TiledCoreAnimationDrawingAreaProxy::sendUpdateGeometry):
1266         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
1267         (WebKit::WebFrameLoaderClient::transitionToCommittedForNewPage):
1268         * WebProcess/WebPage/WebPage.cpp:
1269         (WebKit::WebPage::WebPage):
1270         (WebKit::WebPage::setMinimumLayoutSize):
1271         * WebProcess/WebPage/WebPage.h:
1272         (WebKit::WebPage::minimumLayoutSize):
1273         * WebProcess/WebPage/WebPage.messages.in:
1274         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
1275         (WebKit::TiledCoreAnimationDrawingArea::mainFrameContentSizeChanged):
1276         (WebKit::TiledCoreAnimationDrawingArea::updateGeometry):
1277
1278 2013-06-18  Simon Cooper  <scooper@apple.com>
1279
1280         sandbox violation when Flash runs for the first time
1281         https://bugs.webkit.org/show_bug.cgi?id=117753
1282         <rdar://problem/14165466>
1283
1284         Reviewed by Alexey Proskuryakov.
1285
1286         Allow flash to try and change the ownership of directories it has just created.
1287
1288         * Resources/PlugInSandboxProfiles/com.macromedia.Flash Player.plugin.sb:
1289
1290 2013-06-18  Ruth Fong  <ruth_fong@apple.com>
1291
1292         Expose a getMediaType method in WebKit
1293         https://bugs.webkit.org/show_bug.cgi?id=117667
1294
1295         Reviewed by Brady Eidson.
1296
1297         * GNUmakefile.list.am:
1298         * Target.pri:
1299         Updated to include the added header file InjectedBundleHitTestResultMediaType.h
1300         
1301         * UIProcess/API/C/WKAPICast.h:
1302         (WebKit::toBundleHitTestResultMediaType):
1303         (WebKit::toAPI):
1304         Added methods to convert between BundleHitTestResultMediaType
1305         and WKBundleHitTestResultMediaType.
1306
1307         * WebKit2.xcodeproj/project.pbxproj: Updated to include
1308         InjectedBundleHitTestResultMediaType.h in the WebKit2 project.
1309
1310         * WebProcess/InjectedBundle/API/c/WKBundleHitTestResult.cpp:
1311         (WKBundleHitTestResultGetMediaType): Exposes the method getMediaType and
1312         hooks into InjectedBundleHitTestResult::getMediaType.
1313
1314         * WebProcess/InjectedBundle/API/c/WKBundleHitTestResult.h:
1315
1316         * WebProcess/InjectedBundle/InjectedBundleHitTestResult.cpp:
1317         (WebKit::InjectedBundleHitTestResult::getMediaType): Added to return 
1318         what type, if any, a media element is.
1319
1320         * WebProcess/InjectedBundle/InjectedBundleHitTestResult.h:
1321
1322         * WebProcess/InjectedBundle/InjectedBundleHitTestResultMediaType.h: Added
1323         to contain new BundleHitTestResultMediaType enums.
1324
1325 2013-06-18  Roger Fong  <roger_fong@apple.com>
1326
1327         Re-implement WebFrameNetworkingContext.
1328         <rdar://problem/13174821>.
1329
1330         Reviewed by Alexey Proskuryakov.
1331
1332         * WebProcess/WebCoreSupport/mac/WebFrameNetworkingContext.h: Added.
1333         (WebKit::WebFrameNetworkingContext::create):
1334         (WebKit::WebFrameNetworkingContext::WebFrameNetworkingContext):
1335         * WebProcess/WebCoreSupport/mac/WebFrameNetworkingContext.mm: Added.
1336         (WebKit::WebFrameNetworkingContext::setPrivateBrowsingStorageSessionIdentifierBase):
1337         (WebKit::WebFrameNetworkingContext::ensurePrivateBrowsingSession):
1338         (WebKit::WebFrameNetworkingContext::destroyPrivateBrowsingSession):
1339         (WebKit::WebFrameNetworkingContext::setCookieAcceptPolicyForAllContexts):
1340         (WebKit::WebFrameNetworkingContext::needsSiteSpecificQuirks):
1341         (WebKit::WebFrameNetworkingContext::localFileContentSniffingEnabled):
1342         (WebKit::WebFrameNetworkingContext::scheduledRunLoopPairs):
1343         (WebKit::WebFrameNetworkingContext::sourceApplicationAuditData):
1344         (WebKit::WebFrameNetworkingContext::blockedError):
1345         (WebKit::WebFrameNetworkingContext::storageSession):
1346
1347 2013-06-18  Alexey Proskuryakov  <ap@apple.com>
1348
1349         <rdar://problem/13174821> Remove files with an incorrect license.
1350
1351         Rubber-stamped by Maciej Stachowiak.
1352
1353         This will break the build, stay tuned for a fix coming soon.
1354
1355         * WebProcess/WebCoreSupport/mac/WebFrameNetworkingContext.h: Removed.
1356         * WebProcess/WebCoreSupport/mac/WebFrameNetworkingContext.mm: Removed.
1357
1358 2013-06-17  Santosh Mahto  <santosh.ma@samsung.com>
1359
1360         Extra whitespace in blank line in PlatformPopupMenuData.cpp
1361         https://bugs.webkit.org/show_bug.cgi?id=117627
1362
1363         Reviewed by Brent Fulgham.
1364
1365         * Shared/PlatformPopupMenuData.cpp:
1366         (WebKit::PlatformPopupMenuData::decode):
1367         Removing extra space
1368
1369 2013-06-17  Beth Dakin  <bdakin@apple.com>
1370
1371         PageBanners appear over HTML5 video when media element is in full screen mode
1372         https://bugs.webkit.org/show_bug.cgi?id=117721
1373         -and corresponding-
1374         <rdar://problem/13686998>
1375
1376         Reviewed by Sam Weinig.
1377
1378         When an element enters fullscreen, hide the banners. Show them again when the 
1379         element exits fullscreen.
1380         * WebProcess/FullScreen/WebFullScreenManager.cpp:
1381         (WebKit::WebFullScreenManager::willEnterFullScreen):
1382         (WebKit::WebFullScreenManager::willExitFullScreen):
1383
1384         Handle hiding and showing by removing or re-creating a parent layer for m_layer.
1385         * WebProcess/WebPage/PageBanner.cpp:
1386         (WebKit::PageBanner::hide):
1387         (WebKit::PageBanner::showIfHidden):
1388         * WebProcess/WebPage/PageBanner.h:
1389         * WebProcess/WebPage/mac/PageBannerMac.mm:
1390         (WebKit::PageBanner::PageBanner):
1391         (WebKit::PageBanner::hide):
1392         (WebKit::PageBanner::showIfHidden):
1393         (WebKit::PageBanner::mouseEvent):
1394         * WebProcess/WebPage/WebPage.cpp:
1395         (WebKit::WebPage::hidePageBanners):
1396         (WebKit::WebPage::showPageBanners):
1397         * WebProcess/WebPage/WebPage.h:
1398
1399 2013-06-17  Ruth Fong  <ruth_fong@apple.com>
1400
1401         REGRESSION: Important controls are missing from <video> element UI, when compared to QuickTime
1402         https://bugs.webkit.org/show_bug.cgi?id=20599
1403
1404         Add a "Download Video"/"Download Audio" context menu item to download media
1405         elements.
1406
1407         Reviewed by Beth Dakin.
1408
1409         * Shared/API/c/WKContextMenuItemTypes.h: Updated to include
1410         an enum type for the "Download Video/Audio" context menu item.
1411
1412         * Shared/API/c/WKSharedAPICast.h: Updated to associate
1413         the enums in WebKit and WebCore that handle the "Download Video/Audio"
1414         context menu item.
1415
1416         * UIProcess/API/efl/ewk_context_menu.cpp:
1417         * UIProcess/API/efl/ewk_context_menu_item.cpp:
1418         * UIProcess/API/efl/ewk_context_menu_item.h:
1419         Updated to include new EWK enum type for "Download Video/Audio" context menu item.
1420
1421         * UIProcess/WebPageProxy.cpp: Updated to 
1422         handle the "Download Video/Audio" context menu item mouse click
1423         and download the media item in the UI process.
1424
1425 2013-06-17  Ralph Thomas  <ralpht@gmail.com>
1426
1427         [CoordinatedGraphics][CSS Shaders] Use forwarding header for TextureMapperPlatformCompiledProgram.h
1428         https://bugs.webkit.org/show_bug.cgi?id=117712
1429
1430         Reviewed by Noam Rosenthal.
1431
1432         * Shared/CoordinatedGraphics/WebCustomFilterProgramProxy.h:
1433
1434 2013-06-17  Mark Rowe  <mrowe@apple.com>
1435
1436         <rdar://problem/13145014> Allow CoreIPC messages to transmit importance boosts
1437
1438         Transmitting the importance boost from the UI process to the web process is particularly
1439         important when disabling process suppression on a web process, as it will minimize the
1440         delays that can occur before the message instructing process suppression to be disabled
1441         is processed by the web process.
1442
1443         We keep the importance boost alive for the duration of the CoreIPC message handler. We
1444         achieve this by having an ImportanceAssertion object that owns the assertion, and whose
1445         lifetime is tied to that of the MessageDecoder.
1446
1447         Reviewed by Anders Carlsson.
1448
1449         * Platform/CoreIPC/MessageDecoder.cpp:
1450         (CoreIPC::MessageDecoder::setImportanceAssertion): Associate an importance assertion
1451         with this message.
1452         * Platform/CoreIPC/MessageDecoder.h:
1453         * Platform/CoreIPC/mac/ConnectionMac.cpp:
1454         (CoreIPC::Connection::open): Mark our receive port as allowing importance boosts to be received.
1455         (CoreIPC::Connection::receiveSourceEventHandler):
1456         * Platform/CoreIPC/mac/ImportanceAssertion.h:
1457         (CoreIPC::ImportanceAssertion::create):
1458         (CoreIPC::ImportanceAssertion::~ImportanceAssertion): Release the assertion.
1459         (CoreIPC::ImportanceAssertion::ImportanceAssertion): Take an assertion if a boost was present in
1460         the Mach message.
1461
1462 2013-06-17  Mark Rowe  <mrowe@apple.com>
1463
1464         <rdar://problem/14051357> Web processes sometimes remain in a suppressed
1465         state after their window is unoccluded.
1466
1467         The code in WKView that responds to occlusion notifications was incorrectly
1468         treating the window's occlusion state as being an enum rather than the set of
1469         flags that it is.
1470
1471         Reviewed by Oliver Hunt.
1472
1473         * UIProcess/API/mac/WKView.mm:
1474         (-[WKView _windowDidChangeOcclusionState:]): Test only the visibility state.
1475         (-[WKView setWindowOcclusionDetectionEnabled:]): Ditto.
1476
1477 2013-06-17  Michael Brüning  <michael.bruning@digia.com>
1478
1479         [Qt] Remove Qt specific QTKIT flagged code.
1480         https://bugs.webkit.org/show_bug.cgi?id=117635
1481
1482         Reviewed by Simon Hausmann.
1483
1484         Due to disabling QTKIT for Qt in r151546, the
1485         code the flags that are not taken into account
1486         anymore and the code that has been rendered
1487         unreachable by this are removed.
1488
1489         * Target.pri:
1490         * UIProcess/qt/WebContextQt.cpp:
1491         (WebKit::WebContext::platformInitializeWebProcess):
1492         * WebProcess/WebCoreSupport/qt/WebSystemInterface.h: Removed.
1493         * WebProcess/WebCoreSupport/qt/WebSystemInterface.mm: Removed.
1494         * WebProcess/WebPage/WebPage.cpp:
1495         (WebKit::WebPage::updatePreferences):
1496         * WebProcess/qt/WebProcessMainQt.cpp:
1497         (WebKit::WebProcessMainQt):
1498
1499 2013-06-17  Grzegorz Czajkowski  <g.czajkowski@samsung.com>
1500
1501         Unreviewed, rolling out r151632.
1502         http://trac.webkit.org/changeset/151632
1503         https://bugs.webkit.org/show_bug.cgi?id=117585
1504
1505         Debug build error ASSERT(WTF_USE_GRAMMAR_CHECKING) for non MAC
1506         platforms
1507
1508         * Shared/API/c/WKSharedAPICast.h:
1509         (WebKit::toAPI):
1510         (WebKit::toImpl):
1511         * UIProcess/API/efl/ewk_context_menu_item.cpp:
1512         (getEwkActionFromWKTag):
1513         * UIProcess/API/efl/tests/test_ewk2_text_checker.cpp:
1514         (onContextMenuShow):
1515         (TEST_F):
1516         * UIProcess/API/gtk/WebKitContextMenuActions.cpp:
1517         (webkitContextMenuActionGetActionTag):
1518         (webkitContextMenuActionGetForContextMenuItem):
1519         (webkitContextMenuActionGetLabel):
1520         * UIProcess/WebPageProxy.cpp:
1521         (WebKit::WebPageProxy::contextMenuItemSelected):
1522
1523 2013-06-14  Grzegorz Czajkowski  <g.czajkowski@samsung.com>
1524
1525         Context menu grammar checking items are available when GRAMMAR_CHECKING macro is off
1526         https://bugs.webkit.org/show_bug.cgi?id=117585
1527
1528         Reviewed by Anders Carlsson.
1529
1530         Add GRAMMAR_CHECKING guard to the context menu grammar items.
1531
1532         * Shared/API/c/WKSharedAPICast.h:
1533         (WebKit::toAPI):
1534         (WebKit::toImpl):
1535         * UIProcess/API/efl/ewk_context_menu_item.cpp:
1536         (getEwkActionFromWKTag):
1537         * UIProcess/API/efl/tests/test_ewk2_text_checker.cpp:
1538         (checkSpellingItemsAvailability):
1539         Change callback name, to be consistent with a newly added.
1540
1541         (checkSpellingAndGrammarSubmenuAvailability):
1542         (checkGrammarWithSpellingItemAvailability):
1543         Add two unit tests for EFL to check whether context menu grammar items are
1544         available only when GRAMMAR_CHECKING macro is enabled.
1545
1546         * UIProcess/API/gtk/WebKitContextMenuActions.cpp:
1547         (webkitContextMenuActionGetActionTag):
1548         (webkitContextMenuActionGetForContextMenuItem):
1549         (webkitContextMenuActionGetLabel):
1550         * UIProcess/WebPageProxy.cpp:
1551         (WebKit::WebPageProxy::contextMenuItemSelected):
1552
1553 2013-06-14  Dean Jackson  <dino@apple.com>
1554
1555         Crash in supportsSnapshotting
1556         https://bugs.webkit.org/show_bug.cgi?id=117670
1557         <rdar://problem/14059711>
1558
1559         Reviewed by Darin Adler.
1560
1561         Speculative fix for deferencing a null RefPtr in supportsSnapshotting.
1562         It seems like it was possible to get in a state where the plugin machinery
1563         would fire up and attempt to get a screenshot before there was an active
1564         connection to the plugin process (usually under periods of high load, such
1565         as opening a lot of tabs at once). In this case we're now returning false
1566         from supportsSnapshotting, which will trigger the plugin to restart, but
1567         that's better than requesting a snapshot on something that doesn't yet exist.
1568
1569         * WebProcess/Plugins/PluginProxy.cpp:
1570         (WebKit::PluginProxy::supportsSnapshotting): Guard for an empty connection object.
1571
1572 2013-06-14  Enrica Casucci  <enrica@apple.com>
1573
1574         WKPageFindStringMatches ignores the kWKFindOptionsBackwards option.
1575         https://bugs.webkit.org/show_bug.cgi?id=117647
1576         <rdar://problem/13881024>
1577
1578         Reviewed by Darin Adler.
1579         
1580         The API returns the matched ranges in the DOM order regardless of the
1581         find direction, but the index of the first match after the user selection
1582         should take the find direction into account.
1583
1584         Extended existing test in TestWebKitAPI.
1585
1586         * Shared/API/c/WKFindOptions.h: Added enum for the case where there are
1587         no matches after the user selection in the direction of the find.
1588
1589 2013-06-14  Andres Gomez  <agomez@igalia.com>
1590
1591         [GTK] Compilation problems - hb.h not found
1592         https://bugs.webkit.org/show_bug.cgi?id=117636
1593
1594         Unreviewed GTK+ build fix.
1595
1596         * GNUmakefile.am: Added freetype cflags for WebKit2 GTK+ Platform
1597         library.
1598
1599 2013-06-13  Michał Pakuła vel Rutka  <m.pakula@samsung.com>
1600
1601         [EFL][WK2] Wrong context menu and popup menu positions when scroll is applied
1602         https://bugs.webkit.org/show_bug.cgi?id=116610
1603
1604         Reviewed by Noam Rosenthal.
1605
1606         WebKit2 EFL uses fixed layout - because of this ScrollView::contentsToWindow, does
1607         not take scroll into account, as it is meant to be handled by UI application.
1608         When popup and context menu are created, after calling contentsToWindow their position
1609         are not adjusted to page scroll.
1610         Added two functions to EwkView and WKView, converting contents position to user viewport
1611         coordinates, to adjust popup and context menu positions.
1612
1613         * UIProcess/API/C/CoordinatedGraphics/WKView.cpp:
1614         (WKViewContentsToUserViewport):
1615         * UIProcess/API/C/CoordinatedGraphics/WKView.h:
1616         * UIProcess/API/efl/EwkView.cpp:
1617         (EwkView::showContextMenu):
1618         (EwkView::requestPopupMenu):
1619         * UIProcess/CoordinatedGraphics/WebView.cpp:
1620         (WebKit::WebView::contentsToUserViewport):
1621         * UIProcess/CoordinatedGraphics/WebView.h:
1622
1623 2013-06-12  Anders Carlsson  <andersca@apple.com>
1624
1625         Remove the notion of inactive plug-ins
1626         https://bugs.webkit.org/show_bug.cgi?id=117570
1627         <rdar://problem/13484213>
1628
1629         Reviewed by Tim Horton.
1630
1631         Remove code that deals with inactive plug-ins. We still keep around the kWKPluginLoadPolicyInactive API enum for now.
1632
1633         * Shared/Plugins/PluginModuleInfo.h:
1634         * UIProcess/API/C/WKAPICast.h:
1635         (WebKit::toWKPluginLoadPolicy):
1636         (WebKit::toPluginModuleLoadPolicy):
1637         * UIProcess/Plugins/PluginInfoStore.cpp:
1638         * UIProcess/Plugins/PluginInfoStore.h:
1639         * UIProcess/Plugins/mac/PluginInfoStoreMac.mm:
1640         (WebKit::PluginInfoStore::shouldUsePlugin):
1641         (WebKit::PluginInfoStore::defaultLoadPolicyForPlugin):
1642         * UIProcess/WebPageProxy.cpp:
1643         (WebKit::WebPageProxy::findPlugin):
1644         (WebKit::WebPageProxy::unavailablePluginButtonClicked):
1645         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
1646         (WebKit::WebChromeClient::shouldUnavailablePluginMessageBeButton):
1647         (WebKit::WebChromeClient::unavailablePluginButtonClicked):
1648         * WebProcess/WebPage/WebPage.cpp:
1649         (WebKit::WebPage::createPlugin):
1650
1651 2013-06-12  Hugo Parente Lima  <hugo.lima@openbossa.org>
1652
1653         [GTK] Explicit include glib.h to avoid compilation errors if libsoup isn't used.
1654         https://bugs.webkit.org/show_bug.cgi?id=117564
1655
1656         Reviewed by Martin Robinson.
1657
1658         * UIProcess/Launcher/gtk/ProcessLauncherGtk.cpp:
1659
1660 2013-06-12  Zan Dobersek  <zdobersek@igalia.com>
1661
1662         [GTK] Move more build targets for source code that's free of layer violations into libPlatform
1663         https://bugs.webkit.org/show_bug.cgi?id=115936
1664
1665         Reviewed by Martin Robinson.
1666
1667         * GNUmakefile.am: Add GStreamer dependency's CFLAGS to the list of libPlatformGtk2 CPPFLAGS.
1668
1669 2013-06-12  Ruth Fong  <ruth_fong@apple.com>
1670
1671         "Open Video in New Window" doesn't make sense in fullscreen
1672         https://bugs.webkit.org/show_bug.cgi?id=117556
1673
1674         Reviewed by Beth Dakin.
1675
1676         Adds method mediaIsInFullscreen() that checks if a media element is in
1677         fullscreen mode, which is needed to decide when to display the
1678         "Open Video in New Window" context menu item.
1679
1680         * WebProcess/InjectedBundle/API/c/WKBundleHitTestResult.cpp:
1681         (WKBundleHitTestResultMediaIsInFullscreen): Added.
1682         Hooks into new InjectedBundleHitTestResult::mediaIsInFullscreen() method.
1683         * WebProcess/InjectedBundle/API/c/WKBundleHitTestResult.h:
1684         * WebProcess/InjectedBundle/InjectedBundleHitTestResult.cpp:
1685         (WebKit::InjectedBundleHitTestResult::mediaIsInFullscreen): Added.
1686         Checks if media element is in fullscreen.
1687         * WebProcess/InjectedBundle/InjectedBundleHitTestResult.h:
1688
1689 2013-06-12  Ruth Fong  <ruth_fong@apple.com>
1690
1691         Allow for toggling fullscreen on <video> elements
1692         https://bugs.webkit.org/show_bug.cgi?id=117220
1693
1694         Reviewed by Dean Jackson.
1695
1696         * Shared/API/c/WKContextMenuItemTypes.h:
1697         * Shared/API/c/WKSharedAPICast.h:
1698         Added variables to support the toggle-ability of the fullscreen
1699         video context menu item.
1700
1701 2013-06-12  Carlos Garcia Campos  <cgarcia@igalia.com>
1702
1703         [GTK] Invalidate the ProcessLauncher when the process is terminated before it has finished launching
1704         https://bugs.webkit.org/show_bug.cgi?id=117412
1705
1706         Reviewed by Anders Carlsson.
1707
1708         * UIProcess/Launcher/gtk/ProcessLauncherGtk.cpp:
1709         (WebKit::ProcessLauncher::terminateProcess): If process is still
1710         launching just invalidate the launcher. Reset the process
1711         identifier after killing the process.
1712
1713 2013-06-12  Jae Hyun Park  <jae.park@company100.net>
1714
1715         [Coordinated Graphics] Remove unused headers in CoordinatedLayerTreeHostProxy
1716         https://bugs.webkit.org/show_bug.cgi?id=117539
1717
1718         Reviewed by Noam Rosenthal.
1719
1720         * UIProcess/CoordinatedGraphics/CoordinatedLayerTreeHostProxy.cpp:
1721         * UIProcess/CoordinatedGraphics/CoordinatedLayerTreeHostProxy.h:
1722
1723 2013-06-12  Zan Dobersek  <zdobersek@igalia.com>
1724
1725         [GTK] Remove the WebCoreLayer(Gtk2).a archives before regenerating them
1726         https://bugs.webkit.org/show_bug.cgi?id=116723
1727
1728         Reviewed by Carlos Garcia Campos.
1729
1730         * GNUmakefile.am: When generating the WebCoreLayerGtk2.a archive from all the dependency archives, remove the
1731         current archive (if any). Updating an existent archive in an incremental build is not bulletproof and can lead
1732         to corrupt archives and subsequent build failures. On the other hand, the archive generation is not expensive
1733         and produces a working archive without problems even on incremental builds.
1734
1735 2013-06-12  Zan Dobersek  <zdobersek@igalia.com>
1736
1737         Unreviewed GTK build fix.
1738
1739         * GNUmakefile.list.am: Adding missing build targets to the plugin process after r151480.
1740
1741 2013-06-11  Gavin Barraclough  <barraclough@apple.com>
1742
1743         Add NSSupportsAppNap keys to WebProcess, PluginProcess
1744         https://bugs.webkit.org/show_bug.cgi?id=117528
1745
1746         Reviewed by Mark Rowe.
1747
1748         * PluginProcess/EntryPoint/mac/LegacyProcess/Info.plist:
1749         * PluginProcess/EntryPoint/mac/XPCService/PluginService.32-64.Info.plist:
1750         * PluginProcess/EntryPoint/mac/XPCService/PluginService.Development/Info.plist:
1751         * WebProcess/EntryPoint/mac/LegacyProcess/Info.plist:
1752         * WebProcess/EntryPoint/mac/XPCService/WebContentService.Development/Info.plist:
1753         * WebProcess/EntryPoint/mac/XPCService/WebContentService/Info.plist:
1754             - add NSSupportsAppNap key.
1755
1756 2013-06-11  Oliver Hunt  <oliver@apple.com>
1757
1758         Make sure we aren't throttling plugin timers during initialisation and destruction
1759         https://bugs.webkit.org/show_bug.cgi?id=117522
1760
1761         Reviewed by Darin Adler.
1762
1763         Add a new ActivityAssertion RAII class to handle allowing/disallowing
1764         timer throttling.  Then make use of it during plugin initialisation
1765         and destruction, as well as any synchronous messages (on the basis
1766         that if another process is waiting for the plugin we shouldn't be
1767         throttling timers).
1768
1769         * CMakeLists.txt:
1770         * GNUmakefile.list.am:
1771         * PluginProcess/WebProcessConnection.cpp:
1772         (WebKit::WebProcessConnection::didReceiveSyncMessage):
1773         (WebKit::WebProcessConnection::destroyPlugin):
1774         (WebKit::WebProcessConnection::createPlugin):
1775         * Shared/ActivityAssertion.cpp: Added.
1776         (WebKit::ActivityAssertion::ActivityAssertion):
1777         (WebKit::ActivityAssertion::~ActivityAssertion):
1778         * Shared/ActivityAssertion.h: Added.
1779         * Target.pri:
1780         * WebKit2.xcodeproj/project.pbxproj:
1781
1782 2013-06-06  Timothy Hatcher  <timothy@apple.com>
1783
1784         Update the framework bundle identifier for the Web Inspector.
1785
1786         Reviewed by Mark Rowe.
1787
1788         * UIProcess/mac/WebInspectorProxyMac.mm:
1789         (WebKit::inspectorReallyUsesWebKitUserInterface):
1790         (WebKit::WebInspectorProxy::inspectorPageURL):
1791         (WebKit::WebInspectorProxy::inspectorBaseURL):
1792         * WebProcess/WebPage/mac/WebInspectorMac.mm:
1793         (WebKit::inspectorReallyUsesWebKitUserInterface):
1794         (WebKit::WebInspector::localizedStringsURL):
1795
1796 2013-06-11  Jer Noble  <jer.noble@apple.com>
1797
1798         Do not filter cookies requested through the CookieStorageShim.
1799         https://bugs.webkit.org/show_bug.cgi?id=117511
1800         <rdar://problem/13603433>
1801
1802         Reviewed by Beth Dakin.
1803
1804         Since the shim function is called when the underlying media engine is
1805         creating an HTTPRequest, use CookieRequestHeaderFieldValue (which does
1806         not filter out HTTP-only cookies) rather than CookiesForDOM (which does).
1807
1808         * Shared/mac/CookieStorageShim.cpp:
1809         (WebKit::webKitCookieStorageCopyRequestHeaderFieldsForURL):
1810
1811 2013-06-11  Seokju Kwon  <seokju.kwon@gmail.com>
1812
1813         Remove leftover wxWebkit code
1814         https://bugs.webkit.org/show_bug.cgi?id=117471
1815
1816         Reviewed by Andreas Kling.
1817
1818         * Scripts/generate-forwarding-headers.pl:
1819
1820 2013-06-11  Changhyup Jwa  <ch.jwa@samsung.com>
1821
1822         [EFL][WK2] Add fallback for EWK2UnitTestBase if opengl is not available.
1823         https://bugs.webkit.org/show_bug.cgi?id=117504
1824
1825         Reviewed by Christophe Dumez.
1826
1827         There're many fails on efl webkit2 unit test if opengl is not available.
1828         So, add fallback to non-opengl evas engine.
1829
1830         * UIProcess/API/efl/tests/UnitTestUtils/EWK2UnitTestBase.cpp:
1831         (EWK2UnitTest::EWK2UnitTestBase::SetUp):
1832
1833 2013-06-11  Csaba Osztrogonác  <ossy@webkit.org>
1834
1835         Make WTR use its own temporary directory for application cache
1836         https://bugs.webkit.org/show_bug.cgi?id=117143
1837
1838         Reviewed by Alexey Proskuryakov.
1839
1840         * UIProcess/API/C/WKContext.cpp:
1841         (WKContextSetApplicationCacheDirectory):
1842         * UIProcess/API/C/WKContextPrivate.h:
1843         * UIProcess/WebContext.cpp:
1844         (WebKit::WebContext::applicationCacheDirectory):
1845         * UIProcess/WebContext.h:
1846         (WebKit::WebContext::setApplicationCacheDirectory):
1847         * UIProcess/efl/WebContextEfl.cpp:
1848         (WebKit::WebContext::platformDefaultApplicationCacheDirectory):
1849         * UIProcess/gtk/WebContextGtk.cpp:
1850         (WebKit::WebContext::platformDefaultApplicationCacheDirectory):
1851         * UIProcess/mac/WebContextMac.mm:
1852         (WebKit::WebContext::platformDefaultApplicationCacheDirectory):
1853         * UIProcess/qt/WebContextQt.cpp:
1854         (WebKit::WebContext::platformDefaultApplicationCacheDirectory):
1855
1856 2013-06-11  Michał Pakuła vel Rutka  <m.pakula@samsung.com>
1857
1858         [EFL][WK2] Fix test_ewk2_context_menu
1859         https://bugs.webkit.org/show_bug.cgi?id=116601
1860
1861         Reviewed by Gyuyoung Kim.
1862
1863         test_ewk2_context_menu is always passing, it does not test any context menu feature
1864         as it ends before context menu is called.
1865         One single test was divided into two tests: testing WebKit2 created context menu and
1866         testing menus and items created by application.
1867
1868         * UIProcess/API/efl/tests/UnitTestUtils/EWK2UnitTestBase.cpp:
1869         (EWK2UnitTest::EWK2UnitTestBase::waitUntilTrue): added function introducing internal loop until boolean value is changed to true
1870         * UIProcess/API/efl/tests/UnitTestUtils/EWK2UnitTestBase.h:
1871         * UIProcess/API/efl/tests/test_ewk2_context_menu.cpp:
1872         (customItemSelected):
1873         (showContextMenu):
1874         (showContextMenuForRemoveAndAppend):
1875         (showContextMenuForSubmenu):
1876         (hideContextMenu):
1877         (TEST_F):
1878
1879 2013-06-11  Ryuan Choi  <ryuan.choi@samsung.com>
1880
1881         [EFL][WK2] Add ewk_view_navigate API
1882         https://bugs.webkit.org/show_bug.cgi?id=117467
1883
1884         Reviewed by Christophe Dumez.
1885
1886         The applications will use this API to navigate history more than one step.
1887
1888         * UIProcess/API/efl/ewk_back_forward_list_item_private.h:
1889         (EwkBackForwardListItem::wkItem): Return WKBackForwardListItemRef for page to navigate.
1890         * UIProcess/API/efl/ewk_view.cpp:
1891         (ewk_view_navigate_to): Added new API.
1892         * UIProcess/API/efl/ewk_view.h:
1893         * UIProcess/API/efl/tests/test_ewk2_view.cpp:
1894         (TEST_F): Added more test case for navigation.
1895
1896 2013-06-10  Jae Hyun Park  <jae.park@company100.net>
1897
1898         [CoordinatedGraphics] Typos in custom shader support
1899         https://bugs.webkit.org/show_bug.cgi?id=117413
1900
1901         Reviewed by Noam Rosenthal.
1902
1903         Wrong keyframe is passed when assigning filterValue.
1904
1905         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.cpp:
1906         (WebKit::CoordinatedLayerTreeHost::prepareCustomFilterProxiesIfNeeded):
1907
1908 2013-06-10  Seokju Kwon  <seokju.kwon@gmail.com>
1909
1910         [Qt][GTK] Build fix after r151403
1911         https://bugs.webkit.org/show_bug.cgi?id=117452
1912
1913         Reviewed by Csaba Osztrogonác.
1914
1915         * UIProcess/API/gtk/PageClientImpl.cpp:
1916         (WebKit::PageClientImpl::preferencesDidChange):
1917         * UIProcess/API/gtk/PageClientImpl.h:
1918         * UIProcess/API/qt/raw/qrawwebview_p_p.h:
1919         (QRawWebViewPrivate::preferencesDidChange):
1920         * UIProcess/qt/QtPageClient.h:
1921         (WebKit::QtPageClient::preferencesDidChange):
1922
1923 2013-06-10  Commit Queue  <commit-queue@webkit.org>
1924
1925         Unreviewed, rolling out r151411.
1926         http://trac.webkit.org/changeset/151411
1927         https://bugs.webkit.org/show_bug.cgi?id=117453
1928
1929         because it is duplicated with Bug 117441 (Requested by
1930         gyuyoung_ on #webkit).
1931
1932         * UIProcess/efl/WebViewEfl.cpp:
1933         * UIProcess/efl/WebViewEfl.h:
1934
1935 2013-06-10  Jaehun Lim  <ljaehun.lim@samsung.com>
1936
1937         Fix build error and warning
1938         https://bugs.webkit.org/show_bug.cgi?id=117441
1939
1940         Reviewed by Anders Carlsson.
1941
1942         * UIProcess/CoordinatedGraphics/WebView.cpp:
1943         (WebKit::WebView::preferencesDidChange): Added.
1944         (WebKit::WebView::createPopupMenuProxy): Remove 'page'.
1945         * UIProcess/CoordinatedGraphics/WebView.h:
1946
1947 2013-06-10  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
1948
1949         Unreviewed, EFL Build fix after r151403.
1950
1951         Added preferencesDidChange to WebViewEfl.
1952
1953         * UIProcess/efl/WebViewEfl.cpp:
1954         (WebKit::WebViewEfl::preferencesDidChange):
1955         * UIProcess/efl/WebViewEfl.h:
1956
1957 2013-06-10  Anders Carlsson  <andersca@apple.com>
1958
1959         Crash in StorageAreaMap::applyChange when clearing local storage in another web process
1960         https://bugs.webkit.org/show_bug.cgi?id=117440
1961         <rdar://problem/13961548>
1962
1963         Reviewed by Tim Horton.
1964
1965         Add an early return so we won't try to look up a null key in the m_pendingValueChanges map.
1966         Also, fix an assertion - it's fine for m_storageMap to be null in applyChange.
1967
1968         * WebProcess/Storage/StorageAreaMap.cpp:
1969         (WebKit::StorageAreaMap::applyChange):
1970
1971 2013-06-10  Sergio Correia  <sergio.correia@openbossa.org>
1972
1973         [WK2][CoordinatedGraphics] Add default case to switches to fix strict build
1974         https://bugs.webkit.org/show_bug.cgi?id=117416
1975
1976         Reviewed by Noam Rosenthal.
1977
1978         This patch fixes a strict build by asserting on the default case of two
1979         switch statements where gcc was previously complaining of unhandled cases.
1980
1981         * Shared/CoordinatedGraphics/CoordinatedGraphicsArgumentCoders.cpp:
1982         (CoreIPC::::encode):
1983         (CoreIPC::::decode):
1984
1985 2013-06-10  Anders Carlsson  <andersca@apple.com>
1986
1987         -[WKView _updateWindowAndViewFrames] should avoid updating the view frame in window coordinates if we don't have plugins
1988         https://bugs.webkit.org/show_bug.cgi?id=117420
1989         <rdar://problem/14073034>
1990
1991         Reviewed by Tim Horton.
1992
1993         If plug-ins are disabled there's no need for the web process to know about the view frame in window coordinates so only
1994         send it when plug-ins are enabled. In addition, if accessibility is disabled we don't need to send a message at all.
1995
1996         * UIProcess/API/mac/PageClientImpl.h:
1997         * UIProcess/API/mac/PageClientImpl.mm:
1998         (WebKit::PageClientImpl::preferencesDidChange):
1999         Call through to -[WKView _preferencesDidChange].
2000
2001         * UIProcess/API/mac/WKView.mm:
2002         (-[WKView _updateWindowAndViewFrames]):
2003         Don't compute viewFrameInWindowCoordinates or accessibilityPosition unless they're required. If neither are required,
2004         don't even send a message to the web process.
2005
2006         (-[WKView _preferencesDidChange]):
2007         Update _needsViewFrameInWindowCoordinates and call -[WKView _updateWindowAndViewFrames] if needed.
2008
2009         (-[WKView initWithFrame:contextRef:pageGroupRef:relatedToPage:]):
2010         Set _needsViewFrameInWindowCoordinates based on whether plug-ins are enabled or not.
2011
2012         * UIProcess/WebPageProxy.cpp:
2013         (WebKit::WebPageProxy::preferencesDidChange):
2014         Call the page client.
2015
2016 2013-06-10  Bear Travis  <betravis@adobe.com>
2017
2018         [CSS Shapes][CSS Exclusions] Split CSS Exclusions and CSS Shapes code
2019         https://bugs.webkit.org/show_bug.cgi?id=117162
2020
2021         Reviewed by Alexandru Chiculita.
2022
2023         Adding the WebCore/rendering/shapes directory to the include list.
2024
2025         * CMakeLists.txt:
2026
2027 2013-06-10  Iago Toral Quiroga  <itoral@igalia.com>
2028
2029         Use Cairo implementation of the WidgetBackingStore instead of X11 when running on Wayland
2030         https://bugs.webkit.org/show_bug.cgi?id=116717
2031
2032         Reviewed by Martin Robinson.
2033
2034         Decide which implementation of WidgetBackingStore to use (X11 or Cairo)
2035         depending on whether we are running on X11 or not. Select Cairo
2036         implementation when not running in X11.
2037
2038         * UIProcess/cairo/BackingStoreCairo.cpp:
2039         (WebKit):
2040         (WebKit::createBackingStoreForGTK):
2041         (WebKit::BackingStore::incorporateUpdate):
2042
2043 2013-06-09  Jae Hyun Park  <jae.park@company100.net>
2044
2045         [CoordinatedGraphics] Typo in argument decoder for CoordinatedGraphicsState
2046         https://bugs.webkit.org/show_bug.cgi?id=117384
2047
2048         Reviewed by Noam Rosenthal.
2049
2050         For CSS Shaders, it must decode state.customFiltersToRemove instead of
2051         state.updateAtlasesToRemove.
2052
2053         * Shared/CoordinatedGraphics/CoordinatedGraphicsArgumentCoders.cpp:
2054         (CoreIPC::::decode):
2055
2056 2013-06-08  Jae Hyun Park  <jae.park@company100.net>
2057
2058         [Coordinated Graphics] Pass the ownership of GraphicsSurface explicitly
2059         https://bugs.webkit.org/show_bug.cgi?id=117379
2060
2061         Reviewed by Noam Rosenthal.
2062
2063         When creating WebCoordinatedSurface with GraphicsSurface, it is clearer
2064         to pass the ownership of the created GraphicsSurface explicitly.
2065
2066         * Shared/CoordinatedGraphics/WebCoordinatedSurface.cpp:
2067         (WebKit::WebCoordinatedSurface::create):
2068
2069 2013-06-07  Anders Carlsson  <andersca@apple.com>
2070
2071         Coalesce multiple calls to WebPageProxy::windowAndViewFramesChanged
2072         https://bugs.webkit.org/show_bug.cgi?id=117364
2073         <rdar://problem/14042099>
2074
2075         Reviewed by Geoffrey Garen.
2076
2077         -[WKView _updateWindowAndViewFrames] can be called many times per run loop iteration so coalesce calls
2078         to WebPageProxy::windowAndViewFrames using dispatch_async.
2079
2080         * UIProcess/API/mac/WKView.mm:
2081         (-[WKView _updateWindowAndViewFrames]):
2082
2083 2013-06-07  Thomas Deniau  <deniau@apple.com>
2084
2085         Reproducible crash with triple-finger-tap "define word" gesture on a Netflix video
2086         https://bugs.webkit.org/show_bug.cgi?id=117020
2087
2088         Reviewed by Ryosuke Niwa.
2089
2090         * WebProcess/WebPage/mac/WebPageMac.mm:
2091         (WebKit::WebPage::performDictionaryLookupAtLocation):
2092         Don't invoke the Dictionary lookup when we failed to extract the range of the token
2093         surrounding the tapped position.
2094
2095 2013-06-07  Enrique Ocana Gonzalez  <eocanha@igalia.com>
2096
2097         [GTK] Weird behaviour and no clues to the user when the shared memory file can't be opened
2098         https://bugs.webkit.org/show_bug.cgi?id=117063
2099
2100         Reviewed by Anders Carlsson.
2101
2102         Log error message when the shared memory file can't be opened in
2103         Unix platform using a release build
2104
2105         * Platform/unix/SharedMemoryUnix.cpp:
2106         (WebKit::SharedMemory::create):
2107
2108 2013-06-07  Grzegorz Czajkowski  <g.czajkowski@samsung.com>
2109
2110         [EFL][WK2] Context menu spellchecking items are not available when "Check Spelling While Typing" is off
2111         https://bugs.webkit.org/show_bug.cgi?id=117190
2112
2113         Reviewed by Christophe Dumez.
2114
2115         Context menu items (suggestions, learn and ignore word) are not available
2116         due to missing dictionary. To get the suggestions for the misspelled word,
2117         the dictionary has to be loaded first.
2118
2119         WebKit loads the default dictionary when check spelling while typing is being enabled.
2120         However, context menu spellchecking items should be present even if this setting is off.
2121
2122         * UIProcess/API/efl/ewk_context.cpp:
2123         (EwkContext::EwkContext):
2124         Load the user's default dictionary to ensure context menu spellchecking items.
2125         The dictionary is loaded asynchronously so it shouldn't delay application.
2126
2127         * UIProcess/API/efl/ewk_text_checker.h:
2128         Update doc. Spelling suggestions, learn and ignore word should be available
2129         independently of checking spelling while typing setting.
2130
2131         * UIProcess/API/efl/tests/test_ewk2_text_checker.cpp:
2132         (onContextMenuShow):
2133         (TEST_F):
2134         Add two unit tests to check whether the default dictionary is loaded and
2135         whether the context menu spelling items are available.
2136
2137         * UIProcess/efl/TextCheckerEfl.cpp:
2138         (WebKit::TextChecker::setContinuousSpellCheckingEnabled):
2139         (WebKit::TextChecker::continuousSpellCheckingEnabledStateChanged):
2140         Not set the default dictionary while enabling the setting, it's already loaded.
2141
2142 2013-06-07  Michał Pakuła vel Rutka  <m.pakula@samsung.com>
2143
2144         [EFL][WK2] Implement customContextMenuItemSelected
2145         https://bugs.webkit.org/show_bug.cgi?id=117298
2146
2147         Reviewed by Christophe Dumez.
2148
2149         When custom context menu item is selected using ewk API, the feedback is not
2150         sent back to application, as customContextMenuItemSelected was unimplemented in
2151         contextMenuClientEfl.
2152
2153         * UIProcess/API/efl/EwkView.cpp:
2154         (EwkView::customContextMenuItemSelected):
2155         * UIProcess/API/efl/EwkView.h:
2156         * UIProcess/API/efl/ewk_view.h: added custom_item_selected callback.
2157         * UIProcess/efl/ContextMenuClientEfl.cpp:
2158         (customContextMenuItemSelected):
2159         (ContextMenuClientEfl::ContextMenuClientEfl):
2160
2161 2013-06-06  Oliver Hunt  <oliver@apple.com>
2162
2163         Completely initialize ChildProcess state on launch
2164         https://bugs.webkit.org/show_bug.cgi?id=117328
2165
2166         Reviewed by Sam Weinig.
2167
2168         Use setProcessSuppressionEnabledInternal to avoid setProcessSuppressionEnabled
2169         "optimizing" our initialization away.
2170
2171         * Shared/mac/ChildProcessMac.mm:
2172         (WebKit::ChildProcess::platformInitialize):
2173
2174 2013-06-06  Rafael Brandao  <rafael.lobo@openbossa.org>
2175
2176         [Gtk] Connection is leaking when WebProcess is terminated
2177         https://bugs.webkit.org/show_bug.cgi?id=117293
2178
2179         Reviewed by Martin Robinson.
2180
2181         Connection is leaking because WorkQueue::SocketEventSource inherits from
2182         WorkQueue::EventSource but when it is destroyed, the actual destructor running
2183         is the one from base class; however, subclass contains a function binded from
2184         Connection (m_closeFunction) and we need to do this extra cleanup, otherwise
2185         WorkQueue will keep Connection alive. A better explanation of this fix is provided
2186         on http://stackoverflow.com/questions/461203/when-to-use-virtual-destructors
2187
2188         A quick way to see the leak is to change WK2 test "ReloadPageAfterCrash" to terminate
2189         WebProcess N times and add a printf on Connection destructor.
2190
2191         * Platform/gtk/WorkQueueGtk.cpp:
2192         (WorkQueue::EventSource::~EventSource): Adds a virtual destructor to enable
2193         the subclass to do its own cleanup.
2194
2195 2013-06-06  Jae Hyun Park  <jae.park@company100.net>
2196
2197         Coordinated Graphics : Refactor CoordinatedSurface to manage the lifecycle of GraphicsContext
2198         https://bugs.webkit.org/show_bug.cgi?id=108899
2199
2200         Reviewed by Noam Rosenthal.
2201
2202         This is a preparation patch for Threaded Coordinated Graphics.
2203
2204         This patch changes CoordinatedSurface to be responsible for the
2205         lifecycle of GraphicsContext used in Coordinated Graphics System.
2206         CoordinatedImageBacking and UpdateAtlas do not ask for the ownership
2207         of GraphicsContext anymore. Instead, those classes use client pattern to
2208         ask the CoordiantedSurface to paint to the GraphicsContext.
2209
2210         This refactoring is needed to implement CoordinatedSurface for Threaded
2211         Coordinated Graphics.
2212
2213         * Shared/CoordinatedGraphics/WebCoordinatedSurface.cpp:
2214         (WebKit::WebCoordinatedSurface::paintToSurface):
2215         * Shared/CoordinatedGraphics/WebCoordinatedSurface.h:
2216         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.cpp:
2217         (WebKit::CoordinatedLayerTreeHost::paintToSurface):
2218         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.h:
2219
2220 2013-06-05  Kangil Han  <kangil.han@samsung.com>
2221
2222         [EFL][WK2] Fix test_ewk2_view unit test timed out issue
2223         https://bugs.webkit.org/show_bug.cgi?id=117251
2224
2225         Reviewed by Christophe Dumez.
2226
2227         'ewk_view_contents_size_changed' unit test case has been timed out since r150802 because
2228         same size is filtered by WebView class. So create one different test html string that has
2229         different size to continue unit tests.
2230
2231         * UIProcess/API/efl/tests/test_ewk2_view.cpp:
2232         (onContentsSizeChangedPortrait):
2233         (onContentsSizeChangedLandscape):
2234         (TEST_F):
2235
2236 2013-06-05  Bear Travis  <betravis@adobe.com>
2237
2238         [CSS Exclusions][CSS Shapes] Split CSS Exclusions & Shapes compile & runtime flags
2239         https://bugs.webkit.org/show_bug.cgi?id=117172
2240
2241         Reviewed by Alexandru Chiculita.
2242
2243         Adding the CSS_SHAPES compile flag.
2244
2245         * Configurations/FeatureDefines.xcconfig:
2246
2247 2013-06-05  Anders Carlsson  <andersca@apple.com>
2248
2249         Crash if an IPC connection is invalidated before it's completely set up
2250         https://bugs.webkit.org/show_bug.cgi?id=117274
2251         <rdar://problem/13319035>
2252
2253         Reviewed by Andreas Kling.
2254
2255         Resume our dispatch sources on the connection queue so we won't get invalidation callbacks before
2256         all sources have been set up.
2257
2258         * Platform/CoreIPC/mac/ConnectionMac.cpp:
2259         (CoreIPC::Connection::open):
2260         (CoreIPC::Connection::sendOutgoingMessage):
2261         (CoreIPC::Connection::initializeDeadNameSource):
2262         (CoreIPC::Connection::receiveSourceEventHandler):
2263
2264 2013-06-05  Tim Horton  <timothy_horton@apple.com>
2265
2266         [wk2] WebProcess' page-in-window count can be wrong
2267         https://bugs.webkit.org/show_bug.cgi?id=117106
2268         <rdar://problem/14040991>
2269
2270         Reviewed by Anders Carlsson.
2271
2272         If we're using a single WebProcess and a window is closed, we were
2273         not decrementing the page-in-window count (because we apparently don't
2274         setIsInWindow(false) a WebPage in a closing window before tearing it down).
2275
2276         Turn the page-in-window count into a HashSet of pageIDs instead.
2277
2278         * WebProcess/WebPage/WebPage.cpp:
2279         (WebKit::WebPage::WebPage):
2280         (WebKit::WebPage::setIsInWindow):
2281         Send the pageID instead (this change is just so that I don't need to
2282         fetch the WebPage in WebProcess::removeWebPage).
2283
2284         * WebProcess/WebProcess.cpp:
2285         (WebKit::WebProcess::WebProcess):
2286         Remove m_inWindowPageCount.
2287
2288         (WebKit::WebProcess::removeWebPage):
2289         Ensure that WebPages being torn-down are removed from the in-window WebPage set.
2290
2291         (WebKit::WebProcess::pageDidEnterWindow):
2292         (WebKit::WebProcess::pageWillLeaveWindow):
2293         Use our new HashSet instead of a count.
2294
2295         (WebKit::WebProcess::nonVisibleProcessCleanupTimerFired):
2296         Make sure that we don't have any visible pages before doing cleanup.
2297
2298         * WebProcess/WebProcess.h:
2299         Remove m_inWindowPageCount.
2300         Add m_inWindowPageSet.
2301         Make pageDidEnterWindow/pageWillLeaveWindow take pageID instead of WebPage.
2302
2303 2013-06-05  Tim Horton  <timothy_horton@apple.com>
2304
2305         REGRESSION (r148713): Crash under waitForDidUpdateInWindowState
2306         https://bugs.webkit.org/show_bug.cgi?id=117268
2307         <rdar://problem/13822353>
2308
2309         Reviewed by Anders Carlsson.
2310
2311         Check if the WebProcess is valid before waiting for a message from it.
2312         Reset the bool that tells us that we have an outstanding didUpdateInWindowState message if the WebProcess quits.
2313
2314         * UIProcess/WebPageProxy.cpp:
2315         (WebKit::WebPageProxy::waitForDidUpdateInWindowState):
2316         (WebKit::WebPageProxy::resetStateAfterProcessExited):
2317
2318 2013-06-05  Gwang Yoon Hwang  <ryumiel@company100.net>
2319
2320         [Coordinated Graphics] Prevent a recursive painting in CoordinatedGraphicsLayer
2321         https://bugs.webkit.org/show_bug.cgi?id=117222
2322
2323         Reviewed by Noam Rosenthal.
2324
2325         CoordinatedGraphicsLayer::flushCompositingState() will cross frame
2326         boundaries if the GraphicsLayers are connected. In this case,
2327         updateContentBuffers will invoke a painting of a sub-frame that causes
2328         flushCompositingState recursively.
2329
2330         To prevent this behavior this patch extracts updateContentBuffers from
2331         flushCompositingState, and places it in
2332         updateContentBuffersIncludeSublayers, which traverses the tree
2333         separately from flushing the state for painting.
2334
2335         No new tests, covered by existing tests.
2336
2337         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.cpp:
2338         (WebKit::CoordinatedLayerTreeHost::flushPendingLayerChanges):
2339
2340 2013-06-05  Gwang Yoon Hwang  <ryumiel@company100.net>
2341
2342         [Coordinated Graphics] Rename client classes for CoordinatedImageBacking and UpdateAtlas.
2343         https://bugs.webkit.org/show_bug.cgi?id=111948
2344
2345         Reviewed by Noam Rosenthal.
2346
2347         This patch renames CoordinatedImageBacking::Coordinator to
2348         CoordinatedImageBacking::Client, and UpdateAtlasClient to
2349         UpdateAtlas::Client for naming consistency and clarification.
2350
2351         No new tests, covered by existing tests.
2352
2353         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.h:
2354
2355 2013-06-05  Gwang Yoon Hwang  <ryumiel@company100.net>
2356
2357         [Coordinated Graphics] Unify messages related object's lifecycles into CoordinatedGraphicsState.
2358         https://bugs.webkit.org/show_bug.cgi?id=111919
2359
2360         Reviewed by Noam Rosenthal.
2361
2362         CoordinatedLayerTreeHostProxy has several methods, which simply passes
2363         these calls to CoordinatedGraphicsScene.
2364
2365         This patch removes methods in CoordinatedLayerTreeHostProxy just for
2366         message chaining. Instead of that, messages for creation/deletion of objects
2367         (Layers, CustomFilters, UpdateAtlas, and ImageBacking) are unified into
2368         CommitCoordinatedGraphicsState.
2369
2370         And this patch also removes codes for WebCoordinatedSurface in
2371         CoordinatedLayerTreeHost, except for a factory method.
2372         CoordinatedGraphicsArgumentCoders [en|de]codes CoordinatedSurface itself
2373         using WebCoordinatedSurface.
2374
2375         No new tests, covered by existing tests.
2376
2377         * Shared/CoordinatedGraphics/CoordinatedGraphicsArgumentCoders.cpp:
2378         (CoreIPC::encodeCoordinatedSurface):
2379         (CoreIPC::decodeCoordinatedSurface):
2380         (CoreIPC::::encode):
2381         (CoreIPC::::decode):
2382         * UIProcess/CoordinatedGraphics/CoordinatedLayerTreeHostProxy.cpp:
2383         * UIProcess/CoordinatedGraphics/CoordinatedLayerTreeHostProxy.h:
2384         * UIProcess/CoordinatedGraphics/CoordinatedLayerTreeHostProxy.messages.in:
2385         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.cpp:
2386         (WebKit::CoordinatedLayerTreeHost::flushPendingLayerChanges):
2387         (WebKit::CoordinatedLayerTreeHost::clearPendingStateChanges):
2388         (WebKit::CoordinatedLayerTreeHost::checkCustomFilterProgramProxies):
2389         (WebKit::CoordinatedLayerTreeHost::removeCustomFilterProgramProxy):
2390         (WebKit::CoordinatedLayerTreeHost::detachLayer):
2391         (WebKit::CoordinatedLayerTreeHost::createImageBacking):
2392         (WebKit::CoordinatedLayerTreeHost::updateImageBacking):
2393         (WebKit::CoordinatedLayerTreeHost::clearImageBackingContents):
2394         (WebKit::CoordinatedLayerTreeHost::removeImageBacking):
2395         (WebKit::CoordinatedLayerTreeHost::createGraphicsLayer):
2396         (WebKit::CoordinatedLayerTreeHost::createUpdateAtlas):
2397         (WebKit::CoordinatedLayerTreeHost::removeUpdateAtlas):
2398         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.h:
2399
2400 2013-06-04  Simon Cooper  <scooper@apple.com>
2401
2402         Tighten plugin sandbox profiles against symlink attacks
2403         https://bugs.webkit.org/show_bug.cgi?id=117219
2404         <rdar://problem/13044569>
2405
2406         Reviewed by Sam Weinig.
2407
2408         This inserts deny rules for creating symbolic links. The rules are
2409         inserted at the end of sandbox profile compilation by overriding the
2410         finalizer.  The initial value of %finalize must be the last function
2411         called.
2412
2413         * Resources/PlugInSandboxProfiles/com.apple.WebKit.plugin-common.sb:
2414
2415 2013-06-04  Chris Fleizach  <cfleizach@apple.com>
2416
2417         AX: WK2: accessibility position is calculated every time window frame is updated
2418         https://bugs.webkit.org/show_bug.cgi?id=117201
2419
2420         Reviewed by Tim Horton.
2421
2422         Only calculate the AX position if AX has already been enabled when updating the
2423         WKView's window and frame.
2424
2425         * UIProcess/API/mac/WKView.mm:
2426         (-[WKView _updateWindowAndViewFrames]):
2427         (-[WKView _accessibilityRegisterUIProcessTokens]):
2428             Don't call accessibilityAttributeValue: here because it could enable accessibility prematurely.
2429         (-[WKView enableAccessibilityIfNecessary]):
2430             After enabling AX for the first time, also update the frame so that the AX position is correct.
2431         (-[WKView accessibilityFocusedUIElement]):
2432         (-[WKView accessibilityHitTest:]):
2433         (-[WKView accessibilityAttributeValue:]):
2434             Tell the AXObjectCache that AX is now enabled.
2435
2436 2013-06-04  Mark Rowe  <mrowe@apple.com>
2437
2438         REGRESSION (r151043): Frequent crashes inside WebPageProxy::getPlugInInformation
2439         <http://webkit.org/b/117180>
2440
2441         Reviewed by Brady Eidson.
2442
2443         * UIProcess/mac/WebPageProxyMac.mm:
2444         (WebKit::WebPageProxy::getPlugInInformation): Return early when plugInProcessProxy is null
2445         since there's nothing we can do.
2446
2447 2013-06-04  Michał Pakuła vel Rutka  <m.pakula@samsung.com>
2448
2449         [EFl][WK2] Sub menu items should be of EWK_SUBMENU_TYPE and not checkable
2450         https://bugs.webkit.org/show_bug.cgi?id=116959
2451
2452         Reviewed by Gyuyoung Kim.
2453
2454         Currently using ewk API it is possible to create a sub menu item which is not an EWK_SUBMENU_TYPE
2455         or set checkable flag for it, while it is not possible for items created by WebKit. 
2456         This patch changes ewk context menu API to match WebKit2 behaviour, by creating sub menus with
2457         proper type and checkable flags.
2458
2459         * UIProcess/API/efl/ewk_context_menu_item.cpp:
2460         (ewk_context_menu_item_new_with_submenu):
2461         * UIProcess/API/efl/ewk_context_menu_item.h:
2462         * UIProcess/API/efl/tests/test_ewk2_context_menu.cpp:
2463         (showContextMenu):
2464
2465 2013-06-04  Michał Pakuła vel Rutka  <m.pakula@samsung.com>
2466
2467         [EFL][WK2] Custom context menu items cannot be selected
2468         https://bugs.webkit.org/show_bug.cgi?id=116830
2469
2470         Reviewed by Gyuyoung Kim.
2471
2472         Custom item added using ewk_context_menu_item_append had no
2473         pointer to parent menu, and custom submenu added using with the
2474         the same function had no pointer to EwkView. Both issues
2475         prevented items to be selected.
2476
2477         * UIProcess/API/efl/ewk_context_menu.cpp:
2478         (EwkContextMenu::appendItem):
2479         (EwkContextMenu::contextMenuItemSelected):
2480         (ewk_context_menu_item_append):
2481         (ewk_context_menu_item_select):
2482         * UIProcess/API/efl/ewk_context_menu_private.h:
2483         (EwkContextMenu):
2484         (EwkContextMenu::setEwkView):
2485
2486 2013-06-03  Simon Cooper  <scooper@apple.com>
2487
2488         Unable to play videos in Safari using QuickTime plug-in until I've played those videos in Chrome first
2489         https://bugs.webkit.org/show_bug.cgi?id=117174
2490         <rdar://problem/13711687>
2491
2492         Reviewed by Alexey Proskuryakov.
2493
2494         Pull in fixes that allow https connections within the plugin
2495         environment.
2496
2497         * Resources/PlugInSandboxProfiles/com.apple.WebKit.plugin-common.sb:
2498
2499 2013-06-03  Marcelo Lira  <marcelo.lira@openbossa.org>
2500
2501         [WK2] REGRESSION(r150798): scrolling coordinator is not being enabled when WebPage is set to use fixed layout
2502         https://bugs.webkit.org/show_bug.cgi?id=117163
2503
2504         Reviewed by Darin Adler.
2505
2506         Moved call to WebPage::settings()->setScrollingCoordinatorEnabled()
2507         from CoordinatedLayerTreeHost constructor to WebPage::setUseFixedLayout().
2508         The scrolling coordinator must be enabled or disabled following the
2509         WebPage's use of fixed layout.
2510
2511         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.cpp:
2512         (WebKit::CoordinatedLayerTreeHost::CoordinatedLayerTreeHost):
2513         * WebProcess/WebPage/WebPage.cpp:
2514         (WebKit::WebPage::setUseFixedLayout):
2515
2516 2013-06-03  Anders Carlsson  <andersca@apple.com>
2517
2518         Send mouse events to the banner for as long as the mouse button is down
2519         https://bugs.webkit.org/show_bug.cgi?id=117161
2520         <rdar://problem/13821220>
2521
2522         Reviewed by Beth Dakin.
2523
2524         Keep track of whether the mouse was pressed in a banner and keep sending mouse events to it,
2525         even if they are outside the banner's bounds for as long as the mouse is down.
2526
2527         * WebProcess/WebPage/PageBanner.h:
2528         * WebProcess/WebPage/mac/PageBannerMac.mm:
2529         (WebKit::PageBanner::PageBanner):
2530         (WebKit::PageBanner::mouseEvent):
2531
2532 2013-06-03  Sergio Correia  <sergio.correia@openbossa.org>
2533
2534         [EFL][WK2] Process launcher uses system() for wrapping the WebProcess when using WEB_PROCESS_CMD_PREFIX
2535         https://bugs.webkit.org/show_bug.cgi?id=105156
2536
2537         Reviewed by Christophe Dumez.
2538
2539         When using WEB_PROCESS_CMD_PREFIX - which allows us for instance to analyze
2540         WebProcess under tools like valgrind or gdb -, the ProcessLauncher would
2541         spawn the new process using system(), which would, among other things, keep
2542         an extra UIProcess waiting and executing the shell.
2543
2544         This patch handles the normal case and the case where we have something to
2545         prefix WebProcess (i.e., by using WEB_PROCESS_CMD_PREFIX in a debug build)
2546         the same way, through a call to execvp().
2547
2548         To achieve this a function was introduced to create an array with the given
2549         arguments to the full command to be executed, to be used by execvp(). We use
2550         a Vector<OwnArrayPtr<char>>, so that we can take advantage of the destructor
2551         of OwnArrayPtr to handle the memory deallocation when it goes out of scope.
2552
2553         * UIProcess/Launcher/efl/ProcessLauncherEfl.cpp:
2554         (WebKit::createArgsArray):  This function creates the array to be used by
2555         execvp(), out of the Strings given as arguments.
2556         (WebKit::ProcessLauncher::launchProcess): Rework the logic to accomodate
2557         both the cases with and without WEB_PROCESS_CMD_PREFIX. The execl() call
2558         was replaced with an execvp() call, since now we should deal with having
2559         a variable number of arguments (WEB_PROCESS_CMD_PREFIX) as well.
2560
2561 2013-06-02  Arunprasad Rajkumar  <arurajku@cisco.com>
2562
2563         [Qt] Move Qt port off legacy clipboard
2564         https://bugs.webkit.org/show_bug.cgi?id=116416
2565
2566         Reviewed by Darin Adler.
2567
2568         * WebProcess/WebCoreSupport/qt/WebDragClientQt.cpp:
2569         (WebKit::WebDragClient::startDrag):
2570
2571 2013-06-02  Sergio Correia  <sergio.correia@openbossa.org>
2572
2573         [WK2][CoordinatedGraphics]: Use a properly initialized WebPage when creating a PageClient
2574         https://bugs.webkit.org/show_bug.cgi?id=117116
2575
2576         Reviewed by Tim Horton.
2577
2578         Valgrind reported a "conditional jump or move depends on uninitialised value"
2579         at WebPageProxy constructor, when checking the m_isVisible variable inside
2580         the ENABLE(PAGE_VISIBILITY_API) guard.
2581
2582         The issue was tracked down to the WebView constructor, which was creating a
2583         WebKit::PageClient* making use of `this' before having initialized all of its
2584         attributes.
2585
2586         The solution was to move the initialization of the `page' member to inside the
2587         constructor itself - out of the initialization list -, where we can guarantee
2588         all the relevant stuff has already been properly initialized.
2589
2590         Here's the relevant valgrind trace for reference:
2591
2592         Conditional jump or move depends on uninitialised value(s)
2593             at 0x65A35A4: WebKit::WebPageProxy::WebPageProxy(WebKit::PageClient*,
2594                           WTF::PassRefPtr<WebKit::WebProcessProxy>,
2595                           WebKit::WebPageGroup*, unsigned long) (WebPageProxy.cpp:322)
2596             by 0x65A2BA2: WebKit::WebPageProxy::create(WebKit::PageClient*,
2597                           WTF::PassRefPtr<WebKit::WebProcessProxy>,
2598                           WebKit::WebPageGroup*, unsigned long) (WebPageProxy.cpp:233)
2599             by 0x65E94BB: WebKit::WebProcessProxy::createWebPage(WebKit::PageClient*,
2600                           WebKit::WebContext*, WebKit::WebPageGroup*)
2601                           (WebProcessProxy.cpp:172)
2602             by 0x6570957: WebKit::WebContext::createWebPage(WebKit::PageClient*,
2603                           WebKit::WebPageGroup*, WebKit::WebPageProxy*)
2604                           (WebContext.cpp:735)
2605             by 0x67673E3: WebKit::WebView::WebView(WebKit::WebContext*,
2606                           WebKit::WebPageGroup*) (WebView.cpp:52)
2607             by 0x6775F18: WebKit::WebViewEfl::WebViewEfl(WebKit::WebContext*,
2608                           WebKit::WebPageGroup*) (WebViewEfl.cpp:54)
2609             by 0x6775EB4: WebKit::WebView::create(WebKit::WebContext*,
2610                           WebKit::WebPageGroup*) (WebViewEfl.cpp:49)
2611             by 0x673E13D: WKViewCreate (WKView.cpp:33)
2612             by 0x6763ECE: EWKViewCreate (ewk_view.cpp:92)
2613
2614         * UIProcess/CoordinatedGraphics/WebView.cpp:
2615         (WebKit::WebView::WebView):
2616
2617 2013-05-31  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
2618
2619         [EFL][WK2] Add a null checking condition to in hide() of EwkContextMenu
2620         https://bugs.webkit.org/show_bug.cgi?id=117014
2621
2622         Reviewed by Christophe Dumez.
2623
2624         m_viewImpl is able to be null. So, we need to protect this function against such case.
2625
2626         * UIProcess/API/efl/ewk_context_menu.cpp:
2627         (EwkContextMenu::hide):
2628         (ewk_context_menu_hide):
2629         * UIProcess/API/efl/ewk_context_menu_private.h:
2630         (EwkContextMenu):
2631
2632 2013-05-31  Oliver Hunt  <oliver@apple.com>
2633
2634         Fix bug in active page tracking that lead to plugins hanging during destruction
2635         https://bugs.webkit.org/show_bug.cgi?id=117099
2636
2637         Reviewed by Anders Carlsson.
2638
2639         NPRuntimeObjectMap no longer keeps its own reference to the
2640         throttler, and no longer reports activity during destruction.
2641
2642         * WebProcess/Plugins/Netscape/NPRuntimeObjectMap.cpp:
2643         (WebKit::NPRuntimeObjectMap::NPRuntimeObjectMap):
2644         (WebKit::NPRuntimeObjectMap::evaluate):
2645         * WebProcess/Plugins/Netscape/NPRuntimeObjectMap.h:
2646         * WebProcess/Plugins/PluginView.cpp:
2647         (WebKit::PluginView::PluginView):
2648
2649 2013-05-31  Tim Horton  <timothy_horton@apple.com>
2650
2651         [wk2] All intrinsic content size changes should go through the 0-delay timer
2652         https://bugs.webkit.org/show_bug.cgi?id=117058
2653         <rdar://problem/13935042>
2654
2655         Reviewed by Anders Carlsson.
2656
2657         In r146913, I added a 0-delay timer so that we'd coalesce intrinsic
2658         content size changes. However, didUpdateGeometry was still immediately
2659         invalidating the intrinsic content size without coalescing.
2660
2661         Move that update to the WebProcess to share the timer.
2662
2663         * UIProcess/DrawingAreaProxy.h:
2664         (WebKit::DrawingAreaProxy::didUpdateGeometry):
2665         * UIProcess/DrawingAreaProxy.messages.in:
2666         * UIProcess/mac/TiledCoreAnimationDrawingAreaProxy.h:
2667         * UIProcess/mac/TiledCoreAnimationDrawingAreaProxy.mm:
2668         (WebKit::TiledCoreAnimationDrawingAreaProxy::didUpdateGeometry):
2669         Remove the newIntrinsicContentSize argument, and don't invalidate intrinsic
2670         content size inside didUpdateGeometry.
2671
2672         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
2673         (WebKit::TiledCoreAnimationDrawingArea::updateGeometry):
2674         Start the intrinsic content size update timer when we finish updateGeometry.
2675
2676 2013-05-31  Alexey Proskuryakov  <ap@apple.com>
2677
2678         Sandbox violations when trying to access fonts in non-standard locations
2679         https://bugs.webkit.org/show_bug.cgi?id=117097
2680         <rdar://problem/9264746>
2681
2682         Reviewed by Anders Carlsson.
2683
2684         The issue was that lack of a main xib was resulting in font machinery being
2685         initialized too early, before we entered sandbox.
2686
2687         * Resources/WebContentProcess.xib: Added.
2688         * WebKit2.xcodeproj/project.pbxproj:
2689         * WebProcess/EntryPoint/mac/LegacyProcess/Info.plist:
2690         * WebProcess/EntryPoint/mac/XPCService/WebContentService.Development/Info.plist:
2691         * WebProcess/EntryPoint/mac/XPCService/WebContentService/Info.plist:
2692
2693 2013-05-31  Alexey Proskuryakov  <ap@apple.com>
2694
2695         <rdar://problem/14036464> Sandbox violation when using Web SpeechSynthesis
2696
2697         Reviewed by Anders Carlsson
2698
2699         * WebProcess/com.apple.WebProcess.sb.in: Allow com.apple.speech.synthesis.console.
2700
2701 2013-05-31  Jessie Berlin  <jberlin@apple.com>
2702
2703         Need the ability to get the information for a plug-in with a particular process id that may
2704         be running on a page
2705         https://bugs.webkit.org/show_bug.cgi?id=117090
2706
2707         Rubber-stamped by Anders Carlsson.
2708
2709         Follow-up to r151043 incorprating some feedback I got from Darin after I had already
2710         committed the patch.
2711
2712         * UIProcess/API/C/mac/WKPagePrivateMac.cpp:
2713         (callGetPlugInInformationBlockAndDispose):
2714         Renamed to be less wordy.
2715         (WKPageGetPlugInInformation):
2716         Ditto.
2717         * UIProcess/API/C/mac/WKPagePrivateMac.h:
2718         Ditto.
2719
2720         * UIProcess/Plugins/PluginProcessManager.h:
2721         * UIProcess/Plugins/mac/PluginProcessManagerMac.mm:
2722         (WebKit::PluginProcessManager::findPlugInProcessByID):
2723         Renamed to not use "Cocoa method style" in non-Cocoa functions.
2724         (WebKit::PluginProcessManager::findPlugInProcessByToken):
2725         Ditto.
2726
2727         * UIProcess/WebPageProxy.h:
2728         * UIProcess/mac/WebPageProxyMac.mm:
2729         (WebKit::WebPageProxy::getPlugInInformation):
2730         Reduce ref count churn and fix a variable name.
2731         Updated for the change to findPlugInProcessByID.
2732         (WebKit::WebPageProxy::containsPlugInCallback):
2733         Updated for the change to findPlugInProcessByToken.
2734
2735         * WebProcess/Plugins/PDF/SimplePDFPlugin.h:
2736         Move the override of a virtual function to the private section.
2737
2738 2013-05-31  Jessie Berlin  <jberlin@apple.com>
2739
2740         Need the ability to get the information for a plug-in with a particular process id that may
2741         be running on a page
2742         https://bugs.webkit.org/show_bug.cgi?id=117090
2743
2744         Reviewed by Anders Carlsson.
2745
2746         * UIProcess/API/C/mac/WKPagePrivateMac.cpp:
2747         (callGetInformationForPlugInWithProcessIDBlockAndDispose):
2748         Get the block from the context, invoke it with the result, and dispose of it.
2749         (WKPageGetInformationForPlugInWithProcessID):
2750         Ask the WebPageProxy and provide it with a dictionary callback that uses the
2751         above function to invoke the passed in block.
2752         * UIProcess/API/C/mac/WKPagePrivateMac.h:
2753         Add WKPageGetInformationForPlugInWithProcessID and a typedef for the callback block.
2754
2755         * UIProcess/Plugins/PluginProcessManager.h:
2756         Add ways to get the PluginProcessProxy associated with a process id or process token.
2757         * UIProcess/Plugins/mac/PluginProcessManagerMac.mm:
2758         (WebKit::PluginProcessManager::plugInProcessWithProcessID):
2759         Return the first PluginProcessProxy with the passed in process ID.
2760         (WebKit::PluginProcessManager::plugInProcessWithToken):
2761         Return the first PluginProcessProxy with the passed in process token.
2762
2763         * UIProcess/WebPageProxy.cpp:
2764         (WebKit::WebPageProxy::close):
2765         Invalidate any outstanding requests for plug-in information.
2766         * UIProcess/WebPageProxy.h:
2767         Keep track of the callbacks for the requests for plug-in information.
2768         * UIProcess/WebPageProxy.messages.in:
2769         * UIProcess/mac/WebPageProxyMac.mm:
2770         (WebKit::WebPageProxy::getInformationForPlugInWithProcessID):
2771         If there are no known plug-ins with the provided process ID, invoke the callback with a null
2772         dictionary of plug-in information.
2773         Otherwise, keep track of the callback and send a message to the web process asking for the
2774         information.
2775         (WebKit::WebPageProxy::containsPlugInCallback):
2776         If the page did not contain the plug-in, invoke the callback with a null dictionary of
2777         plug-in information.
2778         Invoke the callback with a dictionary containing the PlugInModuleInfo.
2779
2780         * WebProcess/Plugins/Netscape/NetscapePlugin.h:
2781         Return 0 for the plugInProcessToken.
2782         * WebProcess/Plugins/PDF/SimplePDFPlugin.h:
2783         Ditto.
2784         * WebProcess/Plugins/Plugin.h:
2785         Add a pure virtual method for plugInProcessToken so it can be accessed from from the Plugin
2786         on the PluginView.
2787         * WebProcess/Plugins/PluginProxy.h:
2788         Return the actual plug-in process token.
2789
2790         * WebProcess/Plugins/PluginView.h:
2791         (WebKit::PluginView::plugIn):
2792         Make it possible to get at the plug-in process token through the Plugin.
2793
2794         * WebProcess/WebPage/WebPageMac.mm:
2795         (WebKit::WebPage::containsPluginViewsWithPluginProcessToken):
2796         If there is an instance of the plug-in with that token, send a confirmation to the ui
2797         process.
2798         * WebProcess/WebPage/WebPage.h:
2799         * WebProcess/WebPage/WebPage.messages.in:
2800
2801 2013-05-31  Alexey Proskuryakov  <ap@apple.com>
2802
2803         REGRESSION (r141445): MPEG-4 videos do not play on certain hardware configurations
2804         https://bugs.webkit.org/show_bug.cgi?id=117089
2805         <rdar://problem/13839717>
2806
2807         Reviewed by Mark Rowe.
2808
2809         * Configurations/WebContentProcess.xcconfig: Statically link to a framework that
2810         uses an XPC service to work around a libxpc limitation on Lion.
2811
2812 2013-05-31  Dean Jackson  <dino@apple.com>
2813
2814         Don't create an accelerated compositing layer unless we have to for snapshotting plug-ins
2815         https://bugs.webkit.org/show_bug.cgi?id=117076
2816         <rdar://problem/14030364>
2817
2818         Reviewed by Beth Dakin and Anders Carlsson.
2819
2820         If a plug-in can support software snapshotting, then don't create an
2821         accelerated compositing layer for it while in snapshot mode. This is a
2822         better user experience -- otherwise the page/plug-in looks like it broke.
2823
2824         * WebProcess/Plugins/PluginView.cpp:
2825         (WebKit::PluginView::isAcceleratedCompositingEnabled): If we are in snapshotting mode
2826         and we are a Flash plugin (the only one that supports software snapshots at the moment)
2827         then do not create an accelerated compositing layer.
2828
2829 2013-05-30  Tim Horton  <timothy_horton@apple.com>
2830
2831         It's easy to hit ASSERT_NOT_REACHED in WKDOMNodeClass
2832         https://bugs.webkit.org/show_bug.cgi?id=117051
2833
2834         Reviewed by Anders Carlsson.
2835
2836         Re-add the ASSERT_NOT_REACHED, and return [WKDOMNode class] in the case
2837         where we don't have a specific subclass.
2838
2839         * WebProcess/InjectedBundle/API/mac/WKDOMInternals.mm:
2840         (WebKit::WKDOMNodeClass):
2841
2842 2013-05-31  Stephanie Lewis  <slewis@apple.com>
2843
2844         Update low memory handler to use new memory pressure notifications on new OS versions.
2845         <rdar://problem/14027095>
2846
2847         Reviewed by Mark Rowe.
2848
2849         * WebProcess/WebCoreSupport/mac/WebSystemInterface.mm:
2850         (InitWebCoreSystemInterface):
2851
2852 2013-05-30  Tim Horton  <timothy_horton@apple.com>
2853
2854         Remove ASSERT_NOT_REACHED from WKDOMNodeClass
2855         https://bugs.webkit.org/show_bug.cgi?id=117051
2856
2857         Reviewed by Anders Carlsson.
2858
2859         It's easy to fail this assertion in seemingly-legitimate cases.
2860
2861         * WebProcess/InjectedBundle/API/mac/WKDOMInternals.mm:
2862         (WebKit::WKDOMNodeClass):
2863
2864 2013-05-29  Jeffrey Pfau  <jpfau@apple.com>
2865
2866         [Mac] Enable cache partitioning and the public suffix list on 10.8
2867         <rdar://problem/13679019>
2868
2869         Rubber-stamped by David Kilzer.
2870
2871         * Configurations/FeatureDefines.xcconfig:
2872
2873 2013-05-30  Andreas Kling  <akling@apple.com>
2874
2875         Fix double hash lookup in WebPage::determinePrimarySnapshottedPlugIn() loop.
2876         <http://webkit.org/b/117032>
2877
2878         Reviewed by Anders Carlsson.
2879
2880         * WebProcess/WebPage/WebPage.cpp:
2881         (WebKit::WebPage::determinePrimarySnapshottedPlugIn):
2882
2883 2013-05-29  Tim Horton  <timothy_horton@apple.com>
2884
2885         Expose incrementalRenderingSuppressionTimeout via WK2
2886         https://bugs.webkit.org/show_bug.cgi?id=117015
2887         <rdar://problem/13992853>
2888
2889         Reviewed by Darin Adler.
2890
2891         * Shared/WebPreferencesStore.h:
2892         * UIProcess/API/C/WKPreferencesPrivate.h:
2893         Add IncrementalRenderingSuppressionTimeout preference.
2894
2895         * UIProcess/API/C/WKPreferences.cpp:
2896         (WKPreferencesSetIncrementalRenderingSuppressionTimeout): Added.
2897         (WKPreferencesGetIncrementalRenderingSuppressionTimeout): Added.
2898
2899         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
2900         * WebProcess/WebCoreSupport/WebFrameLoaderClient.h:
2901         (WebKit::WebFrameLoaderClient::forcePageTransitionIfNeeded): Added.
2902         Call didCompletePageTransition, which un-freezes the layer tree.
2903
2904         * WebProcess/WebPage/WebPage.cpp:
2905         (WebKit::WebPage::didCompletePageTransition):
2906         Fix some indentation.
2907
2908         (WebKit::WebPage::updatePreferences):
2909         Forward the timeout value through to WebCore.
2910
2911 2013-05-29  Simon Fraser  <simon.fraser@apple.com>
2912
2913         Fix paint-related milestones to not fire when the layer tree is frozen
2914         https://bugs.webkit.org/show_bug.cgi?id=117012
2915
2916         Reviewed by Tim Horton.
2917         
2918         Implement ChromeClient::layerTreeStateIsFrozen() to return
2919         the frozen state of the drawing area.
2920
2921         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
2922         (WebKit::WebChromeClient::layerTreeStateIsFrozen):
2923         * WebProcess/WebCoreSupport/WebChromeClient.h:
2924         (WebChromeClient):
2925
2926 2013-05-29  Anders Carlsson  <andersca@apple.com>
2927
2928         WebKit should expose HSTS APIs to determine whether a host is in the HSTS cache and to reset HSTS policies
2929         https://bugs.webkit.org/show_bug.cgi?id=117010
2930         <rdar://problem/13689666>
2931
2932         Reviewed by Tim Horton.
2933
2934         * UIProcess/API/C/mac/WKContextPrivateMac.h:
2935         * UIProcess/API/C/mac/WKContextPrivateMac.mm:
2936         * UIProcess/API/C/mac/WKPagePrivateMac.cpp:
2937         * UIProcess/API/C/mac/WKPagePrivateMac.h:
2938         * UIProcess/WebContext.h:
2939         (WebContext):
2940         * UIProcess/mac/WebContextMac.mm:
2941         (WebKit):
2942         (WebKit::privateBrowsingSession):
2943         (WebKit::WebContext::isURLKnownHSTSHost):
2944         (WebKit::WebContext::resetHSTSHosts):
2945
2946 2013-05-29  Tim Horton  <timothy_horton@apple.com>
2947
2948         WKViews using shouldClipToVisibleRect=YES should respect prepareContentInRect: if called
2949         https://bugs.webkit.org/show_bug.cgi?id=116989
2950         <rdar://problem/14007440>
2951
2952         Reviewed by Anders Carlsson.
2953
2954         * UIProcess/API/mac/WKView.mm:
2955         (-[WKView prepareContentInRect:]):
2956         If prepareContentInRect: is called, save the rect and set a flag so we know we should use it.
2957
2958         (-[WKView _updateViewExposedRect]):
2959         Give the WebPage (and later the DrawingArea) the union of the rect handed to prepareContentInRect:
2960         and the WKView's visibleRect, if we're in that mode, so that applications that do their own scrolling
2961         can cause tiles to be created in currently offscreen views (for overdraw).
2962
2963         (-[WKView setFrameSize:]):
2964         (-[WKView _updateWindowAndViewFrames]):
2965         (-[WKView initWithFrame:contextRef:pageGroupRef:relatedToPage:]):
2966         (-[WKView enableFrameSizeUpdates]):
2967         (-[WKView setShouldClipToVisibleRect:]):
2968         (-[WKView forceAsyncDrawingAreaSizeUpdate:]):
2969         Use [_updateViewExposedRect].
2970
2971 2013-05-28  Oliver Hunt  <oliver@apple.com>
2972
2973         Add more accurate activity state tracking
2974         https://bugs.webkit.org/show_bug.cgi?id=116893
2975
2976         Reviewed by Gavin Barraclough.
2977
2978         This extends the logic in WebCore from a Page to Process
2979         granularity, so we will avoid lowering the child process
2980         priority if there is active content.  This also plumbs in
2981         the logic to allow plugins to report that they have done
2982         something "interesting".  Currently this is somewhat conservative
2983         but even this is sufficient to fix some stuttering issues
2984         that we've seen.
2985
2986         * Shared/ChildProcess.cpp:
2987         (WebKit::ChildProcess::ChildProcess):
2988         * Shared/ChildProcess.h:
2989         (ChildProcess):
2990         (WebKit::ChildProcess::processSuppressionEnabled):
2991         (WebKit::ChildProcess::incrementActiveTaskCount):
2992         (WebKit::ChildProcess::decrementActiveTaskCount):
2993         * Shared/mac/ChildProcessMac.mm:
2994         (WebKit):
2995         (WebKit::ChildProcess::setProcessSuppressionEnabledInternal):
2996         (WebKit::ChildProcess::setProcessSuppressionEnabled):
2997         (WebKit::ChildProcess::incrementActiveTaskCount):
2998         (WebKit::ChildProcess::decrementActiveTaskCount):
2999         (WebKit::ChildProcess::suspensionHysteresisTimerFired):
3000         * WebProcess/Plugins/Netscape/NPRuntimeObjectMap.cpp:
3001         (WebKit::NPRuntimeObjectMap::NPRuntimeObjectMap):
3002         (WebKit::NPRuntimeObjectMap::evaluate):
3003         * WebProcess/Plugins/Netscape/NPRuntimeObjectMap.h:
3004         (WebCore):
3005         (NPRuntimeObjectMap):
3006         * WebProcess/Plugins/PluginView.cpp:
3007         (WebKit::PluginView::PluginView):
3008         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
3009         (WebKit::WebChromeClient::incrementActivePageCount):
3010         (WebKit):
3011         (WebKit::WebChromeClient::decrementActivePageCount):
3012         * WebProcess/WebCoreSupport/WebChromeClient.h:
3013         (WebChromeClient):
3014
3015 2013-05-29  Anders Carlsson  <andersca@apple.com>
3016
3017         Return earlier if there's no session storage namespace
3018         https://bugs.webkit.org/show_bug.cgi?id=116984
3019         <rdar://problem/13976781>
3020
3021         Reviewed by Tim Horton.
3022
3023         If we can't find a session storage namespace, return before creating an entry in the m_storageAreasByConnection
3024         hash map since then we'll crash trying to remove it later.
3025
3026         * UIProcess/Storage/StorageManager.cpp:
3027         (WebKit::StorageManager::createSessionStorageMap):
3028
3029 2013-05-29  Martin Robinson  <mrobinson@igalia.com>
3030
3031         Fix more CMake GTK+ build issues after r150336
3032
3033         * CMakeLists.txt: We need to allow for setting the WebProcess output name, since
3034         WebKitGTK+ expects it to be called WebKitWebProcess.
3035         * PlatformGTK.cmake: No longer set WebProcess_EXECUTABLE_NAME as it's been replaced
3036         by WebKit2_WebProcess_OUTPUT_NAME.
3037
3038 2013-05-29  Marcelo Lira  <marcelo.lira@openbossa.org>
3039
3040         [WK2][CoordinatedGraphics][EFL] WKViewUserViewportToContents() function doesn't do what it says
3041         https://bugs.webkit.org/show_bug.cgi?id=116683
3042
3043         Reviewed by Noam Rosenthal.
3044
3045         WKViewUserViewportToContents now converts WebView coordinates to
3046         page contents coordinates, taking into account factors as content
3047         scale and scroll, and also device scale.
3048
3049         The function WKViewUserViewportToScene was added to convert WebView
3050         coordinates to the coordinates of the canvas/scene where the view
3051         is drawn, and EwkView was fixed to use it, instead of
3052         WKViewUserViewportToContents.
3053
3054         * UIProcess/API/C/CoordinatedGraphics/WKView.cpp:
3055         (WKViewUserViewportToScene):
3056         * UIProcess/API/C/CoordinatedGraphics/WKView.h:
3057         * UIProcess/API/efl/EwkView.cpp:
3058         (EwkView::createGLSurface):
3059         * UIProcess/CoordinatedGraphics/WebView.cpp:
3060         (WebKit::WebView::userViewportToContents):
3061         (WebKit):
3062         (WebKit::WebView::userViewportToScene):
3063         (WebKit::WebView::transformToScene):
3064         * UIProcess/CoordinatedGraphics/WebView.h:
3065         (WebView):
3066
3067 2013-05-29  Carlos Garcia Campos  <cgarcia@igalia.com>
3068
3069         Unreviewed. Fix make distcheck.
3070
3071         * GNUmakefile.am: Add WebCoreLayerGtk2.a to DISTCLEANFILES.
3072
3073 2013-05-29  Seokju Kwon  <seokju.kwon@gmail.com>
3074
3075         [GTK] Clean up WebKit2 GNUmakefile.am
3076         https://bugs.webkit.org/show_bug.cgi?id=116907
3077
3078         Reviewed by Martin Robinson.
3079
3080         Removed WebNotificationManagerProxy.messages.in after r150785.
3081
3082         * GNUmakefile.am:
3083
3084 2013-05-28  Alexey Proskuryakov  <ap@apple.com>
3085
3086         Freeze when loading a particular page on washingtonpost.com with NetworkProcess enabled
3087         https://bugs.webkit.org/show_bug.cgi?id=116887
3088         <rdar://problem/12965959>
3089
3090         Reviewed by Darin Adler.
3091
3092         * Shared/cf/ArgumentCodersCF.cpp:
3093         (CoreIPC::encode):
3094         (CoreIPC::decode):
3095         Fix for the bug: use good shared WebCore code to manipulate CFURLs. Also, added
3096         a FIXME about empty URLs.
3097
3098         * Shared/API/c/cf/WKURLCF.cpp: (WKURLCreateWithCFURL): Fixed to not use
3099         CFURLGetString, as that could prevent loading certain resources, like ones with
3100         curly braces in resource specifiers. We want KURL normalization, not CFURL one.
3101
3102 2013-05-28  Tim Horton  <timothy_horton@apple.com>
3103
3104         Rendering suppression extension tokens shouldn't be 0, should handle overflow
3105         https://bugs.webkit.org/show_bug.cgi?id=116886
3106         <rdar://problem/14004474>
3107
3108         Reviewed by Darin Adler.
3109
3110         Don't use invalid HashSet values as tokens, and ensure that
3111         we're not already using a token before returning it.
3112
3113         * WebProcess/WebPage/WebPage.cpp:
3114         (WebKit::WebPage::extendIncrementalRenderingSuppression):
3115
3116 2013-05-28  Lauro Neto <lauro.neto@openbossa.org>
3117
3118         [GTK] Connection issues in repeated WebProcess crash/reloads.
3119         https://bugs.webkit.org/show_bug.cgi?id=115880
3120
3121         Reviewed by Anders Carlsson.
3122
3123         When stressing the WebProcess creation/destruction, WebKitGTK can
3124         often run into socket issues like bad file descriptor errors or
3125         polling a socket indefinitely.
3126
3127         Currently WebKitGTK has three places where a socket can be
3128         closed.
3129
3130         - childFinishedFunction (in ProcessLauncherGtk.cpp)
3131         - Connection::platformInvalidate (in ConnectionUnix.cpp)
3132         - WorkQueue EventSource destruction (in WorkQueueGtk.cpp)
3133
3134         To avoid these race conditions, socket closing will be handled
3135         by the event source callback in WorkQueueGtk.cpp.
3136
3137         * Platform/CoreIPC/unix/ConnectionUnix.cpp:
3138         (CoreIPC::Connection::platformInvalidate): Do not close the socket
3139         when the connection is invalidated, the socket event source is
3140         unregistered in this method and the socket is closed when the
3141         GSocket associated to the event source is destroyed.
3142         * UIProcess/Launcher/gtk/ProcessLauncherGtk.cpp:
3143         (WebKit::ProcessLauncher::launchProcess): Do not monitor child
3144         process to close the connection on termination. This was needed in
3145         the past when we used DGRAM sockets, we currently use always
3146         connection oriented sockets, so that when the other end closes
3147         the connection we are notified and the connection is invalidated.
3148
3149 2013-05-28  Martin Robinson  <mrobinson@igalia.com>
3150
3151         Fix GTK+ CMake build
3152
3153         * PlatformGTK.cmake: After r150336, the name of the WebKit2
3154         library target is simply "WebKit2."
3155
3156 2013-05-28  Marcelo Lira  <marcelo.lira@openbossa.org>
3157
3158         [WK2][CoordinatedGraphics] DrawingArea's visible content area must be updated when contents size changes
3159         https://bugs.webkit.org/show_bug.cgi?id=116845
3160
3161         Reviewed by Noam Rosenthal.
3162
3163         * UIProcess/CoordinatedGraphics/WebView.cpp:
3164         (WebKit::WebView::didChangeContentsSize):
3165
3166 2013-05-28  Noam Rosenthal  <noam@webkit.org>
3167
3168         [Qt] REGRESSION(r149292): broke scrolling in Qt WK2 desktop mode
3169         https://bugs.webkit.org/show_bug.cgi?id=116597
3170
3171         ScrollingCoordinatorCoordinatedGraphics is tailored specifically for
3172         fixedLayout mode. When fixedLayout is not set, it should be turned off.
3173
3174         Reviewed by Allan Sandfeld Jensen.
3175
3176         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.cpp:
3177         (WebKit::CoordinatedLayerTreeHost::CoordinatedLayerTreeHost):
3178
3179 2013-05-28  Andreas Kling  <akling@apple.com>
3180
3181         Document::setFocusedNode() should be setFocusedElement().
3182         <http://webkit.org/b/116857>
3183
3184         Reviewed by Antti Koivisto.
3185
3186         * WebProcess/Plugins/PluginView.cpp:
3187         (WebKit::PluginView::focusPluginElement):
3188         * WebProcess/WebPage/WebPage.cpp:
3189         (WebKit::WebPage::focusedPluginViewForFrame):
3190         (WebKit::WebPage::setInitialFocus):
3191
3192 2013-05-28  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
3193
3194         [EFL][WK2] Clean up duplicated include files.
3195         https://bugs.webkit.org/show_bug.cgi?id=116851
3196
3197         Reviewed by Christophe Dumez.
3198
3199         Remove some of duplicated include file in ewk files.
3200
3201         * UIProcess/API/efl/EwkView.h:
3202         * UIProcess/API/efl/ewk_color_picker.cpp:
3203         * UIProcess/API/efl/ewk_context_menu.cpp:
3204         * UIProcess/API/efl/ewk_security_origin_private.h:
3205
3206 2013-05-28  Ryuan Choi  <ryuan.choi@samsung.com>
3207
3208         [EFL] pc files should have harfbuzz dependency.
3209         https://bugs.webkit.org/show_bug.cgi?id=116852
3210
3211         Reviewed by Gyuyoung Kim.
3212
3213         * efl/ewebkit2.pc.in: Added harfbuzz as Required package.
3214
3215 2013-05-27  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
3216
3217         [EFL][WK2] Remove unneeded WebCore namespace use in ewk
3218         https://bugs.webkit.org/show_bug.cgi?id=116707
3219
3220         Reviewed by Christophe Dumez.
3221
3222         * UIProcess/API/efl/ewk_security_origin.cpp: Remove "using namespace WebCore".
3223         * UIProcess/API/efl/ewk_text_checker.cpp: ditto.
3224
3225 2013-05-26  Jon Lee  <jonlee@apple.com>
3226
3227         [WK2] Notifications clobber each other with multiple processes
3228         https://bugs.webkit.org/show_bug.cgi?id=116428
3229         <rdar://problem/13935191>
3230
3231         Reviewed by Darin Adler.
3232
3233         With multiple processes, the notification IDs, when passed up to the UI process, can clobber
3234         each other. To fix this, we need to maintain a global map of notification IDs. This map is
3235         keyed by its own unique notification ID, and maps to a pair containing the web page ID and that
3236         web page's ID for the notification.
3237
3238         Now that we maintain groups of notifications based on the web page, we no longer send IPC messages
3239         from WebNotificationManager to WebNotificationManagerProxy; instead we send messages to the
3240         WebPageProxy. This removes the need for WebNotificationManagerProxy to be a message receiver.
3241
3242         When a page closes, all of the web notifications are cleared out. However, by the time the
3243         WebPage::close() is called, the connection between WebPage and WebPageProxy is destroyed. Since
3244         the WebPage is told to close from the UI process anyway, we clear out the notifications separately,
3245         instead of waiting for a message from the WebPage.
3246
3247         * UIProcess/Notifications/WebNotificationManagerProxy.h: Update to take into account the
3248         notification's web page. Remove inheritance of CoreIPC::MessageReceiver. Expose the original message
3249         handlers as public functions, since they will be called from WebPageProxy. Add a new map that
3250         associates a global ID with a notification ID that came from a web page.
3251             There are now two flavors of clearNotifications(). One clears out all notifications associated
3252         with a web page. This is called when the page is closed. The other clears out a subset of
3253         notifications associated with a web page. This is called when notifications associated with a sub-frame
3254         is closed.
3255         * UIProcess/Notifications/WebNotificationManagerProxy.messages.in: Removed. All messages from
3256         the web process go to WebPageProxy now.
3257
3258         * UIProcess/Notifications/WebNotificationManagerProxy.cpp: Update to take into account the
3259         notification's web page.
3260
3261         (WebKit::generateGlobalNotificationID): The manager proxy now maintains its own global notification
3262         ID generator.
3263         (WebKit::WebNotificationManagerProxy::WebNotificationManagerProxy): The proxy is no longer a
3264         message receiver. Remove code that registers it as such.
3265
3266         (WebKit::WebNotificationManagerProxy::show): Refactor to differentiate between the notification ID
3267         that came from the web process, and the global notification ID the proxy maintains. Add the mapping
3268         from the global ID to the (web page ID, notification ID) pair.
3269         (WebKit::WebNotificationManagerProxy::cancel): Refactor to take into consideration the web page.
3270         (WebKit::WebNotificationManagerProxy::didDestroyNotification): Refactor to take into consideration
3271         the web page. Fixes a leak where we did not remove the item from the maps. This function is called
3272         from the web process, when the ScriptExecutionContext is destroyed, so we remove it from our maps
3273         before we pass the message along to the provider.
3274
3275         Helper functions that evaluate when a given notification in the map matches the desired parameters.
3276         (WebKit::pageIDsMatch): The notification is associated with the provided page.
3277         (WebKit::pageAndNotificationIDsMatch): The notification is associated with the provided page and is
3278         contained within the list of provided notifications.
3279
3280         (WebKit::WebNotificationManagerProxy::clearNotifications): Changed to only remove notifications
3281         associated with the provided web page, and could include a specific list of notifications. This latter
3282         situation occurs if notifications were associated with an iframe, and that iframe was removed.
3283         There is an O(n) walk that could be make more efficient using another hash map, but that's overhead
3284         for a map that should be small in size anyway.
3285
3286         (WebKit::WebNotificationManagerProxy::providerDidShowNotification): Refactor to take into
3287         consideration the web page.
3288         (WebKit::WebNotificationManagerProxy::providerDidClickNotification): Refactor to take into
3289         consideration the web page.
3290         (WebKit::WebNotificationManagerProxy::providerDidCloseNotifications): Now we need to comb through
3291         the list of global IDs and put them in buckets based on the notification's web pages. After that
3292         is done we can send the DidCloseNotifications() to those pages' processes. There is a possible
3293         extra optimization here where we group based on the page's process instead, to reduce the number
3294         of messages sent to processes.
3295
3296         * UIProcess/WebPageProxy.cpp:
3297         (WebKit::WebPageProxy::close): When a web page is closed, we clear the notifications associated
3298         with the page.
3299         (WebKit::WebPageProxy::cancelNotification): Forward call to WebNotificationManagerProxy.
3300         (WebKit::WebPageProxy::clearNotifications): Ditto.
3301         (WebKit::WebPageProxy::didDestroyNotification): Ditto.
3302         * UIProcess/WebPageProxy.h:
3303         * UIProcess/WebPageProxy.messages.in:
3304
3305         * WebProcess/Notifications/NotificationPermissionRequestManager.cpp:
3306         * WebProcess/Notifications/WebNotificationManager.cpp:
3307         (WebKit::WebNotificationManager::cancel):
3308         (WebKit::WebNotificationManager::clearNotifications):
3309         (WebKit::WebNotificationManager::didDestroyNotification):
3310         * WebProcess/Notifications/NotificationPermissionRequestManager.cpp: Remove extraneous include.
3311
3312         * CMakeLists.txt: Remove WebNotificationManagerProxy.messages.in and related files.
3313         * DerivedSources.pri: Ditto.
3314         * DerivedSources.make: Ditto.
3315         * GNUmakefile.list.am: Ditto.
3316         * WebKit2.xcodeproj/project.pbxproj: Ditto.
3317
3318 2013-05-27  Tim Horton  <timothy_horton@apple.com>
3319
3320         Unreviewed build fix take 2.
3321
3322         * WebProcess/Plugins/PDF/PDFPlugin.mm:
3323
3324 2013-05-27  Tim Horton  <timothy_horton@apple.com>
3325
3326         Unreviewed build fix.
3327
3328         * WebProcess/Plugins/PDF/PDFPlugin.mm:
3329
3330 2013-05-27  Tim Horton  <timothy_horton@apple.com>
3331
3332         PDFPlugin: Main-frame PDFPlugin Accessibility
3333         https://bugs.webkit.org/show_bug.cgi?id=116563
3334         <rdar://problem/13458534>
3335
3336         Reviewed by Sam Weinig.
3337
3338         * WebProcess/Plugins/PDF/PDFLayerControllerDetails.h:
3339         Forward-declare a variety of accessibility methods.
3340
3341         * WebProcess/Plugins/PDF/PDFPlugin.h:
3342         Add convertFromPDFViewToScreen, boundsOnScreen, accessibilityObject, and
3343         storage for our accessibility wrapper.
3344         * WebProcess/Plugins/PDF/PDFPlugin.mm:
3345         Add WKPDFPluginAccessibilityObject.
3346
3347         (-[WKPDFPluginAccessibilityObject accessibilityIsIgnored]):
3348         We want to be included in the accessibility tree.
3349
3350         (-[WKPDFPluginAccessibilityObject accessibilityAttributeValue:]):
3351         (-[WKPDFPluginAccessibilityObject accessibilityAttributeValue:forParameter:]):
3352         Grab values for accessibility attributes from the relevant sources
3353         (mostly from PDFLayerController).
3354
3355         (-[WKPDFPluginAccessibilityObject readingModel]): Ditto.
3356         (-[WKPDFPluginAccessibilityObject accessibilityAttributeNames]):
3357         (-[WKPDFPluginAccessibilityObject accessibilityParameterizedAttributeNames]):
3358         (-[WKPDFPluginAccessibilityObject accessibilityActionNames]):
3359         Return the set of accessibility attributes, actions, and parameterized
3360         attributes that we support.
3361
3362         (-[WKPDFPluginAccessibilityObject accessibilityIsAttributeSettable:]):
3363         (-[WKPDFPluginAccessibilityObject accessibilitySetValue:forAttribute:]):
3364         Forward some other accessibility methods to PDFLayerController.
3365
3366         (-[WKPDFPluginAccessibilityObject accessibilityFocusedUIElement]):
3367         (-[WKPDFPluginAccessibilityObject accessibilityHitTest:]):
3368         We have no children, so if a hit test makes it to us, it's ours.
3369
3370         (WebKit::PDFPlugin::PDFPlugin):
3371         Make a WKPDFPluginAccessibilityObject and hook it up.
3372         [FIXME: this could use some de-crapifying]
3373
3374         (WebKit::PDFPlugin::convertFromPluginToPDFView):
3375         Transform a point from plugin space to PDFLayerController space.
3376
3377         (WebKit::PDFPlugin::convertFromPDFViewToRootView):
3378         (WebKit::PDFPlugin::convertFromPDFViewToScreen): Added.
3379         (WebKit::PDFPlugin::boundsOnScreen):
3380         Return the PDFPlugin's frame in screen coordinates.
3381
3382         (WebKit::PDFPlugin::accessibilityObject):
3383         Return our accessibility wrapper.
3384
3385         * WebProcess/Plugins/PDF/SimplePDFPlugin.h:
3386         * WebProcess/Plugins/Plugin.h:
3387         (WebKit::Plugin::accessibilityObject):
3388         * WebProcess/Plugins/PluginView.cpp:
3389         (WebKit::PluginView::accessibilityObject):
3390         * WebProcess/Plugins/PluginView.h:
3391         Add accessibilityObject(), to acquire accessibility wrappers from plugins.
3392
3393         * WebProcess/WebPage/WebPage.h:
3394         (WebPage): Add accessibilityObjectForMainFramePlugin();
3395         * WebProcess/WebPage/mac/WKAccessibilityWebPageObject.mm:
3396         (-[WKAccessibilityWebPageObject accessibilityRootObjectWrapper]):
3397         If the main frame has a PluginDocument that has an accessibilityObject,
3398         use that one instead of the WebPage's.
3399
3400         * WebProcess/WebPage/mac/WebPageMac.mm:
3401         (WebKit::WebPage::accessibilityObjectForMainFramePlugin):
3402         Return the accessibilityObject from the main-frame PluginDocument, if
3403         there is one.
3404
3405 2013-05-27  Marcelo Lira  <marcelo.lira@openbossa.org>
3406
3407         [WK2][CoordinatedGraphics] Misuse of DrawingAreaProxy::setVisibleContentsRect() in WebView::updateViewportSize()
3408         https://bugs.webkit.org/show_bug.cgi?id=116688
3409
3410         Reviewed by Noam Rosenthal.
3411
3412         Visible contents area passed to DrawingAreaProxy::setVisibleContentsRect()
3413         must be calculated including the page scale factor and avoid crossing the
3414         boundaries of the page contents size. In other words the DrawingArea
3415         must know the actual dimensions of what it being drawn. If the
3416         DrawingArea thinks the visible rectangle is bigger than it is, the
3417         contents will be drawn pixelated and blurry.
3418
3419         * UIProcess/CoordinatedGraphics/WebView.cpp:
3420         (WebKit::WebView::didChangeContentsSize):
3421         (WebKit::WebView::updateViewportSize):
3422         (WebKit::WebView::visibleContentsSize):
3423         (WebKit):
3424         * UIProcess/CoordinatedGraphics/WebView.h:
3425         (WebKit::WebView::contentsSize):
3426         (WebView):
3427
3428 2013-05-27  Carlos Garcia Campos  <cgarcia@igalia.com>
3429
3430         [GTK] WebKitWebView child widgets are not rendered with recent GTK+
3431         https://bugs.webkit.org/show_bug.cgi?id=116794
3432
3433         Reviewed by Xan Lopez.
3434
3435         Since rev d22fd7223c75f4720ddb982c659efb0d8d7543c4 of GTK+ expose
3436         events are not propagated to child GdkWindows anymore, and child
3437         widgets are rendered via gtk_container_propagate_draw(). Since all
3438         our children have its own GdkWindow (auth widget, inspector view
3439         and windowed plugins) we don't propagate the draw signal making
3440         them invisible with current GTK+.
3441
3442         * UIProcess/API/gtk/WebKitWebViewBase.cpp:
3443         (webkitWebViewBaseDraw): Chain up to the parent draw(), so it's
3444         propagated to the children. This shouldn't have any effect in
3445         previous versions of GTK+ because gtk_container_propagate_draw()
3446         returned early when the child widget had its own GdkWindow.
3447
3448 2013-05-27  Xan Lopez  <xlopez@igalia.com>
3449
3450         Reset all clients on WebPage close
3451         https://bugs.webkit.org/show_bug.cgi?id=112334
3452
3453         Reviewed by Anders Carlsson.
3454
3455         We do not reset the clients on WebPage::close(), so there's a
3456         small chance that someone will try to access them after that. This
3457         won't work and will generally cause runtime warnings, crashes or
3458         other issues. Reset them all to null to prevent this situation.
3459
3460         * WebProcess/WebPage/WebPage.cpp:
3461         (WebKit::WebPage::close):
3462
3463 2013-05-27  Manuel Rego Casasnovas  <rego@igalia.com>
3464
3465         [GTK] Notify WebProcess in WebKitURISchemeRequest when we fail to read the user InputStream
3466         https://bugs.webkit.org/show_bug.cgi?id=114347
3467
3468         Reviewed by Carlos Garcia Campos.
3469
3470         While processing a WebKitURISchemeRequest if there is any error reading
3471         the InputStream provided by the user (for example the stream is already
3472         closed) we have to notify the WebProcess that the request has failed.
3473
3474         * UIProcess/API/gtk/WebKitURISchemeRequest.cpp:
3475         (webkitURISchemeRequestReadCallback): Get the error from
3476         g_input_stream_read_finish() and use it to call
3477         webkit_uri_scheme_request_finish_error() in order to finish the failing
3478         WebKitURISchemeRequest properly.
3479         * UIProcess/API/gtk/tests/TestWebKitWebContext.cpp:
3480         (testWebContextURIScheme): Modify test to check the new situation using
3481         an already closed InputStream.
3482
3483 2013-05-27  Carlos Garcia Campos  <cgarcia@igalia.com>
3484
3485         Unreviewed. Fix make distcheck.
3486
3487         * GNUmakefile.list.am: Add missing header file.
3488
3489 2013-05-26  Changhun Kang  <temoochin@company100.net>
3490
3491         The public WK header file should not include WKAPICast.h
3492         https://bugs.webkit.org/show_bug.cgi?id=115230
3493
3494         Reviewed by Darin Adler.
3495
3496         Otherwise, WebKit internal headers are exposed.
3497         No new tests. No change in behavior.
3498         * UIProcess/API/C/soup/WKSoupRequestManager.h:
3499         * UIProcess/soup/WebSoupRequestManagerClient.h:
3500
3501 2013-05-26  Andreas Kling  <akling@apple.com>
3502
3503         FocusController::setFocusedNode() should be setFocusedElement().
3504         <http://webkit.org/b/116780>
3505
3506         Reviewed by Antti Koivisto.
3507
3508         * WebProcess/Plugins/PluginView.cpp:
3509         (WebKit::PluginView::focusPluginElement):
3510
3511 2013-05-25  Andreas Kling  <akling@apple.com>
3512
3513         PluginDocument::pluginNode() should be pluginElement() instead.
3514         <http://webkit.org/b/116774>
3515
3516         Reviewed by Anders Carlsson.
3517
3518         * WebProcess/WebPage/WebPage.cpp:
3519         (WebKit::WebPage::focusedPluginViewForFrame):
3520
3521 2013-05-25  Simon Fraser  <simon.fraser@apple.com>
3522
3523         Unprefix Page Visibility API
3524         https://bugs.webkit.org/show_bug.cgi?id=102340
3525
3526         Reviewed by Tim Horton.
3527         
3528         Renaming of the "preview" state to "unloaded".
3529
3530         * Shared/API/c/WKPageVisibilityTypes.h:
3531         * Shared/API/c/WKSharedAPICast.h:
3532         (WebKit::toPageVisibilityState):
3533
3534 2013-05-25  Andreas Kling  <akling@apple.com>
3535
3536         Move Node::isMouseFocusable() to Element.
3537         <http://webkit.org/b/116762>
3538
3539         Reviewed by Anders Carlsson.
3540
3541         * WebProcess/WebPage/WebPage.cpp:
3542         (WebKit::WebPage::highlightPotentialActivation):
3543
3544             Check that the potentially activated Node is an Element before asking if it's mouse-focusable.
3545
3546 2013-05-25  Andreas Kling  <akling@apple.com>
3547
3548         REGRESSION: WebProcess is terminated when all Safari windows are closed.
3549         <rdar://problem/13990901>
3550         <http://webkit.org/b/116766>
3551
3552         Reviewed by Alexey Proskuryakov.
3553
3554         When closing the last page, only disconnect the web process if we're using a network process.
3555         Otherwise there might be session state in the web process getting lost.
3556
3557         * UIProcess/WebProcessProxy.cpp:
3558         (WebKit::WebProcessProxy::removeWebPage):
3559
3560 2013-05-25  Santosh Mahto  <santosh.ma@samsung.com>
3561
3562         WebFrameProxy::didFailLoad clears frame title for no apparent reason
3563         https://bugs.webkit.org/show_bug.cgi?id=116655
3564
3565         Reviewed by Alexey Proskuryakov.
3566
3567         * UIProcess/WebFrameProxy.cpp:
3568         (WebKit::WebFrameProxy::didFailLoad):
3569
3570 2013-05-24  Seokju Kwon  <seokju.kwon@gmail.com>
3571
3572         [Qt][GTK] Build fix after r150669
3573         https://bugs.webkit.org/show_bug.cgi?id=116751
3574
3575         Reviewed by Christophe Dumez.
3576
3577         * GNUmakefile.list.am:
3578         * Target.pri:
3579         * WebProcess/WebCoreSupport/gtk/WebEditorClientGtk.cpp:
3580         (WebKit::WebEditorClient::getEditorCommandsForKeyEvent):
3581
3582 2013-05-24  Seokju Kwon  <seokju.kwon@gmail.com>
3583
3584         [EFL] Build fix after r150669
3585         https://bugs.webkit.org/show_bug.cgi?id=116750
3586
3587         Reviewed by Anders Carlsson.
3588
3589         * CMakeLists.txt:
3590         * WebProcess/Battery/WebBatteryManager.cpp:
3591         (WebKit::WebBatteryManager::registerWebPage):
3592         (WebKit::WebBatteryManager::unregisterWebPage):
3593         * WebProcess/NetworkInfo/WebNetworkInfoManager.cpp:
3594         (WebKit::WebNetworkInfoManager::registerWebPage):
3595         (WebKit::WebNetworkInfoManager::unregisterWebPage):
3596         (WebKit::WebNetworkInfoManager::bandwidth):
3597         (WebKit::WebNetworkInfoManager::metered):
3598         * WebProcess/WebCoreSupport/WebVibrationClient.cpp:
3599         (WebKit::WebVibrationClient::vibrate):
3600         (WebKit::WebVibrationClient::cancelVibration):
3601         * WebProcess/soup/WebSoupRequestManager.cpp:
3602         (WebKit::WebSoupRequestManager::didReceiveURIRequestData):
3603         (WebKit::WebSoupRequestManager::send):
3604
3605 2013-05-24  Anders Carlsson  <andersca@apple.com>
3606
3607         MessageSender shouldn't be a class template
3608         https://bugs.webkit.org/show_bug.cgi?id=116743
3609
3610         Reviewed by Andreas Kling.
3611
3612         Change MessageSender to be a proper abstract base class. Subclasses of MessageSender must
3613         implement messageSenderConnection() as well as messageSenderDestinationID().
3614
3615         This reduces code size and will allow us to be more flexible with MessageSender in the future.
3616
3617         * NetworkProcess/NetworkResourceLoader.cpp:
3618         (WebKit::NetworkResourceLoader::sendAbortingOnFailure):
3619         (WebKit::NetworkResourceLoader::messageSenderConnection):
3620         (WebKit):
3621         (WebKit::NetworkResourceLoader::messageSenderDestinationID):
3622         * NetworkProcess/NetworkResourceLoader.h:
3623         (NetworkResourceLoader):
3624         * NetworkProcess/mac/DiskCacheMonitor.h:
3625         (DiskCacheMonitor):
3626         * NetworkProcess/mac/DiskCacheMonitor.mm:
3627         (WebKit::DiskCacheMonitor::messageSenderConnection):
3628         (WebKit::DiskCacheMonitor::messageSenderDestinationID):
3629         (WebKit):
3630         * Platform/CoreIPC/MessageSender.h:
3631         (CoreIPC):
3632         (MessageSender):
3633         (CoreIPC::MessageSender::send):
3634         (CoreIPC::MessageSender::sendSync):
3635         * Shared/ChildProcess.cpp:
3636         (WebKit::ChildProcess::messageSenderConnection):
3637         (WebKit):
3638         (WebKit::ChildProcess::messageSenderDestinationID):
3639         * Shared/ChildProcess.h:
3640         (ChildProcess):
3641         * Shared/Downloads/Download.cpp:
3642         (WebKit::Download::messageSenderConnection):
3643         (WebKit):
3644         (WebKit::Download::messageSenderDestinationID):
3645         * Shared/Downloads/Download.h:
3646         (Download):
3647         * Shared/Network/CustomProtocols/mac/CustomProtocolManagerMac.mm:
3648         (WebKit::CustomProtocolManager::initialize):
3649         * Shared/WebConnection.h:
3650         (WebConnection):
3651         * Shared/mac/SecItemShim.cpp:
3652         (WebKit::sendSecItemRequest):
3653         * UIProcess/WebConnectionToWebProcess.cpp:
3654         (WebKit::WebConnectionToWebProcess::hasValidConnection):
3655         (WebKit::WebConnectionToWebProcess::messageSenderConnection):
3656         (WebKit::WebConnectionToWebProcess::messageSenderDestinationID):
3657         * UIProcess/WebConnectionToWebProcess.h:
3658         (WebConnectionToWebProcess):
3659         * WebKit2.xcodeproj/project.pbxproj:
3660         * WebProcess/Geolocation/WebGeolocationManager.cpp:
3661         (WebKit::WebGeolocationManager::registerWebPage):
3662         (WebKit::WebGeolocationManager::unregisterWebPage):
3663         * WebProcess/IconDatabase/WebIconDatabaseProxy.cpp:
3664         (WebKit::WebIconDatabaseProxy::retainIconForPageURL):
3665         (WebKit::WebIconDatabaseProxy::releaseIconForPageURL):
3666         (WebKit::WebIconDatabaseProxy::synchronousIconForPageURL):
3667         (WebKit::WebIconDatabaseProxy::loadDecisionForIconURL):
3668         (WebKit::WebIconDatabaseProxy::setIconURLForPageURL):
3669         (WebKit::WebIconDatabaseProxy::setIconDataForIconURL):
3670         * WebProcess/InjectedBundle/InjectedBundle.cpp:
3671         (WebKit::InjectedBundle::postMessage):
3672         (WebKit::InjectedBundle::postSynchronousMessage):
3673         * WebProcess/Network/WebResourceLoader.cpp:
3674         (WebKit::WebResourceLoader::messageSenderConnection):
3675         (WebKit::WebResourceLoader::messageSenderDestinationID):
3676         * WebProcess/Network/WebResourceLoader.h:
3677         (WebResourceLoader):
3678         * WebProcess/Notifications/WebNotificationManager.cpp:
3679         (WebKit::WebNotificationManager::show):
3680         (WebKit::WebNotificationManager::cancel):
3681         (WebKit::WebNotificationManager::clearNotifications):
3682         (WebKit::WebNotificationManager::didDestroyNotification):
3683         * WebProcess/Plugins/PDF/PDFPlugin.mm:
3684         (WebKit::PDFPlugin::writeItemsToPasteboard):
3685         * WebProcess/Plugins/PluginProcessConnectionManager.cpp:
3686         (WebKit::PluginProcessConnectionManager::getPluginProcessConnection):
3687         * WebProcess/Storage/StorageAreaMap.cpp:
3688         (WebKit::StorageAreaMap::StorageAreaMap):
3689         (WebKit::StorageAreaMap::~StorageAreaMap):
3690         (WebKit::StorageAreaMap::setItem):
3691         (WebKit::StorageAreaMap::removeItem):
3692         (WebKit::StorageAreaMap::clear):
3693         (WebKit::StorageAreaMap::loadValuesIfNeeded):
3694         * WebProcess/WebConnectionToUIProcess.cpp:
3695         (WebKit::WebConnectionToUIProcess::hasValidConnection):
3696         (WebKit::WebConnectionToUIProcess::messageSenderConnection):
3697         (WebKit::WebConnectionToUIProcess::messageSenderDestinationID):
3698         * WebProcess/WebConnectionToUIProcess.h:
3699         (WebConnectionToUIProcess):
3700         * WebProcess/WebCoreSupport/WebChromeClient.cpp:
3701         (WebKit::WebChromeClient::windowRect):
3702         (WebKit::WebChromeClient::focusedFrameChanged):
3703         (WebKit::WebChromeClient::createWindow):
3704         (WebKit::WebChromeClient::toolbarsVisible):
3705         (WebKit::WebChromeClient::statusbarVisible):
3706         (WebKit::WebChromeClient::menubarVisible):
3707         (WebKit::WebChromeClient::runBeforeUnloadConfirmPanel):
3708         (WebKit::WebChromeClient::runJavaScriptAlert):
3709         (WebKit::WebChromeClient::runJavaScriptConfirm):
3710         (WebKit::WebChromeClient::runJavaScriptPrompt):
3711         (WebKit::WebChromeClient::shouldInterruptJavaScript):
3712         (WebKit::WebChromeClient::exceededDatabaseQuota):
3713         * WebProcess/WebCoreSupport/WebColorChooser.cpp:
3714         (WebKit::WebColorChooser::WebColorChooser):
3715         (WebKit::WebColorChooser::setSelectedColor):
3716         (WebKit::WebColorChooser::endChooser):
3717         * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
3718         (WebKit::WebFrameLoaderClient::dispatchDidReceiveIcon):
3719         (WebKit::WebFrameLoaderClient::updateGlobalHistory):
3720         (WebKit::WebFrameLoaderClient::updateGlobalHistoryRedirectLinks):
3721         (WebKit::WebFrameLoaderClient::setTitle):
3722         * WebProcess/WebCoreSupport/WebPlatformStrategies.cpp:
3723         (WebKit::WebPlatformStrategies::populatePluginCache):
3724         (WebKit::WebPlatformStrategies::getTypes):
3725         (WebKit::WebPlatformStrategies::bufferForType):
3726         (WebKit::WebPlatformStrategies::getPathnamesForType):
3727         (WebKit::WebPlatformStrategies::stringForType):
3728         (WebKit::WebPlatformStrategies::copy):
3729         (WebKit::WebPlatformStrategies::changeCount):
3730         (WebKit::WebPlatformStrategies::uniqueName):
3731         (WebKit::WebPlatformStrategies::color):
3732         (WebKit::WebPlatformStrategies::url):
3733         (WebKit::WebPlatformStrategies::addTypes):
3734         (WebKit::WebPlatformStrategies::setTypes):
3735         (WebKit::WebPlatformStrategies::setBufferForType):
3736         (WebKit::WebPlatformStrategies::setPathnamesForType):
3737         (WebKit::WebPlatformStrategies::setStringForType):
3738         * WebProcess/WebCoreSupport/WebPopupMenu.cpp:
3739         (WebKit::WebPopupMenu::show):
3740         (WebKit::WebPopupMenu::hide):
3741         * WebProcess/WebCoreSupport/WebSearchPopupMenu.cpp:
3742         (WebKit::WebSearchPopupMenu::saveRecentSearches):
3743         (WebKit::WebSearchPopupMenu::loadRecentSearches):
3744         * WebProcess/WebPage/EventDispatcher.cpp:
3745         (WebKit::EventDispatcher::sendDidReceiveEvent):
3746         * WebProcess/WebPage/WebBackForwardListProxy.cpp:
3747         (WebKit::updateBackForwardItem):
3748         (WebKit::WebBackForwardListProxy::itemAtIndex):
3749         (WebKit::WebBackForwardListProxy::backListCount):
3750         (WebKit::WebBackForwardListProxy::forwardListCount):
3751         * WebProcess/WebPage/WebInspector.cpp:
3752         (WebKit::WebInspector::createInspectorPage):
3753         (WebKit::WebInspector::didClose):
3754         (WebKit::WebInspector::bringToFront):
3755         (WebKit::WebInspector::inspectedURLChanged):
3756         (WebKit::WebInspector::save):
3757         (WebKit::WebInspector::append):
3758         (WebKit::WebInspector::attachBottom):
3759         (WebKit::WebInspector::attachRight):
3760         (WebKit::WebInspector::detach):
3761         (WebKit::WebInspector::setAttachedWindowHeight):
3762         (WebKit::WebInspector::setAttachedWindowWidth):
3763         (WebKit::WebInspector::setToolbarHeight):
3764         (WebKit::WebInspector::updateDockingAvailability):
3765         (WebKit::WebInspector::sendMessageToRemoteFrontend):
3766         * WebProcess/WebPage/WebPage.cpp:
3767         (WebKit::WebPage::messageSenderConnection):
3768         (WebKit):
3769         (WebKit::WebPage::messageSenderDestinationID):
3770         * WebProcess/WebPage/WebPage.h:
3771         (WebPage):
3772         * WebProcess/WebPage/mac/WebPageMac.mm:
3773         (WebKit::WebPage::executeKeypressCommandsInternal):
3774         (WebKit::WebPage::handleEditingKeyboardEvent):
3775         * WebProcess/WebProcess.cpp:
3776         (WebKit::WebProcess::ensureNetworkProcessConnection):
3777         (WebKit::WebProcess::shouldTerminate):
3778
3779 2013-05-24  Tim Horton  <timothy_horton@apple.com>
3780
3781         Animated GIFs don't repaint after TiledCoreAnimationDrawingArea un-suspends painting
3782         https://bugs.webkit.org/show_bug.cgi?id=116744
3783         <rdar://problem/13973514>
3784
3785         Reviewed by Simon Fraser.
3786
3787         * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
3788         (WebKit::TiledCoreAnimationDrawingArea::resumePainting):
3789         Force WebCore to repaint animated images when painting is resumed.
3790
3791 2013-05-24  Christophe Dumez  <ch.dumez@sisa.samsung.com>
3792
3793         Remove custom code for webkitAudioContext global constructor getter
3794         https://bugs.webkit.org/show_bug.cgi?id=116530
3795
3796         Reviewed by Geoffrey Garen.
3797
3798         Use RuntimeEnabledFeatures instead of WebCore Settings to toggle Web Audio support.
3799
3800         * WebProcess/InjectedBundle/InjectedBundle.cpp:
3801         (WebKit::InjectedBundle::overrideBoolPreferenceForTestRunner):
3802         * WebProcess/WebPage/WebPage.cpp:
3803         (WebKit::WebPage::updatePreferences):
3804
3805 2013-05-24  Thomas Deniau  <deniau@apple.com>
3806
3807         Add more lines to the context during Dictionary lookups
3808         https://bugs.webkit.org/show_bug.cgi?id=115256
3809
3810         Reviewed by Ryosuke Niwa.
3811
3812         * WebProcess/WebPage/mac/WebPageMac.mm:
3813         (WebKit::WebPage::performDictionaryLookupAtLocation):
3814         Instead of using the current paragraph as the context (which stops at
3815         line breaks), get a few lines before and after the point, so that the
3816         context contains at least four lines in each direction.
3817         This way the Dictionary will be able to look up things that extend past
3818         the current line.
3819
3820 2013-05-24  Anders Carlsson  <andersca@apple.com>
3821
3822         Intermittent crash when typing in Address Bar
3823         https://bugs.webkit.org/show_bug.cgi?id=116728
3824         <rdar://problem/13976781>
3825
3826         Reviewed by Sam Weinig.
3827
3828         If a web process connection has been removed from the storage manager because we disconnected it
3829         since there were no more active pages associated with the web process, we'll fail to find it here
3830         so just return early instead of crashing.
3831
3832         * UIProcess/Storage/StorageManager.cpp:
3833         (WebKit::StorageManager::destroyStorageMap):
3834
3835 2013-05-24  Andreas Kling  <akling@apple.com>
3836
3837         Typing in Safari's unified field causes unnecessary web content repaints.
3838         <http://webkit.org/b/116703>
3839
3840         Reviewed by Andy Estes.
3841
3842         * WebProcess/WebPage/FindController.cpp:
3843         (WebKit::FindController::countStringMatches):
3844
3845             Call WebCore::Page::countMatchesForText() instead of markAllMatchesForText(). If the search string
3846             is found inside the page content, the renderer containing that text will no longer be repainted.
3847
3848 2013-05-23  Ryuan Choi  <ryuan.choi@samsung.com>
3849
3850         [WK2][EFL][QT] Build break after r150610
3851         https://bugs.webkit.org/show_bug.cgi?id=116699
3852
3853         Reviewed by Csaba Osztrogonác.
3854
3855         * UIProcess/WebPageProxy.cpp:
3856         (WebKit::WebPageProxy::findPlugin): Initialized pluginProcessSandboxPolicy.
3857
3858 2013-05-23  Anders Carlsson  <andersca@apple.com>
3859
3860         Shim Flash plug-in to allow its updater to run
3861         https://bugs.webkit.org/show_bug.cgi?id=116692
3862         <rdar://problem/13938510>
3863
3864         Reviewed by Sam Weinig.
3865
3866         * PluginProcess/PluginProcess.h:
3867         * PluginProcess/mac/PluginProcessMac.mm:
3868         (WebKit::replacedNSConcreteTask_launch):
3869         (WebKit::initializeCocoaOverrides):
3870         Patch -[NSConcreteTask launch] to call PluginProcess::launchProcess.
3871
3872         (WebKit::PluginProcess::launchProcess):
3873         Send a LaunchProcess message to the UI process.
3874
3875         * UIProcess/Plugins/PluginProcessProxy.cpp:
3876         * UIProcess/Plugins/PluginProcessProxy.h:
3877         Remove PluginProcessProxy::didReceiveMessage.
3878
3879         (PluginProcessProxy):
3880         * UIProcess/Plugins/PluginProcessProxy.messages.in:
3881         Add LaunchProcess message and remove LegacyReceiver attribute.
3882
3883         * UIProcess/Plugins/mac/PluginProcessProxyMac.mm:
3884         (WebKit::isFlashUpdater):
3885         Helper function to determine whether the process is the flash updater.
3886
3887         (WebKit::shouldLaunchProcess):
3888         Return whether we should launch this process.
3889
3890         (WebKit::PluginProcessProxy::launchProcess):
3891         Determine if we should launch this process and then do so.
3892
3893 2013-05-23  Anders Carlsson  <andersca@apple.com>
3894
3895         Don't run all plug-ins unsandboxed
3896         https://bugs.webkit.org/show_bug.cgi?id=116690
3897         <rdar://problem/13975569>
3898
3899         Reviewed by Jessie Berlin.
3900
3901         Remove debugging code.
3902
3903         * UIProcess/WebPageProxy.cpp:
3904         (WebKit::WebPageProxy::findPlugin):
3905
3906 2013-05-23  Anders Carlsson  <andersca@apple.com>
3907
3908         Crash in convertMainResourceLoadToDownload when downloading file by option-return
3909         https://bugs.webkit.org/show_bug.cgi?id=116451
3910
3911         Reviewed by Andreas Kling.
3912
3913         If the main resource loader is null, create a new download instead since there's no existing loader to convert.
3914
3915         * NetworkProcess/NetworkConnectionToWebProcess.cpp:
3916         (WebKit::NetworkConnectionToWebProcess::convertMainResourceLoadToDownload):
3917         * WebProcess/WebPage/WebFrame.cpp:
3918         (WebKit::WebFrame::convertMainResourceLoadToDownload):
3919
3920 2013-05-22  Alexey Proskuryakov  <ap@apple.com>
3921
3922         <rdar://problem/13849260> Sandbox violations reading .CFUserTextEncoding
3923
3924         Reviewed by Dan Bernstein.
3925
3926         * WebProcess/com.apple.WebProcess.sb.in: Allow this.
3927
3928 2013-05-23  Gavin Barraclough  <barraclough@apple.com>
3929
3930         Move posix_spawn onto a zero delay timer
3931         https://bugs.webkit.org/show_bug.cgi?id=116682
3932
3933         Reviewed by Anders Carlson.
3934
3935         <rdar://problem/13973468>
3936
3937         * Shared/EntryPointUtilities/mac/XPCService/XPCServiceMain.Development.mm:
3938         (ReexecInfo):
3939             - struct to hold info from the XPC message.
3940         (WebKit::reexec):
3941             - moved call to posix_spawn out to this helper.
3942         (WebKit::reexecCallBack):
3943             - calls reexec.
3944         (WebKit::XPCServiceEventHandler):
3945             - removed call to posix_spawn; schedule a call to reexecCallBack.
3946
3947 2013-05-23  Csaba Osztrogonác  <ossy@webkit.org>
3948
3949         [cmake] Fix generating-forwarding-headers rule after r150460
3950         https://bugs.webkit.org/show_bug.cgi?id=116659
3951
3952         Reviewed by Christophe Dumez.
3953
3954         * CMakeLists.txt: Typo fix.
3955
3956 2013-05-23  Anton Obzhirov  <a.obzhirov@samsung.com>
3957
3958         [GTK] Remote Web Inspector sometimes won't serve any content
3959         https://bugs.webkit.org/show_bug.cgi?id=116225
3960
3961         Reviewed by Gustavo Noronha Silva.
3962
3963         Added an option to use environment variable to set up path to
3964         inspector server files. Implementation is similar to InspectorClientGtk
3965         implementation.
3966
3967         * UIProcess/InspectorServer/WebInspectorServer.h:
3968         (WebInspectorServer):
3969         * UIProcess/InspectorServer/gtk/WebInspectorServerGtk.cpp:
3970         (WebKit::WebInspectorServer::platformResourceForPath):
3971         (WebKit::WebInspectorServer::inspectorServerFilesPath):
3972         (WebKit):
3973
3974 2013-05-23  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
3975
3976         [EFL][WK2] Use WK2 C API in ewk_view_pagination_mode_set|get
3977         https://bugs.webkit.org/show_bug.cgi?id=116657
3978
3979         Reviewed by Christophe Dumez.
3980
3981         WKPageGet|SetPaginationMode APIs is present in WK2 C APIs. So, we need to use them for
3982         ewk_view_pagination_mode_set|get.
3983
3984         Besides we don't need to use WebCore namespace anymore.
3985
3986         * UIProcess/API/efl/ewk_view.cpp:
3987         (ewk_view_pagination_mode_set):
3988         (ewk_view_pagination_mode_get):
3989
3990 2013-05-23  Roland Takacs  <rtakacs@inf.u-szeged.hu>
3991
3992         Support frame instrumentation for coordinated graphics
3993         https://bugs.webkit.org/show_bug.cgi?id=115260
3994
3995         Reviewed by Andreas Kling.
3996
3997         Enabled supportsFrameInstrumentation on ports that use coordinated graphics
3998         by calling didBeginFrame().
3999
4000         * WebProcess/WebCoreSupport/WebInspectorClient.cpp:
4001         (WebKit::WebInspectorClient::supportsFrameInstrumentation):
4002         (WebKit):
4003         * WebProcess/WebCoreSupport/WebInspectorClient.h:
4004         (WebInspectorClient):
4005         * WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.cpp:
4006         (WebKit::CoordinatedLayerTreeHost::syncDisplayState):
4007
4008 2013-05-22  Dean Jackson  <dino@apple.com>
4009
4010         Don't snapshot plugins that can't be snapshotted
4011         https://bugs.webkit.org/show_bug.cgi?id=116490
4012
4013         Reviewed by Tim Horton.
4014
4015         Some plugins, such as QuickTime, don't support snapshotting. We're
4016         planning on another way to capture snapshots, but in the meantime make
4017         sure that they don't fail to initialise because they were told to
4018         not use accelerated rendering.
4019
4020         Expose a new message on the plugins so that they can tell the PluginView
4021         if they support snapshotting or not.
4022
4023         * PluginProcess/PluginControllerProxy.cpp:
4024         (WebKit::PluginControllerProxy::supportsSnapshotting): New method.
4025         * PluginProcess/PluginControllerProxy.h: Ditto.
4026         * PluginProcess/PluginControllerProxy.messages.in: Message signature.
4027
4028         * WebProcess/Plugins/Netscape/NetscapePlugin.h: Add supportsSnapshotting.
4029         * WebProcess/Plugins/PDF/SimplePDFPlugin.h: Ditto.
4030         * WebProcess/Plugins/Plugin.h: Ditto - pure virtual here.
4031
4032         * WebProcess/Plugins/PluginProxy.cpp:
4033         (WebKit::PluginProxy::supportsSnapshotting): Send the message to the plugin process and return the results.
4034         * WebProcess/Plugins/PluginProxy.h:
4035
4036         * WebProcess/Plugins/PluginView.cpp:
4037         (WebKit::PluginView::didInitializePlugin): If the snapshotting plugin has a layer, make
4038             sure to add it to the tree.
4039         (WebKit::PluginView::isAcceleratedCompositingEnabled): Snapshotting plugins can use
4040             accelerated compositing, just like normal plugins.
4041         (WebKit::PluginView::pluginSnapshotTimerFired): If the plugin doesn't allow snapshotting,
4042             immediately restart it.
4043
4044 2013-05-22  Anders Carlsson  <andersca@apple.com>
4045
4046         Fix crash when closing a page that's trying to access session storage
4047         https://bugs.webkit.org/show_bug.cgi?id=116634
4048         <rdar://problem/13904054>
4049
4050         Reviewed by Geoffrey Garen.
4051
4052         It is possible for the StorageManager to get messages from a web page that has already been closed by the UI process.
4053         If that happens, just ignore the messages.
4054
4055         * UIProcess/Storage/StorageManager.cpp:
4056         (WebKit::StorageManager::createSessionStorageMap):
4057         (WebKit::StorageManager::getValues):
4058         (WebKit::StorageManager::setItem):
4059         (WebKit::StorageManager::removeItem):
4060         (WebKit::StorageManager::clear):
4061         (WebKit::StorageManager::destroySessionStorageNamespaceInternal):
4062
4063 2013-05-22  Alexey Proskuryakov  <ap@apple.com>
4064
4065         Crashes in NetworkProcess due to incorrect private browsing session tracking
4066         https://bugs.webkit.org/show_bug.cgi?id=116628
4067
4068         Reviewed by Brady Eidson.
4069
4070         The current API for private browsing makes it extremely difficult to track sessions.
4071         Private browsing is enabled via WKPreferences, but the session is shared, so it
4072         has to be maintained while there is any chance that any page group anywhere still
4073         needs it.
4074
4075         This patch fixes some of the issues, but ultimately, I think that we'll just need
4076         to deprecate and replace the API.
4077
4078         * NetworkProcess/NetworkConnectionToWebProcess.cpp: (WebKit::storageSession):
4079         There are valid scenarios where privateBrowsingEnabled is true, but there is no
4080         private browsing session. Handle that without crashing, although this unfortunately
4081         means that it will be harder to spot logic errors when using a wrong session.
4082         (WebKit::NetworkConnectionToWebProcess::registerBlobURL): Removed an obsolete FIXME.
4083
4084         * NetworkProcess/mac/RemoteNetworkingContext.h: Changed privateBrowsingSession()
4085         to return a pointer, as no caller could know when it was safe to call it.
4086
4087         * NetworkProcess/mac/RemoteNetworkingContext.mm:
4088         (WebKit::RemoteNetworkingContext::storageSession): Handle the case where private
4089         browsing session is unexpectedly missing without crashing.
4090         (WebKit::RemoteNetworkingContext::privateBrowsingSession): Changed to return a pointer.
4091
4092         * UIProcess/WebContext.cpp: (WebKit::WebContext::ensureNetworkProcess):
4093         Actually initialize privateBrowsingEnabled creation parameter. It would be very
4094         difficult to figure out 100% reliably whether NetworkProcess needs a private browsing
4095         session with the current API, but for existing clients, looking at
4096         m_privateBrowsingEnterCount is good enough. Certainly better than not initializing.
4097
4098         * WebProcess/InjectedBundle/InjectedBundle.cpp:
4099         (WebKit::InjectedBundle::setPrivateBrowsingEnabled): Added a FIXME.
4100
4101 2013-05-22  Tim Horton  <timothy_horton@apple.com>
4102
4103         [wk2] Should be able to make tiled WKViews clip to the view's exposed rect without using autolayout
4104         https://bugs.webkit.org/show_bug.cgi?id=116625
4105         <rdar://problem/13962816>
4106
4107         Reviewed by Anders Carlsson.
4108
4109         The two modes are not dependent; it should be possible to enable
4110         clips-to-exposed-rect without using autolayout. This enables apps to
4111         make very large tiled WKViews that don't create tiles for the whole