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

Side by Side Diff: third_party/WebKit/Source/core/html/HTMLCanvasElement.h

Issue 1512803004: Use refs for GraphicsContext (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@ScrollbarTheme
Patch Set: Created 5 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2004, 2006, 2009, 2010 Apple Inc. All rights reserved. 2 * Copyright (C) 2004, 2006, 2009, 2010 Apple Inc. All rights reserved.
3 * Copyright (C) 2007 Alp Toker <alp@atoker.com> 3 * Copyright (C) 2007 Alp Toker <alp@atoker.com>
4 * Copyright (C) 2010 Torch Mobile (Beijing) Co. Ltd. All rights reserved. 4 * Copyright (C) 2010 Torch Mobile (Beijing) Co. Ltd. All rights reserved.
5 * 5 *
6 * Redistribution and use in source and binary forms, with or without 6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions 7 * modification, are permitted provided that the following conditions
8 * are met: 8 * are met:
9 * 1. Redistributions of source code must retain the above copyright 9 * 1. Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after
103 void toBlob(FileCallback*, const String& mimeType, const ScriptValue& qualit yArgument, ExceptionState&); 103 void toBlob(FileCallback*, const String& mimeType, const ScriptValue& qualit yArgument, ExceptionState&);
104 void toBlob(FileCallback* callback, const String& mimeType, ExceptionState& exceptionState) { return toBlob(callback, mimeType, ScriptValue(), exceptionStat e); } 104 void toBlob(FileCallback* callback, const String& mimeType, ExceptionState& exceptionState) { return toBlob(callback, mimeType, ScriptValue(), exceptionStat e); }
105 105
106 // Used for canvas capture. 106 // Used for canvas capture.
107 void addListener(CanvasDrawListener*); 107 void addListener(CanvasDrawListener*);
108 void removeListener(CanvasDrawListener*); 108 void removeListener(CanvasDrawListener*);
109 109
110 // Used for rendering 110 // Used for rendering
111 void didDraw(const FloatRect&); 111 void didDraw(const FloatRect&);
112 112
113 void paint(GraphicsContext*, const LayoutRect&); 113 void paint(GraphicsContext&, const LayoutRect&);
114 114
115 SkCanvas* drawingCanvas() const; 115 SkCanvas* drawingCanvas() const;
116 void disableDeferral() const; 116 void disableDeferral() const;
117 SkCanvas* existingDrawingCanvas() const; 117 SkCanvas* existingDrawingCanvas() const;
118 118
119 void setRenderingContext(PassOwnPtrWillBeRawPtr<CanvasRenderingContext>); 119 void setRenderingContext(PassOwnPtrWillBeRawPtr<CanvasRenderingContext>);
120 CanvasRenderingContext* renderingContext() const { return m_context.get(); } 120 CanvasRenderingContext* renderingContext() const { return m_context.get(); }
121 121
122 void ensureUnacceleratedImageBuffer(); 122 void ensureUnacceleratedImageBuffer();
123 ImageBuffer* buffer() const; 123 ImageBuffer* buffer() const;
(...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after
226 mutable bool m_didFailToCreateImageBuffer; 226 mutable bool m_didFailToCreateImageBuffer;
227 bool m_imageBufferIsClear; 227 bool m_imageBufferIsClear;
228 OwnPtr<ImageBuffer> m_imageBuffer; 228 OwnPtr<ImageBuffer> m_imageBuffer;
229 229
230 mutable RefPtr<Image> m_copiedImage; // FIXME: This is temporary for platfor ms that have to copy the image buffer to render (and for CSSCanvasValue). 230 mutable RefPtr<Image> m_copiedImage; // FIXME: This is temporary for platfor ms that have to copy the image buffer to render (and for CSSCanvasValue).
231 }; 231 };
232 232
233 } // namespace blink 233 } // namespace blink
234 234
235 #endif // HTMLCanvasElement_h 235 #endif // HTMLCanvasElement_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698