34     protected \ILIAS\DI\UIServices 
$ui;
    38     protected \ILIAS\MediaObjects\MediaType\MediaTypeManager 
$media_type;
    48         $this->tpl = $DIC[
"tpl"];
    49         $this->
lng = $DIC->language();
    50         $this->
tabs = $DIC->tabs();
    51         $this->
access = $DIC->access();
    52         $this->
toolbar = $DIC->toolbar();
    53         $this->
user = $DIC->user();
    54         $ilCtrl = $DIC->ctrl();
    55         $this->
ui = $DIC->ui();
    64         $this->media_type = $DIC->mediaObjects()
    70         if (
$pc_id != 
"" && $a_hier_id == 
"") {
    72             $a_hier_id = $hier_ids[
$pc_id] ?? 
"";
    73             $ilCtrl->setParameter($this, 
"hier_id", $a_hier_id);
    76         $this->pool_view = 
"folder";
    78         $pv = 
$request->getString(
"pool_view");
    79         if (in_array($pv, array(
"folder", 
"all"))) {
    80             $this->pool_view = $pv;
    83         $this->
ctrl = $ilCtrl;
    85         $this->
ctrl->saveParameter($this, [
"pool_view", 
"pcid"]);
   107         $this->sub_cmd = $a_val;
   131         $this->enabledmapareas = $a_enabledmapareas;
   143     public function executeCommand()
   152         $next_class = $this->
ctrl->getNextClass($this);
   155         $cmd = $this->
ctrl->getCmd();
   156         if (is_object($this->content_obj)) {
   161             $mob = $this->content_obj->getMediaObject();
   162             if (is_object($mob)) {
   164                     $this->content_obj->getMediaObject()->getTitle());
   165                 $mob_gui = 
new ilObjMediaObjectGUI(
"", $this->content_obj->getMediaObject()->getId(), 
false, 
false);
   172         switch ($next_class) {
   173             case "ilobjmediaobjectgui":
   176                 $this->tpl->setTitle($this->
lng->txt(
"mob") . 
": " .
   177                     $this->content_obj->getMediaObject()->getTitle());
   178                 $mob_gui = 
new ilObjMediaObjectGUI(
"", $this->content_obj->getMediaObject()->getId(), 
false, 
false);
   181                 $ret = $this->
ctrl->forwardCommand($mob_gui);
   185             case "ilpcimagemapeditorgui":
   186                 $ilTabs->setTabActive(
"cont_inst_map_areas");
   194                 $ret = $this->
ctrl->forwardCommand($image_map_edit);
   200                 $ret = $this->$cmd();
   208         $a_post_cmd = 
"edpost",
   210         $a_input_error = 
false   219         if (in_array(
$sub_command, [
"insertNew", 
"insertFromPool"])) {
   223         if ((
$sub_command == 
"") && $this->edit_repo->getSubCmd() != 
"") {
   228             case "insertFromPool":
   232             case "poolSelection":
   243                 $ilTabs->setSubTabActive(
"cont_new_mob");
   245                 if ($a_input_error) {
   249                     $mob_gui->initForm(
"create");
   250                     $form = $mob_gui->getForm();
   252                 $form->
setFormAction($ilCtrl->getFormAction($this, 
"create"));
   276         if (in_array(
$sub_command, [
"insertNew", 
"insertFromPool"])) {
   280         if ((
$sub_command == 
"") && $this->edit_repo->getSubCmd() != 
"") {
   285             case "insertFromPool":
   289             case "poolSelection":
   299                 $ilCtrl->setParameter($this, 
"subCmd", 
"changeObjectReference");
   301                 $ilTabs->setSubTabActive(
"cont_new_mob");
   306                 $mob_gui->initForm(
"create");
   307                 $form = $mob_gui->getForm();
   312                 $this->tpl->setContent($form->
getHTML());
   318         $std_alias_item = $this->content_obj->getStandardMediaAliasItem();
   319         $std_item = $this->content_obj->getMediaObject()->getMediaItem(
"Standard");
   322         if (($std_alias_item->getWidth() != 
"" && $std_alias_item->getHeight() != 
"")) {
   325         if ($std_alias_item->getWidth() == 
"" && $std_alias_item->getHeight() == 
""   326             && $std_item->getWidth() != 
"" && $std_item->getHeight() != 
"") {
   331             $this->tpl->setOnScreenMessage(
'failure', $this->
lng->txt(
"mob_no_fixed_size_map_editing"));
   347         if ($this->edit_repo->getMediaPool() > 0 &&
   348             $ilAccess->checkAccess(
"write", 
"", $this->edit_repo->getMediaPool())
   354             $ilCtrl->setParameter($this, 
"subCmd", 
"poolSelection");
   355             if ($a_change_obj_ref) {
   357                     $lng->
txt(
"cont_switch_to_media_pool"),
   358                     $ilCtrl->getLinkTarget($this, 
"changeObjectReference")
   362                     $lng->
txt(
"cont_switch_to_media_pool"),
   363                     $ilCtrl->getLinkTarget($this, 
"insert")
   366             $ilCtrl->setParameter($this, 
"subCmd", 
"");
   370             $tcmd = ($a_change_obj_ref)
   371                 ? 
"changeObjectReference"   374             $ilCtrl->setParameter($this, 
"pool_view", 
"folder");
   375             $actions[
$lng->
txt(
"folders")] = $ilCtrl->getLinkTarget($this, $tcmd);
   376             $ilCtrl->setParameter($this, 
"pool_view", 
"all");
   377             $actions[
$lng->
txt(
"mep_all_mobs")] = $ilCtrl->getLinkTarget($this, $tcmd);
   378             $ilCtrl->setParameter($this, 
"pool_view", $this->pool_view);
   379             $aria_label = 
$lng->
txt(
"cont_change_pool_view");
   380             $view_control = 
$f->viewControl()->mode($actions, $aria_label)->withActive(($this->pool_view == 
"folder")
   383             $tb->addComponent($view_control);
   385             $html = $tb->getHTML();
   387             $this->
getTabs(
true, $a_change_obj_ref);
   388             $ilTabs->setSubTabActive(
"cont_mob_from_media_pool");
   391             $ilCtrl->setParameter($this, 
"subCmd", 
"insertFromPool");
   392             $tcmd = ($a_change_obj_ref)
   393                 ? 
"changeObjectReference"   395             $tmode = ($a_change_obj_ref)
   400             if ($this->
getSubCmd() == 
"applyFilter") {
   407                     $this->pool_view == 
"all"   409                 $mpool_table->resetOffset();
   410                 $mpool_table->writeFilterToSession();
   412             if ($this->
getSubCmd() == 
"resetFilter") {
   419                     $this->pool_view == 
"all"   421                 $mpool_table->resetOffset();
   422                 $mpool_table->resetFilter();
   430                 $this->pool_view == 
"all"   433             $html .= $mpool_table->getHTML();
   445         bool $a_change_obj_ref = 
false   449         $this->edit_repo->setMediaPool($this->request->getInt(
"pool_ref_id"));
   450         $ilCtrl->
setParameter($this, 
"subCmd", 
"insertFromPool");
   451         if ($a_change_obj_ref) {
   452             $ilCtrl->redirect($this, 
"changeObjectReference");
   454             $ilCtrl->redirect($this, 
"insert");
   462         bool $a_change_obj_ref = 
false   468         $this->
getTabs(
true, $a_change_obj_ref);
   469         $ilTabs->setSubTabActive(
"cont_mob_from_media_pool");
   471         $ilCtrl->setParameter($this, 
"subCmd", 
"poolSelection");
   472         if ($a_change_obj_ref) {
   473             $exp = 
new ilPoolSelectorGUI($this, 
"changeObjectReference", $this, 
"changeObjectReference");
   479         $exp->setTypeWhiteList(array(
"root", 
"cat", 
"grp", 
"fold", 
"crs", 
"mep"));
   480         $exp->setClickableTypes(array(
'mep'));
   482         if (!$exp->handleCommand()) {
   494         $this->
create(
false, 
true);
   505         $ids = $this->request->getIntArray(
"id");
   506         if (count($ids) == 1) {
   508             $this->content_obj->readMediaObject($fid);
   509             $this->content_obj->updateObjectReference();
   510             $this->updated = $this->pg_obj->update();
   512             $this->tpl->setOnScreenMessage(
'info', 
$lng->
txt(
"cont_select_max_one_item"), 
true);
   513             $ilCtrl->redirect($this, 
"changeObjectReference");
   515         $ilCtrl->redirect($this, 
"editAlias");
   522         bool $a_create_alias = 
true,
   523         bool $a_change_obj_ref = 
false   528         if ($this->sub_command == 
"insertFromPool") {
   529             $ids = $this->request->getIntArray(
"id");
   530             for ($i = count($ids) - 1; $i >= 0; $i--) {
   533                 $this->content_obj->readMediaObject($fid);
   534                 $this->content_obj->createAlias(
   536                     $this->request->getHierId(),
   540             $this->updated = $this->pg_obj->update();
   547         $mob_gui->initForm(
"create");
   549         if (!$mob_gui->checkFormInput()) {
   550             $this->
form = $mob_gui->getForm();
   551             $this->
insert(
"edpost", 
"", 
true);
   555         if ($a_change_obj_ref != 
true) {
   558         $this->content_obj->createMediaObject();
   559         $media_obj = $this->content_obj->getMediaObject();
   561         $mob_gui->setObjectPerCreationForm($media_obj);
   563         if ($a_create_alias) {
   567             $this->content_obj->createAlias($this->pg_obj, $this->hier_id, $this->pc_id);
   568             $this->updated = $this->pg_obj->update();
   569             if ($this->updated === 
true) {
   570                 $this->pg_obj->stripHierIDs();
   571                 $this->pg_obj->addHierIDs();
   572                 $ilCtrl->setParameter($this, 
"hier_id", $this->content_obj->readHierId());
   573                 $ilCtrl->setParameter($this, 
"pc_id", $this->content_obj->readPCId());
   574                 $this->content_obj->setHierId($this->content_obj->readHierId());
   575                 $this->
setHierId($this->content_obj->readHierId());
   576                 $this->content_obj->setPcId($this->content_obj->readPCId());
   577                 $this->tpl->setOnScreenMessage(
'success', 
$lng->
txt(
"saved_media_object"), 
true);
   578                 $this->
ctrl->redirectByClass(
"ilobjmediaobjectgui", 
"edit");
   585             if ($a_change_obj_ref == 
true) {
   586                 $this->content_obj->updateObjectReference();
   587                 $this->updated = $this->pg_obj->update();
   588                 $this->
ctrl->redirect($this, 
"editAlias");
   605         if ($this->content_obj->checkInstanceEditing()) {
   606             $this->
ctrl->redirect($this, 
"editAlias");
   608         $this->
ctrl->redirectByClass(
"ilobjmediaobjectgui", 
"edit");
   631         $std_item = $this->content_obj->getMediaObject()->getMediaItem(
"Standard");
   635         $this->form_gui->addItem($title);
   637             $this->
lng->txt(
"cont_" . strtolower($std_item->getLocationType())),
   640         $this->form_gui->addItem($loc);
   642             $this->
lng->txt(
"cont_format"),
   645         $this->form_gui->addItem($format);
   649         $orig_size = $std_item->getOriginalSize();
   650         $add_str = (!is_null($orig_size))
   651             ? 
" (" . $orig_size[
"width"] . 
" x " . $orig_size[
"height"] . 
")"   655         $radio_size->addOption($op1);
   659                 " / " . 
$lng->
txt(
"cont_height"), 
"st_width_height");
   660         if (is_int(strpos($std_item->getFormat(), 
"image"))
   661             && $std_item->getLocationType() === 
"LocalFile") {
   663             $width_height->setConstrainProportions(
true);
   667         $radio_size->addOption($op2);
   668         $this->form_gui->addItem($radio_size);
   676         $rad_caption->addOption($op1);
   679         $caption->setCols(30);
   680         $caption->setRows(2);
   687         $rad_caption->addOption($op2);
   688         $this->form_gui->addItem($rad_caption);
   691         if ($this->media_type->usesAltTextProperty($std_item->getFormat())) {
   700             $rad_tr->addOption($op1);
   702             $rad_tr->addOption($op2);
   703             $this->form_gui->addItem($rad_tr);
   704             $rad_tr->setInfo(
$lng->
txt(
"text_repr_info"));
   708         if ($this->media_type->usesParameterProperty($std_item->getFormat())) {
   709             if ($this->media_type->usesAutoStartParameterOnly(
   710                 $std_item->getLocation(),
   711                 $std_item->getFormat()
   734                 $rad_parameters->addOption($op1);
   740                 $rad_parameters->addOption($op2);
   741                 $this->form_gui->addItem($rad_parameters);
   746         if ($this->content_obj->getMediaObject()->hasFullScreenItem()) {
   747             $full_item = $this->content_obj->getMediaObject()->getMediaItem(
"Fullscreen");
   750             $fs_sec->setTitle(
$lng->
txt(
"cont_fullscreen"));
   751             $this->form_gui->addItem($fs_sec);
   757             $radio_prop->addOption($op1);
   758             $op2 = 
new ilRadioOption($this->
lng->txt(
"cont_" . strtolower($full_item->getLocationType())) . 
": " .
   759                 $full_item->getLocation(), 
"y");
   760             $radio_prop->addOption($op2);
   761             $this->form_gui->addItem($radio_prop);
   765                 $this->
lng->txt(
"cont_format"),
   768             $this->form_gui->addItem($format);
   772             $fw_size = $std_item->getOriginalSize();
   773             $add_str = (!is_null($fw_size))
   774                 ? 
" (" . $fw_size[
"width"] . 
" x " . $fw_size[
"height"] . 
")"   778             $radio_size->addOption($op1);
   782                     " / " . 
$lng->
txt(
"cont_height"), 
"full_width_height");
   783             if (is_int(strpos($full_item->getFormat(), 
"image"))
   784                 && $full_item->getLocationType() === 
"LocalFile") {
   786                 $width_height->setConstrainProportions(
true);
   790             $radio_size->addOption($op2);
   791             $this->form_gui->addItem($radio_size);
   799             $rad_caption->addOption($op1);
   802             $caption->setCols(30);
   803             $caption->setRows(2);
   810             $rad_caption->addOption($op2);
   811             $this->form_gui->addItem($rad_caption);
   814             if (substr($full_item->getFormat(), 0, 5) == 
"image") {
   823                 $rad_tr->addOption($op1);
   825                 $rad_tr->addOption($op2);
   826                 $this->form_gui->addItem($rad_tr);
   827                 $rad_tr->setInfo(
$lng->
txt(
"text_repr_info"));
   831             if ($this->media_type->usesParameterProperty($full_item->getFormat())) {
   832                 if ($this->media_type->usesAutoStartParameterOnly(
   833                     $full_item->getLocation(),
   834                     $full_item->getFormat()
   857                     $rad_parameters->addOption($op1);
   863                     $rad_parameters->addOption($op2);
   864                     $this->form_gui->addItem($rad_parameters);
   869         $this->form_gui->setTitle(
$lng->
txt(
"cont_edit_mob_alias_prop"));
   870         $this->form_gui->addCommandButton(
"saveAliasProperties", 
$lng->
txt(
"save"));
   872         if (
$lm_set->get(
"replace_mob_feature")) {
   873             $this->form_gui->addCommandButton(
"changeObjectReference", 
$lng->
txt(
"cont_change_object_reference"));
   875         $this->form_gui->setFormAction($ilCtrl->getFormAction($this));
   887         $std_alias_item = $this->content_obj->getStandardMediaAliasItem();
   888         $std_item = $this->content_obj->getMediaObject()->getMediaItem(
"Standard");
   890         $values[
"title"] = $this->content_obj->getMediaObject()->getTitle();
   891         $values[
"st_location"] = $std_item->getLocation();
   892         $values[
"st_format"] = $std_item->getFormat();
   895         if ($std_alias_item->definesSize()) {
   896             $values[
"st_width_height"][
"width"] = $std_alias_item->getWidth();
   897             $values[
"st_width_height"][
"height"] = $std_alias_item->getHeight();
   898             $values[
"st_width_height"][
"constr_prop"] = 
true;
   900             if ($std_item->getWidth() !== 
"" || $std_item->getHeight() !== 
"") {
   901                 $values[
"st_width_height"][
"width"] = $std_item->getWidth();
   902                 $values[
"st_width_height"][
"height"] = $std_item->getHeight();
   903                 $values[
"st_width_height"][
"constr_prop"] = 
true;
   905                 $orig_size = $std_item->getOriginalSize();
   906                 if (!is_null($orig_size)) {
   907                     $values[
"st_width_height"][
"width"] = $orig_size[
"width"];
   908                     $values[
"st_width_height"][
"height"] = $orig_size[
"height"];
   909                     $values[
"st_width_height"][
"constr_prop"] = 
true;
   915         $values[
"st_caption"] = $std_alias_item->getCaption();
   916         if (trim($std_item->getCaption()) == 
"") {
   917             $values[
"def_caption"] = 
$lng->
txt(
"cont_no_caption");
   919             $values[
"def_caption"] = $std_item->getCaption();
   923         $values[
"st_text_representation"] = $std_alias_item->getTextRepresentation();
   924         if (trim($std_item->getTextRepresentation()) == 
"") {
   925             $values[
"def_text_representation"] = 
$lng->
txt(
"cont_no_text");
   927             $values[
"def_text_representation"] = $std_item->getTextRepresentation();
   931         if ($this->media_type->usesAutoStartParameterOnly(
   932             $std_item->getLocation(),
   933             $std_item->getFormat()
   941             $values[
"st_parameters"] = $std_alias_item->getParameterString();
   945         $values[
"st_derive_size"] = $std_alias_item->definesSize()
   948         $values[
"st_derive_caption"] = $std_alias_item->definesCaption()
   951         $values[
"st_derive_text_representation"] = $std_alias_item->definesTextRepresentation()
   954         $values[
"st_derive_parameters"] = $std_alias_item->definesParameters()
   957         if (trim($std_item->getParameterString()) == 
"") {
   958             $values[
"def_parameters"] = 
"<i>" . 
$lng->
txt(
"cont_no_parameters") . 
"</i>";
   960             $values[
"def_parameters"] = $std_item->getParameterString();
   964         if ($this->content_obj->getMediaObject()->hasFullScreenItem()) {
   965             $full_alias_item = $this->content_obj->getFullscreenMediaAliasItem();
   966             $full_item = $this->content_obj->getMediaObject()->getMediaItem(
"Fullscreen");
   968             $values[
"fullscreen"] = 
"n";
   969             if ($full_alias_item->exists()) {
   970                 $values[
"fullscreen"] = 
"y";
   973             $values[
"full_location"] = $full_item->getLocation();
   974             $values[
"full_format"] = $full_item->getFormat();
   976             if ($full_alias_item->definesSize()) {
   977                 $values[
"full_width_height"][
"width"] = $full_alias_item->getWidth();
   978                 $values[
"full_width_height"][
"height"] = $full_alias_item->getHeight();
   979                 $values[
"full_width_height"][
"constr_prop"] = 
true;
   981                 if ($full_item->getWidth() !== 
"" || $full_item->getHeight() !== 
"") {
   982                     $values[
"full_width_height"][
"width"] = $full_item->getWidth();
   983                     $values[
"full_width_height"][
"height"] = $full_item->getHeight();
   984                     $values[
"full_width_height"][
"constr_prop"] = 
true;
   986                     $orig_full_size = $full_item->getOriginalSize();
   987                     if (!is_null($orig_full_size)) {
   988                         $values[
"full_width_height"][
"width"] = $orig_full_size[
"width"];
   989                         $values[
"full_width_height"][
"height"] = $orig_full_size[
"height"];
   990                         $values[
"full_width_height"][
"constr_prop"] = 
true;
   995             $values[
"full_caption"] = $full_alias_item->getCaption();
   996             if (trim($full_item->getCaption()) == 
"") {
   997                 $values[
"full_def_caption"] = 
$lng->
txt(
"cont_no_caption");
   999                 $values[
"full_def_caption"] = $full_item->getCaption();
  1001             $values[
"full_text_representation"] = $full_alias_item->getTextRepresentation();
  1002             if (trim($full_item->getTextRepresentation()) == 
"") {
  1003                 $values[
"full_def_text_representation"] = 
$lng->
txt(
"cont_no_text");
  1005                 $values[
"full_def_text_representation"] = $full_item->getTextRepresentation();
  1007             $values[
"full_parameters"] = $full_alias_item->getParameterString();
  1008             $values[
"full_derive_size"] = $full_alias_item->definesSize()
  1011             $values[
"full_derive_caption"] = $full_alias_item->definesCaption()
  1014             $values[
"full_derive_text_representation"] = $full_alias_item->definesTextRepresentation()
  1019             if ($this->media_type->usesAutoStartParameterOnly(
  1020                 $full_item->getLocation(),
  1021                 $full_item->getFormat()
  1029                 $values[
"full_parameters"] = $full_alias_item->getParameterString();
  1032             $values[
"full_derive_parameters"] = $full_alias_item->definesParameters()
  1035             if (trim($full_item->getParameterString()) == 
"") {
  1036                 $values[
"full_def_parameters"] = 
"<i>" . 
$lng->
txt(
"cont_no_parameters") . 
"</i>";
  1038                 $values[
"full_def_parameters"] = $full_item->getParameterString();
  1042         $this->form_gui->setValuesByArray($values, 
true);
  1054         $std_alias_item = $this->content_obj->getStandardMediaAliasItem();
  1055         $full_alias_item = $this->content_obj->getFullscreenMediaAliasItem();
  1056         $std_item = $this->content_obj->getMediaObject()->getMediaItem(
"Standard");
  1057         $full_item = $this->content_obj->getMediaObject()->getMediaItem(
"Fullscreen");
  1060         if ($form->
getInput(
"st_derive_size") == 
"y") {
  1061             $std_alias_item->deriveSize();
  1063             $size = $this->request->getStringArray(
"st_width_height");
  1064             $std_alias_item->setWidth($size[
"width"]);
  1065             $std_alias_item->setHeight($size[
"height"]);
  1069         if ($form->
getInput(
"st_derive_caption") == 
"y") {
  1070             $std_alias_item->deriveCaption();
  1072             $std_alias_item->setCaption($form->
getInput(
"st_caption"));
  1076         if ($form->
getInput(
"st_derive_text_representation") == 
"y") {
  1077             $std_alias_item->deriveTextRepresentation();
  1079             $std_alias_item->setTextRepresentation(
  1080                 $form->
getInput(
"st_text_representation")
  1085         if ($form->
getInput(
"st_derive_parameters") == 
"y") {
  1086             $std_alias_item->deriveParameters();
  1088             if ($this->media_type->usesAutoStartParameterOnly(
  1089                 $std_item->getLocation(),
  1090                 $std_item->getFormat()
  1094                 $std_alias_item->setParameters(
  1102         if ($this->content_obj->getMediaObject()->hasFullscreenItem()) {
  1103             if ($form->
getInput(
"fullscreen") == 
"y") {
  1104                 if (!$full_alias_item->exists()) {
  1105                     $full_alias_item->insert();
  1109                 if ($form->
getInput(
"full_derive_size") == 
"y") {
  1110                     $full_alias_item->deriveSize();
  1112                     $full_size = $this->request->getStringArray(
"full_width_height");
  1113                     $full_alias_item->setWidth($full_size[
"width"]);
  1114                     $full_alias_item->setHeight($full_size[
"height"]);
  1118                 if ($form->
getInput(
"full_derive_caption") == 
"y") {
  1119                     $full_alias_item->deriveCaption();
  1121                     $full_alias_item->setCaption($form->
getInput(
"full_caption"));
  1125                 if ($form->
getInput(
"full_derive_text_representation") == 
"y") {
  1126                     $full_alias_item->deriveTextRepresentation();
  1128                     $full_alias_item->setTextRepresentation(
  1129                         $form->
getInput(
"full_text_representation")
  1134                 if ($form->
getInput(
"full_derive_parameters") == 
"y") {
  1135                     $full_alias_item->deriveParameters();
  1137                     if ($this->media_type->usesAutoStartParameterOnly(
  1138                         $full_item->getLocation(),
  1139                         $full_item->getFormat()
  1147                 if ($full_alias_item->exists()) {
  1148                     $full_alias_item->delete();
  1153         $this->updated = $this->pg_obj->update();
  1154         if ($this->updated === 
true) {
  1155             $this->tpl->setOnScreenMessage(
'success', $this->
lng->txt(
"msg_obj_modified"), 
true);
  1156             $this->
ctrl->redirect($this, 
"editAlias");
  1157             $this->
ctrl->returnToParent($this, 
"jump" . $this->hier_id);
  1159             $this->pg_obj->addHierIDs();
  1171         $ilUser->
addObjectToClipboard($this->content_obj->getMediaObject()->getId(), $this->content_obj->getMediaObject()->getType(), $this->content_obj->getMediaObject()->getTitle());
  1172         $this->tpl->setOnScreenMessage(
'success', $this->
lng->txt(
"copied_to_clipboard"), 
true);
  1173         $this->
ctrl->returnToParent($this, 
"jump" . $this->hier_id);
  1181         $std_alias_item = $this->content_obj->getStandardMediaAliasItem();
  1182         $std_alias_item->setHorizontalAlign(
"Center");
  1191         $std_alias_item = $this->content_obj->getStandardMediaAliasItem();
  1192         $std_alias_item->setHorizontalAlign(
"Left");
  1201         $std_alias_item = $this->content_obj->getStandardMediaAliasItem();
  1202         $std_alias_item->setHorizontalAlign(
"Right");
  1211         $std_alias_item = $this->content_obj->getStandardMediaAliasItem();
  1212         $std_alias_item->setHorizontalAlign(
"LeftFloat");
  1221         $std_alias_item = $this->content_obj->getStandardMediaAliasItem();
  1222         $std_alias_item->setHorizontalAlign(
"RightFloat");
  1235             ($this->content_obj->getClass() != 
"" && $this->content_obj->getClass() != 
"Media")) {
  1246         $a_seleted_value = 
"";
  1256         $form->
setTitle($this->
lng->txt(
"cont_edit_style"));
  1259             $this->
lng->txt(
"cont_characteristic"),
  1264         if (is_object($this->content_obj)) {
  1265             if (($chars[$a_seleted_value] ?? 
"") === 
"" && ($this->content_obj->getClass() !== 
"")) {
  1266                 $chars = array_merge(
  1267                     array($this->content_obj->getClass() => $this->content_obj->getClass()),
  1273         $selected = $this->content_obj->getClass();
  1274         if ($selected == 
"") {
  1275             $selected = 
"MediaContainer";
  1279         foreach ($chars as $k => $char) {
  1280             $html = 
'<div class="ilCOPgEditStyleSelectionItem">' .
  1283             $options[$k] = $char;
  1285         $char_prop->setOptions($options);
  1287         $char_prop->setValue($selected);
  1293             $this->
lng->txt(
"cont_caption_style"),
  1301         $cap_style->setOptions($options);
  1303         if (count($options) > 0) {
  1304             $current_value = $this->content_obj->getCaptionClass() ?: 
"MediaCaption";
  1305             $cap_style->setValue($current_value);
  1320             $this->
lng->txt(
"cont_characteristic"),
  1324         $selected = $this->content_obj->getClass();
  1325         if ($selected == 
"") {
  1326             $selected = 
"MediaContainer";
  1330         if (is_object($this->content_obj)) {
  1331             if ((
$chars[$selected] ?? 
"") == 
"" && ($this->content_obj->getClass() != 
"")) {
  1333                     array($this->content_obj->getClass() => $this->content_obj->getClass()),
  1340         foreach (
$chars as $k => $char) {
  1341             $html = 
'<div class="ilCOPgEditStyleSelectionItem">' .
  1344             $options[$k] = $char;
  1346         $char_prop->setOptions($options);
  1347         $char_prop->setValue($selected);
  1357         $this->content_obj->setClass(
  1358             $this->request->getString(
"characteristic")
  1360         $this->content_obj->setCaptionClass(
  1361             $this->request->getString(
"caption_style")
  1364         $this->updated = $this->pg_obj->update();
  1365         if ($this->updated === 
true) {
  1366             $this->
ctrl->returnToParent($this, 
"jump" . $this->hier_id);
  1368             $this->pg_obj->addHierIDs();
  1374         bool $a_create = 
false,
  1375         bool $a_change_obj_ref = 
false  1384                     $ilCtrl->getLinkTarget($this, 
"editStyle"),
  1390             if ($this->content_obj->checkInstanceEditing()) {
  1392                     "cont_mob_inst_prop",
  1393                     $ilCtrl->getLinkTarget($this, 
"editAlias"),
  1399                     $st_item = $this->content_obj->getMediaObject()->getMediaItem(
"Standard");
  1400                     if (is_object($st_item)) {
  1401                         $format = $st_item->getFormat();
  1402                         if (substr($format, 0, 5) == 
"image" && !is_int(strpos($format, 
"svg"))) {
  1404                                 "cont_inst_map_areas",
  1405                                 $ilCtrl->getLinkTargetByClass(
"ilpcimagemapeditorgui", 
"editMapAreas"),
  1407                                 "ilpcimagemapeditorgui"  1414             if ($a_change_obj_ref) {
  1415                 $cmd = 
"changeObjectReference";
  1420             if ($a_change_obj_ref) {
  1421                 $ilCtrl->setParameter($this, 
"subCmd", 
"insertNew");
  1422                 $ilTabs->addSubTabTarget(
  1424                     $ilCtrl->getLinkTarget($this, $cmd),
  1428                 $ilCtrl->setParameter($this, 
"subCmd", 
"insertFromPool");
  1429                 $ilTabs->addSubTabTarget(
  1430                     "cont_mob_from_media_pool",
  1431                     $ilCtrl->getLinkTarget($this, $cmd),
  1434                 $ilCtrl->setParameter($this, 
"subCmd", 
"");
  1442     public static function _getStandardCharacteristics(): array
  1447         $lng = $DIC->language();
  1450             "MediaContainer" => 
$lng->
txt(
"cont_Media"),
  1451             "MediaContainerMax50" => 
"MediaContainerMax50",
  1452             "MediaContainerFull100" => 
"MediaContainerFull100",
  1453             "MediaContainerHighlighted" => 
"MediaContainerHighlighted",
  1454             "MediaContainerSeparated" => 
"MediaContainerSeparated"  1463         $chars = self::_getStandardCharacteristics();
  1464         if ($a_style_id > 0 &&
  1468             $new_chars = array();
  1469             foreach (
$chars as $char) {
  1470                 if ((
$chars[$char] ?? 
"") != 
"") {      
  1471                     $new_chars[$char] = 
$chars[$char];
  1473                     $new_chars[$char] = $char;
 
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
 
ilPageContent $content_obj
 
getCharacteristicsOfCurrentStyle(array $a_type)
Get characteristics of current style and call setCharacteristics, if style is given. 
 
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
 
txt(string $a_topic, string $a_default_lang_fallback_mod="")
gets the text for a given topic if the topic is not in the list, the topic itself with "-" will be re...
 
addTarget(string $a_text, string $a_link, $a_cmd="", $a_cmdClass="", string $a_frame="", bool $a_activate=false, bool $a_dir_text=false)
 
setHierId(string $a_hier_id)
set hierarchical id in dom object 
 
redirectToParent(string $hier_id="")
 
loadLanguageModule(string $a_module)
Load language module. 
 
addObjectToClipboard(int $a_item_id, string $a_type, string $a_title, int $a_parent=0, string $a_time='', int $a_order_nr=0)
add an item to user's personal clipboard 
 
setCharacteristics(array $a_chars)
 
setTitleIcon(string $a_icon_path, string $a_icon_desc="")
set title icon 
 
Content object of ilPageObject (see ILIAS DTD). 
 
static _lookupObjId(int $ref_id)
 
User Interface for Editing of Page Content Objects (Paragraphs, Tables, ...) 
 
getHierIdsForPCIds(array $a_pc_ids)
Get hier ids for a set of pc ids. 
 
setContent(string $a_html)
Sets content for standard template. 
 
Class ilPageObject Handles PageObjects of ILIAS Learning Modules (see ILIAS DTD) 
 
ilGlobalTemplateInterface $tpl
 
static getImagePath(string $image_name, string $module_path="", string $mode="output", bool $offline=false)
get image path (for images located in a template directory) 
 
setTitle(string $a_title, bool $hidden=false)
Sets title in standard template. 
 
User interface class for page content map editor. 
 
form( $class_path, string $cmd, string $submit_caption="")
 
getCharacteristics(string $a_type="", bool $a_no_hidden=false, bool $a_include_core=true)
Get characteristics. 
 
static extractParameterString(string $a_parstr)
 
__construct(Container $dic, ilPlugin $plugin)
 
This class represents a text area property in a property form. 
 
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
 
setParameter(object $a_gui_obj, string $a_parameter, $a_value)
 
static _lookupType(int $id, bool $reference=false)