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

Unified Diff: base/files/file_path_watcher.h

Issue 10065037: RefCounted types should not have public destructors, base/ edition (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | base/files/file_path_watcher_browsertest.cc » ('j') | base/threading/worker_pool_unittest.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/files/file_path_watcher.h
diff --git a/base/files/file_path_watcher.h b/base/files/file_path_watcher.h
index 3174a9e0ac9069037151b616839aa789cd1ab5e1..82e2445aeb0fa961dd2afd925922a68a90e6bd36 100644
--- a/base/files/file_path_watcher.h
+++ b/base/files/file_path_watcher.h
@@ -33,11 +33,16 @@ class BASE_EXPORT FilePathWatcher {
// corresponding FileWatcher object to prevent a reference cycle.
class Delegate : public base::RefCountedThreadSafe<Delegate> {
public:
- virtual ~Delegate() {}
virtual void OnFilePathChanged(const FilePath& path) = 0;
// Called when platform specific code detected an error. The watcher will
// not call OnFilePathChanged for future changes.
virtual void OnFilePathError(const FilePath& path) {}
+
+ protected:
+ virtual ~Delegate() {}
+
+ private:
+ friend class base::RefCountedThreadSafe<Delegate>;
};
// Used internally to encapsulate different members on different platforms.
« no previous file with comments | « no previous file | base/files/file_path_watcher_browsertest.cc » ('j') | base/threading/worker_pool_unittest.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698