OLD | NEW |
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_HELP_HANDLER_H_ | 5 #ifndef CHROME_BROWSER_UI_WEBUI_HELP_HELP_HANDLER_H_ |
6 #define CHROME_BROWSER_UI_WEBUI_HELP_HELP_HANDLER_H_ | 6 #define CHROME_BROWSER_UI_WEBUI_HELP_HELP_HANDLER_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/compiler_specific.h" | 10 #include "base/compiler_specific.h" |
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
53 void RelaunchNow(const base::ListValue* args); | 53 void RelaunchNow(const base::ListValue* args); |
54 | 54 |
55 // Opens the feedback dialog. |args| must be empty. | 55 // Opens the feedback dialog. |args| must be empty. |
56 void OpenFeedbackDialog(const base::ListValue* args); | 56 void OpenFeedbackDialog(const base::ListValue* args); |
57 | 57 |
58 // Opens the help page. |args| must be empty. | 58 // Opens the help page. |args| must be empty. |
59 void OpenHelpPage(const base::ListValue* args); | 59 void OpenHelpPage(const base::ListValue* args); |
60 | 60 |
61 #if defined(OS_CHROMEOS) | 61 #if defined(OS_CHROMEOS) |
62 // Sets the release track version. | 62 // Sets the release track version. |
63 void SetReleaseTrack(const base::ListValue* args); | 63 void SetChannel(const base::ListValue* args); |
64 #endif | 64 #endif |
65 | 65 |
66 // Callback method which forwards status updates to the page. | 66 // Callback method which forwards status updates to the page. |
67 void SetUpdateStatus(VersionUpdater::Status status, int progress, | 67 void SetUpdateStatus(VersionUpdater::Status status, int progress, |
68 const string16& fail_message); | 68 const string16& fail_message); |
69 | 69 |
70 #if defined(OS_MACOSX) | 70 #if defined(OS_MACOSX) |
71 // Callback method which forwards promotion state to the page. | 71 // Callback method which forwards promotion state to the page. |
72 void SetPromotionState(VersionUpdater::PromotionState state); | 72 void SetPromotionState(VersionUpdater::PromotionState state); |
73 #endif | 73 #endif |
74 | 74 |
75 #if defined(OS_CHROMEOS) | 75 #if defined(OS_CHROMEOS) |
76 // Callbacks from VersionLoader. | 76 // Callbacks from VersionLoader. |
77 void OnOSVersion(const std::string& version); | 77 void OnOSVersion(const std::string& version); |
78 void OnOSFirmware(const std::string& firmware); | 78 void OnOSFirmware(const std::string& firmware); |
79 void OnReleaseChannel(const std::string& channel); | 79 void OnCurrentChannel(const std::string& channel); |
| 80 void OnTargetChannel(const std::string& channel); |
80 | 81 |
81 void ProcessLsbFileInfo( | 82 void ProcessLsbFileInfo( |
82 base::PlatformFileError rv, const base::PlatformFileInfo& file_info); | 83 base::PlatformFileError rv, const base::PlatformFileInfo& file_info); |
83 #endif | 84 #endif |
84 | 85 |
85 // Specialized instance of the VersionUpdater used to update the browser. | 86 // Specialized instance of the VersionUpdater used to update the browser. |
86 scoped_ptr<VersionUpdater> version_updater_; | 87 scoped_ptr<VersionUpdater> version_updater_; |
87 | 88 |
88 // Used for callbacks. | 89 // Used for callbacks. |
89 base::WeakPtrFactory<HelpHandler> weak_factory_; | 90 base::WeakPtrFactory<HelpHandler> weak_factory_; |
90 | 91 |
91 // Used to observe notifications. | 92 // Used to observe notifications. |
92 content::NotificationRegistrar registrar_; | 93 content::NotificationRegistrar registrar_; |
93 | 94 |
94 #if defined(OS_CHROMEOS) | 95 #if defined(OS_CHROMEOS) |
95 // Handles asynchronously loading the CrOS version info. | 96 // Handles asynchronously loading the CrOS version info. |
96 chromeos::VersionLoader loader_; | 97 chromeos::VersionLoader loader_; |
97 | 98 |
98 // Used to request the version. | 99 // Used to request the version. |
99 CancelableTaskTracker tracker_; | 100 CancelableTaskTracker tracker_; |
100 #endif // defined(OS_CHROMEOS) | 101 #endif // defined(OS_CHROMEOS) |
101 | 102 |
102 DISALLOW_COPY_AND_ASSIGN(HelpHandler); | 103 DISALLOW_COPY_AND_ASSIGN(HelpHandler); |
103 }; | 104 }; |
104 | 105 |
105 #endif // CHROME_BROWSER_UI_WEBUI_HELP_HELP_HANDLER_H_ | 106 #endif // CHROME_BROWSER_UI_WEBUI_HELP_HELP_HANDLER_H_ |
OLD | NEW |