Add Double-click Autopilot option to System->General preferences.

Translators:
Nomade: Please review the french System->General and make sure it reads properly
Damian: Please take care of translating panel_preferences_ascent_system.xml
miKa: Please update the translation of panel_preferences_ascent_system.xml so it reads properly.
This commit is contained in:
Lirusaito
2015-11-13 13:06:33 -05:00
parent 966be89d98
commit 855e1d9caa
6 changed files with 26 additions and 16 deletions

View File

@@ -654,6 +654,19 @@ static bool handleAllowLargeSounds(const LLSD& newvalue)
return true;
}
enum DCAction { AUTOPILOT, TELEPORT };
static void handleDoubleClickActionChanged(const DCAction& action, const LLSD& newvalue)
{
// Doubleclick actions - there can be only one
if (newvalue.asBoolean())
{
if (action == AUTOPILOT)
gSavedSettings.setBOOL("DoubleClickTeleport", false);
else
gSavedSettings.setBOOL("DoubleClickAutopilot", false);
}
}
void handleHighResChanged(const LLSD& val)
{
if (val) // High Res Snapshot active, must uncheck RenderUIInSnapshot
@@ -855,6 +868,8 @@ void settings_setup_listeners()
gSavedSettings.getControl("AllowLargeSounds")->getSignal()->connect(boost::bind(&handleAllowLargeSounds, _2));
gSavedSettings.getControl("LiruUseZQSDKeys")->getSignal()->connect(boost::bind(load_default_bindings, _2));
gSavedSettings.getControl("DoubleClickAutopilot")->getSignal()->connect(boost::bind(handleDoubleClickActionChanged, AUTOPILOT, _2));
gSavedSettings.getControl("DoubleClickTeleport")->getSignal()->connect(boost::bind(handleDoubleClickActionChanged, TELEPORT, _2));
gSavedSettings.getControl("HighResSnapshot")->getSignal()->connect(boost::bind(&handleHighResChanged, _2));
}

View File

@@ -7306,16 +7306,7 @@ void menu_toggle_double_click_control(void* user_data)
{
std::string setting(static_cast<char*>(user_data));
LLControlVariable* control(gSavedSettings.getControl(setting));
bool checked = control->get();
// Doubleclick actions - there can be only one
if (!checked)
{
if (setting == "DoubleClickAutoPilot")
gSavedSettings.setBOOL("DoubleClickTeleport", false);
else if (setting == "DoubleClickTeleport")
gSavedSettings.setBOOL("DoubleClickAutoPilot", false);
}
control->set(!checked);
control->set(!control->get());
}

View File

@@ -3,8 +3,9 @@
<tab_container label="System" name="Ascent System">
<panel label="Generell" name="User Interface">
<check_box label="Teleport mit Doppelklick erlauben" tool_tip="Doppelklick auf eine Person oder Ort teleportiert dich dorthin" name="double_click_teleport_check"/>
<check_box label="Kamera nach Teleport zurücksetzen" tool_tip="Platziert die Kamera nach einem Teleport in der Standardposition" name="center_after_teleport_check"/>
<text name="double_click_text" value="Doppelklick"/>
<check_box label="Teleport" tool_tip="Doppelklick auf eine Person oder Ort teleportiert dich dorthin" name="double_click_teleport_check"/>
<check_box label="Kamera nach Teleport zurücksetzen" tool_tip="Platziert die Kamera nach einem Teleport in der Standardposition" name="center_after_teleport_check"/>
<check_box label="TP Ziel um halbe Avatargrösse erhöhen" tool_tip="Versucht den TP so zu platzieren dass der Avatar genau am Zielpunkt ankommt" name="offset_teleport_check"/>
<check_box name="clear_beacon_after_tp" label="Lösche roten Ankunftsmarker nach Teleport"/>
<check_box name="fly_after_tp" label="Nach Teleport immer fliegen" tool_tip="Vermeide Fallen aus großer Höhe durch automatisches Fliegen nach Teleport"/>

View File

@@ -3,8 +3,10 @@
<tab_container label="System" bottom="0" height="440" width="497" left="0" name="Ascent System" tab_min_width="70" tab_position="top">
<panel border="true" left="1" bottom="-408" height="408" width="500" label="General" name="User Interface">
<check_box left="10" bottom_delta="-25" control_name="DoubleClickTeleport" follows="top" initial_value="false"
label="Enable teleporting via double-click in-world" tool_tip="Double-clicking on an object/person will teleport you to that location." name="double_click_teleport_check"/>
<text left="12" bottom_delta="-20" follows="top" name="double_click_text" value="Enable double-click"/>
<check_box left_delta="105" bottom_delta="-5" control_name="DoubleClickTeleport" follows="top"
label="teleport" tool_tip="Double-clicking on an object/person will teleport you to that location." name="double_click_teleport_check"/>
<check_box left_delta="67" bottom_delta="0" control_name="DoubleClickAutopilot" follows="top" label="autopilot" tool_tip="Double-clicking on something will make you walk to that location." name="double_click_autopilot_check"/>
<check_box enabled_control="DoubleClickTeleport" left="20" bottom_delta="-18" control_name="OptionRotateCamAfterLocalTP" follows="top" initial_value="false"
label="Reset camera after teleporting" tool_tip="Centers the camera behind you after a local teleport." name="center_after_teleport_check"/>
<check_box enabled_control="DoubleClickTeleport" bottom_delta="-18" control_name="OptionOffsetTPByAgentHeight" follows="left|top" font="SansSerifSmall" height="16" initial_value="false"

View File

@@ -3,7 +3,7 @@
<tab_container label="Sistema" name="Ascent System">
<!-- =========================== -->
<panel label="General" name="User Interface">
<check_box label="Habilitar Teleporte con doble click" tool_tip="Haciendo doble click en un objeto o persona te transportará hacia su ubicación." name="double_click_teleport_check"/>
<check_box tool_tip="Haciendo doble click en un objeto o persona te transportará hacia su ubicación." name="double_click_teleport_check"/>
<check_box label="Reiniciar la Cámara luego de Teleportar" tool_tip="Centra la cámara detrás tuyo luego de un teleport." name="center_after_teleport_check"/>
<check_box label="Desplazar destino TP a mitad de la altura del agente" tool_tip="Intenta apuntar el TP de modo que tus pies se apoyen en la tierra del punto al que estás apuntando." name="offset_teleport_check"/>
<check_box name="clear_beacon_after_tp" label="Borrar baliza roja de destino despues de teleportarte"/>

View File

@@ -3,7 +3,8 @@
<tab_container label="System" name="Ascent System">
<panel label="G&#xE9;n&#xE9;ral" name="User Interface">
<check_box label="Activer le TP avec le double-clic" tool_tip="Activer le TP sur un objet/une personne avec le double-clic" name="double_click_teleport_check"/>
<text name="double_click_text" value="Activer le double-clic pour"/>
<check_box left_delta="135" label="le TP" tool_tip="Activer le TP sur un objet/une personne avec le double-clic" name="double_click_teleport_check"/>
<check_box label="R&#xE9;initialiser la cam&#xE9;ra apr&#xE8;s le TP" tool_tip="Centre la cam&#xE9;ra derri&#xE8;re vous apr&#xE8;s un TP." name="center_after_teleport_check"/>
<check_box label="Compenser la cible du TP" tool_tip="Essaye de cibler le TP pour que vos pieds atterrissent au point vis&#xE9;" name="offset_teleport_check"/>
<check_box name="clear_beacon_after_tp" label="Effacer la balise rouge de destination après un TP"/>