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 "config.h" | 5 #include "config.h" |
6 #include "core/paint/ViewDisplayList.h" | 6 #include "core/paint/ViewDisplayList.h" |
7 | 7 |
8 #include "core/rendering/RenderObject.h" | 8 #include "core/rendering/RenderObject.h" |
9 #include "core/rendering/RenderView.h" | 9 #include "core/rendering/RenderView.h" |
10 #include "platform/NotImplemented.h" | 10 #include "platform/NotImplemented.h" |
(...skipping 19 matching lines...) Expand all Loading... |
30 OwnPtr<AtomicPaintChunk> paintChunk = adoptPtr(new AtomicPaintChunk(m_contex
t->endRecording(), m_renderer, m_phase)); | 30 OwnPtr<AtomicPaintChunk> paintChunk = adoptPtr(new AtomicPaintChunk(m_contex
t->endRecording(), m_renderer, m_phase)); |
31 ASSERT(m_renderer->view()); | 31 ASSERT(m_renderer->view()); |
32 m_renderer->view()->viewDisplayList().add(paintChunk.release()); | 32 m_renderer->view()->viewDisplayList().add(paintChunk.release()); |
33 } | 33 } |
34 | 34 |
35 const PaintCommandList& ViewDisplayList::paintCommandList() | 35 const PaintCommandList& ViewDisplayList::paintCommandList() |
36 { | 36 { |
37 ASSERT(RuntimeEnabledFeatures::slimmingPaintEnabled()); | 37 ASSERT(RuntimeEnabledFeatures::slimmingPaintEnabled()); |
38 | 38 |
39 updatePaintCommandList(); | 39 updatePaintCommandList(); |
40 return m_paintList; | 40 return m_newPaints; |
41 } | 41 } |
42 | 42 |
43 void ViewDisplayList::add(WTF::PassOwnPtr<AtomicPaintChunk> atomicPaintChunk) | 43 void ViewDisplayList::add(WTF::PassOwnPtr<AtomicPaintChunk> atomicPaintChunk) |
44 { | 44 { |
45 ASSERT(RuntimeEnabledFeatures::slimmingPaintEnabled()); | 45 ASSERT(RuntimeEnabledFeatures::slimmingPaintEnabled()); |
46 m_newPaints.append(atomicPaintChunk); | 46 m_newPaints.append(atomicPaintChunk); |
47 } | 47 } |
48 | 48 |
49 void ViewDisplayList::invalidate(const RenderObject* renderer) | 49 void ViewDisplayList::invalidate(const RenderObject* renderer) |
50 { | 50 { |
(...skipping 11 matching lines...) Expand all Loading... |
62 // appending new items. | 62 // appending new items. |
63 // | 63 // |
64 // The algorithm should be O(|existing paint list| + |newly painted list|). By u
sing the ordering | 64 // The algorithm should be O(|existing paint list| + |newly painted list|). By u
sing the ordering |
65 // implied by the existing paint list, extra treewalks are avoided. | 65 // implied by the existing paint list, extra treewalks are avoided. |
66 void ViewDisplayList::updatePaintCommandList() | 66 void ViewDisplayList::updatePaintCommandList() |
67 { | 67 { |
68 notImplemented(); | 68 notImplemented(); |
69 } | 69 } |
70 | 70 |
71 } // namespace blink | 71 } // namespace blink |
OLD | NEW |