Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(61)

Side by Side Diff: third_party/WebKit/Source/web/RemoteFrameOwner.h

Issue 2331223002: Added allowvr attribute to iframes and vrEnabled to Document (Closed)
Patch Set: Rebase and moved vrEnabled from navigator to document Created 4 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be found 2 // Use of this source code is governed by a BSD-style license that can be found
3 // in the LICENSE file. 3 // in the LICENSE file.
4 4
5 #ifndef RemoteFrameOwner_h 5 #ifndef RemoteFrameOwner_h
6 #define RemoteFrameOwner_h 6 #define RemoteFrameOwner_h
7 7
8 #include "core/frame/FrameOwner.h" 8 #include "core/frame/FrameOwner.h"
9 #include "platform/scroll/ScrollTypes.h" 9 #include "platform/scroll/ScrollTypes.h"
10 #include "public/web/WebFrameOwnerProperties.h" 10 #include "public/web/WebFrameOwnerProperties.h"
(...skipping 18 matching lines...) Expand all
29 void clearContentFrame() override; 29 void clearContentFrame() override;
30 SandboxFlags getSandboxFlags() const override { return m_sandboxFlags; } 30 SandboxFlags getSandboxFlags() const override { return m_sandboxFlags; }
31 void setSandboxFlags(SandboxFlags flags) { m_sandboxFlags = flags; } 31 void setSandboxFlags(SandboxFlags flags) { m_sandboxFlags = flags; }
32 void dispatchLoad() override; 32 void dispatchLoad() override;
33 // TODO(dcheng): Implement. 33 // TODO(dcheng): Implement.
34 void renderFallbackContent() override { } 34 void renderFallbackContent() override { }
35 ScrollbarMode scrollingMode() const override { return m_scrolling; } 35 ScrollbarMode scrollingMode() const override { return m_scrolling; }
36 int marginWidth() const override { return m_marginWidth; } 36 int marginWidth() const override { return m_marginWidth; }
37 int marginHeight() const override { return m_marginHeight; } 37 int marginHeight() const override { return m_marginHeight; }
38 bool allowFullscreen() const override { return m_allowFullscreen; } 38 bool allowFullscreen() const override { return m_allowFullscreen; }
39 bool allowVR() const override { return m_allowVR; }
39 const WebVector<WebPermissionType>& delegatedPermissions() const override { return m_delegatedPermissions; } 40 const WebVector<WebPermissionType>& delegatedPermissions() const override { return m_delegatedPermissions; }
40 41
41 void setScrollingMode(WebFrameOwnerProperties::ScrollingMode); 42 void setScrollingMode(WebFrameOwnerProperties::ScrollingMode);
42 void setMarginWidth(int marginWidth) { m_marginWidth = marginWidth; } 43 void setMarginWidth(int marginWidth) { m_marginWidth = marginWidth; }
43 void setMarginHeight(int marginHeight) { m_marginHeight = marginHeight; } 44 void setMarginHeight(int marginHeight) { m_marginHeight = marginHeight; }
44 void setAllowFullscreen(bool allowFullscreen) { m_allowFullscreen = allowFul lscreen; } 45 void setAllowFullscreen(bool allowFullscreen) { m_allowFullscreen = allowFul lscreen; }
46 void setAllowVR(bool allowVR) { m_allowVR = allowVR; }
45 void setDelegatedpermissions(const WebVector<WebPermissionType>& delegatedPe rmissions) { m_delegatedPermissions = delegatedPermissions; } 47 void setDelegatedpermissions(const WebVector<WebPermissionType>& delegatedPe rmissions) { m_delegatedPermissions = delegatedPermissions; }
46 48
47 DECLARE_VIRTUAL_TRACE(); 49 DECLARE_VIRTUAL_TRACE();
48 50
49 private: 51 private:
50 RemoteFrameOwner(SandboxFlags, const WebFrameOwnerProperties&); 52 RemoteFrameOwner(SandboxFlags, const WebFrameOwnerProperties&);
51 53
52 // Intentionally private to prevent redundant checks when the type is 54 // Intentionally private to prevent redundant checks when the type is
53 // already HTMLFrameOwnerElement. 55 // already HTMLFrameOwnerElement.
54 bool isLocal() const override { return false; } 56 bool isLocal() const override { return false; }
55 bool isRemote() const override { return true; } 57 bool isRemote() const override { return true; }
56 58
57 Member<Frame> m_frame; 59 Member<Frame> m_frame;
58 SandboxFlags m_sandboxFlags; 60 SandboxFlags m_sandboxFlags;
59 ScrollbarMode m_scrolling; 61 ScrollbarMode m_scrolling;
60 int m_marginWidth; 62 int m_marginWidth;
61 int m_marginHeight; 63 int m_marginHeight;
62 bool m_allowFullscreen; 64 bool m_allowFullscreen;
65 bool m_allowVR;
63 WebVector<WebPermissionType> m_delegatedPermissions; 66 WebVector<WebPermissionType> m_delegatedPermissions;
64 }; 67 };
65 68
66 DEFINE_TYPE_CASTS(RemoteFrameOwner, FrameOwner, owner, owner->isRemote(), owner. isRemote()); 69 DEFINE_TYPE_CASTS(RemoteFrameOwner, FrameOwner, owner, owner->isRemote(), owner. isRemote());
67 70
68 } // namespace blink 71 } // namespace blink
69 72
70 #endif // RemoteFrameOwner_h 73 #endif // RemoteFrameOwner_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698