OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/renderer_host/render_widget_host_view_aura.h" | 5 #include "content/browser/renderer_host/render_widget_host_view_aura.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include <tuple> | 10 #include <tuple> |
(...skipping 1719 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1730 ViewMsg_ReclaimCompositorResources::Param params; | 1730 ViewMsg_ReclaimCompositorResources::Param params; |
1731 ViewMsg_ReclaimCompositorResources::Read(msg, ¶ms); | 1731 ViewMsg_ReclaimCompositorResources::Read(msg, ¶ms); |
1732 EXPECT_EQ(0u, std::get<0>(params)); // output_surface_id | 1732 EXPECT_EQ(0u, std::get<0>(params)); // output_surface_id |
1733 EXPECT_FALSE(std::get<1>(params)); // is_swap_ack | 1733 EXPECT_FALSE(std::get<1>(params)); // is_swap_ack |
1734 } | 1734 } |
1735 sink_->ClearMessages(); | 1735 sink_->ClearMessages(); |
1736 | 1736 |
1737 // Report that the surface is drawn to trigger an ACK. | 1737 // Report that the surface is drawn to trigger an ACK. |
1738 cc::Surface* surface = manager->GetSurfaceForId(view_->surface_id()); | 1738 cc::Surface* surface = manager->GetSurfaceForId(view_->surface_id()); |
1739 EXPECT_TRUE(surface); | 1739 EXPECT_TRUE(surface); |
1740 surface->RunDrawCallbacks(cc::SurfaceDrawStatus::DRAWN); | 1740 surface->RunDrawCallbacks(); |
1741 EXPECT_EQ(1u, sink_->message_count()); | 1741 EXPECT_EQ(1u, sink_->message_count()); |
1742 { | 1742 { |
1743 const IPC::Message* msg = sink_->GetMessageAt(0); | 1743 const IPC::Message* msg = sink_->GetMessageAt(0); |
1744 EXPECT_EQ(ViewMsg_ReclaimCompositorResources::ID, msg->type()); | 1744 EXPECT_EQ(ViewMsg_ReclaimCompositorResources::ID, msg->type()); |
1745 ViewMsg_ReclaimCompositorResources::Param params; | 1745 ViewMsg_ReclaimCompositorResources::Param params; |
1746 ViewMsg_ReclaimCompositorResources::Read(msg, ¶ms); | 1746 ViewMsg_ReclaimCompositorResources::Read(msg, ¶ms); |
1747 EXPECT_EQ(1u, std::get<0>(params)); // output_surface_id | 1747 EXPECT_EQ(1u, std::get<0>(params)); // output_surface_id |
1748 EXPECT_EQ(true, std::get<1>(params)); // is_swap_ack | 1748 EXPECT_EQ(true, std::get<1>(params)); // is_swap_ack |
1749 } | 1749 } |
1750 | 1750 |
(...skipping 2715 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4466 // No bounds at index 1. | 4466 // No bounds at index 1. |
4467 EXPECT_FALSE(text_input_client()->GetCompositionCharacterBounds(1, &bound)); | 4467 EXPECT_FALSE(text_input_client()->GetCompositionCharacterBounds(1, &bound)); |
4468 | 4468 |
4469 // Valid bound at index 0. | 4469 // Valid bound at index 0. |
4470 EXPECT_TRUE(text_input_client()->GetCompositionCharacterBounds(0, &bound)); | 4470 EXPECT_TRUE(text_input_client()->GetCompositionCharacterBounds(0, &bound)); |
4471 EXPECT_EQ(4 + (int)index, bound.height()); | 4471 EXPECT_EQ(4 + (int)index, bound.height()); |
4472 } | 4472 } |
4473 } | 4473 } |
4474 | 4474 |
4475 } // namespace content | 4475 } // namespace content |
OLD | NEW |