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

Unified Diff: chrome/browser/ui/webui/help/version_updater_win.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, 6 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/webui/help/version_updater_win.h
diff --git a/chrome/browser/ui/webui/help/version_updater_win.h b/chrome/browser/ui/webui/help/version_updater_win.h
new file mode 100644
index 0000000000000000000000000000000000000000..2886f1a4c6fda84fecf660cb432d698c2d7aed2d
--- /dev/null
+++ b/chrome/browser/ui/webui/help/version_updater_win.h
@@ -0,0 +1,57 @@
+// Copyright (c) 2012 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef CHROME_BROWSER_UI_WEBUI_HELP_VERSION_UPDATER_WIN_H_
+#define CHROME_BROWSER_UI_WEBUI_HELP_VERSION_UPDATER_WIN_H_
+#pragma once
+
+#include "base/compiler_specific.h"
+#include "base/memory/ref_counted.h"
+#include "base/string16.h"
+#include "chrome/browser/google/google_update.h"
+#include "chrome/browser/ui/webui/help/version_updater.h"
+
+namespace views {
+
+class Widget;
+
+}
+
+class VersionUpdaterWin : public VersionUpdater,
+ public GoogleUpdateStatusListener {
+ protected:
+ friend class VersionUpdater;
+
+ // Clients must use VersionUpdater::Create().
+ VersionUpdaterWin();
+ virtual ~VersionUpdaterWin();
+
+ private:
+ // VersionUpdater implementation.
+ static views::Widget* GetWidget();
+ virtual void CheckForUpdate(const StatusCallback& callback) OVERRIDE;
+ virtual void RelaunchBrowser() const OVERRIDE;
+
+ // GoogleUpdateStatusListener implementation.
+ virtual void OnReportResults(GoogleUpdateUpgradeResult result,
+ GoogleUpdateErrorCode error_code,
+ const string16& error_message,
+ const string16& version) OVERRIDE;
+
+ // Update the UI to show the status of the upgrade.
+ void UpdateStatus(GoogleUpdateUpgradeResult result,
+ GoogleUpdateErrorCode error_code,
+ const string16& error_message);
+
+ // The class that communicates with Google Update to find out if an update is
+ // available and asks it to start an upgrade.
+ scoped_refptr<GoogleUpdate> google_updater_;
+
+ // Callback used to communicate update status to the client.
+ StatusCallback callback_;
+
+ DISALLOW_COPY_AND_ASSIGN(VersionUpdaterWin);
+};
+
+#endif // CHROME_BROWSER_UI_WEBUI_HELP_VERSION_UPDATER_WIN_H_
« no previous file with comments | « chrome/browser/ui/webui/help/version_updater_chromeos.cc ('k') | chrome/browser/ui/webui/help/version_updater_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698