summaryrefslogtreecommitdiffstats
path: root/cc
diff options
context:
space:
mode:
authorreveman@google.com <reveman@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2012-11-28 06:49:18 +0000
committerreveman@google.com <reveman@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2012-11-28 06:49:18 +0000
commit6edd39e198f68dca540598a5e3f90b92de5fcaf8 (patch)
tree592e0fdc415bca5440fbb4ac85ea3785ae6df4ea /cc
parentc59e6605f2749f5b3bb439826252bb1036dce0d0 (diff)
downloadchromium_src-6edd39e198f68dca540598a5e3f90b92de5fcaf8.zip
chromium_src-6edd39e198f68dca540598a5e3f90b92de5fcaf8.tar.gz
chromium_src-6edd39e198f68dca540598a5e3f90b92de5fcaf8.tar.bz2
cc: Schedule redraw when tile initialization completes.
BUG=155209 Review URL: https://codereview.chromium.org/11415170 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@169871 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'cc')
-rw-r--r--cc/layer_tree_host_impl.cc6
-rw-r--r--cc/layer_tree_host_impl.h1
-rw-r--r--cc/test/fake_tile_manager_client.h1
-rw-r--r--cc/tile_manager.cc2
-rw-r--r--cc/tile_manager.h1
5 files changed, 11 insertions, 0 deletions
diff --git a/cc/layer_tree_host_impl.cc b/cc/layer_tree_host_impl.cc
index 48bc1fb..2426e01 100644
--- a/cc/layer_tree_host_impl.cc
+++ b/cc/layer_tree_host_impl.cc
@@ -783,6 +783,12 @@ void LayerTreeHostImpl::ScheduleManageTiles()
m_client->setNeedsManageTilesOnImplThread();
}
+void LayerTreeHostImpl::ScheduleRedraw()
+{
+ if (m_client)
+ m_client->setNeedsRedrawOnImplThread();
+}
+
void LayerTreeHostImpl::setManagedMemoryPolicy(const ManagedMemoryPolicy& policy)
{
if (m_managedMemoryPolicy == policy)
diff --git a/cc/layer_tree_host_impl.h b/cc/layer_tree_host_impl.h
index 736090d..c05c30d 100644
--- a/cc/layer_tree_host_impl.h
+++ b/cc/layer_tree_host_impl.h
@@ -174,6 +174,7 @@ public:
// TileManagerClient implementation.
virtual void ScheduleManageTiles() OVERRIDE;
+ virtual void ScheduleRedraw() OVERRIDE;
// WebCompositorOutputSurfaceClient implementation.
virtual void onVSyncParametersChanged(double monotonicTimebase, double intervalInSeconds) OVERRIDE;
diff --git a/cc/test/fake_tile_manager_client.h b/cc/test/fake_tile_manager_client.h
index 6e94924..8458350 100644
--- a/cc/test/fake_tile_manager_client.h
+++ b/cc/test/fake_tile_manager_client.h
@@ -15,6 +15,7 @@ class FakeTileManagerClient : public TileManagerClient {
// TileManagerClient implementation.
virtual void ScheduleManageTiles() OVERRIDE {}
+ virtual void ScheduleRedraw() OVERRIDE {}
};
} // namespace cc
diff --git a/cc/tile_manager.cc b/cc/tile_manager.cc
index 2820a42..e31cc28 100644
--- a/cc/tile_manager.cc
+++ b/cc/tile_manager.cc
@@ -357,6 +357,8 @@ void TileManager::DidFinishTileInitialization(
DCHECK(!managed_tile_state.resource_id);
managed_tile_state.resource_id = resource_id;
managed_tile_state.resource_id_is_being_initialized = false;
+ // TODO(qinmin): Make this conditional on managed_tile_state.bin == NOW_BIN.
+ client_->ScheduleRedraw();
}
}
diff --git a/cc/tile_manager.h b/cc/tile_manager.h
index 56ea032..83e8b75 100644
--- a/cc/tile_manager.h
+++ b/cc/tile_manager.h
@@ -25,6 +25,7 @@ class ResourceProvider;
class CC_EXPORT TileManagerClient {
public:
virtual void ScheduleManageTiles() = 0;
+ virtual void ScheduleRedraw() = 0;
protected:
virtual ~TileManagerClient() {}