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

Side by Side Diff: Source/WebKit/chromium/tests/Canvas2DLayerManagerTest.cpp

Issue 14298018: This CL implements the first draft of Canvas 2D Context Attributes, aka getContext('2d', { alpha: f… (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: IDL cleanup Created 7 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 | Annotate | Revision Log
OLDNEW
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
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
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
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698