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

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

Issue 9320056: Help: Implement the initial version of the cross-platform help/about page. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: String fix. Created 8 years, 10 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) 2012 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_HELP_VERSION_UPDATER_H_
6 #define CHROME_BROWSER_UI_WEBUI_HELP_VERSION_UPDATER_H_
7 #pragma once
8
9 #include "base/callback.h"
10
11 // Interface implemented to expose per-platform updating functionality.
12 class VersionUpdater {
13 public:
14 // Update process state machine.
15 enum Status {
16 CHECKING,
17 UPDATING,
18 NEARLY_UPDATED,
19 UPDATED
20 };
21
22 // Used to update the client of status changes. int parameter is the progress
23 // and should only be non-zero for the UPDATING state.
24 typedef base::Callback<void(Status, int)> StatusCallback;
25
26 virtual ~VersionUpdater() {}
27
28 // Sub-classes must implement this method to create the respective
29 // specialization.
30 static VersionUpdater* Create();
31
32 // Begins the update process. |callback| is called for each status update.
33 virtual void CheckForUpdate(const StatusCallback& callback) = 0;
34
35 // Relaunches the browser, generally after being updated.
36 virtual void RelaunchBrowser() const = 0;
37 };
38
39 #endif // CHROME_BROWSER_UI_WEBUI_HELP_VERSION_UPDATER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698