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

Side by Side Diff: Source/core/dom/Document.cpp

Issue 14178009: Remove CSS_REGIONS compile flag from Blink. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Use RuntimeEnabledFeatures::cssRegionsEnabled all over the places. Guard WEBKIT_REGION_RULE at runt… Created 7 years, 7 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 /* 1 /*
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) 3 * (C) 1999 Antti Koivisto (koivisto@kde.org)
4 * (C) 2001 Dirk Mueller (mueller@kde.org) 4 * (C) 2001 Dirk Mueller (mueller@kde.org)
5 * (C) 2006 Alexey Proskuryakov (ap@webkit.org) 5 * (C) 2006 Alexey Proskuryakov (ap@webkit.org)
6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2011, 2012 Apple Inc. All r ights reserved. 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2011, 2012 Apple Inc. All r ights reserved.
7 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t orchmobile.com/) 7 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t orchmobile.com/)
8 * Copyright (C) 2008, 2009, 2011, 2012 Google Inc. All rights reserved. 8 * Copyright (C) 2008, 2009, 2011, 2012 Google Inc. All rights reserved.
9 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies) 9 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies)
10 * Copyright (C) Research In Motion Limited 2010-2011. All rights reserved. 10 * Copyright (C) Research In Motion Limited 2010-2011. All rights reserved.
(...skipping 1069 matching lines...) Expand 10 before | Expand all | Expand 10 after
1080 bool Document::regionBasedColumnsEnabled() const 1080 bool Document::regionBasedColumnsEnabled() const
1081 { 1081 {
1082 return settings() && settings()->regionBasedColumnsEnabled(); 1082 return settings() && settings()->regionBasedColumnsEnabled();
1083 } 1083 }
1084 1084
1085 bool Document::cssStickyPositionEnabled() const 1085 bool Document::cssStickyPositionEnabled() const
1086 { 1086 {
1087 return settings() && settings()->cssStickyPositionEnabled(); 1087 return settings() && settings()->cssStickyPositionEnabled();
1088 } 1088 }
1089 1089
1090 bool Document::cssRegionsEnabled() const
1091 {
1092 return RuntimeEnabledFeatures::cssRegionsEnabled();
1093 }
1094
1095 bool Document::cssCompositingEnabled() const 1090 bool Document::cssCompositingEnabled() const
1096 { 1091 {
1097 return RuntimeEnabledFeatures::cssCompositingEnabled(); 1092 return RuntimeEnabledFeatures::cssCompositingEnabled();
1098 } 1093 }
1099 1094
1100 bool Document::cssGridLayoutEnabled() const 1095 bool Document::cssGridLayoutEnabled() const
1101 { 1096 {
1102 return settings() && settings()->cssGridLayoutEnabled(); 1097 return settings() && settings()->cssGridLayoutEnabled();
1103 } 1098 }
1104 1099
1105 #if ENABLE(CSS_REGIONS)
1106
1107 PassRefPtr<DOMNamedFlowCollection> Document::webkitGetNamedFlows() 1100 PassRefPtr<DOMNamedFlowCollection> Document::webkitGetNamedFlows()
1108 { 1101 {
1109 if (!cssRegionsEnabled() || !renderer()) 1102 if (!RuntimeEnabledFeatures::cssRegionsEnabled() || !renderer())
1110 return 0; 1103 return 0;
1111 1104
1112 updateStyleIfNeeded(); 1105 updateStyleIfNeeded();
1113 1106
1114 return namedFlows()->createCSSOMSnapshot(); 1107 return namedFlows()->createCSSOMSnapshot();
1115 } 1108 }
1116 1109
1117 #endif
1118
1119 NamedFlowCollection* Document::namedFlows() 1110 NamedFlowCollection* Document::namedFlows()
1120 { 1111 {
1121 if (!m_namedFlows) 1112 if (!m_namedFlows)
1122 m_namedFlows = NamedFlowCollection::create(this); 1113 m_namedFlows = NamedFlowCollection::create(this);
1123 1114
1124 return m_namedFlows.get(); 1115 return m_namedFlows.get();
1125 } 1116 }
1126 1117
1127 PassRefPtr<Element> Document::createElementNS(const String& namespaceURI, const String& qualifiedName, ExceptionCode& ec) 1118 PassRefPtr<Element> Document::createElementNS(const String& namespaceURI, const String& qualifiedName, ExceptionCode& ec)
1128 { 1119 {
(...skipping 4590 matching lines...) Expand 10 before | Expand all | Expand 10 after
5719 return; 5710 return;
5720 5711
5721 Vector<RefPtr<Element> > associatedFormControls; 5712 Vector<RefPtr<Element> > associatedFormControls;
5722 copyToVector(m_associatedFormControls, associatedFormControls); 5713 copyToVector(m_associatedFormControls, associatedFormControls);
5723 5714
5724 frame()->page()->chrome()->client()->didAssociateFormControls(associatedForm Controls); 5715 frame()->page()->chrome()->client()->didAssociateFormControls(associatedForm Controls);
5725 m_associatedFormControls.clear(); 5716 m_associatedFormControls.clear();
5726 } 5717 }
5727 5718
5728 } // namespace WebCore 5719 } // namespace WebCore
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698