| 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 "public/platform/WebString.h" | 8 #include "public/platform/WebString.h" |
| 9 #include "public/platform/WebVector.h" | 9 #include "public/platform/WebVector.h" |
| 10 #include "public/platform/modules/permissions/WebPermissionType.h" | 10 #include "public/platform/modules/permissions/WebPermissionType.h" |
| 11 #include <algorithm> | 11 #include <algorithm> |
| 12 | 12 |
| 13 namespace blink { | 13 namespace blink { |
| 14 | 14 |
| 15 struct WebFrameOwnerProperties { | 15 struct WebFrameOwnerProperties { |
| 16 enum class ScrollingMode { Auto, AlwaysOff, AlwaysOn, Last = AlwaysOn }; | 16 enum class ScrollingMode { Auto, AlwaysOff, AlwaysOn, Last = AlwaysOn }; |
| 17 | 17 |
| 18 ScrollingMode scrollingMode; | 18 ScrollingMode scrollingMode; |
| 19 int marginWidth; | 19 int marginWidth; |
| 20 int marginHeight; | 20 int marginHeight; |
| 21 bool allowFullscreen; | 21 bool allowFullscreen; |
| 22 bool allowPaymentRequest; |
| 22 WebString requiredCsp; | 23 WebString requiredCsp; |
| 23 WebVector<WebPermissionType> delegatedPermissions; | 24 WebVector<WebPermissionType> delegatedPermissions; |
| 24 | 25 |
| 25 WebFrameOwnerProperties() | 26 WebFrameOwnerProperties() |
| 26 : scrollingMode(ScrollingMode::Auto), | 27 : scrollingMode(ScrollingMode::Auto), |
| 27 marginWidth(-1), | 28 marginWidth(-1), |
| 28 marginHeight(-1), | 29 marginHeight(-1), |
| 29 allowFullscreen(false) {} | 30 allowFullscreen(false), |
| 31 allowPaymentRequest(false) {} |
| 30 | 32 |
| 31 #if INSIDE_BLINK | 33 #if INSIDE_BLINK |
| 32 WebFrameOwnerProperties( | 34 WebFrameOwnerProperties( |
| 33 ScrollbarMode scrollingMode, | 35 ScrollbarMode scrollingMode, |
| 34 int marginWidth, | 36 int marginWidth, |
| 35 int marginHeight, | 37 int marginHeight, |
| 36 bool allowFullscreen, | 38 bool allowFullscreen, |
| 39 bool allowPaymentRequest, |
| 37 const WebString& requiredCsp, | 40 const WebString& requiredCsp, |
| 38 const WebVector<WebPermissionType>& delegatedPermissions) | 41 const WebVector<WebPermissionType>& delegatedPermissions) |
| 39 : scrollingMode(static_cast<ScrollingMode>(scrollingMode)), | 42 : scrollingMode(static_cast<ScrollingMode>(scrollingMode)), |
| 40 marginWidth(marginWidth), | 43 marginWidth(marginWidth), |
| 41 marginHeight(marginHeight), | 44 marginHeight(marginHeight), |
| 42 allowFullscreen(allowFullscreen), | 45 allowFullscreen(allowFullscreen), |
| 46 allowPaymentRequest(allowPaymentRequest), |
| 43 requiredCsp(requiredCsp), | 47 requiredCsp(requiredCsp), |
| 44 delegatedPermissions(delegatedPermissions) {} | 48 delegatedPermissions(delegatedPermissions) {} |
| 45 #endif | 49 #endif |
| 46 }; | 50 }; |
| 47 | 51 |
| 48 } // namespace blink | 52 } // namespace blink |
| 49 | 53 |
| 50 #endif | 54 #endif |
| OLD | NEW |