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

Side by Side Diff: third_party/WebKit/Source/platform/graphics/OffscreenCanvasFrameDispatcher.h

Issue 2517343003: Update Resize information from OffscreenCanvas to OffscreenCanvasFrameDispatcher (Closed)
Patch Set: fix error Created 4 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 // 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 OffscreenCanvasFrameDispatcher_h 5 #ifndef OffscreenCanvasFrameDispatcher_h
6 #define OffscreenCanvasFrameDispatcher_h 6 #define OffscreenCanvasFrameDispatcher_h
7 7
8 #include "platform/PlatformExport.h" 8 #include "platform/PlatformExport.h"
9 #include "wtf/RefPtr.h" 9 #include "wtf/RefPtr.h"
10 #include "wtf/WeakPtr.h" 10 #include "wtf/WeakPtr.h"
11 11
12 namespace blink { 12 namespace blink {
13 13
14 class StaticBitmapImage; 14 class StaticBitmapImage;
15 15
16 class PLATFORM_EXPORT OffscreenCanvasFrameDispatcher { 16 class PLATFORM_EXPORT OffscreenCanvasFrameDispatcher {
17 public: 17 public:
18 OffscreenCanvasFrameDispatcher() : m_weakPtrFactory(this) {} 18 OffscreenCanvasFrameDispatcher() : m_weakPtrFactory(this) {}
19 virtual ~OffscreenCanvasFrameDispatcher() {} 19 virtual ~OffscreenCanvasFrameDispatcher() {}
20 virtual void dispatchFrame(RefPtr<StaticBitmapImage>, 20 virtual void dispatchFrame(RefPtr<StaticBitmapImage>,
21 double commitStartTime, 21 double commitStartTime,
22 bool isWebGLSoftwareRendering = false) = 0; 22 bool isWebGLSoftwareRendering = false) = 0;
23 virtual void reclaimResource(unsigned resourceId) = 0; 23 virtual void reclaimResource(unsigned resourceId) = 0;
24 24
25 virtual void reshape(int width, int height) = 0;
26
25 WeakPtr<OffscreenCanvasFrameDispatcher> createWeakPtr() { 27 WeakPtr<OffscreenCanvasFrameDispatcher> createWeakPtr() {
26 return m_weakPtrFactory.createWeakPtr(); 28 return m_weakPtrFactory.createWeakPtr();
27 } 29 }
28 30
29 private: 31 private:
30 WeakPtrFactory<OffscreenCanvasFrameDispatcher> m_weakPtrFactory; 32 WeakPtrFactory<OffscreenCanvasFrameDispatcher> m_weakPtrFactory;
31 }; 33 };
32 34
33 } // namespace blink 35 } // namespace blink
34 36
35 #endif // OffscreenCanvasFrameDispatcher_h 37 #endif // OffscreenCanvasFrameDispatcher_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698