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

Side by Side Diff: content/browser/frame_host/render_widget_host_view_child_frame_unittest.cc

Issue 2563783002: ui + mus: Split ContextFactory into ContextFactory(Client) and ContextFactoryPrivate (Closed)
Patch Set: Restore mash 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 unified diff | Download patch
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 "content/browser/frame_host/render_widget_host_view_child_frame.h" 5 #include "content/browser/frame_host/render_widget_host_view_child_frame.h"
6 6
7 #include <stdint.h> 7 #include <stdint.h>
8 8
9 #include <utility> 9 #include <utility>
10 10
(...skipping 165 matching lines...) Expand 10 before | Expand all | Expand 10 after
176 view_->Show(); 176 view_->Show();
177 177
178 view_->OnSwapCompositorFrame( 178 view_->OnSwapCompositorFrame(
179 0, CreateDelegatedFrame(scale_factor, view_size, view_rect)); 179 0, CreateDelegatedFrame(scale_factor, view_size, view_rect));
180 180
181 cc::SurfaceId id = GetSurfaceId(); 181 cc::SurfaceId id = GetSurfaceId();
182 if (id.is_valid()) { 182 if (id.is_valid()) {
183 #if !defined(OS_ANDROID) 183 #if !defined(OS_ANDROID)
184 ImageTransportFactory* factory = ImageTransportFactory::GetInstance(); 184 ImageTransportFactory* factory = ImageTransportFactory::GetInstance();
185 cc::SurfaceManager* manager = 185 cc::SurfaceManager* manager =
186 factory->GetContextFactory()->GetSurfaceManager(); 186 factory->GetContextFactoryPrivate()->GetSurfaceManager();
187 cc::Surface* surface = manager->GetSurfaceForId(id); 187 cc::Surface* surface = manager->GetSurfaceForId(id);
188 EXPECT_TRUE(surface); 188 EXPECT_TRUE(surface);
189 // There should be a SurfaceSequence created by the RWHVChildFrame. 189 // There should be a SurfaceSequence created by the RWHVChildFrame.
190 EXPECT_EQ(1u, surface->GetDestructionDependencyCount()); 190 EXPECT_EQ(1u, surface->GetDestructionDependencyCount());
191 #endif 191 #endif
192 192
193 // Surface ID should have been passed to CrossProcessFrameConnector to 193 // Surface ID should have been passed to CrossProcessFrameConnector to
194 // be sent to the embedding renderer. 194 // be sent to the embedding renderer.
195 EXPECT_EQ(id, test_frame_connector_->last_surface_id_received_); 195 EXPECT_EQ(id, test_frame_connector_->last_surface_id_received_);
196 EXPECT_EQ(view_size, test_frame_connector_->last_frame_size_received_); 196 EXPECT_EQ(view_size, test_frame_connector_->last_frame_size_received_);
197 EXPECT_EQ(scale_factor, test_frame_connector_->last_scale_factor_received_); 197 EXPECT_EQ(scale_factor, test_frame_connector_->last_scale_factor_received_);
198 } 198 }
199 } 199 }
200 200
201 } // namespace content 201 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/context_factory.cc ('k') | content/browser/frame_host/render_widget_host_view_guest_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698