WPDKView::removeFromSuperview PHP Method

removeFromSuperview() public method

Remove this view from its superview
public removeFromSuperview ( )
    public function removeFromSuperview()
    {
        if (!empty($this->superview)) {
            /**
             * Filter the potential removing of this view from superview.
             *
             * @param bool $continue Default TRUE. Set to FALSE to avoid removing this view.
             *
             */
            $continue = apply_filters('wpdk_view_should_removed_superview', true, $this);
            if ($continue) {
                unset($this->superview->subviews[$this->id]);
                /**
                 * Fires when this view is removed froma superview
                 *
                 * @param WPDKView $view This view.
                 */
                do_action('wpdk_view_did_removed_superview', $this);
            }
        }
    }