Changeset - f95d14374866
[Not reviewed]
default
0 1 0
Nathan Brink (binki) - 14 years ago 2011-04-10 13:48:18
ohnobinki@ohnopublishing.net
Close the autocomplete menu upon pressing ENTER (seems to only affect webkit people).
1 file changed with 2 insertions and 0 deletions:
0 comments (0 inline, 0 general)
scripts/scheduleInput.js
Show inline comments
 
@@ -395,24 +395,26 @@ function course_autocomplete(course_i, t
 
		semester: slate_permutate_semester
 
	    },
 
	    success: function(data, textStatus, reqobj)
 
	    {
 
		var new_course_num;
 

	
 
		if (data.sections)
 
		{
 
		    if (sectionsOfClass[course_i])
 
			return;
 

	
 
		    add_sections(course_i, data);
 
		    /* Close the autocomplete menu thingy. */
 
		    course_name_elem.autocomplete('close');
 

	
 
		    new_course_num = add_class();
 

	
 
		    if (course_name_elem.val() != data.course_id)
 

	
 
		    /* position the user's cursor the new class's input box */
 
		    jQuery('#input-course-' + new_course_num).focus();
 
		}
 
	    }
 
	}
 
    );
 

	
0 comments (0 inline, 0 general)