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

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

Issue 2493673002: Synchronize OffscreenCanvas content with the placeholder canvas (Closed)
Patch Set: fix obsolete test Created 4 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) 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 28 matching lines...) Expand all
39 #include "core/html/canvas/CanvasDrawListener.h" 39 #include "core/html/canvas/CanvasDrawListener.h"
40 #include "core/html/canvas/CanvasImageSource.h" 40 #include "core/html/canvas/CanvasImageSource.h"
41 #include "core/imagebitmap/ImageBitmapSource.h" 41 #include "core/imagebitmap/ImageBitmapSource.h"
42 #include "core/page/PageVisibilityObserver.h" 42 #include "core/page/PageVisibilityObserver.h"
43 #include "platform/geometry/FloatRect.h" 43 #include "platform/geometry/FloatRect.h"
44 #include "platform/geometry/IntSize.h" 44 #include "platform/geometry/IntSize.h"
45 #include "platform/graphics/CanvasSurfaceLayerBridge.h" 45 #include "platform/graphics/CanvasSurfaceLayerBridge.h"
46 #include "platform/graphics/GraphicsTypes.h" 46 #include "platform/graphics/GraphicsTypes.h"
47 #include "platform/graphics/GraphicsTypes3D.h" 47 #include "platform/graphics/GraphicsTypes3D.h"
48 #include "platform/graphics/ImageBufferClient.h" 48 #include "platform/graphics/ImageBufferClient.h"
49 #include "platform/graphics/OffscreenCanvasPlaceholder.h"
49 #include "platform/heap/Handle.h" 50 #include "platform/heap/Handle.h"
50 #include <memory> 51 #include <memory>
51 52
52 #define CanvasDefaultInterpolationQuality InterpolationLow 53 #define CanvasDefaultInterpolationQuality InterpolationLow
53 54
54 namespace blink { 55 namespace blink {
55 56
56 class AffineTransform; 57 class AffineTransform;
57 class CanvasContextCreationAttributes; 58 class CanvasContextCreationAttributes;
58 class CanvasRenderingContext; 59 class CanvasRenderingContext;
(...skipping 11 matching lines...) Expand all
70 class 71 class
71 CanvasRenderingContext2DOrWebGLRenderingContextOrWebGL2RenderingContextOrIma geBitmapRenderingContext; 72 CanvasRenderingContext2DOrWebGLRenderingContextOrWebGL2RenderingContextOrIma geBitmapRenderingContext;
72 typedef CanvasRenderingContext2DOrWebGLRenderingContextOrWebGL2RenderingContextO rImageBitmapRenderingContext 73 typedef CanvasRenderingContext2DOrWebGLRenderingContextOrWebGL2RenderingContextO rImageBitmapRenderingContext
73 RenderingContext; 74 RenderingContext;
74 75
75 class CORE_EXPORT HTMLCanvasElement final : public HTMLElement, 76 class CORE_EXPORT HTMLCanvasElement final : public HTMLElement,
76 public ContextLifecycleObserver, 77 public ContextLifecycleObserver,
77 public PageVisibilityObserver, 78 public PageVisibilityObserver,
78 public CanvasImageSource, 79 public CanvasImageSource,
79 public ImageBufferClient, 80 public ImageBufferClient,
80 public ImageBitmapSource { 81 public ImageBitmapSource,
82 public OffscreenCanvasPlaceholder {
81 DEFINE_WRAPPERTYPEINFO(); 83 DEFINE_WRAPPERTYPEINFO();
82 USING_GARBAGE_COLLECTED_MIXIN(HTMLCanvasElement); 84 USING_GARBAGE_COLLECTED_MIXIN(HTMLCanvasElement);
83 USING_PRE_FINALIZER(HTMLCanvasElement, dispose); 85 USING_PRE_FINALIZER(HTMLCanvasElement, dispose);
84 86
85 public: 87 public:
86 using Node::getExecutionContext; 88 using Node::getExecutionContext;
87 89
88 DECLARE_NODE_FACTORY(HTMLCanvasElement); 90 DECLARE_NODE_FACTORY(HTMLCanvasElement);
89 ~HTMLCanvasElement() override; 91 ~HTMLCanvasElement() override;
90 92
(...skipping 211 matching lines...) Expand 10 before | Expand all | Expand 10 after
302 // Used for OffscreenCanvas that controls this HTML canvas element 304 // Used for OffscreenCanvas that controls this HTML canvas element
303 std::unique_ptr<CanvasSurfaceLayerBridge> m_surfaceLayerBridge; 305 std::unique_ptr<CanvasSurfaceLayerBridge> m_surfaceLayerBridge;
304 306
305 int m_numFramesSinceLastRenderingModeSwitch; 307 int m_numFramesSinceLastRenderingModeSwitch;
306 bool m_pendingRenderingModeSwitch; 308 bool m_pendingRenderingModeSwitch;
307 }; 309 };
308 310
309 } // namespace blink 311 } // namespace blink
310 312
311 #endif // HTMLCanvasElement_h 313 #endif // HTMLCanvasElement_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698