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

Unified Diff: cc/surfaces/surface_factory.cc

Issue 2369793002: WIP: Propagate SurfaceID up window tree hierarchy
Patch Set: Fix input events: EventDispatcher ignores container windows Created 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « cc/surfaces/surface.cc ('k') | cc/surfaces/surface_id.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/surfaces/surface_factory.cc
diff --git a/cc/surfaces/surface_factory.cc b/cc/surfaces/surface_factory.cc
index 18cd8b33abd9726f46ca57c4de062c2f42e20fdf..9bea80fe3ab0c853e51e2ecbd19f07ef195e70d8 100644
--- a/cc/surfaces/surface_factory.cc
+++ b/cc/surfaces/surface_factory.cc
@@ -73,6 +73,14 @@ void SurfaceFactory::SubmitCompositorFrame(const SurfaceId& surface_id,
OwningSurfaceMap::iterator it = surface_map_.find(surface_id);
DCHECK(it != surface_map_.end());
DCHECK(it->second->factory().get() == this);
+ const CompositorFrame& previous_frame = it->second->GetEligibleFrame();
+ if (!previous_frame.delegated_frame_data) {
+ gfx::Size frame_size =
+ frame.delegated_frame_data->render_pass_list[0]->output_rect.size();
+ float device_scale_factor = frame.metadata.device_scale_factor;
+ manager_->DidCreateNewSurface(frame_size, device_scale_factor,
+ it->second->surface_id());
+ }
it->second->QueueFrame(std::move(frame), callback);
if (!manager_->SurfaceModified(surface_id)) {
TRACE_EVENT_INSTANT0("cc", "Damage not visible.", TRACE_EVENT_SCOPE_THREAD);
« no previous file with comments | « cc/surfaces/surface.cc ('k') | cc/surfaces/surface_id.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698