|
|
|
@ -59,6 +59,7 @@ import org.thoughtcrime.securesms.util.DynamicLanguage;
|
|
|
|
|
import org.thoughtcrime.securesms.util.ExpirationUtil;
|
|
|
|
|
import org.thoughtcrime.securesms.util.Util;
|
|
|
|
|
import org.whispersystems.libsignal.util.guava.Optional;
|
|
|
|
|
import org.whispersystems.signalservice.loki.api.opengroups.PublicChat;
|
|
|
|
|
|
|
|
|
|
import java.lang.ref.WeakReference;
|
|
|
|
|
import java.sql.Date;
|
|
|
|
@ -97,6 +98,7 @@ public class MessageDetailsActivity extends PassphraseRequiredActionBarActivity
|
|
|
|
|
private View receivedContainer;
|
|
|
|
|
private TextView transport;
|
|
|
|
|
private TextView toFrom;
|
|
|
|
|
private View separator;
|
|
|
|
|
private ListView recipientsList;
|
|
|
|
|
private LayoutInflater inflater;
|
|
|
|
|
|
|
|
|
@ -177,6 +179,7 @@ public class MessageDetailsActivity extends PassphraseRequiredActionBarActivity
|
|
|
|
|
receivedDate = header.findViewById(R.id.received_time);
|
|
|
|
|
transport = header.findViewById(R.id.transport);
|
|
|
|
|
toFrom = header.findViewById(R.id.tofrom);
|
|
|
|
|
separator = header.findViewById(R.id.separator);
|
|
|
|
|
expiresContainer = header.findViewById(R.id.expires_container);
|
|
|
|
|
expiresInText = header.findViewById(R.id.expires_in);
|
|
|
|
|
recipientsList.setHeaderDividersEnabled(false);
|
|
|
|
@ -262,6 +265,12 @@ public class MessageDetailsActivity extends PassphraseRequiredActionBarActivity
|
|
|
|
|
toFromRes = R.string.message_details_header__from;
|
|
|
|
|
}
|
|
|
|
|
toFrom.setText(toFromRes);
|
|
|
|
|
long threadID = messageRecord.getThreadId();
|
|
|
|
|
PublicChat openGroup = DatabaseFactory.getLokiThreadDatabase(this).getPublicChat(threadID);
|
|
|
|
|
if (openGroup != null && messageRecord.isOutgoing()) {
|
|
|
|
|
toFrom.setVisibility(View.GONE);
|
|
|
|
|
separator.setVisibility(View.GONE);
|
|
|
|
|
}
|
|
|
|
|
conversationItem.bind(messageRecord, Optional.absent(), Optional.absent(), glideRequests, dynamicLanguage.getCurrentLocale(), new HashSet<>(), recipient, null, false);
|
|
|
|
|
recipientsList.setAdapter(new MessageDetailsRecipientAdapter(this, glideRequests, messageRecord, recipients, isPushGroup));
|
|
|
|
|
}
|
|
|
|
|