mirror of
https://github.com/AppleCommander/AppleCommander.git
synced 2025-01-03 10:29:19 +00:00
Uses supportsDiskMap to check if a disk map can/should be added.
This commit is contained in:
parent
2926f343ff
commit
01a1917d15
@ -73,7 +73,9 @@ public class DiskWindow {
|
|||||||
imageManager, this);
|
imageManager, this);
|
||||||
diskMapTabs = new DiskMapTab[disks.length];
|
diskMapTabs = new DiskMapTab[disks.length];
|
||||||
for (int i=0; i<disks.length; i++) {
|
for (int i=0; i<disks.length; i++) {
|
||||||
diskMapTabs[i] = new DiskMapTab(tabFolder, disks[i]);
|
if (disks[i].supportsDiskMap()) {
|
||||||
|
diskMapTabs[i] = new DiskMapTab(tabFolder, disks[i]);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
diskInfoTab = new DiskInfoTab(tabFolder, disks);
|
diskInfoTab = new DiskInfoTab(tabFolder, disks);
|
||||||
tabFolder.setSelection(tabFolder.getItems()[0]);
|
tabFolder.setSelection(tabFolder.getItems()[0]);
|
||||||
@ -94,8 +96,8 @@ public class DiskWindow {
|
|||||||
* Dispose of all shared resources.
|
* Dispose of all shared resources.
|
||||||
*/
|
*/
|
||||||
private void dispose(DisposeEvent event) {
|
private void dispose(DisposeEvent event) {
|
||||||
for (int i=0; i<disks.length; i++) {
|
for (int i=0; i<diskMapTabs.length; i++) {
|
||||||
diskMapTabs[i].dispose();
|
if (diskMapTabs[i] != null) diskMapTabs[i].dispose();
|
||||||
}
|
}
|
||||||
diskInfoTab.dispose();
|
diskInfoTab.dispose();
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user