From 4e6eaa2849595f6a92f5e36d9fcd4e456281e244 Mon Sep 17 00:00:00 2001 From: Liru Date: Wed, 1 Nov 2017 18:15:47 -0400 Subject: [PATCH] New abuse reports upload the screenshot whenever possible --- indra/newview/llfloaterreporter.cpp | 30 ++++++----------------------- 1 file changed, 6 insertions(+), 24 deletions(-) diff --git a/indra/newview/llfloaterreporter.cpp b/indra/newview/llfloaterreporter.cpp index ca0dd49d8..0b175dcfa 100644 --- a/indra/newview/llfloaterreporter.cpp +++ b/indra/newview/llfloaterreporter.cpp @@ -221,7 +221,6 @@ void LLFloaterReporter::draw() void LLFloaterReporter::enableControls(BOOL enable) { getChildView("category_combo")->setEnabled(enable); - getChildView("screen_check")->setEnabled(enable); getChildView("screenshot")->setEnabled(false); getChildView("pick_btn")->setEnabled(enable); getChildView("summary_edit")->setEnabled(enable); @@ -389,19 +388,10 @@ void LLFloaterReporter::onClickSend(void *userdata) } else { - if(self->getChild("screen_check")->getValue()) - { - self->getChildView("send_btn")->setEnabled(FALSE); - self->getChildView("cancel_btn")->setEnabled(FALSE); - // the callback from uploading the image calls sendReportViaLegacy() - self->uploadImage(); - } - else - { - self->sendReportViaLegacy(self->gatherReport()); - LLUploadDialog::modalUploadFinished(); - self->close(); - } + self->getChildView("send_btn")->setEnabled(FALSE); + self->getChildView("cancel_btn")->setEnabled(FALSE); + // the callback from uploading the image calls sendReportViaLegacy() + self->uploadImage(); } } } @@ -646,20 +636,12 @@ LLSD LLFloaterReporter::gatherReport() gGLManager.mGLRenderer.c_str(), gGLManager.mDriverVersionVendorString.c_str()); - // only send a screenshot ID if we're asked to and the email is - // going to LL - Estate Owners cannot see the screenshot asset - LLUUID screenshot_id = LLUUID::null; - if (getChild("screen_check")->getValue()) - { - screenshot_id = getChild("screenshot")->getValue(); - } - LLSD report = LLSD::emptyMap(); report["report-type"] = (U8) mReportType; report["category"] = getChild("category_combo")->getValue(); report["position"] = mPosition.getValue(); report["check-flags"] = (U8)0; // this is not used - report["screenshot-id"] = screenshot_id; + report["screenshot-id"] = getChild("screenshot")->getValue(); report["object-id"] = mObjectID; report["abuser-id"] = mAbuserID; report["abuse-region-name"] = ""; @@ -743,7 +725,7 @@ private: void LLFloaterReporter::sendReportViaCaps(std::string url, std::string sshot_url, const LLSD& report) { - if(getChild("screen_check")->getValue().asBoolean() && !sshot_url.empty()) + if(!sshot_url.empty()) { // try to upload screenshot LLHTTPClient::post(sshot_url, report, new LLUserReportScreenshotResponder(report,