diff options
author | Andrey Kleshchev <andreykproductengine@lindenlab.com> | 2022-09-29 22:38:40 +0300 |
---|---|---|
committer | Andrey Kleshchev <andreykproductengine@lindenlab.com> | 2022-09-29 22:39:32 +0300 |
commit | 9346b45188462056698083f4f83fe8fecbe19bdf (patch) | |
tree | 9d0ac5c1633c27d85ffb9e44d62c6d4f6c1a2a27 /indra/newview/lltexturectrl.cpp | |
parent | 02df55b9b366f3df98fc4b861dffa779c9d0a536 (diff) |
SL-17653 Multi-material file support for local materials
Diffstat (limited to 'indra/newview/lltexturectrl.cpp')
-rw-r--r-- | indra/newview/lltexturectrl.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/indra/newview/lltexturectrl.cpp b/indra/newview/lltexturectrl.cpp index f4649a672b..ff0d74a7c9 100644 --- a/indra/newview/lltexturectrl.cpp +++ b/indra/newview/lltexturectrl.cpp @@ -965,13 +965,16 @@ void LLFloaterTexturePicker::onBtnUpload(void* userdata) if (LLAssetType::AT_MATERIAL == asset_type) { - std::string filename = LLLocalGLTFMaterialMgr::getInstance()->getFilename(tracking_id); + std::string filename; + S32 index; + LLLocalGLTFMaterialMgr::getInstance()->getFilenameAndIndex(tracking_id, filename, index); if (!filename.empty()) { LLMaterialEditor* me = (LLMaterialEditor*)LLFloaterReg::getInstance("material_editor"); if (me) { - me->loadMaterialFromFile(filename); + me->loadMaterialFromFile(filename, index); + me->setFocus(TRUE); } } } |