Oilpan: fix build after r202625.
[chromium-blink-merge.git] / third_party / WebKit / Source / core / frame / RemoteFrame.h
blobc12ec4b6011cd4b0a9087b7900d2de507aadd483
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
3 // found in the LICENSE file.
5 #ifndef RemoteFrame_h
6 #define RemoteFrame_h
8 #include "core/CoreExport.h"
9 #include "core/dom/RemoteSecurityContext.h"
10 #include "core/frame/Frame.h"
12 namespace blink {
14 class Event;
15 class IntRect;
16 class RemoteDOMWindow;
17 class RemoteFrameClient;
18 class RemoteFrameView;
19 class WebLayer;
20 class WindowProxyManager;
21 struct FrameLoadRequest;
23 class CORE_EXPORT RemoteFrame: public Frame {
24 public:
25 static PassRefPtrWillBeRawPtr<RemoteFrame> create(RemoteFrameClient*, FrameHost*, FrameOwner*);
27 ~RemoteFrame() override;
29 // Frame overrides:
30 DECLARE_VIRTUAL_TRACE();
31 bool isRemoteFrame() const override { return true; }
32 DOMWindow* domWindow() const override;
33 WindowProxy* windowProxy(DOMWrapperWorld&) override;
34 void navigate(Document& originDocument, const KURL&, bool replaceCurrentItem, UserGestureStatus) override;
35 void navigate(const FrameLoadRequest& passedRequest) override;
36 void reload(FrameLoadType, ClientRedirectPolicy) override;
37 void detach(FrameDetachType) override;
38 RemoteSecurityContext* securityContext() const override;
39 void printNavigationErrorMessage(const Frame&, const char* reason) override { }
40 void disconnectOwnerElement() override;
41 bool prepareForCommit() override;
42 bool shouldClose() override;
44 // FIXME: Remove this method once we have input routing in the browser
45 // process. See http://crbug.com/339659.
46 void forwardInputEvent(Event*);
48 void frameRectsChanged(const IntRect& frameRect);
50 void setRemotePlatformLayer(WebLayer*);
51 WebLayer* remotePlatformLayer() const { return m_remotePlatformLayer; }
53 void setView(PassRefPtrWillBeRawPtr<RemoteFrameView>);
54 void createView();
56 RemoteFrameView* view() const;
58 private:
59 RemoteFrame(RemoteFrameClient*, FrameHost*, FrameOwner*);
61 // Internal Frame helper overrides:
62 WindowProxyManager* windowProxyManager() const override { return m_windowProxyManager.get(); }
64 RemoteFrameClient* remoteFrameClient() const;
66 RefPtrWillBeMember<RemoteFrameView> m_view;
67 RefPtrWillBeMember<RemoteSecurityContext> m_securityContext;
68 RefPtrWillBeMember<RemoteDOMWindow> m_domWindow;
69 OwnPtrWillBeMember<WindowProxyManager> m_windowProxyManager;
70 WebLayer* m_remotePlatformLayer;
73 inline RemoteFrameView* RemoteFrame::view() const
75 return m_view.get();
78 DEFINE_TYPE_CASTS(RemoteFrame, Frame, remoteFrame, remoteFrame->isRemoteFrame(), remoteFrame.isRemoteFrame());
80 } // namespace blink
82 #endif // RemoteFrame_h