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

Side by Side Diff: Source/core/css/CSSGradientValue.h

Issue 805823002: Remove code duplication from the customCSSText() methods of gradient classes. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Rename the new method Created 6 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
« no previous file with comments | « no previous file | Source/core/css/CSSGradientValue.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2008 Apple Inc. All rights reserved. 2 * Copyright (C) 2008 Apple Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after
88 88
89 void setFirstX(PassRefPtrWillBeRawPtr<CSSPrimitiveValue> val) { m_firstX = v al; } 89 void setFirstX(PassRefPtrWillBeRawPtr<CSSPrimitiveValue> val) { m_firstX = v al; }
90 void setFirstY(PassRefPtrWillBeRawPtr<CSSPrimitiveValue> val) { m_firstY = v al; } 90 void setFirstY(PassRefPtrWillBeRawPtr<CSSPrimitiveValue> val) { m_firstY = v al; }
91 void setSecondX(PassRefPtrWillBeRawPtr<CSSPrimitiveValue> val) { m_secondX = val; } 91 void setSecondX(PassRefPtrWillBeRawPtr<CSSPrimitiveValue> val) { m_secondX = val; }
92 void setSecondY(PassRefPtrWillBeRawPtr<CSSPrimitiveValue> val) { m_secondY = val; } 92 void setSecondY(PassRefPtrWillBeRawPtr<CSSPrimitiveValue> val) { m_secondY = val; }
93 93
94 void addStop(const CSSGradientColorStop& stop) { m_stops.append(stop); } 94 void addStop(const CSSGradientColorStop& stop) { m_stops.append(stop); }
95 95
96 unsigned stopCount() const { return m_stops.size(); } 96 unsigned stopCount() const { return m_stops.size(); }
97 97
98 void appendCSSTextForDeprecatedColorStops(StringBuilder&) const;
99
98 void sortStopsIfNeeded(); 100 void sortStopsIfNeeded();
99 101
100 bool isRepeating() const { return m_repeating; } 102 bool isRepeating() const { return m_repeating; }
101 103
102 CSSGradientType gradientType() const { return m_gradientType; } 104 CSSGradientType gradientType() const { return m_gradientType; }
103 105
104 bool isFixedSize() const { return false; } 106 bool isFixedSize() const { return false; }
105 IntSize fixedSize(const RenderObject*) const { return IntSize(); } 107 IntSize fixedSize(const RenderObject*) const { return IntSize(); }
106 108
107 bool isPending() const { return false; } 109 bool isPending() const { return false; }
(...skipping 150 matching lines...) Expand 10 before | Expand all | Expand 10 after
258 260
259 RefPtrWillBeMember<CSSPrimitiveValue> m_endHorizontalSize; 261 RefPtrWillBeMember<CSSPrimitiveValue> m_endHorizontalSize;
260 RefPtrWillBeMember<CSSPrimitiveValue> m_endVerticalSize; 262 RefPtrWillBeMember<CSSPrimitiveValue> m_endVerticalSize;
261 }; 263 };
262 264
263 DEFINE_CSS_VALUE_TYPE_CASTS(CSSRadialGradientValue, isRadialGradientValue()); 265 DEFINE_CSS_VALUE_TYPE_CASTS(CSSRadialGradientValue, isRadialGradientValue());
264 266
265 } // namespace blink 267 } // namespace blink
266 268
267 #endif // CSSGradientValue_h 269 #endif // CSSGradientValue_h
OLDNEW
« no previous file with comments | « no previous file | Source/core/css/CSSGradientValue.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698