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

Side by Side Diff: sky/engine/core/css/CSSRule.cpp

Issue 654693004: Remove meta viewport and @viewport CSS rules. (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 6 years, 1 month 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 /* 1 /*
2 * (C) 1999-2003 Lars Knoll (knoll@kde.org) 2 * (C) 1999-2003 Lars Knoll (knoll@kde.org)
3 * (C) 2002-2003 Dirk Mueller (mueller@kde.org) 3 * (C) 2002-2003 Dirk Mueller (mueller@kde.org)
4 * Copyright (C) 2002, 2005, 2006, 2007, 2012 Apple Inc. All rights reserved. 4 * Copyright (C) 2002, 2005, 2006, 2007, 2012 Apple Inc. All rights reserved.
5 * 5 *
6 * This library is free software; you can redistribute it and/or 6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Library General Public 7 * modify it under the terms of the GNU Library General Public
8 * License as published by the Free Software Foundation; either 8 * License as published by the Free Software Foundation; either
9 * version 2 of the License, or (at your option) any later version. 9 * version 2 of the License, or (at your option) any later version.
10 * 10 *
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
42 // doesn't derive ScriptWrappable or ScriptWrappableBase. Then, we can safely 42 // doesn't derive ScriptWrappable or ScriptWrappableBase. Then, we can safely
43 // remove ScriptWrappableBase from the base class list. 43 // remove ScriptWrappableBase from the base class list.
44 struct SameSizeAsCSSRule : public RefCountedWillBeGarbageCollectedFinalized<Same SizeAsCSSRule>, public ScriptWrappableBase { 44 struct SameSizeAsCSSRule : public RefCountedWillBeGarbageCollectedFinalized<Same SizeAsCSSRule>, public ScriptWrappableBase {
45 virtual ~SameSizeAsCSSRule(); 45 virtual ~SameSizeAsCSSRule();
46 unsigned char bitfields; 46 unsigned char bitfields;
47 void* pointerUnion; 47 void* pointerUnion;
48 }; 48 };
49 49
50 COMPILE_ASSERT(sizeof(CSSRule) == sizeof(SameSizeAsCSSRule), CSSRule_should_stay _small); 50 COMPILE_ASSERT(sizeof(CSSRule) == sizeof(SameSizeAsCSSRule), CSSRule_should_stay _small);
51 51
52 COMPILE_ASSERT(StyleRuleBase::Viewport == static_cast<StyleRuleBase::Type>(CSSRu le::VIEWPORT_RULE), enums_should_match);
53
54 void CSSRule::setCSSText(const String&) 52 void CSSRule::setCSSText(const String&)
55 { 53 {
56 notImplemented(); 54 notImplemented();
57 } 55 }
58 56
59 const CSSParserContext& CSSRule::parserContext() const 57 const CSSParserContext& CSSRule::parserContext() const
60 { 58 {
61 CSSStyleSheet* styleSheet = parentStyleSheet(); 59 CSSStyleSheet* styleSheet = parentStyleSheet();
62 return styleSheet ? styleSheet->contents()->parserContext() : strictCSSParse rContext(); 60 return styleSheet ? styleSheet->contents()->parserContext() : strictCSSParse rContext();
63 } 61 }
64 62
65 void CSSRule::trace(Visitor* visitor) 63 void CSSRule::trace(Visitor* visitor)
66 { 64 {
67 #if ENABLE(OILPAN) 65 #if ENABLE(OILPAN)
68 // This makes the parent link strong, which is different from the 66 // This makes the parent link strong, which is different from the
69 // pre-oilpan world, where the parent link is mysteriously zeroed under 67 // pre-oilpan world, where the parent link is mysteriously zeroed under
70 // some circumstances. 68 // some circumstances.
71 if (m_parentIsRule) 69 if (m_parentIsRule)
72 visitor->trace(m_parentRule); 70 visitor->trace(m_parentRule);
73 else 71 else
74 visitor->trace(m_parentStyleSheet); 72 visitor->trace(m_parentStyleSheet);
75 #endif 73 #endif
76 } 74 }
77 75
78 } // namespace blink 76 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698