Skip to content

Commit aa83369

Browse files
committed
Show hashed upgrade message as link to play store.
1 parent 359a98f commit aa83369

File tree

7 files changed

+16
-17
lines changed

7 files changed

+16
-17
lines changed

surespot/src/main/java/com/twofours/surespot/chat/ChatAdapter.java

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,5 @@
11
package com.twofours.surespot.chat;
22

3-
import java.lang.ref.WeakReference;
4-
import java.util.ArrayList;
5-
import java.util.Collections;
6-
import java.util.ListIterator;
7-
83
import android.content.Context;
94
import android.content.SharedPreferences;
105
import android.text.TextUtils;
@@ -29,6 +24,11 @@
2924
import com.twofours.surespot.voice.VoiceController;
3025
import com.twofours.surespot.voice.VoiceMessageDownloader;
3126

27+
import java.lang.ref.WeakReference;
28+
import java.util.ArrayList;
29+
import java.util.Collections;
30+
import java.util.ListIterator;
31+
3232
public class ChatAdapter extends BaseAdapter {
3333
private final static String TAG = "ChatAdapter";
3434
private ArrayList<SurespotMessage> mMessages = new ArrayList<SurespotMessage>();
@@ -335,7 +335,9 @@ public View getView(int position, View convertView, ViewGroup parent) {
335335
}
336336

337337
if (item.isHashed()) {
338-
chatMessageViewHolder.tvText.setText(R.string.decrypt_update);
338+
chatMessageViewHolder.tvText.setAutoLinkMask(0);
339+
UIUtils.setHtml(mContext, chatMessageViewHolder.tvText, R.string.decrypt_update);
340+
339341
chatMessageViewHolder.tvText.setVisibility(View.VISIBLE);
340342

341343
chatMessageViewHolder.voiceView.setVisibility(View.GONE);
@@ -360,7 +362,8 @@ public View getView(int position, View convertView, ViewGroup parent) {
360362
if (item.getPlainData() != null) {
361363
chatMessageViewHolder.tvText.clearAnimation();
362364
chatMessageViewHolder.tvText.setText(item.getPlainData());
363-
} else {
365+
}
366+
else {
364367
chatMessageViewHolder.tvText.setText("");
365368
mMessageDecryptor.decrypt(chatMessageViewHolder.tvText, item);
366369
}

surespot/src/main/res/values-de/strings.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -343,5 +343,5 @@
343343
<string name="notification_message_no_from">%s: Neue Nachricht empfangen.</string>
344344
<string name="notification_invite_no_from">%s: Kontaktanfrage erhalten.</string>
345345
<string name="notification_invite_accept_no_from">%s: Kontaktanfrage akzeptiert.</string>
346-
<string name="decrypt_update">Bitte aktualisieren Sie Surespot zu entschlüsseln.</string>
346+
<string name="decrypt_update"><![CDATA["<a href="market://details?id=com.twofours.surespot">Bitte aktualisieren Sie Surespot aus dem Google Play Store .</a>"]]></string>
347347
</resources>

surespot/src/main/res/values-es/strings.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -343,5 +343,5 @@
343343
<string name="notification_message_no_from">%s: tienes un mensaje nuevo.</string>
344344
<string name="notification_invite_no_from">%s: tienes una invitación nueva.</string>
345345
<string name="notification_invite_accept_no_from">%s: Invitación de contacto aceptada.</string>
346-
<string name="decrypt_update">Por favor, actualice surespot para descifrar.</string>
346+
<string name="decrypt_update"><![CDATA["<a href="market://details?id=com.twofours.surespot">Por favor, actualice surespot de la tienda de Google Play .</a>"]]></string>
347347
</resources>

surespot/src/main/res/values-fr/strings.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -316,6 +316,6 @@
316316
<string name="no_audio_detected">pas d\'audio détecté - impossible d\'envoyer un message vocal</string>
317317
<string name="share_invite_link">part inviter lien</string>
318318
<string name="share_link_help">"Utilisez l'option de menu \"part inviter lien\" de partager un lien par email, sms, twitter, ou d'autres médias sociaux, qui lorsqu'il est cliqué installera surespot / vous invitez un ami à surespot"</string>
319-
<string name="decrypt_update">S\'il vous plaît mettre à jour surespot à décrypter.</string>
319+
<string name="decrypt_update"><![CDATA["<a href="market://details?id=com.twofours.surespot">S'il vous plaît mettre à jour surespot du magasin de jeu Google .</a>"]]></string>
320320

321321
</resources>

surespot/src/main/res/values-it/strings.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -343,5 +343,5 @@
343343
<string name="notification_message_no_from">%s: Nuovo messaggio ricevuto.</string>
344344
<string name="notification_invite_no_from">%s: Nuovo invito ricevuto.</string>
345345
<string name="notification_invite_accept_no_from">%s: Invito accettato.</string>
346-
<string name="decrypt_update">Si prega di aggiornare SureSpot per decifrare.</string>
346+
<string name="decrypt_update"><![CDATA["<a href="market://details?id=com.twofours.surespot">Si prega di aggiornare SureSpot dal Google Play Store .</a>"]]></string>
347347
</resources>

surespot/src/main/res/values/strings.xml

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -359,7 +359,5 @@
359359
<string name="notification_message_no_from">%s: New message received.</string>
360360
<string name="notification_invite_no_from">%s: Friend invite received.</string>
361361
<string name="notification_invite_accept_no_from">%s: Friend invite accepted.</string>
362-
<string name="whats_new_57_message">New features!\n\nSave password in keychain.\n\nFriend aliases (long press on friend name on home tab).\n\nImproved reconnect handling.\n\nThank you for funding this project through your donations!</string>
363-
<string name="whats_new_57_title">Version 58</string>
364-
<string name="decrypt_update">Please update surespot to decrypt.</string>
362+
<string name="decrypt_update"><![CDATA["<a href="market://details?id=com.twofours.surespot">Please update surespot from the play store.</a>"]]></string>
365363
</resources>

surespot/surespot.iml

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,6 @@
7474
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/exploded-aar/com.android.support/support-v4/22.2.0/jars" />
7575
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/exploded-aar/com.google.android.gms/play-services-base/7.8.0/jars" />
7676
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/exploded-aar/com.google.android.gms/play-services-drive/7.8.0/jars" />
77-
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/exploded-aar/com.google.android.gms/play-services-gcm/7.8.0/jars" />
7877
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/incremental" />
7978
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/jacoco" />
8079
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/javaResources" />
@@ -95,13 +94,12 @@
9594
<orderEntry type="library" exported="" name="google-api-client-android-1.17.0-rc" level="project" />
9695
<orderEntry type="library" exported="" name="google-http-client-1.19.0" level="project" />
9796
<orderEntry type="library" exported="" name="google-http-client-android-1.17.0-rc" level="project" />
98-
<orderEntry type="library" exported="" name="play-services-gcm-7.8.0" level="project" />
9997
<orderEntry type="library" exported="" name="guava-18.0" level="project" />
10098
<orderEntry type="library" exported="" name="google-api-services-drive-v2-rev103-1.17.0-rc" level="project" />
10199
<orderEntry type="library" exported="" name="gson-2.3" level="project" />
102100
<orderEntry type="library" exported="" name="support-annotations-22.2.0" level="project" />
103-
<orderEntry type="library" exported="" name="support-v4-22.2.0" level="project" />
104101
<orderEntry type="library" exported="" name="play-services-drive-7.8.0" level="project" />
102+
<orderEntry type="library" exported="" name="support-v4-22.2.0" level="project" />
105103
<orderEntry type="library" exported="" name="google-http-client-gson-1.19.0" level="project" />
106104
<orderEntry type="library" exported="" name="google-oauth-client-1.17.0-rc" level="project" />
107105
<orderEntry type="library" exported="" name="gcm" level="project" />

0 commit comments

Comments
 (0)