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

Side by Side Diff: third_party/WebKit/WebCore/platform/graphics/qt/GradientQt.cpp

Issue 21184: WebKit merge 40722:40785 (part 1) (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 11 years, 10 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 | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2006, 2007, 2008 Apple Computer, Inc. All rights reserved. 2 * Copyright (C) 2006, 2007, 2008 Apple Computer, Inc. All rights reserved.
3 * Copyright (C) 2007 Alp Toker <alp@atoker.com> 3 * Copyright (C) 2007 Alp Toker <alp@atoker.com>
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 10 matching lines...) Expand all
21 * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY 21 * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
22 * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 22 * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
23 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 23 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
24 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 24 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
25 */ 25 */
26 26
27 #include "config.h" 27 #include "config.h"
28 #include "Gradient.h" 28 #include "Gradient.h"
29 29
30 #include "CSSParser.h" 30 #include "CSSParser.h"
31 #include "NotImplemented.h" 31 #include "GraphicsContext.h"
32 32
33 #include <QGradient> 33 #include <QGradient>
34 #include <QPainter>
34 35
35 namespace WebCore { 36 namespace WebCore {
36 37
37 void Gradient::platformDestroy() 38 void Gradient::platformDestroy()
38 { 39 {
39 delete m_gradient; 40 delete m_gradient;
40 m_gradient = 0; 41 m_gradient = 0;
41 } 42 }
42 43
43 QGradient* Gradient::platformGradient() 44 QGradient* Gradient::platformGradient()
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
76 case SpreadMethodRepeat: 77 case SpreadMethodRepeat:
77 m_gradient->setSpread(QGradient::RepeatSpread); 78 m_gradient->setSpread(QGradient::RepeatSpread);
78 break; 79 break;
79 } 80 }
80 81
81 return m_gradient; 82 return m_gradient;
82 } 83 }
83 84
84 void Gradient::fill(GraphicsContext* context, const FloatRect& rect) 85 void Gradient::fill(GraphicsContext* context, const FloatRect& rect)
85 { 86 {
86 notImplemented(); 87 context->platformContext()->fillRect(rect, *platformGradient());
87 } 88 }
88 89
89 } //namespace 90 } //namespace
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698