Tools__ObjectModuleInformation.st
changeset 2739 8efd89a9863d
parent 2658 c284507a1279
child 2763 c36ead4db5bc
--- a/Tools__ObjectModuleInformation.st	Tue Dec 22 18:24:39 2009 +0100
+++ b/Tools__ObjectModuleInformation.st	Wed Jan 13 12:42:22 2010 +0100
@@ -983,11 +983,11 @@
     module := objectHandles at:sel.
     fileName := module pathName.
 
+    self canUnloadSelectedDLL value:true.
+
     module isMethodHandle ifTrue:[
         |method nm entry1 entry2 entry3|
 
-        self canUnloadSelectedDLL value:true.
-
         self middleLabelHolder value:'Compiled Method:'.
 
         (method := module method) isNil ifTrue:[
@@ -1294,14 +1294,22 @@
 !
 
 unloadSelectedModuleRemoveClasses:doRemoveClasses
-    (Dialog 
-        confirm:'This is a possibly dangerous operation, as the DLL is unloaded without caring for 
+    |module dll|
+
+    module := allModules at:self selectedModuleIndex ifAbsent:nil.
+    module isNil ifTrue:[
+        dll := objectHandles at:self selectedModuleIndex ifAbsent:nil.
+    ].
+    module notNil ifTrue:[
+        (Dialog 
+            confirm:'This is a possibly dangerous operation, as the DLL is unloaded without caring for 
 proper package-deinstallation procedures. Please use this only in repair situations and when the 
 regular unloadPackage operation fails.
 
 Continue ?')
-    ifFalse:[
-        ^ self  
+        ifFalse:[
+            ^ self  
+        ].
     ].
 
     self withWaitCursorDo:[
@@ -1312,7 +1320,7 @@
         self selectedModuleIndexHolder value:nil.
 
         info isNil ifTrue:[
-            "/ selected a method
+            "/ selected a method/dll
             "/ idx := idx - allModules size.
             pathName := handle pathName.
         ] ifFalse:[