diff options
author | haertl.mike <> | 2008-10-28 16:41:52 +0000 |
---|---|---|
committer | haertl.mike <> | 2008-10-28 16:41:52 +0000 |
commit | 70f0a7fae5cec1dc62430e29a6cce83ed1d49f6d (patch) | |
tree | e5fee722a126225fb80306a1e948ed9f9daeaaf8 /framework/Web/Javascripts | |
parent | 5af1a4cca7044655f89bf96ced94d0c5968daff1 (diff) |
Fixed issue 4 (trac ticket 900)
Diffstat (limited to 'framework/Web/Javascripts')
-rw-r--r-- | framework/Web/Javascripts/source/prado/activecontrols/activecontrols3.js | 1 | ||||
-rw-r--r-- | framework/Web/Javascripts/source/prado/controls/controls.js | 19 |
2 files changed, 15 insertions, 5 deletions
diff --git a/framework/Web/Javascripts/source/prado/activecontrols/activecontrols3.js b/framework/Web/Javascripts/source/prado/activecontrols/activecontrols3.js index aa1fd99b..d5cae7b8 100644 --- a/framework/Web/Javascripts/source/prado/activecontrols/activecontrols3.js +++ b/framework/Web/Javascripts/source/prado/activecontrols/activecontrols3.js @@ -28,6 +28,7 @@ Prado.WebUI.TActiveImageButton = Class.extend(Prado.WebUI.TImageButton, var request = new Prado.CallbackRequest(options.EventTarget, options); request.dispatch(); Event.stop(event); + this.removeXYInput(event,options); } }); /** diff --git a/framework/Web/Javascripts/source/prado/controls/controls.js b/framework/Web/Javascripts/source/prado/controls/controls.js index bea18e76..dac7a0c0 100644 --- a/framework/Web/Javascripts/source/prado/controls/controls.js +++ b/framework/Web/Javascripts/source/prado/controls/controls.js @@ -69,12 +69,9 @@ Object.extend(Prado.WebUI.TImageButton.prototype, */
onPostBack : function(event, options)
{
- if(!this.hasXYInput)
- {
- this.addXYInput(event,options);
- this.hasXYInput = true;
- }
+ this.addXYInput(event,options);
Prado.PostBack(event, options);
+ this.removeXYInput(event,options);
},
/**
@@ -111,6 +108,18 @@ Object.extend(Prado.WebUI.TImageButton.prototype, y_input = INPUT({type:'hidden',name:id+'_y','id':id+'_y',value:y});
this.element.parentNode.appendChild(y_input);
}
+ },
+
+ /**
+ * Remove hidden inputs for x,y-click capturing
+ * @param event DOM click event.
+ * @param array image button options.
+ */
+ removeXYInput : function(event,options)
+ {
+ id = options['EventTarget'];
+ this.element.parentNode.removeChild($(id+"_x"));
+ this.element.parentNode.removeChild($(id+"_y"));
}
});
|