OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 2012 Google Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
6 * are met: | 6 * are met: |
7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
(...skipping 24 matching lines...) Expand all Loading... |
35 | 35 |
36 using namespace WebCore; | 36 using namespace WebCore; |
37 using testing::InSequence; | 37 using testing::InSequence; |
38 using testing::Return; | 38 using testing::Return; |
39 using testing::Test; | 39 using testing::Test; |
40 | 40 |
41 | 41 |
42 class FakeCanvas2DLayerBridge : public Canvas2DLayerBridge { | 42 class FakeCanvas2DLayerBridge : public Canvas2DLayerBridge { |
43 public: | 43 public: |
44 FakeCanvas2DLayerBridge() | 44 FakeCanvas2DLayerBridge() |
45 : Canvas2DLayerBridge(GraphicsContext3DPrivate::createGraphicsContextFro
mWebContext(adoptPtr(new WebKit::FakeWebGraphicsContext3D)), IntSize(1, 1), Sing
leThread, 0) | 45 : Canvas2DLayerBridge(GraphicsContext3DPrivate::createGraphicsContextFro
mWebContext(adoptPtr(new WebKit::FakeWebGraphicsContext3D)), IntSize(1, 1), NonO
paque, SingleThread, 0) |
46 , m_freeableBytes(0) | 46 , m_freeableBytes(0) |
47 , m_freeMemoryIfPossibleCount(0) | 47 , m_freeMemoryIfPossibleCount(0) |
48 , m_flushCount(0) | 48 , m_flushCount(0) |
49 { | 49 { |
50 } | 50 } |
51 | 51 |
52 virtual size_t storageAllocatedForRecording() OVERRIDE | 52 virtual size_t storageAllocatedForRecording() OVERRIDE |
53 { | 53 { |
54 // Because the fake layer has no canvas to query, just | 54 // Because the fake layer has no canvas to query, just |
55 // return status quo. Allocation changes that would normally be | 55 // return status quo. Allocation changes that would normally be |
(...skipping 185 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
241 flushEvictionTest(); | 241 flushEvictionTest(); |
242 } | 242 } |
243 | 243 |
244 TEST_F(Canvas2DLayerManagerTest, testDeferredFrame) | 244 TEST_F(Canvas2DLayerManagerTest, testDeferredFrame) |
245 { | 245 { |
246 deferredFrameTest(); | 246 deferredFrameTest(); |
247 } | 247 } |
248 | 248 |
249 } // namespace | 249 } // namespace |
250 | 250 |
OLD | NEW |