OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "config.h" | 5 #include "config.h" |
6 #include "core/frame/RemoteFrame.h" | 6 #include "core/frame/RemoteFrame.h" |
7 | 7 |
8 #include "core/dom/RemoteSecurityContext.h" | 8 #include "core/dom/RemoteSecurityContext.h" |
9 #include "core/frame/RemoteDOMWindow.h" | 9 #include "core/frame/RemoteDOMWindow.h" |
10 #include "core/frame/RemoteFrameClient.h" | 10 #include "core/frame/RemoteFrameClient.h" |
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
63 if (!client()) | 63 if (!client()) |
64 return; | 64 return; |
65 Frame::detach(); | 65 Frame::detach(); |
66 } | 66 } |
67 | 67 |
68 RemoteSecurityContext* RemoteFrame::securityContext() const | 68 RemoteSecurityContext* RemoteFrame::securityContext() const |
69 { | 69 { |
70 return m_securityContext.get(); | 70 return m_securityContext.get(); |
71 } | 71 } |
72 | 72 |
73 bool RemoteFrame::checkLoadComplete() | |
74 { | |
75 if (isLoading()) | |
76 return false; | |
77 | |
78 bool allChildrenAreDoneLoading = true; | |
79 for (RefPtrWillBeRawPtr<Frame> child = tree().firstChild(); child; child = c
hild->tree().nextSibling()) { | |
80 allChildrenAreDoneLoading &= child->checkLoadComplete(); | |
81 } | |
82 return allChildrenAreDoneLoading; | |
83 } | |
84 | |
85 void RemoteFrame::forwardInputEvent(Event* event) | 73 void RemoteFrame::forwardInputEvent(Event* event) |
86 { | 74 { |
87 remoteFrameClient()->forwardInputEvent(event); | 75 remoteFrameClient()->forwardInputEvent(event); |
88 } | 76 } |
89 | 77 |
90 void RemoteFrame::setView(PassRefPtrWillBeRawPtr<RemoteFrameView> view) | 78 void RemoteFrame::setView(PassRefPtrWillBeRawPtr<RemoteFrameView> view) |
91 { | 79 { |
92 // Oilpan: as RemoteFrameView performs no finalization actions, | 80 // Oilpan: as RemoteFrameView performs no finalization actions, |
93 // no explicit dispose() of it needed here. (cf. FrameView::dispose().) | 81 // no explicit dispose() of it needed here. (cf. FrameView::dispose().) |
94 m_view = view; | 82 m_view = view; |
(...skipping 10 matching lines...) Expand all Loading... |
105 owner->setWidget(view); | 93 owner->setWidget(view); |
106 } | 94 } |
107 } | 95 } |
108 | 96 |
109 RemoteFrameClient* RemoteFrame::remoteFrameClient() const | 97 RemoteFrameClient* RemoteFrame::remoteFrameClient() const |
110 { | 98 { |
111 return static_cast<RemoteFrameClient*>(client()); | 99 return static_cast<RemoteFrameClient*>(client()); |
112 } | 100 } |
113 | 101 |
114 } // namespace blink | 102 } // namespace blink |
OLD | NEW |