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

Side by Side Diff: third_party/WebKit/Source/core/css/CSSPathValue.h

Issue 1439793003: SVG: Promote d to a property (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: RefPtrWillBePersistent Created 5 years 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 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 CSSPathValue_h 5 #ifndef CSSPathValue_h
6 #define CSSPathValue_h 6 #define CSSPathValue_h
7 7
8 #include "core/css/CSSValue.h" 8 #include "core/css/CSSValue.h"
9 #include "core/svg/SVGPathByteStream.h"
9 #include "wtf/PassRefPtr.h" 10 #include "wtf/PassRefPtr.h"
10 #include "wtf/RefPtr.h" 11 #include "wtf/RefPtr.h"
11 12
12 namespace blink { 13 namespace blink {
13 14
14 class CSSPathValue : public CSSValue { 15 class CSSPathValue : public CSSValue {
15 public: 16 public:
16 static PassRefPtrWillBeRawPtr<CSSPathValue> create(const String& pathString) 17 static PassRefPtrWillBeRawPtr<CSSPathValue> create(PassOwnPtr<SVGPathByteStr eam> pathByteStream)
17 { 18 {
18 return adoptRefWillBeNoop(new CSSPathValue(pathString)); 19 return adoptRefWillBeNoop(new CSSPathValue(pathByteStream));
19 } 20 }
20 21
22 static PassRefPtrWillBeRawPtr<CSSPathValue> create(const String&);
23
24 static CSSPathValue* emptyPathValue();
25
21 String customCSSText() const; 26 String customCSSText() const;
22 27
23 bool equals(const CSSPathValue&) const; 28 bool equals(const CSSPathValue&) const;
24 29
25 DECLARE_TRACE_AFTER_DISPATCH(); 30 DECLARE_TRACE_AFTER_DISPATCH();
26 31
27 const String& pathString() const { return m_pathString; } 32 const SVGPathByteStream& byteStream() const { return *m_pathByteStream; }
33 String pathString() const;
28 34
29 private: 35 private:
30 CSSPathValue(const String& pathString); 36 CSSPathValue(PassOwnPtr<SVGPathByteStream>);
31 37
32 String m_pathString; 38 OwnPtr<SVGPathByteStream> m_pathByteStream;
33 }; 39 };
34 40
35 DEFINE_CSS_VALUE_TYPE_CASTS(CSSPathValue, isPathValue()); 41 DEFINE_CSS_VALUE_TYPE_CASTS(CSSPathValue, isPathValue());
36 42
37 } // namespace blink 43 } // namespace blink
38 44
39 #endif // CSSPathValue_h 45 #endif // CSSPathValue_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698