OldLauncher.st
changeset 25 f2d5bfa2c257
parent 21 add60084cf35
child 27 3dd66037a853
--- a/OldLauncher.st	Mon Jan 17 10:27:52 1994 +0100
+++ b/OldLauncher.st	Mon Jan 17 10:29:58 1994 +0100
@@ -24,7 +24,7 @@
 
 allows startup of smalltalk applications
 
-$Header: /cvs/stx/stx/libtool/OldLauncher.st,v 1.8 1994-01-13 00:16:57 claus Exp $
+$Header: /cvs/stx/stx/libtool/OldLauncher.st,v 1.9 1994-01-17 09:29:58 claus Exp $
 written spring 91 by claus
 '!
 
@@ -275,6 +275,7 @@
                             'Getting started'
                             'Customizing'
                             'Tools'
+                            'other topics'
                             '-'
                             'Help Browser'
                            ))
@@ -283,6 +284,7 @@
                             showGettingStarted
                             showCustomizing
                             tools
+                            otherTopics
                             nil
                             startHelpView
                           )
@@ -309,6 +311,26 @@
 
     ).
 
+    (myMenu subMenuAt:#helpMenu) subMenuAt:#otherTopics put:(
+        PopUpMenu labels:(resources array:#(
+                            'Garbage collection'
+                            'Language & primitives'
+                            '-'
+                            'stc manual page'
+                            'smalltalk manual page'
+                           ))
+               selectors:#(
+                            showGCDocumentation
+                            showLanguageDocumentation
+			    nil
+                            showSTCManualPage
+                            showSmalltalkManualPage
+                          )
+                receiver:self
+                     for:self
+
+    ).
+
     myMenu borderWidth:0.
     myMenu origin:(0 @ 0).
     myMenu font:(self font).
@@ -408,6 +430,15 @@
                         action:[:fileName | anImage saveOn:fileName].
     box pattern:'*.tiff'.
     box showAtPointer
+!
+
+closeDownViews
+    "tell each topview that we are going to terminate and give it chance
+     to save its contents."
+
+    StandardSystemView allDerivedInstancesDo:[:aTopView |
+        aTopView saveTerminate
+    ]
 ! !
 
 !Launcher methodsFor:'events'!
@@ -715,6 +746,22 @@
     self showDocumentFile:'doc/misc/debugger'
 !
 
+showGCDocumentation
+    self showDocumentFile:'doc/misc/GC'
+!
+
+showLanguageDocumentation
+    self showDocumentFile:'doc/misc/language'
+!
+
+showSTCManualPage
+    self showDocumentFile:'doc/misc/stc'
+!
+
+showSmalltalkManualPage
+    self showDocumentFile:'doc/misc/smalltalk'
+!
+
 startHelpView
     self warn:'The HelpSystem is still under construction.
 
@@ -753,9 +800,22 @@
         exitBox okText2:(resources at:'save & exit').
     ].
 
-    exitBox action:[:name | Smalltalk exit].
+    exitBox action:[:name | 
+        self closeDownViews.
+        Smalltalk exit
+    ].
+
     exitBox action2:[:name | 
         ObjectMemory snapShotOn:name. 
+
+        "this is NOT required - all data should be in the snapshot ...
+         ... however, if remote disks/mounatble filesystems are involved,
+         which may not be present the next time, it may make sense to 
+         uncomment it and query for saving - time will show which is better.
+        "
+"
+        self closeDownViews.
+"
         Smalltalk exit
     ].