Patch for https://bugs.webkit.org/show_bug.cgi?id=41826
authorweinig@apple.com <weinig@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 8 Jul 2010 16:35:32 +0000 (16:35 +0000)
committerweinig@apple.com <weinig@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 8 Jul 2010 16:35:32 +0000 (16:35 +0000)
Convert BackForwardList to an abstract base class and add BackForwardListImpl
as the concrete implementation of it.

Reviewed by Anders Carlsson.

WebCore:

* CMakeLists.txt:
* GNUmakefile.am:
* WebCore.exp.in:
* WebCore.gypi:
* WebCore.pro:
* WebCore.vcproj/WebCore.vcproj:
* WebCore.xcodeproj/project.pbxproj:
* history/BackForwardController.cpp:
(WebCore::BackForwardController::BackForwardController):
* history/BackForwardController.h:
* history/BackForwardList.cpp: Removed.
* history/BackForwardList.h:
(WebCore::BackForwardList::~BackForwardList):
(WebCore::BackForwardList::isBackForwardListImpl):
(WebCore::BackForwardList::BackForwardList):
* history/BackForwardListChromium.cpp:
* history/BackForwardListImpl.cpp: Copied from WebCore/history/BackForwardList.cpp.
* history/BackForwardListImpl.h: Copied from WebCore/history/BackForwardList.h.
(WebCore::BackForwardListImpl::isBackForwardListImpl):

WebKit/mac:

* History/WebBackForwardList.mm:
(-[WebBackForwardList init]):
(-[WebBackForwardList setPageCacheSize:]):
(-[WebBackForwardList pageCacheSize]):

WebKit/qt:

* Api/qwebhistory.cpp:
(QWebHistory::clear):
(QWebHistory::back):
(QWebHistory::forward):
(QWebHistory::goToItem):
(operator>>):
(QWebHistoryPrivate::page):

WebKit2:

* WebProcess/WebCoreSupport/WebBackForwardControllerClient.cpp:
(WebKit::WebBackForwardControllerClient::createBackForwardList):

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

20 files changed:
WebCore/CMakeLists.txt
WebCore/ChangeLog
WebCore/GNUmakefile.am
WebCore/WebCore.exp.in
WebCore/WebCore.gypi
WebCore/WebCore.pro
WebCore/WebCore.vcproj/WebCore.vcproj
WebCore/WebCore.xcodeproj/project.pbxproj
WebCore/history/BackForwardController.cpp
WebCore/history/BackForwardController.h
WebCore/history/BackForwardList.h
WebCore/history/BackForwardListChromium.cpp
WebCore/history/BackForwardListImpl.cpp [moved from WebCore/history/BackForwardList.cpp with 85% similarity]
WebCore/history/BackForwardListImpl.h [new file with mode: 0644]
WebKit/mac/ChangeLog
WebKit/mac/History/WebBackForwardList.mm
WebKit/qt/Api/qwebhistory.cpp
WebKit/qt/ChangeLog
WebKit2/ChangeLog
WebKit2/WebProcess/WebCoreSupport/WebBackForwardControllerClient.cpp

