0

I have a lot of images in the assets folder of my application that I'd like to display in a dialog popup. How can I go about doing this? I saw a similar question covering how to display the icons, with a pretty solid answer. But in the answer, the icons are pulled from a drawable. So, I suppose I have two options:

I have taken a look at the "Icons in a list dialog" thread but the answer posted uses drawables. I don't have a drawable for every single image because I have over 250 images.

Then I saw the "load drawable from assets" thread, but that doesn't quite get me there either. The "icons in a list dialog" expects a specific r.drawable.drawablename.

This is currently how I display the countries text:

public void onClick(Card card, View view) {
     AlertDialog.Builder builder = new AlertDialog.Builder(FtC_Setup.this);
     builder.setTitle("Standard countries");
     final CharSequence[] items = FtC_Play.allCountries.toArray(new CharSequence[FtC_Play.allCountries.size()]);
     builder.setItems(items, null).show(); 
}
Community
  • 1
  • 1
  • 2
    Possible duplicate of [Is it possible to load a drawable from the assets folder?](http://stackoverflow.com/questions/4884882/is-it-possible-to-load-a-drawable-from-the-assets-folder) – adneal Apr 26 '14 at 02:51
  • I saw that question. But I don't know what to do once it is loaded - how do I display it? – NomNuggetNom Apr 26 '14 at 14:57
  • Also, that is loading a drawable. I am just loading a .gif, which I need to convert and then be able to display. – NomNuggetNom Apr 26 '14 at 15:53

0 Answers0