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

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

Issue 2808493002: [blink] Request compositing update when canvas hibernates/wakes up. (Closed)
Patch Set: trigger compositing update from Canvas2DLayerBridge instead Created 3 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 /* 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 185 matching lines...) Expand 10 before | Expand all | Expand 10 after
196 int SourceWidth() override { return size_.Width(); } 196 int SourceWidth() override { return size_.Width(); }
197 int SourceHeight() override { return size_.Height(); } 197 int SourceHeight() override { return size_.Height(); }
198 198
199 // CanvasSurfaceLayerBridgeObserver implementation 199 // CanvasSurfaceLayerBridgeObserver implementation
200 void OnWebLayerReplaced() override; 200 void OnWebLayerReplaced() override;
201 201
202 // ImageBufferClient implementation 202 // ImageBufferClient implementation
203 void NotifySurfaceInvalid() override; 203 void NotifySurfaceInvalid() override;
204 void DidDisableAcceleration() override; 204 void DidDisableAcceleration() override;
205 void RestoreCanvasMatrixClipStack(PaintCanvas*) const override; 205 void RestoreCanvasMatrixClipStack(PaintCanvas*) const override;
206 void SetNeedsCompositingUpdate() override;
206 207
207 // ImageBitmapSource implementation 208 // ImageBitmapSource implementation
208 IntSize BitmapSourceSize() const override; 209 IntSize BitmapSourceSize() const override;
209 ScriptPromise CreateImageBitmap(ScriptState*, 210 ScriptPromise CreateImageBitmap(ScriptState*,
210 EventTarget&, 211 EventTarget&,
211 Optional<IntRect> crop_rect, 212 Optional<IntRect> crop_rect,
212 const ImageBitmapOptions&, 213 const ImageBitmapOptions&,
213 ExceptionState&) override; 214 ExceptionState&) override;
214 215
215 // OffscreenCanvasPlaceholder implementation. 216 // OffscreenCanvasPlaceholder implementation.
(...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after
321 std::unique_ptr<CanvasSurfaceLayerBridge> surface_layer_bridge_; 322 std::unique_ptr<CanvasSurfaceLayerBridge> surface_layer_bridge_;
322 323
323 int num_frames_since_last_rendering_mode_switch_; 324 int num_frames_since_last_rendering_mode_switch_;
324 bool pending_rendering_mode_switch_; 325 bool pending_rendering_mode_switch_;
325 bool did_notify_listeners_for_current_frame_ = false; 326 bool did_notify_listeners_for_current_frame_ = false;
326 }; 327 };
327 328
328 } // namespace blink 329 } // namespace blink
329 330
330 #endif // HTMLCanvasElement_h 331 #endif // HTMLCanvasElement_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698