index 967c8c8..4c23d40 100644 (file)
@@ -899,7 +899,7 @@ SET(WebCore_SOURCES
     editing/visible_units.cpp
 
     history/BackForwardController.cpp
-    history/BackForwardList.cpp
+    history/BackForwardListImpl.cpp
     history/CachedFrame.cpp
     history/CachedPage.cpp
     history/HistoryItem.cpp
index b425789..d1ea86f 100644 (file)
@@ -1,3 +1,31 @@
+2010-07-08  Sam Weinig  <sam@webkit.org>
+
+        Reviewed by Anders Carlsson.
+
+        Patch for https://bugs.webkit.org/show_bug.cgi?id=41826
+        Convert BackForwardList to an abstract base class and add BackForwardListImpl
+        as the concrete implementation of it.
+
+        * CMakeLists.txt:
+        * GNUmakefile.am:
+        * WebCore.exp.in:
+        * WebCore.gypi:
+        * WebCore.pro:
+        * WebCore.vcproj/WebCore.vcproj:
+        * WebCore.xcodeproj/project.pbxproj:
+        * history/BackForwardController.cpp:
+        (WebCore::BackForwardController::BackForwardController):
+        * history/BackForwardController.h:
+        * history/BackForwardList.cpp: Removed.
+        * history/BackForwardList.h:
+        (WebCore::BackForwardList::~BackForwardList):
+        (WebCore::BackForwardList::isBackForwardListImpl):
+        (WebCore::BackForwardList::BackForwardList):
+        * history/BackForwardListChromium.cpp:
+        * history/BackForwardListImpl.cpp: Copied from WebCore/history/BackForwardList.cpp.
+        * history/BackForwardListImpl.h: Copied from WebCore/history/BackForwardList.h.
+        (WebCore::BackForwardListImpl::isBackForwardListImpl):
+
 2010-07-08  Vitaly Repeshko  <vitalyr@chromium.org>
 
         Reviewed by Pavel Feldman.
index dbbf0cf..7fa3752 100644 (file)
@@ -1054,8 +1054,9 @@ webcore_sources += \
        WebCore/history/BackForwardController.cpp \
        WebCore/history/BackForwardController.h \
        WebCore/history/BackForwardControllerClient.h \
-       WebCore/history/BackForwardList.cpp \
        WebCore/history/BackForwardList.h \
+       WebCore/history/BackForwardListImpl.cpp \
+       WebCore/history/BackForwardListImpl.h \
        WebCore/history/CachedFrame.cpp \
        WebCore/history/CachedFrame.h \
        WebCore/history/CachedFramePlatformData.h \
index c271525..bab7a1b 100644 (file)
@@ -317,29 +317,6 @@ __ZN7WebCore14SecurityOrigin40setDomainRelaxationForbiddenForURLSchemeEbRKNS_6St
 __ZN7WebCore14SecurityOrigin6createERKNS_4KURLEi
 __ZN7WebCore14SecurityOrigin7canLoadERKNS_4KURLERKNS_6StringEPNS_8DocumentE
 __ZN7WebCore15ArchiveResource6createEN3WTF10PassRefPtrINS_12SharedBufferEEERKNS_4KURLERKNS_6StringESA_SA_RKNS_16ResourceResponseE
-__ZN7WebCore15BackForwardList10removeItemEPNS_11HistoryItemE
-__ZN7WebCore15BackForwardList10setEnabledEb
-__ZN7WebCore15BackForwardList11currentItemEv
-__ZN7WebCore15BackForwardList11forwardItemEv
-__ZN7WebCore15BackForwardList11itemAtIndexEi
-__ZN7WebCore15BackForwardList11setCapacityEi
-__ZN7WebCore15BackForwardList12containsItemEPNS_11HistoryItemE
-__ZN7WebCore15BackForwardList13backListCountEv
-__ZN7WebCore15BackForwardList16forwardListCountEv
-__ZN7WebCore15BackForwardList17backListWithLimitEiRN3WTF6VectorINS1_6RefPtrINS_11HistoryItemEEELm0EEE
-__ZN7WebCore15BackForwardList20forwardListWithLimitEiRN3WTF6VectorINS1_6RefPtrINS_11HistoryItemEEELm0EEE
-__ZN7WebCore15BackForwardList5closeEv
-__ZN7WebCore15BackForwardList6closedEv
-__ZN7WebCore15BackForwardList6goBackEv
-__ZN7WebCore15BackForwardList7addItemEN3WTF10PassRefPtrINS_11HistoryItemEEE
-__ZN7WebCore15BackForwardList7enabledEv
-__ZN7WebCore15BackForwardList7entriesEv
-__ZN7WebCore15BackForwardList8backItemEv
-__ZN7WebCore15BackForwardList8capacityEv
-__ZN7WebCore15BackForwardList8goToItemEPNS_11HistoryItemE
-__ZN7WebCore15BackForwardList9goForwardEv
-__ZN7WebCore15BackForwardListC1EPNS_4PageE
-__ZN7WebCore15BackForwardListD1Ev
 __ZN7WebCore15DOMWrapperWorld15unregisterWorldEv
 __ZN7WebCore15DOMWrapperWorldD1Ev
 __ZN7WebCore15DatabaseTracker12deleteOriginEPNS_14SecurityOriginE
@@ -422,6 +399,7 @@ __ZN7WebCore19AnimationController16resumeAnimationsEPNS_8DocumentE
 __ZN7WebCore19AnimationController17suspendAnimationsEPNS_8DocumentE
 __ZN7WebCore19AnimationController20pauseAnimationAtTimeEPNS_12RenderObjectERKNS_6StringEd
 __ZN7WebCore19AnimationController21pauseTransitionAtTimeEPNS_12RenderObjectERKNS_6StringEd
+__ZN7WebCore19BackForwardListImplC1EPNS_4PageE
 __ZN7WebCore19CSSStyleDeclaration11setPropertyERKNS_6StringES3_Ri
 __ZN7WebCore19InspectorController34inspectorStartsAttachedSettingNameEv
 __ZN7WebCore19SelectionController10setFocusedEb
@@ -506,7 +484,6 @@ __ZN7WebCore4KURLC1ENS_18ParsedURLStringTagERKNS_6StringE
 __ZN7WebCore4KURLC1EP5NSURL
 __ZN7WebCore4KURLC1EPK7__CFURL
 __ZN7WebCore4KURLC1ERKS0_RKNS_6StringE
-__ZN7WebCore4coreEP20NSURLProtectionSpace
 __ZN7WebCore4Node10renderRectEPb
 __ZN7WebCore4Node17stopIgnoringLeaksEv
 __ZN7WebCore4Node18startIgnoringLeaksEv
@@ -533,6 +510,7 @@ __ZN7WebCore4Page9goForwardEv
 __ZN7WebCore4Page9initGroupEv
 __ZN7WebCore4PageC1EPNS_12ChromeClientEPNS_17ContextMenuClientEPNS_12EditorClientEPNS_10DragClientEPNS_15InspectorClientEPNS_18PluginHalterClientEPNS_27GeolocationControllerClientEPNS_23DeviceOrientationClientEPNS_27BackForwardControllerClientE
 __ZN7WebCore4PageD1Ev
+__ZN7WebCore4coreEP20NSURLProtectionSpace
 __ZN7WebCore4toJSEPN3JSC9ExecStateEPNS_17JSDOMGlobalObjectEPNS_19CSSStyleDeclarationE
 __ZN7WebCore5Cache11setDisabledEb
 __ZN7WebCore5Cache13getStatisticsEv
index 4edc426..dc3c1fc 100644 (file)
             'history/BackForwardController.cpp',
             'history/BackForwardController.h',
             'history/BackForwardControllerClient.h',
-            'history/BackForwardList.cpp',
             'history/BackForwardList.h',
+            'history/BackForwardListImpl.cpp',
+            'history/BackForwardListImpl.h',
             'history/BackForwardListChromium.cpp',
             'history/CachedFrame.cpp',
             'history/CachedFrame.h',
index d030e34..8a836f8 100644 (file)
@@ -600,7 +600,7 @@ SOURCES += \
     editing/visible_units.cpp \
     editing/WrapContentsInDummySpanCommand.cpp \
     history/BackForwardController.cpp \
-    history/BackForwardList.cpp \
+    history/BackForwardListImpl.cpp \
     history/CachedFrame.cpp \
     history/CachedPage.cpp \
     history/HistoryItem.cpp \
@@ -1354,6 +1354,7 @@ HEADERS += \
     editing/WrapContentsInDummySpanCommand.h \
     history/BackForwardController.h \
     history/BackForwardControllerClient.h \
+    history/BackForwardListImpl.h \
     history/BackForwardList.h \
     history/CachedFrame.h \
     history/CachedPage.h \
index 6a23781..0da7453 100644 (file)
                                >\r
                        </File>\r
                        <File\r
-                               RelativePath="..\history\BackForwardList.cpp"\r
+                               RelativePath="..\history\BackForwardList.h"\r
                                >\r
                        </File>\r
                        <File\r
-                               RelativePath="..\history\BackForwardList.h"\r
+                               RelativePath="..\history\BackForwardListImpl.cpp"\r
+                               >\r
+                       </File>\r
+                       <File\r
+                               RelativePath="..\history\BackForwardListImpl.h"\r
                                >\r
                        </File>\r
                        <File\r
index e1f8188..95a6660 100644 (file)
                51721FD311D27EF200638B42 /* JSBeforeProcessEvent.h in Headers */ = {isa = PBXBuildFile; fileRef = 51721FD111D27EF200638B42 /* JSBeforeProcessEvent.h */; };
                5172204B11D2960500638B42 /* BeforeProcessEvent.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 5172204A11D2960500638B42 /* BeforeProcessEvent.cpp */; };
                51741D0F0B07259A00ED442C /* BackForwardList.h in Headers */ = {isa = PBXBuildFile; fileRef = 51741D0B0B07259A00ED442C /* BackForwardList.h */; settings = {ATTRIBUTES = (Private, ); }; };
