AbstractSettingsApplication.st
changeset 9187 fd78cc38b8b8
parent 9185 7f2236aec3d4
child 9233 50ef1ada9fda
--- a/AbstractSettingsApplication.st	Thu Nov 05 20:28:25 2009 +0100
+++ b/AbstractSettingsApplication.st	Thu Nov 05 20:28:42 2009 +0100
@@ -47,6 +47,14 @@
 	privateIn:AbstractSettingsApplication
 !
 
+AbstractSettingsApplication subclass:#CodeGeneratorSettingsAppl
+	instanceVariableNames:'generateComments generateCommentsForGetters
+		generateCommentsForSetters'
+	classVariableNames:''
+	poolDictionaries:''
+	privateIn:AbstractSettingsApplication
+!
+
 AbstractSettingsApplication subclass:#DebuggerSettingsAppl
 	instanceVariableNames:'showErrorNotifier verboseBacktraceInDebugger
 		allowSendMailFromDebugger useNewLayoutInDebugger'
@@ -1878,6 +1886,173 @@
     ^ ObjectMemory supportsJustInTimeCompilation
 ! !
 
+!AbstractSettingsApplication::CodeGeneratorSettingsAppl class methodsFor:'image specs'!
+
+defaultIcon
+    "This resource specification was automatically generated
+     by the ImageEditor of ST/X."
+
+    "Do not manually edit this!! If it is corrupted,
+     the ImageEditor may not be able to read the specification."
+
+    "
+     self defaultIcon inspect
+     ImageEditor openOnClass:self andSelector:#defaultIcon
+     Icon flushCachedIcons
+    "
+
+    <resource: #image>
+
+    ^Icon
+        constantNamed:'AbstractSettingsApplication::CodeGeneratorSettingsAppl class defaultIcon'
+        ifAbsentPut:[(Depth8Image new) width: 22; height: 22; photometric:(#palette); bitsPerSample:(#[8]); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'
+B (JB (JB (JB (JB (JB (JB (JB (HB@ HB@ HB@ HB@ HB@ HB@$JB (JB@ EAPTEAPTEAPTEAPTEAPTIB@@@B  HAP(JB TEAPTEAPTEAPTEBP @@@(H
+B@TJAPTEAPTEAPTEAPTEAP$H@@@JB@ EB TEAPTEAPTQAPTEAPTIB@@@B  HAP(JB TEAPTQD!!DEAPTEBP @@@(HB@TEAPTEDQDEDQLQAQDQAP$H@@@JB@ E
+APTEDQPUDQTVEQDUEADIB@@@B  HAPTEAPTQE1 YF!!$XE1DEBP @@@(HB@TEAPTEAQDUF ,ZEQDEAP$H@@(JB@ EAPTEAPTQEQ(KF!!TQAPTIB@@JB  HAPTE
+APTQE1 YF!!$XE1DEA@ JB (HB@TEAPTQEATQEQXUDQTTDPPHB (JB@ EAPTEAQDQAQDSDPTQDPTDB@(JB  HAP(JB TEAPTQD!!DEAPTEA@ JB (HB@TEAP(E
+APTEAQDEAPTEAPPHB (JB@ EAPTJAPTEAPTEAPTEAPTDB@(JB  HAP(JB TEAPTEAPTEAPTEA@ JB (HB@TEAPTEAPTEAPTEAPTEAPPHB (JB@$DA@PDA@PD
+A@PDA@PDA@PDB@(JB (HB@ HB@ HB@ HB@ HB@ HB@ JB @a') ; colorMapFromArray:#[240 160 80 192 80 0 64 0 0 240 208 160 0 0 0 240 240 240 192 192 192 240 128 0 208 208 208 48 48 48 160 160 160 255 248 248 207 216 240 240 240 248 239 232 240 48 88 176 224 224 232 240 144 24 255 248 48 255 248 96 255 248 24 240 208 24 255 248 152 255 248 88 255 248 136 255 248 176 255 248 200]; mask:((Depth1Image new) width: 22; height: 22; photometric:(#blackIs0); bitsPerSample:(#(1)); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@_?? _??0_??0_??0_??0_??0_??0_??0_??0_??0_??0_??0_??0_??0_??0_??0_??0_??0_??0_??0O??0') ; yourself); yourself]
+! !
+
+!AbstractSettingsApplication::CodeGeneratorSettingsAppl class methodsFor:'interface specs'!
+
+windowSpec
+    "This resource specification was automatically generated
+     by the UIPainter of ST/X."
+
+    "Do not manually edit this!! If it is corrupted,
+     the UIPainter may not be able to read the specification."
+
+    "
+     UIPainter new openOnClass:AbstractSettingsApplication::CodeGeneratorSettingsAppl andSelector:#windowSpec
+     AbstractSettingsApplication::CodeGeneratorSettingsAppl new openInterface:#windowSpec
+     AbstractSettingsApplication::CodeGeneratorSettingsAppl open
+    "
+
+    <resource: #canvas>
+
+    ^ 
+     #(FullSpec
+        name: windowSpec
+        window: 
+       (WindowSpec
+          label: 'Tool Settings'
+          name: 'Tool Settings'
+          min: (Point 10 10)
+          bounds: (Rectangle 0 0 607 786)
+        )
+        component: 
+       (SpecCollection
+          collection: (
+           (VerticalPanelViewSpec
+              name: 'VerticalPanel2'
+              layout: (LayoutFrame 0 0.0 0 0 0 1.0 342 0)
+              horizontalLayout: fit
+              verticalLayout: top
+              horizontalSpace: 3
+              verticalSpace: 3
+              component: 
+             (SpecCollection
+                collection: (
+                 (CheckBoxSpec
+                    label: 'Generate Comments'
+                    name: 'GenerateComments'
+                    activeHelpKey: generateComments
+                    model: generateComments
+                    translateLabel: true
+                    extent: (Point 607 25)
+                  )
+                 (CheckBoxSpec
+                    label: 'Generate Comments In Getters'
+                    name: 'GenerateCommentsInGetters'
+                    activeHelpKey: generateCommentsInGetters
+                    enableChannel: generateComments
+                    model: generateCommentsInGetters
+                    translateLabel: true
+                    extent: (Point 607 25)
+                  )
+                 (CheckBoxSpec
+                    label: 'Generate Comments In Setters'
+                    name: 'GenerateCommentsInSetters'
+                    activeHelpKey: generateCommentsInSetters
+                    enableChannel: generateComments
+                    model: generateCommentsInSetters
+                    translateLabel: true
+                    extent: (Point 607 25)
+                  )
+                 )
+               
+              )
+            )
+           )
+         
+        )
+      )
+! !
+
+!AbstractSettingsApplication::CodeGeneratorSettingsAppl methodsFor:'actions'!
+
+basicReadSettings
+    self 
+        readAspects:(self aspectSelectors)
+        from:currentUserPrefs.
+!
+
+basicSaveSettings
+    self 
+        writeAspects:(self aspectSelectors)
+        to:currentUserPrefs.
+! !
+
+!AbstractSettingsApplication::CodeGeneratorSettingsAppl methodsFor:'aspects'!
+
+aspectSelectors
+    ^ #(
+        generateComments
+        generateCommentsForGetters
+        generateCommentsForSetters
+    )
+!
+
+generateComments
+    generateComments isNil ifTrue:[
+        generateComments := UserPreferences current generateComments asValue.
+        generateComments onChangeSend:#updateModifiedChannel to:self
+    ].
+    ^ generateComments.
+!
+
+generateCommentsForGetters
+    generateCommentsForGetters isNil ifTrue:[
+        generateCommentsForGetters := UserPreferences current generateCommentsForGetters asValue.
+        generateCommentsForGetters onChangeSend:#updateModifiedChannel to:self
+    ].
+    ^ generateCommentsForGetters.
+!
+
+generateCommentsForSetters
+    generateCommentsForSetters isNil ifTrue:[
+        generateCommentsForSetters := UserPreferences current generateCommentsForSetters asValue.
+        generateCommentsForSetters onChangeSend:#updateModifiedChannel to:self
+    ].
+    ^ generateCommentsForSetters.
+! !
+
+!AbstractSettingsApplication::CodeGeneratorSettingsAppl methodsFor:'help'!
+
+helpFilename
+    ^ 'Launcher/codeGeneratorSettings.html'
+! !
+
+!AbstractSettingsApplication::CodeGeneratorSettingsAppl methodsFor:'queries'!
+
+hasUnsavedChanges
+    (self
+        hasChangedAspectIn:(self aspectSelectors)
+        asComparedTo:currentUserPrefs) ifTrue:[^ true].
+    ^ false.
+! !
+
 !AbstractSettingsApplication::DebuggerSettingsAppl class methodsFor:'image specs'!
 
 defaultIcon
@@ -10855,11 +11030,11 @@
     <resource: #image>
 
     ^Icon
-        constantNamed:#'AbstractSettingsApplication::SourceCodeFormatSettingsAppl class defaultIcon'
+        constantNamed:'AbstractSettingsApplication::SourceCodeFormatSettingsAppl class defaultIcon'
         ifAbsentPut:[(Depth4Image new) width: 22; height: 22; photometric:(#palette); bitsPerSample:(#(4)); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'
-*******************************("H"H"H"H"J(@**"EUUUUUUUU@@^**HUUUUUUUU@@]:*(!!UUUUUUUT@A7**"EY&YVYVX@]7^**HUUUUUU@@]7\Z*(
-!!UUUUU@@]7\R**"EUUUUT@A7]1J**HU&Y%XC]7\Q&**(!!UUU(3M7\Y&***"EUUU#L3L2QJ***HUUV#L3L6UD***(!!VY*L3L6Z$R***"EUUP3M&ZEQJ***HUU
-RRY(UUUD***(!!UUJ)UUUUTR***"E)J******QJ***HUUUUUUUUUD***TQDQDQDQDQDR***************(b') ; colorMapFromArray:#[240 160 80 192 80 0 64 0 0 240 208 160 0 0 0 240 240 240 192 192 192 240 128 0 208 208 208 48 48 48 160 160 160]; mask:((Depth1Image new) width: 22; height: 22; photometric:(#blackIs0); bitsPerSample:(#(1)); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@G??LG??<G??<G??<G??<G??<G??<G??<G??8G??0G??0G??0G??0G??0G??0G??0G??0G??0O??0@@@@') ; yourself); yourself]
+***************("H"H"H"H"H"Z**"EUUUUUUUUUY @*HV*)UUUUUUU&@B(!!ZUUUUUUUUVX@J"E)UUUUUUUUY @*HV*)UUUUUUU&@B(!!UUUV****%VX@J"E
+UUUUUUUUUY @*HUUUU****)U&@B(!!UUUUUUUUUVXB*"EUUUZ****UY J*HUUUUUUUUUURJ*(!!UUUV****%UH**"EUUUUUUUUUT"**HV*)UUUUUUURJ*(!!UV%
+UUUUUUUH**"EUZUUUUUUUT"**HV*)UUUUUUURJ*(!!UUUUUUUUUUH**"TQDQDQDQDQD"**("H"H"H"H"H"J(b') ; colorMapFromArray:#[240 160 80 192 80 0 64 0 0 240 208 160 0 0 0 240 240 240 192 192 192 240 128 0 208 208 208 48 48 48 160 160 160]; mask:((Depth1Image new) width: 22; height: 22; photometric:(#blackIs0); bitsPerSample:(#(1)); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@_?? _??0_??0_??0_??0_??0_??0_??0_??0_??0_??0_??0_??0_??0_??0_??0_??0_??0_??0_??0O??0') ; yourself); yourself]
 ! !
 
 !AbstractSettingsApplication::SourceCodeFormatSettingsAppl class methodsFor:'interface specs'!
@@ -15738,9 +15913,9 @@
 !AbstractSettingsApplication class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libtool/AbstractSettingsApplication.st,v 1.348 2009-11-05 19:22:56 stefan Exp $'
+    ^ '$Header: /cvs/stx/stx/libtool/AbstractSettingsApplication.st,v 1.349 2009-11-05 19:28:42 cg Exp $'
 !
 
 version_CVS
-    ^ '$Header: /cvs/stx/stx/libtool/AbstractSettingsApplication.st,v 1.348 2009-11-05 19:22:56 stefan Exp $'
-! !
+    ^ '$Header: /cvs/stx/stx/libtool/AbstractSettingsApplication.st,v 1.349 2009-11-05 19:28:42 cg Exp $'
+! !