diff options
Diffstat (limited to 'chrome/browser')
20 files changed, 61 insertions, 67 deletions
diff --git a/chrome/browser/chrome_select_file_dialog_factory_win.cc b/chrome/browser/chrome_select_file_dialog_factory_win.cc index 40d3baa..98d8a6d 100644 --- a/chrome/browser/chrome_select_file_dialog_factory_win.cc +++ b/chrome/browser/chrome_select_file_dialog_factory_win.cc @@ -72,7 +72,7 @@ class GetOpenFileNameClient : public content::UtilityProcessHostClient { bool OnMessageReceived(const IPC::Message& message) override; protected: - virtual ~GetOpenFileNameClient(); + ~GetOpenFileNameClient() override; private: void OnResult(const base::FilePath& directory, @@ -205,7 +205,7 @@ class GetSaveFileNameClient : public content::UtilityProcessHostClient { bool OnMessageReceived(const IPC::Message& message) override; protected: - virtual ~GetSaveFileNameClient(); + ~GetSaveFileNameClient() override; private: void OnResult(const base::FilePath& path, int one_based_filter_index); diff --git a/chrome/browser/component_updater/sw_reporter_installer_win.cc b/chrome/browser/component_updater/sw_reporter_installer_win.cc index 3ba5527..4dddf2e 100644 --- a/chrome/browser/component_updater/sw_reporter_installer_win.cc +++ b/chrome/browser/component_updater/sw_reporter_installer_win.cc @@ -290,23 +290,23 @@ class SwReporterInstallerTraits : public ComponentInstallerTraits { public: explicit SwReporterInstallerTraits(PrefService* prefs) : prefs_(prefs) {} - virtual ~SwReporterInstallerTraits() {} + ~SwReporterInstallerTraits() override {} - virtual bool VerifyInstallation(const base::DictionaryValue& manifest, - const base::FilePath& dir) const { + bool VerifyInstallation(const base::DictionaryValue& manifest, + const base::FilePath& dir) const override { return base::PathExists(dir.Append(kSwReporterExeName)); } - virtual bool CanAutoUpdate() const { return true; } + bool CanAutoUpdate() const override { return true; } - virtual bool OnCustomInstall(const base::DictionaryValue& manifest, - const base::FilePath& install_dir) { + bool OnCustomInstall(const base::DictionaryValue& manifest, + const base::FilePath& install_dir) override { return true; } - virtual void ComponentReady(const base::Version& version, - const base::FilePath& install_dir, - scoped_ptr<base::DictionaryValue> manifest) { + void ComponentReady(const base::Version& version, + const base::FilePath& install_dir, + scoped_ptr<base::DictionaryValue> manifest) override { DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); ReportVersionWithUma(version); @@ -352,11 +352,11 @@ class SwReporterInstallerTraits : public ComponentInstallerTraits { } } - virtual base::FilePath GetBaseDirectory() const { return install_dir(); } + base::FilePath GetBaseDirectory() const override { return install_dir(); } - virtual void GetHash(std::vector<uint8_t>* hash) const { GetPkHash(hash); } + void GetHash(std::vector<uint8_t>* hash) const override { GetPkHash(hash); } - virtual std::string GetName() const { return "Software Reporter Tool"; } + std::string GetName() const override { return "Software Reporter Tool"; } static base::FilePath install_dir() { // The base directory on windows looks like: diff --git a/chrome/browser/diagnostics/diagnostics_writer.cc b/chrome/browser/diagnostics/diagnostics_writer.cc index 835c24f..f219812 100644 --- a/chrome/browser/diagnostics/diagnostics_writer.cc +++ b/chrome/browser/diagnostics/diagnostics_writer.cc @@ -67,22 +67,18 @@ class WinConsole : public SimpleConsole { ::AllocConsole(); } - virtual ~WinConsole() { - ::FreeConsole(); - } + ~WinConsole() override { ::FreeConsole(); } - virtual bool Init() { - return SetIOHandles(); - } + bool Init() override { return SetIOHandles(); } - virtual bool Write(const base::string16& txt) { + bool Write(const base::string16& txt) override { DWORD sz = txt.size(); return (TRUE == ::WriteConsoleW(std_out_, txt.c_str(), sz, &sz, NULL)); } // Reads a string from the console. Internally it is limited to 256 // characters. - virtual void OnQuit() { + void OnQuit() override { // Block here so the user can see the results. SetColor(SimpleConsole::DEFAULT); Write(L"Press [enter] to continue\n"); @@ -92,7 +88,7 @@ class WinConsole : public SimpleConsole { } // Sets the foreground and background color. - virtual bool SetColor(Color color) { + bool SetColor(Color color) override { uint16 color_combo = FOREGROUND_RED | FOREGROUND_GREEN | FOREGROUND_BLUE | FOREGROUND_INTENSITY; switch (color) { diff --git a/chrome/browser/first_run/try_chrome_dialog_view.h b/chrome/browser/first_run/try_chrome_dialog_view.h index 48ed058..5a0de80 100644 --- a/chrome/browser/first_run/try_chrome_dialog_view.h +++ b/chrome/browser/first_run/try_chrome_dialog_view.h @@ -85,7 +85,7 @@ class TryChromeDialogView : public views::ButtonListener, private: explicit TryChromeDialogView(size_t flavor); - virtual ~TryChromeDialogView(); + ~TryChromeDialogView() override; Result ShowModal(const ActiveModalDialogListener& listener); diff --git a/chrome/browser/first_run/try_chrome_dialog_view_browsertest.cc b/chrome/browser/first_run/try_chrome_dialog_view_browsertest.cc index 17778bf..aafa507 100644 --- a/chrome/browser/first_run/try_chrome_dialog_view_browsertest.cc +++ b/chrome/browser/first_run/try_chrome_dialog_view_browsertest.cc @@ -29,7 +29,7 @@ public: } protected: - virtual void SetUpCommandLine(base::CommandLine* command_line) { + void SetUpCommandLine(base::CommandLine* command_line) override { command_line->AppendSwitchASCII(switches::kTryChromeAgain, "10001"); } }; diff --git a/chrome/browser/google/google_update_win.cc b/chrome/browser/google/google_update_win.cc index 791279a..1e0d1b9 100644 --- a/chrome/browser/google/google_update_win.cc +++ b/chrome/browser/google/google_update_win.cc @@ -173,16 +173,16 @@ class GoogleUpdateJobObserver : public CComObjectRootEx<CComSingleThreadModel>, private: // IJobObserver: - STDMETHOD(OnShow)(); - STDMETHOD(OnCheckingForUpdate)(); - STDMETHOD(OnUpdateAvailable)(const TCHAR* version_string); - STDMETHOD(OnWaitingToDownload)(); - STDMETHOD(OnDownloading)(int time_remaining_ms, int pos); - STDMETHOD(OnWaitingToInstall)(); - STDMETHOD(OnInstalling)(); - STDMETHOD(OnPause)(); - STDMETHOD(OnComplete)(LegacyCompletionCodes code, const TCHAR* text); - STDMETHOD(SetEventSink)(IProgressWndEvents* event_sink); + STDMETHOD(OnShow)() override; + STDMETHOD(OnCheckingForUpdate)() override; + STDMETHOD(OnUpdateAvailable)(const TCHAR* version_string) override; + STDMETHOD(OnWaitingToDownload)() override; + STDMETHOD(OnDownloading)(int time_remaining_ms, int pos) override; + STDMETHOD(OnWaitingToInstall)() override; + STDMETHOD(OnInstalling)() override; + STDMETHOD(OnPause)() override; + STDMETHOD(OnComplete)(LegacyCompletionCodes code, const TCHAR* text) override; + STDMETHOD(SetEventSink)(IProgressWndEvents* event_sink) override; // The task runner associated with the thread in which the job runs. scoped_refptr<base::SingleThreadTaskRunner> task_runner_; diff --git a/chrome/browser/hang_monitor/hung_plugin_action.h b/chrome/browser/hang_monitor/hung_plugin_action.h index 5ad00bb..bc38ef5 100644 --- a/chrome/browser/hang_monitor/hung_plugin_action.h +++ b/chrome/browser/hang_monitor/hung_plugin_action.h @@ -21,9 +21,9 @@ class HungPluginAction : public HungWindowDetector::HungWindowNotification { HungPluginAction(); ~HungPluginAction(); // HungWindowNotification implementation - virtual bool OnHungWindowDetected(HWND hung_window, - HWND top_level_window, - ActionOnHungWindow* action); + bool OnHungWindowDetected(HWND hung_window, + HWND top_level_window, + ActionOnHungWindow* action) override; protected: void OnWindowResponsive(HWND window); diff --git a/chrome/browser/hang_monitor/hung_window_detector.h b/chrome/browser/hang_monitor/hung_window_detector.h index 5cf8b7e..4404cec 100644 --- a/chrome/browser/hang_monitor/hung_window_detector.h +++ b/chrome/browser/hang_monitor/hung_window_detector.h @@ -48,7 +48,7 @@ class HungWindowDetector : public WorkerThreadTicker::Callback { // Note that the Initialize method needs to be called to initiate monitoring // of hung windows. explicit HungWindowDetector(HungWindowNotification* notification); - ~HungWindowDetector(); + ~HungWindowDetector() override; // This method initialized the monitoring of hung windows. All descendant // windows of the passed-in top-level window which belong to a thread @@ -62,7 +62,7 @@ class HungWindowDetector : public WorkerThreadTicker::Callback { int message_response_timeout); // Implementation of the WorkerThreadTicker::Callback interface - virtual void OnTick(); + void OnTick() override; private: // Helper function that checks whether the specified child window is hung. diff --git a/chrome/browser/importer/ie_importer_browsertest_win.cc b/chrome/browser/importer/ie_importer_browsertest_win.cc index 828f9d1..9872017 100644 --- a/chrome/browser/importer/ie_importer_browsertest_win.cc +++ b/chrome/browser/importer/ie_importer_browsertest_win.cc @@ -347,7 +347,7 @@ class TestObserver : public ProfileWriter, favicon_count_ += usage.size(); } - virtual void AddIE7PasswordInfo(const IE7PasswordInfo& info) { + void AddIE7PasswordInfo(const IE7PasswordInfo& info) override { // This function also gets called for the IEImporter test. Ignore. if (ie_version_ == IE7) { EXPECT_EQ(L"Test1", info.url_hash); @@ -357,13 +357,13 @@ class TestObserver : public ProfileWriter, } } - virtual void AddHomepage(const GURL& homepage) { + void AddHomepage(const GURL& homepage) override { EXPECT_EQ(homepage.spec(), "http://www.test.com/"); ++homepage_count_; } private: - ~TestObserver() {} + ~TestObserver() override {} size_t bookmark_count_; size_t history_count_; diff --git a/chrome/browser/jumplist_win.h b/chrome/browser/jumplist_win.h index cd46088..72b6d02 100644 --- a/chrome/browser/jumplist_win.h +++ b/chrome/browser/jumplist_win.h @@ -86,7 +86,7 @@ class JumpList : public TabRestoreServiceObserver, friend struct content::BrowserThread::DeleteOnThread< content::BrowserThread::UI>; friend class base::DeleteHelper<JumpList>; - virtual ~JumpList(); + ~JumpList() override; // Creates a ShellLinkItem object from a tab (or a window) and add it to the // given list. diff --git a/chrome/browser/password_manager/password_store_win.h b/chrome/browser/password_manager/password_store_win.h index bfa8c83..00ab273 100644 --- a/chrome/browser/password_manager/password_store_win.h +++ b/chrome/browser/password_manager/password_store_win.h @@ -38,7 +38,7 @@ class PasswordStoreWin : public password_manager::PasswordStoreDefault { private: class DBHandler; - virtual ~PasswordStoreWin(); + ~PasswordStoreWin() override; // Invoked from Shutdown, but run on the DB thread. void ShutdownOnDBThread(); diff --git a/chrome/browser/password_manager/password_store_win_unittest.cc b/chrome/browser/password_manager/password_store_win_unittest.cc index 1abeb39..f46823f 100644 --- a/chrome/browser/password_manager/password_store_win_unittest.cc +++ b/chrome/browser/password_manager/password_store_win_unittest.cc @@ -114,7 +114,7 @@ class PasswordStoreWinTest : public testing::Test { return true; } - virtual void SetUp() { + void SetUp() override { ASSERT_TRUE(db_thread_.Start()); ASSERT_TRUE(temp_dir_.CreateUniqueTempDir()); @@ -134,7 +134,7 @@ class PasswordStoreWinTest : public testing::Test { wds_->Init(); } - virtual void TearDown() { + void TearDown() override { if (store_.get()) store_->Shutdown(); wds_->ShutdownOnUIThread(); diff --git a/chrome/browser/printing/pdf_to_emf_converter.cc b/chrome/browser/printing/pdf_to_emf_converter.cc index 0e22cca..f7bfceb 100644 --- a/chrome/browser/printing/pdf_to_emf_converter.cc +++ b/chrome/browser/printing/pdf_to_emf_converter.cc @@ -61,7 +61,7 @@ class LazyEmf : public MetafilePlayer { public: LazyEmf(const scoped_refptr<RefCountedTempDir>& temp_dir, ScopedTempFile file) : temp_dir_(temp_dir), file_(file.Pass()) {} - virtual ~LazyEmf() { Close(); } + ~LazyEmf() override { Close(); } bool SafePlayback(HDC hdc) const override; bool SaveTo(base::File* file) const override; @@ -142,7 +142,7 @@ class PdfToEmfUtilityProcessHostClient ScopedTempFile emf_; }; - virtual ~PdfToEmfUtilityProcessHostClient(); + ~PdfToEmfUtilityProcessHostClient() override; bool Send(IPC::Message* msg); @@ -181,7 +181,7 @@ class PdfToEmfConverterImpl : public PdfToEmfConverter { public: PdfToEmfConverterImpl(); - virtual ~PdfToEmfConverterImpl(); + ~PdfToEmfConverterImpl() override; void Start(const scoped_refptr<base::RefCountedMemory>& data, const PdfRenderSettings& conversion_settings, diff --git a/chrome/browser/ui/views/accessibility/navigation_accessibility_uitest_win.cc b/chrome/browser/ui/views/accessibility/navigation_accessibility_uitest_win.cc index 7205f9e..9f0e8e0 100644 --- a/chrome/browser/ui/views/accessibility/navigation_accessibility_uitest_win.cc +++ b/chrome/browser/ui/views/accessibility/navigation_accessibility_uitest_win.cc @@ -178,7 +178,7 @@ void CALLBACK WinAccessibilityEventMonitor::WinEventHookThunk( class NavigationAccessibilityTest : public InProcessBrowserTest { protected: NavigationAccessibilityTest() {} - virtual ~NavigationAccessibilityTest() {} + ~NavigationAccessibilityTest() override {} void SendKeyPress(ui::KeyboardCode key) { gfx::NativeWindow native_window = browser()->window()->GetNativeWindow(); diff --git a/chrome/browser/ui/views/message_center/web_notification_tray.h b/chrome/browser/ui/views/message_center/web_notification_tray.h index e08984c..e9fcc565 100644 --- a/chrome/browser/ui/views/message_center/web_notification_tray.h +++ b/chrome/browser/ui/views/message_center/web_notification_tray.h @@ -71,7 +71,7 @@ class WebNotificationTray : public message_center::MessageCenterTrayDelegate, // This shows a platform-specific balloon informing the user of the existence // of the message center in the status tray area. - void DisplayFirstRunBalloon(); + void DisplayFirstRunBalloon() override; void EnforceStatusIconVisible(); #endif diff --git a/chrome/browser/ui/views/status_icons/status_tray_state_changer_win.h b/chrome/browser/ui/views/status_icons/status_tray_state_changer_win.h index 42ec2c0..78327f9 100644 --- a/chrome/browser/ui/views/status_icons/status_tray_state_changer_win.h +++ b/chrome/browser/ui/views/status_icons/status_tray_state_changer_win.h @@ -72,10 +72,10 @@ class StatusTrayStateChangerWin : public INotificationCB, // entry in Explorer's list of notification area icons, and ever time // one of them changes, until UnregisterCallback is called or |this| // is destroyed. - virtual HRESULT STDMETHODCALLTYPE Notify(ULONG, NOTIFYITEM*); + HRESULT STDMETHODCALLTYPE Notify(ULONG, NOTIFYITEM*) override; protected: - virtual ~StatusTrayStateChangerWin(); + ~StatusTrayStateChangerWin() override; private: friend class StatusTrayStateChangerWinTest; diff --git a/chrome/browser/ui/views/status_icons/status_tray_win_unittest.cc b/chrome/browser/ui/views/status_icons/status_tray_win_unittest.cc index 450d371..babdfca 100644 --- a/chrome/browser/ui/views/status_icons/status_tray_win_unittest.cc +++ b/chrome/browser/ui/views/status_icons/status_tray_win_unittest.cc @@ -21,7 +21,7 @@ class FakeStatusTrayStateChangerProxy : public StatusTrayStateChangerProxy { FakeStatusTrayStateChangerProxy() : enqueue_called_(false), icon_id_(0), window_(NULL) {} - virtual void EnqueueChange(UINT icon_id, HWND window) { + void EnqueueChange(UINT icon_id, HWND window) override { enqueue_called_ = true; icon_id_ = icon_id; window_ = window; @@ -44,10 +44,8 @@ class FakeStatusIconObserver : public StatusIconObserver { FakeStatusIconObserver() : balloon_clicked_(false), status_icon_click_count_(0) {} - virtual void OnStatusIconClicked() { - ++status_icon_click_count_; - } - virtual void OnBalloonClicked() { balloon_clicked_ = true; } + void OnStatusIconClicked() override { ++status_icon_click_count_; } + void OnBalloonClicked() override { balloon_clicked_ = true; } bool balloon_clicked() const { return balloon_clicked_; } size_t status_icon_click_count() const { return status_icon_click_count_; diff --git a/chrome/browser/ui/views/tabs/window_finder_win.cc b/chrome/browser/ui/views/tabs/window_finder_win.cc index 33d401f0..d2cf4db 100644 --- a/chrome/browser/ui/views/tabs/window_finder_win.cc +++ b/chrome/browser/ui/views/tabs/window_finder_win.cc @@ -72,7 +72,7 @@ class TopMostFinder : public BaseWindowFinder { return finder.is_top_most_; } - virtual bool ShouldStopIterating(HWND hwnd) { + bool ShouldStopIterating(HWND hwnd) override { if (hwnd == target_) { // Window is topmost, stop iterating. is_top_most_ = true; @@ -176,7 +176,7 @@ class LocalProcessWindowFinder : public BaseWindowFinder { } protected: - virtual bool ShouldStopIterating(HWND hwnd) { + bool ShouldStopIterating(HWND hwnd) override { RECT r; if (IsWindowVisible(hwnd) && GetWindowRect(hwnd, &r) && PtInRect(&r, screen_loc_.ToPOINT())) { diff --git a/chrome/browser/ui/webui/conflicts_ui.cc b/chrome/browser/ui/webui/conflicts_ui.cc index 39f10ae..e101888 100644 --- a/chrome/browser/ui/webui/conflicts_ui.cc +++ b/chrome/browser/ui/webui/conflicts_ui.cc @@ -80,10 +80,10 @@ class ConflictsDOMHandler : public WebUIMessageHandler, public content::NotificationObserver { public: ConflictsDOMHandler() {} - virtual ~ConflictsDOMHandler() {} + ~ConflictsDOMHandler() override {} // WebUIMessageHandler implementation. - virtual void RegisterMessages(); + void RegisterMessages() override; // Callback for the "requestModuleList" message. void HandleRequestModuleList(const base::ListValue* args); @@ -93,7 +93,7 @@ class ConflictsDOMHandler : public WebUIMessageHandler, void Observe(int type, const content::NotificationSource& source, - const content::NotificationDetails& details); + const content::NotificationDetails& details) override; content::NotificationRegistrar registrar_; diff --git a/chrome/browser/web_applications/update_shortcut_worker_win.h b/chrome/browser/web_applications/update_shortcut_worker_win.h index 825a3ea..b56b2ed 100644 --- a/chrome/browser/web_applications/update_shortcut_worker_win.h +++ b/chrome/browser/web_applications/update_shortcut_worker_win.h @@ -31,9 +31,9 @@ class UpdateShortcutWorker : public content::NotificationObserver { private: // Overridden from content::NotificationObserver: - virtual void Observe(int type, - const content::NotificationSource& source, - const content::NotificationDetails& details); + void Observe(int type, + const content::NotificationSource& source, + const content::NotificationDetails& details) override; // Downloads icon via the FaviconDriver. void DownloadIcon(); |