addElement( 'select', 'effect', array('label' => 'Effect', 'multiOptions' => $dataObj->getDSlideEffect4Select()) ); $this->addElement( 'text', 'interval', array('label' => 'Interval', 'required' => true, 'class' => 'digit', 'size' => 5) ); $this->getElement('interval')->getDecorator('ViewHelper')->setAdditionalHtmlAfterElement(' seconds'); $this->getElement('interval')->addValidator('Int', true); $this->addElement( 'text', 'effectDuration', array('label' => 'Effect Duration', 'required' => true, 'class' => 'digit', 'size' => 5) ); $this->getElement('effectDuration')->getDecorator('ViewHelper')->setAdditionalHtmlAfterElement(' miliseconds'); $this->getElement('effectDuration')->addValidator('Int', true); $checkboxDecorators = array( 'ViewHelper', 'Errors', array('decorator' => 'Label', 'options' => array('placement' => 'APPEND')), 'DtDdWrapper' ); $this->addElement( 'checkbox', 'enableButtons', array('label' => 'Show Player Buttons', 'decorators' => $checkboxDecorators) ); $this->addElement( 'checkbox', 'autoHideToolbar', array('label' => 'Auto Hide Toolbar', 'decorators' => $checkboxDecorators) ); $this->addElement( 'checkbox', 'showArrows', array('label' => 'Show Arrows', 'decorators' => $checkboxDecorators) ); $this->addElement( 'checkbox', 'autostart', array('label' => 'Autostart', 'decorators' => $checkboxDecorators) ); $this->addElement( 'checkbox', 'enablePaginator', array('label' => 'Show Paginator', 'decorators' => $checkboxDecorators) ); $this->addElement('text', 'limit', array('label' => 'Limit Slides', 'class' => 'digit', 'size' => 5)); $this->getElement('limit')->getDecorator('ViewHelper') ->setAdditionalHtmlAfterElement(' (leave blank to have no limits)'); $paginatorOptions = new Qs_Form_SubForm(array('legend' => 'Paginator Options')); $paginatorOptions->addElement( 'text', 'pageLinks', array('label' => 'Links Count', 'required' => false, 'class' => 'digit', 'size' => 5) ); $paginatorOptions->getElement('pageLinks')->getDecorator('ViewHelper') ->setAdditionalHtmlAfterElement(' (leave blank to calculate automatically)'); $paginatorOptions->getElement('pageLinks')->addValidator('Int', true); $paginatorOptions->addElement( 'text', 'linkWidth', array('label' => 'Link Width', 'class' => 'digit', 'size' => 5) ); $paginatorOptions->getElement('linkWidth')->getDecorator('ViewHelper')->setAdditionalHtmlAfterElement(' px'); $paginatorOptions->getElement('linkWidth')->addValidator('Int', true); $paginatorOptions->addElement( 'text', 'template', array( 'label' => 'Template', 'description' => 'Constants: {FirstPageLink} {PreviousPageLink} {PageLinks} {NextPageLink} {LastPageLink}' ) ); $this->addSubForm($paginatorOptions, 'paginatorOptions'); return $this; } }