24 require_once(
"./Services/MediaObjects/classes/class.ilObjMediaObjectGUI.php");
47 $this->multiple =
false;
48 $this->page_back_title = $lng->txt(
"cont_back");
49 if (
$_GET[
"returnCommand"] !=
"")
51 $this->mode =
"getObject";
58 $ilCtrl->setParameter($this,
"returnCommand",
59 rawurlencode(
$_GET[
"returnCommand"]));
61 $ilCtrl->saveParameter($this, array(
"clip_item_id"));
71 return array(
"ilObjMediaObjectGUI");
81 $next_class = $ilCtrl->getNextClass($this);
82 $cmd = $ilCtrl->getCmd();
86 case "ilobjmediaobjectgui":
87 $ilCtrl->setReturn($this,
"view");
88 $ilTabs->clearTargets();
89 $ilTabs->setBackTarget($lng->txt(
"back"),
90 $ilCtrl->getLinkTarget($this,
"view"));
91 require_once(
"classes/class.ilTabsGUI.php");
95 $ret =& $ilCtrl->forwardCommand($mob_gui);
99 $ilUser->addObjectToClipboard(
$ret->getId(),
"mob",
$ret->getTitle());
100 $ilCtrl->redirect($this,
"view");
118 $this->multiple = $a_multiple;
126 return $this->multiple;
136 $this->insertbuttontitle = $a_insertbuttontitle;
148 if ($this->insertbuttontitle ==
"")
150 return $lng->txt(
"insert");
153 return $this->insertbuttontitle;
163 $tpl->addBlockfile(
"BUTTONS",
"buttons",
"tpl.buttons.html");
165 $tpl->setCurrentBlock(
"btn_cell");
166 $tpl->setVariable(
"BTN_LINK",
167 $ilCtrl->getLinkTargetByClass(
"ilobjmediaobjectgui",
"create"));
168 $tpl->setVariable(
"BTN_TXT", $lng->txt(
"cont_create_mob"));
169 $tpl->parseCurrentBlock();
171 include_once(
"./Services/Clipboard/classes/class.ilClipboardTableGUI.php");
173 $tpl->setContent($table_gui->getHTML());
182 $this->mode =
"getObject";
197 $ilias->raiseError($lng->txt(
"no_checkbox"),$ilias->error_obj->MESSAGE);
200 foreach(
$_POST[
"id"] AS $obj_id)
202 $id = explode(
":", $obj_id);
205 $ilUser->removeObjectFromClipboard($id[1],
"mob");
206 include_once(
"./Services/MediaObjects/classes/class.ilObjMediaObject.php");
210 if ($id[0] ==
"incl")
212 $ilUser->removeObjectFromClipboard($id[1],
"incl");
215 $ilCtrl->redirect($this,
"view");
228 $ilias->raiseError($lng->txt(
"no_checkbox"),$ilias->error_obj->MESSAGE);
233 if(count(
$_POST[
"id"]) > 1)
235 $ilias->raiseError($lng->txt(
"cont_select_max_one_item"),$ilias->error_obj->MESSAGE);
245 return $_SESSION[
"ilEditClipboard_mob_id"];
256 $tpl->setTitle($lng->txt(
"clipboard"));
265 $this->page_back_title = $a_title;
278 $tabs_gui->setBackTarget($this->page_back_title,
279 $ilCtrl->getParentReturn($this));