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

Side by Side Diff: content/public/browser/browser_plugin_guest_delegate.h

Issue 564973004: Move ContentWindow from BrowserPlugin To GuestView (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Addressed comments + fixed teardown bug Created 6 years, 3 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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 #ifndef CONTENT_PUBLIC_BROWSER_BROWSER_PLUGIN_GUEST_DELEGATE_H_ 5 #ifndef CONTENT_PUBLIC_BROWSER_BROWSER_PLUGIN_GUEST_DELEGATE_H_
6 #define CONTENT_PUBLIC_BROWSER_BROWSER_PLUGIN_GUEST_DELEGATE_H_ 6 #define CONTENT_PUBLIC_BROWSER_BROWSER_PLUGIN_GUEST_DELEGATE_H_
7 7
8 #include "base/callback_forward.h" 8 #include "base/callback_forward.h"
9 #include "base/process/kill.h" 9 #include "base/process/kill.h"
10 #include "content/common/content_export.h" 10 #include "content/common/content_export.h"
(...skipping 10 matching lines...) Expand all
21 namespace content { 21 namespace content {
22 22
23 // Objects implement this interface to get notified about changes in the guest 23 // Objects implement this interface to get notified about changes in the guest
24 // WebContents and to provide necessary functionality. 24 // WebContents and to provide necessary functionality.
25 class CONTENT_EXPORT BrowserPluginGuestDelegate { 25 class CONTENT_EXPORT BrowserPluginGuestDelegate {
26 public: 26 public:
27 virtual ~BrowserPluginGuestDelegate() {} 27 virtual ~BrowserPluginGuestDelegate() {}
28 28
29 // Notification that the embedder will begin attachment. This is called 29 // Notification that the embedder will begin attachment. This is called
30 // prior to resuming resource loads. 30 // prior to resuming resource loads.
31 virtual void WillAttach(content::WebContents* embedder_web_contents) {} 31 virtual void WillAttach(content::WebContents* embedder_web_contents,
32 int element_instance_id) {}
Charlie Reis 2014/09/17 21:46:43 Please document these new parameters, since this i
Fady Samuel 2014/09/17 22:05:46 Done.
32 33
33 virtual WebContents* CreateNewGuestWindow( 34 virtual WebContents* CreateNewGuestWindow(
34 const WebContents::CreateParams& create_params); 35 const WebContents::CreateParams& create_params);
35 36
36 // Notification that the embedder has completed attachment. 37 // Notification that the embedder has completed attachment.
37 virtual void DidAttach() {} 38 virtual void DidAttach(int guest_routing_id) {}
38 39
39 // Notification that the BrowserPlugin has resized. 40 // Notification that the BrowserPlugin has resized.
40 virtual void ElementSizeChanged(const gfx::Size& old_size, 41 virtual void ElementSizeChanged(const gfx::Size& old_size,
41 const gfx::Size& new_size) {} 42 const gfx::Size& new_size) {}
42 43
43 // Notifies that the content size of the guest has changed. 44 // Notifies that the content size of the guest has changed.
44 // Note: In autosize mode, it si possible that the guest size may not match 45 // Note: In autosize mode, it si possible that the guest size may not match
45 // the element size. 46 // the element size.
46 virtual void GuestSizeChanged(const gfx::Size& old_size, 47 virtual void GuestSizeChanged(const gfx::Size& old_size,
47 const gfx::Size& new_size) {} 48 const gfx::Size& new_size) {}
(...skipping 12 matching lines...) Expand all
60 // Registers a |callback| with the delegate that the delegate would call when 61 // Registers a |callback| with the delegate that the delegate would call when
61 // it is about to be destroyed. 62 // it is about to be destroyed.
62 typedef base::Callback<void()> DestructionCallback; 63 typedef base::Callback<void()> DestructionCallback;
63 virtual void RegisterDestructionCallback( 64 virtual void RegisterDestructionCallback(
64 const DestructionCallback& callback) {} 65 const DestructionCallback& callback) {}
65 }; 66 };
66 67
67 } // namespace content 68 } // namespace content
68 69
69 #endif // CONTENT_PUBLIC_BROWSER_BROWSER_PLUGIN_GUEST_DELEGATE_H_ 70 #endif // CONTENT_PUBLIC_BROWSER_BROWSER_PLUGIN_GUEST_DELEGATE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698