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

Side by Side Diff: cc/resources/rasterizer.cc

Issue 523243002: cc: Generalize raster task notifications (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: tasks_in_set -> tasks Created 6 years, 3 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
« no previous file with comments | « cc/resources/rasterizer.h ('k') | cc/resources/tile_manager.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 "cc/resources/rasterizer.h" 5 #include "cc/resources/rasterizer.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 namespace cc { 9 namespace cc {
10 10
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
49 RasterTask::RasterTask(const Resource* resource, 49 RasterTask::RasterTask(const Resource* resource,
50 ImageDecodeTask::Vector* dependencies) 50 ImageDecodeTask::Vector* dependencies)
51 : resource_(resource) { 51 : resource_(resource) {
52 dependencies_.swap(*dependencies); 52 dependencies_.swap(*dependencies);
53 } 53 }
54 54
55 RasterTask::~RasterTask() {} 55 RasterTask::~RasterTask() {}
56 56
57 RasterTask* RasterTask::AsRasterTask() { return this; } 57 RasterTask* RasterTask::AsRasterTask() { return this; }
58 58
59 RasterTaskQueue::Item::Item(RasterTask* task, bool required_for_activation) 59 RasterTaskQueue::Item::Item(RasterTask* task,
60 : task(task), required_for_activation(required_for_activation) {} 60 const TaskSetCollection& task_sets)
61 : task(task), task_sets(task_sets) {
62 DCHECK(task_sets.any());
63 }
61 64
62 RasterTaskQueue::Item::~Item() {} 65 RasterTaskQueue::Item::~Item() {}
63 66
64 RasterTaskQueue::RasterTaskQueue() { 67 RasterTaskQueue::RasterTaskQueue() {
65 } 68 }
66 69
67 RasterTaskQueue::~RasterTaskQueue() {} 70 RasterTaskQueue::~RasterTaskQueue() {}
68 71
69 void RasterTaskQueue::Swap(RasterTaskQueue* other) { 72 void RasterTaskQueue::Swap(RasterTaskQueue* other) {
70 items.swap(other->items); 73 items.swap(other->items);
71 } 74 }
72 75
73 void RasterTaskQueue::Reset() { 76 void RasterTaskQueue::Reset() {
74 items.clear(); 77 items.clear();
75 } 78 }
76 79
77 } // namespace cc 80 } // namespace cc
OLDNEW
« no previous file with comments | « cc/resources/rasterizer.h ('k') | cc/resources/tile_manager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698