0

Let's talk about the problem directly. We are building a real-time chat application like WhatsApp or Facebook where we can send text messages with our own custom emojis. The emojis are sent to the end-user with text as sort code "jemmy [emoji code love] for you" something like this.

And to the server this "jemmy [image code love] for you" message read and parse to know which sort code have used and then attach a corresponding image URL with the text like "jemmy <img src="love.jpeg"> for you" and send to the recipient.

The recipient parses this message with Html.formHtml(message, Image.ImageGatter()) and where the problem actually arises. Html.formHtml(message, Image.ImageGatter()) takes more time to load an image from the message because it downloads the image first from the URL and then inflates it with text.

Note: Every time when we want to add a new emoji we save it into the server.

Now let's come to the point. Let's say we have all of our emojis in our application drawable folder and If we do exactly the same that the server does it will show the emoji with text very first as we loaded it from the drawable.

But when we release our apk to the google play store and after that, we need a new emoji in our app how we can get it into application drawable. For example, in Facebook messenger, we can download a new sticker and can use them afterward.

But my question is how and where facebook download and save the sticker. Same thing I want in my application too. Whenever we upload a new emoji I want to download it as Facebook messenger does.

I hope this is clear to you what I wanted to achieve. So, would you please anyone can give me a walkthrough that can help me to achieve what I wanted to, described above.

Thanks a lot in advance

0 Answers0