From fe60cc221f922ea362826e2d00431c5df28fe85f Mon Sep 17 00:00:00 2001 From: wei <> Date: Fri, 6 Oct 2006 03:46:05 +0000 Subject: fixed #410 #412 --- framework/Web/Javascripts/js/debug/ajax.js | 32 +++++++++++++++------------- framework/Web/Javascripts/js/debug/logger.js | 17 +++++++++++++-- framework/Web/Javascripts/js/debug/prado.js | 4 ++-- 3 files changed, 34 insertions(+), 19 deletions(-) (limited to 'framework/Web/Javascripts/js/debug') diff --git a/framework/Web/Javascripts/js/debug/ajax.js b/framework/Web/Javascripts/js/debug/ajax.js index 77df7bc2..ba777546 100644 --- a/framework/Web/Javascripts/js/debug/ajax.js +++ b/framework/Web/Javascripts/js/debug/ajax.js @@ -2614,6 +2614,7 @@ Prado.WebUI.TRatingList = Base.extend( { selectedIndex : -1, enabled : true, + readOnly : false, constructor : function(options) { @@ -2632,20 +2633,20 @@ Prado.WebUI.TRatingList = Base.extend( _init: function(options) { Element.addClassName($(this.options.ListID),this.options.Style); - var radios = document.getElementsByName(this.options.ListName); this.radios = new Array(); var index=0; - for(var i = 0; i index ? 'removeClassName' : 'addClassName' Element[action](this.radios[i].parentNode, "rating_selected"); } this.setCaption(index); @@ -2701,7 +2704,7 @@ Prado.WebUI.TRatingList = Base.extend( var value = index > -1 ? this.radios[index].value : this.options.caption; var caption = $(this.options.CaptionID); if(caption) caption.innerHTML = value; - $(this.options.ListName).title = value; + $(this.options.ListID).title = value; }, setEnabled : function(value) @@ -2711,7 +2714,6 @@ Prado.WebUI.TRatingList = Base.extend( { var action = value ? 'removeClassName' : 'addClassName' Element[action](this.radios[i].parentNode, "rating_disabled"); - Element.removeClassName(this.radios[i].parentNode, "rating_hover"); } } }, diff --git a/framework/Web/Javascripts/js/debug/logger.js b/framework/Web/Javascripts/js/debug/logger.js index 2a376904..5d465d56 100644 --- a/framework/Web/Javascripts/js/debug/logger.js +++ b/framework/Web/Javascripts/js/debug/logger.js @@ -195,6 +195,8 @@ LogConsole.prototype = { commandHistory : [], commandIndex : 0, + hidden : true, + // Methods // ------- @@ -207,7 +209,7 @@ LogConsole.prototype = { document.body.appendChild(this.logElement) Element.hide(this.logElement) - this.logElement.style.position = "absolute" + this.logElement.style.position = "absolute" this.logElement.style.left = '0px' this.logElement.style.width = '100%' @@ -272,8 +274,15 @@ LogConsole.prototype = { Event.observe(this.inputElement, 'keyup', this.handleInput.bind(this)) Event.observe(this.inputElement, 'click', function() {this.inputElement.select()}.bind(this)) + if(document.all && !window.opera) + { window.setInterval(this.repositionWindow.bind(this), 500) - this.repositionWindow() + } + else + { + this.logElement.style.position="fixed"; + this.logElement.style.bottom="0px"; + } // Listen to the logger.... Logger.onupdate.addListener(this.logUpdate.bind(this)) @@ -310,11 +319,15 @@ LogConsole.prototype = { show : function() { Element.show(this.logElement) this.outputElement.scrollTop = this.outputElement.scrollHeight // Scroll to bottom when toggled + if(document.all && !window.opera) + this.repositionWindow(); Cookie.set('ConsoleVisible', 'true') this.inputElement.select() + this.hidden = false; }, hide : function() { + this.hidden = true; Element.hide(this.logElement) Cookie.set('ConsoleVisible', 'false') }, diff --git a/framework/Web/Javascripts/js/debug/prado.js b/framework/Web/Javascripts/js/debug/prado.js index 920c2150..aaae6bad 100644 --- a/framework/Web/Javascripts/js/debug/prado.js +++ b/framework/Web/Javascripts/js/debug/prado.js @@ -3504,7 +3504,7 @@ Prado.WebUI.TCheckBoxList = Base.extend( var checkBoxOptions = Object.extend( { ID : options.ListID+"_c"+i, - EventTarget : options.ListName+"$c"+i + EventTarget : options.ListID+"$c"+i }, options); new Prado.WebUI.TCheckBox(checkBoxOptions); } @@ -3520,7 +3520,7 @@ Prado.WebUI.TRadioButtonList = Base.extend( var radioButtonOptions = Object.extend( { ID : options.ListID+"_c"+i, - EventTarget : options.ListName+"$c"+i + EventTarget : options.ListID+"$c"+i }, options); new Prado.WebUI.TRadioButton(radioButtonOptions); } -- cgit v1.2.3