summaryrefslogtreecommitdiffstats
path: root/chrome/browser/extensions/extension_function.h
diff options
context:
space:
mode:
authorrafaelw@chromium.org <rafaelw@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-07-24 02:14:56 +0000
committerrafaelw@chromium.org <rafaelw@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-07-24 02:14:56 +0000
commit76a3db852fb58323d63b6857493191e00e97422a (patch)
treea9af5546c680a37ec89c1aaec0733f1026a24711 /chrome/browser/extensions/extension_function.h
parentd267ac762bb0764857fedb92a516a9aa290b0dd2 (diff)
downloadchromium_src-76a3db852fb58323d63b6857493191e00e97422a.zip
chromium_src-76a3db852fb58323d63b6857493191e00e97422a.tar.gz
chromium_src-76a3db852fb58323d63b6857493191e00e97422a.tar.bz2
Push bookmarks.remove/removeAll polymorphism into c++. fix bookmarks id schema issues (http://code.google.com/p/chromium/issues/detail?id=17562 failed to update schema types from int to string).
R=erikkay BUG=17417 Review URL: http://codereview.chromium.org/160064 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@21503 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/extensions/extension_function.h')
-rw-r--r--chrome/browser/extensions/extension_function.h8
1 files changed, 6 insertions, 2 deletions
diff --git a/chrome/browser/extensions/extension_function.h b/chrome/browser/extensions/extension_function.h
index ed2f9d0..02bab68 100644
--- a/chrome/browser/extensions/extension_function.h
+++ b/chrome/browser/extensions/extension_function.h
@@ -29,11 +29,12 @@ class Profile;
// APIs that live beyond a single stack frame.
class ExtensionFunction : public base::RefCounted<ExtensionFunction> {
public:
- ExtensionFunction() : request_id_(-1), has_callback_(false) {}
+ ExtensionFunction() : request_id_(-1), name_(""), has_callback_(false) {}
virtual ~ExtensionFunction() {}
// Specifies the name of the function.
- virtual void SetName(const std::string& name) { }
+ void set_name(const std::string& name) { name_ = name; }
+ const std::string name() { return name_; }
// Specifies the raw arguments to the function, as a JSON-encoded string.
virtual void SetArgs(const std::string& args) = 0;
@@ -71,6 +72,9 @@ class ExtensionFunction : public base::RefCounted<ExtensionFunction> {
// Id of this request, used to map the response back to the caller.
int request_id_;
+ // The name of this function.
+ std::string name_;
+
// True if the js caller provides a callback function to receive the response
// of this call.
bool has_callback_;