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

Side by Side Diff: extensions/browser/guest_view/guest_view_base.cc

Issue 921473006: GuestView: Fix message routing across embedder navigations (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Updated comments CQ'ing Created 5 years, 10 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 "extensions/browser/guest_view/guest_view_base.h" 5 #include "extensions/browser/guest_view/guest_view_base.h"
6 6
7 #include "base/lazy_instance.h" 7 #include "base/lazy_instance.h"
8 #include "base/strings/utf_string_conversions.h" 8 #include "base/strings/utf_string_conversions.h"
9 #include "components/ui/zoom/page_zoom.h" 9 #include "components/ui/zoom/page_zoom.h"
10 #include "components/ui/zoom/zoom_controller.h" 10 #include "components/ui/zoom/zoom_controller.h"
(...skipping 377 matching lines...) Expand 10 before | Expand all | Expand 10 after
388 388
389 // Inform the associated GuestViewContainer that the contentWindow is ready. 389 // Inform the associated GuestViewContainer that the contentWindow is ready.
390 embedder_web_contents()->Send(new GuestViewMsg_GuestAttached( 390 embedder_web_contents()->Send(new GuestViewMsg_GuestAttached(
391 element_instance_id_, 391 element_instance_id_,
392 guest_proxy_routing_id)); 392 guest_proxy_routing_id));
393 393
394 SendQueuedEvents(); 394 SendQueuedEvents();
395 } 395 }
396 396
397 void GuestViewBase::DidDetach() { 397 void GuestViewBase::DidDetach() {
398 GuestViewManager::FromBrowserContext(browser_context_)->DetachGuest( 398 GuestViewManager::FromBrowserContext(browser_context_)->DetachGuest(this);
399 this, element_instance_id_);
400 StopTrackingEmbedderZoomLevel(); 399 StopTrackingEmbedderZoomLevel();
401 owner_web_contents()->Send(new GuestViewMsg_GuestDetached( 400 owner_web_contents()->Send(new GuestViewMsg_GuestDetached(
402 element_instance_id_)); 401 element_instance_id_));
403 element_instance_id_ = guestview::kInstanceIDNone; 402 element_instance_id_ = guestview::kInstanceIDNone;
404 } 403 }
405 404
406 void GuestViewBase::ElementSizeChanged(const gfx::Size& size) { 405 void GuestViewBase::ElementSizeChanged(const gfx::Size& size) {
407 if (size.IsEmpty()) 406 if (size.IsEmpty())
408 return; 407 return;
409 408
(...skipping 373 matching lines...) Expand 10 before | Expand all | Expand 10 after
783 void GuestViewBase::RegisterGuestViewTypes() { 782 void GuestViewBase::RegisterGuestViewTypes() {
784 AppViewGuest::Register(); 783 AppViewGuest::Register();
785 ExtensionOptionsGuest::Register(); 784 ExtensionOptionsGuest::Register();
786 ExtensionViewGuest::Register(); 785 ExtensionViewGuest::Register();
787 MimeHandlerViewGuest::Register(); 786 MimeHandlerViewGuest::Register();
788 SurfaceWorkerGuest::Register(); 787 SurfaceWorkerGuest::Register();
789 WebViewGuest::Register(); 788 WebViewGuest::Register();
790 } 789 }
791 790
792 } // namespace extensions 791 } // namespace extensions
OLDNEW
« no previous file with comments | « content/public/browser/browser_plugin_guest_manager.cc ('k') | extensions/browser/guest_view/guest_view_manager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698