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

Unified Diff: chrome/browser/external_protocol/external_protocol_handler.h

Issue 2076253002: Simplify the text in the external protocol confirmation dialog. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix ChromeOS compile Created 4 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/browser/external_protocol/external_protocol_handler.h
diff --git a/chrome/browser/external_protocol/external_protocol_handler.h b/chrome/browser/external_protocol/external_protocol_handler.h
index 692f2dda0aa88bd2669ad77f4d954617cac66d47..75ff77a874ce1388652539b0a79fddb6d8e740f4 100644
--- a/chrome/browser/external_protocol/external_protocol_handler.h
+++ b/chrome/browser/external_protocol/external_protocol_handler.h
@@ -67,25 +67,6 @@ class ExternalProtocolHandler {
bool has_user_gesture,
Delegate* delegate);
- // Creates and runs a External Protocol dialog box.
- // |url| - The url of the request.
- // |render_process_host_id| and |routing_id| are used by
- // tab_util::GetWebContentsByID to aquire the tab contents associated with
- // this dialog.
- // NOTE: There is a race between the Time of Check and the Time Of Use for
- // the command line. Since the caller (web page) does not have access
- // to change the command line by itself, we do not do anything special
- // to protect against this scenario.
- // This is implemented separately on each platform.
- static void RunExternalProtocolDialog(const GURL& url,
- int render_process_host_id,
- int routing_id,
- ui::PageTransition page_transition,
- bool has_user_gesture);
-
- // Register the ExcludedSchemes preference.
- static void RegisterPrefs(PrefRegistrySimple* registry);
-
// Starts a url using the external protocol handler with the help
// of shellexecute. Should only be called if the protocol is whitelisted
// (checked in LaunchUrl) or if the user explicitly allows it. (By selecting
@@ -98,16 +79,39 @@ class ExternalProtocolHandler {
int render_process_host_id,
int tab_contents_id);
- // Prepopulates the dictionary with known protocols to deny or allow, if
- // preferences for them do not already exist.
- static void PrepopulateDictionary(base::DictionaryValue* win_pref);
-
// Allows LaunchUrl to proceed with launching an external protocol handler.
// This is typically triggered by a user gesture, but is also called for
// each extension API function. Note that each call to LaunchUrl resets
// the state to false (not allowed).
static void PermitLaunchUrl();
+ // Prepopulates the dictionary with known protocols to deny or allow, if
+ // preferences for them do not already exist.
+ static void PrepopulateDictionary(base::DictionaryValue* win_pref);
+
+ // Records an UMA metric for the state of the checkbox in the dialog, i.e.
+ // whether |selected| is true (checked) or false (unchecked).
+ static void RecordMetrics(bool selected);
+
+ // Register the ExcludedSchemes preference.
+ static void RegisterPrefs(PrefRegistrySimple* registry);
+
+ // Creates and runs a External Protocol dialog box.
+ // |url| - The url of the request.
+ // |render_process_host_id| and |routing_id| are used by
+ // tab_util::GetWebContentsByID to aquire the tab contents associated with
+ // this dialog.
+ // NOTE: There is a race between the Time of Check and the Time Of Use for
+ // the command line. Since the caller (web page) does not have access
+ // to change the command line by itself, we do not do anything special
+ // to protect against this scenario.
+ // This is implemented separately on each platform.
+ static void RunExternalProtocolDialog(const GURL& url,
+ int render_process_host_id,
+ int routing_id,
+ ui::PageTransition page_transition,
+ bool has_user_gesture);
+
private:
DISALLOW_COPY_AND_ASSIGN(ExternalProtocolHandler);
};

Powered by Google App Engine
This is Rietveld 408576698