location input bar now disabled while searching

This commit is contained in:
Doug Bell 2010-08-25 16:33:21 -05:00
parent 8472cb99a2
commit 95f51b61ce
2 changed files with 17 additions and 1 deletions

View file

@ -1057,13 +1057,23 @@ WebGUI.Admin.LocationBar.prototype.goHome
*/
WebGUI.Admin.LocationBar.prototype.toggleSearchDialog
= function ( ) {
var input = document.getElementById( 'locationInput' );
if ( this.searchDialog == true ) {
this.hideSearchDialog();
this.searchDialog = false;
input.value = this.savedLocationInput;
this.savedLocationInput = "";
input.readonly = false;
YAHOO.util.Dom.removeClass( input, 'disabled' );
}
else {
this.showSearchDialog();
this.searchDialog = true;
this.savedLocationInput = input.value;
input.value = "";
this.updateLocationBarQuery();
input.readonly = true;
YAHOO.util.Dom.addClass( input, 'disabled' );
}
};