-               51741D100B07259A00ED442C /* BackForwardList.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 51741D0C0B07259A00ED442C /* BackForwardList.cpp */; };
                51741D110B07259A00ED442C /* HistoryItem.h in Headers */ = {isa = PBXBuildFile; fileRef = 51741D0D0B07259A00ED442C /* HistoryItem.h */; settings = {ATTRIBUTES = (Private, ); }; };
                51741D120B07259A00ED442C /* HistoryItem.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 51741D0E0B07259A00ED442C /* HistoryItem.cpp */; };
                5174E20A10A1F44F00F95E6F /* PopStateEvent.h in Headers */ = {isa = PBXBuildFile; fileRef = 5174E20810A1F44F00F95E6F /* PopStateEvent.h */; };
                BCA846D60DC67A350026C309 /* RenderReplica.cpp in Sources */ = {isa = PBXBuildFile; fileRef = BCA846D40DC67A350026C309 /* RenderReplica.cpp */; };
                BCA846D70DC67A350026C309 /* RenderReplica.h in Headers */ = {isa = PBXBuildFile; fileRef = BCA846D50DC67A350026C309 /* RenderReplica.h */; };
                BCA85A100C3AEAF4006F8308 /* DOMSVGNumberInternal.h in Headers */ = {isa = PBXBuildFile; fileRef = BCA85A0F0C3AEAF4006F8308 /* DOMSVGNumberInternal.h */; };
-               BCA8C81E11E3D36900812FB7 /* BackForwardController.h in Headers */ = {isa = PBXBuildFile; fileRef = BCA8C81C11E3D36900812FB7 /* BackForwardController.h */; };
+               BCA8C81E11E3D36900812FB7 /* BackForwardController.h in Headers */ = {isa = PBXBuildFile; fileRef = BCA8C81C11E3D36900812FB7 /* BackForwardController.h */; settings = {ATTRIBUTES = (Private, ); }; };
                BCA8C81F11E3D36900812FB7 /* BackForwardController.cpp in Sources */ = {isa = PBXBuildFile; fileRef = BCA8C81D11E3D36900812FB7 /* BackForwardController.cpp */; };
                BCA8C83111E3D53200812FB7 /* BackForwardControllerClient.h in Headers */ = {isa = PBXBuildFile; fileRef = BCA8C83011E3D53200812FB7 /* BackForwardControllerClient.h */; settings = {ATTRIBUTES = (Private, ); }; };
+               BCA8CA5F11E4E6D100812FB7 /* BackForwardListImpl.cpp in Sources */ = {isa = PBXBuildFile; fileRef = BCA8CA5D11E4E6D100812FB7 /* BackForwardListImpl.cpp */; };
+               BCA8CA6011E4E6D100812FB7 /* BackForwardListImpl.h in Headers */ = {isa = PBXBuildFile; fileRef = BCA8CA5E11E4E6D100812FB7 /* BackForwardListImpl.h */; settings = {ATTRIBUTES = (Private, ); }; };
                BCAA90C30A7EBA60008B1229 /* Scrollbar.cpp in Sources */ = {isa = PBXBuildFile; fileRef = BCAA90C20A7EBA60008B1229 /* Scrollbar.cpp */; };
                BCACF3BC1072921A00C0C8A3 /* UserContentURLPattern.cpp in Sources */ = {isa = PBXBuildFile; fileRef = BCACF3BA1072921A00C0C8A3 /* UserContentURLPattern.cpp */; };
                BCACF3BD1072921A00C0C8A3 /* UserContentURLPattern.h in Headers */ = {isa = PBXBuildFile; fileRef = BCACF3BB1072921A00C0C8A3 /* UserContentURLPattern.h */; settings = {ATTRIBUTES = (Private, ); }; };
                51721FD111D27EF200638B42 /* JSBeforeProcessEvent.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSBeforeProcessEvent.h; sourceTree = "<group>"; };
                5172204A11D2960500638B42 /* BeforeProcessEvent.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = BeforeProcessEvent.cpp; sourceTree = "<group>"; };
                51741D0B0B07259A00ED442C /* BackForwardList.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = BackForwardList.h; sourceTree = "<group>"; };
-               51741D0C0B07259A00ED442C /* BackForwardList.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = BackForwardList.cpp; sourceTree = "<group>"; };
                51741D0D0B07259A00ED442C /* HistoryItem.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = HistoryItem.h; sourceTree = "<group>"; };
                51741D0E0B07259A00ED442C /* HistoryItem.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; path = HistoryItem.cpp; sourceTree = "<group>"; };
                5174E20810A1F44F00F95E6F /* PopStateEvent.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PopStateEvent.h; sourceTree = "<group>"; };
                BCA8C81C11E3D36900812FB7 /* BackForwardController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = BackForwardController.h; sourceTree = "<group>"; };
                BCA8C81D11E3D36900812FB7 /* BackForwardController.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = BackForwardController.cpp; sourceTree = "<group>"; };
                BCA8C83011E3D53200812FB7 /* BackForwardControllerClient.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = BackForwardControllerClient.h; sourceTree = "<group>"; };
+               BCA8CA5D11E4E6D100812FB7 /* BackForwardListImpl.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = BackForwardListImpl.cpp; sourceTree = "<group>"; };
+               BCA8CA5E11E4E6D100812FB7 /* BackForwardListImpl.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = BackForwardListImpl.h; sourceTree = "<group>"; };
                BCAA90C20A7EBA60008B1229 /* Scrollbar.cpp */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.cpp.cpp; name = Scrollbar.cpp; path = platform/Scrollbar.cpp; sourceTree = SOURCE_ROOT; };
                BCACF3BA1072921A00C0C8A3 /* UserContentURLPattern.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = UserContentURLPattern.cpp; sourceTree = "<group>"; };
                BCACF3BB1072921A00C0C8A3 /* UserContentURLPattern.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UserContentURLPattern.h; sourceTree = "<group>"; };
                        children = (
                                9363B6290F8E8FE000803810 /* cf */,
                                5160F4920B0AA71500C1D2AF /* mac */,
