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

Unified Diff: base/task.h

Issue 9015021: Remove DeleteTask and convert remaining users. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix last Linux gotchas (upload attempt #2) Created 9 years 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | chrome/browser/automation/automation_provider.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/task.h
diff --git a/base/task.h b/base/task.h
index b546af5193347c02c31174c0f3c623b1bde0e7f7..c83a8b1e87df176be132162bf09371a8fc359c6f 100644
--- a/base/task.h
+++ b/base/task.h
@@ -205,26 +205,7 @@ class ScopedRunnableMethodFactory {
base::WeakPtrFactory<T> weak_factory_;
};
-// General task implementations ------------------------------------------------
-
-// Task to delete an object
-template<class T>
-class DeleteTask : public CancelableTask {
- public:
- explicit DeleteTask(const T* obj) : obj_(obj) {
- }
- virtual void Run() {
- delete obj_;
- }
- virtual void Cancel() {
- obj_ = NULL;
- }
-
- private:
- const T* obj_;
-};
-
-// Equivalents for use by base::Bind().
+// Delete helper for use with base::Bind().
template<typename T>
void DeletePointer(T* obj) {
delete obj;
« no previous file with comments | « no previous file | chrome/browser/automation/automation_provider.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698