summaryrefslogtreecommitdiff
path: root/indra/newview/llpanelsnapshotinventory.cpp
diff options
context:
space:
mode:
authorNat Goodspeed <nat@lindenlab.com>2024-09-05 11:00:11 -0400
committerNat Goodspeed <nat@lindenlab.com>2024-09-05 11:00:11 -0400
commit000a23ba0534fdf9bfc4a1b051b7cee0adceef3e (patch)
tree776fe10c7aaf76371a889f79c48c3c9405fd5a4e /indra/newview/llpanelsnapshotinventory.cpp
parent7ac4c3b56e5246fceaa73e7c9c665d3c04827d6c (diff)
parentbacf9cfeab90bd1ffad827fa3c34ced985c768a2 (diff)
Merge branch 'develop' into release/luau-scripting
Diffstat (limited to 'indra/newview/llpanelsnapshotinventory.cpp')
-rw-r--r--indra/newview/llpanelsnapshotinventory.cpp14
1 files changed, 13 insertions, 1 deletions
diff --git a/indra/newview/llpanelsnapshotinventory.cpp b/indra/newview/llpanelsnapshotinventory.cpp
index 05d3c88c29..5a7dd92b98 100644
--- a/indra/newview/llpanelsnapshotinventory.cpp
+++ b/indra/newview/llpanelsnapshotinventory.cpp
@@ -155,7 +155,19 @@ void LLPanelSnapshotInventory::onResolutionCommit(LLUICtrl* ctrl)
void LLPanelSnapshotInventoryBase::onSend()
{
- S32 expected_upload_cost = LLAgentBenefitsMgr::current().getTextureUploadCost();
+ S32 w = 0;
+ S32 h = 0;
+
+ if( mSnapshotFloater )
+ {
+ LLSnapshotLivePreview* preview = mSnapshotFloater->getPreviewView();
+ if( preview )
+ {
+ preview->getSize(w, h);
+ }
+ }
+
+ S32 expected_upload_cost = LLAgentBenefitsMgr::current().getTextureUploadCost(w, h);
if (can_afford_transaction(expected_upload_cost))
{
if (mSnapshotFloater)