OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 #include "platform/graphics/RecordingImageBufferSurface.h" | 5 #include "platform/graphics/RecordingImageBufferSurface.h" |
6 | 6 |
7 #include "platform/graphics/GraphicsContext.h" | 7 #include "platform/graphics/GraphicsContext.h" |
8 #include "platform/graphics/ImageBuffer.h" | 8 #include "platform/graphics/ImageBuffer.h" |
9 #include "platform/graphics/ImageBufferClient.h" | 9 #include "platform/graphics/ImageBufferClient.h" |
10 #include "platform/graphics/UnacceleratedImageBufferSurface.h" | 10 #include "platform/graphics/UnacceleratedImageBufferSurface.h" |
(...skipping 20 matching lines...) Expand all Loading... |
31 : m_isDirty(false) | 31 : m_isDirty(false) |
32 , m_imageBuffer(imageBuffer) | 32 , m_imageBuffer(imageBuffer) |
33 , m_frameCount(0) | 33 , m_frameCount(0) |
34 { } | 34 { } |
35 | 35 |
36 ~FakeImageBufferClient() override { } | 36 ~FakeImageBufferClient() override { } |
37 | 37 |
38 // ImageBufferClient implementation | 38 // ImageBufferClient implementation |
39 void notifySurfaceInvalid() override { } | 39 void notifySurfaceInvalid() override { } |
40 bool isDirty() override { return m_isDirty; } | 40 bool isDirty() override { return m_isDirty; } |
| 41 void didDisableAcceleration() override { } |
41 void didFinalizeFrame() override | 42 void didFinalizeFrame() override |
42 { | 43 { |
43 if (m_isDirty) { | 44 if (m_isDirty) { |
44 Platform::current()->currentThread()->removeTaskObserver(this); | 45 Platform::current()->currentThread()->removeTaskObserver(this); |
45 m_isDirty = false; | 46 m_isDirty = false; |
46 } | 47 } |
47 ++m_frameCount; | 48 ++m_frameCount; |
48 } | 49 } |
49 | 50 |
50 // TaskObserver implementation | 51 // TaskObserver implementation |
(...skipping 333 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
384 expectDisplayListEnabled(true); | 385 expectDisplayListEnabled(true); |
385 } | 386 } |
386 | 387 |
387 TEST_F(RecordingImageBufferSurfaceTest, testClearRect) | 388 TEST_F(RecordingImageBufferSurfaceTest, testClearRect) |
388 { | 389 { |
389 CALL_TEST_TASK_WRAPPER(testClearRect); | 390 CALL_TEST_TASK_WRAPPER(testClearRect); |
390 expectDisplayListEnabled(true); | 391 expectDisplayListEnabled(true); |
391 } | 392 } |
392 | 393 |
393 } // namespace blink | 394 } // namespace blink |
OLD | NEW |