Changeset 79950 in webkit
- Timestamp:
- Feb 28, 2011 5:33:49 PM (13 years ago)
- Location:
- trunk/Source/WebCore
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebCore/ChangeLog
r79947 r79950 1 2011-02-28 Noel Gordon <noel.gordon@gmail.com> 2 Reviewed by James Robinson. 3 4 [chromium] GradientSkia: use the common Gradient stop sorting methods. 5 https://bugs.webkit.org/show_bug.cgi?id=54625 6 7 Remove a FIXME: call the Gradient.cpp stop storting routines, no need 8 to duplicate that code herein. 9 10 No change in behavior, so no new tests. 11 12 * platform/graphics/skia/GradientSkia.cpp: 13 (WebCore::Gradient::platformGradient): 14 1 15 2011-02-28 Steve Block <steveblock@google.com> 2 16 -
trunk/Source/WebCore/platform/graphics/skia/GradientSkia.cpp
r79063 r79950 111 111 } 112 112 113 static inline bool compareStops(const Gradient::ColorStop& a, const Gradient::ColorStop& b)114 {115 return a.stop < b.stop;116 }117 118 113 SkShader* Gradient::platformGradient() 119 114 { … … 121 116 return m_gradient; 122 117 123 // FIXME: This and compareStops() are also in Gradient.cpp and 124 // CSSGradientValue.cpp; probably should refactor in WebKit. 125 if (!m_stopsSorted) { 126 if (m_stops.size()) 127 std::stable_sort(m_stops.begin(), m_stops.end(), compareStops); 128 m_stopsSorted = true; 129 } 118 sortStopsIfNecessary(); 119 ASSERT(m_stopsSorted); 130 120 131 121 size_t countUsed = totalStopsNeeded(m_stops.data(), m_stops.size());
Note: See TracChangeset
for help on using the changeset viewer.