private void deleteSound(int position) { String filePath = sounds[position].getPath(); database.deleteSound(sounds[position]); File file = new File(filePath); if (file.delete()) { Toast.makeText(this, filePath + " " + R.string.info_deleted, Toast.LENGTH_SHORT).show(); refreshList(); } else { Toast.makeText(this, R.string.info_shit_happened, Toast.LENGTH_SHORT).show(); } }