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

Unified Diff: chrome/common/extensions/docs/static/js/branch.js

Issue 15087006: Docserver: there is only one. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: epic rebase Created 7 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/common/extensions/docs/static/js/branch.js
diff --git a/chrome/common/extensions/docs/static/js/branch.js b/chrome/common/extensions/docs/static/js/branch.js
deleted file mode 100644
index bd214975f8b1de58cb21d8c93fa9053f99eda7a8..0000000000000000000000000000000000000000
--- a/chrome/common/extensions/docs/static/js/branch.js
+++ /dev/null
@@ -1,33 +0,0 @@
-// Copyright (c) 2012 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-(function() {
-
-function init() {
- var branchChooser = document.getElementById('branch-chooser-popup');
- Array.prototype.forEach.call(branchChooser.getElementsByTagName('button'),
- function(button) {
- button.addEventListener('click', function(event) {
- choose(button.className);
- event.stopPropagation();
- });
- });
-}
-
-function choose(branch) {
- var currentBranch = window.bootstrap.branchInfo.current;
- var path = window.location.pathname.split('/');
- if (path[0] == '')
- path = path.slice(1);
- var index = path.indexOf(currentBranch);
- if (index != -1)
- path[index] = branch;
- else
- path.splice(0, 0, branch);
- window.location.pathname = '/' + path.join('/');
-}
-
-init();
-
-})()
« no previous file with comments | « chrome/common/extensions/docs/static/css/site.css ('k') | chrome/common/extensions/docs/static/js/platform_chooser.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698