[Webkit-unassigned] [Bug 30037] Factor PageController out of FrameLoader and Page

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Sat Oct 3 08:21:49 PDT 2009


--- Comment #6 from Adam Barth <abarth at webkit.org>  2009-10-03 08:21:49 PDT ---
My main goal for this patch is to remove these methods from FrameLoader because
they have nothing to do with FrameLoader:

-        bool canGoBackOrForward(int distance) const;
-        void goBackOrForward(int distance);
-        int getHistoryLength();

They ought to be methods of some page-scoped object.  Looking around, they seem
related to these methods of Page:

-        bool goBack();
-        bool goForward();
-        void goToItem(HistoryItem*, FrameLoadType);

I was going to add them to the Page object, but I saw this comment:

-        // FIXME: The following three methods don't fall under the
responsibilities of the Page object
-        // They seem to fit a hypothetical Page-controller object that would
be akin to the 
-        // Frame-FrameLoader relationship.  They have to live here now, but
should move somewhere that
-        // makes more sense when that class exists.

I didn't want to add to the problem described by this comment, so I created the
hypothetical Page-controller object.  If you'd prefer we just moved the methods
from FrameLoader to Page, I'd be happy to do that (and it would make the patch
MUCH smaller).  We can sort out whether to create the hypothetical
Page-controller object later.

Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

More information about the webkit-unassigned mailing list