From 3ba6d2dfa48372a9a522d2d7c47813077192f23f Mon Sep 17 00:00:00 2001 From: Jeremy Goecks Date: Fri, 9 Apr 2010 13:02:15 -0400 Subject: [PATCH] Rollback text + autocomplete for big selects. Only use text + autocomplete for dbkey. --- static/scripts/galaxy.base.js | 5 ++--- static/scripts/packed/galaxy.base.js | 2 +- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/static/scripts/galaxy.base.js b/static/scripts/galaxy.base.js index 0062e864713..2a68a4d30cc 100644 --- a/static/scripts/galaxy.base.js +++ b/static/scripts/galaxy.base.js @@ -120,10 +120,9 @@ function array_length(an_array) { } // Replace any select box with 20+ options with a text input box + autocomplete. -// TODO: make this work _well_ on pages with multiple forms; currently, value is reverted when any form is submitted - -// value should be reverted when only the form that element is in is submitted. +// TODO: make work with dynamic tool inputs and then can replace all big selects. function replace_big_select_inputs() { - $('select').each( function() { + $('select[name=dbkey]').each( function() { var select_elt = $(this); // Skip if there are < 20 options. if (select_elt.find('option').length < 20) diff --git a/static/scripts/packed/galaxy.base.js b/static/scripts/packed/galaxy.base.js index 8115f97302a..ba5abb131b7 100644 --- a/static/scripts/packed/galaxy.base.js +++ b/static/scripts/packed/galaxy.base.js @@ -1 +1 @@ -$(document).ready(function(){replace_big_select_inputs()});$.fn.makeAbsolute=function(a){return this.each(function(){var b=$(this);var c=b.position();b.css({position:"absolute",marginLeft:0,marginTop:0,top:c.top,left:c.left,right:$(window).width()-(c.left+b.width())});if(a){b.remove().appendTo("body")}})};function ensure_popup_helper(){if($("#popup-helper").length===0){$("