Launcher.st
changeset 1733 19fa1448e6ae
parent 1729 79a4d5dd4c13
child 1744 1099dc1d6ea1
equal deleted inserted replaced
1732:099fb9d23958 1733:19fa1448e6ae
  4786 
  4786 
  4787 restoreSettingsFor:requestor
  4787 restoreSettingsFor:requestor
  4788     "restore settings from a settings-file."
  4788     "restore settings from a settings-file."
  4789 
  4789 
  4790     "a temporary kludge - we need a central systemSettings object for this,
  4790     "a temporary kludge - we need a central systemSettings object for this,
  4791      which can be saved/restored with a single store/read."
  4791      which can be saved/restored with a single store/read.
       
  4792      Will move entries over to UserPreferences over time;
       
  4793      new items should always go there."
  4792 
  4794 
  4793     |fileName resources|
  4795     |fileName resources|
  4794 
  4796 
  4795     resources := requestor class classResources.
  4797     resources := requestor class classResources.
  4796 
  4798 
  4811         Smalltalk fileIn:fileName.
  4813         Smalltalk fileIn:fileName.
  4812 
  4814 
  4813         self reopenLauncher.
  4815         self reopenLauncher.
  4814     ].
  4816     ].
  4815 
  4817 
  4816     "Modified: 8.1.1997 / 14:53:52 / cg"
  4818     "Modified: / 21.7.1998 / 11:37:54 / cg"
  4817 
       
  4818 !
  4819 !
  4819 
  4820 
  4820 saveSettingsFor:requestor
  4821 saveSettingsFor:requestor
  4821     "save settings to a settings-file."
  4822     "save settings to a settings-file."
  4822 
  4823 
  4823     "a temporary kludge - we need a central systemSettings object for this,
  4824     "a temporary kludge - we need a central systemSettings object for this,
  4824      which can be saved/restored with a single store/read."
  4825      which can be saved/restored with a single store/read.
       
  4826      Will move entries over to UserPreferences over time;
       
  4827      new items should always go there."
  4825 
  4828 
  4826     |s screen fileName resources|
  4829     |s screen fileName resources|
  4827 
  4830 
  4828     resources := requestor class classResources.
  4831     resources := requestor class classResources.
  4829 
  4832 
  4950       nextPutLine:'StandardSystemView returnFocusWhenClosingModalBoxes: ' , (StandardSystemView returnFocusWhenClosingModalBoxes storeString) , '.';
  4953       nextPutLine:'StandardSystemView returnFocusWhenClosingModalBoxes: ' , (StandardSystemView returnFocusWhenClosingModalBoxes storeString) , '.';
  4951       nextPutLine:'StandardSystemView takeFocusWhenMapped: ' , (StandardSystemView takeFocusWhenMapped storeString) , '.';
  4954       nextPutLine:'StandardSystemView takeFocusWhenMapped: ' , (StandardSystemView takeFocusWhenMapped storeString) , '.';
  4952       nextPutLine:'MenuView showAcceleratorKeys: ' , (MenuView showAcceleratorKeys storeString) , '.';
  4955       nextPutLine:'MenuView showAcceleratorKeys: ' , (MenuView showAcceleratorKeys storeString) , '.';
  4953       nextPutLine:'EditTextView st80Mode: ' , (EditTextView st80Mode storeString) , '.';
  4956       nextPutLine:'EditTextView st80Mode: ' , (EditTextView st80Mode storeString) , '.';
  4954       nextPutLine:'UserPreferences current syntaxColoring: ' , (UserPreferences current syntaxColoring storeString) , '.';
  4957       nextPutLine:'UserPreferences current syntaxColoring: ' , (UserPreferences current syntaxColoring storeString) , '.';
       
  4958       nextPutLine:'UserPreferences current useNewInspector: ' , (UserPreferences current useNewInspector storeString) , '.';
  4955       nextPutLine:'Class tryLocalSourceFirst: ' , (Class tryLocalSourceFirst storeString) , '.'.
  4959       nextPutLine:'Class tryLocalSourceFirst: ' , (Class tryLocalSourceFirst storeString) , '.'.
  4956     (Exception emergencyHandler == Launcher notifyingEmergencyHandler) ifTrue:[
  4960     (Exception emergencyHandler == Launcher notifyingEmergencyHandler) ifTrue:[
  4957         s nextPutLine:'Exception emergencyHandler:(Launcher notifyingEmergencyHandler).'.
  4961         s nextPutLine:'Exception emergencyHandler:(Launcher notifyingEmergencyHandler).'.
  4958     ].
  4962     ].
  4959 
  4963 
  5003 
  5007 
  5004     "
  5008     "
  5005      Transcript topView application saveSettings
  5009      Transcript topView application saveSettings
  5006     "
  5010     "
  5007 
  5011 
  5008     "Modified: / 1.4.1998 / 12:18:15 / cg"
  5012     "Modified: / 21.7.1998 / 11:37:44 / cg"
  5009 
       
  5010 !
  5013 !
  5011 
  5014 
  5012 sourceAndDebuggerSettingsFor:requestor
  5015 sourceAndDebuggerSettingsFor:requestor
  5013     "open a dialog on misc other settings"
  5016     "open a dialog on misc other settings"
  5014 
  5017 
  5016      useManager hasManager 
  5019      useManager hasManager 
  5017      repository repositoryHolder localSourceFirst 
  5020      repository repositoryHolder localSourceFirst 
  5018      sourceCacheDir cacheEntry
  5021      sourceCacheDir cacheEntry
  5019      component localCheck oldIndent nm fn manager
  5022      component localCheck oldIndent nm fn manager
  5020      keepMethodHistory showErrorNotifier showVerboseStack
  5023      keepMethodHistory showErrorNotifier showVerboseStack
  5021      syntaxColoring resources useNewInspector pos|
  5024      syntaxColoring resources useNewInspector pos currentUserPrefs|
       
  5025 
       
  5026     currentUserPrefs := UserPreferences current.
  5022 
  5027 
  5023     resources := requestor class classResources.
  5028     resources := requestor class classResources.
  5024 
  5029 
  5025     "/ 
  5030     "/ 
  5026     "/ extract relevant system settings ...
  5031     "/ extract relevant system settings ...
  5027     "/
  5032     "/
  5028     keepMethodHistory := Class methodHistory notNil asValue.
  5033     keepMethodHistory := Class methodHistory notNil asValue.
  5029     logDoits := Smalltalk logDoits asValue.
  5034     logDoits := Smalltalk logDoits asValue.
  5030     updChanges := Class updatingChanges asValue.
  5035     updChanges := Class updatingChanges asValue.
  5031     changeFileName := ObjectMemory nameForChanges asValue.
  5036     changeFileName := ObjectMemory nameForChanges asValue.
  5032     useNewInspector := UserPreferences current useNewInspector asValue.
  5037     useNewInspector := currentUserPrefs useNewInspector asValue.
  5033 
  5038 
  5034     hasManager := AbstractSourceCodeManager notNil
  5039     hasManager := AbstractSourceCodeManager notNil
  5035                   and:[AbstractSourceCodeManager isLoaded].
  5040                   and:[AbstractSourceCodeManager isLoaded].
  5036 
  5041 
  5037     hasManager ifTrue:[
  5042     hasManager ifTrue:[
  5049         useManager := false.
  5054         useManager := false.
  5050         localSourceFirst := false
  5055         localSourceFirst := false
  5051     ].
  5056     ].
  5052     showErrorNotifier := (Exception emergencyHandler == Launcher notifyingEmergencyHandler) asValue.
  5057     showErrorNotifier := (Exception emergencyHandler == Launcher notifyingEmergencyHandler) asValue.
  5053     showVerboseStack := (DebugView defaultVerboseBacktrace ? false) asValue.
  5058     showVerboseStack := (DebugView defaultVerboseBacktrace ? false) asValue.
  5054     syntaxColoring := UserPreferences current syntaxColoring asValue.
  5059     syntaxColoring := currentUserPrefs syntaxColoring asValue.
  5055 
  5060 
  5056     sourceCacheDir := nil asValue.
  5061     sourceCacheDir := nil asValue.
  5057 
  5062 
  5058     "/
  5063     "/
  5059     "/ create a box on those values ...
  5064     "/ create a box on those values ...
  5202             Exception emergencyHandler:nil
  5207             Exception emergencyHandler:nil
  5203         ] ifTrue:[
  5208         ] ifTrue:[
  5204             Exception emergencyHandler:(Launcher notifyingEmergencyHandler)
  5209             Exception emergencyHandler:(Launcher notifyingEmergencyHandler)
  5205         ].
  5210         ].
  5206         DebugView defaultVerboseBacktrace:(showVerboseStack value).
  5211         DebugView defaultVerboseBacktrace:(showVerboseStack value).
  5207         UserPreferences current syntaxColoring:syntaxColoring value.
  5212         currentUserPrefs syntaxColoring:syntaxColoring value.
  5208         UserPreferences current useNewInspector:useNewInspector value.
  5213         currentUserPrefs useNewInspector:useNewInspector value.
  5209         useNewInspector value ifTrue:[
  5214         useNewInspector value ifTrue:[
  5210             Inspector := NewInspector::InspectorView
  5215             Inspector := NewInspector::InspectorView
  5211         ] ifFalse:[
  5216         ] ifFalse:[
  5212             Inspector := InspectorView
  5217             Inspector := InspectorView
  5213         ].
  5218         ].
  5215     box destroy
  5220     box destroy
  5216 
  5221 
  5217     "Modified: / 9.9.1996 / 22:43:36 / stefan"
  5222     "Modified: / 9.9.1996 / 22:43:36 / stefan"
  5218     "Created: / 17.1.1997 / 17:39:33 / cg"
  5223     "Created: / 17.1.1997 / 17:39:33 / cg"
  5219     "Modified: / 16.4.1998 / 17:18:47 / ca"
  5224     "Modified: / 16.4.1998 / 17:18:47 / ca"
  5220     "Modified: / 18.6.1998 / 18:43:25 / cg"
  5225     "Modified: / 21.7.1998 / 11:34:45 / cg"
  5221 !
  5226 !
  5222 
  5227 
  5223 viewStyleSettingsFor:requestor 
  5228 viewStyleSettingsFor:requestor 
  5224     "open a dialog on viewStyle related settings"
  5229     "open a dialog on viewStyle related settings"
  5225 
  5230 
  5552 ! !
  5557 ! !
  5553 
  5558 
  5554 !Launcher class methodsFor:'documentation'!
  5559 !Launcher class methodsFor:'documentation'!
  5555 
  5560 
  5556 version
  5561 version
  5557     ^ '$Header: /cvs/stx/stx/libtool/Launcher.st,v 1.354 1998-07-20 11:22:32 cg Exp $'
  5562     ^ '$Header: /cvs/stx/stx/libtool/Launcher.st,v 1.355 1998-07-21 09:40:06 cg Exp $'
  5558 ! !
  5563 ! !