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

Unified Diff: chrome/browser/chromeos/sim_dialog_delegate.cc

Issue 399303003: Eliminate use of sim unlock UI notifications (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase Created 6 years, 5 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/chromeos/sim_dialog_delegate.cc
diff --git a/chrome/browser/chromeos/sim_dialog_delegate.cc b/chrome/browser/chromeos/sim_dialog_delegate.cc
index d61c0e4fe66d78060079a3935c7a0e1bbe85d550..ebb819f1c04e05d2eb60740ad63f2b951e1f37a2 100644
--- a/chrome/browser/chromeos/sim_dialog_delegate.cc
+++ b/chrome/browser/chromeos/sim_dialog_delegate.cc
@@ -24,14 +24,6 @@ const int kDefaultHeight = 225;
const int kChangePinWidth = 350;
const int kChangePinHeight = 245;
-// URL that includes additional mode (other than Unlock flow) that we're using
-// dialog for. Possible values:
-// change-pin - use dialog to change PIN, ask for old & new PIN.
-// set-lock-on - enable RequirePin restriction.
-// set-lock-off - disable RequirePin restriction.
-// In general SIM unlock case sim-unlock URL is loaded w/o parameters.
-const char kSimDialogSpecialModeURL[] = "chrome://sim-unlock/?mode=%s";
-
// Dialog mode constants.
const char kSimDialogChangePinMode[] = "change-pin";
const char kSimDialogSetLockOnMode[] = "set-lock-on";
@@ -76,8 +68,15 @@ GURL SimDialogDelegate::GetDialogContentURL() const {
mode_value = kSimDialogSetLockOnMode;
else
mode_value = kSimDialogSetLockOffMode;
- return GURL(
- base::StringPrintf(kSimDialogSpecialModeURL, mode_value.c_str()));
+
+ // Create a URL that includes an additional mode (other than Unlock flow).
+ // Possible values for mode are:
+ // change-pin - use dialog to change PIN, ask for old & new PIN.
+ // set-lock-on - enable RequirePin restriction.
+ // set-lock-off - disable RequirePin restriction.
+ std::string url_string =
+ std::string(chrome::kChromeUISimUnlockURL) + "?mode=" + mode_value;
+ return GURL(url_string);
}
}

Powered by Google App Engine
This is Rietveld 408576698