<rdar://problem/16020380> [Cocoa] Inform the client when back-forward navigation gestures begin and end
https://bugs.webkit.org/show_bug.cgi?id=134853

Reviewed by Sam Weinig.

* UIProcess/API/Cocoa/WKNavigationDelegatePrivate.h: Declared new WKNavigationDelegate
methods.

* UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView _isShowingNavigationGestureSnapshot]): Added this getter.

* UIProcess/API/Cocoa/WKWebViewPrivate.h: Declared new property
_isShowingNavigationGestureSnapshot.

* UIProcess/Cocoa/NavigationState.h:
* UIProcess/Cocoa/NavigationState.mm:
(WebKit::NavigationState::setNavigationDelegate): Initialize new flags in
m_navigationDelegateMethods.
(WebKit::NavigationState::navigationGestureDidBegin): Added. Calls the new
WKNavigationDelegate method.
(WebKit::NavigationState::navigationGestureWillEnd): Ditto.
(WebKit::NavigationState::navigationGestureDidEnd): Ditto.

* UIProcess/PageClient.h: Declared new client functions.

* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::WebPageProxy): Initialize new member variable.
(WebKit::WebPageProxy::navigationGestureDidBegin): Set m_isShowingNavigationGestureSnapshot
and call the new client function.
(WebKit::WebPageProxy::navigationGestureWillEnd): Call the new client function.
(WebKit::WebPageProxy::navigationGestureDidEnd): Ditto.
(WebKit::WebPageProxy::navigationGestureSnapshotWasRemoved): Clear
m_isShowingNavigationGestureSnapshot.
* UIProcess/WebPageProxy.h:
(WebKit::WebPageProxy::isShowingNavigationGestureSnapshot): Added this getter.

* UIProcess/ios/PageClientImplIOS.h: Declared overrides of new client functions.
* UIProcess/ios/PageClientImplIOS.mm:
(WebKit::PageClientImpl::navigationGestureDidBegin): Override that calls the new
NavigationState function.
(WebKit::PageClientImpl::navigationGestureWillEnd): Ditto.
(WebKit::PageClientImpl::navigationGestureDidEnd): Ditto.

* UIProcess/ios/ViewGestureControllerIOS.mm:
(WebKit::ViewGestureController::beginSwipeGesture): Added calls to
WebPageProxy::navigationGestureDidBegin and WebPageProxy::navigationGestureWillEnd.
(WebKit::ViewGestureController::endSwipeGesture): Added calls to
WebPageProxy::navigationGestureDidEnd.
(WebKit::ViewGestureController::removeSwipeSnapshot): Added call to
WebPageProxy::navigationGestureSnapshotWasRemoved.

* UIProcess/mac/PageClientImpl.h: Declared overrides of new client functions.
* UIProcess/mac/PageClientImpl.mm:
(WebKit::PageClientImpl::navigationGestureDidBegin): Override that calls the new
NavigationState function.
(WebKit::PageClientImpl::navigationGestureWillEnd): Ditto.
(WebKit::PageClientImpl::navigationGestureDidEnd): Ditto.

* UIProcess/mac/ViewGestureControllerMac.mm:
(WebKit::ViewGestureController::beginSwipeGesture): Added call to
WebPageProxy::navigationGestureDidBegin.
(WebKit::ViewGestureController::endSwipeGesture): Added calls to
WebPageProxy::navigationGestureDidEnd.
(WebKit::ViewGestureController::removeSwipeSnapshot): Added call to
WebPageProxy::navigationGestureSnapshotWasRemoved.



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@171034 268f45cc-cd09-0410-ab3c-d52691b4dbfc
REGRESSION(r171024) [GTK] Build broken.
https://bugs.webkit.org/show_bug.cgi?id=134859

Unreviewed GTK build fix.


* UIProcess/gtk/WebContextGtk.cpp:
(WebKit::WebContext::platformMediaCacheDirectory):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@171035 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Memory leaks with autoLoadImages off
https://bugs.webkit.org/show_bug.cgi?id=124411

Reviewed by Darin Adler.

Do not emit notifyFinished for images with deferred load,
and allow deferred loads to be cancelled.

* loader/cache/CachedResource.cpp:
(WebCore::CachedResource::checkNotify):
(WebCore::CachedResource::cancelLoad):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@171036 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Use braced-init-list to create one-item Vector object in insertPerformanceEntry
https://bugs.webkit.org/show_bug.cgi?id=133675

Patch by Zan Dobersek <zdobersek@igalia.com> on 2014-07-12
Reviewed by Darin Adler.

* page/PerformanceUserTiming.cpp:
(WebCore::insertPerformanceEntry): Avoid wasting three lines for creating a
Vector object with just one item that in the end gets copied. Use the
braced-init-list syntax instead, leveraging Vector's std::initializer_list
constructor.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@171037 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Style Checker should prevent enums in bitfields
https://bugs.webkit.org/show_bug.cgi?id=57352

Reviewed by Darin Adler.

Added check that enums are not used as types for bitfields
and a unit test.

* Scripts/webkitpy/style/checkers/cpp.py:
(check_language):
(CppChecker):
* Scripts/webkitpy/style/checkers/cpp_unittest.py:
(CppStyleTest):
(CppStyleTest.test_enum_bitfields):
(CppStyleTest.test_plain_integral_bitfields):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@171038 268f45cc-cd09-0410-ab3c-d52691b4dbfc