OLD | NEW |
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 172 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
183 const FloatSize&) const override; | 183 const FloatSize&) const override; |
184 bool wouldTaintOrigin(SecurityOrigin*) const override; | 184 bool wouldTaintOrigin(SecurityOrigin*) const override; |
185 FloatSize elementSize(const FloatSize&) const override; | 185 FloatSize elementSize(const FloatSize&) const override; |
186 bool isCanvasElement() const override { return true; } | 186 bool isCanvasElement() const override { return true; } |
187 bool isOpaque() const override; | 187 bool isOpaque() const override; |
188 bool isAccelerated() const override; | 188 bool isAccelerated() const override; |
189 int sourceWidth() override { return m_size.width(); } | 189 int sourceWidth() override { return m_size.width(); } |
190 int sourceHeight() override { return m_size.height(); } | 190 int sourceHeight() override { return m_size.height(); } |
191 | 191 |
192 // CanvasSurfaceLayerBridgeObserver implementation | 192 // CanvasSurfaceLayerBridgeObserver implementation |
193 void OnWebLayerReplaced() override; | 193 void OnWebLayerReplaced(int width, int height) override; |
194 | 194 |
195 // ImageBufferClient implementation | 195 // ImageBufferClient implementation |
196 void notifySurfaceInvalid() override; | 196 void notifySurfaceInvalid() override; |
197 bool isDirty() override { return !m_dirtyRect.isEmpty(); } | 197 bool isDirty() override { return !m_dirtyRect.isEmpty(); } |
198 void didDisableAcceleration() override; | 198 void didDisableAcceleration() override; |
199 void didFinalizeFrame() override; | 199 void didFinalizeFrame() override; |
200 void restoreCanvasMatrixClipStack(SkCanvas*) const override; | 200 void restoreCanvasMatrixClipStack(SkCanvas*) const override; |
201 | 201 |
202 void doDeferredPaintInvalidation(); | 202 void doDeferredPaintInvalidation(); |
203 | 203 |
(...skipping 107 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
311 // Used for OffscreenCanvas that controls this HTML canvas element | 311 // Used for OffscreenCanvas that controls this HTML canvas element |
312 std::unique_ptr<CanvasSurfaceLayerBridge> m_surfaceLayerBridge; | 312 std::unique_ptr<CanvasSurfaceLayerBridge> m_surfaceLayerBridge; |
313 | 313 |
314 int m_numFramesSinceLastRenderingModeSwitch; | 314 int m_numFramesSinceLastRenderingModeSwitch; |
315 bool m_pendingRenderingModeSwitch; | 315 bool m_pendingRenderingModeSwitch; |
316 }; | 316 }; |
317 | 317 |
318 } // namespace blink | 318 } // namespace blink |
319 | 319 |
320 #endif // HTMLCanvasElement_h | 320 #endif // HTMLCanvasElement_h |
OLD | NEW |