[Soup] Wrap SoupSession by NetworkStorageSession
authorkbalazs@webkit.org <kbalazs@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 4 Feb 2013 09:33:30 +0000 (09:33 +0000)
committerkbalazs@webkit.org <kbalazs@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 4 Feb 2013 09:33:30 +0000 (09:33 +0000)
commit60537dac77cee9db8773916877f86f2650f17ce3
tree824735012352af93fa6840e48af76935c92ae8b5
parentf0157c440018ad52849c96aed8057d0bc75d4fcb
[Soup] Wrap SoupSession by NetworkStorageSession
https://bugs.webkit.org/show_bug.cgi?id=108615

Reviewed by Alexey Proskuryakov.

Source/WebCore:

Implement NetworkStorageSession for ports using soup. It has been
separated from NetworkingContext, so now we have a default storage
session, which is the same as before but now wrapped with NetworkStorageSession,
and it can be overridden by the networking context.

No change in behavior so no new tests.

* CMakeLists.txt:
* GNUmakefile.list.am:
* PlatformBlackBerry.cmake:
* PlatformEfl.cmake:
* loader/CookieJar.cpp:
(WebCore):
Now we also get the storage session from the networking context
and not the other way.

* platform/network/NetworkStorageSession.h:
(NetworkStorageSession):
(WebCore::NetworkStorageSession::setSoupSession):
(WebCore::NetworkStorageSession::soupSession):
Hold a SoupSession pointer for ports using soup. Added a setter because it is
necessary for API's that allow it to be specified per page, like EFL WK1.

* platform/network/NetworkingContext.h:
(NetworkingContext):
* platform/network/soup/CookieJarSoup.cpp:
(WebCore::cookieJarForSession):
* platform/network/soup/NetworkStorageSessionSoup.cpp: Copied from Source/WebKit2/WebProcess/WebCoreSupport/soup/WebFrameNetworkingContext.cpp.
(WebCore::NetworkStorageSession::NetworkStorageSession):
(WebCore::NetworkStorageSession::defaultStorageSession):
(WebCore::NetworkStorageSession::createDefaultSession):
(WebCore::NetworkStorageSession::createPrivateBrowsingSession):
(WebCore::NetworkStorageSession::switchToNewTestingSession):
* platform/network/soup/ResourceHandleSoup.cpp:
(WebCore::sessionFromContext):

* CMakeLists.txt:
* GNUmakefile.list.am:
* PlatformBlackBerry.cmake:
* PlatformEfl.cmake:
* loader/CookieJar.cpp:
(WebCore):
* platform/network/NetworkStorageSession.h:
(NetworkStorageSession):
(WebCore::NetworkStorageSession::setSoupSession):
(WebCore::NetworkStorageSession::soupSession):
* platform/network/NetworkingContext.h:
(NetworkingContext):
* platform/network/soup/CookieJarSoup.cpp:
(WebCore::cookieJarForSession):
* platform/network/soup/ResourceHandleSoup.cpp:
(WebCore::sessionFromContext):

Source/WebKit/efl:

Changed to hold the SoupSession pointer in a NetworkStorageSession
so we can pass it to WebCore. _Ewk_View_Private_Data has to be
changed for that reason.

* WebCoreSupport/FrameNetworkingContextEfl.cpp:
(WebCore::FrameNetworkingContextEfl::storageSession):
* WebCoreSupport/FrameNetworkingContextEfl.h:
(FrameNetworkingContextEfl):
* ewk/ewk_view.cpp:
(_Ewk_View_Private_Data):
(_ewk_view_priv_new):
(ewk_view_soup_session_get):
(ewk_view_soup_session_set):
(EWKPrivate::storageSession):
(EWKPrivate):
* ewk/ewk_view_private.h:
(EWKPrivate):

Source/WebKit/gtk:

* WebCoreSupport/FrameNetworkingContextGtk.cpp:
(WebKit::FrameNetworkingContextGtk::storageSession):
* WebCoreSupport/FrameNetworkingContextGtk.h:
(FrameNetworkingContextGtk):

Source/WebKit2:

* WebProcess/WebCoreSupport/soup/WebFrameNetworkingContext.cpp:
(WebKit::WebFrameNetworkingContext::storageSession):
* WebProcess/WebCoreSupport/soup/WebFrameNetworkingContext.h:
(WebFrameNetworkingContext):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@141749 268f45cc-cd09-0410-ab3c-d52691b4dbfc
22 files changed:
Source/WebCore/CMakeLists.txt
Source/WebCore/ChangeLog
Source/WebCore/GNUmakefile.list.am
Source/WebCore/PlatformBlackBerry.cmake
Source/WebCore/PlatformEfl.cmake
Source/WebCore/loader/CookieJar.cpp
Source/WebCore/platform/network/NetworkStorageSession.h
Source/WebCore/platform/network/NetworkingContext.h
Source/WebCore/platform/network/soup/CookieJarSoup.cpp
Source/WebCore/platform/network/soup/NetworkStorageSessionSoup.cpp [new file with mode: 0644]
Source/WebCore/platform/network/soup/ResourceHandleSoup.cpp
Source/WebKit/efl/ChangeLog
Source/WebKit/efl/WebCoreSupport/FrameNetworkingContextEfl.cpp
Source/WebKit/efl/WebCoreSupport/FrameNetworkingContextEfl.h
Source/WebKit/efl/ewk/ewk_view.cpp
Source/WebKit/efl/ewk/ewk_view_private.h
Source/WebKit/gtk/ChangeLog
Source/WebKit/gtk/WebCoreSupport/FrameNetworkingContextGtk.cpp
Source/WebKit/gtk/WebCoreSupport/FrameNetworkingContextGtk.h
Source/WebKit2/ChangeLog
Source/WebKit2/WebProcess/WebCoreSupport/soup/WebFrameNetworkingContext.cpp
Source/WebKit2/WebProcess/WebCoreSupport/soup/WebFrameNetworkingContext.h