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

Side by Side Diff: sky/engine/core/html/canvas/CanvasStyle.h

Issue 723253004: Remove tons of OILPAN. (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 6 years, 1 month 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 /* 1 /*
2 * Copyright (C) 2006, 2008 Apple Inc. All rights reserved. 2 * Copyright (C) 2006, 2008 Apple Inc. All rights reserved.
3 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies) 3 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies)
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 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
59 CanvasGradient* canvasGradient() const { return m_gradient.get(); } 59 CanvasGradient* canvasGradient() const { return m_gradient.get(); }
60 CanvasPattern* canvasPattern() const { return m_pattern.get(); } 60 CanvasPattern* canvasPattern() const { return m_pattern.get(); }
61 61
62 void applyFillColor(GraphicsContext*); 62 void applyFillColor(GraphicsContext*);
63 void applyStrokeColor(GraphicsContext*); 63 void applyStrokeColor(GraphicsContext*);
64 64
65 bool isEquivalentColor(const CanvasStyle&) const; 65 bool isEquivalentColor(const CanvasStyle&) const;
66 bool isEquivalentRGBA(float r, float g, float b, float a) const; 66 bool isEquivalentRGBA(float r, float g, float b, float a) const;
67 bool isEquivalentCMYKA(float c, float m, float y, float k, float a) cons t; 67 bool isEquivalentCMYKA(float c, float m, float y, float k, float a) cons t;
68 68
69 void trace(Visitor*);
70
71 private: 69 private:
72 enum Type { RGBA, CMYKA, Gradient, ImagePattern, CurrentColor, CurrentCo lorWithOverrideAlpha }; 70 enum Type { RGBA, CMYKA, Gradient, ImagePattern, CurrentColor, CurrentCo lorWithOverrideAlpha };
73 71
74 CanvasStyle(Type, float overrideAlpha = 0); 72 CanvasStyle(Type, float overrideAlpha = 0);
75 CanvasStyle(RGBA32 rgba); 73 CanvasStyle(RGBA32 rgba);
76 CanvasStyle(float grayLevel, float alpha); 74 CanvasStyle(float grayLevel, float alpha);
77 CanvasStyle(float r, float g, float b, float a); 75 CanvasStyle(float r, float g, float b, float a);
78 CanvasStyle(float c, float m, float y, float k, float a); 76 CanvasStyle(float c, float m, float y, float k, float a);
79 CanvasStyle(PassRefPtr<CanvasGradient>); 77 CanvasStyle(PassRefPtr<CanvasGradient>);
80 CanvasStyle(PassRefPtr<CanvasPattern>); 78 CanvasStyle(PassRefPtr<CanvasPattern>);
(...skipping 18 matching lines...) Expand all
99 float a; 97 float a;
100 } m_cmyka; 98 } m_cmyka;
101 }; 99 };
102 100
103 RGBA32 currentColor(HTMLCanvasElement*); 101 RGBA32 currentColor(HTMLCanvasElement*);
104 bool parseColorOrCurrentColor(RGBA32& parsedColor, const String& colorString , HTMLCanvasElement*); 102 bool parseColorOrCurrentColor(RGBA32& parsedColor, const String& colorString , HTMLCanvasElement*);
105 103
106 } // namespace blink 104 } // namespace blink
107 105
108 #endif 106 #endif
OLDNEW
« no previous file with comments | « sky/engine/core/html/canvas/CanvasRenderingContext2D.cpp ('k') | sky/engine/core/html/canvas/CanvasStyle.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698