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

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

Issue 637083002: Sets the default background color of inline signin and user manager to grey (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: nits fixed Created 6 years, 2 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 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 "base/bind_helpers.h" 5 #include "base/bind_helpers.h"
6 #include "base/command_line.h" 6 #include "base/command_line.h"
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "base/message_loop/message_loop.h" 8 #include "base/message_loop/message_loop.h"
9 #include "content/browser/browser_plugin/browser_plugin_guest.h" 9 #include "content/browser/browser_plugin/browser_plugin_guest.h"
10 #include "content/browser/frame_host/render_widget_host_view_guest.h" 10 #include "content/browser/frame_host/render_widget_host_view_guest.h"
(...skipping 336 matching lines...) Expand 10 before | Expand all | Expand 10 after
347 347
348 void RenderWidgetHostViewGuest::CopyFromCompositingSurface( 348 void RenderWidgetHostViewGuest::CopyFromCompositingSurface(
349 const gfx::Rect& src_subrect, 349 const gfx::Rect& src_subrect,
350 const gfx::Size& dst_size, 350 const gfx::Size& dst_size,
351 CopyFromCompositingSurfaceCallback& callback, 351 CopyFromCompositingSurfaceCallback& callback,
352 const SkColorType color_type) { 352 const SkColorType color_type) {
353 CHECK(guest_); 353 CHECK(guest_);
354 guest_->CopyFromCompositingSurface(src_subrect, dst_size, callback); 354 guest_->CopyFromCompositingSurface(src_subrect, dst_size, callback);
355 } 355 }
356 356
357 void RenderWidgetHostViewGuest::SetBackgroundOpaque(bool opaque) { 357 void RenderWidgetHostViewGuest::SetBackgroundColor(SkColor color) {
358 // Content embedders can toggle opaque backgrounds through this API. 358 // Content embedders can toggle opaque backgrounds through this API.
359 // We plumb the value here so that BrowserPlugin updates its compositing 359 // We plumb the value here so that BrowserPlugin updates its compositing
360 // state in response to this change. We also want to preserve this flag 360 // state in response to this change. We also want to preserve this flag
361 // after recovering from a crash so we let BrowserPluginGuest store it. 361 // after recovering from a crash so we let BrowserPluginGuest store it.
362 if (!guest_) 362 if (!guest_)
363 return; 363 return;
364 RenderWidgetHostViewBase::SetBackgroundOpaque(opaque); 364 RenderWidgetHostViewBase::SetBackgroundColor(color);
365 bool opaque = GetBackgroundOpaque();
365 host_->SetBackgroundOpaque(opaque); 366 host_->SetBackgroundOpaque(opaque);
366 guest_->SetContentsOpaque(opaque); 367 guest_->SetContentsOpaque(opaque);
367 } 368 }
368 369
369 bool RenderWidgetHostViewGuest::LockMouse() { 370 bool RenderWidgetHostViewGuest::LockMouse() {
370 return platform_view_->LockMouse(); 371 return platform_view_->LockMouse();
371 } 372 }
372 373
373 void RenderWidgetHostViewGuest::UnlockMouse() { 374 void RenderWidgetHostViewGuest::UnlockMouse() {
374 return platform_view_->UnlockMouse(); 375 return platform_view_->UnlockMouse();
(...skipping 217 matching lines...) Expand 10 before | Expand all | Expand 10 after
592 } 593 }
593 594
594 if (blink::WebInputEvent::isGestureEventType(event->type)) { 595 if (blink::WebInputEvent::isGestureEventType(event->type)) {
595 host_->ForwardGestureEvent( 596 host_->ForwardGestureEvent(
596 *static_cast<const blink::WebGestureEvent*>(event)); 597 *static_cast<const blink::WebGestureEvent*>(event));
597 return; 598 return;
598 } 599 }
599 } 600 }
600 601
601 } // namespace content 602 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698