10398
|
1 |
"
|
|
2 |
COPYRIGHT (c) 2006 by eXept Software AG
|
|
3 |
All Rights Reserved
|
|
4 |
|
|
5 |
This software is furnished under a license and may be used
|
|
6 |
only in accordance with the terms of that license and with the
|
|
7 |
inclusion of the above copyright notice. This software may not
|
|
8 |
be provided or otherwise made available to, or used by, any
|
|
9 |
other person. No title to or ownership of the software is
|
|
10 |
hereby transferred.
|
|
11 |
"
|
10337
|
12 |
"{ Package: 'stx:libtool' }"
|
|
13 |
|
|
14 |
"{ NameSpace: Tools }"
|
|
15 |
|
|
16 |
AbstractSettingsApplication subclass:#CodeView2SettingsAppl
|
10398
|
17 |
instanceVariableNames:'useCodeView2InTools useCodeView2InDebugger useCodeView2InBrowser
|
|
18 |
useCodeView2InToolEnabled useCodeView2InWorkspace'
|
10337
|
19 |
classVariableNames:''
|
|
20 |
poolDictionaries:''
|
|
21 |
category:'Interface-CodeView'
|
|
22 |
!
|
|
23 |
|
10398
|
24 |
!CodeView2SettingsAppl class methodsFor:'documentation'!
|
|
25 |
|
|
26 |
copyright
|
|
27 |
"
|
|
28 |
COPYRIGHT (c) 2006 by eXept Software AG
|
|
29 |
All Rights Reserved
|
|
30 |
|
|
31 |
This software is furnished under a license and may be used
|
|
32 |
only in accordance with the terms of that license and with the
|
|
33 |
inclusion of the above copyright notice. This software may not
|
|
34 |
be provided or otherwise made available to, or used by, any
|
|
35 |
other person. No title to or ownership of the software is
|
|
36 |
hereby transferred.
|
|
37 |
"
|
|
38 |
! !
|
10337
|
39 |
|
|
40 |
!CodeView2SettingsAppl class methodsFor:'interface specs'!
|
|
41 |
|
|
42 |
windowSpec
|
|
43 |
"This resource specification was automatically generated
|
|
44 |
by the UIPainter of ST/X."
|
|
45 |
|
|
46 |
"Do not manually edit this!! If it is corrupted,
|
|
47 |
the UIPainter may not be able to read the specification."
|
|
48 |
|
|
49 |
"
|
|
50 |
UIPainter new openOnClass:Tools::CodeView2SettingsAppl andSelector:#windowSpec
|
|
51 |
Tools::CodeView2SettingsAppl new openInterface:#windowSpec
|
|
52 |
Tools::CodeView2SettingsAppl open
|
|
53 |
"
|
|
54 |
|
|
55 |
<resource: #canvas>
|
|
56 |
|
|
57 |
^
|
|
58 |
#(FullSpec
|
|
59 |
name: windowSpec
|
|
60 |
window:
|
|
61 |
(WindowSpec
|
|
62 |
label: 'Code Editor Settings'
|
|
63 |
name: 'Code Editor Settings'
|
|
64 |
min: (Point 10 10)
|
|
65 |
bounds: (Rectangle 0 0 576 300)
|
|
66 |
)
|
|
67 |
component:
|
|
68 |
(SpecCollection
|
|
69 |
collection: (
|
|
70 |
(VerticalPanelViewSpec
|
|
71 |
name: 'VBox'
|
|
72 |
layout: (LayoutFrame 0 0 0 0 0 1 0 1)
|
|
73 |
horizontalLayout: fit
|
|
74 |
verticalLayout: top
|
|
75 |
horizontalSpace: 3
|
|
76 |
verticalSpace: 3
|
|
77 |
component:
|
|
78 |
(SpecCollection
|
|
79 |
collection: (
|
|
80 |
(FramedBoxSpec
|
|
81 |
label: 'Tool Support'
|
|
82 |
name: 'ToolSupport'
|
|
83 |
labelPosition: topLeft
|
|
84 |
translateLabel: true
|
|
85 |
component:
|
|
86 |
(SpecCollection
|
|
87 |
collection: (
|
|
88 |
(VerticalPanelViewSpec
|
|
89 |
name: 'ToolSupportCheckBox'
|
10398
|
90 |
layout: (LayoutFrame 0 0 0 0 0 1 104 0)
|
10337
|
91 |
horizontalLayout: fit
|
|
92 |
verticalLayout: top
|
|
93 |
horizontalSpace: 3
|
|
94 |
verticalSpace: 3
|
|
95 |
component:
|
|
96 |
(SpecCollection
|
|
97 |
collection: (
|
|
98 |
(CheckBoxSpec
|
|
99 |
label: 'Use Advanced Code Editor in All Tools (when supported)'
|
|
100 |
name: 'CheckBox1'
|
|
101 |
model: useCodeView2InTools
|
|
102 |
translateLabel: true
|
|
103 |
extent: (Point 540 22)
|
|
104 |
)
|
10398
|
105 |
(DividerSpec
|
|
106 |
name: 'Separator1'
|
|
107 |
extent: (Point 540 4)
|
|
108 |
)
|
|
109 |
(CheckBoxSpec
|
|
110 |
label: 'Use Advanced Code Editor in Class Browser'
|
|
111 |
name: 'CheckBox2'
|
|
112 |
enableChannel: useCodeView2InToolEnabled
|
|
113 |
model: useCodeView2InBrowser
|
|
114 |
translateLabel: true
|
|
115 |
extent: (Point 540 22)
|
|
116 |
)
|
|
117 |
(CheckBoxSpec
|
|
118 |
label: 'Use Advanced Code Editor in Debugger (HIGHLY EXPERIMENTAL!!!!!!)'
|
|
119 |
name: 'CheckBox3'
|
|
120 |
enableChannel: useCodeView2InToolEnabled
|
|
121 |
model: useCodeView2InDebugger
|
|
122 |
translateLabel: true
|
|
123 |
extent: (Point 540 22)
|
|
124 |
)
|
|
125 |
(CheckBoxSpec
|
|
126 |
label: 'Use Advanced Code Editor in Workspace'
|
|
127 |
name: 'CheckBox4'
|
|
128 |
enableChannel: useCodeView2InToolEnabled
|
|
129 |
model: useCodeView2InWorkspace
|
|
130 |
translateLabel: true
|
|
131 |
extent: (Point 540 22)
|
|
132 |
)
|
10337
|
133 |
)
|
|
134 |
|
|
135 |
)
|
|
136 |
useDynamicPreferredHeight: true
|
|
137 |
usePreferredHeight: true
|
|
138 |
)
|
|
139 |
)
|
|
140 |
|
|
141 |
)
|
10398
|
142 |
extent: (Point 590 154)
|
10337
|
143 |
useDynamicPreferredHeight: true
|
|
144 |
useDynamicPreferredWidth: true
|
|
145 |
usePreferredHeight: true
|
|
146 |
usePreferredWidth: true
|
|
147 |
)
|
|
148 |
)
|
|
149 |
|
|
150 |
)
|
|
151 |
)
|
|
152 |
)
|
|
153 |
|
|
154 |
)
|
|
155 |
)
|
10398
|
156 |
|
10337
|
157 |
! !
|
|
158 |
|
|
159 |
!CodeView2SettingsAppl methodsFor:'aspects'!
|
|
160 |
|
10398
|
161 |
useCodeView2InBrowser
|
|
162 |
"return/create the 'useCodeView2InTools' value holder (automatically generated)"
|
|
163 |
|
|
164 |
useCodeView2InBrowser isNil ifTrue:[
|
|
165 |
useCodeView2InBrowser := ValueHolder new.
|
|
166 |
useCodeView2InBrowser onChangeSend:#updateModifiedChannel to:self
|
|
167 |
|
|
168 |
].
|
|
169 |
^ useCodeView2InBrowser
|
|
170 |
|
|
171 |
"Modified: / 11-03-2010 / 10:09:04 / Jan Vrany <jan.vrany@fit.cvut.cz>"
|
|
172 |
"Created: / 26-07-2011 / 10:30:26 / Jan Vrany <jan.vrany@fit.cvut.cz>"
|
|
173 |
!
|
|
174 |
|
|
175 |
useCodeView2InDebugger
|
|
176 |
"return/create the 'useCodeView2InTools' value holder (automatically generated)"
|
|
177 |
|
|
178 |
useCodeView2InDebugger isNil ifTrue:[
|
|
179 |
useCodeView2InDebugger := ValueHolder new.
|
|
180 |
useCodeView2InDebugger onChangeSend:#updateModifiedChannel to:self
|
|
181 |
|
|
182 |
].
|
|
183 |
^ useCodeView2InDebugger
|
|
184 |
|
|
185 |
"Modified: / 11-03-2010 / 10:09:04 / Jan Vrany <jan.vrany@fit.cvut.cz>"
|
|
186 |
"Created: / 26-07-2011 / 10:30:39 / Jan Vrany <jan.vrany@fit.cvut.cz>"
|
|
187 |
!
|
|
188 |
|
10337
|
189 |
useCodeView2InTools
|
|
190 |
"return/create the 'useCodeView2InTools' value holder (automatically generated)"
|
|
191 |
|
|
192 |
useCodeView2InTools isNil ifTrue:[
|
|
193 |
useCodeView2InTools := ValueHolder new.
|
|
194 |
useCodeView2InTools onChangeSend:#updateModifiedChannel to:self
|
|
195 |
|
|
196 |
].
|
|
197 |
^ useCodeView2InTools
|
|
198 |
|
|
199 |
"Modified: / 11-03-2010 / 10:09:04 / Jan Vrany <jan.vrany@fit.cvut.cz>"
|
10398
|
200 |
!
|
|
201 |
|
|
202 |
useCodeView2InWorkspace
|
|
203 |
"return/create the 'useCodeView2InTools' value holder (automatically generated)"
|
|
204 |
|
|
205 |
useCodeView2InWorkspace isNil ifTrue:[
|
|
206 |
useCodeView2InWorkspace := ValueHolder new.
|
|
207 |
useCodeView2InWorkspace onChangeSend:#updateModifiedChannel to:self
|
|
208 |
|
|
209 |
].
|
|
210 |
^ useCodeView2InWorkspace
|
|
211 |
|
|
212 |
"Modified: / 11-03-2010 / 10:09:04 / Jan Vrany <jan.vrany@fit.cvut.cz>"
|
|
213 |
"Created: / 26-07-2011 / 10:31:07 / Jan Vrany <jan.vrany@fit.cvut.cz>"
|
|
214 |
! !
|
|
215 |
|
|
216 |
!CodeView2SettingsAppl methodsFor:'aspects-enablement'!
|
|
217 |
|
|
218 |
useCodeView2InToolEnabled
|
|
219 |
"return/create the 'useCodeView2InTools' value holder (automatically generated)"
|
|
220 |
|
|
221 |
useCodeView2InToolEnabled isNil ifTrue:[
|
|
222 |
useCodeView2InToolEnabled :=
|
|
223 |
(AspectAdaptor forAspect: #not) subjectChannel:
|
|
224 |
self useCodeView2InTools
|
|
225 |
|
|
226 |
|
|
227 |
].
|
|
228 |
^ useCodeView2InToolEnabled
|
|
229 |
|
|
230 |
"Modified: / 11-03-2010 / 10:09:04 / Jan Vrany <jan.vrany@fit.cvut.cz>"
|
|
231 |
"Created: / 26-07-2011 / 10:39:03 / Jan Vrany <jan.vrany@fit.cvut.cz>"
|
10337
|
232 |
! !
|
|
233 |
|
|
234 |
!CodeView2SettingsAppl methodsFor:'protocol'!
|
|
235 |
|
|
236 |
basicAspects
|
10398
|
237 |
^#(
|
|
238 |
#useCodeView2InTools
|
|
239 |
#useCodeView2InBrowser
|
|
240 |
#useCodeView2InDebugger
|
|
241 |
#useCodeView2InWorkspace
|
|
242 |
)
|
|
243 |
|
|
244 |
"Modified: / 26-07-2011 / 10:31:39 / Jan Vrany <jan.vrany@fit.cvut.cz>"
|
10337
|
245 |
!
|
|
246 |
|
|
247 |
basicReadSettings
|
|
248 |
self readAspects:self basicAspects from:currentUserPrefs.
|
|
249 |
|
|
250 |
"Modified: / 19-07-2011 / 17:11:00 / Jan Vrany <jan.vrany@fit.cvut.cz>"
|
|
251 |
!
|
|
252 |
|
|
253 |
basicSaveSettings
|
|
254 |
|
|
255 |
self writeAspects:self basicAspects to:currentUserPrefs.
|
|
256 |
|
10398
|
257 |
"Modified: / 26-07-2011 / 10:43:53 / Jan Vrany <jan.vrany@fit.cvut.cz>"
|
10337
|
258 |
!
|
|
259 |
|
|
260 |
helpFilename
|
|
261 |
"subclasses must return the relative name of a helpFile
|
|
262 |
in the doc/online/<language>/help directory.
|
|
263 |
Or nil, if no help is available."
|
|
264 |
|
|
265 |
^ nil"for now"
|
|
266 |
|
|
267 |
"Modified: / 19-07-2011 / 16:55:16 / Jan Vrany <jan.vrany@fit.cvut.cz>"
|
|
268 |
! !
|
|
269 |
|
|
270 |
!CodeView2SettingsAppl methodsFor:'queries'!
|
|
271 |
|
|
272 |
hasUnsavedChanges
|
|
273 |
|
|
274 |
(self
|
|
275 |
hasChangedAspectIn: self basicAspects
|
|
276 |
asComparedTo:currentUserPrefs) ifTrue:[^ true].
|
|
277 |
^ false.
|
|
278 |
|
|
279 |
"Modified: / 19-07-2011 / 17:12:32 / Jan Vrany <jan.vrany@fit.cvut.cz>"
|
|
280 |
! !
|
|
281 |
|
|
282 |
!CodeView2SettingsAppl class methodsFor:'documentation'!
|
|
283 |
|
|
284 |
version
|
10398
|
285 |
^ '$Header: /cvs/stx/stx/libtool/Tools__CodeView2SettingsAppl.st,v 1.2 2011-07-26 09:53:35 vrany Exp $'
|
10337
|
286 |
!
|
|
287 |
|
|
288 |
version_CVS
|
10398
|
289 |
^ '$Header: /cvs/stx/stx/libtool/Tools__CodeView2SettingsAppl.st,v 1.2 2011-07-26 09:53:35 vrany Exp $'
|
|
290 |
!
|
|
291 |
|
|
292 |
version_SVN
|
|
293 |
^ '§Id§'
|
10337
|
294 |
! !
|