diff options
Diffstat (limited to 'indra')
-rw-r--r-- | indra/newview/llfloatersettingsdebug.cpp | 14 | ||||
-rw-r--r-- | indra/newview/llfloatersettingsdebug.h | 1 | ||||
-rw-r--r-- | indra/newview/skins/default/xui/en/floater_settings_debug.xml | 13 |
3 files changed, 27 insertions, 1 deletions
diff --git a/indra/newview/llfloatersettingsdebug.cpp b/indra/newview/llfloatersettingsdebug.cpp index 1c10db4e0d..a494b715a2 100644 --- a/indra/newview/llfloatersettingsdebug.cpp +++ b/indra/newview/llfloatersettingsdebug.cpp @@ -35,6 +35,7 @@ #include "llviewercontrol.h" #include "lltexteditor.h" #include "llclipboard.h" +#include "llsdutil.h" LLFloaterSettingsDebug::LLFloaterSettingsDebug(const LLSD& key) @@ -54,6 +55,7 @@ BOOL LLFloaterSettingsDebug::postBuild() mComment = getChild<LLTextEditor>("comment_text"); mSettingName = getChild<LLTextBox>("setting_name_txt"); + mLLSDVal = getChild<LLTextEditor>("llsd_text"); mCopyBtn = getChild<LLButton>("copy_btn"); getChild<LLFilterEditor>("filter_input")->setCommitCallback(boost::bind(&LLFloaterSettingsDebug::setSearchFilter, this, _2)); @@ -472,6 +474,17 @@ void LLFloaterSettingsDebug::updateControl(LLControlVariable* controlp) color_swatch->setValue(sd); break; } + case TYPE_LLSD: + { + mLLSDVal->setVisible(true); + std::string new_text = ll_pretty_print_sd(sd); + // Don't setText if not nessesary, it will reset scroll + if (mLLSDVal->getText() != new_text) + { + mLLSDVal->setText(new_text); + } + break; + } default: mComment->setText(std::string("unknown")); break; @@ -638,6 +651,7 @@ void LLFloaterSettingsDebug::hideUIControls() getChildView("val_text")->setVisible(false); getChildView("default_btn")->setVisible(false); getChildView("boolean_combo")->setVisible(false); + mLLSDVal->setVisible(false); mSettingName->setVisible(false); mCopyBtn->setVisible(false); mComment->setVisible(false); diff --git a/indra/newview/llfloatersettingsdebug.h b/indra/newview/llfloatersettingsdebug.h index e52d5ac863..20aa9bb159 100644 --- a/indra/newview/llfloatersettingsdebug.h +++ b/indra/newview/llfloatersettingsdebug.h @@ -69,6 +69,7 @@ private: protected: class LLTextEditor* mComment; + LLTextEditor* mLLSDVal; LLTextBox* mSettingName; LLButton* mCopyBtn; diff --git a/indra/newview/skins/default/xui/en/floater_settings_debug.xml b/indra/newview/skins/default/xui/en/floater_settings_debug.xml index 6fd8f2b255..0b8190df7e 100644 --- a/indra/newview/skins/default/xui/en/floater_settings_debug.xml +++ b/indra/newview/skins/default/xui/en/floater_settings_debug.xml @@ -69,7 +69,7 @@ visible="false" use_ellipses="true" text_color="White" - width="240"> + width="225"> Debug setting name </text> <text_editor @@ -212,4 +212,15 @@ name="hide_default" width="330"> </check_box> + <text_editor + read_only="true" + visible="false" + height="115" + layout="topleft" + name="llsd_text" + follows="left|top" + width="240" + left="320" + top="180" + word_wrap="true" /> </floater> |