Android examples for Media:Ring
delete Files Ring Pack Tone from MediaStore
//package com.java2s; import android.content.Context; import android.os.Build; import android.provider.MediaStore; public class Main { public static int deleteFilesRingPackTone(Context ctx, String data) { String selection = MediaStore.MediaColumns.DATA + " = ?"; String[] args = { data }; if (Build.VERSION.SDK_INT >= 11) { return ctx.getContentResolver().delete( MediaStore.Files.getContentUri("external"), selection, args);/* w w w. java2 s. c om*/ } else { throw new UnsupportedOperationException( "Can only be called from API >= 11!"); } } }