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

Side by Side Diff: extensions/browser/extension_function.h

Issue 510313002: Extensions-related fixups for scoped_refptr conversion operator removal. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: 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
« no previous file with comments | « extensions/browser/api/usb/usb_api.cc ('k') | extensions/common/extension_messages.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 EXTENSIONS_BROWSER_EXTENSION_FUNCTION_H_ 5 #ifndef EXTENSIONS_BROWSER_EXTENSION_FUNCTION_H_
6 #define EXTENSIONS_BROWSER_EXTENSION_FUNCTION_H_ 6 #define EXTENSIONS_BROWSER_EXTENSION_FUNCTION_H_
7 7
8 #include <list> 8 #include <list>
9 #include <string> 9 #include <string>
10 10
(...skipping 195 matching lines...) Expand 10 before | Expand all | Expand 10 after
206 // Sets the function's bad message state. 206 // Sets the function's bad message state.
207 void set_bad_message(bool bad_message) { bad_message_ = bad_message; } 207 void set_bad_message(bool bad_message) { bad_message_ = bad_message; }
208 208
209 // Specifies the name of the function. 209 // Specifies the name of the function.
210 void set_name(const std::string& name) { name_ = name; } 210 void set_name(const std::string& name) { name_ = name; }
211 const std::string& name() const { return name_; } 211 const std::string& name() const { return name_; }
212 212
213 void set_profile_id(void* profile_id) { profile_id_ = profile_id; } 213 void set_profile_id(void* profile_id) { profile_id_ = profile_id; }
214 void* profile_id() const { return profile_id_; } 214 void* profile_id() const { return profile_id_; }
215 215
216 void set_extension(const extensions::Extension* extension) { 216 void set_extension(
217 const scoped_refptr<const extensions::Extension>& extension) {
217 extension_ = extension; 218 extension_ = extension;
218 } 219 }
219 const extensions::Extension* extension() const { return extension_.get(); } 220 const extensions::Extension* extension() const { return extension_.get(); }
220 const std::string& extension_id() const { return extension_->id(); } 221 const std::string& extension_id() const { return extension_->id(); }
221 222
222 void set_request_id(int request_id) { request_id_ = request_id; } 223 void set_request_id(int request_id) { request_id_ = request_id; }
223 int request_id() { return request_id_; } 224 int request_id() { return request_id_; }
224 225
225 void set_source_url(const GURL& source_url) { source_url_ = source_url; } 226 void set_source_url(const GURL& source_url) { source_url_ = source_url; }
226 const GURL& source_url() { return source_url_; } 227 const GURL& source_url() { return source_url_; }
(...skipping 378 matching lines...) Expand 10 before | Expand all | Expand 10 after
605 virtual bool RunSync() = 0; 606 virtual bool RunSync() = 0;
606 607
607 // ValidationFailure override to match RunSync(). 608 // ValidationFailure override to match RunSync().
608 static bool ValidationFailure(SyncIOThreadExtensionFunction* function); 609 static bool ValidationFailure(SyncIOThreadExtensionFunction* function);
609 610
610 private: 611 private:
611 virtual ResponseAction Run() OVERRIDE; 612 virtual ResponseAction Run() OVERRIDE;
612 }; 613 };
613 614
614 #endif // EXTENSIONS_BROWSER_EXTENSION_FUNCTION_H_ 615 #endif // EXTENSIONS_BROWSER_EXTENSION_FUNCTION_H_
OLDNEW
« no previous file with comments | « extensions/browser/api/usb/usb_api.cc ('k') | extensions/common/extension_messages.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698