diff options
Diffstat (limited to 'framework/Web/UI/ActiveControls/TDropContainer.php')
-rwxr-xr-x | framework/Web/UI/ActiveControls/TDropContainer.php | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/framework/Web/UI/ActiveControls/TDropContainer.php b/framework/Web/UI/ActiveControls/TDropContainer.php index 915aa8f9..e6933147 100755 --- a/framework/Web/UI/ActiveControls/TDropContainer.php +++ b/framework/Web/UI/ActiveControls/TDropContainer.php @@ -172,6 +172,17 @@ class TDropContainer extends TPanel implements IActiveControl, ICallbackEventHan return 'Prado.WebUI.DropContainer'; } + /** + * Registers clientscripts + * + * This method overrides the parent implementation and is invoked before render. + * @param mixed event parameter + */ + public function onPreRender($param) + { + parent::onPreRender($param); + $this->getPage()->getClientScript()->registerPradoScript('dragdrop'); + } /** * Ensure that the ID attribute is rendered and registers the javascript code @@ -182,8 +193,6 @@ class TDropContainer extends TPanel implements IActiveControl, ICallbackEventHan parent::addAttributesToRender($writer); $writer->addAttribute('id',$this->getClientID()); - $this->getPage()->getClientScript()->registerPradoScript('dragdrop'); - $this->getActiveControl()->registerCallbackClientScript( $this->getClientClassName(), $this->getPostBackOptions()); } |