mirror of
https://github.com/SimpleMobileTools/Simple-Gallery.git
synced 2024-12-22 13:34:49 +01:00
delete the empty folder itself too
This commit is contained in:
parent
e03cf07761
commit
b880912ecb
@ -173,10 +173,13 @@ public class MainActivity extends AppCompatActivity
|
||||
updatedFiles.add(f.getAbsolutePath());
|
||||
f.delete();
|
||||
}
|
||||
updatedFiles.add(dir.getAbsolutePath());
|
||||
dir.delete();
|
||||
}
|
||||
|
||||
final String[] deletedPaths = updatedFiles.toArray(new String[updatedFiles.size()]);
|
||||
MediaScannerConnection.scanFile(this, deletedPaths, null, null);
|
||||
toBeDeleted.clear();
|
||||
}
|
||||
|
||||
private View.OnClickListener undoDeletion = new View.OnClickListener() {
|
||||
|
@ -194,6 +194,7 @@ public class PhotosActivity extends AppCompatActivity
|
||||
|
||||
final String[] deletedPaths = toBeDeleted.toArray(new String[toBeDeleted.size()]);
|
||||
MediaScannerConnection.scanFile(this, deletedPaths, null, this);
|
||||
toBeDeleted.clear();
|
||||
}
|
||||
|
||||
private View.OnClickListener undoDeletion = new View.OnClickListener() {
|
||||
|
@ -143,6 +143,7 @@ public class ViewPagerActivity extends AppCompatActivity
|
||||
final String[] deletedPath = new String[]{toBeDeleted};
|
||||
MediaScannerConnection.scanFile(this, deletedPath, null, this);
|
||||
}
|
||||
toBeDeleted = "";
|
||||
}
|
||||
|
||||
private View.OnClickListener undoDeletion = new View.OnClickListener() {
|
||||
|
Loading…
Reference in New Issue
Block a user