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

Unified Diff: chrome/installer/util/shell_util.h

Issue 11127002: Move "default for protocol" probing logic out of shell_integration_win.cc into shell_util.cc. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: better order in enum Created 8 years, 2 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/installer/util/shell_util.h
diff --git a/chrome/installer/util/shell_util.h b/chrome/installer/util/shell_util.h
index a67a7243fb62c2564f76b264a5f2edc65a6a1431..745c0fcb2805d8a3eee19e89b3c2bd1b14ca39be 100644
--- a/chrome/installer/util/shell_util.h
+++ b/chrome/installer/util/shell_util.h
@@ -32,6 +32,13 @@ class ShellUtil {
SYSTEM_LEVEL = 0x2 // Make any shell changes only at the system level
};
+ // Chrome's default handler state for a given protocol.
+ enum DefaultState {
+ UNKNOWN_DEFAULT,
+ NOT_DEFAULT,
+ IS_DEFAULT,
+ };
+
// Typical shortcut directories. Resolved in GetShortcutPath().
enum ChromeShortcutLocation {
SHORTCUT_DESKTOP,
@@ -379,6 +386,12 @@ class ShellUtil {
// Windows prior to Windows 8.
static bool CanMakeChromeDefaultUnattended();
+ // Returns true if Chrome is the default handler for HTTP and HTTPS.
+ static DefaultState IsChromeDefault();
+
+ // Returns true if Chrome is the default handler for |protocol|.
+ static DefaultState IsChromeDefaultProtocolClient(const string16& protocol);
+
// Make Chrome the default browser. This function works by going through
// the url protocols and file associations that are related to general
// browsing, e.g. http, https, .html etc., and requesting to become the

Powered by Google App Engine
This is Rietveld 408576698