]> git.sur5r.net Git - bacula/bacula/blobdiff - gui/baculum/framework/Web/UI/ActiveControls/TDropContainer.php
baculum: New Baculum API and Baculum Web
[bacula/bacula] / gui / baculum / framework / Web / UI / ActiveControls / TDropContainer.php
old mode 100755 (executable)
new mode 100644 (file)
index 43e8017..216d3db
@@ -1,13 +1,11 @@
 <?php
 /**
  * TDropContainer class file
- * 
+ *
  * @author Christophe BOULAIN (Christophe.Boulain@gmail.com)
  * @copyright Copyright &copy; 2008, PradoSoft
- * @license http://www.pradosoft.com/license
- * @version $Id: TDropContainer.php 3159 2012-2013 PradoSoft
- * @license http://www.pradosoft.com/license
- * @version $Id: TDropContainer.php 3285 2013-04-11 07:28:07Z ctrlaltca $
+ * @license https://github.com/pradosoft/prado/blob/master/COPYRIGHT
+ * @license https://github.com/pradosoft/prado/blob/master/COPYRIGHT
  * @package System.Web.UI.ActiveControls
  */
 
@@ -23,30 +21,34 @@ Prado::using('System.Web.UI.ActiveControls.TActivePanel');
 
 /**
  * TDropContainer is a panel where TDraggable controls can be dropped.
+ *
+ * Warning: this class is deprecatd and will be removed in a future release.
+ * We suggest you to investigate using {@link TJuiDroppable} instead.
+ *
  * When a TDraggable component is dropped into a TDropContainer, the {@link OnDrop OnDrop} event is raised.
- * The {@link TDropContainerEventParameter} param will contain the dropped control. 
- * 
+ * The {@link TDropContainerEventParameter} param will contain the dropped control.
+ *
  * Properties :
- * 
+ *
  * <b>{@link setAcceptCssClass AcceptCssClass}</b> : a coma delimited classname of elements that the drop container can accept.
  * <b>{@link setHoverCssClass HoverCssClass}</b>: CSS classname of the container when a draggable element hovers over the container.
- * 
+ *
  * Events:
- * 
+ *
  * <b>{@link OnDrop OnDrop}</b> : raised when a TDraggable control is dropped. The dropped control id is encapsulated in the event parameter,
  * as well as mouse coordinates and key modifiers status
  *
- * 
+ *
  * @author Christophe BOULAIN (Christophe.Boulain@gmail.com)
  * @copyright Copyright &copy; 2008, PradoSoft
- * @license http://www.pradosoft.com/license
- * @version $Id: TDropContainer.php 3285 2013-04-11 07:28:07Z ctrlaltca $
+ * @license https://github.com/pradosoft/prado/blob/master/COPYRIGHT
  * @package System.Web.UI.ActiveControls
+ * @deprecated Use TJuiDroppable instead
  */
-class TDropContainer extends TPanel implements IActiveControl, ICallbackEventHandler 
-{      
+class TDropContainer extends TPanel implements IActiveControl, ICallbackEventHandler
+{
        private $_container=null;
-       
+
        /**
         * Creates a new callback control, sets the adapter to
         * TActiveControlAdapter. If you override this class, be sure to set the
@@ -91,7 +93,7 @@ class TDropContainer extends TPanel implements IActiveControl, ICallbackEventHan
        {
                $this->setViewState('Accepts', TPropertyValue::ensureArray($value), '');
        }
-       
+
        /**
         * Sets the Css class name used when a draggble element is hovering
         * over this container.
@@ -111,8 +113,8 @@ class TDropContainer extends TPanel implements IActiveControl, ICallbackEventHan
        {
                return $this->getViewState('HoverClass', '');
        }
-       
-       
+
+
        /**
         * Raises callback event. This method is required bu {@link ICallbackEventHandler}
         * interface.
@@ -125,19 +127,19 @@ class TDropContainer extends TPanel implements IActiveControl, ICallbackEventHan
                $this->onDrop($param->getCallbackParameter());
                $this->onCallback($param);
        }
-       
+
        /**
-        * Raises the onDrop event. 
+        * Raises the onDrop event.
         * The drop parameters are encapsulated into a {@link TDropContainerEventParameter}
-        * 
+        *
         * @param object $dropControlId
         */
        public function onDrop ($dropParams)
        {
                $this->raiseEvent('OnDrop', $this, new TDropContainerEventParameter ($dropParams));
-               
+
        }
-       
+
        /**
         * This method is invoked when a callback is requested. The method raises
         * 'OnCallback' event to fire up the event handlers. If you override this
@@ -149,7 +151,7 @@ class TDropContainer extends TPanel implements IActiveControl, ICallbackEventHan
        {
                $this->raiseEvent('OnCallback', $this, $param);
        }
-       
+
        /**
         * Gets the post back options for this textbox.
         * @return array
@@ -163,7 +165,7 @@ class TDropContainer extends TPanel implements IActiveControl, ICallbackEventHan
                $options['hoverclass'] = $this->getHoverCssClass();
                return $options;
        }
-       
+
        /**
         * Gets the name of the javascript class responsible for performing postback for this control.
         * This method overrides the parent implementation.
@@ -172,7 +174,7 @@ class TDropContainer extends TPanel implements IActiveControl, ICallbackEventHan
        protected function getClientClassName()
        {
                return 'Prado.WebUI.DropContainer';
-       }       
+       }
 
        /**
         * Registers clientscripts
@@ -198,7 +200,7 @@ class TDropContainer extends TPanel implements IActiveControl, ICallbackEventHan
                $this->getActiveControl()->registerCallbackClientScript(
                        $this->getClientClassName(), $this->getPostBackOptions());
        }
-       
+
        /**
         * Creates child control
         * Override parent implementation to create a container which will contain all
@@ -214,7 +216,7 @@ class TDropContainer extends TPanel implements IActiveControl, ICallbackEventHan
                        parent::getControls()->add($this->_container);
                }
        }
-       
+
        /**
         * Override parent implementation to return the container control collection.
         *
@@ -225,7 +227,7 @@ class TDropContainer extends TPanel implements IActiveControl, ICallbackEventHan
                $this->ensureChildControls();
                return $this->_container->getControls();
        }
-       
+
        /**
         * Renders and replaces the panel's content on the client-side.
         * When render() is called before the OnPreRender event, such as when render()
@@ -246,19 +248,18 @@ class TDropContainer extends TPanel implements IActiveControl, ICallbackEventHan
                        $this->getPage()->getAdapter()->registerControlToRender($this->_container,$writer);
                }
        }
-                       
+
 }
 
 /**
  * TDropContainerEventParameter class
- * 
+ *
  * TDropContainerEventParameter encapsulate the parameter
  * data for <b>OnDrop</b> event of TDropContainer components
- * 
+ *
  * @author Christophe BOULAIN (Christophe.Boulain@ceram.fr)
  * @copyright Copyright &copy; 2008, PradoSoft
- * @license http://www.pradosoft.com/license
- * @version $Id: TDropContainer.php 3285 2013-04-11 07:28:07Z ctrlaltca $
+ * @license https://github.com/pradosoft/prado/blob/master/COPYRIGHT
  * @package System.Web.UI.ActiveControls
  */
 class TDropContainerEventParameter extends TEventParameter