summaryrefslogtreecommitdiff
path: root/indra/newview
diff options
context:
space:
mode:
authorBrad Payne (Vir Linden) <vir@lindenlab.com>2011-06-29 15:14:49 -0400
committerBrad Payne (Vir Linden) <vir@lindenlab.com>2011-06-29 15:14:49 -0400
commit0c05ea2740b63c824fba2bab37f67ca2188f0d07 (patch)
treeafa5540d0c00b4b10b3262caf7fe0c200722c019 /indra/newview
parent31df1e93192f2fbdfdda552c7b04d76f94b9f068 (diff)
Fixes for upload permission checking problems
Diffstat (limited to 'indra/newview')
-rwxr-xr-x[-rw-r--r--]indra/newview/llfloatermodelpreview.cpp10
-rw-r--r--indra/newview/llfloatermodeluploadbase.cpp2
2 files changed, 9 insertions, 3 deletions
diff --git a/indra/newview/llfloatermodelpreview.cpp b/indra/newview/llfloatermodelpreview.cpp
index ea85dc0052..00cc81c5d6 100644..100755
--- a/indra/newview/llfloatermodelpreview.cpp
+++ b/indra/newview/llfloatermodelpreview.cpp
@@ -5489,14 +5489,18 @@ void LLFloaterModelPreview::DecompRequest::completed()
}
}
+void dump_llsd_to_file(const LLSD& content, std::string filename);
+
void LLFloaterModelPreview::onPermReceived(const LLSD& result)
{
+ dump_llsd_to_file(result,"perm_received.xml");
std::string upload_status = result["mesh_upload_status"].asString();
- mHasUploadPerm = "valid" == upload_status;
+ // BAP HACK: handle "" for case that MeshUploadFlag cap is broken.
+ mHasUploadPerm = (("" == upload_status) || ("valid" == upload_status));
mUploadBtn->setEnabled(mHasUploadPerm);
- getChild<LLTextBox>("warning_title")->setVisible(mHasUploadPerm);
- getChild<LLTextBox>("warning_message")->setVisible(mHasUploadPerm);
+ getChild<LLTextBox>("warning_title")->setVisible(!mHasUploadPerm);
+ getChild<LLTextBox>("warning_message")->setVisible(!mHasUploadPerm);
}
void LLFloaterModelPreview::setPermErrorStatus(U32 status, const std::string& reason)
diff --git a/indra/newview/llfloatermodeluploadbase.cpp b/indra/newview/llfloatermodeluploadbase.cpp
index 56c6447792..6d3800bfa4 100644
--- a/indra/newview/llfloatermodeluploadbase.cpp
+++ b/indra/newview/llfloatermodeluploadbase.cpp
@@ -52,5 +52,7 @@ void LLFloaterModelUploadBase::requestAgentUploadPermissions()
LLSD args;
args["CAPABILITY"] = capability;
LLNotificationsUtil::add("RegionCapabilityRequestError", args);
+ // BAP HACK avoid being blocked by broken server side stuff
+ mHasUploadPerm = true;
}
}