summaryrefslogtreecommitdiff
path: root/indra/newview/llfloatertwitter.cpp
diff options
context:
space:
mode:
authorCho <cho@lindenlab.com>2013-11-08 00:33:14 +0000
committerCho <cho@lindenlab.com>2013-11-08 00:33:14 +0000
commit15434d53ea1f1bca37b7b9d6d569b3cb61d09bbe (patch)
treef271bcde249573bb5711a0e23655f3fff63fe898 /indra/newview/llfloatertwitter.cpp
parent389ddfd5add78998aaadb171593b5b036d2dbee0 (diff)
added SLShare links to snapshot floater for ACME-1167
Diffstat (limited to 'indra/newview/llfloatertwitter.cpp')
-rw-r--r--indra/newview/llfloatertwitter.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/indra/newview/llfloatertwitter.cpp b/indra/newview/llfloatertwitter.cpp
index 5a2402cdd6..1324bd5fd8 100644
--- a/indra/newview/llfloatertwitter.cpp
+++ b/indra/newview/llfloatertwitter.cpp
@@ -109,6 +109,8 @@ void LLTwitterPhotoPanel::draw()
mRefreshBtn->setEnabled(no_ongoing_connection && mPhotoCheckbox->getValue().asBoolean());
mPhotoCheckbox->setEnabled(no_ongoing_connection);
+ bool add_photo = mPhotoCheckbox->getValue().asBoolean();
+
// Display the preview if one is available
if (previewp && previewp->getThumbnailImage())
{
@@ -131,7 +133,7 @@ void LLTwitterPhotoPanel::draw()
gGL.matrixMode(LLRender::MM_MODELVIEW);
// Apply floater transparency to the texture unless the floater is focused.
- F32 alpha = (mPhotoCheckbox->getValue().asBoolean() ? (getTransparencyType() == TT_ACTIVE ? 1.0f : getCurrentTransparency()) : 0.5f);
+ F32 alpha = (add_photo ? (getTransparencyType() == TT_ACTIVE ? 1.0f : getCurrentTransparency()) : 0.5f);
LLColor4 color = LLColor4::white;
gl_draw_scaled_image(offset_x, offset_y,
thumbnail_w, thumbnail_h,
@@ -144,7 +146,7 @@ void LLTwitterPhotoPanel::draw()
mWorkingLabel->setVisible(!(previewp && previewp->getSnapshotUpToDate()));
// Enable Post if we have a preview to send and no on going connection being processed
- mPostButton->setEnabled(no_ongoing_connection && (previewp && previewp->getSnapshotUpToDate()));
+ mPostButton->setEnabled(no_ongoing_connection && ((add_photo && previewp && previewp->getSnapshotUpToDate()) || !mStatusTextBox->getValue().asString().empty()));
// Draw the rest of the panel on top of it
LLPanel::draw();