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

Side by Side Diff: chrome/browser/ui/webui/options/chromeos/about_page_handler.h

Issue 9814030: get rid of old options pages (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: more fixes Created 8 years, 9 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
(Empty)
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef CHROME_BROWSER_UI_WEBUI_OPTIONS_CHROMEOS_ABOUT_PAGE_HANDLER_H_
6 #define CHROME_BROWSER_UI_WEBUI_OPTIONS_CHROMEOS_ABOUT_PAGE_HANDLER_H_
7
8 #include <string>
9
10 #include "base/compiler_specific.h"
11 #include "chrome/browser/ui/webui/options/options_ui.h"
12 #include "chrome/browser/chromeos/dbus/update_engine_client.h"
13 #include "chrome/browser/chromeos/version_loader.h"
14
15 namespace chromeos {
16
17 // ChromeOS about page UI handler.
18 class AboutPageHandler : public OptionsPageUIHandler {
19
20 public:
21 AboutPageHandler();
22 virtual ~AboutPageHandler();
23
24 // OptionsPageUIHandler implementation.
25 virtual void GetLocalizedValues(
26 base::DictionaryValue* localized_strings) OVERRIDE;
27 virtual void RegisterMessages() OVERRIDE;
28
29 private:
30 class UpdateObserver;
31
32 // The function is called from JavaScript when the about page is ready.
33 void PageReady(const base::ListValue* args);
34
35 // The function is called from JavaScript to set the release track like
36 // "beta-channel" and "dev-channel".
37 void SetReleaseTrack(const base::ListValue* args);
38
39 // Initiates update check.
40 void CheckNow(const base::ListValue* args);
41
42 // Restarts the system.
43 void RestartNow(const base::ListValue* args);
44
45 // Callback from VersionLoader giving the version.
46 void OnOSVersion(VersionLoader::Handle handle,
47 std::string version);
48 void OnOSFirmware(VersionLoader::Handle handle,
49 std::string firmware);
50 void UpdateStatus(const UpdateEngineClient::Status& status);
51
52 // UpdateEngine Callback handler.
53 static void UpdateSelectedChannel(UpdateObserver* observer,
54 const std::string& channel);
55
56 // Handles asynchronously loading the version.
57 VersionLoader loader_;
58
59 // Used to request the version.
60 CancelableRequestConsumer consumer_;
61
62 // Update Observer
63 scoped_ptr<UpdateObserver> update_observer_;
64
65 int progress_;
66 bool sticky_;
67 bool started_;
68
69 DISALLOW_COPY_AND_ASSIGN(AboutPageHandler);
70 };
71
72 } // namespace chromeos
73
74 #endif // CHROME_BROWSER_UI_WEBUI_OPTIONS_CHROMEOS_ABOUT_PAGE_HANDLER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698