Reputation: 1555
I want to use a Dialog to allow the user to scan its device for all the files with a certain extension and import some of them.
To do that, I plan to show a dialog, which will have the following behaviour:
I'm wondering what's the best strategy to implement this?
I can think of two possibilites:
View.VISIBLE
and View.GONE
). I prefer the other option because here I will inflate some view that won't be shown.Upvotes: 0
Views: 1292
Reputation: 3561
Display a ListView into your DialogFragment and use an emptyView for the progress. Implement a Loader to scan for your Files. When the loader finished the work simply use an Adapter for your ListView and the Empty View will disappear automatically.
Upvotes: 2