From 4cb6d6bd3c22c18bdbe7dea29e0de9c77ebfe025 Mon Sep 17 00:00:00 2001 From: xue <> Date: Wed, 22 Mar 2006 22:37:15 +0000 Subject: TWizard is completed. --- framework/Web/UI/WebControls/TMultiView.php | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) (limited to 'framework/Web/UI/WebControls/TMultiView.php') diff --git a/framework/Web/UI/WebControls/TMultiView.php b/framework/Web/UI/WebControls/TMultiView.php index a88fbda7..42e76349 100644 --- a/framework/Web/UI/WebControls/TMultiView.php +++ b/framework/Web/UI/WebControls/TMultiView.php @@ -40,6 +40,7 @@ class TMultiView extends TControl const CMD_SWITCHVIEWID='SwitchViewID'; const CMD_SWITCHVIEWINDEX='SwitchViewIndex'; private $_cachedActiveViewIndex=-1; + private $_ignoreBubbleEvents=false; /** * Processes an object that is created during parsing template. @@ -166,6 +167,16 @@ class TMultiView extends TControl return $this->getControls(); } + /** + * Makes the multiview ignore all bubbled events. + * This is method is used internally by framework and control + * developers. + */ + public function ignoreBubbleEvents() + { + $this->_ignoreBubbleEvents=true; + } + /** * Initializes the active view if any. * This method overrides the parent implementation. @@ -197,7 +208,7 @@ class TMultiView extends TControl */ public function onBubbleEvent($sender,$param) { - if($param instanceof TCommandEventParameter) + if(!$this->_ignoreBubbleEvents && ($param instanceof TCommandEventParameter)) { switch($param->getCommandName()) { -- cgit v1.2.3