OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 Google Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
6 * met: | 6 * met: |
7 * | 7 * |
8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
46 } | 46 } |
47 | 47 |
48 FrameHost::FrameHost(Page& page) | 48 FrameHost::FrameHost(Page& page) |
49 : m_page(&page), | 49 : m_page(&page), |
50 m_visualViewport(VisualViewport::create(*this)), | 50 m_visualViewport(VisualViewport::create(*this)), |
51 m_overscrollController( | 51 m_overscrollController( |
52 OverscrollController::create(*m_visualViewport, | 52 OverscrollController::create(*m_visualViewport, |
53 m_page->chromeClient())), | 53 m_page->chromeClient())), |
54 m_consoleMessageStorage(new ConsoleMessageStorage()), | 54 m_consoleMessageStorage(new ConsoleMessageStorage()), |
55 m_globalRootScrollerController( | 55 m_globalRootScrollerController( |
56 TopDocumentRootScrollerController::create(*this)), | 56 TopDocumentRootScrollerController::create(page)), |
57 m_subframeCount(0) {} | 57 m_subframeCount(0) {} |
58 | 58 |
59 // Explicitly in the .cpp to avoid default constructor in .h | 59 // Explicitly in the .cpp to avoid default constructor in .h |
60 FrameHost::~FrameHost() {} | 60 FrameHost::~FrameHost() {} |
61 | 61 |
62 Page& FrameHost::page() { | 62 Page& FrameHost::page() { |
63 return *m_page; | 63 return *m_page; |
64 } | 64 } |
65 | 65 |
66 const Page& FrameHost::page() const { | 66 const Page& FrameHost::page() const { |
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
133 #endif | 133 #endif |
134 | 134 |
135 int FrameHost::subframeCount() const { | 135 int FrameHost::subframeCount() const { |
136 #if DCHECK_IS_ON() | 136 #if DCHECK_IS_ON() |
137 checkFrameCountConsistency(m_subframeCount + 1, m_page->mainFrame()); | 137 checkFrameCountConsistency(m_subframeCount + 1, m_page->mainFrame()); |
138 #endif | 138 #endif |
139 return m_subframeCount; | 139 return m_subframeCount; |
140 } | 140 } |
141 | 141 |
142 } // namespace blink | 142 } // namespace blink |
OLD | NEW |