diff options
Diffstat (limited to 'linden/indra/newview/llfloaterpreference.cpp')
-rw-r--r-- | linden/indra/newview/llfloaterpreference.cpp | 42 |
1 files changed, 41 insertions, 1 deletions
diff --git a/linden/indra/newview/llfloaterpreference.cpp b/linden/indra/newview/llfloaterpreference.cpp index f061018..100ae0c 100644 --- a/linden/indra/newview/llfloaterpreference.cpp +++ b/linden/indra/newview/llfloaterpreference.cpp | |||
@@ -54,6 +54,7 @@ | |||
54 | #include "llpaneldebug.h" | 54 | #include "llpaneldebug.h" |
55 | #include "llpanelgeneral.h" | 55 | #include "llpanelgeneral.h" |
56 | #include "llpanelinput.h" | 56 | #include "llpanelinput.h" |
57 | #include "llpanelLCD.h" | ||
57 | #include "llpanelmsgs.h" | 58 | #include "llpanelmsgs.h" |
58 | #include "llpanelweb.h" | 59 | #include "llpanelweb.h" |
59 | #include "llprefschat.h" | 60 | #include "llprefschat.h" |
@@ -80,6 +81,14 @@ const S32 PREF_FLOATER_MIN_HEIGHT = 2 * SCROLLBAR_SIZE + 2 * LLPANEL_BORDER_WIDT | |||
80 | 81 | ||
81 | LLFloaterPreference* LLFloaterPreference::sInstance = NULL; | 82 | LLFloaterPreference* LLFloaterPreference::sInstance = NULL; |
82 | 83 | ||
84 | #if LL_WINDOWS | ||
85 | // for Logitech LCD keyboards / speakers | ||
86 | #ifndef LL_LOGITECH_LCD_H | ||
87 | #include "lllogitechlcd.h" | ||
88 | #endif | ||
89 | extern llLCD *gLcdScreen; | ||
90 | #endif | ||
91 | |||
83 | // Must be done at run time, not compile time. JC | 92 | // Must be done at run time, not compile time. JC |
84 | S32 pref_min_width() | 93 | S32 pref_min_width() |
85 | { | 94 | { |
@@ -108,7 +117,8 @@ LLPreferenceCore::LLPreferenceCore(LLTabContainerCommon* tab_container, LLButton | |||
108 | mDisplayPanel(NULL), | 117 | mDisplayPanel(NULL), |
109 | mDisplayPanel2(NULL), | 118 | mDisplayPanel2(NULL), |
110 | mAudioPanel(NULL), | 119 | mAudioPanel(NULL), |
111 | mMsgPanel(NULL) | 120 | mMsgPanel(NULL), |
121 | mLCDPanel(NULL) | ||
112 | { | 122 | { |
113 | mGeneralPanel = new LLPanelGeneral(); | 123 | mGeneralPanel = new LLPanelGeneral(); |
114 | mTabContainer->addTabPanel(mGeneralPanel, mGeneralPanel->getLabel(), FALSE, onTabChanged, mTabContainer); | 124 | mTabContainer->addTabPanel(mGeneralPanel, mGeneralPanel->getLabel(), FALSE, onTabChanged, mTabContainer); |
@@ -156,6 +166,20 @@ LLPreferenceCore::LLPreferenceCore(LLTabContainerCommon* tab_container, LLButton | |||
156 | mTabContainer->addTabPanel(mPrefsIM->getPanel(), mPrefsIM->getPanel()->getLabel(), FALSE, onTabChanged, mTabContainer); | 166 | mTabContainer->addTabPanel(mPrefsIM->getPanel(), mPrefsIM->getPanel()->getLabel(), FALSE, onTabChanged, mTabContainer); |
157 | mPrefsIM->getPanel()->setDefaultBtn(default_btn); | 167 | mPrefsIM->getPanel()->setDefaultBtn(default_btn); |
158 | 168 | ||
169 | #if LL_WINDOWS && LL_LCD_COMPILE | ||
170 | |||
171 | // only add this option if we actually have a logitech keyboard / speaker set | ||
172 | if (gLcdScreen->Enabled()) | ||
173 | { | ||
174 | mLCDPanel = new LLPanelLCD(); | ||
175 | mTabContainer->addTabPanel(mLCDPanel, mLCDPanel->getLabel(), FALSE, onTabChanged, mTabContainer); | ||
176 | mLCDPanel->setDefaultBtn(default_btn); | ||
177 | } | ||
178 | |||
179 | #else | ||
180 | mLCDPanel = NULL; | ||
181 | #endif | ||
182 | |||
159 | mMsgPanel = new LLPanelMsgs(); | 183 | mMsgPanel = new LLPanelMsgs(); |
160 | mTabContainer->addTabPanel(mMsgPanel, mMsgPanel->getLabel(), FALSE, onTabChanged, mTabContainer); | 184 | mTabContainer->addTabPanel(mMsgPanel, mMsgPanel->getLabel(), FALSE, onTabChanged, mTabContainer); |
161 | mMsgPanel->setDefaultBtn(default_btn); | 185 | mMsgPanel->setDefaultBtn(default_btn); |
@@ -240,6 +264,14 @@ void LLPreferenceCore::apply() | |||
240 | #if LL_LIBXUL_ENABLED | 264 | #if LL_LIBXUL_ENABLED |
241 | mWebPanel->apply(); | 265 | mWebPanel->apply(); |
242 | #endif | 266 | #endif |
267 | #if LL_WINDOWS && LL_LCD_COMPILE | ||
268 | // only add this option if we actually have a logitech keyboard / speaker set | ||
269 | if (gLcdScreen->Enabled()) | ||
270 | { | ||
271 | mLCDPanel->apply(); | ||
272 | } | ||
273 | #endif | ||
274 | // mWebPanel->apply(); | ||
243 | } | 275 | } |
244 | 276 | ||
245 | 277 | ||
@@ -259,6 +291,14 @@ void LLPreferenceCore::cancel() | |||
259 | #if LL_LIBXUL_ENABLED | 291 | #if LL_LIBXUL_ENABLED |
260 | mWebPanel->cancel(); | 292 | mWebPanel->cancel(); |
261 | #endif | 293 | #endif |
294 | #if LL_WINDOWS && LL_LCD_COMPILE | ||
295 | // only add this option if we actually have a logitech keyboard / speaker set | ||
296 | if (gLcdScreen->Enabled()) | ||
297 | { | ||
298 | mLCDPanel->cancel(); | ||
299 | } | ||
300 | #endif | ||
301 | // mWebPanel->cancel(); | ||
262 | } | 302 | } |
263 | 303 | ||
264 | // static | 304 | // static |