-                               51741D0C0B07259A00ED442C /* BackForwardList.cpp */,
                                51741D0B0B07259A00ED442C /* BackForwardList.h */,
+                               BCA8CA5D11E4E6D100812FB7 /* BackForwardListImpl.cpp */,
+                               BCA8CA5E11E4E6D100812FB7 /* BackForwardListImpl.h */,
                                BCA8C81D11E3D36900812FB7 /* BackForwardController.cpp */,
                                BCA8C81C11E3D36900812FB7 /* BackForwardController.h */,
                                BCA8C83011E3D53200812FB7 /* BackForwardControllerClient.h */,
                                97EF561111E40783007E026F /* HTMLConstructionSite.h in Headers */,
                                BCA8C81E11E3D36900812FB7 /* BackForwardController.h in Headers */,
                                BCA8C83111E3D53200812FB7 /* BackForwardControllerClient.h in Headers */,
+                               BCA8CA6011E4E6D100812FB7 /* BackForwardListImpl.h in Headers */,
                        );
                        runOnlyForDeploymentPostprocessing = 0;
                };
                                A8CFF0500A154F09000A4234 /* AutoTableLayout.cpp in Sources */,
                                29A812370FBB9C1D00510293 /* AXObjectCache.cpp in Sources */,
                                29A8124B0FBB9CA900510293 /* AXObjectCacheMac.mm in Sources */,
-                               51741D100B07259A00ED442C /* BackForwardList.cpp in Sources */,
                                BC124EE70C2641CD009E2349 /* BarInfo.cpp in Sources */,
                                B2C3DA210D006C1D00EF6F26 /* Base64.cpp in Sources */,
                                5172204B11D2960500638B42 /* BeforeProcessEvent.cpp in Sources */,
                                BCA8C81F11E3D36900812FB7 /* BackForwardController.cpp in Sources */,
                                4F4F5FFB11CBD2E100A186BF /* RemoteInspectorFrontend2.cpp in Sources */,
                                97EF561011E40783007E026F /* HTMLConstructionSite.cpp in Sources */,
+                               BCA8CA5F11E4E6D100812FB7 /* BackForwardListImpl.cpp in Sources */,
                        );
                        runOnlyForDeploymentPostprocessing = 0;
                };
index c73e139..4f779c6 100644 (file)
@@ -28,6 +28,7 @@
 
 #include "BackForwardControllerClient.h"
 #include "BackForwardList.h"
