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

Unified Diff: services/ui/surfaces/display_compositor.cc

Issue 2547243002: Set device scale factor in CompositorFrame and scale frame size in WS. (Closed)
Patch Set: test Created 4 years 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
Index: services/ui/surfaces/display_compositor.cc
diff --git a/services/ui/surfaces/display_compositor.cc b/services/ui/surfaces/display_compositor.cc
index 772fbd009153230795c5c4144ad74681462bcdaf..52e0bc9ffdcf588e455a006f12f21c451eebcf85 100644
--- a/services/ui/surfaces/display_compositor.cc
+++ b/services/ui/surfaces/display_compositor.cc
@@ -246,6 +246,7 @@ void DisplayCompositor::OnSurfaceCreated(const cc::SurfaceId& surface_id,
const gfx::Size& frame_size,
float device_scale_factor) {
DCHECK(thread_checker_.CalledOnValidThread());
+ DCHECK_GT(device_scale_factor, 0.0f);
// We can get into a situation where multiple CompositorFrames arrive for a
// CompositorFrameSink before the DisplayCompositorClient can add any
// references for the frame. When the second frame with a new size arrives,
« no previous file with comments | « content/browser/compositor/mus_browser_compositor_output_surface.cc ('k') | services/ui/ws/frame_generator.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698