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

Side by Side Diff: chrome/common/extensions/docs/js/bootstrap.js

Issue 9350019: Adding a trailing '/' to the doc switcher URL. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: License. Created 8 years, 10 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium 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
1 var fileXHREnabled = function() { 5 var fileXHREnabled = function() {
2 var xhr = new XMLHttpRequest(); 6 var xhr = new XMLHttpRequest();
3 try { 7 try {
4 xhr.onreadystatechange = function() {}; 8 xhr.onreadystatechange = function() {};
5 xhr.onerror = function() {}; 9 xhr.onerror = function() {};
6 xhr.open("GET", "nothing.xml", true); 10 xhr.open("GET", "nothing.xml", true);
7 xhr.send(null); 11 xhr.send(null);
8 } catch (e) { 12 } catch (e) {
9 return false; 13 return false;
10 } 14 }
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
69 if (currentBranch == '') { 73 if (currentBranch == '') {
70 document.getElementById('unofficialWarning').style.display = 'block'; 74 document.getElementById('unofficialWarning').style.display = 'block';
71 document.getElementById('goToOfficialDocs').onclick = function() { 75 document.getElementById('goToOfficialDocs').onclick = function() {
72 location.href = officialURL; 76 location.href = officialURL;
73 }; 77 };
74 } else if (currentBranch != 'stable') { 78 } else if (currentBranch != 'stable') {
75 document.getElementById("branchName").textContent = 79 document.getElementById("branchName").textContent =
76 currentBranch.toUpperCase(); 80 currentBranch.toUpperCase();
77 document.getElementById('branchWarning').style.display = 'block'; 81 document.getElementById('branchWarning').style.display = 'block';
78 document.getElementById('branchChooser').onchange = function() { 82 document.getElementById('branchChooser').onchange = function() {
79 location.href = officialURL + this.value; 83 location.href = officialURL + this.value + "/";
80 }; 84 };
81 } 85 }
82 } 86 }
83 } 87 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698