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

Unified Diff: cc/surfaces/surface_hittest_unittest.cc

Issue 2661543002: Rename LocalFrameId to LocalSurfaceId (Closed)
Patch Set: c Created 3 years, 11 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_factory_unittest.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_hittest_unittest.cc
diff --git a/cc/surfaces/surface_hittest_unittest.cc b/cc/surfaces/surface_hittest_unittest.cc
index 13869fe87144bbb9deebba0c71b3ac04b9996874..d8dca4000b6cff2c8c7f78eac61223974137e24e 100644
--- a/cc/surfaces/surface_hittest_unittest.cc
+++ b/cc/surfaces/surface_hittest_unittest.cc
@@ -74,7 +74,7 @@ TEST(SurfaceHittestTest, Hittest_BadCompositorFrameDoesNotCrash) {
// Add a reference to a non-existant child surface on the root surface.
SurfaceId child_surface_id(
kArbitraryFrameSinkId,
- LocalFrameId(0xdeadbeef, base::UnguessableToken::Create()));
+ LocalSurfaceId(0xdeadbeef, base::UnguessableToken::Create()));
gfx::Rect child_rect(200, 200);
CreateSurfaceDrawQuad(root_pass,
gfx::Transform(),
@@ -84,9 +84,10 @@ TEST(SurfaceHittestTest, Hittest_BadCompositorFrameDoesNotCrash) {
// Submit the root frame.
SurfaceIdAllocator root_allocator;
- LocalFrameId root_local_frame_id = root_allocator.GenerateId();
- SurfaceId root_surface_id(root_frame_sink_id, root_local_frame_id);
- root_factory.SubmitCompositorFrame(root_local_frame_id, std::move(root_frame),
+ LocalSurfaceId root_local_surface_id = root_allocator.GenerateId();
+ SurfaceId root_surface_id(root_frame_sink_id, root_local_surface_id);
+ root_factory.SubmitCompositorFrame(root_local_surface_id,
+ std::move(root_frame),
SurfaceFactory::DrawCallback());
{
@@ -116,9 +117,10 @@ TEST(SurfaceHittestTest, Hittest_SingleSurface) {
// Submit the root frame.
SurfaceIdAllocator root_allocator;
- LocalFrameId root_local_frame_id = root_allocator.GenerateId();
- SurfaceId root_surface_id(root_frame_sink_id, root_local_frame_id);
- root_factory.SubmitCompositorFrame(root_local_frame_id, std::move(root_frame),
+ LocalSurfaceId root_local_surface_id = root_allocator.GenerateId();
+ SurfaceId root_surface_id(root_frame_sink_id, root_local_surface_id);
+ root_factory.SubmitCompositorFrame(root_local_surface_id,
+ std::move(root_frame),
SurfaceFactory::DrawCallback());
TestCase tests[] = {
{
@@ -154,8 +156,8 @@ TEST(SurfaceHittestTest, Hittest_ChildSurface) {
// Add a reference to the child surface on the root surface.
SurfaceIdAllocator child_allocator;
- LocalFrameId child_local_frame_id = child_allocator.GenerateId();
- SurfaceId child_surface_id(child_frame_sink_id, child_local_frame_id);
+ LocalSurfaceId child_local_surface_id = child_allocator.GenerateId();
+ SurfaceId child_surface_id(child_frame_sink_id, child_local_surface_id);
gfx::Rect child_rect(200, 200);
CreateSurfaceDrawQuad(root_pass,
gfx::Transform(1.0f, 0.0f, 0.0f, 50.0f,
@@ -168,9 +170,10 @@ TEST(SurfaceHittestTest, Hittest_ChildSurface) {
// Submit the root frame.
SurfaceIdAllocator root_allocator;
- LocalFrameId root_local_frame_id = root_allocator.GenerateId();
- SurfaceId root_surface_id(root_frame_sink_id, root_local_frame_id);
- root_factory.SubmitCompositorFrame(root_local_frame_id, std::move(root_frame),
+ LocalSurfaceId root_local_surface_id = root_allocator.GenerateId();
+ SurfaceId root_surface_id(root_frame_sink_id, root_local_surface_id);
+ root_factory.SubmitCompositorFrame(root_local_surface_id,
+ std::move(root_frame),
SurfaceFactory::DrawCallback());
// Creates a child surface.
@@ -188,7 +191,7 @@ TEST(SurfaceHittestTest, Hittest_ChildSurface) {
root_rect, child_solid_quad_rect);
// Submit the frame.
- child_factory.SubmitCompositorFrame(child_local_frame_id,
+ child_factory.SubmitCompositorFrame(child_local_surface_id,
std::move(child_frame),
SurfaceFactory::DrawCallback());
@@ -243,7 +246,8 @@ TEST(SurfaceHittestTest, Hittest_ChildSurface) {
root_rect,
child_rect,
child_surface_id);
- root_factory.SubmitCompositorFrame(root_local_frame_id, std::move(root_frame),
+ root_factory.SubmitCompositorFrame(root_local_surface_id,
+ std::move(root_frame),
SurfaceFactory::DrawCallback());
// Verify that point (100, 100) no longer falls on the child surface.
@@ -299,8 +303,8 @@ TEST(SurfaceHittestTest, Hittest_InvalidRenderPassDrawQuad) {
// Add a reference to the child surface on the root surface.
SurfaceIdAllocator child_allocator;
- LocalFrameId child_local_frame_id = child_allocator.GenerateId();
- SurfaceId child_surface_id(child_frame_sink_id, child_local_frame_id);
+ LocalSurfaceId child_local_surface_id = child_allocator.GenerateId();
+ SurfaceId child_surface_id(child_frame_sink_id, child_local_surface_id);
gfx::Rect child_rect(200, 200);
CreateSurfaceDrawQuad(root_pass,
gfx::Transform(1.0f, 0.0f, 0.0f, 50.0f,
@@ -313,9 +317,10 @@ TEST(SurfaceHittestTest, Hittest_InvalidRenderPassDrawQuad) {
// Submit the root frame.
SurfaceIdAllocator root_allocator;
- LocalFrameId root_local_frame_id = root_allocator.GenerateId();
- SurfaceId root_surface_id(root_frame_sink_id, root_local_frame_id);
- root_factory.SubmitCompositorFrame(root_local_frame_id, std::move(root_frame),
+ LocalSurfaceId root_local_surface_id = root_allocator.GenerateId();
+ SurfaceId root_surface_id(root_frame_sink_id, root_local_surface_id);
+ root_factory.SubmitCompositorFrame(root_local_surface_id,
+ std::move(root_frame),
SurfaceFactory::DrawCallback());
// Creates a child surface.
@@ -333,7 +338,7 @@ TEST(SurfaceHittestTest, Hittest_InvalidRenderPassDrawQuad) {
child_solid_quad_rect);
// Submit the frame.
- child_factory.SubmitCompositorFrame(child_local_frame_id,
+ child_factory.SubmitCompositorFrame(child_local_surface_id,
std::move(child_frame),
SurfaceFactory::DrawCallback());
@@ -430,9 +435,9 @@ TEST(SurfaceHittestTest, Hittest_RenderPassDrawQuad) {
// Submit the root frame.
SurfaceIdAllocator root_allocator;
- LocalFrameId root_local_frame_id = root_allocator.GenerateId();
- SurfaceId root_surface_id(root_frame_sink_id, root_local_frame_id);
- factory.SubmitCompositorFrame(root_local_frame_id, std::move(root_frame),
+ LocalSurfaceId root_local_surface_id = root_allocator.GenerateId();
+ SurfaceId root_surface_id(root_frame_sink_id, root_local_surface_id);
+ factory.SubmitCompositorFrame(root_local_surface_id, std::move(root_frame),
SurfaceFactory::DrawCallback());
TestCase tests[] = {
@@ -504,8 +509,8 @@ TEST(SurfaceHittestTest, Hittest_SingleSurface_WithInsetsDelegate) {
// Add a reference to the child surface on the root surface.
SurfaceIdAllocator child_allocator;
- LocalFrameId child_local_frame_id = child_allocator.GenerateId();
- SurfaceId child_surface_id(child_frame_sink_id, child_local_frame_id);
+ LocalSurfaceId child_local_surface_id = child_allocator.GenerateId();
+ SurfaceId child_surface_id(child_frame_sink_id, child_local_surface_id);
gfx::Rect child_rect(200, 200);
CreateSurfaceDrawQuad(
root_pass,
@@ -517,9 +522,10 @@ TEST(SurfaceHittestTest, Hittest_SingleSurface_WithInsetsDelegate) {
// Submit the root frame.
SurfaceIdAllocator root_allocator;
- LocalFrameId root_local_frame_id = root_allocator.GenerateId();
- SurfaceId root_surface_id(root_frame_sink_id, root_local_frame_id);
- root_factory.SubmitCompositorFrame(root_local_frame_id, std::move(root_frame),
+ LocalSurfaceId root_local_surface_id = root_allocator.GenerateId();
+ SurfaceId root_surface_id(root_frame_sink_id, root_local_surface_id);
+ root_factory.SubmitCompositorFrame(root_local_surface_id,
+ std::move(root_frame),
SurfaceFactory::DrawCallback());
// Creates a child surface.
@@ -535,7 +541,7 @@ TEST(SurfaceHittestTest, Hittest_SingleSurface_WithInsetsDelegate) {
root_rect, child_solid_quad_rect);
// Submit the frame.
- child_factory.SubmitCompositorFrame(child_local_frame_id,
+ child_factory.SubmitCompositorFrame(child_local_surface_id,
std::move(child_frame),
SurfaceFactory::DrawCallback());
« no previous file with comments | « cc/surfaces/surface_factory_unittest.cc ('k') | cc/surfaces/surface_id.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698