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

Side by Side Diff: third_party/WebKit/Source/modules/csspaint/PaintRenderingContext2D.h

Issue 1878253003: Allow explicit conversion operators and implement WTF::OwnPtr::operator bool. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix 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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 PaintRenderingContext2D_h 5 #ifndef PaintRenderingContext2D_h
6 #define PaintRenderingContext2D_h 6 #define PaintRenderingContext2D_h
7 7
8 #include "bindings/core/v8/ScriptWrappable.h" 8 #include "bindings/core/v8/ScriptWrappable.h"
9 #include "modules/ModulesExport.h" 9 #include "modules/ModulesExport.h"
10 #include "modules/canvas2d/BaseRenderingContext2D.h" 10 #include "modules/canvas2d/BaseRenderingContext2D.h"
(...skipping 19 matching lines...) Expand all
30 30
31 // PaintRenderingContext2D doesn't have any pixel readback so the origin 31 // PaintRenderingContext2D doesn't have any pixel readback so the origin
32 // is always clean, and unable to taint it. 32 // is always clean, and unable to taint it.
33 bool originClean() const final { return true; } 33 bool originClean() const final { return true; }
34 void setOriginTainted() final { } 34 void setOriginTainted() final { }
35 bool wouldTaintOrigin(CanvasImageSource*) final { return false; } 35 bool wouldTaintOrigin(CanvasImageSource*) final { return false; }
36 36
37 int width() const final; 37 int width() const final;
38 int height() const final; 38 int height() const final;
39 39
40 bool hasImageBuffer() const final { return m_imageBuffer; } 40 bool hasImageBuffer() const final { return m_imageBuffer.get(); }
41 ImageBuffer* imageBuffer() const final { return m_imageBuffer.get(); } 41 ImageBuffer* imageBuffer() const final { return m_imageBuffer.get(); }
42 42
43 bool parseColorOrCurrentColor(Color&, const String& colorString) const final ; 43 bool parseColorOrCurrentColor(Color&, const String& colorString) const final ;
44 44
45 SkCanvas* drawingCanvas() const final; 45 SkCanvas* drawingCanvas() const final;
46 SkCanvas* existingDrawingCanvas() const final; 46 SkCanvas* existingDrawingCanvas() const final;
47 void disableDeferral(DisableDeferralReason) final { } 47 void disableDeferral(DisableDeferralReason) final { }
48 48
49 AffineTransform baseTransform() const final; 49 AffineTransform baseTransform() const final;
50 50
(...skipping 15 matching lines...) Expand all
66 66
67 private: 67 private:
68 explicit PaintRenderingContext2D(PassOwnPtr<ImageBuffer>); 68 explicit PaintRenderingContext2D(PassOwnPtr<ImageBuffer>);
69 69
70 OwnPtr<ImageBuffer> m_imageBuffer; 70 OwnPtr<ImageBuffer> m_imageBuffer;
71 }; 71 };
72 72
73 } // namespace blink 73 } // namespace blink
74 74
75 #endif // PaintRenderingContext2D_h 75 #endif // PaintRenderingContext2D_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698