| Index: third_party/WebKit/Source/core/frame/FrameHost.cpp
|
| diff --git a/third_party/WebKit/Source/core/frame/FrameHost.cpp b/third_party/WebKit/Source/core/frame/FrameHost.cpp
|
| index 0af55d145c6eb85a58708021cf7115b0a1342ecd..b20120f8ee6e470dd54526db7ff27fa21dff4b38 100644
|
| --- a/third_party/WebKit/Source/core/frame/FrameHost.cpp
|
| +++ b/third_party/WebKit/Source/core/frame/FrameHost.cpp
|
| @@ -55,8 +55,7 @@ FrameHost::FrameHost(Page& page)
|
| m_eventHandlerRegistry(new EventHandlerRegistry(page)),
|
| m_consoleMessageStorage(new ConsoleMessageStorage()),
|
| m_globalRootScrollerController(
|
| - TopDocumentRootScrollerController::create(*this)),
|
| - m_subframeCount(0) {}
|
| + TopDocumentRootScrollerController::create(*this)) {}
|
|
|
| // Explicitly in the .cpp to avoid default constructor in .h
|
| FrameHost::~FrameHost() {}
|
| @@ -123,23 +122,16 @@ DEFINE_TRACE(FrameHost) {
|
| visitor->trace(m_globalRootScrollerController);
|
| }
|
|
|
| -#if DCHECK_IS_ON()
|
| -void checkFrameCountConsistency(int expectedFrameCount, Frame* frame) {
|
| - ASSERT(expectedFrameCount >= 0);
|
| -
|
| - int actualFrameCount = 0;
|
| - for (; frame; frame = frame->tree().traverseNext())
|
| - ++actualFrameCount;
|
| +void FrameHost::incrementSubframeCount() {
|
| + page().incrementSubframeCount();
|
| +}
|
|
|
| - ASSERT(expectedFrameCount == actualFrameCount);
|
| +void FrameHost::decrementSubframeCount() {
|
| + page().decrementSubframeCount();
|
| }
|
| -#endif
|
|
|
| int FrameHost::subframeCount() const {
|
| -#if DCHECK_IS_ON()
|
| - checkFrameCountConsistency(m_subframeCount + 1, m_page->mainFrame());
|
| -#endif
|
| - return m_subframeCount;
|
| + return page().subframeCount();
|
| }
|
|
|
| } // namespace blink
|
|
|