| Index: cc/raster/tile_task_runner.h
 | 
| diff --git a/cc/raster/tile_task_runner.h b/cc/raster/tile_task_runner.h
 | 
| index 8c3bb341594312dee8f977a450e9d4f02d904598..281226534446fa25f9007ea2b2ad07c630160c98 100644
 | 
| --- a/cc/raster/tile_task_runner.h
 | 
| +++ b/cc/raster/tile_task_runner.h
 | 
| @@ -19,6 +19,9 @@ class RasterTask;
 | 
|  class Resource;
 | 
|  class RasterBuffer;
 | 
|  
 | 
| +const TaskTypeId kRasterTaskTypeId = kDefaultTaskTypeId + 1;
 | 
| +const TaskTypeId kImageDecodeTaskTypeId = kDefaultTaskTypeId + 2;
 | 
| +
 | 
|  class CC_EXPORT TileTaskClient {
 | 
|   public:
 | 
|    virtual std::unique_ptr<RasterBuffer> AcquireBufferForRaster(
 | 
| @@ -35,14 +38,6 @@ class CC_EXPORT TileTask : public Task {
 | 
|   public:
 | 
|    typedef std::vector<scoped_refptr<TileTask>> Vector;
 | 
|  
 | 
| -  virtual void ScheduleOnOriginThread(TileTaskClient* client) = 0;
 | 
| -  virtual void CompleteOnOriginThread(TileTaskClient* client) = 0;
 | 
| -
 | 
| -  void WillSchedule();
 | 
| -  void DidSchedule();
 | 
| -  bool HasBeenScheduled() const;
 | 
| -
 | 
| -  void WillComplete();
 | 
|    void DidComplete();
 | 
|    bool HasCompleted() const;
 | 
|  
 | 
| @@ -50,7 +45,6 @@ class CC_EXPORT TileTask : public Task {
 | 
|    TileTask();
 | 
|    ~TileTask() override;
 | 
|  
 | 
| -  bool did_schedule_;
 | 
|    bool did_complete_;
 | 
|  };
 | 
|  
 | 
| @@ -78,13 +72,13 @@ class CC_EXPORT RasterTask : public TileTask {
 | 
|  };
 | 
|  
 | 
|  // This interface can be used to schedule and run tile tasks.
 | 
| -// The client can call CheckForCompletedTasks() at any time to dispatch
 | 
| -// pending completion callbacks for all tasks that have finished running.
 | 
| +// The client can call CollectCompletedTasks() at any time to process
 | 
| +// all completed tasks at the moment that have finished running or cancelled.
 | 
|  class CC_EXPORT TileTaskRunner {
 | 
|   public:
 | 
|    // Tells the worker pool to shutdown after canceling all previously scheduled
 | 
|    // tasks. Reply callbacks are still guaranteed to run when
 | 
| -  // CheckForCompletedTasks() is called.
 | 
| +  // CollectCompletedTasks() is called.
 | 
|    virtual void Shutdown() = 0;
 | 
|  
 | 
|    // Schedule running of tile tasks in |graph| and all dependencies.
 | 
| @@ -94,8 +88,8 @@ class CC_EXPORT TileTaskRunner {
 | 
|    // ScheduleTasks().
 | 
|    virtual void ScheduleTasks(TaskGraph* graph) = 0;
 | 
|  
 | 
| -  // Check for completed tasks and dispatch reply callbacks.
 | 
| -  virtual void CheckForCompletedTasks() = 0;
 | 
| +  // Collect completed tasks.
 | 
| +  virtual void CollectCompletedTasks(Task::Vector* completed_tasks) = 0;
 | 
|  
 | 
|    // Returns the format to use for the tiles.
 | 
|    virtual ResourceFormat GetResourceFormat(bool must_support_alpha) const = 0;
 | 
| @@ -103,6 +97,9 @@ class CC_EXPORT TileTaskRunner {
 | 
|    // Determine if the resource requires swizzling.
 | 
|    virtual bool GetResourceRequiresSwizzle(bool must_support_alpha) const = 0;
 | 
|  
 | 
| +  // TODO(prashant.n): This will be removed soon. Don't use this.
 | 
| +  virtual TileTaskClient* AsTileTaskClient() = 0;
 | 
| +
 | 
|   protected:
 | 
|    // Check if resource format matches output format.
 | 
|    static bool ResourceFormatRequiresSwizzle(ResourceFormat format);
 | 
| 
 |