summaryrefslogtreecommitdiff
path: root/indra/newview/llfloatersnapshot.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/llfloatersnapshot.cpp')
-rw-r--r--indra/newview/llfloatersnapshot.cpp15
1 files changed, 10 insertions, 5 deletions
diff --git a/indra/newview/llfloatersnapshot.cpp b/indra/newview/llfloatersnapshot.cpp
index d55272c558..0931f77281 100644
--- a/indra/newview/llfloatersnapshot.cpp
+++ b/indra/newview/llfloatersnapshot.cpp
@@ -1004,6 +1004,7 @@ void LLSnapshotLivePreview::saveTexture()
LLFloaterPerms::getEveryonePerms(),
"Snapshot : " + pos_string,
callback, expected_upload_cost, userdata);
+ gViewerWindow->playSnapshotAnimAndSound();
}
else
{
@@ -1025,6 +1026,10 @@ BOOL LLSnapshotLivePreview::saveLocal()
mDataSize = 0;
updateSnapshot(FALSE, FALSE);
+ if(success)
+ {
+ gViewerWindow->playSnapshotAnimAndSound();
+ }
return success;
}
@@ -1044,6 +1049,8 @@ void LLSnapshotLivePreview::saveWeb()
LLLandmarkActions::getRegionNameAndCoordsFromPosGlobal(gAgentCamera.getCameraPositionGlobal(),
boost::bind(&LLSnapshotLivePreview::regionNameCallback, this, jpg, metadata, _1, _2, _3, _4));
+
+ gViewerWindow->playSnapshotAnimAndSound();
}
void LLSnapshotLivePreview::regionNameCallback(LLImageJPEG* snapshot, LLSD& metadata, const std::string& name, S32 x, S32 y, S32 z)
@@ -1533,8 +1540,6 @@ void LLFloaterSnapshot::Impl::onClickNewSnapshot(void* data)
if (previewp && view)
{
previewp->updateSnapshot(TRUE);
-
- gViewerWindow->playSnapshotAnimAndSound();
}
}
@@ -2184,9 +2189,11 @@ void LLFloaterSnapshot::draw()
S32 offset_y = thumbnail_rect.mBottom + (thumbnail_rect.getHeight() - previewp->getThumbnailHeight()) / 2 ;
glMatrixMode(GL_MODELVIEW);
+ // Apply floater transparency to the texture unless the floater is focused.
+ F32 alpha = getTransparencyType() == TT_ACTIVE ? 1.0f : getCurrentTransparency();
gl_draw_scaled_image(offset_x, offset_y,
previewp->getThumbnailWidth(), previewp->getThumbnailHeight(),
- previewp->getThumbnailImage(), LLColor4::white);
+ previewp->getThumbnailImage(), LLColor4::white % alpha);
previewp->drawPreviewRect(offset_x, offset_y) ;
}
@@ -2204,8 +2211,6 @@ void LLFloaterSnapshot::onOpen(const LLSD& key)
gSnapshotFloaterView->setEnabled(TRUE);
gSnapshotFloaterView->setVisible(TRUE);
gSnapshotFloaterView->adjustToFitScreen(this, FALSE);
-
- gViewerWindow->playSnapshotAnimAndSound();
}
void LLFloaterSnapshot::onClose(bool app_quitting)