| Index: content/browser/renderer_host/render_widget_host_unittest.cc
|
| diff --git a/content/browser/renderer_host/render_widget_host_unittest.cc b/content/browser/renderer_host/render_widget_host_unittest.cc
|
| index f6bb1084ff210c440c59a5a89af27a3a772275c5..e58133d150ef5e6c0fe661b8c6876e5081c99fd1 100644
|
| --- a/content/browser/renderer_host/render_widget_host_unittest.cc
|
| +++ b/content/browser/renderer_host/render_widget_host_unittest.cc
|
| @@ -83,7 +83,7 @@ class RenderWidgetHostProcess : public MockRenderProcessHost {
|
| // message reply. False implies timeout.
|
| bool update_msg_should_reply_;
|
|
|
| - // Indicates the flags that should be sent with a the repaint request. This
|
| + // Indicates the flags that should be sent with a repaint request. This
|
| // only has an effect when update_msg_should_reply_ is true.
|
| int update_msg_reply_flags_;
|
|
|
| @@ -106,6 +106,7 @@ void RenderWidgetHostProcess::InitUpdateRectParams(
|
| params->view_size = gfx::Size(w, h);
|
| params->flags = update_msg_reply_flags_;
|
| params->needs_ack = true;
|
| + params->scale_factor = 1;
|
| }
|
|
|
| bool RenderWidgetHostProcess::WaitForBackingStoreMsg(
|
| @@ -1091,3 +1092,13 @@ TEST_F(RenderWidgetHostTest, MultipleInputEvents) {
|
| MessageLoop::current()->Run();
|
| EXPECT_TRUE(host_->unresponsive_timer_fired());
|
| }
|
| +
|
| +TEST_F(RenderWidgetHostTest, IncorrectBitmapScaleFactor) {
|
| + ViewHostMsg_UpdateRect_Params params;
|
| + process_->InitUpdateRectParams(¶ms);
|
| + params.scale_factor = params.scale_factor * 2;
|
| +
|
| + EXPECT_EQ(0, process_->bad_msg_count());
|
| + host_->OnMsgUpdateRect(params);
|
| + EXPECT_EQ(1, process_->bad_msg_count());
|
| +}
|
|
|