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

Side by Side Diff: chrome/browser/ui/webui/help/version_updater_chromeos.h

Issue 10699039: Switch to using the WebUI About screen on Windows. Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 5 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 CHROME_BROWSER_UI_WEBUI_HELP_VERSION_UPDATER_CHROMEOS_H_ 5 #ifndef CHROME_BROWSER_UI_WEBUI_HELP_VERSION_UPDATER_CHROMEOS_H_
6 #define CHROME_BROWSER_UI_WEBUI_HELP_VERSION_UPDATER_CHROMEOS_H_ 6 #define CHROME_BROWSER_UI_WEBUI_HELP_VERSION_UPDATER_CHROMEOS_H_
7 #pragma once 7 #pragma once
8 8
9 #include "base/compiler_specific.h" 9 #include "base/compiler_specific.h"
10 #include "base/memory/weak_ptr.h" 10 #include "base/memory/weak_ptr.h"
11 #include "chrome/browser/ui/webui/help/version_updater.h" 11 #include "chrome/browser/ui/webui/help/version_updater.h"
12 #include "chromeos/dbus/update_engine_client.h" 12 #include "chromeos/dbus/update_engine_client.h"
13 13
14 class VersionUpdaterCros : public VersionUpdater, 14 class VersionUpdaterCros : public VersionUpdater,
15 public chromeos::UpdateEngineClient::Observer { 15 public chromeos::UpdateEngineClient::Observer {
16 public:
17 // VersionUpdater implementation.
18 virtual void CheckForUpdate(const StatusCallback& callback) OVERRIDE;
19 virtual void RelaunchBrowser() const OVERRIDE;
20 virtual void SetReleaseChannel(const std::string& channel) OVERRIDE;
21 virtual void GetReleaseChannel(const ChannelCallback& callback) OVERRIDE;
22
23 protected: 16 protected:
24 friend class VersionUpdater; 17 friend class VersionUpdater;
25 18
26 // Clients must use VersionUpdater::Create(). 19 // Clients must use VersionUpdater::Create().
27 VersionUpdaterCros(); 20 VersionUpdaterCros();
28 virtual ~VersionUpdaterCros(); 21 virtual ~VersionUpdaterCros();
29 22
30 private: 23 private:
24 // VersionUpdater implementation.
25 virtual void CheckForUpdate(const StatusCallback& callback) OVERRIDE;
26 virtual void RelaunchBrowser() const OVERRIDE;
27 virtual void SetReleaseChannel(const std::string& channel) OVERRIDE;
28 virtual void GetReleaseChannel(const ChannelCallback& callback) OVERRIDE;
29
31 // UpdateEngineClient::Observer implementation. 30 // UpdateEngineClient::Observer implementation.
32 virtual void UpdateStatusChanged( 31 virtual void UpdateStatusChanged(
33 const chromeos::UpdateEngineClient::Status& status) OVERRIDE; 32 const chromeos::UpdateEngineClient::Status& status) OVERRIDE;
34 33
35 // Callback from UpdateEngineClient::RequestUpdateCheck(). 34 // Callback from UpdateEngineClient::RequestUpdateCheck().
36 void OnUpdateCheck(chromeos::UpdateEngineClient::UpdateCheckResult result); 35 void OnUpdateCheck(chromeos::UpdateEngineClient::UpdateCheckResult result);
37 36
38 // Callback from UpdateEngineClient::GetReleaseTrack(). 37 // Callback from UpdateEngineClient::GetReleaseTrack().
39 void UpdateSelectedChannel(const std::string& channel); 38 void UpdateSelectedChannel(const std::string& channel);
40 39
41 // Callback used to communicate update status to the client. 40 // Callback used to communicate update status to the client.
42 StatusCallback callback_; 41 StatusCallback callback_;
43 42
44 // Callback used to communicate current channel to the client. 43 // Callback used to communicate current channel to the client.
45 ChannelCallback channel_callback_; 44 ChannelCallback channel_callback_;
46 45
47 base::WeakPtrFactory<VersionUpdaterCros> weak_ptr_factory_; 46 base::WeakPtrFactory<VersionUpdaterCros> weak_ptr_factory_;
48 47
49 DISALLOW_COPY_AND_ASSIGN(VersionUpdaterCros); 48 DISALLOW_COPY_AND_ASSIGN(VersionUpdaterCros);
50 }; 49 };
51 50
52 #endif // CHROME_BROWSER_UI_WEBUI_HELP_VERSION_UPDATER_CHROMEOS_H_ 51 #endif // CHROME_BROWSER_UI_WEBUI_HELP_VERSION_UPDATER_CHROMEOS_H_
OLDNEW
« no previous file with comments | « chrome/browser/ui/webui/help/help_handler.cc ('k') | chrome/browser/ui/webui/help/version_updater_chromeos.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698