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

Unified Diff: Source/core/inspector/LayoutEditor.h

Issue 1310923003: Devtools [LayoutEditor]: Patch values in the selected rule (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@medias
Patch Set: Address comments Created 5 years, 3 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 side-by-side diff with in-line comments
Download patch
Index: Source/core/inspector/LayoutEditor.h
diff --git a/Source/core/inspector/LayoutEditor.h b/Source/core/inspector/LayoutEditor.h
index dbc9c0ceac996d55c1624766cc21e9b8866e1720..aabebd035a92d4329c109b5b5f97e613d0623a5b 100644
--- a/Source/core/inspector/LayoutEditor.h
+++ b/Source/core/inspector/LayoutEditor.h
@@ -8,7 +8,7 @@
#include "core/CSSPropertyNames.h"
#include "core/CoreExport.h"
#include "core/css/CSSPrimitiveValue.h"
-#include "core/css/CSSStyleRule.h"
+#include "core/css/CSSRuleList.h"
#include "core/dom/Element.h"
#include "platform/heap/Handle.h"
#include "wtf/PassOwnPtr.h"
@@ -49,7 +49,8 @@ private:
RefPtrWillBeRawPtr<CSSPrimitiveValue> getPropertyCSSValue(CSSPropertyID) const;
PassRefPtr<JSONObject> createValueDescription(const String&) const;
void appendAnchorFor(JSONArray*, const String&, const String&, const FloatPoint&, const FloatPoint&) const;
- void initializeCSSRules();
+ bool setCSSPropertyValueInCurrentRule(const String&);
+ bool currentStyleIsInline();
RefPtrWillBeMember<Element> m_element;
RawPtrWillBeMember<InspectorCSSAgent> m_cssAgent;
@@ -60,10 +61,10 @@ private:
CSSPrimitiveValue::UnitType m_valueUnitType;
bool m_isDirty;
- WillBeHeapVector<RefPtrWillBeMember<CSSStyleRule>> m_matchedRules;
+ RefPtrWillBeRawPtr<CSSRuleList> m_matchedRules;
HashMap<int, String> m_cachedSelectorsInfo;
- // -1 means "inline style".
- int m_currentRuleIndex;
+ // When m_currentRuleIndex == m_matchedRules.length(), current style is inline style.
+ unsigned m_currentRuleIndex;
};
} // namespace blink

Powered by Google App Engine
This is Rietveld 408576698