OLD | NEW |
(Empty) | |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef CHROME_BROWSER_BROWSER_PLUGIN_CHROME_BROWSER_PLUGIN_GUEST_OBSERVER_H_ |
| 6 #define CHROME_BROWSER_BROWSER_PLUGIN_CHROME_BROWSER_PLUGIN_GUEST_OBSERVER_H_ |
| 7 |
| 8 #include "content/public/browser/browser_plugin/browser_plugin_guest_observer.h" |
| 9 |
| 10 #include "base/memory/ref_counted.h" |
| 11 #include "base/memory/scoped_ptr.h" |
| 12 |
| 13 namespace base { |
| 14 class ListValue; |
| 15 } // namespace base |
| 16 |
| 17 namespace extensions { |
| 18 class Extension; |
| 19 } // namespace extensions |
| 20 |
| 21 class ChromeBrowserPluginGuestObserver |
| 22 : public content::BrowserPluginGuestObserver, |
| 23 public base::RefCounted<ChromeBrowserPluginGuestObserver> { |
| 24 public: |
| 25 explicit ChromeBrowserPluginGuestObserver(content::BrowserPluginGuest* guest); |
| 26 |
| 27 virtual bool OnMessageReceivedFromEmbedder( |
| 28 const IPC::Message& message) OVERRIDE; |
| 29 |
| 30 private: |
| 31 friend class base::RefCounted<ChromeBrowserPluginGuestObserver>; |
| 32 |
| 33 virtual ~ChromeBrowserPluginGuestObserver(); |
| 34 |
| 35 virtual void OnDestruct() OVERRIDE; |
| 36 |
| 37 // Message handlers. |
| 38 // If possible, navigate the guest to |relative_index| entries away from the |
| 39 // current navigation entry. |
| 40 void OnGo(int relative_index); |
| 41 |
| 42 DISALLOW_COPY_AND_ASSIGN(ChromeBrowserPluginGuestObserver); |
| 43 }; |
| 44 |
| 45 #endif // CHROME_BROWSER_BROWSER_PLUGIN_CHROME_BROWSER_PLUGIN_GUEST_OBSERVER_H_ |
OLD | NEW |