summaryrefslogtreecommitdiffstats
path: root/chrome/browser
diff options
context:
space:
mode:
authorhclam@chromium.org <hclam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-11-06 03:28:20 +0000
committerhclam@chromium.org <hclam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-11-06 03:28:20 +0000
commit08ffa6bd4032c34c135d23b47276c0a83ab34f76 (patch)
tree3e5cd86f532dc04214b70ed10886c5cb16b3aeb7 /chrome/browser
parenta5971dc68d14d4cb063c10138133483a14cd7530 (diff)
downloadchromium_src-08ffa6bd4032c34c135d23b47276c0a83ab34f76.zip
chromium_src-08ffa6bd4032c34c135d23b47276c0a83ab34f76.tar.gz
chromium_src-08ffa6bd4032c34c135d23b47276c0a83ab34f76.tar.bz2
Rever r31175 r31176 r31187
XP tests are failing, the guess is r31175 and r31176. TBR=beng TEST=XP tests go green Review URL: http://codereview.chromium.org/376008 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@31201 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser')
-rw-r--r--chrome/browser/autocomplete/autocomplete.h6
-rw-r--r--chrome/browser/autocomplete/autocomplete_unittest.cc2
-rw-r--r--chrome/browser/autocomplete/history_contents_provider.h2
-rw-r--r--chrome/browser/autocomplete/history_url_provider.h2
-rw-r--r--chrome/browser/autocomplete/keyword_provider.h2
-rw-r--r--chrome/browser/autocomplete/search_provider.h2
-rw-r--r--chrome/browser/automation/automation_extension_function.h2
-rw-r--r--chrome/browser/automation/automation_provider.h8
-rw-r--r--chrome/browser/automation/ui_controls_win.cc6
-rw-r--r--chrome/browser/bookmarks/bookmark_storage.h5
-rw-r--r--chrome/browser/browser_about_handler.cc3
-rw-r--r--chrome/browser/chromeos/version_loader.h4
-rw-r--r--chrome/browser/dom_ui/chrome_url_data_manager.h6
-rw-r--r--chrome/browser/dom_ui/dom_ui_favicon_source.h3
-rw-r--r--chrome/browser/dom_ui/dom_ui_theme_source.h3
-rw-r--r--chrome/browser/dom_ui/dom_ui_theme_source_unittest.cc3
-rw-r--r--chrome/browser/dom_ui/dom_ui_thumbnail_source.h2
-rw-r--r--chrome/browser/dom_ui/downloads_ui.cc2
-rw-r--r--chrome/browser/dom_ui/filebrowse_ui.cc2
-rw-r--r--chrome/browser/dom_ui/fileicon_source.h3
-rw-r--r--chrome/browser/dom_ui/history_ui.h2
-rw-r--r--chrome/browser/dom_ui/new_tab_ui.cc2
-rw-r--r--chrome/browser/dom_ui/new_tab_ui.h2
-rw-r--r--chrome/browser/dom_ui/print_ui.h2
-rw-r--r--chrome/browser/download/download_file.h5
-rw-r--r--chrome/browser/download/download_manager.h5
-rw-r--r--chrome/browser/download/download_request_manager.h4
-rw-r--r--chrome/browser/download/save_file_manager.h5
-rw-r--r--chrome/browser/download/save_package.h6
-rw-r--r--chrome/browser/extensions/extension_browser_actions_api.h5
-rw-r--r--chrome/browser/extensions/extension_devtools_manager.h4
-rw-r--r--chrome/browser/extensions/extension_disabled_infobar_delegate.cc7
-rw-r--r--chrome/browser/extensions/extension_function.h13
-rw-r--r--chrome/browser/extensions/extension_function_dispatcher.h6
-rw-r--r--chrome/browser/extensions/extension_i18n_api.h1
-rw-r--r--chrome/browser/extensions/extension_message_service.h5
-rw-r--r--chrome/browser/extensions/extension_page_actions_module.h10
-rw-r--r--chrome/browser/extensions/extension_tabs_module.h16
-rw-r--r--chrome/browser/extensions/extension_test_api.h4
-rw-r--r--chrome/browser/extensions/extension_toolstrip_api.h3
-rw-r--r--chrome/browser/extensions/extension_updater.cc5
-rw-r--r--chrome/browser/extensions/extension_updater.h4
-rw-r--r--chrome/browser/extensions/extensions_service.h11
-rw-r--r--chrome/browser/extensions/extensions_ui.h2
-rw-r--r--chrome/browser/extensions/file_reader.h4
-rw-r--r--chrome/browser/extensions/image_loading_tracker.h5
-rw-r--r--chrome/browser/extensions/pack_extension_job.h4
-rw-r--r--chrome/browser/extensions/sandboxed_extension_unpacker.h8
-rw-r--r--chrome/browser/extensions/user_script_listener.h4
-rw-r--r--chrome/browser/extensions/user_script_listener_unittest.cc3
-rw-r--r--chrome/browser/extensions/user_script_master.h10
-rw-r--r--chrome/browser/process_singleton_linux.cc10
-rw-r--r--chrome/browser/sync/sync_setup_wizard.cc4
53 files changed, 42 insertions, 207 deletions
diff --git a/chrome/browser/autocomplete/autocomplete.h b/chrome/browser/autocomplete/autocomplete.h
index 0193b8c..0416328 100644
--- a/chrome/browser/autocomplete/autocomplete.h
+++ b/chrome/browser/autocomplete/autocomplete.h
@@ -483,6 +483,8 @@ class AutocompleteProvider
name_(name) {
}
+ virtual ~AutocompleteProvider();
+
// Invoked when the profile changes.
// NOTE: Do not access any previous Profile* at this point as it may have
// already been deleted.
@@ -536,10 +538,6 @@ class AutocompleteProvider
static size_t max_matches() { return max_matches_; }
protected:
- friend class base::RefCountedThreadSafe<AutocompleteProvider>;
-
- virtual ~AutocompleteProvider();
-
// Trims "http:" and up to two subsequent slashes from |url|. Returns the
// number of characters that were trimmed.
static size_t TrimHttpPrefix(std::wstring* url);
diff --git a/chrome/browser/autocomplete/autocomplete_unittest.cc b/chrome/browser/autocomplete/autocomplete_unittest.cc
index 0e8671a..adff59c 100644
--- a/chrome/browser/autocomplete/autocomplete_unittest.cc
+++ b/chrome/browser/autocomplete/autocomplete_unittest.cc
@@ -35,8 +35,6 @@ class TestProvider : public AutocompleteProvider {
}
private:
- ~TestProvider() {}
-
void Run();
void AddResults(int start_at, int num);
diff --git a/chrome/browser/autocomplete/history_contents_provider.h b/chrome/browser/autocomplete/history_contents_provider.h
index 18a4b36..49ca83e 100644
--- a/chrome/browser/autocomplete/history_contents_provider.h
+++ b/chrome/browser/autocomplete/history_contents_provider.h
@@ -49,8 +49,6 @@ class HistoryContentsProvider : public AutocompleteProvider {
static const size_t kMaxMatchCount = 50;
private:
- ~HistoryContentsProvider() {}
-
void QueryComplete(HistoryService::Handle handle,
history::QueryResults* results);
diff --git a/chrome/browser/autocomplete/history_url_provider.h b/chrome/browser/autocomplete/history_url_provider.h
index 50f6ba7..b87a2e3 100644
--- a/chrome/browser/autocomplete/history_url_provider.h
+++ b/chrome/browser/autocomplete/history_url_provider.h
@@ -177,8 +177,6 @@ class HistoryURLProvider : public AutocompleteProvider {
void QueryComplete(HistoryURLProviderParams* params_gets_deleted);
private:
- ~HistoryURLProvider() {}
-
struct Prefix {
Prefix(std::wstring prefix, int num_components)
: prefix(prefix),
diff --git a/chrome/browser/autocomplete/keyword_provider.h b/chrome/browser/autocomplete/keyword_provider.h
index adf81d8..6caa2b1 100644
--- a/chrome/browser/autocomplete/keyword_provider.h
+++ b/chrome/browser/autocomplete/keyword_provider.h
@@ -69,8 +69,6 @@ class KeywordProvider : public AutocompleteProvider {
bool minimal_changes);
private:
- ~KeywordProvider() {}
-
// Extracts the keyword from |input| into |keyword|. Any remaining characters
// after the keyword are placed in |remaining_input|. Returns true if |input|
// is valid and has a keyword. This makes use of SplitKeywordFromInput to
diff --git a/chrome/browser/autocomplete/search_provider.h b/chrome/browser/autocomplete/search_provider.h
index f36c070..f333c4f 100644
--- a/chrome/browser/autocomplete/search_provider.h
+++ b/chrome/browser/autocomplete/search_provider.h
@@ -75,8 +75,6 @@ class SearchProvider : public AutocompleteProvider,
static const int kKeywordProviderURLFetcherID;
private:
- ~SearchProvider() {}
-
// Manages the providers (TemplateURLs) used by SearchProvider. Two providers
// may be used:
// . The default provider. This corresponds to the user's default search
diff --git a/chrome/browser/automation/automation_extension_function.h b/chrome/browser/automation/automation_extension_function.h
index ed57ca1..d6fac7d 100644
--- a/chrome/browser/automation/automation_extension_function.h
+++ b/chrome/browser/automation/automation_extension_function.h
@@ -46,8 +46,6 @@ class AutomationExtensionFunction : public ExtensionFunction {
const std::string& target);
private:
- ~AutomationExtensionFunction() {}
-
static bool enabled_;
std::string args_;
DISALLOW_COPY_AND_ASSIGN(AutomationExtensionFunction);
diff --git a/chrome/browser/automation/automation_provider.h b/chrome/browser/automation/automation_provider.h
index 418c804..dc540da 100644
--- a/chrome/browser/automation/automation_provider.h
+++ b/chrome/browser/automation/automation_provider.h
@@ -56,6 +56,7 @@ class AutomationProvider : public base::RefCounted<AutomationProvider>,
public IPC::Message::Sender {
public:
explicit AutomationProvider(Profile* profile);
+ virtual ~AutomationProvider();
Profile* profile() const { return profile_; }
@@ -130,10 +131,6 @@ class AutomationProvider : public base::RefCounted<AutomationProvider>,
// Adds the external tab passed in to the tab tracker.
bool AddExternalTab(ExternalTabContainer* external_tab);
- protected:
- friend class base::RefCounted<AutomationProvider>;
- virtual ~AutomationProvider();
-
private:
// IPC Message callbacks.
void CloseBrowser(int handle, IPC::Message* reply_message);
@@ -570,6 +567,7 @@ class TestingAutomationProvider : public AutomationProvider,
public NotificationObserver {
public:
explicit TestingAutomationProvider(Profile* profile);
+ virtual ~TestingAutomationProvider();
// BrowserList::Observer implementation
// Called immediately after a browser is added to the list
@@ -582,8 +580,6 @@ class TestingAutomationProvider : public AutomationProvider,
virtual void OnChannelError();
private:
- virtual ~TestingAutomationProvider();
-
virtual void Observe(NotificationType type,
const NotificationSource& source,
const NotificationDetails& details);
diff --git a/chrome/browser/automation/ui_controls_win.cc b/chrome/browser/automation/ui_controls_win.cc
index 43e8b32..29ca089 100644
--- a/chrome/browser/automation/ui_controls_win.cc
+++ b/chrome/browser/automation/ui_controls_win.cc
@@ -24,6 +24,8 @@ class InputDispatcher : public base::RefCounted<InputDispatcher> {
public:
InputDispatcher(Task* task, WPARAM message_waiting_for);
+ ~InputDispatcher();
+
// Invoked from the hook. If mouse_message matches message_waiting_for_
// MatchingMessageFound is invoked.
void DispatchedMessage(WPARAM mouse_message);
@@ -33,10 +35,6 @@ class InputDispatcher : public base::RefCounted<InputDispatcher> {
void MatchingMessageFound();
private:
- friend class base::RefCounted<InputDispatcher>;
-
- ~InputDispatcher();
-
// Notifies the task and release this (which should delete it).
void NotifyTask();
diff --git a/chrome/browser/bookmarks/bookmark_storage.h b/chrome/browser/bookmarks/bookmark_storage.h
index e3e1337..d41b2c5 100644
--- a/chrome/browser/bookmarks/bookmark_storage.h
+++ b/chrome/browser/bookmarks/bookmark_storage.h
@@ -92,6 +92,7 @@ class BookmarkStorage : public NotificationObserver,
// Creates a BookmarkStorage for the specified model
BookmarkStorage(Profile* profile, BookmarkModel* model);
+ ~BookmarkStorage();
// Loads the bookmarks into the model, notifying the model when done. This
// takes ownership of |details|. See LoadDetails for details.
@@ -108,10 +109,6 @@ class BookmarkStorage : public NotificationObserver,
virtual bool SerializeData(std::string* output);
private:
- friend class base::RefCountedThreadSafe<BookmarkStorage>;
-
- ~BookmarkStorage();
-
class LoadTask;
// Callback from backend with the results of the bookmark file.
diff --git a/chrome/browser/browser_about_handler.cc b/chrome/browser/browser_about_handler.cc
index 54bd4f0..21b166e 100644
--- a/chrome/browser/browser_about_handler.cc
+++ b/chrome/browser/browser_about_handler.cc
@@ -112,6 +112,7 @@ class AboutSource : public ChromeURLDataManager::DataSource {
public:
// Creates our datasource.
AboutSource();
+ virtual ~AboutSource();
// Called when the network layer has requested a resource underneath
// the path we registered.
@@ -125,8 +126,6 @@ class AboutSource : public ChromeURLDataManager::DataSource {
void FinishDataRequest(const std::string& html, int request_id);
private:
- virtual ~AboutSource();
-
DISALLOW_COPY_AND_ASSIGN(AboutSource);
};
diff --git a/chrome/browser/chromeos/version_loader.h b/chrome/browser/chromeos/version_loader.h
index 15c281f..f118934 100644
--- a/chrome/browser/chromeos/version_loader.h
+++ b/chrome/browser/chromeos/version_loader.h
@@ -53,10 +53,6 @@ class VersionLoader : public CancelableRequestProvider {
void GetVersion(scoped_refptr<GetVersionRequest> request);
private:
- friend class base::RefCountedThreadSafe<Backend>;
-
- ~Backend() {}
-
DISALLOW_COPY_AND_ASSIGN(Backend);
};
diff --git a/chrome/browser/dom_ui/chrome_url_data_manager.h b/chrome/browser/dom_ui/chrome_url_data_manager.h
index f553a3f..c159190 100644
--- a/chrome/browser/dom_ui/chrome_url_data_manager.h
+++ b/chrome/browser/dom_ui/chrome_url_data_manager.h
@@ -44,6 +44,7 @@ class ChromeURLDataManager {
DataSource(const std::string& source_name,
MessageLoop* message_loop)
: source_name_(source_name), message_loop_(message_loop) {}
+ virtual ~DataSource() {}
// Sent by the DataManager to request data at |path|. The source should
// call SendResponse() when the data is available or if the request could
@@ -75,11 +76,6 @@ class ChromeURLDataManager {
static void SetFontAndTextDirection(DictionaryValue* localized_strings);
- protected:
- friend class base::RefCountedThreadSafe<DataSource>;
-
- virtual ~DataSource() {}
-
private:
// The name of this source.
// E.g., for favicons, this could be "favicon", which results in paths for
diff --git a/chrome/browser/dom_ui/dom_ui_favicon_source.h b/chrome/browser/dom_ui/dom_ui_favicon_source.h
index 0d42eaf..6556c39 100644
--- a/chrome/browser/dom_ui/dom_ui_favicon_source.h
+++ b/chrome/browser/dom_ui/dom_ui_favicon_source.h
@@ -20,6 +20,7 @@ class Profile;
class DOMUIFavIconSource : public ChromeURLDataManager::DataSource {
public:
explicit DOMUIFavIconSource(Profile* profile);
+ virtual ~DOMUIFavIconSource() { }
// Called when the network layer has requested a resource underneath
// the path we registered.
@@ -39,8 +40,6 @@ class DOMUIFavIconSource : public ChromeURLDataManager::DataSource {
GURL url);
private:
- virtual ~DOMUIFavIconSource() {}
-
Profile* profile_;
CancelableRequestConsumerT<int, 0> cancelable_consumer_;
diff --git a/chrome/browser/dom_ui/dom_ui_theme_source.h b/chrome/browser/dom_ui/dom_ui_theme_source.h
index f20d104..65f83e7 100644
--- a/chrome/browser/dom_ui/dom_ui_theme_source.h
+++ b/chrome/browser/dom_ui/dom_ui_theme_source.h
@@ -26,9 +26,6 @@ class DOMUIThemeSource : public ChromeURLDataManager::DataSource {
virtual MessageLoop* MessageLoopForRequestPath(const std::string& path) const;
- protected:
- virtual ~DOMUIThemeSource() {}
-
private:
// Populate new_tab_css_ and new_incognito_tab_css. These must be called
// from the UI thread because they involve profile and theme access.
diff --git a/chrome/browser/dom_ui/dom_ui_theme_source_unittest.cc b/chrome/browser/dom_ui/dom_ui_theme_source_unittest.cc
index 09e98b2..f33bf27 100644
--- a/chrome/browser/dom_ui/dom_ui_theme_source_unittest.cc
+++ b/chrome/browser/dom_ui/dom_ui_theme_source_unittest.cc
@@ -26,9 +26,6 @@ class MockThemeSource : public DOMUIThemeSource {
int result_request_id_;
size_t result_data_size_;
-
- private:
- ~MockThemeSource() {}
};
class DOMUISourcesTest : public testing::Test {
diff --git a/chrome/browser/dom_ui/dom_ui_thumbnail_source.h b/chrome/browser/dom_ui/dom_ui_thumbnail_source.h
index 03263b2..48f2879 100644
--- a/chrome/browser/dom_ui/dom_ui_thumbnail_source.h
+++ b/chrome/browser/dom_ui/dom_ui_thumbnail_source.h
@@ -40,8 +40,6 @@ class DOMUIThumbnailSource : public ChromeURLDataManager::DataSource,
scoped_refptr<RefCountedBytes> data);
private:
- ~DOMUIThumbnailSource() {}
-
// NotificationObserver implementation
virtual void Observe(NotificationType type,
const NotificationSource& source,
diff --git a/chrome/browser/dom_ui/downloads_ui.cc b/chrome/browser/dom_ui/downloads_ui.cc
index 5dff5b9..39adf47e 100644
--- a/chrome/browser/dom_ui/downloads_ui.cc
+++ b/chrome/browser/dom_ui/downloads_ui.cc
@@ -41,8 +41,6 @@ class DownloadsUIHTMLSource : public ChromeURLDataManager::DataSource {
}
private:
- ~DownloadsUIHTMLSource() {}
-
DISALLOW_COPY_AND_ASSIGN(DownloadsUIHTMLSource);
};
diff --git a/chrome/browser/dom_ui/filebrowse_ui.cc b/chrome/browser/dom_ui/filebrowse_ui.cc
index 182c20a..0a07074 100644
--- a/chrome/browser/dom_ui/filebrowse_ui.cc
+++ b/chrome/browser/dom_ui/filebrowse_ui.cc
@@ -50,8 +50,6 @@ class FileBrowseUIHTMLSource : public ChromeURLDataManager::DataSource {
}
private:
- ~FileBrowseUIHTMLSource() {}
-
DISALLOW_COPY_AND_ASSIGN(FileBrowseUIHTMLSource);
};
diff --git a/chrome/browser/dom_ui/fileicon_source.h b/chrome/browser/dom_ui/fileicon_source.h
index a9f43d7..a13c207 100644
--- a/chrome/browser/dom_ui/fileicon_source.h
+++ b/chrome/browser/dom_ui/fileicon_source.h
@@ -18,6 +18,7 @@ class GURL;
class FileIconSource : public ChromeURLDataManager::DataSource {
public:
explicit FileIconSource();
+ virtual ~FileIconSource();
// Called when the network layer has requested a resource underneath
// the path we registered.
@@ -34,8 +35,6 @@ class FileIconSource : public ChromeURLDataManager::DataSource {
SkBitmap* icon);
private:
- virtual ~FileIconSource();
-
CancelableRequestConsumerT<int, 0> cancelable_consumer_;
// Raw PNG representation of the favicon to show when the favicon
diff --git a/chrome/browser/dom_ui/history_ui.h b/chrome/browser/dom_ui/history_ui.h
index 990c423..3dc51c4 100644
--- a/chrome/browser/dom_ui/history_ui.h
+++ b/chrome/browser/dom_ui/history_ui.h
@@ -29,8 +29,6 @@ class HistoryUIHTMLSource : public ChromeURLDataManager::DataSource {
}
private:
- ~HistoryUIHTMLSource() {}
-
DISALLOW_COPY_AND_ASSIGN(HistoryUIHTMLSource);
};
diff --git a/chrome/browser/dom_ui/new_tab_ui.cc b/chrome/browser/dom_ui/new_tab_ui.cc
index 9dd8dc84..10addde 100644
--- a/chrome/browser/dom_ui/new_tab_ui.cc
+++ b/chrome/browser/dom_ui/new_tab_ui.cc
@@ -144,8 +144,6 @@ class IncognitoTabHTMLSource : public ChromeURLDataManager::DataSource {
}
private:
- ~IncognitoTabHTMLSource() {}
-
// Populate full_html_. This must be called from the UI thread because it
// involves profile access.
//
diff --git a/chrome/browser/dom_ui/new_tab_ui.h b/chrome/browser/dom_ui/new_tab_ui.h
index 1feac2a..e4b494c 100644
--- a/chrome/browser/dom_ui/new_tab_ui.h
+++ b/chrome/browser/dom_ui/new_tab_ui.h
@@ -78,8 +78,6 @@ class NewTabUI : public DOMUI,
static bool first_run() { return first_run_; }
private:
- ~NewTabHTMLSource() {}
-
// In case a file path to the new tab page was provided this tries to load
// the file and returns the file content if successful. This returns an
// empty string in case of failure.
diff --git a/chrome/browser/dom_ui/print_ui.h b/chrome/browser/dom_ui/print_ui.h
index 508a6c4..8443da4 100644
--- a/chrome/browser/dom_ui/print_ui.h
+++ b/chrome/browser/dom_ui/print_ui.h
@@ -31,8 +31,6 @@ class PrintUIHTMLSource : public ChromeURLDataManager::DataSource {
}
private:
- ~PrintUIHTMLSource() {}
-
DISALLOW_COPY_AND_ASSIGN(PrintUIHTMLSource);
};
diff --git a/chrome/browser/download/download_file.h b/chrome/browser/download/download_file.h
index 0705ffe..ef367ce 100644
--- a/chrome/browser/download/download_file.h
+++ b/chrome/browser/download/download_file.h
@@ -168,6 +168,7 @@ class DownloadFileManager
: public base::RefCountedThreadSafe<DownloadFileManager> {
public:
DownloadFileManager(ResourceDispatcherHost* rdh);
+ ~DownloadFileManager();
// Called on shutdown on the UI thread.
void Shutdown();
@@ -233,10 +234,6 @@ class DownloadFileManager
static void DeleteFile(const FilePath& path);
private:
- friend class base::RefCountedThreadSafe<DownloadFileManager>;
-
- ~DownloadFileManager();
-
// Timer helpers for updating the UI about the current progress of a download.
void StartUpdateTimer();
void StopUpdateTimer();
diff --git a/chrome/browser/download/download_manager.h b/chrome/browser/download/download_manager.h
index 30423ba..3974df6 100644
--- a/chrome/browser/download/download_manager.h
+++ b/chrome/browser/download/download_manager.h
@@ -311,6 +311,7 @@ class DownloadManager : public base::RefCountedThreadSafe<DownloadManager>,
public:
DownloadManager();
+ ~DownloadManager();
static void RegisterUserPrefs(PrefService* prefs);
@@ -464,10 +465,6 @@ class DownloadManager : public base::RefCountedThreadSafe<DownloadManager>,
int request_id);
private:
- friend class base::RefCountedThreadSafe<DownloadManager>;
-
- ~DownloadManager();
-
// Opens a download via the Windows shell.
void OpenDownloadInShell(const DownloadItem* download,
gfx::NativeView parent_window);
diff --git a/chrome/browser/download/download_request_manager.h b/chrome/browser/download/download_request_manager.h
index 2b03572..8e120bb 100644
--- a/chrome/browser/download/download_request_manager.h
+++ b/chrome/browser/download/download_request_manager.h
@@ -148,6 +148,7 @@ class DownloadRequestManager :
};
DownloadRequestManager();
+ ~DownloadRequestManager();
// Returns the download status for a page. This does not change the state in
// anyway.
@@ -168,12 +169,9 @@ class DownloadRequestManager :
void OnUserGesture(TabContents* tab);
private:
- friend class base::RefCountedThreadSafe<DownloadRequestManager>;
friend class DownloadRequestManagerTest;
friend class TabDownloadState;
- ~DownloadRequestManager();
-
// For unit tests. If non-null this is used instead of creating a dialog.
class TestingDelegate {
public:
diff --git a/chrome/browser/download/save_file_manager.h b/chrome/browser/download/save_file_manager.h
index ba470d1..a77f052 100644
--- a/chrome/browser/download/save_file_manager.h
+++ b/chrome/browser/download/save_file_manager.h
@@ -80,6 +80,7 @@ class SaveFileManager
: public base::RefCountedThreadSafe<SaveFileManager> {
public:
SaveFileManager(ResourceDispatcherHost* rdh);
+ ~SaveFileManager();
// Lifetime management.
void Shutdown();
@@ -143,10 +144,6 @@ class SaveFileManager
void RemoveSavedFileFromFileMap(const SaveIDList & save_ids);
private:
- friend class base::RefCountedThreadSafe<SaveFileManager>;
-
- ~SaveFileManager();
-
// A cleanup helper that runs on the file thread.
void OnShutdown();
diff --git a/chrome/browser/download/save_package.h b/chrome/browser/download/save_package.h
index 4d52864..a20f027 100644
--- a/chrome/browser/download/save_package.h
+++ b/chrome/browser/download/save_package.h
@@ -94,6 +94,8 @@ class SavePackage : public base::RefCountedThreadSafe<SavePackage>,
const FilePath& file_full_path,
const FilePath& directory_full_path);
+ ~SavePackage();
+
// Initialize the SavePackage. Returns true if it initializes properly.
// Need to make sure that this method must be called in the UI thread because
// using g_browser_process on a non-UI thread can cause crashes during
@@ -195,14 +197,10 @@ class SavePackage : public base::RefCountedThreadSafe<SavePackage>,
virtual void FileSelectionCanceled(void* params);
private:
- friend class base::RefCountedThreadSafe<SavePackage>;
-
// For testing only.
SavePackage(const FilePath& file_full_path,
const FilePath& directory_full_path);
- ~SavePackage();
-
// Notes from Init() above applies here as well.
void InternalInit();
diff --git a/chrome/browser/extensions/extension_browser_actions_api.h b/chrome/browser/extensions/extension_browser_actions_api.h
index fceab48..f892551 100644
--- a/chrome/browser/extensions/extension_browser_actions_api.h
+++ b/chrome/browser/extensions/extension_browser_actions_api.h
@@ -14,7 +14,6 @@ class ExtensionActionState;
class BrowserActionFunction : public SyncExtensionFunction {
protected:
BrowserActionFunction() : tab_id_(ExtensionAction::kDefaultTabId) {}
- virtual ~BrowserActionFunction() {}
virtual bool RunImpl();
virtual bool RunBrowserAction() = 0;
@@ -31,26 +30,22 @@ class BrowserActionFunction : public SyncExtensionFunction {
};
class BrowserActionSetIconFunction : public BrowserActionFunction {
- ~BrowserActionSetIconFunction() {}
virtual bool RunBrowserAction();
DECLARE_EXTENSION_FUNCTION_NAME("browserAction.setIcon")
};
class BrowserActionSetTitleFunction : public BrowserActionFunction {
- ~BrowserActionSetTitleFunction() {}
virtual bool RunBrowserAction();
DECLARE_EXTENSION_FUNCTION_NAME("browserAction.setTitle")
};
class BrowserActionSetBadgeTextFunction : public BrowserActionFunction {
- ~BrowserActionSetBadgeTextFunction() {}
virtual bool RunBrowserAction();
DECLARE_EXTENSION_FUNCTION_NAME("browserAction.setBadgeText")
};
class BrowserActionSetBadgeBackgroundColorFunction
: public BrowserActionFunction {
- ~BrowserActionSetBadgeBackgroundColorFunction() {}
virtual bool RunBrowserAction();
DECLARE_EXTENSION_FUNCTION_NAME("browserAction.setBadgeBackgroundColor")
};
diff --git a/chrome/browser/extensions/extension_devtools_manager.h b/chrome/browser/extensions/extension_devtools_manager.h
index f1337ef..35e7cec 100644
--- a/chrome/browser/extensions/extension_devtools_manager.h
+++ b/chrome/browser/extensions/extension_devtools_manager.h
@@ -34,6 +34,7 @@ class ExtensionDevToolsManager
public:
// UI thread only:
explicit ExtensionDevToolsManager(Profile* profile);
+ ~ExtensionDevToolsManager();
void AddEventListener(const std::string& event_name,
int render_process_id);
@@ -44,9 +45,6 @@ class ExtensionDevToolsManager
void BridgeClosingForTab(int tab_id);
private:
- friend class base::RefCountedThreadSafe<ExtensionDevToolsManager>;
-
- ~ExtensionDevToolsManager();
// Map of tab IDs to the ExtensionDevToolsBridge connected to the tab
std::map<int, linked_ptr<ExtensionDevToolsBridge> > tab_id_to_bridge_;
diff --git a/chrome/browser/extensions/extension_disabled_infobar_delegate.cc b/chrome/browser/extensions/extension_disabled_infobar_delegate.cc
index 44f819f..0d0d7b4 100644
--- a/chrome/browser/extensions/extension_disabled_infobar_delegate.cc
+++ b/chrome/browser/extensions/extension_disabled_infobar_delegate.cc
@@ -37,6 +37,9 @@ class ExtensionDisabledDialogDelegate
NewRunnableMethod(this, &ExtensionDisabledDialogDelegate::Start));
}
+ virtual ~ExtensionDisabledDialogDelegate() {
+ }
+
// ExtensionInstallUI::Delegate
virtual void ContinueInstall() {
service_->EnableExtension(extension_->id());
@@ -48,10 +51,6 @@ class ExtensionDisabledDialogDelegate
}
private:
- friend class base::RefCountedThreadSafe<ExtensionDisabledDialogDelegate>;
-
- virtual ~ExtensionDisabledDialogDelegate() {}
-
void Start() {
// We start on the file thread so we can decode the install icon.
FilePath install_icon_path = install_icon_resource_.GetFilePath();
diff --git a/chrome/browser/extensions/extension_function.h b/chrome/browser/extensions/extension_function.h
index 2766eb7..e8a77dd 100644
--- a/chrome/browser/extensions/extension_function.h
+++ b/chrome/browser/extensions/extension_function.h
@@ -33,6 +33,7 @@ class Profile;
class ExtensionFunction : public base::RefCounted<ExtensionFunction> {
public:
ExtensionFunction() : request_id_(-1), name_(""), has_callback_(false) {}
+ virtual ~ExtensionFunction() {}
// Specifies the name of the function.
void set_name(const std::string& name) { name_ = name; }
@@ -68,10 +69,6 @@ class ExtensionFunction : public base::RefCounted<ExtensionFunction> {
virtual void Run() = 0;
protected:
- friend class base::RefCounted<ExtensionFunction>;
-
- virtual ~ExtensionFunction() {}
-
// Gets the extension that called this function. This can return NULL for
// async functions.
Extension* GetExtension() {
@@ -94,6 +91,7 @@ class ExtensionFunction : public base::RefCounted<ExtensionFunction> {
// of this call.
bool has_callback_;
+ private:
DISALLOW_COPY_AND_ASSIGN(ExtensionFunction);
};
@@ -106,6 +104,7 @@ class ExtensionFunction : public base::RefCounted<ExtensionFunction> {
class AsyncExtensionFunction : public ExtensionFunction {
public:
AsyncExtensionFunction() : args_(NULL), bad_message_(false) {}
+ virtual ~AsyncExtensionFunction() {}
virtual void SetArgs(const Value* args);
virtual const std::string GetResult();
@@ -120,8 +119,6 @@ class AsyncExtensionFunction : public ExtensionFunction {
virtual bool RunImpl() = 0;
protected:
- virtual ~AsyncExtensionFunction() {}
-
void SendResponse(bool success);
// Note: After Run() returns, dispatcher() can be NULL. Since these getters
@@ -144,6 +141,7 @@ class AsyncExtensionFunction : public ExtensionFunction {
// returning. The calling renderer process will be killed.
bool bad_message_;
+ private:
DISALLOW_COPY_AND_ASSIGN(AsyncExtensionFunction);
};
@@ -166,9 +164,6 @@ class SyncExtensionFunction : public AsyncExtensionFunction {
SendResponse(RunImpl());
}
- protected:
- virtual ~SyncExtensionFunction() {}
-
private:
DISALLOW_COPY_AND_ASSIGN(SyncExtensionFunction);
};
diff --git a/chrome/browser/extensions/extension_function_dispatcher.h b/chrome/browser/extensions/extension_function_dispatcher.h
index 16a9fb3..b987e0e 100644
--- a/chrome/browser/extensions/extension_function_dispatcher.h
+++ b/chrome/browser/extensions/extension_function_dispatcher.h
@@ -37,15 +37,9 @@ class ExtensionFunctionDispatcher {
// The peer object allows us to notify ExtensionFunctions when we are
// destroyed.
- // TODO: this should use WeakPtr
struct Peer : public base::RefCounted<Peer> {
Peer(ExtensionFunctionDispatcher* dispatcher) : dispatcher_(dispatcher) {}
ExtensionFunctionDispatcher* dispatcher_;
-
- private:
- friend class base::RefCounted<Peer>;
-
- ~Peer() {}
};
// Gets a list of all known extension function names.
diff --git a/chrome/browser/extensions/extension_i18n_api.h b/chrome/browser/extensions/extension_i18n_api.h
index 275c882..b7e0cd9 100644
--- a/chrome/browser/extensions/extension_i18n_api.h
+++ b/chrome/browser/extensions/extension_i18n_api.h
@@ -8,7 +8,6 @@
#include "chrome/browser/extensions/extension_function.h"
class GetAcceptLanguagesFunction : public SyncExtensionFunction {
- ~GetAcceptLanguagesFunction() {}
virtual bool RunImpl();
DECLARE_EXTENSION_FUNCTION_NAME("i18n.getAcceptLanguages")
};
diff --git a/chrome/browser/extensions/extension_message_service.h b/chrome/browser/extensions/extension_message_service.h
index 9451381..cf52b65 100644
--- a/chrome/browser/extensions/extension_message_service.h
+++ b/chrome/browser/extensions/extension_message_service.h
@@ -62,6 +62,7 @@ class ExtensionMessageService
// --- UI thread only:
explicit ExtensionMessageService(Profile* profile);
+ ~ExtensionMessageService();
// Notification that our owning profile is going away.
void ProfileDestroyed();
@@ -127,13 +128,9 @@ class ExtensionMessageService
ResourceMessageFilter* source);
private:
- friend class base::RefCountedThreadSafe<ExtensionMessageService>;
-
// A map of channel ID to its channel object.
typedef std::map<int, MessageChannel*> MessageChannelMap;
- ~ExtensionMessageService();
-
// Allocates a pair of port ids.
// NOTE: this can be called from any thread.
void AllocatePortIdPair(int* port1, int* port2);
diff --git a/chrome/browser/extensions/extension_page_actions_module.h b/chrome/browser/extensions/extension_page_actions_module.h
index 8c0e291..42225fc 100644
--- a/chrome/browser/extensions/extension_page_actions_module.h
+++ b/chrome/browser/extensions/extension_page_actions_module.h
@@ -12,7 +12,6 @@ class ExtensionAction;
class PageActionFunction : public SyncExtensionFunction {
protected:
- virtual ~PageActionFunction() {}
bool SetPageActionEnabled(bool enable);
bool InitCommon(int tab_id);
@@ -23,55 +22,46 @@ class PageActionFunction : public SyncExtensionFunction {
};
class EnablePageActionFunction : public PageActionFunction {
- ~EnablePageActionFunction() {}
virtual bool RunImpl();
DECLARE_EXTENSION_FUNCTION_NAME("pageActions.enableForTab")
};
class DisablePageActionFunction : public PageActionFunction {
- ~DisablePageActionFunction() {}
virtual bool RunImpl();
DECLARE_EXTENSION_FUNCTION_NAME("pageActions.disableForTab")
};
class PageActionShowFunction : public PageActionFunction {
- ~PageActionShowFunction() {}
virtual bool RunImpl();
DECLARE_EXTENSION_FUNCTION_NAME("pageAction.show")
};
class PageActionHideFunction : public PageActionFunction {
- ~PageActionHideFunction() {}
virtual bool RunImpl();
DECLARE_EXTENSION_FUNCTION_NAME("pageAction.hide")
};
class PageActionSetIconFunction : public PageActionFunction {
- ~PageActionSetIconFunction() {}
virtual bool RunImpl();
DECLARE_EXTENSION_FUNCTION_NAME("pageAction.setIcon")
};
class PageActionSetTitleFunction : public PageActionFunction {
- ~PageActionSetTitleFunction() {}
virtual bool RunImpl();
DECLARE_EXTENSION_FUNCTION_NAME("pageAction.setTitle")
};
class PageActionSetBadgeBackgroundColorFunction : public PageActionFunction {
- ~PageActionSetBadgeBackgroundColorFunction() {}
virtual bool RunImpl();
DECLARE_EXTENSION_FUNCTION_NAME("pageAction.setBadgeBackgroundColor")
};
class PageActionSetBadgeTextColorFunction : public PageActionFunction {
- ~PageActionSetBadgeTextColorFunction() {}
virtual bool RunImpl();
DECLARE_EXTENSION_FUNCTION_NAME("pageAction.setBadgeTextColor")
};
class PageActionSetBadgeTextFunction : public PageActionFunction {
- ~PageActionSetBadgeTextFunction() {}
virtual bool RunImpl();
DECLARE_EXTENSION_FUNCTION_NAME("pageAction.setBadgeText")
};
diff --git a/chrome/browser/extensions/extension_tabs_module.h b/chrome/browser/extensions/extension_tabs_module.h
index 1fa7f21..05fdcf3 100644
--- a/chrome/browser/extensions/extension_tabs_module.h
+++ b/chrome/browser/extensions/extension_tabs_module.h
@@ -51,81 +51,66 @@ class ExtensionTabUtil {
// Windows
class GetWindowFunction : public SyncExtensionFunction {
- ~GetWindowFunction() {}
virtual bool RunImpl();
DECLARE_EXTENSION_FUNCTION_NAME("windows.get")
};
class GetCurrentWindowFunction : public SyncExtensionFunction {
- ~GetCurrentWindowFunction() {}
virtual bool RunImpl();
DECLARE_EXTENSION_FUNCTION_NAME("windows.getCurrent")
};
class GetLastFocusedWindowFunction : public SyncExtensionFunction {
- ~GetLastFocusedWindowFunction() {}
virtual bool RunImpl();
DECLARE_EXTENSION_FUNCTION_NAME("windows.getLastFocused")
};
class GetAllWindowsFunction : public SyncExtensionFunction {
- ~GetAllWindowsFunction() {}
virtual bool RunImpl();
DECLARE_EXTENSION_FUNCTION_NAME("windows.getAll")
};
class CreateWindowFunction : public SyncExtensionFunction {
- ~CreateWindowFunction() {}
virtual bool RunImpl();
DECLARE_EXTENSION_FUNCTION_NAME("windows.create")
};
class UpdateWindowFunction : public SyncExtensionFunction {
- ~UpdateWindowFunction() {}
virtual bool RunImpl();
DECLARE_EXTENSION_FUNCTION_NAME("windows.update")
};
class RemoveWindowFunction : public SyncExtensionFunction {
- ~RemoveWindowFunction() {}
virtual bool RunImpl();
DECLARE_EXTENSION_FUNCTION_NAME("windows.remove")
};
// Tabs
class GetTabFunction : public SyncExtensionFunction {
- ~GetTabFunction() {}
virtual bool RunImpl();
DECLARE_EXTENSION_FUNCTION_NAME("tabs.get")
};
class GetSelectedTabFunction : public SyncExtensionFunction {
- ~GetSelectedTabFunction() {}
virtual bool RunImpl();
DECLARE_EXTENSION_FUNCTION_NAME("tabs.getSelected")
};
class GetAllTabsInWindowFunction : public SyncExtensionFunction {
- ~GetAllTabsInWindowFunction() {}
virtual bool RunImpl();
DECLARE_EXTENSION_FUNCTION_NAME("tabs.getAllInWindow")
};
class CreateTabFunction : public SyncExtensionFunction {
- ~CreateTabFunction() {}
virtual bool RunImpl();
DECLARE_EXTENSION_FUNCTION_NAME("tabs.create")
};
class UpdateTabFunction : public SyncExtensionFunction {
- ~UpdateTabFunction() {}
virtual bool RunImpl();
DECLARE_EXTENSION_FUNCTION_NAME("tabs.update")
};
class MoveTabFunction : public SyncExtensionFunction {
- ~MoveTabFunction() {}
virtual bool RunImpl();
DECLARE_EXTENSION_FUNCTION_NAME("tabs.move")
};
class RemoveTabFunction : public SyncExtensionFunction {
- ~RemoveTabFunction() {}
virtual bool RunImpl();
DECLARE_EXTENSION_FUNCTION_NAME("tabs.remove")
};
class DetectTabLanguageFunction : public AsyncExtensionFunction,
public NotificationObserver {
private:
- ~DetectTabLanguageFunction() {}
virtual bool RunImpl();
virtual void Observe(NotificationType type,
@@ -135,7 +120,6 @@ class DetectTabLanguageFunction : public AsyncExtensionFunction,
DECLARE_EXTENSION_FUNCTION_NAME("tabs.detectLanguage")
};
class CaptureVisibleTabFunction : public SyncExtensionFunction {
- ~CaptureVisibleTabFunction() {}
virtual bool RunImpl();
DECLARE_EXTENSION_FUNCTION_NAME("tabs.captureVisibleTab")
};
diff --git a/chrome/browser/extensions/extension_test_api.h b/chrome/browser/extensions/extension_test_api.h
index 79adf13..6ab6857 100644
--- a/chrome/browser/extensions/extension_test_api.h
+++ b/chrome/browser/extensions/extension_test_api.h
@@ -8,21 +8,19 @@
#include "chrome/browser/extensions/extension_function.h"
class ExtensionTestPassFunction : public SyncExtensionFunction {
- ~ExtensionTestPassFunction() {}
virtual bool RunImpl();
DECLARE_EXTENSION_FUNCTION_NAME("test.notifyPass")
};
class ExtensionTestFailFunction : public SyncExtensionFunction {
- ~ExtensionTestFailFunction() {}
virtual bool RunImpl();
DECLARE_EXTENSION_FUNCTION_NAME("test.notifyFail")
};
class ExtensionTestLogFunction : public SyncExtensionFunction {
- ~ExtensionTestLogFunction() {}
virtual bool RunImpl();
DECLARE_EXTENSION_FUNCTION_NAME("test.log")
};
#endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_TEST_API_H_
+
diff --git a/chrome/browser/extensions/extension_toolstrip_api.h b/chrome/browser/extensions/extension_toolstrip_api.h
index cd4c5e0..6f648bb 100644
--- a/chrome/browser/extensions/extension_toolstrip_api.h
+++ b/chrome/browser/extensions/extension_toolstrip_api.h
@@ -17,7 +17,6 @@ namespace extension_toolstrip_api_events {
class ToolstripFunction : public SyncExtensionFunction {
protected:
- virtual ~ToolstripFunction() {}
virtual bool RunImpl();
ExtensionShelfModel* model_;
@@ -25,13 +24,11 @@ class ToolstripFunction : public SyncExtensionFunction {
};
class ToolstripExpandFunction : public ToolstripFunction {
- ~ToolstripExpandFunction() {}
virtual bool RunImpl();
DECLARE_EXTENSION_FUNCTION_NAME("toolstrip.expand")
};
class ToolstripCollapseFunction : public ToolstripFunction {
- ~ToolstripCollapseFunction() {}
virtual bool RunImpl();
DECLARE_EXTENSION_FUNCTION_NAME("toolstrip.collapse")
};
diff --git a/chrome/browser/extensions/extension_updater.cc b/chrome/browser/extensions/extension_updater.cc
index 7cf0e4d..a546b23 100644
--- a/chrome/browser/extensions/extension_updater.cc
+++ b/chrome/browser/extensions/extension_updater.cc
@@ -95,11 +95,6 @@ class ExtensionUpdaterFileHandler
LOG(WARNING) << "Failed to delete temp file " << path.value();
}
}
-
- private:
- friend class base::RefCountedThreadSafe<ExtensionUpdaterFileHandler>;
-
- ~ExtensionUpdaterFileHandler() {}
};
diff --git a/chrome/browser/extensions/extension_updater.h b/chrome/browser/extensions/extension_updater.h
index 84a5a0e..ed6ab2c 100644
--- a/chrome/browser/extensions/extension_updater.h
+++ b/chrome/browser/extensions/extension_updater.h
@@ -44,6 +44,8 @@ class ExtensionUpdater
PrefService* prefs,
int frequency_seconds);
+ virtual ~ExtensionUpdater();
+
// Starts the updater running.
void Start();
@@ -61,12 +63,10 @@ class ExtensionUpdater
}
private:
- friend class base::RefCountedThreadSafe<ExtensionUpdater>;
friend class ExtensionUpdaterTest;
friend class ExtensionUpdaterFileHandler;
friend class SafeManifestParser;
- virtual ~ExtensionUpdater();
// We need to keep track of some information associated with a url
// when doing a fetch.
diff --git a/chrome/browser/extensions/extensions_service.h b/chrome/browser/extensions/extensions_service.h
index a73263d..55e336d 100644
--- a/chrome/browser/extensions/extensions_service.h
+++ b/chrome/browser/extensions/extensions_service.h
@@ -83,6 +83,7 @@ class ExtensionsService
PrefService* prefs,
const FilePath& install_directory,
bool autoupdate_enabled);
+ virtual ~ExtensionsService();
// Gets the list of currently installed extensions.
virtual const ExtensionList* extensions() const { return &extensions_; }
@@ -227,10 +228,6 @@ class ExtensionsService
virtual std::vector<FilePath> GetTransientBlacklistPaths();
private:
- friend class base::RefCountedThreadSafe<ExtensionsService>;
-
- virtual ~ExtensionsService();
-
// Look up an extension by ID, optionally including either or both of enabled
// and disabled extensions.
Extension* GetExtensionByIdInternal(const std::string& id,
@@ -293,6 +290,8 @@ class ExtensionsServiceBackend
// preferences.
ExtensionsServiceBackend(const FilePath& install_directory);
+ virtual ~ExtensionsServiceBackend();
+
// Loads a single extension from |path| where |path| is the top directory of
// a specific extension where its manifest file lives.
// Errors are reported through ExtensionErrorReporter. On success,
@@ -328,10 +327,6 @@ class ExtensionsServiceBackend
const FilePath& path,
Extension::Location location);
private:
- friend class base::RefCountedThreadSafe<ExtensionsServiceBackend>;
-
- virtual ~ExtensionsServiceBackend();
-
// Finish installing the extension in |crx_path| after it has been unpacked to
// |unpacked_path|. If |expected_id| is not empty, it's verified against the
// extension's manifest before installation. If |silent| is true, there will
diff --git a/chrome/browser/extensions/extensions_ui.h b/chrome/browser/extensions/extensions_ui.h
index 352e42c..6023255 100644
--- a/chrome/browser/extensions/extensions_ui.h
+++ b/chrome/browser/extensions/extensions_ui.h
@@ -48,8 +48,6 @@ class ExtensionsUIHTMLSource : public ChromeURLDataManager::DataSource {
}
private:
- ~ExtensionsUIHTMLSource() {}
-
DISALLOW_COPY_AND_ASSIGN(ExtensionsUIHTMLSource);
};
diff --git a/chrome/browser/extensions/file_reader.h b/chrome/browser/extensions/file_reader.h
index 7ca6309..008450e 100644
--- a/chrome/browser/extensions/file_reader.h
+++ b/chrome/browser/extensions/file_reader.h
@@ -29,10 +29,6 @@ class FileReader : public base::RefCountedThreadSafe<FileReader> {
void Start();
private:
- friend class base::RefCountedThreadSafe<FileReader>;
-
- ~FileReader() {}
-
void ReadFileOnBackgroundThread();
void RunCallback(bool success, const std::string& data);
diff --git a/chrome/browser/extensions/image_loading_tracker.h b/chrome/browser/extensions/image_loading_tracker.h
index 23f7b71..a56aaeb 100644
--- a/chrome/browser/extensions/image_loading_tracker.h
+++ b/chrome/browser/extensions/image_loading_tracker.h
@@ -37,6 +37,7 @@ class ImageLoadingTracker
// get deleted until we get a response from image loading (see
// ImageLoadingDone).
}
+ ~ImageLoadingTracker() {}
// If there are remaining images to be loaded, the observing object should
// call this method on its destruction, so that the tracker will not attempt
@@ -55,10 +56,6 @@ class ImageLoadingTracker
private:
class LoadImageTask;
- friend class base::RefCountedThreadSafe<ImageLoadingTracker>;
-
- ~ImageLoadingTracker() {}
-
// When an image has finished loaded and scaled on the file thread, it is
// posted back to this method on the original thread. This method then calls
// the observer's OnImageLoaded and deletes the ImageLoadingTracker if it was
diff --git a/chrome/browser/extensions/pack_extension_job.h b/chrome/browser/extensions/pack_extension_job.h
index 526d16d..8a40692 100644
--- a/chrome/browser/extensions/pack_extension_job.h
+++ b/chrome/browser/extensions/pack_extension_job.h
@@ -34,10 +34,6 @@ class PackExtensionJob : public base::RefCountedThreadSafe<PackExtensionJob> {
void ClearClient();
private:
- friend class base::RefCountedThreadSafe<PackExtensionJob>;
-
- ~PackExtensionJob() {}
-
void RunOnFileThread();
void ReportSuccessOnUIThread();
void ReportFailureOnUIThread(const std::string& error);
diff --git a/chrome/browser/extensions/sandboxed_extension_unpacker.h b/chrome/browser/extensions/sandboxed_extension_unpacker.h
index b5f1741..91cd67f 100644
--- a/chrome/browser/extensions/sandboxed_extension_unpacker.h
+++ b/chrome/browser/extensions/sandboxed_extension_unpacker.h
@@ -20,6 +20,9 @@ class ResourceDispatcherHost;
class SandboxedExtensionUnpackerClient
: public base::RefCountedThreadSafe<SandboxedExtensionUnpackerClient> {
public:
+ virtual ~SandboxedExtensionUnpackerClient(){
+ }
+
// temp_dir - A temporary directoy containing the results of the extension
// unpacking. The client is responsible for deleting this directory.
//
@@ -31,11 +34,6 @@ class SandboxedExtensionUnpackerClient
const FilePath& extension_root,
Extension* extension) = 0;
virtual void OnUnpackFailure(const std::string& error) = 0;
-
- protected:
- friend class base::RefCountedThreadSafe<SandboxedExtensionUnpackerClient>;
-
- virtual ~SandboxedExtensionUnpackerClient() {}
};
// SandboxedExtensionUnpacker unpacks extensions from the CRX format into a
diff --git a/chrome/browser/extensions/user_script_listener.h b/chrome/browser/extensions/user_script_listener.h
index 7c22b53..303e354 100644
--- a/chrome/browser/extensions/user_script_listener.h
+++ b/chrome/browser/extensions/user_script_listener.h
@@ -36,12 +36,8 @@ class UserScriptListener
bool ShouldStartRequest(URLRequest* request);
private:
- friend class base::RefCountedThreadSafe<UserScriptListener>;
-
typedef std::list<URLPattern> URLPatterns;
- ~UserScriptListener() {}
-
// Resume any requests that we delayed in order to wait for user scripts.
void StartDelayedRequests();
diff --git a/chrome/browser/extensions/user_script_listener_unittest.cc b/chrome/browser/extensions/user_script_listener_unittest.cc
index e36a05f..980c3c9 100644
--- a/chrome/browser/extensions/user_script_listener_unittest.cc
+++ b/chrome/browser/extensions/user_script_listener_unittest.cc
@@ -42,9 +42,6 @@ class MockUserScriptMaster : public UserScriptMaster {
void TestStartScan() {
UserScriptMaster::StartScan();
}
-
- private:
- ~MockUserScriptMaster() {}
};
class MockIOThread : public ChromeThread {
diff --git a/chrome/browser/extensions/user_script_master.h b/chrome/browser/extensions/user_script_master.h
index a8c3fa6..270a690 100644
--- a/chrome/browser/extensions/user_script_master.h
+++ b/chrome/browser/extensions/user_script_master.h
@@ -29,6 +29,7 @@ class UserScriptMaster : public base::RefCountedThreadSafe<UserScriptMaster>,
// For testability, the constructor takes the path the scripts live in.
// This is normally a directory inside the profile.
UserScriptMaster(const FilePath& script_dir);
+ virtual ~UserScriptMaster();
// Add a watched directory. All scripts will be reloaded when any file in
// this directory changes.
@@ -52,11 +53,6 @@ class UserScriptMaster : public base::RefCountedThreadSafe<UserScriptMaster>,
// Returns the path to the directory user scripts are stored in.
FilePath user_script_dir() const { return user_script_dir_; }
- protected:
- friend class base::RefCountedThreadSafe<UserScriptMaster>;
-
- virtual ~UserScriptMaster();
-
private:
FRIEND_TEST(UserScriptMasterTest, Parse1);
FRIEND_TEST(UserScriptMasterTest, Parse2);
@@ -95,10 +91,6 @@ class UserScriptMaster : public base::RefCountedThreadSafe<UserScriptMaster>,
}
private:
- friend class base::RefCountedThreadSafe<UserScriptMaster::ScriptReloader>;
-
- ~ScriptReloader() {}
-
// Where functions are run:
// master file
// StartScan -> RunScan
diff --git a/chrome/browser/process_singleton_linux.cc b/chrome/browser/process_singleton_linux.cc
index 046d7f9..af2a519 100644
--- a/chrome/browser/process_singleton_linux.cc
+++ b/chrome/browser/process_singleton_linux.cc
@@ -402,6 +402,10 @@ class ProcessSingleton::LinuxWatcher
parent_(parent) {
}
+ virtual ~LinuxWatcher() {
+ STLDeleteElements(&readers_);
+ }
+
// Start listening for connections on the socket. This method should be
// called from the IO thread.
void StartListening(int socket);
@@ -426,12 +430,6 @@ class ProcessSingleton::LinuxWatcher
}
private:
- friend class base::RefCountedThreadSafe<ProcessSingleton::LinuxWatcher>;
-
- virtual ~LinuxWatcher() {
- STLDeleteElements(&readers_);
- }
-
// Removes and deletes the SocketReader.
void RemoveSocketReader(SocketReader* reader);
diff --git a/chrome/browser/sync/sync_setup_wizard.cc b/chrome/browser/sync/sync_setup_wizard.cc
index b05fe30..645c931 100644
--- a/chrome/browser/sync/sync_setup_wizard.cc
+++ b/chrome/browser/sync/sync_setup_wizard.cc
@@ -23,6 +23,7 @@ class SyncResourcesSource : public ChromeURLDataManager::DataSource {
SyncResourcesSource()
: DataSource(chrome::kSyncResourcesHost, MessageLoop::current()) {
}
+ virtual ~SyncResourcesSource() { }
virtual void StartDataRequest(const std::string& path, int request_id);
@@ -32,10 +33,7 @@ class SyncResourcesSource : public ChromeURLDataManager::DataSource {
else
return "text/html";
}
-
private:
- virtual ~SyncResourcesSource() {}
-
DISALLOW_COPY_AND_ASSIGN(SyncResourcesSource);
};