Skip to content
This repository was archived by the owner on Jul 25, 2024. It is now read-only.

Commit 7041b4d

Browse files
committed
Removed .png extension from autocomplete emoji list.
Fix:#445
1 parent a7c1a44 commit 7041b4d

File tree

3 files changed

+5
-3
lines changed

3 files changed

+5
-3
lines changed

app/src/main/java/com/zulip/android/ZulipApp.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -351,6 +351,8 @@ private void setupEmoji() {
351351
new Callable<Void>() {
352352
public Void call() throws Exception {
353353
for (String newEmoji : emojis) {
354+
//currently emojis are in png format
355+
newEmoji = newEmoji.replace(".png", "");
354356
dao.create(new Emoji(newEmoji));
355357
}
356358
return null;

app/src/main/java/com/zulip/android/activities/ZulipActivity.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -489,8 +489,8 @@ public boolean setViewValue(View view, Cursor cursor, int columnIndex) {
489489
view.setVisibility(View.GONE);
490490
} else {
491491
try {
492-
Drawable drawable = Drawable.createFromStream(getApplicationContext().getAssets().open("emoji/" + name),
493-
"emoji/" + name);
492+
Drawable drawable = Drawable.createFromStream(getApplicationContext().getAssets().open("emoji/" + name + ".png"),
493+
"emoji/" + name + ".png");
494494
((ImageView) view).setImageDrawable(drawable);
495495
} catch (Exception e) {
496496
ZLog.logException(e);

app/src/main/java/com/zulip/android/database/DatabaseHelper.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ public class DatabaseHelper extends OrmLiteSqliteOpenHelper {
3030
private static final String DATABASE_NAME = "zulip-%s.db";
3131
// any time you make changes to your database objects, you may have to
3232
// increase the database version
33-
private static final int DATABASE_VERSION = 9;
33+
private static final int DATABASE_VERSION = 10;
3434

3535
public DatabaseHelper(ZulipApp app, String email) {
3636
super(app, String.format(DATABASE_NAME, MD5Util.md5Hex(email)), null,

0 commit comments

Comments
 (0)