protected function getStdEditControl($readOnly = false)
 {
     //$control = new InputFileControl(null, $this->name);
     $control = new UploaderControl(null, $this->name);
     $control->setTargetFilename($this->entity->id);
     $control->setToken($this->entity->__toToken());
     return $control;
 }
 protected function getStdEditControl($readOnly = false)
 {
     $control = new ControlContainer(null);
     $id = 'image' . $this->name;
     if ($this->getValue() != '' && file_exists('medien/-1/' . $this->getValue())) {
         $url = Configuration::get('site.url') . "/medien/-1/thumbs/{$this->getValue()}";
     } else {
         $url = Configuration::get('site.url') . "/pixel.png";
     }
     $htmlControl = new HtmlControl($control);
     $htmlControl->setInnerHtml("<img src=\"{$url}\" id=\"{$id}\" class=\"img-thumbnail\" />");
     $uploader = new UploaderControl($control, $this->name);
     $uploader->setTargetFilename($this->entity->id);
     $uploader->setValue($this->getValue());
     return $control;
 }