OLD | NEW |
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 | 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 #ifndef WebFrameOwnerProperties_h | 5 #ifndef WebFrameOwnerProperties_h |
6 #define WebFrameOwnerProperties_h | 6 #define WebFrameOwnerProperties_h |
7 | 7 |
8 #include "../platform/WebFeaturePolicy.h" | 8 #include "../platform/WebFeaturePolicy.h" |
9 #include "../platform/WebString.h" | 9 #include "../platform/WebString.h" |
10 #include "../platform/WebVector.h" | 10 #include "../platform/WebVector.h" |
11 | 11 |
12 #include <algorithm> | 12 #include <algorithm> |
13 | 13 |
14 namespace blink { | 14 namespace blink { |
15 | 15 |
16 struct WebFrameOwnerProperties { | 16 struct WebFrameOwnerProperties { |
17 enum class ScrollingMode { Auto, AlwaysOff, AlwaysOn, Last = AlwaysOn }; | 17 enum class ScrollingMode { Auto, AlwaysOff, AlwaysOn, Last = AlwaysOn }; |
18 | 18 |
19 WebString name; // browsing context container's name | 19 WebString name; // browsing context container's name |
20 ScrollingMode scrollingMode; | 20 ScrollingMode scrollingMode; |
21 int marginWidth; | 21 int marginWidth; |
22 int marginHeight; | 22 int marginHeight; |
23 bool allowFullscreen; | 23 bool allowFullscreen; |
24 bool allowPaymentRequest; | 24 bool allowPaymentRequest; |
| 25 bool isDisplayNone; |
25 WebString requiredCsp; | 26 WebString requiredCsp; |
26 | 27 |
27 public: | 28 public: |
28 WebVector<WebFeaturePolicyFeature> allowedFeatures; | 29 WebVector<WebFeaturePolicyFeature> allowedFeatures; |
29 | 30 |
30 WebFrameOwnerProperties() | 31 WebFrameOwnerProperties() |
31 : scrollingMode(ScrollingMode::Auto), | 32 : scrollingMode(ScrollingMode::Auto), |
32 marginWidth(-1), | 33 marginWidth(-1), |
33 marginHeight(-1), | 34 marginHeight(-1), |
34 allowFullscreen(false), | 35 allowFullscreen(false), |
35 allowPaymentRequest(false) {} | 36 allowPaymentRequest(false), |
| 37 isDisplayNone(false) {} |
36 | 38 |
37 #if INSIDE_BLINK | 39 #if INSIDE_BLINK |
38 WebFrameOwnerProperties( | 40 WebFrameOwnerProperties( |
39 const WebString& name, | 41 const WebString& name, |
40 ScrollbarMode scrollingMode, | 42 ScrollbarMode scrollingMode, |
41 int marginWidth, | 43 int marginWidth, |
42 int marginHeight, | 44 int marginHeight, |
43 bool allowFullscreen, | 45 bool allowFullscreen, |
44 bool allowPaymentRequest, | 46 bool allowPaymentRequest, |
| 47 bool isDisplayNone, |
45 const WebString& requiredCsp, | 48 const WebString& requiredCsp, |
46 const WebVector<WebFeaturePolicyFeature>& allowedFeatures) | 49 const WebVector<WebFeaturePolicyFeature>& allowedFeatures) |
47 : name(name), | 50 : name(name), |
48 scrollingMode(static_cast<ScrollingMode>(scrollingMode)), | 51 scrollingMode(static_cast<ScrollingMode>(scrollingMode)), |
49 marginWidth(marginWidth), | 52 marginWidth(marginWidth), |
50 marginHeight(marginHeight), | 53 marginHeight(marginHeight), |
51 allowFullscreen(allowFullscreen), | 54 allowFullscreen(allowFullscreen), |
52 allowPaymentRequest(allowPaymentRequest), | 55 allowPaymentRequest(allowPaymentRequest), |
| 56 isDisplayNone(isDisplayNone), |
53 requiredCsp(requiredCsp), | 57 requiredCsp(requiredCsp), |
54 allowedFeatures(allowedFeatures) {} | 58 allowedFeatures(allowedFeatures) {} |
55 #endif | 59 #endif |
56 }; | 60 }; |
57 | 61 |
58 } // namespace blink | 62 } // namespace blink |
59 | 63 |
60 #endif | 64 #endif |
OLD | NEW |