Skip to content

Instantly share code, notes, and snippets.

@danoz73
Last active December 14, 2015 08:59
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save danoz73/5061888 to your computer and use it in GitHub Desktop.
Save danoz73/5061888 to your computer and use it in GitHub Desktop.
private void scanMedia(File file) {
Uri uri = Uri.fromFile(file);
Intent scanFileIntent = new Intent(Intent.ACTION_MEDIA_SCANNER_SCAN_FILE, uri);
sendBroadcast(scanFileIntent);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment