diff options
author | Nat Goodspeed <nat@lindenlab.com> | 2024-09-05 11:00:11 -0400 |
---|---|---|
committer | Nat Goodspeed <nat@lindenlab.com> | 2024-09-05 11:00:11 -0400 |
commit | 000a23ba0534fdf9bfc4a1b051b7cee0adceef3e (patch) | |
tree | 776fe10c7aaf76371a889f79c48c3c9405fd5a4e /indra/newview/llpanelsnapshotinventory.cpp | |
parent | 7ac4c3b56e5246fceaa73e7c9c665d3c04827d6c (diff) | |
parent | bacf9cfeab90bd1ffad827fa3c34ced985c768a2 (diff) |
Merge branch 'develop' into release/luau-scripting
Diffstat (limited to 'indra/newview/llpanelsnapshotinventory.cpp')
-rw-r--r-- | indra/newview/llpanelsnapshotinventory.cpp | 14 |
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) |