| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2012 Intel Corporation. All rights reserved. | 2 * Copyright (C) 2012 Intel Corporation. All rights reserved. |
| 3 * Copyright (C) 2012 Apple Inc. All rights reserved. | 3 * Copyright (C) 2012 Apple Inc. All rights reserved. |
| 4 * | 4 * |
| 5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
| 6 * modification, are permitted provided that the following conditions | 6 * modification, are permitted provided that the following conditions |
| 7 * are met: | 7 * are met: |
| 8 * | 8 * |
| 9 * 1. Redistributions of source code must retain the above | 9 * 1. Redistributions of source code must retain the above |
| 10 * copyright notice, this list of conditions and the following | 10 * copyright notice, this list of conditions and the following |
| (...skipping 10 matching lines...) Expand all Loading... |
| 21 * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, | 21 * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, |
| 22 * OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, | 22 * OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, |
| 23 * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR | 23 * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR |
| 24 * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY | 24 * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY |
| 25 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR | 25 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR |
| 26 * TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF | 26 * TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF |
| 27 * THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF | 27 * THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF |
| 28 * SUCH DAMAGE. | 28 * SUCH DAMAGE. |
| 29 */ | 29 */ |
| 30 | 30 |
| 31 #ifndef WebKitCSSViewportRule_h | 31 #ifndef CSSViewportRule_h |
| 32 #define WebKitCSSViewportRule_h | 32 #define CSSViewportRule_h |
| 33 | 33 |
| 34 #if ENABLE(CSS_DEVICE_ADAPTATION) | 34 #if ENABLE(CSS_DEVICE_ADAPTATION) |
| 35 | 35 |
| 36 #include "core/css/CSSRule.h" | 36 #include "core/css/CSSRule.h" |
| 37 | 37 |
| 38 namespace WebCore { | 38 namespace WebCore { |
| 39 | 39 |
| 40 class CSSStyleDeclaration; | 40 class CSSStyleDeclaration; |
| 41 class StyleRuleViewport; | 41 class StyleRuleViewport; |
| 42 class StyleRuleCSSStyleDeclaration; | 42 class StyleRuleCSSStyleDeclaration; |
| 43 | 43 |
| 44 class WebKitCSSViewportRule: public CSSRule { | 44 class CSSViewportRule: public CSSRule { |
| 45 public: | 45 public: |
| 46 static PassRefPtr<WebKitCSSViewportRule> create(StyleRuleViewport* viewportR
ule, CSSStyleSheet* sheet) | 46 static PassRefPtr<CSSViewportRule> create(StyleRuleViewport* viewportRule, C
SSStyleSheet* sheet) |
| 47 { | 47 { |
| 48 return adoptRef(new WebKitCSSViewportRule(viewportRule, sheet)); | 48 return adoptRef(new CSSViewportRule(viewportRule, sheet)); |
| 49 } | 49 } |
| 50 ~WebKitCSSViewportRule(); | 50 ~CSSViewportRule(); |
| 51 | 51 |
| 52 virtual CSSRule::Type type() const OVERRIDE { return WEBKIT_VIEWPORT_RULE; } | 52 virtual CSSRule::Type type() const OVERRIDE { return WEBKIT_VIEWPORT_RULE; } |
| 53 virtual String cssText() const OVERRIDE; | 53 virtual String cssText() const OVERRIDE; |
| 54 virtual void reattach(StyleRuleBase*) OVERRIDE; | 54 virtual void reattach(StyleRuleBase*) OVERRIDE; |
| 55 virtual void reportMemoryUsage(MemoryObjectInfo*) const OVERRIDE; | 55 virtual void reportMemoryUsage(MemoryObjectInfo*) const OVERRIDE; |
| 56 | 56 |
| 57 CSSStyleDeclaration* style() const; | 57 CSSStyleDeclaration* style() const; |
| 58 | 58 |
| 59 private: | 59 private: |
| 60 WebKitCSSViewportRule(StyleRuleViewport*, CSSStyleSheet*); | 60 CSSViewportRule(StyleRuleViewport*, CSSStyleSheet*); |
| 61 | 61 |
| 62 RefPtr<StyleRuleViewport> m_viewportRule; | 62 RefPtr<StyleRuleViewport> m_viewportRule; |
| 63 mutable RefPtr<StyleRuleCSSStyleDeclaration> m_propertiesCSSOMWrapper; | 63 mutable RefPtr<StyleRuleCSSStyleDeclaration> m_propertiesCSSOMWrapper; |
| 64 }; | 64 }; |
| 65 | 65 |
| 66 } // namespace WebCore | 66 } // namespace WebCore |
| 67 | 67 |
| 68 #endif // WebKitCSSViewportRule_h | 68 #endif // CSSViewportRule_h |
| 69 | 69 |
| 70 #endif // ENABLE(CSS_DEVICE_ADAPTATION) | 70 #endif // ENABLE(CSS_DEVICE_ADAPTATION) |
| OLD | NEW |