+#include "BackForwardListImpl.h"
 
 namespace WebCore {
 
@@ -36,7 +37,7 @@ BackForwardController::BackForwardController(Page* page, BackForwardControllerCl
     , m_client(client)
 {
     if (!m_client)
-        m_list = BackForwardList::create(page);
+        m_list = BackForwardListImpl::create(page);
     else
         m_list = m_client->createBackForwardList();
 }
index 41aa65c..02c13a1 100644 (file)
@@ -32,6 +32,7 @@
 
 namespace WebCore {
 
+class Page;
 class BackForwardControllerClient;
 
 class BackForwardController : public Noncopyable {
index eb4921a..0813054 100644 (file)
 
 #include <wtf/RefCounted.h>
 #include <wtf/PassRefPtr.h>
-#include <wtf/HashSet.h>
 #include <wtf/Vector.h>
 
 namespace WebCore {
 
-class Document;
 class HistoryItem;
-class Page;
-class SerializedScriptValue;
-class String;
 
 typedef Vector<RefPtr<HistoryItem> > HistoryItemVector;
-typedef HashSet<RefPtr<HistoryItem> > HistoryItemHashSet;
 
 #if PLATFORM(CHROMIUM)
 // In the Chromium port, the back/forward list is managed externally.
@@ -62,65 +56,56 @@ public:
 
 class BackForwardList : public RefCounted<BackForwardList> {
 public: 
-    static PassRefPtr<BackForwardList> create(Page* page) { return adoptRef(new BackForwardList(page)); }
-    ~BackForwardList();
+    virtual ~BackForwardList()
+    {
+    }
+
+    virtual bool isBackForwardListImpl() const { return false; }
 
 #if PLATFORM(CHROMIUM)
     // Must be called before any other methods. 
-    void setClient(BackForwardListClient* client) { m_client = client; }
+    virtual void setClient(BackForwardListClient*) = 0;
 #endif
-    
-    Page* page() { return m_page; }
-    
-    void addItem(PassRefPtr<HistoryItem>);
-    void goBack();
-    void goForward();
-    void goToItem(HistoryItem*);
+
+    virtual void addItem(PassRefPtr<HistoryItem>) = 0;
+    virtual void goBack() = 0;
+    virtual void goForward() = 0;
+    virtual void goToItem(HistoryItem*) = 0;
         
-    HistoryItem* backItem();
-    HistoryItem* currentItem();
-    HistoryItem* forwardItem();
-    HistoryItem* itemAtIndex(int);
-
-    void backListWithLimit(int, HistoryItemVector&);
-    void forwardListWithLimit(int, HistoryItemVector&);
-
-    int capacity();
-    void setCapacity(int);
-    bool enabled();
-    void setEnabled(bool);
-    int backListCount();
-    int forwardListCount();
-    bool containsItem(HistoryItem*);
-
-    void close();
-    bool closed();
+    virtual HistoryItem* backItem() = 0;
+    virtual HistoryItem* currentItem() = 0;
+    virtual HistoryItem* forwardItem() = 0;
+    virtual HistoryItem* itemAtIndex(int) = 0;
+
+    virtual void backListWithLimit(int, HistoryItemVector&) = 0;
+    virtual void forwardListWithLimit(int, HistoryItemVector&) = 0;
+
+    virtual int capacity() = 0;
+    virtual void setCapacity(int) = 0;
+    virtual bool enabled() = 0;
+    virtual void setEnabled(bool) = 0;
+    virtual int backListCount() = 0;
+    virtual int forwardListCount() = 0;
+    virtual bool containsItem(HistoryItem*) = 0;
+
+    virtual void close() = 0;
+    virtual bool closed() = 0;
     
-    void removeItem(HistoryItem*);
-    HistoryItemVector& entries();
+    virtual void removeItem(HistoryItem*)  = 0;
+    virtual HistoryItemVector& entries()  = 0;
     
-    void pushStateItem(PassRefPtr<HistoryItem>);
+    virtual void pushStateItem(PassRefPtr<HistoryItem>) = 0;
 
 #if ENABLE(WML)
-    void clearWMLPageHistory();
+    virtual void clearWMLPageHistory()  = 0;
 #endif
 
-private:
-    BackForwardList(Page*);
-    
-    Page* m_page;
-#if PLATFORM(CHROMIUM) 
-    BackForwardListClient* m_client;
-#else
-    HistoryItemVector m_entries;
-    HistoryItemHashSet m_entryHash;
-    unsigned m_current;
-#endif
-    unsigned m_capacity;
-    bool m_closed;
-    bool m_enabled;
+protected:
+    BackForwardList()
+    {
+    }
 };
     
-} //namespace WebCore
+} // namespace WebCore
 
-#endif
+#endif // BackForwardList_h
index a780b7d..d4d390f 100644 (file)
@@ -26,7 +26,7 @@
  */
 
 #include "config.h"
-#include "BackForwardList.h"
+#include "BackForwardListImpl.h"
 
 #include "HistoryItem.h"
 #include "Logging.h"
@@ -36,7 +36,7 @@ namespace WebCore {
 static const unsigned DefaultCapacity = 100;
 static const unsigned NoCurrentItemIndex = UINT_MAX;
 
-BackForwardList::BackForwardList(Page* page)
+BackForwardListImpl::BackForwardListImpl(Page* page)
     : m_page(page)
     , m_client(0)
     , m_capacity(DefaultCapacity)
@@ -45,12 +45,12 @@ BackForwardList::BackForwardList(Page* page)
 {
 }
 
-BackForwardList::~BackForwardList()
+BackForwardListImpl::~BackForwardListImpl()
 {
     ASSERT(m_closed);
 }
 
-void BackForwardList::addItem(PassRefPtr<HistoryItem> prpItem)
+void BackForwardListImpl::addItem(PassRefPtr<HistoryItem> prpItem)
 {
     ASSERT(prpItem);
     if (m_capacity == 0 || !m_enabled)
@@ -59,44 +59,44 @@ void BackForwardList::addItem(PassRefPtr<HistoryItem> prpItem)
     m_client->addItem(prpItem);
 }
 
-void BackForwardList::goToItem(HistoryItem* item)
+void BackForwardListImpl::goToItem(HistoryItem* item)
 {
     m_client->goToItem(item);
 }
 
-HistoryItem* BackForwardList::backItem()
+HistoryItem* BackForwardListImpl::backItem()
 {
     ASSERT_NOT_REACHED();
     return 0;
 }
 
-HistoryItem* BackForwardList::forwardItem()
+HistoryItem* BackForwardListImpl::forwardItem()
 {
     ASSERT_NOT_REACHED();
     return 0;
 }
 
-HistoryItem* BackForwardList::currentItem()
+HistoryItem* BackForwardListImpl::currentItem()
 {
     return m_client->currentItem();
 }
 
-int BackForwardList::capacity()
+int BackForwardListImpl::capacity()
 {
     return m_capacity;
 }
 
-void BackForwardList::setCapacity(int size)
+void BackForwardListImpl::setCapacity(int size)
 {
     m_capacity = size;
 }
 
-bool BackForwardList::enabled()
+bool BackForwardListImpl::enabled()
 {
     return m_enabled;
 }
 
-void BackForwardList::setEnabled(bool enabled)
+void BackForwardListImpl::setEnabled(bool enabled)
 {
     m_enabled = enabled;
     if (!enabled) {
@@ -106,22 +106,22 @@ void BackForwardList::setEnabled(bool enabled)
     }
 }
 
-int BackForwardList::backListCount()
+int BackForwardListImpl::backListCount()
 {
     return m_client->backListCount();
 }
 
-int BackForwardList::forwardListCount()
+int BackForwardListImpl::forwardListCount()
 {
     return m_client->forwardListCount();
 }
 
-HistoryItem* BackForwardList::itemAtIndex(int index)
+HistoryItem* BackForwardListImpl::itemAtIndex(int index)
 {
     return m_client->itemAtIndex(index);
 }
 
-void BackForwardList::pushStateItem(PassRefPtr<HistoryItem> newItem)
+void BackForwardListImpl::pushStateItem(PassRefPtr<HistoryItem> newItem)
 {
     RefPtr<HistoryItem> current = m_client->currentItem();
 
@@ -131,13 +131,13 @@ void BackForwardList::pushStateItem(PassRefPtr<HistoryItem> newItem)
         current->setStateObject(SerializedScriptValue::create());
 }
 
-HistoryItemVector& BackForwardList::entries()
+HistoryItemVector& BackForwardListImpl::entries()
 {
     static HistoryItemVector noEntries;
     return noEntries;
 }
 
-void BackForwardList::close()
+void BackForwardListImpl::close()
 {
     if (m_client)
         m_client->close();
@@ -145,7 +145,7 @@ void BackForwardList::close()
     m_closed = true;
 }
 
-bool BackForwardList::closed()
+bool BackForwardListImpl::closed()
 {
     return m_closed;
 }
similarity index 85%
rename from WebCore/history/BackForwardList.cpp
rename to WebCore/history/BackForwardListImpl.cpp
index 656cce2..9da3cad 100644 (file)
@@ -25,7 +25,7 @@
  */
 
 #include "config.h"
-#include "BackForwardList.h"
+#include "BackForwardListImpl.h"
 
 #include "Frame.h"
 #include "FrameLoader.h"
@@ -43,7 +43,7 @@ namespace WebCore {
 static const unsigned DefaultCapacity = 100;
 static const unsigned NoCurrentItemIndex = UINT_MAX;
 
-BackForwardList::BackForwardList(Page* page)
+BackForwardListImpl::BackForwardListImpl(Page* page)
     : m_page(page)
     , m_current(NoCurrentItemIndex)
     , m_capacity(DefaultCapacity)
@@ -52,12 +52,12 @@ BackForwardList::BackForwardList(Page* page)
 {
 }
 
-BackForwardList::~BackForwardList()
+BackForwardListImpl::~BackForwardListImpl()
 {
     ASSERT(m_closed);
 }
 
-void BackForwardList::addItem(PassRefPtr<HistoryItem> prpItem)
+void BackForwardListImpl::addItem(PassRefPtr<HistoryItem> prpItem)
 {
     ASSERT(prpItem);
     if (m_capacity == 0 || !m_enabled)
@@ -93,7 +93,7 @@ void BackForwardList::addItem(PassRefPtr<HistoryItem> prpItem)
         m_page->mainFrame()->loader()->client()->dispatchDidAddBackForwardItem(currentItem());
 }
 
-void BackForwardList::goBack()
+void BackForwardListImpl::goBack()
 {
     ASSERT(m_current > 0);
     if (m_current > 0) {
@@ -103,7 +103,7 @@ void BackForwardList::goBack()
     }
 }
 
-void BackForwardList::goForward()
+void BackForwardListImpl::goForward()
 {
     ASSERT(m_current < m_entries.size() - 1);
     if (m_current < m_entries.size() - 1) {
@@ -113,7 +113,7 @@ void BackForwardList::goForward()
     }
 }
 
-void BackForwardList::goToItem(HistoryItem* item)
+void BackForwardListImpl::goToItem(HistoryItem* item)
 {
     if (!m_entries.size() || !item)
         return;
@@ -129,28 +129,28 @@ void BackForwardList::goToItem(HistoryItem* item)
     }
 }
 
-HistoryItem* BackForwardList::backItem()
+HistoryItem* BackForwardListImpl::backItem()
 {
     if (m_current && m_current != NoCurrentItemIndex)
         return m_entries[m_current - 1].get();
     return 0;
 }
 
-HistoryItem* BackForwardList::currentItem()
+HistoryItem* BackForwardListImpl::currentItem()
 {
     if (m_current != NoCurrentItemIndex)
         return m_entries[m_current].get();
     return 0;
 }
 
-HistoryItem* BackForwardList::forwardItem()
+HistoryItem* BackForwardListImpl::forwardItem()
 {
     if (m_entries.size() && m_current < m_entries.size() - 1)
         return m_entries[m_current + 1].get();
     return 0;
 }
 
-void BackForwardList::backListWithLimit(int limit, HistoryItemVector& list)
+void BackForwardListImpl::backListWithLimit(int limit, HistoryItemVector& list)
 {
     list.clear();
     if (m_current != NoCurrentItemIndex) {
@@ -160,7 +160,7 @@ void BackForwardList::backListWithLimit(int limit, HistoryItemVector& list)
     }
 }
 
-void BackForwardList::forwardListWithLimit(int limit, HistoryItemVector& list)
+void BackForwardListImpl::forwardListWithLimit(int limit, HistoryItemVector& list)
 {
     ASSERT(limit > -1);
     list.clear();
@@ -176,12 +176,12 @@ void BackForwardList::forwardListWithLimit(int limit, HistoryItemVector& list)
     }
 }
 
-int BackForwardList::capacity()
+int BackForwardListImpl::capacity()
 {
     return m_capacity;
 }
 
-void BackForwardList::setCapacity(int size)
+void BackForwardListImpl::setCapacity(int size)
 {    
     while (size < (int)m_entries.size()) {
         RefPtr<HistoryItem> item = m_entries.last();
@@ -200,12 +200,12 @@ void BackForwardList::setCapacity(int size)
     m_capacity = size;
 }
 
-bool BackForwardList::enabled()
+bool BackForwardListImpl::enabled()
 {
     return m_enabled;
 }
 
-void BackForwardList::setEnabled(bool enabled)
+void BackForwardListImpl::setEnabled(bool enabled)
 {
     m_enabled = enabled;
     if (!enabled) {
@@ -215,17 +215,17 @@ void BackForwardList::setEnabled(bool enabled)
     }
 }
 
-int BackForwardList::backListCount()
+int BackForwardListImpl::backListCount()
 {
     return m_current == NoCurrentItemIndex ? 0 : m_current;
 }
 
-int BackForwardList::forwardListCount()
+int BackForwardListImpl::forwardListCount()
 {
     return m_current == NoCurrentItemIndex ? 0 : (int)m_entries.size() - (m_current + 1);
 }
 
-HistoryItem* BackForwardList::itemAtIndex(int index)
+HistoryItem* BackForwardListImpl::itemAtIndex(int index)
 {
     // Do range checks without doing math on index to avoid overflow.
     if (index < -(int)m_current)
@@ -237,12 +237,12 @@ HistoryItem* BackForwardList::itemAtIndex(int index)
     return m_entries[index + m_current].get();
 }
 
-HistoryItemVector& BackForwardList::entries()
+HistoryItemVector& BackForwardListImpl::entries()
 {
     return m_entries;
 }
 
-void BackForwardList::pushStateItem(PassRefPtr<HistoryItem> newItem)
+void BackForwardListImpl::pushStateItem(PassRefPtr<HistoryItem> newItem)
 {
     ASSERT(newItem);
     ASSERT(newItem->stateObject());
@@ -256,7 +256,7 @@ void BackForwardList::pushStateItem(PassRefPtr<HistoryItem> newItem)
         current->setStateObject(SerializedScriptValue::create());
 }
 
-void BackForwardList::close()
+void BackForwardListImpl::close()
 {
     int size = m_entries.size();
     for (int i = 0; i < size; ++i)
@@ -267,12 +267,12 @@ void BackForwardList::close()
     m_closed = true;
 }
 
-bool BackForwardList::closed()
+bool BackForwardListImpl::closed()
 {
     return m_closed;
 }
 
-void BackForwardList::removeItem(HistoryItem* item)
+void BackForwardListImpl::removeItem(HistoryItem* item)
 {
     if (!item)
         return;
@@ -294,13 +294,13 @@ void BackForwardList::removeItem(HistoryItem* item)
         }
 }
 
-bool BackForwardList::containsItem(HistoryItem* entry)
+bool BackForwardListImpl::containsItem(HistoryItem* entry)
 {
     return m_entryHash.contains(entry);
 }
 
 #if ENABLE(WML)
-void BackForwardList::clearWMLPageHistory()
+void BackForwardListImpl::clearWMLPageHistory()
 {
     RefPtr<HistoryItem> currentItem = this->currentItem();
 
diff --git a/WebCore/history/BackForwardListImpl.h b/WebCore/history/BackForwardListImpl.h
new file mode 100644 (file)
index 0000000..86e1227
--- /dev/null
@@ -0,0 +1,107 @@
+/*
+ * Copyright (C) 2006 Apple Computer, Inc.  All rights reserved.
+ * Copyright (C) 2008 Torch Mobile Inc. All rights reserved. (http://www.torchmobile.com/)
+ * Copyright (C) 2009 Google, Inc. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY APPLE COMPUTER, INC. ``AS IS'' AND ANY
+ * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL APPLE COMPUTER, INC. OR
+ * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
+ * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+ * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
+ * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
+ * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 
+ */
+
+#ifndef BackForwardListImpl_h
+#define BackForwardListImpl_h
+
+#include "BackForwardList.h"
+#include <wtf/HashSet.h>
+
+namespace WebCore {
+
+class HistoryItem;
+class Page;
+
+typedef Vector<RefPtr<HistoryItem> > HistoryItemVector;
+typedef HashSet<RefPtr<HistoryItem> > HistoryItemHashSet;
+
+class BackForwardListImpl : public BackForwardList {
+public: 
+    static PassRefPtr<BackForwardListImpl> create(Page* page) { return adoptRef(new BackForwardListImpl(page)); }
+    ~BackForwardListImpl();
+
+    bool isBackForwardListImpl() const { return true; }
+
+#if PLATFORM(CHROMIUM)
+    // Must be called before any other methods. 
+    void setClient(BackForwardListClient* client) { m_client = client; }
+#endif
+    
+    Page* page() { return m_page; }
+    
+    void addItem(PassRefPtr<HistoryItem>);
+    void goBack();
+    void goForward();
+    void goToItem(HistoryItem*);
+        
+    HistoryItem* backItem();
+    HistoryItem* currentItem();
+    HistoryItem* forwardItem();
+    HistoryItem* itemAtIndex(int);
+
+    void backListWithLimit(int, HistoryItemVector&);
+    void forwardListWithLimit(int, HistoryItemVector&);
+
+    int capacity();
+    void setCapacity(int);
+    bool enabled();
+    void setEnabled(bool);
+    int backListCount();
+    int forwardListCount();
+    bool containsItem(HistoryItem*);
+
+    void close();
+    bool closed();
+    
+    void removeItem(HistoryItem*);
+    HistoryItemVector& entries();
+    
+    void pushStateItem(PassRefPtr<HistoryItem>);
+
+#if ENABLE(WML)
+    void clearWMLPageHistory();
+#endif
+
+private:
+    BackForwardListImpl(Page*);
+    
+    Page* m_page;
+#if PLATFORM(CHROMIUM) 
+    BackForwardListClient* m_client;
+#else
+    HistoryItemVector m_entries;
+    HistoryItemHashSet m_entryHash;
+    unsigned m_current;
+#endif
+    unsigned m_capacity;
+    bool m_closed;
+    bool m_enabled;
+};
+    
+} // namespace WebCore
+
+#endif // BackForwardListImpl_h
index 893c79b..65a7744 100644 (file)
@@ -1,3 +1,16 @@
+2010-07-08  Sam Weinig  <sam@webkit.org>
+
+        Reviewed by Anders Carlsson.
+
+        Patch for https://bugs.webkit.org/show_bug.cgi?id=41826
+        Convert BackForwardList to an abstract base class and add BackForwardListImpl
+        as the concrete implementation of it.
+
+        * History/WebBackForwardList.mm:
+        (-[WebBackForwardList init]):
+        (-[WebBackForwardList setPageCacheSize:]):
+        (-[WebBackForwardList pageCacheSize]):
+
 2010-07-07  Sam Weinig  <sam@webkit.org>
 
         Reviewed by Anders Carlsson.
index 6d9e998..617ee0e 100644 (file)
@@ -38,7 +38,7 @@
 #import "WebPreferencesPrivate.h"
 #import "WebTypesInternal.h"
 #import "WebViewPrivate.h"
-#import <WebCore/BackForwardList.h>
+#import <WebCore/BackForwardListImpl.h>
 #import <WebCore/HistoryItem.h>
 #import <WebCore/Page.h>
 #import <WebCore/PageCache.h>
@@ -109,7 +109,7 @@ WebBackForwardList *kit(BackForwardList* backForwardList)
 
 - (id)init
 {
-    return [self initWithBackForwardList:BackForwardList::create(0)];
+    return [self initWithBackForwardList:BackForwardListImpl::create(0)];
 }
 
 - (void)dealloc
@@ -293,12 +293,14 @@ static bool bumperCarBackForwardHackNeeded()
 
 - (void)setPageCacheSize:(NSUInteger)size
 {
-    [kit(core(self)->page()) setUsesPageCache:size != 0];
+    ASSERT(core(self)->isBackForwardListImpl());
+    [kit(static_cast<BackForwardListImpl*>(core(self))->page()) setUsesPageCache:size != 0];
 }
 
 - (NSUInteger)pageCacheSize
 {
-    return [kit(core(self)->page()) usesPageCache] ? pageCache()->capacity() : 0;
+    ASSERT(core(self)->isBackForwardListImpl());
+    return [kit(static_cast<BackForwardListImpl*>(core(self))->page()) usesPageCache] ? pageCache()->capacity() : 0;
 }
 
 - (int)backListCount
index a6f3d0c..55305c9 100644 (file)
@@ -22,6 +22,7 @@
 #include "qwebhistory_p.h"
 #include "qwebframe_p.h"
 
+#include "BackForwardListImpl.h"
 #include "PlatformString.h"
 #include "Image.h"
 #include "KURL.h"
@@ -259,7 +260,7 @@ void QWebHistory::clear()
     WebCore::BackForwardList* lst = d->lst;
 
     //clear visited links
-    WebCore::Page* page = lst->page();
+    WebCore::Page* page = static_cast<WebCore::BackForwardListImpl*>(lst)->page();
     if (page && page->groupPtr())
         page->groupPtr()->removeVisitedLinks();
 
@@ -363,7 +364,7 @@ bool QWebHistory::canGoForward() const
 void QWebHistory::back()
 {
     if (canGoBack()) {
-        WebCore::Page* page = d->lst->page();
+        WebCore::Page* page = static_cast<WebCore::BackForwardListImpl*>(d->lst)->page();
         page->goToItem(d->lst->backItem(), WebCore::FrameLoadTypeIndexedBackForward);
     }
 }
@@ -377,7 +378,7 @@ void QWebHistory::back()
 void QWebHistory::forward()
 {
     if (canGoForward()) {
-        WebCore::Page* page = d->lst->page();
+        WebCore::Page* page = static_cast<WebCore::BackForwardListImpl*>(d->lst)->page();
         page->goToItem(d->lst->forwardItem(), WebCore::FrameLoadTypeIndexedBackForward);
     }
 }
@@ -389,7 +390,7 @@ void QWebHistory::forward()
 */
 void QWebHistory::goToItem(const QWebHistoryItem &item)
 {
-    WebCore::Page* page = d->lst->page();
+    WebCore::Page* page = static_cast<WebCore::BackForwardListImpl*>(d->lst)->page();
     page->goToItem(item.d->item, WebCore::FrameLoadTypeIndexedBackForward);
 }
 
@@ -538,7 +539,7 @@ QDataStream& operator>>(QDataStream& source, QWebHistory& history)
             }
             d->lst->removeItem(nullItem);
             // Update the HistoryController.
-            history.d->lst->page()->mainFrame()->loader()->history()->setCurrentItem(history.d->lst->entries()[currentIndex].get());
+            static_cast<WebCore::BackForwardListImpl*>(history.d->lst)->page()->mainFrame()->loader()->history()->setCurrentItem(history.d->lst->entries()[currentIndex].get());
             history.goToItem(history.itemAt(currentIndex));
         }
     }
@@ -550,7 +551,7 @@ QDataStream& operator>>(QDataStream& source, QWebHistory& history)
 
 QWebPagePrivate* QWebHistoryPrivate::page()
 {
-    return QWebFramePrivate::kit(lst->page()->mainFrame())->page()->handle();
+    return QWebFramePrivate::kit(static_cast<WebCore::BackForwardListImpl*>(lst)->page()->mainFrame())->page()->handle();
 }
 
 WebCore::HistoryItem* QWebHistoryItemPrivate::core(QWebHistoryItem* q)
index 66539bc..6f8a0cf 100644 (file)
@@ -1,3 +1,19 @@
+2010-07-08  Sam Weinig  <sam@webkit.org>
+
+        Reviewed by Anders Carlsson.
+
+        Patch for https://bugs.webkit.org/show_bug.cgi?id=41826
+        Convert BackForwardList to an abstract base class and add BackForwardListImpl
+        as the concrete implementation of it.
+
+        * Api/qwebhistory.cpp:
+        (QWebHistory::clear):
+        (QWebHistory::back):
+        (QWebHistory::forward):
+        (QWebHistory::goToItem):
+        (operator>>):
+        (QWebHistoryPrivate::page):
+
 2010-07-08  Tor Arne Vestbø  <tor.arne.vestbo@nokia.com>
 
         Reviewed by Simon Hausmann.
index 32bb025..dd99d19 100644 (file)
@@ -1,3 +1,14 @@
+2010-07-08  Sam Weinig  <sam@webkit.org>
+
+        Reviewed by Anders Carlsson.
+
+        Patch for https://bugs.webkit.org/show_bug.cgi?id=41826
+        Convert BackForwardList to an abstract base class and add BackForwardListImpl
+        as the concrete implementation of it.
+
+        * WebProcess/WebCoreSupport/WebBackForwardControllerClient.cpp:
+        (WebKit::WebBackForwardControllerClient::createBackForwardList):
+
 2010-07-08  Luiz Agostini  <luiz@webkit.org>, Kenneth Rohde Christiansen <kenneth@webkit.org>
 
         Reviewed by Antti Koivisto.
index efc1a1d..e3d816d 100644 (file)
@@ -26,7 +26,7 @@
 #include "WebBackForwardControllerClient.h"
 
 #include "WebPage.h"
-#include <WebCore/BackForwardList.h>
+#include <WebCore/BackForwardListImpl.h>
 
 using namespace WebCore;
 
@@ -39,7 +39,7 @@ void WebBackForwardControllerClient::backForwardControllerDestroyed()
 
 PassRefPtr<BackForwardList> WebBackForwardControllerClient::createBackForwardList()
 {
-    return BackForwardList::create(m_page->corePage());
+    return BackForwardListImpl::create(m_page->corePage());
 }
 
 } // namespace WebKit