diff options
author | Jacek Antonelli | 2008-08-15 23:45:42 -0500 |
---|---|---|
committer | Jacek Antonelli | 2008-08-15 23:45:42 -0500 |
commit | ce28e056c20bf2723f565bbf464b87781ec248a2 (patch) | |
tree | ef7b0501c4de4b631a916305cbc2a5fdc125e52d /linden/indra/newview/llpanelinput.cpp | |
parent | Second Life viewer sources 1.19.1.4b (diff) | |
download | meta-impy-ce28e056c20bf2723f565bbf464b87781ec248a2.zip meta-impy-ce28e056c20bf2723f565bbf464b87781ec248a2.tar.gz meta-impy-ce28e056c20bf2723f565bbf464b87781ec248a2.tar.bz2 meta-impy-ce28e056c20bf2723f565bbf464b87781ec248a2.tar.xz |
Second Life viewer sources 1.20.2
Diffstat (limited to '')
-rw-r--r-- | linden/indra/newview/llpanelinput.cpp | 30 |
1 files changed, 16 insertions, 14 deletions
diff --git a/linden/indra/newview/llpanelinput.cpp b/linden/indra/newview/llpanelinput.cpp index 7fac7f8..7034b1c 100644 --- a/linden/indra/newview/llpanelinput.cpp +++ b/linden/indra/newview/llpanelinput.cpp | |||
@@ -38,11 +38,12 @@ | |||
38 | #include "llrect.h" | 38 | #include "llrect.h" |
39 | #include "llfontgl.h" | 39 | #include "llfontgl.h" |
40 | #include "message.h" | 40 | #include "message.h" |
41 | #include "llvieweruictrlfactory.h" | 41 | #include "lluictrlfactory.h" |
42 | 42 | ||
43 | // project includes | 43 | // project includes |
44 | #include "llviewerwindow.h" | 44 | #include "llviewerwindow.h" |
45 | #include "llcheckboxctrl.h" | 45 | #include "llcheckboxctrl.h" |
46 | #include "llfloaterjoystick.h" | ||
46 | #include "llradiogroup.h" | 47 | #include "llradiogroup.h" |
47 | #include "llresmgr.h" | 48 | #include "llresmgr.h" |
48 | #include "llspinctrl.h" | 49 | #include "llspinctrl.h" |
@@ -73,24 +74,13 @@ | |||
73 | 74 | ||
74 | LLPanelInput::LLPanelInput() | 75 | LLPanelInput::LLPanelInput() |
75 | { | 76 | { |
76 | gUICtrlFactory->buildPanel(this, "panel_preferences_input.xml"); | 77 | LLUICtrlFactory::getInstance()->buildPanel(this, "panel_preferences_input.xml"); |
77 | } | 78 | } |
78 | 79 | ||
79 | BOOL LLPanelInput::postBuild() | 80 | BOOL LLPanelInput::postBuild() |
80 | { | 81 | { |
81 | requires("Mouse Sensitivity", WIDGET_TYPE_SLIDER_BAR); | 82 | childSetAction("joystic_setup_button", onClickJoystickSetup, (void*)this); |
82 | requires("invert mouse", WIDGET_TYPE_CHECKBOX); | ||
83 | requires("automatic fly", WIDGET_TYPE_CHECKBOX); | ||
84 | requires("dynamic camera", WIDGET_TYPE_SLIDER); | ||
85 | requires("edit camera movement", WIDGET_TYPE_CHECKBOX); | ||
86 | requires("appearance camera movement", WIDGET_TYPE_CHECKBOX); | ||
87 | requires("avfp", WIDGET_TYPE_CHECKBOX); | ||
88 | 83 | ||
89 | if (!checkRequirements()) | ||
90 | { | ||
91 | return FALSE; | ||
92 | } | ||
93 | |||
94 | refresh(); | 84 | refresh(); |
95 | 85 | ||
96 | return TRUE; | 86 | return TRUE; |
@@ -135,3 +125,15 @@ void LLPanelInput::cancel() | |||
135 | gSavedSettings.setBOOL("FirstPersonAvatarVisible", mFirstPersonAvatarVisible); | 125 | gSavedSettings.setBOOL("FirstPersonAvatarVisible", mFirstPersonAvatarVisible); |
136 | } | 126 | } |
137 | 127 | ||
128 | //static | ||
129 | void LLPanelInput::onClickJoystickSetup(void* user_data) | ||
130 | { | ||
131 | LLPanelInput* prefs = (LLPanelInput*)user_data; | ||
132 | LLFloaterJoystick* floaterp = LLFloaterJoystick::showInstance(); | ||
133 | LLFloater* parent_floater = gFloaterView->getParentFloater(prefs); | ||
134 | if (parent_floater) | ||
135 | { | ||
136 | parent_floater->addDependentFloater(floaterp, FALSE); | ||
137 | } | ||
138 | } | ||
139 | |||