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

Side by Side Diff: chrome/browser/resources/gaia_auth/util.js

Issue 10443024: Added chrome switch that lets tests override URL path, moved GAIA auth extension from CrOS (Closed) 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
(Empty)
1 // Copyright (c) 2011 The Chromium OS 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 function $(id) {
6 return document.getElementById(id);
7 }
8
9 function getUrlSearchParams(search) {
10 var params = {};
11
12 if (search) {
13 // Strips leading '?'
14 search = search.substring(1);
15 var pairs = search.split('&');
16 for (var i = 0; i < pairs.length; ++i) {
17 var pair = pairs[i].split('=');
18 if (pair.length == 2) {
19 params[pair[0]] = decodeURIComponent(pair[1]);
20 } else {
21 params[pair] = true;
22 }
23 }
24 }
25
26 return params;
27 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698