3 require_once
'Services/Form/classes/class.ilPropertyFormGUI.php';
59 parent::__construct();
61 $this->
user = $DIC->user();
62 $this->ctrl = $DIC->ctrl();
64 $this->mainTpl = $DIC[
'tpl'];
65 $this->lng = $DIC[
'lng'];
66 $this->
event = $DIC->event();
68 $this->chatSettings =
new ilSetting(
'chatroom');
69 $this->notificationSettings =
new ilSetting(
'notifications');
82 switch($this->ctrl->getCmd())
84 case 'saveChatOptions':
88 case 'showChatOptions':
101 $this->chatSettings->get(
'chat_enabled',
false) && (
112 return $this->notificationSettings->get(
'enable_osd',
false) && $this->chatSettings->get(
'play_invitation_sound',
false);
121 $this->chatSettings->get(
'enable_osc',
false) &&
122 !(bool)$this->
settings->get(
'usr_settings_hide_chat_osc_accept_msg',
false)
131 $this->lng->loadLanguageModule(
'chatroom');
133 $this->
setFormAction($this->ctrl->getFormAction($this,
'saveChatOptions'));
134 $this->
setTitle($this->lng->txt(
"chat_settings"));
138 $chb =
new ilCheckboxInputGUI($this->lng->txt(
'play_invitation_sound'),
'play_invitation_sound');
144 $chb =
new ilCheckboxInputGUI($this->lng->txt(
'chat_osc_accept_msg'),
'chat_osc_accept_msg');
145 $chb->
setInfo($this->lng->txt(
'chat_osc_accept_msg_info'));
146 $chb->setDisabled((
bool)$this->
settings->get(
'usr_settings_disable_chat_osc_accept_msg',
false));
160 $this->ctrl->returnToParent($this);
164 'play_invitation_sound' => $this->
user->getPref(
'chat_play_invitation_sound'),
165 'chat_osc_accept_msg' =>
ilUtil::yn2tf($this->
user->getPref(
'chat_osc_accept_msg'))
168 $this->mainTpl->setContent($this->
getHTML());
169 $this->mainTpl->show();
179 $this->ctrl->returnToParent($this);
190 $this->
user->setPref(
'chat_play_invitation_sound', (
int)$this->
getInput(
'play_invitation_sound'));
198 $this->
user->writePrefs();
202 'chatSettingsChanged',
204 'user' => $this->
user static sendSuccess($a_info="", $a_keep=false)
Send Success Message to Screen.
static tf2yn($a_tf)
convert true/false to "y"/"n"
Create styles array
The data for the language used.
static yn2tf($a_yn)
convert "y"/"n" to true/false