diff options
author | Brad Payne (Vir Linden) <vir@lindenlab.com> | 2016-03-22 16:19:10 -0400 |
---|---|---|
committer | Brad Payne (Vir Linden) <vir@lindenlab.com> | 2016-03-22 16:19:10 -0400 |
commit | 0879c48d832a69050e6fc6ac67b0d5f95b52e054 (patch) | |
tree | c872ae80e13d12c3a282fd2af2c5005b0edb5e95 /indra/newview/llpreviewscript.cpp | |
parent | cbbe82b8dc08260aa4102214a7c99aeab7915371 (diff) | |
parent | 2afde26d93cc8773f5e84d187844f909347fc1bf (diff) |
merge
Diffstat (limited to 'indra/newview/llpreviewscript.cpp')
-rwxr-xr-x | indra/newview/llpreviewscript.cpp | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/indra/newview/llpreviewscript.cpp b/indra/newview/llpreviewscript.cpp index 67832c5994..33847b7885 100755 --- a/indra/newview/llpreviewscript.cpp +++ b/indra/newview/llpreviewscript.cpp @@ -1961,7 +1961,8 @@ LLLiveLSLEditor::LLLiveLSLEditor(const LLSD& key) : mCloseAfterSave(FALSE), mPendingUploads(0), mIsModifiable(FALSE), - mIsNew(false) + mIsNew(false), + mIsSaving(FALSE) { mFactoryMap["script ed panel"] = LLCallbackMap(LLLiveLSLEditor::createScriptEdPanel, this); } @@ -2002,6 +2003,8 @@ void LLLiveLSLEditor::callbackLSLCompileSucceeded(const LLUUID& task_id, LL_DEBUGS() << "LSL Bytecode saved" << LL_ENDL; mScriptEd->mErrorList->setCommentText(LLTrans::getString("CompileSuccessful")); mScriptEd->mErrorList->setCommentText(LLTrans::getString("SaveComplete")); + getChild<LLCheckBoxCtrl>("running")->set(is_script_running); + mIsSaving = FALSE; closeIfNeeded(); } @@ -2022,6 +2025,7 @@ void LLLiveLSLEditor::callbackLSLCompileFailed(const LLSD& compile_errors) mScriptEd->mErrorList->addElement(row); } mScriptEd->selectFirstError(); + mIsSaving = FALSE; closeIfNeeded(); } @@ -2249,12 +2253,12 @@ void LLLiveLSLEditor::draw() if(object->permAnyOwner()) { runningCheckbox->setLabel(getString("script_running")); - runningCheckbox->setEnabled(TRUE); + runningCheckbox->setEnabled(!mIsSaving); if(object->permAnyOwner()) { runningCheckbox->setLabel(getString("script_running")); - runningCheckbox->setEnabled(TRUE); + runningCheckbox->setEnabled(!mIsSaving); } else { @@ -2387,6 +2391,7 @@ void LLLiveLSLEditor::saveIfNeeded(bool sync /*= true*/) getWindow()->incBusyCount(); mPendingUploads++; BOOL is_running = getChild<LLCheckBoxCtrl>( "running")->get(); + mIsSaving = TRUE; if (!url.empty()) { uploadAssetViaCaps(url, filename, mObjectUUID, mItemUUID, is_running, mScriptEd->getAssociatedExperience()); |