diff options
Diffstat (limited to 'indra/newview')
-rwxr-xr-x | indra/newview/llfloatermodelpreview.cpp | 18 | ||||
-rwxr-xr-x[-rw-r--r--] | indra/newview/llfloatermodelpreview.h | 2 | ||||
-rwxr-xr-x[-rw-r--r--] | indra/newview/skins/default/xui/en/floater_model_preview.xml | 2 |
3 files changed, 17 insertions, 5 deletions
diff --git a/indra/newview/llfloatermodelpreview.cpp b/indra/newview/llfloatermodelpreview.cpp index 40c892f06a..ff687386de 100755 --- a/indra/newview/llfloatermodelpreview.cpp +++ b/indra/newview/llfloatermodelpreview.cpp @@ -279,11 +279,6 @@ BOOL LLFloaterModelPreview::postBuild() return FALSE; } - - - - - childSetAction("lod_browse", onBrowseLOD, this); childSetCommitCallback("cancel_btn", onCancel, this); @@ -306,6 +301,8 @@ BOOL LLFloaterModelPreview::postBuild() childSetAction("ok_btn", onUpload, this); childDisable("ok_btn"); + childSetAction("reset_btn", onReset, this); + childSetAction("clear_materials", onClearMaterials, this); childSetCommitCallback("preview_lod_combo", onPreviewLODCommit, this); @@ -4636,6 +4633,17 @@ void LLFloaterModelPreview::onBrowseLOD(void* data) } //static +void LLFloaterModelPreview::onReset(void* user_data) +{ + assert_main_thread(); + + LLFloaterModelPreview* fmp = (LLFloaterModelPreview*) user_data; + LLModelPreview* mp = fmp->mModelPreview; + std::string filename = mp->mLODFile[3]; + mp->loadModel(filename,3); +} + +//static void LLFloaterModelPreview::onUpload(void* user_data) { assert_main_thread(); diff --git a/indra/newview/llfloatermodelpreview.h b/indra/newview/llfloatermodelpreview.h index dabe3c613d..dc6a33d0ab 100644..100755 --- a/indra/newview/llfloatermodelpreview.h +++ b/indra/newview/llfloatermodelpreview.h @@ -162,6 +162,8 @@ public: static void onBrowseLOD(void* data); + static void onReset(void* data); + static void onUpload(void* data); static void onClearMaterials(void* data); diff --git a/indra/newview/skins/default/xui/en/floater_model_preview.xml b/indra/newview/skins/default/xui/en/floater_model_preview.xml index 7be6165a0d..d08c3e7078 100644..100755 --- a/indra/newview/skins/default/xui/en/floater_model_preview.xml +++ b/indra/newview/skins/default/xui/en/floater_model_preview.xml @@ -86,6 +86,8 @@ <text left="10" bottom="540" width="290" height="15" follows="bottom|left|right" name="status">[STATUS]</text> + <button bottom="540" left="300" follows="bottom|right" height="20" label="Defaults" + width="80" name="reset_btn" tool_tip="Reset to defaults"/> <button bottom="540" left="430" follows="bottom|right" height="20" label="Upload" width="80" name="ok_btn" tool_tip="Upload to simulator"/> <button left_pad="10" follows="right|bottom" height="20" width="80" label="Cancel" name="cancel_btn"/> |