# HG changeset patch # User Mads Kiilerich # Date 1508637688 -7200 # Node ID d39fcf27fa44772f9188c40dcf5f49a5b7cb7d6d # Parent 7a31cb862a58ae637da356875ce279f5cdd68906 files: simplify header, making it more like changeset "Search file list" is moved out of the header to a separate div. The "Follow current branch" functionality is dropped, and there is thus less need for passing the current URL around ... but it is generally still used for browser history navigation. The removal of branch following is a temporary feature regression - that will be fixed next. diff -r 7a31cb862a58 -r d39fcf27fa44 kallithea/public/js/base.js --- a/kallithea/public/js/base.js Wed Aug 16 17:34:44 2017 +0200 +++ b/kallithea/public/js/base.js Sun Oct 22 04:01:28 2017 +0200 @@ -799,20 +799,7 @@ } /* activate files.html stuff */ -var fileBrowserListeners = function(current_url, node_list_url, url_base){ - var current_url_branch = "?branch=__BRANCH__"; - - $('#stay_at_branch').on('click',function(e){ - if(e.currentTarget.checked){ - var uri = current_url_branch; - uri = uri.replace('__BRANCH__',e.currentTarget.value); - window.location = uri; - } - else{ - window.location = current_url; - } - }); - +var fileBrowserListeners = function(node_list_url, url_base){ var $node_filter = $('#node_filter'); var filterTimeout = null; diff -r 7a31cb862a58 -r d39fcf27fa44 kallithea/templates/files/files.html --- a/kallithea/templates/files/files.html Wed Aug 16 17:34:44 2017 +0200 +++ b/kallithea/templates/files/files.html Sun Oct 22 04:01:28 2017 +0200 @@ -100,7 +100,7 @@ var _f_path = State.data.f_path; var _rev = State.data.rev; - fileBrowserListeners(State.url, State.data.node_list_url, State.data.url_base); + fileBrowserListeners(State.data.node_list_url, State.data.url_base); // Inform Google Analytics of the change if ( typeof window.pageTracker !== 'undefined' ) { window.pageTracker._trackPageview(State.url); @@ -233,7 +233,7 @@ f_path: ${h.js(h.safe_unicode(c.file.path))} } } - fileBrowserListeners(_State.url, _State.data.node_list_url, _State.data.url_base); + fileBrowserListeners(_State.data.node_list_url, _State.data.url_base); // change branch filter $("#branch_selector").select2({ diff -r 7a31cb862a58 -r d39fcf27fa44 kallithea/templates/files/files_browser.html --- a/kallithea/templates/files/files_browser.html Wed Aug 16 17:34:44 2017 +0200 +++ b/kallithea/templates/files/files_browser.html Sun Oct 22 04:01:28 2017 +0200 @@ -26,7 +26,6 @@
- ${h.form(h.url.current())} ${_('Revision')} @@ -35,15 +34,13 @@ - - - - +
+ +
+ ${h.form(h.url.current())} + ${h.end_form()}
-
- -