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

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

Issue 1858753003: Remove RawPtr from core/css (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 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 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 CSSColorValue_h 5 #ifndef CSSColorValue_h
6 #define CSSColorValue_h 6 #define CSSColorValue_h
7 7
8 #include "core/css/CSSValue.h" 8 #include "core/css/CSSValue.h"
9 #include "platform/graphics/Color.h" 9 #include "platform/graphics/Color.h"
10 #include "wtf/PassRefPtr.h" 10 #include "wtf/PassRefPtr.h"
11 11
12 namespace blink { 12 namespace blink {
13 13
14 // Represents the non-keyword subset of <color>. 14 // Represents the non-keyword subset of <color>.
15 class CSSColorValue : public CSSValue { 15 class CSSColorValue : public CSSValue {
16 public: 16 public:
17 static RawPtr<CSSColorValue> create(Color color) 17 static CSSColorValue* create(Color color)
18 { 18 {
19 return new CSSColorValue(color); 19 return new CSSColorValue(color);
20 } 20 }
21 21
22 String customCSSText() const 22 String customCSSText() const
23 { 23 {
24 return m_color.serializedAsCSSComponentValue(); 24 return m_color.serializedAsCSSComponentValue();
25 } 25 }
26 26
27 Color value() const { return m_color; } 27 Color value() const { return m_color; }
(...skipping 14 matching lines...) Expand all
42 , m_color(color) { } 42 , m_color(color) { }
43 43
44 Color m_color; 44 Color m_color;
45 }; 45 };
46 46
47 DEFINE_CSS_VALUE_TYPE_CASTS(CSSColorValue, isColorValue()); 47 DEFINE_CSS_VALUE_TYPE_CASTS(CSSColorValue, isColorValue());
48 48
49 } // namespace blink 49 } // namespace blink
50 50
51 #endif // CSSColorValue_h 51 #endif // CSSColorValue_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698