Go away when idle checkbox added to General Preferences.
This commit is contained in:
@@ -70,6 +70,7 @@ BOOL LLPanelGeneral::postBuild()
|
||||
childSetValue("show_my_name_checkbox", gSavedSettings.getBOOL("RenderNameHideSelf"));
|
||||
childSetValue("small_avatar_names_checkbox", gSavedSettings.getBOOL("SmallAvatarNames"));
|
||||
childSetValue("show_my_title_checkbox", gSavedSettings.getBOOL("RenderHideGroupTitle"));
|
||||
childSetValue("away_when_idle_checkbox", gSavedSettings.getBOOL("AllowIdleAFK"));
|
||||
childSetValue("afk_timeout_spinner", gSavedSettings.getF32("AFKTimeout"));
|
||||
childSetValue("notify_money_change_checkbox", gSavedSettings.getBOOL("NotifyMoneyChange"));
|
||||
childSetValue("no_transaction_clutter_checkbox", gSavedSettings.getBOOL("LiruNoTransactionClutter"));
|
||||
@@ -112,6 +113,9 @@ BOOL LLPanelGeneral::postBuild()
|
||||
childSetVisible("maturity_desired_combobox", can_choose);
|
||||
childSetVisible("maturity_desired_textbox", !can_choose);
|
||||
|
||||
childSetEnabled("afk_timeout_spinner", gSavedSettings.getBOOL("AllowIdleAFK"));
|
||||
childSetCommitCallback("away_when_idle_checkbox", &onClickCheckbox, this);
|
||||
|
||||
childSetEnabled("no_transaction_clutter_checkbox", gSavedSettings.getBOOL("NotifyMoneyChange"));
|
||||
childSetCommitCallback("notify_money_change_checkbox", &onClickCheckbox, this);
|
||||
|
||||
@@ -149,6 +153,7 @@ void LLPanelGeneral::apply()
|
||||
gSavedSettings.setBOOL("RenderNameHideSelf", childGetValue("show_my_name_checkbox"));
|
||||
gSavedSettings.setBOOL("SmallAvatarNames", childGetValue("small_avatar_names_checkbox"));
|
||||
gSavedSettings.setBOOL("RenderHideGroupTitle", childGetValue("show_my_title_checkbox"));
|
||||
gSavedSettings.setBOOL("AllowIdleAFK", childGetValue("away_when_idle_checkbox"));
|
||||
gSavedSettings.setF32("AFKTimeout", childGetValue("afk_timeout_spinner").asReal());
|
||||
gSavedSettings.setBOOL("NotifyMoneyChange", childGetValue("notify_money_change_checkbox"));
|
||||
gSavedSettings.setBOOL("LiruNoTransactionClutter", childGetValue("no_transaction_clutter_checkbox"));
|
||||
@@ -173,7 +178,9 @@ void LLPanelGeneral::onClickCheckbox(LLUICtrl* ctrl, void* data)
|
||||
{
|
||||
LLPanelGeneral* self = (LLPanelGeneral*)data;
|
||||
bool enabled = ctrl->getValue().asBoolean();
|
||||
if(ctrl->getName() == "notify_money_change_checkbox")
|
||||
if(ctrl->getName() == "away_when_idle_checkbox")
|
||||
self->childSetEnabled("afk_timeout_spinner", enabled);
|
||||
else if(ctrl->getName() == "notify_money_change_checkbox")
|
||||
self->childSetEnabled("no_transaction_clutter_checkbox", enabled);
|
||||
}
|
||||
|
||||
|
||||
@@ -23,8 +23,8 @@
|
||||
<text bottom="-180" height="12" left="10" name="UI Size:">UI Size:</text>
|
||||
<slider bottom="-180" can_edit_text="true" height="16" increment="0.025" initial_val="1" left="98" max_val="1.4" min_val="0.75" name="ui_scale_slider" value="1" width="227" />
|
||||
<check_box bottom="-195" height="16" initial_value="false" label="Use resolution independent scale" left="101" name="ui_auto_scale"/>
|
||||
<spinner bottom="-220" decimal_digits="0" height="16" increment="1" initial_val="300" label="Away Timeout:" label_width="91" left="10" max_val="600" min_val="0" name="afk_timeout_spinner" width="137"/>
|
||||
<check_box bottom="-257" height="16" initial_value="false" label="Notify when in-world currency is spent or received" left="10" name="notify_money_change_checkbox"/>
|
||||
<check_box bottom="-219" height="16" left="10" label="Go away when idle" name="away_when_idle_checkbox"/>
|
||||
<spinner bottom="-220" decimal_digits="0" height="16" increment="1" initial_val="300" label="Away Timeout:" label_width="91" left="136" max_val="600" min_val="0" name="afk_timeout_spinner" width="137"/>
|
||||
<check_box bottom="-257" height="16" initial_value="false" label="Notify when in-world currency is exchanged" left="10" name="notify_money_change_checkbox"/>
|
||||
<check_box bottom="-257" height="16" label="without filling up the corner" left="245" name="no_transaction_clutter_checkbox" tool_tip="Still present the notifications, but have them pop up in the bottom right momentarily, then leave, so the transaction draws attention but doesn't get in the way."/>
|
||||
<text bottom="-291" height="10" left="10" name="maturity_desired_label">Rating:</text>
|
||||
@@ -37,7 +37,7 @@
|
||||
<text bottom="-291" height="10" left="265" name="maturity_desired_textbox">PG only</text>
|
||||
<text bottom="-20" height="10" left="10" name="start_location_textbox">Start Location:</text>
|
||||
<text bottom="-64" height="10" name="show_names_textbox">Show Names:</text>
|
||||
<text bottom="-214" height="10" left="150" name="seconds_textbox">seconds</text>
|
||||
<text bottom="-214" height="10" left="276" name="seconds_textbox">seconds</text>
|
||||
<text bottom="-331" height="18" left="10" name="crash_report_textbox">Crash reports:</text>
|
||||
<text bottom="-363" height="18" name="language_textbox">Language:</text>
|
||||
<text bottom_delta="6" follows="top" height="18" left_delta="243" name="language_textbox2">(Requires restart for full effect)
|
||||
|
||||
Reference in New Issue
Block a user