OLD | NEW |
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 "base/strings/string16.h" | 10 #include "base/strings/string16.h" |
(...skipping 21 matching lines...) Expand all Loading... |
32 | 32 |
33 // Request the delegate to close this guest, and do whatever cleanup it needs | 33 // Request the delegate to close this guest, and do whatever cleanup it needs |
34 // to do. | 34 // to do. |
35 virtual void Close() {} | 35 virtual void Close() {} |
36 | 36 |
37 // Informs the delegate that the guest render process is gone. |status| | 37 // Informs the delegate that the guest render process is gone. |status| |
38 // indicates whether the guest was killed, crashed, or was terminated | 38 // indicates whether the guest was killed, crashed, or was terminated |
39 // gracefully. | 39 // gracefully. |
40 virtual void GuestProcessGone(base::TerminationStatus status) {} | 40 virtual void GuestProcessGone(base::TerminationStatus status) {} |
41 | 41 |
42 // Informs the delegate that the embedder has been destroyed. | |
43 virtual void EmbedderDestroyed() {} | |
44 | |
45 virtual bool HandleKeyboardEvent(const NativeWebKeyboardEvent& event); | 42 virtual bool HandleKeyboardEvent(const NativeWebKeyboardEvent& event); |
46 | 43 |
47 // Notification that a load in the guest resulted in abort. Note that |url| | 44 // Notification that a load in the guest resulted in abort. Note that |url| |
48 // may be invalid. | 45 // may be invalid. |
49 virtual void LoadAbort(bool is_top_level, | 46 virtual void LoadAbort(bool is_top_level, |
50 const GURL& url, | 47 const GURL& url, |
51 const std::string& error_type) {} | 48 const std::string& error_type) {} |
52 | 49 |
53 // Notification that the page has made some progress loading. |progress| is a | 50 // Notification that the page has made some progress loading. |progress| is a |
54 // value between 0.0 (nothing loaded) and 1.0 (page loaded completely). | 51 // value between 0.0 (nothing loaded) and 1.0 (page loaded completely). |
(...skipping 19 matching lines...) Expand all Loading... |
74 const PermissionResponseCallback& callback); | 71 const PermissionResponseCallback& callback); |
75 | 72 |
76 // Notifies that the content size of the guest has changed in autosize mode. | 73 // Notifies that the content size of the guest has changed in autosize mode. |
77 virtual void SizeChanged(const gfx::Size& old_size, | 74 virtual void SizeChanged(const gfx::Size& old_size, |
78 const gfx::Size& new_size) {} | 75 const gfx::Size& new_size) {} |
79 }; | 76 }; |
80 | 77 |
81 } // namespace content | 78 } // namespace content |
82 | 79 |
83 #endif // CONTENT_PUBLIC_BROWSER_BROWSER_PLUGIN_GUEST_DELEGATE_H_ | 80 #endif // CONTENT_PUBLIC_BROWSER_BROWSER_PLUGIN_GUEST_DELEGATE_H_ |
OLD | NEW |