OLD | NEW |
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 21 matching lines...) Expand all Loading... |
32 namespace { | 32 namespace { |
33 class MockRenderWidgetHostDelegate : public RenderWidgetHostDelegate { | 33 class MockRenderWidgetHostDelegate : public RenderWidgetHostDelegate { |
34 public: | 34 public: |
35 MockRenderWidgetHostDelegate() {} | 35 MockRenderWidgetHostDelegate() {} |
36 ~MockRenderWidgetHostDelegate() override {} | 36 ~MockRenderWidgetHostDelegate() override {} |
37 private: | 37 private: |
38 void Cut() override {} | 38 void Cut() override {} |
39 void Copy() override {} | 39 void Copy() override {} |
40 void Paste() override {} | 40 void Paste() override {} |
41 void SelectAll() override {} | 41 void SelectAll() override {} |
| 42 bool HasMouseLock(RenderWidgetHostImpl*) override { return false; } |
42 }; | 43 }; |
43 | 44 |
44 class MockCrossProcessFrameConnector : public CrossProcessFrameConnector { | 45 class MockCrossProcessFrameConnector : public CrossProcessFrameConnector { |
45 public: | 46 public: |
46 MockCrossProcessFrameConnector() | 47 MockCrossProcessFrameConnector() |
47 : CrossProcessFrameConnector(nullptr), last_scale_factor_received_(0.f) {} | 48 : CrossProcessFrameConnector(nullptr), last_scale_factor_received_(0.f) {} |
48 ~MockCrossProcessFrameConnector() override {} | 49 ~MockCrossProcessFrameConnector() override {} |
49 | 50 |
50 void SetChildFrameSurface(const cc::SurfaceId& surface_id, | 51 void SetChildFrameSurface(const cc::SurfaceId& surface_id, |
51 const gfx::Size& frame_size, | 52 const gfx::Size& frame_size, |
(...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
171 | 172 |
172 // Surface ID should have been passed to CrossProcessFrameConnector to | 173 // Surface ID should have been passed to CrossProcessFrameConnector to |
173 // be sent to the embedding renderer. | 174 // be sent to the embedding renderer. |
174 EXPECT_EQ(id, test_frame_connector_->last_surface_id_received_); | 175 EXPECT_EQ(id, test_frame_connector_->last_surface_id_received_); |
175 EXPECT_EQ(view_size, test_frame_connector_->last_frame_size_received_); | 176 EXPECT_EQ(view_size, test_frame_connector_->last_frame_size_received_); |
176 EXPECT_EQ(scale_factor, test_frame_connector_->last_scale_factor_received_); | 177 EXPECT_EQ(scale_factor, test_frame_connector_->last_scale_factor_received_); |
177 } | 178 } |
178 } | 179 } |
179 | 180 |
180 } // namespace content | 181 } // namespace content |
OLD | NEW |