Title: [154571] trunk/Source/WebCore
- Revision
- 154571
- Author
- [email protected]
- Date
- 2013-08-25 02:33:29 -0700 (Sun, 25 Aug 2013)
Log Message
No need for clearTimers function in Frame
https://bugs.webkit.org/show_bug.cgi?id=120265
Reviewed by Andreas Kling.
* history/CachedFrame.cpp:
(WebCore::clearTimers): Added. Moved here from Frame.
(WebCore::CachedFrame::CachedFrame): Call above function.
(WebCore::CachedFrame::destroy): Ditto.
* page/Frame.cpp: Removed the two clearTimers functions.
* page/Frame.h: Ditto.
Modified Paths
Diff
Modified: trunk/Source/WebCore/ChangeLog (154570 => 154571)
--- trunk/Source/WebCore/ChangeLog 2013-08-25 09:27:30 UTC (rev 154570)
+++ trunk/Source/WebCore/ChangeLog 2013-08-25 09:33:29 UTC (rev 154571)
@@ -1,3 +1,18 @@
+2013-08-25 Darin Adler <[email protected]>
+
+ No need for clearTimers function in Frame
+ https://bugs.webkit.org/show_bug.cgi?id=120265
+
+ Reviewed by Andreas Kling.
+
+ * history/CachedFrame.cpp:
+ (WebCore::clearTimers): Added. Moved here from Frame.
+ (WebCore::CachedFrame::CachedFrame): Call above function.
+ (WebCore::CachedFrame::destroy): Ditto.
+
+ * page/Frame.cpp: Removed the two clearTimers functions.
+ * page/Frame.h: Ditto.
+
2013-08-24 Ryuan Choi <[email protected]>
Unreviewed build fix after r154560
Modified: trunk/Source/WebCore/history/CachedFrame.cpp (154570 => 154571)
--- trunk/Source/WebCore/history/CachedFrame.cpp 2013-08-25 09:27:30 UTC (rev 154570)
+++ trunk/Source/WebCore/history/CachedFrame.cpp 2013-08-25 09:33:29 UTC (rev 154571)
@@ -149,6 +149,13 @@
m_document->documentDidResumeFromPageCache();
}
+static void clearTimers(FrameView& view, Document& document)
+{
+ view.unscheduleRelayout();
+ view.frame().animation().suspendAnimationsForDocument(&document);
+ view.frame().eventHandler().stopAutoscrollTimer();
+}
+
CachedFrame::CachedFrame(Frame* frame)
: CachedFrameBase(frame)
{
@@ -191,7 +198,7 @@
#endif
// documentWillSuspendForPageCache() can set up a layout timer on the FrameView, so clear timers after that.
- frame->clearTimers();
+ clearTimers(*m_view, *m_document);
// Deconstruct the FrameTree, to restore it later.
// We do this for two reasons:
@@ -271,7 +278,7 @@
if (m_cachedFramePlatformData)
m_cachedFramePlatformData->clear();
- Frame::clearTimers(m_view.get(), m_document.get());
+ clearTimers(*m_view, *m_document);
// FIXME: Why do we need to call removeAllEventListeners here? When the document is in page cache, this method won't work
// fully anyway, because the document won't be able to access its DOMWindow object (due to being frameless).
Modified: trunk/Source/WebCore/page/Frame.cpp (154570 => 154571)
--- trunk/Source/WebCore/page/Frame.cpp 2013-08-25 09:27:30 UTC (rev 154570)
+++ trunk/Source/WebCore/page/Frame.cpp 2013-08-25 09:33:29 UTC (rev 154571)
@@ -614,20 +614,6 @@
return &toFrameView(widget)->frame();
}
-void Frame::clearTimers(FrameView *view, Document *document)
-{
- if (view) {
- view->unscheduleRelayout();
- view->frame().animation().suspendAnimationsForDocument(document);
- view->frame().eventHandler().stopAutoscrollTimer();
- }
-}
-
-void Frame::clearTimers()
-{
- clearTimers(m_view.get(), document());
-}
-
#if ENABLE(PAGE_VISIBILITY_API)
void Frame::dispatchVisibilityStateChangeEvent()
{
Modified: trunk/Source/WebCore/page/Frame.h (154570 => 154571)
--- trunk/Source/WebCore/page/Frame.h 2013-08-25 09:27:30 UTC (rev 154570)
+++ trunk/Source/WebCore/page/Frame.h 2013-08-25 09:33:29 UTC (rev 154571)
@@ -169,9 +169,6 @@
int orientation() const { return m_orientation; }
#endif
- void clearTimers();
- static void clearTimers(FrameView*, Document*);
-
String documentTypeString() const;
String displayStringModifiedByEncoding(const String&) const;
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes