Update wrapper implementations to use base types (issue #1336).

git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@1775 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
This commit is contained in:
Marshall Greenblatt
2014-07-15 17:19:43 +00:00
parent f9bf8dfa10
commit 646ae3310f
7 changed files with 105 additions and 90 deletions

View File

@ -37,6 +37,7 @@
#define CEF_INCLUDE_WRAPPER_CEF_MESSAGE_ROUTER_H_
#pragma once
#include "include/base/cef_ref_counted.h"
#include "include/cef_base.h"
#include "include/cef_browser.h"
#include "include/cef_process_message.h"
@ -211,7 +212,8 @@ struct CefMessageRouterConfig {
// Implements the browser side of query routing. The methods of this class may
// be called on any browser process thread unless otherwise indicated.
///
class CefMessageRouterBrowserSide : public CefBase {
class CefMessageRouterBrowserSide :
public base::RefCountedThreadSafe<CefMessageRouterBrowserSide> {
public:
///
// Callback associated with a single pending asynchronous query. Execute the
@ -360,16 +362,20 @@ class CefMessageRouterBrowserSide : public CefBase {
CefRefPtr<CefBrowser> browser,
CefProcessId source_process,
CefRefPtr<CefProcessMessage> message) =0;
protected:
// Protect against accidental deletion of this object.
friend class base::RefCountedThreadSafe<CefMessageRouterBrowserSide>;
virtual ~CefMessageRouterBrowserSide() {}
};
///
// Implements the renderer side of query routing. The methods of this class must
// be called on the render process main thread.
///
class CefMessageRouterRendererSide : public CefBase {
class CefMessageRouterRendererSide :
public base::RefCountedThreadSafe<CefMessageRouterRendererSide> {
public:
virtual ~CefMessageRouterRendererSide() {}
///
// Create a new router with the specified configuration.
///
@ -412,6 +418,11 @@ class CefMessageRouterRendererSide : public CefBase {
CefRefPtr<CefBrowser> browser,
CefProcessId source_process,
CefRefPtr<CefProcessMessage> message) =0;
protected:
// Protect against accidental deletion of this object.
friend class base::RefCountedThreadSafe<CefMessageRouterRendererSide>;
virtual ~CefMessageRouterRendererSide() {}
};
#endif // CEF_INCLUDE_WRAPPER_CEF_MESSAGE_ROUTER_H_