ILIAS
release_5-2 Revision v5.2.25-18-g3f80b828510
|
Toolbar. More...
Public Member Functions | |
__construct () | |
setFormAction ($a_val, $a_multipart=false, $a_target="") | |
Set form action (if form action is set, toolbar is wrapped into form tags) More... | |
getFormAction () | |
Get form action. More... | |
setLeadingImage ($a_img, $a_alt) | |
Set leading image. More... | |
setHidden ($a_val) | |
Set hidden. More... | |
getHidden () | |
Get hidden. More... | |
setId ($a_val) | |
Set id. More... | |
getId () | |
Get id. More... | |
setPreventDoubleSubmission ($a_val) | |
Set prevent double submission. More... | |
getPreventDoubleSubmission () | |
Get prevent double submission. More... | |
addButton ($a_txt, $a_cmd, $a_target="", $a_acc_key="", $a_additional_attrs='', $a_id="", $a_class='submit') | |
Add button to toolbar. More... | |
addFormButton ($a_txt, $a_cmd, $a_acc_key="", $a_primary=false, $a_class=false) | |
Add form button to toolbar. More... | |
addInputItem (ilToolbarItem $a_item, $a_output_label=false) | |
Add input item. More... | |
addStickyItem (ilToolbarItem $a_item, $a_output_label=false) | |
Add a sticky item. More... | |
addButtonInstance (ilButtonBase $a_button) | |
Add button instance. More... | |
addDropDown ($a_txt, $a_dd_html) | |
Add input item. More... | |
addSeparator () | |
Add separator. More... | |
addText ($a_text) | |
Add text. More... | |
addSpacer ($a_width=null) | |
Add spacer. More... | |
addLink ($a_caption, $a_url, $a_disabled=false) | |
Add link. More... | |
setOpenFormTag ($a_val) | |
Set open form tag. More... | |
getOpenFormTag () | |
Get open form tag. More... | |
setCloseFormTag ($a_val) | |
Set close form tag. More... | |
getCloseFormTag () | |
Get close form tag. More... | |
setFormName ($a_val) | |
Set form name. More... | |
getFormName () | |
Get form name. More... | |
getGroupedItems () | |
Get all groups (items separated by a separator) More... | |
getItems () | |
setItems ($items) | |
Data Fields | |
$items = array() | |
Protected Member Functions | |
applyAutoStickyToSingleElement () | |
If the toolbar consists of only one button, make it sticky Note: Atm this is only possible for buttons. More... | |
Protected Attributes | |
$id = '' | |
$form_action = '' | |
$hidden | |
$lead_img | |
$open_form_tag = true | |
$close_form_tag = true | |
$form_target = "" | |
$form_name = "" | |
$prevent_double_submission = false | |
$sticky_items = array() | |
$has_separator = false | |
Static Protected Attributes | |
static | $instances = 0 |
Toolbar.
The toolbar currently only supports a list of buttons as links.
A default toolbar object is available in the $ilToolbar global object.
Definition at line 17 of file class.ilToolbarGUI.php.
ilToolbarGUI::__construct | ( | ) |
Definition at line 88 of file class.ilToolbarGUI.php.
ilToolbarGUI::addButton | ( | $a_txt, | |
$a_cmd, | |||
$a_target = "" , |
|||
$a_acc_key = "" , |
|||
$a_additional_attrs = '' , |
|||
$a_id = "" , |
|||
$a_class = 'submit' |
|||
) |
Add button to toolbar.
string | text |
string | link href / submit command |
string | frame target |
string | access key |
Definition at line 199 of file class.ilToolbarGUI.php.
References array.
Referenced by ilTestResultsToolbarGUI\build(), ilObjTestGUI\populateQuestionBrowserToolbarButtons(), ilBookingScheduleGUI\render(), ilBookingObjectGUI\render(), and ilMembershipGUI\showMailToMemberToolbarButton().
ilToolbarGUI::addButtonInstance | ( | ilButtonBase | $a_button | ) |
Add button instance.
ilButtonBase | $a_button |
Definition at line 264 of file class.ilToolbarGUI.php.
References addStickyItem(), array, and ilButtonBase\isPrimary().
Referenced by ilTestNavigationToolbarGUI\addFinishTestButton(), ilTestNavigationToolbarGUI\addQuestionListButton(), ilTestNavigationToolbarGUI\addQuestionSelectionButton(), ilTestNavigationToolbarGUI\addQuestionTreeButton(), ilTestNavigationToolbarGUI\addSuspendTestButton(), ilTestResultsToolbarGUI\build(), and ilTestSkillEvaluationToolbarGUI\build().
ilToolbarGUI::addDropDown | ( | $a_txt, | |
$a_dd_html | |||
) |
ilToolbarGUI::addFormButton | ( | $a_txt, | |
$a_cmd, | |||
$a_acc_key = "" , |
|||
$a_primary = false , |
|||
$a_class = false |
|||
) |
Add form button to toolbar.
string | text |
string | link href / submit command |
string | access key |
bool | primary action |
string | css class |
Definition at line 218 of file class.ilToolbarGUI.php.
References addStickyItem(), array, and ilSubmitButton\getInstance().
Referenced by ilDidacticTemplateGUI\appendToolbarSwitch(), ilAssQuestionPreviewToolbarGUI\build(), ilTestSkillEvaluationToolbarGUI\build(), ilTestInfoScreenToolbarGUI\build(), and ilTestRandomQuestionSetSourcePoolDefinitionListToolbarGUI\populateNewQuestionSelectionRuleInputs().
ilToolbarGUI::addInputItem | ( | ilToolbarItem | $a_item, |
$a_output_label = false |
|||
) |
Add input item.
ilToolbarItem | $a_item | |
bool | $a_output_label |
Definition at line 240 of file class.ilToolbarGUI.php.
References array.
Referenced by ilDidacticTemplateGUI\appendToolbarSwitch(), ilTestResultsToolbarGUI\build(), ilTestSkillEvaluationToolbarGUI\build(), and ilTestRandomQuestionSetSourcePoolDefinitionListToolbarGUI\populateNewQuestionSelectionRuleInputs().
ilToolbarGUI::addLink | ( | $a_caption, | |
$a_url, | |||
$a_disabled = false |
|||
) |
Add link.
string | $a_caption | |
string | $a_url | |
boolean | $a_disabled |
Definition at line 316 of file class.ilToolbarGUI.php.
References array.
ilToolbarGUI::addSeparator | ( | ) |
Add separator.
Definition at line 286 of file class.ilToolbarGUI.php.
References array.
Referenced by ilTestResultsToolbarGUI\build(), ilTestSkillEvaluationToolbarGUI\build(), ilTestInfoScreenToolbarGUI\build(), and ilMembershipGUI\showMailToMemberToolbarButton().
ilToolbarGUI::addSpacer | ( | $a_width = null | ) |
ilToolbarGUI::addStickyItem | ( | ilToolbarItem | $a_item, |
$a_output_label = false |
|||
) |
Add a sticky item.
Sticky items are always visible, also if the toolbar is collapsed (responsive view). Sticky items are displayed first in the toolbar.
ilToolbarItem | $a_item | |
bool | $a_output_label |
Definition at line 253 of file class.ilToolbarGUI.php.
References array.
Referenced by addButtonInstance(), addFormButton(), and applyAutoStickyToSingleElement().
ilToolbarGUI::addText | ( | $a_text | ) |
Add text.
Definition at line 295 of file class.ilToolbarGUI.php.
References array.
Referenced by ilDidacticTemplateGUI\appendToolbarSwitch().
|
protected |
If the toolbar consists of only one button, make it sticky Note: Atm this is only possible for buttons.
If we are dealing with objects implementing the ilToolbarItem interface one day, other elements can be added as sticky.
Definition at line 656 of file class.ilToolbarGUI.php.
References addStickyItem(), array, ilSubmitButton\getInstance(), and ilLinkButton\getInstance().
Referenced by getGroupedItems().
ilToolbarGUI::getCloseFormTag | ( | ) |
Get close form tag.
Definition at line 356 of file class.ilToolbarGUI.php.
References $close_form_tag.
Referenced by getGroupedItems().
ilToolbarGUI::getFormAction | ( | ) |
Get form action.
Definition at line 112 of file class.ilToolbarGUI.php.
References $form_action.
Referenced by getGroupedItems().
ilToolbarGUI::getFormName | ( | ) |
Get form name.
Definition at line 376 of file class.ilToolbarGUI.php.
References $form_name.
Referenced by getGroupedItems().
ilToolbarGUI::getGroupedItems | ( | ) |
Get all groups (items separated by a separator)
Definition at line 387 of file class.ilToolbarGUI.php.
References $GLOBALS, $li, $lng, $tpl, applyAutoStickyToSingleElement(), array, ilAccessKeyGUI\getAttribute(), getCloseFormTag(), getFormAction(), getFormName(), getHidden(), getId(), getOpenFormTag(), and getPreventDoubleSubmission().
ilToolbarGUI::getHidden | ( | ) |
Get hidden.
Definition at line 144 of file class.ilToolbarGUI.php.
References $hidden.
Referenced by getGroupedItems().
ilToolbarGUI::getId | ( | ) |
Get id.
Definition at line 164 of file class.ilToolbarGUI.php.
Referenced by ilTestInfoScreenToolbarGUI\build(), and getGroupedItems().
ilToolbarGUI::getItems | ( | ) |
Definition at line 636 of file class.ilToolbarGUI.php.
References $items.
Referenced by ilTestInfoScreenToolbarGUI\build().
ilToolbarGUI::getOpenFormTag | ( | ) |
Get open form tag.
Definition at line 336 of file class.ilToolbarGUI.php.
References $open_form_tag.
Referenced by getGroupedItems().
ilToolbarGUI::getPreventDoubleSubmission | ( | ) |
Get prevent double submission.
Definition at line 184 of file class.ilToolbarGUI.php.
References $prevent_double_submission.
Referenced by getGroupedItems().
ilToolbarGUI::setCloseFormTag | ( | $a_val | ) |
Set close form tag.
boolean | $a_val | close form tag |
Definition at line 346 of file class.ilToolbarGUI.php.
ilToolbarGUI::setFormAction | ( | $a_val, | |
$a_multipart = false , |
|||
$a_target = "" |
|||
) |
Set form action (if form action is set, toolbar is wrapped into form tags)
string | $a_val | form action |
bool | $a_multipart | |
string | $a_target |
Definition at line 100 of file class.ilToolbarGUI.php.
Referenced by ilTestRandomQuestionSetSourcePoolDefinitionListToolbarGUI\build(), and ilTestSkillEvaluationToolbarGUI\build().
ilToolbarGUI::setFormName | ( | $a_val | ) |
Set form name.
string | $a_val | form name |
Definition at line 366 of file class.ilToolbarGUI.php.
ilToolbarGUI::setHidden | ( | $a_val | ) |
ilToolbarGUI::setId | ( | $a_val | ) |
Set id.
string | $a_val | id |
Definition at line 154 of file class.ilToolbarGUI.php.
Referenced by ilTestResultsToolbarGUI\build().
ilToolbarGUI::setItems | ( | $items | ) |
array | $items |
Definition at line 645 of file class.ilToolbarGUI.php.
References $items.
Referenced by ilTestInfoScreenToolbarGUI\clearItems().
ilToolbarGUI::setLeadingImage | ( | $a_img, | |
$a_alt | |||
) |
Set leading image.
string | $a_img | |
string | $a_alt |
Definition at line 124 of file class.ilToolbarGUI.php.
References array.
ilToolbarGUI::setOpenFormTag | ( | $a_val | ) |
Set open form tag.
boolean | $a_val | open form tag |
Definition at line 326 of file class.ilToolbarGUI.php.
ilToolbarGUI::setPreventDoubleSubmission | ( | $a_val | ) |
Set prevent double submission.
bool | $a_val | prevent double submission |
Definition at line 174 of file class.ilToolbarGUI.php.
|
protected |
Definition at line 61 of file class.ilToolbarGUI.php.
Referenced by getCloseFormTag().
|
protected |
Definition at line 33 of file class.ilToolbarGUI.php.
Referenced by getFormAction().
|
protected |
Definition at line 71 of file class.ilToolbarGUI.php.
Referenced by getFormName().
|
protected |
Definition at line 66 of file class.ilToolbarGUI.php.
|
protected |
Definition at line 86 of file class.ilToolbarGUI.php.
|
protected |
Definition at line 38 of file class.ilToolbarGUI.php.
Referenced by getHidden().
|
protected |
Definition at line 28 of file class.ilToolbarGUI.php.
|
staticprotected |
Definition at line 23 of file class.ilToolbarGUI.php.
ilToolbarGUI::$items = array() |
Definition at line 43 of file class.ilToolbarGUI.php.
Referenced by getItems(), and setItems().
|
protected |
Definition at line 48 of file class.ilToolbarGUI.php.
|
protected |
Definition at line 56 of file class.ilToolbarGUI.php.
Referenced by getOpenFormTag().
|
protected |
Definition at line 76 of file class.ilToolbarGUI.php.
Referenced by getPreventDoubleSubmission().
|
protected |
Definition at line 81 of file class.ilToolbarGUI.php.