public function populateQuestionSpecificFormPart(ilPropertyFormGUI $form)
 {
     // flash file
     $flash = new ilFlashFileInputGUI($this->lng->txt("flashfile"), "flash");
     $flash->setRequired(TRUE);
     if (strlen($this->object->getApplet())) {
         $flash->setApplet($this->object->getApplet());
         $flash->setAppletPathWeb($this->object->getFlashPathWeb());
     }
     $flash->setWidth($this->object->getWidth());
     $flash->setHeight($this->object->getHeight());
     $flash->setParameters($this->object->getParameters());
     $form->addItem($flash);
     if ($this->object->getId()) {
         $hidden = new ilHiddenInputGUI("", "ID");
         $hidden->setValue($this->object->getId());
         $form->addItem($hidden);
     }
     // points
     $points = new ilNumberInputGUI($this->lng->txt("points"), "points");
     $points->setValue($this->object->getPoints());
     $points->setRequired(TRUE);
     $points->setSize(3);
     $points->setMinValue(0.0);
     $form->addItem($points);
     return $form;
 }
 /**
  * Creates an output of the edit form for the question
  *
  * @access public
  */
 public function editQuestion($checkonly = FALSE)
 {
     //$save = ((strcmp($this->ctrl->getCmd(), "save") == 0) || (strcmp($this->ctrl->getCmd(), "saveEdit") == 0)) ? TRUE : FALSE;
     $save = $this->isSaveCommand();
     $this->getQuestionTemplate();
     include_once "./Services/Form/classes/class.ilPropertyFormGUI.php";
     $form = new ilPropertyFormGUI();
     $form->setFormAction($this->ctrl->getFormAction($this));
     $form->setTitle($this->outQuestionType());
     $form->setMultipart(TRUE);
     $form->setTableWidth("100%");
     $form->setId("flash");
     $this->addBasicQuestionFormProperties($form);
     // flash file
     $flash = new ilFlashFileInputGUI($this->lng->txt("flashfile"), "flash");
     $flash->setRequired(TRUE);
     if (strlen($this->object->getApplet())) {
         $flash->setApplet($this->object->getApplet());
         $flash->setAppletPathWeb($this->object->getFlashPathWeb());
     }
     $flash->setWidth($this->object->getWidth());
     $flash->setHeight($this->object->getHeight());
     $flash->setParameters($this->object->getParameters());
     $form->addItem($flash);
     if ($this->object->getId()) {
         $hidden = new ilHiddenInputGUI("", "ID");
         $hidden->setValue($this->object->getId());
         $form->addItem($hidden);
     }
     // points
     $points = new ilNumberInputGUI($this->lng->txt("points"), "points");
     $points->setValue($this->object->getPoints());
     $points->setRequired(TRUE);
     $points->setSize(3);
     $points->setMinValue(0.0);
     $form->addItem($points);
     $this->addQuestionFormCommandButtons($form);
     $errors = false;
     if ($save) {
         $form->setValuesByPost();
         $errors = !$form->checkInput();
         $form->setValuesByPost();
         // again, because checkInput now performs the whole stripSlashes handling and we need this if we don't want to have duplication of backslashes
         if ($errors) {
             $checkonly = false;
         }
     }
     if (!$checkonly) {
         $this->tpl->setVariable("QUESTION_DATA", $form->getHTML());
     }
     return $errors;
 }