Revision 9172
org.gvsig.vcsgis/trunk/org.gvsig.vcsgis/org.gvsig.vcsgis.lib/org.gvsig.vcsgis.lib.api/src/main/java/org/gvsig/vcsgis/lib/workspace/VCSGisWorkspace.java | ||
---|---|---|
316 | 316 |
public boolean canUpdate(MutableObject<String> message, String tableName); |
317 | 317 |
|
318 | 318 |
public List<VCSGisRepositoryLogData> log(String tableName, String featureRelatedCode, SimpleTaskStatus status); |
319 |
|
|
319 |
|
|
320 |
public void setConfigValue(String name, String value); |
|
320 | 321 |
} |
org.gvsig.vcsgis/trunk/org.gvsig.vcsgis/org.gvsig.vcsgis.lib/org.gvsig.vcsgis.lib.impl/src/main/java/org/gvsig/vcsgis/lib/workspace/VCSGisWorkspaceImpl.java | ||
---|---|---|
5479 | 5479 |
} |
5480 | 5480 |
} |
5481 | 5481 |
|
5482 |
@Override |
|
5483 |
public void setConfigValue(String name, String value) { |
|
5484 |
VarsTable varsTable = new VarsTable(); |
|
5485 |
varsTable.set(this, name, value); |
|
5486 |
} |
|
5482 | 5487 |
} |
org.gvsig.vcsgis/trunk/org.gvsig.vcsgis/org.gvsig.vcsgis.swing/org.gvsig.vcsgis.swing.impl/src/main/java/org/gvsig/vcsgis/swing/impl/setWorkingCopyOffline/VCSGisJSetWorkingCopyOfflineView.xml | ||
---|---|---|
1 |
<?xml version="1.0" encoding="UTF-8"?> |
|
2 |
|
|
3 |
<object classname="com.jeta.forms.store.memento.FormPackage"> |
|
4 |
<at name="fileversion"> |
|
5 |
<object classname="com.jeta.forms.store.memento.FormsVersion2"> |
|
6 |
<at name="major">2</at> |
|
7 |
<at name="minor">0</at> |
|
8 |
<at name="sub">0</at> |
|
9 |
</object> |
|
10 |
</at> |
|
11 |
<at name="form"> |
|
12 |
<object classname="com.jeta.forms.store.memento.FormMemento"> |
|
13 |
<super classname="com.jeta.forms.store.memento.ComponentMemento"> |
|
14 |
<at name="cellconstraints"> |
|
15 |
<object classname="com.jeta.forms.store.memento.CellConstraintsMemento"> |
|
16 |
<at name="column">1</at> |
|
17 |
<at name="row">1</at> |
|
18 |
<at name="colspan">1</at> |
|
19 |
<at name="rowspan">1</at> |
|
20 |
<at name="halign">default</at> |
|
21 |
<at name="valign">default</at> |
|
22 |
<at name="insets" object="insets">0,0,0,0</at> |
|
23 |
</object> |
|
24 |
</at> |
|
25 |
<at name="componentclass">com.jeta.forms.gui.form.FormComponent</at> |
|
26 |
</super> |
|
27 |
<at name="id">/home/jjdelcerro/datos/devel/org.gvsig.vcsgis/org.gvsig.vcsgis.swing/org.gvsig.vcsgis.swing.impl/src/main/java/org/gvsig/vcsgis/swing/impl/setWorkingCopyAsOffline/VCSGisJSetWorkingCopyAsOfflineView.xml</at> |
|
28 |
<at name="path">datos/devel/org.gvsig.vcsgis/org.gvsig.vcsgis.swing/org.gvsig.vcsgis.swing.impl/src/main/java/org/gvsig/vcsgis/swing/impl/setWorkingCopyAsOffline/VCSGisJSetWorkingCopyAsOfflineView.xml</at> |
|
29 |
<at name="rowspecs">CENTER:2DLU:NONE,CENTER:DEFAULT:NONE,CENTER:2DLU:NONE,CENTER:DEFAULT:NONE,CENTER:2DLU:NONE</at> |
|
30 |
<at name="colspecs">FILL:4DLU:NONE,FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:DEFAULT:GROW(1.0),FILL:4DLU:NONE,FILL:DEFAULT:NONE,FILL:4DLU:NONE</at> |
|
31 |
<at name="components"> |
|
32 |
<object classname="java.util.LinkedList"> |
|
33 |
<item > |
|
34 |
<at name="value"> |
|
35 |
<object classname="com.jeta.forms.store.memento.BeanMemento"> |
|
36 |
<super classname="com.jeta.forms.store.memento.ComponentMemento"> |
|
37 |
<at name="cellconstraints"> |
|
38 |
<object classname="com.jeta.forms.store.memento.CellConstraintsMemento"> |
|
39 |
<at name="column">2</at> |
|
40 |
<at name="row">2</at> |
|
41 |
<at name="colspan">1</at> |
|
42 |
<at name="rowspan">1</at> |
|
43 |
<at name="halign">default</at> |
|
44 |
<at name="valign">default</at> |
|
45 |
<at name="insets" object="insets">0,0,0,0</at> |
|
46 |
</object> |
|
47 |
</at> |
|
48 |
<at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at> |
|
49 |
</super> |
|
50 |
<at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at> |
|
51 |
<at name="beanclass">com.jeta.forms.components.label.JETALabel</at> |
|
52 |
<at name="beanproperties"> |
|
53 |
<object classname="com.jeta.forms.store.memento.PropertiesMemento"> |
|
54 |
<at name="classname">com.jeta.forms.components.label.JETALabel</at> |
|
55 |
<at name="properties"> |
|
56 |
<object classname="com.jeta.forms.store.support.PropertyMap"> |
|
57 |
<at name="border"> |
|
58 |
<object classname="com.jeta.forms.store.properties.CompoundBorderProperty"> |
|
59 |
<super classname="com.jeta.forms.store.properties.BorderProperty"> |
|
60 |
<at name="name">border</at> |
|
61 |
</super> |
|
62 |
<at name="borders"> |
|
63 |
<object classname="java.util.LinkedList"> |
|
64 |
<item > |
|
65 |
<at name="value"> |
|
66 |
<object classname="com.jeta.forms.store.properties.DefaultBorderProperty"> |
|
67 |
<super classname="com.jeta.forms.store.properties.BorderProperty"> |
|
68 |
<at name="name">border</at> |
|
69 |
</super> |
|
70 |
</object> |
|
71 |
</at> |
|
72 |
</item> |
|
73 |
</object> |
|
74 |
</at> |
|
75 |
</object> |
|
76 |
</at> |
|
77 |
<at name="name">lblWorkspace</at> |
|
78 |
<at name="width">75</at> |
|
79 |
<at name="text">_Workingcopy</at> |
|
80 |
<at name="fill"> |
|
81 |
<object classname="com.jeta.forms.store.properties.effects.PaintProperty"> |
|
82 |
<at name="name">fill</at> |
|
83 |
</object> |
|
84 |
</at> |
|
85 |
<at name="height">16</at> |
|
86 |
</object> |
|
87 |
</at> |
|
88 |
</object> |
|
89 |
</at> |
|
90 |
</object> |
|
91 |
</at> |
|
92 |
</item> |
|
93 |
<item > |
|
94 |
<at name="value"> |
|
95 |
<object classname="com.jeta.forms.store.memento.BeanMemento"> |
|
96 |
<super classname="com.jeta.forms.store.memento.ComponentMemento"> |
|
97 |
<at name="cellconstraints"> |
|
98 |
<object classname="com.jeta.forms.store.memento.CellConstraintsMemento"> |
|
99 |
<at name="column">4</at> |
|
100 |
<at name="row">2</at> |
|
101 |
<at name="colspan">1</at> |
|
102 |
<at name="rowspan">1</at> |
|
103 |
<at name="halign">default</at> |
|
104 |
<at name="valign">default</at> |
|
105 |
<at name="insets" object="insets">0,0,0,0</at> |
|
106 |
</object> |
|
107 |
</at> |
|
108 |
<at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at> |
|
109 |
</super> |
|
110 |
<at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at> |
|
111 |
<at name="beanclass">javax.swing.JComboBox</at> |
|
112 |
<at name="beanproperties"> |
|
113 |
<object classname="com.jeta.forms.store.memento.PropertiesMemento"> |
|
114 |
<at name="classname">javax.swing.JComboBox</at> |
|
115 |
<at name="properties"> |
|
116 |
<object classname="com.jeta.forms.store.support.PropertyMap"> |
|
117 |
<at name="border"> |
|
118 |
<object classname="com.jeta.forms.store.properties.CompoundBorderProperty"> |
|
119 |
<super classname="com.jeta.forms.store.properties.BorderProperty"> |
|
120 |
<at name="name">border</at> |
|
121 |
</super> |
|
122 |
<at name="borders"> |
|
123 |
<object classname="java.util.LinkedList"> |
|
124 |
<item > |
|
125 |
<at name="value"> |
|
126 |
<object classname="com.jeta.forms.store.properties.DefaultBorderProperty"> |
|
127 |
<super classname="com.jeta.forms.store.properties.BorderProperty"> |
|
128 |
<at name="name">border</at> |
|
129 |
</super> |
|
130 |
</object> |
|
131 |
</at> |
|
132 |
</item> |
|
133 |
</object> |
|
134 |
</at> |
|
135 |
</object> |
|
136 |
</at> |
|
137 |
<at name="name">cboWorkspaces</at> |
|
138 |
<at name="width">1483</at> |
|
139 |
<at name="items"> |
|
140 |
<object classname="com.jeta.forms.store.properties.ItemsProperty"> |
|
141 |
<at name="name">items</at> |
|
142 |
</object> |
|
143 |
</at> |
|
144 |
<at name="height">22</at> |
|
145 |
</object> |
|
146 |
</at> |
|
147 |
</object> |
|
148 |
</at> |
|
149 |
</object> |
|
150 |
</at> |
|
151 |
</item> |
|
152 |
<item > |
|
153 |
<at name="value"> |
|
154 |
<object classname="com.jeta.forms.store.memento.BeanMemento"> |
|
155 |
<super classname="com.jeta.forms.store.memento.ComponentMemento"> |
|
156 |
<at name="cellconstraints"> |
|
157 |
<object classname="com.jeta.forms.store.memento.CellConstraintsMemento"> |
|
158 |
<at name="column">6</at> |
|
159 |
<at name="row">2</at> |
|
160 |
<at name="colspan">1</at> |
|
161 |
<at name="rowspan">1</at> |
|
162 |
<at name="halign">default</at> |
|
163 |
<at name="valign">default</at> |
|
164 |
<at name="insets" object="insets">0,0,0,0</at> |
|
165 |
</object> |
|
166 |
</at> |
|
167 |
<at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at> |
|
168 |
</super> |
|
169 |
<at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at> |
|
170 |
<at name="beanclass">javax.swing.JButton</at> |
|
171 |
<at name="beanproperties"> |
|
172 |
<object classname="com.jeta.forms.store.memento.PropertiesMemento"> |
|
173 |
<at name="classname">javax.swing.JButton</at> |
|
174 |
<at name="properties"> |
|
175 |
<object classname="com.jeta.forms.store.support.PropertyMap"> |
|
176 |
<at name="border"> |
|
177 |
<object classname="com.jeta.forms.store.properties.CompoundBorderProperty"> |
|
178 |
<super classname="com.jeta.forms.store.properties.BorderProperty"> |
|
179 |
<at name="name">border</at> |
|
180 |
</super> |
|
181 |
<at name="borders"> |
|
182 |
<object classname="java.util.LinkedList"> |
|
183 |
<item > |
|
184 |
<at name="value"> |
|
185 |
<object classname="com.jeta.forms.store.properties.EmptyBorderProperty"> |
|
186 |
<super classname="com.jeta.forms.store.properties.BorderProperty"> |
|
187 |
<at name="name">border</at> |
|
188 |
</super> |
|
189 |
<at name="top">2</at> |
|
190 |
<at name="left">2</at> |
|
191 |
<at name="bottom">2</at> |
|
192 |
<at name="right">2</at> |
|
193 |
</object> |
|
194 |
</at> |
|
195 |
</item> |
|
196 |
</object> |
|
197 |
</at> |
|
198 |
</object> |
|
199 |
</at> |
|
200 |
<at name="actionCommand">...</at> |
|
201 |
<at name="name">btnInitWorkspace</at> |
|
202 |
<at name="width">13</at> |
|
203 |
<at name="text">...</at> |
|
204 |
<at name="height">20</at> |
|
205 |
</object> |
|
206 |
</at> |
|
207 |
</object> |
|
208 |
</at> |
|
209 |
</object> |
|
210 |
</at> |
|
211 |
</item> |
|
212 |
<item > |
|
213 |
<at name="value"> |
|
214 |
<object classname="com.jeta.forms.store.memento.BeanMemento"> |
|
215 |
<super classname="com.jeta.forms.store.memento.ComponentMemento"> |
|
216 |
<at name="cellconstraints"> |
|
217 |
<object classname="com.jeta.forms.store.memento.CellConstraintsMemento"> |
|
218 |
<at name="column">2</at> |
|
219 |
<at name="row">4</at> |
|
220 |
<at name="colspan">1</at> |
|
221 |
<at name="rowspan">1</at> |
|
222 |
<at name="halign">default</at> |
|
223 |
<at name="valign">default</at> |
|
224 |
<at name="insets" object="insets">0,0,0,0</at> |
|
225 |
</object> |
|
226 |
</at> |
|
227 |
<at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at> |
|
228 |
</super> |
|
229 |
<at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at> |
|
230 |
<at name="beanclass">com.jeta.forms.components.label.JETALabel</at> |
|
231 |
<at name="beanproperties"> |
|
232 |
<object classname="com.jeta.forms.store.memento.PropertiesMemento"> |
|
233 |
<at name="classname">com.jeta.forms.components.label.JETALabel</at> |
|
234 |
<at name="properties"> |
|
235 |
<object classname="com.jeta.forms.store.support.PropertyMap"> |
|
236 |
<at name="border"> |
|
237 |
<object classname="com.jeta.forms.store.properties.CompoundBorderProperty"> |
|
238 |
<super classname="com.jeta.forms.store.properties.BorderProperty"> |
|
239 |
<at name="name">border</at> |
|
240 |
</super> |
|
241 |
<at name="borders"> |
|
242 |
<object classname="java.util.LinkedList"> |
|
243 |
<item > |
|
244 |
<at name="value"> |
|
245 |
<object classname="com.jeta.forms.store.properties.DefaultBorderProperty"> |
|
246 |
<super classname="com.jeta.forms.store.properties.BorderProperty"> |
|
247 |
<at name="name">border</at> |
|
248 |
</super> |
|
249 |
</object> |
|
250 |
</at> |
|
251 |
</item> |
|
252 |
</object> |
|
253 |
</at> |
|
254 |
</object> |
|
255 |
</at> |
|
256 |
<at name="name">lblOffline</at> |
|
257 |
<at name="width">75</at> |
|
258 |
<at name="text">_Offline</at> |
|
259 |
<at name="fill"> |
|
260 |
<object classname="com.jeta.forms.store.properties.effects.PaintProperty"> |
|
261 |
<at name="name">fill</at> |
|
262 |
</object> |
|
263 |
</at> |
|
264 |
<at name="height">16</at> |
|
265 |
</object> |
|
266 |
</at> |
|
267 |
</object> |
|
268 |
</at> |
|
269 |
</object> |
|
270 |
</at> |
|
271 |
</item> |
|
272 |
<item > |
|
273 |
<at name="value"> |
|
274 |
<object classname="com.jeta.forms.store.memento.BeanMemento"> |
|
275 |
<super classname="com.jeta.forms.store.memento.ComponentMemento"> |
|
276 |
<at name="cellconstraints"> |
|
277 |
<object classname="com.jeta.forms.store.memento.CellConstraintsMemento"> |
|
278 |
<at name="column">4</at> |
|
279 |
<at name="row">4</at> |
|
280 |
<at name="colspan">1</at> |
|
281 |
<at name="rowspan">1</at> |
|
282 |
<at name="halign">default</at> |
|
283 |
<at name="valign">default</at> |
|
284 |
<at name="insets" object="insets">0,0,0,0</at> |
|
285 |
</object> |
|
286 |
</at> |
|
287 |
<at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at> |
|
288 |
</super> |
|
289 |
<at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at> |
|
290 |
<at name="beanclass">javax.swing.JCheckBox</at> |
|
291 |
<at name="beanproperties"> |
|
292 |
<object classname="com.jeta.forms.store.memento.PropertiesMemento"> |
|
293 |
<at name="classname">javax.swing.JCheckBox</at> |
|
294 |
<at name="properties"> |
|
295 |
<object classname="com.jeta.forms.store.support.PropertyMap"> |
|
296 |
<at name="border"> |
|
297 |
<object classname="com.jeta.forms.store.properties.CompoundBorderProperty"> |
|
298 |
<super classname="com.jeta.forms.store.properties.BorderProperty"> |
|
299 |
<at name="name">border</at> |
|
300 |
</super> |
|
301 |
<at name="borders"> |
|
302 |
<object classname="java.util.LinkedList"> |
|
303 |
<item > |
|
304 |
<at name="value"> |
|
305 |
<object classname="com.jeta.forms.store.properties.DefaultBorderProperty"> |
|
306 |
<super classname="com.jeta.forms.store.properties.BorderProperty"> |
|
307 |
<at name="name">border</at> |
|
308 |
</super> |
|
309 |
</object> |
|
310 |
</at> |
|
311 |
</item> |
|
312 |
</object> |
|
313 |
</at> |
|
314 |
</object> |
|
315 |
</at> |
|
316 |
<at name="name">chkOffline</at> |
|
317 |
<at name="width">1483</at> |
|
318 |
<at name="height">15</at> |
|
319 |
</object> |
|
320 |
</at> |
|
321 |
</object> |
|
322 |
</at> |
|
323 |
</object> |
|
324 |
</at> |
|
325 |
</item> |
|
326 |
</object> |
|
327 |
</at> |
|
328 |
<at name="properties"> |
|
329 |
<object classname="com.jeta.forms.store.memento.PropertiesMemento"> |
|
330 |
<at name="classname">com.jeta.forms.gui.form.GridView</at> |
|
331 |
<at name="properties"> |
|
332 |
<object classname="com.jeta.forms.store.support.PropertyMap"> |
|
333 |
<at name="border"> |
|
334 |
<object classname="com.jeta.forms.store.properties.CompoundBorderProperty"> |
|
335 |
<super classname="com.jeta.forms.store.properties.BorderProperty"> |
|
336 |
<at name="name">border</at> |
|
337 |
</super> |
|
338 |
<at name="borders"> |
|
339 |
<object classname="java.util.LinkedList"/> |
|
340 |
</at> |
|
341 |
</object> |
|
342 |
</at> |
|
343 |
<at name="name"/> |
|
344 |
<at name="fill"> |
|
345 |
<object classname="com.jeta.forms.store.properties.effects.PaintProperty"> |
|
346 |
<at name="name">fill</at> |
|
347 |
</object> |
|
348 |
</at> |
|
349 |
<at name="scollBars"> |
|
350 |
<object classname="com.jeta.forms.store.properties.ScrollBarsProperty"> |
|
351 |
<at name="name">scollBars</at> |
|
352 |
<at name="verticalpolicy">21</at> |
|
353 |
<at name="horizontalpolicy">31</at> |
|
354 |
<at name="border"> |
|
355 |
<object classname="com.jeta.forms.store.properties.CompoundBorderProperty"> |
|
356 |
<super classname="com.jeta.forms.store.properties.BorderProperty"> |
|
357 |
<at name="name">border</at> |
|
358 |
</super> |
|
359 |
<at name="borders"> |
|
360 |
<object classname="java.util.LinkedList"> |
|
361 |
<item > |
|
362 |
<at name="value"> |
|
363 |
<object classname="com.jeta.forms.store.properties.DefaultBorderProperty"> |
|
364 |
<super classname="com.jeta.forms.store.properties.BorderProperty"> |
|
365 |
<at name="name">border</at> |
|
366 |
</super> |
|
367 |
</object> |
|
368 |
</at> |
|
369 |
</item> |
|
370 |
</object> |
|
371 |
</at> |
|
372 |
</object> |
|
373 |
</at> |
|
374 |
</object> |
|
375 |
</at> |
|
376 |
</object> |
|
377 |
</at> |
|
378 |
</object> |
|
379 |
</at> |
|
380 |
<at name="cellpainters"> |
|
381 |
<object classname="com.jeta.forms.store.support.Matrix"> |
|
382 |
<at name="rows"> |
|
383 |
<object classname="[Ljava.lang.Object;" size="5"> |
|
384 |
<at name="item" index="0"> |
|
385 |
<object classname="[Ljava.lang.Object;" size="7"/> |
|
386 |
</at> |
|
387 |
<at name="item" index="1"> |
|
388 |
<object classname="[Ljava.lang.Object;" size="7"/> |
|
389 |
</at> |
|
390 |
<at name="item" index="2"> |
|
391 |
<object classname="[Ljava.lang.Object;" size="7"/> |
|
392 |
</at> |
|
393 |
<at name="item" index="3"> |
|
394 |
<object classname="[Ljava.lang.Object;" size="7"/> |
|
395 |
</at> |
|
396 |
<at name="item" index="4"> |
|
397 |
<object classname="[Ljava.lang.Object;" size="7"/> |
|
398 |
</at> |
|
399 |
</object> |
|
400 |
</at> |
|
401 |
</object> |
|
402 |
</at> |
|
403 |
<at name="rowgroups"> |
|
404 |
<object classname="com.jeta.forms.store.memento.FormGroupSet"> |
|
405 |
<at name="groups"> |
|
406 |
<object classname="java.util.HashMap"/> |
|
407 |
</at> |
|
408 |
</object> |
|
409 |
</at> |
|
410 |
<at name="colgroups"> |
|
411 |
<object classname="com.jeta.forms.store.memento.FormGroupSet"> |
|
412 |
<at name="groups"> |
|
413 |
<object classname="java.util.HashMap"/> |
|
414 |
</at> |
|
415 |
</object> |
|
416 |
</at> |
|
417 |
</object> |
|
418 |
</at> |
|
419 |
</object> |
org.gvsig.vcsgis/trunk/org.gvsig.vcsgis/org.gvsig.vcsgis.swing/org.gvsig.vcsgis.swing.impl/src/main/java/org/gvsig/vcsgis/swing/impl/setWorkingCopyOffline/VCSGisJSetWorkingCopyOfflineView.java | ||
---|---|---|
1 |
package org.gvsig.vcsgis.swing.impl.setWorkingCopyOffline; |
|
2 |
|
|
3 |
import com.jeta.open.i18n.I18NUtils; |
|
4 |
import com.jgoodies.forms.layout.CellConstraints; |
|
5 |
import com.jgoodies.forms.layout.FormLayout; |
|
6 |
import java.awt.BorderLayout; |
|
7 |
import java.awt.ComponentOrientation; |
|
8 |
import java.awt.Container; |
|
9 |
import java.awt.Dimension; |
|
10 |
import javax.swing.Box; |
|
11 |
import javax.swing.ImageIcon; |
|
12 |
import javax.swing.JButton; |
|
13 |
import javax.swing.JCheckBox; |
|
14 |
import javax.swing.JComboBox; |
|
15 |
import javax.swing.JFrame; |
|
16 |
import javax.swing.JLabel; |
|
17 |
import javax.swing.JPanel; |
|
18 |
import javax.swing.border.EmptyBorder; |
|
19 |
|
|
20 |
|
|
21 |
public class VCSGisJSetWorkingCopyOfflineView extends JPanel |
|
22 |
{ |
|
23 |
JLabel lblWorkspace = new JLabel(); |
|
24 |
JComboBox cboWorkspaces = new JComboBox(); |
|
25 |
JButton btnInitWorkspace = new JButton(); |
|
26 |
JLabel lblOffline = new JLabel(); |
|
27 |
JCheckBox chkOffline = new JCheckBox(); |
|
28 |
|
|
29 |
/** |
|
30 |
* Default constructor |
|
31 |
*/ |
|
32 |
public VCSGisJSetWorkingCopyOfflineView() |
|
33 |
{ |
|
34 |
initializePanel(); |
|
35 |
} |
|
36 |
|
|
37 |
/** |
|
38 |
* Adds fill components to empty cells in the first row and first column of the grid. |
|
39 |
* This ensures that the grid spacing will be the same as shown in the designer. |
|
40 |
* @param cols an array of column indices in the first row where fill components should be added. |
|
41 |
* @param rows an array of row indices in the first column where fill components should be added. |
|
42 |
*/ |
|
43 |
void addFillComponents( Container panel, int[] cols, int[] rows ) |
|
44 |
{ |
|
45 |
Dimension filler = new Dimension(10,10); |
|
46 |
|
|
47 |
boolean filled_cell_11 = false; |
|
48 |
CellConstraints cc = new CellConstraints(); |
|
49 |
if ( cols.length > 0 && rows.length > 0 ) |
|
50 |
{ |
|
51 |
if ( cols[0] == 1 && rows[0] == 1 ) |
|
52 |
{ |
|
53 |
/** add a rigid area */ |
|
54 |
panel.add( Box.createRigidArea( filler ), cc.xy(1,1) ); |
|
55 |
filled_cell_11 = true; |
|
56 |
} |
|
57 |
} |
|
58 |
|
|
59 |
for( int index = 0; index < cols.length; index++ ) |
|
60 |
{ |
|
61 |
if ( cols[index] == 1 && filled_cell_11 ) |
|
62 |
{ |
|
63 |
continue; |
|
64 |
} |
|
65 |
panel.add( Box.createRigidArea( filler ), cc.xy(cols[index],1) ); |
|
66 |
} |
|
67 |
|
|
68 |
for( int index = 0; index < rows.length; index++ ) |
|
69 |
{ |
|
70 |
if ( rows[index] == 1 && filled_cell_11 ) |
|
71 |
{ |
|
72 |
continue; |
|
73 |
} |
|
74 |
panel.add( Box.createRigidArea( filler ), cc.xy(1,rows[index]) ); |
|
75 |
} |
|
76 |
|
|
77 |
} |
|
78 |
|
|
79 |
/** |
|
80 |
* Helper method to load an image file from the CLASSPATH |
|
81 |
* @param imageName the package and name of the file to load relative to the CLASSPATH |
|
82 |
* @return an ImageIcon instance with the specified image file |
|
83 |
* @throws IllegalArgumentException if the image resource cannot be loaded. |
|
84 |
*/ |
|
85 |
public ImageIcon loadImage( String imageName ) |
|
86 |
{ |
|
87 |
try |
|
88 |
{ |
|
89 |
ClassLoader classloader = getClass().getClassLoader(); |
|
90 |
java.net.URL url = classloader.getResource( imageName ); |
|
91 |
if ( url != null ) |
|
92 |
{ |
|
93 |
ImageIcon icon = new ImageIcon( url ); |
|
94 |
return icon; |
|
95 |
} |
|
96 |
} |
|
97 |
catch( Exception e ) |
|
98 |
{ |
|
99 |
e.printStackTrace(); |
|
100 |
} |
|
101 |
throw new IllegalArgumentException( "Unable to load image: " + imageName ); |
|
102 |
} |
|
103 |
|
|
104 |
/** |
|
105 |
* Method for recalculating the component orientation for |
|
106 |
* right-to-left Locales. |
|
107 |
* @param orientation the component orientation to be applied |
|
108 |
*/ |
|
109 |
public void applyComponentOrientation( ComponentOrientation orientation ) |
|
110 |
{ |
|
111 |
// Not yet implemented... |
|
112 |
// I18NUtils.applyComponentOrientation(this, orientation); |
|
113 |
super.applyComponentOrientation(orientation); |
|
114 |
} |
|
115 |
|
|
116 |
public JPanel createPanel() |
|
117 |
{ |
|
118 |
JPanel jpanel1 = new JPanel(); |
|
119 |
FormLayout formlayout1 = new FormLayout("FILL:4DLU:NONE,FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:DEFAULT:GROW(1.0),FILL:4DLU:NONE,FILL:DEFAULT:NONE,FILL:4DLU:NONE","CENTER:2DLU:NONE,CENTER:DEFAULT:NONE,CENTER:2DLU:NONE,CENTER:DEFAULT:NONE,CENTER:2DLU:NONE"); |
|
120 |
CellConstraints cc = new CellConstraints(); |
|
121 |
jpanel1.setLayout(formlayout1); |
|
122 |
|
|
123 |
lblWorkspace.setName("lblWorkspace"); |
|
124 |
lblWorkspace.setText("_Workingcopy"); |
|
125 |
jpanel1.add(lblWorkspace,cc.xy(2,2)); |
|
126 |
|
|
127 |
cboWorkspaces.setName("cboWorkspaces"); |
|
128 |
jpanel1.add(cboWorkspaces,cc.xy(4,2)); |
|
129 |
|
|
130 |
btnInitWorkspace.setActionCommand("..."); |
|
131 |
btnInitWorkspace.setName("btnInitWorkspace"); |
|
132 |
btnInitWorkspace.setText("..."); |
|
133 |
EmptyBorder emptyborder1 = new EmptyBorder(2,2,2,2); |
|
134 |
btnInitWorkspace.setBorder(emptyborder1); |
|
135 |
jpanel1.add(btnInitWorkspace,cc.xy(6,2)); |
|
136 |
|
|
137 |
lblOffline.setName("lblOffline"); |
|
138 |
lblOffline.setText("_Offline"); |
|
139 |
jpanel1.add(lblOffline,cc.xy(2,4)); |
|
140 |
|
|
141 |
chkOffline.setName("chkOffline"); |
|
142 |
jpanel1.add(chkOffline,cc.xy(4,4)); |
|
143 |
|
|
144 |
addFillComponents(jpanel1,new int[]{ 1,2,3,4,5,6,7 },new int[]{ 1,2,3,4,5 }); |
|
145 |
return jpanel1; |
|
146 |
} |
|
147 |
|
|
148 |
/** |
|
149 |
* Initializer |
|
150 |
*/ |
|
151 |
protected void initializePanel() |
|
152 |
{ |
|
153 |
setLayout(new BorderLayout()); |
|
154 |
add(createPanel(), BorderLayout.CENTER); |
|
155 |
} |
|
156 |
|
|
157 |
|
|
158 |
} |
org.gvsig.vcsgis/trunk/org.gvsig.vcsgis/org.gvsig.vcsgis.swing/org.gvsig.vcsgis.swing.impl/src/main/java/org/gvsig/vcsgis/swing/impl/setWorkingCopyOffline/VCSGisJSetWorkingCopyOfflineImpl.java | ||
---|---|---|
1 |
/* |
|
2 |
* gvSIG. Desktop Geographic Information System. |
|
3 |
* |
|
4 |
* Copyright (C) 2007-2020 gvSIG Association. |
|
5 |
* |
|
6 |
* This program is free software; you can redistribute it and/or |
|
7 |
* modify it under the terms of the GNU General Public License |
|
8 |
* as published by the Free Software Foundation; either version 3 |
|
9 |
* of the License, or (at your option) any later version. |
|
10 |
* |
|
11 |
* This program is distributed in the hope that it will be useful, |
|
12 |
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
13 |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|
14 |
* GNU General Public License for more details. |
|
15 |
* |
|
16 |
* You should have received a copy of the GNU General Public License |
|
17 |
* along with this program. If not, see <https://www.gnu.org/licenses/>. |
|
18 |
* |
|
19 |
* For any additional information, do not hesitate to contact us |
|
20 |
* at info AT gvsig.com, or visit our website www.gvsig.com. |
|
21 |
*/ |
|
22 |
package org.gvsig.vcsgis.swing.impl.setWorkingCopyOffline; |
|
23 |
|
|
24 |
import javax.swing.ImageIcon; |
|
25 |
import javax.swing.JComponent; |
|
26 |
import javax.swing.SwingUtilities; |
|
27 |
import javax.swing.event.ChangeEvent; |
|
28 |
import org.apache.commons.lang3.BooleanUtils; |
|
29 |
import org.gvsig.tools.swing.api.Component; |
|
30 |
import org.gvsig.tools.swing.api.ToolsSwingLocator; |
|
31 |
import org.gvsig.tools.swing.api.ToolsSwingManager; |
|
32 |
import org.gvsig.tools.swing.api.ToolsSwingUtils; |
|
33 |
import org.gvsig.tools.swing.api.pickercontroller.PickerController; |
|
34 |
import org.gvsig.tools.swing.api.task.TaskStatusSwingManager; |
|
35 |
import org.gvsig.tools.swing.api.windowmanager.Dialog; |
|
36 |
import org.gvsig.tools.swing.api.windowmanager.WindowManager_v2; |
|
37 |
import org.gvsig.vcsgis.lib.workspace.VCSGisWorkspace; |
|
38 |
import org.gvsig.vcsgis.swing.VCSGisSwingLocator; |
|
39 |
import org.gvsig.vcsgis.swing.VCSGisSwingManager; |
|
40 |
import org.gvsig.vcsgis.swing.VCSGisSwingServices; |
|
41 |
import static org.gvsig.vcsgis.swing.impl.VCSGisSwingCommons.notInSwingThreadInvokeLater; |
|
42 |
import org.gvsig.vcsgis.swing.impl.VCSGisSwingManagerImpl; |
|
43 |
import org.slf4j.LoggerFactory; |
|
44 |
import org.gvsig.vcsgis.swing.VCSGisJSetWorkingCopyOffline; |
|
45 |
|
|
46 |
/** |
|
47 |
* |
|
48 |
* @author gvSIG Team |
|
49 |
*/ |
|
50 |
@SuppressWarnings("UseSpecificCatch") |
|
51 |
public class VCSGisJSetWorkingCopyOfflineImpl extends VCSGisJSetWorkingCopyOfflineView |
|
52 |
implements Component, VCSGisJSetWorkingCopyOffline |
|
53 |
{ |
|
54 |
|
|
55 |
private static final org.slf4j.Logger LOGGER = LoggerFactory.getLogger(VCSGisJSetWorkingCopyOfflineImpl.class); |
|
56 |
|
|
57 |
private Dialog dialog; |
|
58 |
|
|
59 |
private PickerController<VCSGisWorkspace> workspacePicker; |
|
60 |
|
|
61 |
public VCSGisJSetWorkingCopyOfflineImpl() { |
|
62 |
initComponents(); |
|
63 |
} |
|
64 |
|
|
65 |
public VCSGisJSetWorkingCopyOfflineImpl(VCSGisWorkspace workspace, String model) { |
|
66 |
this(); |
|
67 |
SwingUtilities.invokeLater(() -> { |
|
68 |
workspacePicker.set(workspace); |
|
69 |
}); |
|
70 |
} |
|
71 |
|
|
72 |
private void initComponents() { |
|
73 |
TaskStatusSwingManager taskStatusManager = ToolsSwingLocator.getTaskStatusSwingManager(); |
|
74 |
VCSGisSwingManager swingManager = VCSGisSwingLocator.getVCSGisSwingManager(); |
|
75 |
VCSGisSwingServices services = swingManager.getDefaultServices(); |
|
76 |
|
|
77 |
translate(); |
|
78 |
|
|
79 |
|
|
80 |
this.workspacePicker = swingManager.createWorkspacePickerController( |
|
81 |
cboWorkspaces, |
|
82 |
btnInitWorkspace |
|
83 |
); |
|
84 |
|
|
85 |
this.workspacePicker.addChangeListener((ChangeEvent e) -> { |
|
86 |
doUpdateComponents(); |
|
87 |
}); |
|
88 |
|
|
89 |
ToolsSwingUtils.ensureRowsCols(this, 3, 70); |
|
90 |
|
|
91 |
} |
|
92 |
|
|
93 |
@Override |
|
94 |
public JComponent asJComponent() { |
|
95 |
return this; |
|
96 |
} |
|
97 |
|
|
98 |
@Override |
|
99 |
public void setDialog(Dialog dialog) { |
|
100 |
this.dialog = dialog; |
|
101 |
this.doUpdateComponents(); |
|
102 |
} |
|
103 |
|
|
104 |
|
|
105 |
@Override |
|
106 |
public VCSGisWorkspace getWorkspace() { |
|
107 |
return this.workspacePicker.get(); |
|
108 |
} |
|
109 |
|
|
110 |
private void doUpdateComponents() { |
|
111 |
if (notInSwingThreadInvokeLater(this::doUpdateComponents)) { |
|
112 |
return; |
|
113 |
} |
|
114 |
VCSGisWorkspace workspace = getWorkspace(); |
|
115 |
boolean canConnect = workspace != null; |
|
116 |
if (dialog != null) { |
|
117 |
this.dialog.setButtonEnabled(WindowManager_v2.BUTTON_OK, canConnect); |
|
118 |
} |
|
119 |
} |
|
120 |
|
|
121 |
@Override |
|
122 |
public void setOffline() { |
|
123 |
final VCSGisWorkspace workspace = this.getWorkspace(); |
|
124 |
boolean offline = this.chkOffline.isSelected(); |
|
125 |
workspace.setOffline(offline); |
|
126 |
workspace.setConfigValue("OFFLINE", BooleanUtils.toStringTrueFalse(offline)); |
|
127 |
} |
|
128 |
|
|
129 |
private void translate() { |
|
130 |
ToolsSwingManager swingManager = ToolsSwingLocator.getToolsSwingManager(); |
|
131 |
swingManager.translate(this.lblWorkspace); |
|
132 |
swingManager.translate(this.lblOffline); |
|
133 |
} |
|
134 |
|
|
135 |
@Override |
|
136 |
public ImageIcon loadImage(String imageName) { |
|
137 |
return VCSGisSwingManagerImpl.loadImage(imageName); |
|
138 |
} |
|
139 |
|
|
140 |
@Override |
|
141 |
public boolean isProcessing() { |
|
142 |
return false; |
|
143 |
} |
|
144 |
|
|
145 |
} |
org.gvsig.vcsgis/trunk/org.gvsig.vcsgis/org.gvsig.vcsgis.swing/org.gvsig.vcsgis.swing.impl/src/main/java/org/gvsig/vcsgis/swing/impl/VCSGisSwingManagerImpl.java | ||
---|---|---|
90 | 90 |
import org.gvsig.vcsgis.swing.impl.repoEntitiyFeatureTypeEditor.RepositoryEntityFeatureTypeEditorImpl; |
91 | 91 |
import org.gvsig.vcsgis.swing.impl.resourceTable.VCSGisJCreateResourceTableImpl; |
92 | 92 |
import org.gvsig.vcsgis.swing.impl.revisions.VCSGisJRevisionsImpl; |
93 |
import org.gvsig.vcsgis.swing.impl.setWorkingCopyOffline.VCSGisJSetWorkingCopyOfflineImpl; |
|
93 | 94 |
import org.gvsig.vcsgis.swing.impl.showServerTableForm.VCSGisJShowServerTableFormImpl; |
94 | 95 |
import org.slf4j.Logger; |
95 | 96 |
import org.slf4j.LoggerFactory; |
97 |
import org.gvsig.vcsgis.swing.VCSGisJSetWorkingCopyOffline; |
|
96 | 98 |
|
97 | 99 |
/** |
98 | 100 |
* @author gvSIG Team |
... | ... | |
397 | 399 |
public VCSGisJLog createLogPanel() { |
398 | 400 |
return new VCSGisJLogImpl(); |
399 | 401 |
} |
402 |
|
|
403 |
@Override |
|
404 |
public VCSGisJSetWorkingCopyOffline createSetWorkingCopyOfflinePanel() { |
|
405 |
return new VCSGisJSetWorkingCopyOfflineImpl(); |
|
406 |
} |
|
407 |
|
|
408 |
|
|
400 | 409 |
} |
org.gvsig.vcsgis/trunk/org.gvsig.vcsgis/org.gvsig.vcsgis.swing/org.gvsig.vcsgis.swing.api/src/main/java/org/gvsig/vcsgis/swing/VCSGisSwingManager.java | ||
---|---|---|
131 | 131 |
public int getRepositoryEntityFeatureTypeEditorMode(); |
132 | 132 |
|
133 | 133 |
public VCSGisJLog createLogPanel(); |
134 |
|
|
135 |
public VCSGisJSetWorkingCopyOffline createSetWorkingCopyOfflinePanel(); |
|
136 |
|
|
134 | 137 |
} |
org.gvsig.vcsgis/trunk/org.gvsig.vcsgis/org.gvsig.vcsgis.swing/org.gvsig.vcsgis.swing.api/src/main/java/org/gvsig/vcsgis/swing/VCSGisJSetWorkingCopyOffline.java | ||
---|---|---|
1 |
package org.gvsig.vcsgis.swing; |
|
2 |
|
|
3 |
/* |
|
4 |
* gvSIG. Desktop Geographic Information System. |
|
5 |
* |
|
6 |
* Copyright (C) 2007-2020 gvSIG Association. |
|
7 |
* |
|
8 |
* This program is free software; you can redistribute it and/or |
|
9 |
* modify it under the terms of the GNU General Public License |
|
10 |
* as published by the Free Software Foundation; either version 3 |
|
11 |
* of the License, or (at your option) any later version. |
|
12 |
* |
|
13 |
* This program is distributed in the hope that it will be useful, |
|
14 |
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
15 |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|
16 |
* GNU General Public License for more details. |
|
17 |
* |
|
18 |
* You should have received a copy of the GNU General Public License |
|
19 |
* along with this program. If not, see <https://www.gnu.org/licenses/>. |
|
20 |
* |
|
21 |
* For any additional information, do not hesitate to contact us |
|
22 |
* at info AT gvsig.com, or visit our website www.gvsig.com. |
|
23 |
*/ |
|
24 |
|
|
25 |
|
|
26 |
import org.gvsig.vcsgis.lib.workspace.VCSGisWorkspace; |
|
27 |
|
|
28 |
/** |
|
29 |
* |
|
30 |
* @author jjdelcerro |
|
31 |
*/ |
|
32 |
public interface VCSGisJSetWorkingCopyOffline extends VCSGisPanel { |
|
33 |
|
|
34 |
public void setOffline(); |
|
35 |
|
|
36 |
public VCSGisWorkspace getWorkspace(); |
|
37 |
|
|
38 |
} |
org.gvsig.vcsgis/trunk/org.gvsig.vcsgis/org.gvsig.vcsgis.app/org.gvsig.vcsgis.app.mainplugin/src/main/resources-plugin/i18n/text.properties | ||
---|---|---|
363 | 363 |
_Cant_update_table_XtablaX_are_in_edition=No es posible actualizar la tabla ''{0}'', esta en edici\u00f3n. |
364 | 364 |
|
365 | 365 |
_Select_entities_in_use=Seleccionar entidades en uso |
366 |
_VCS_Set_Working_copy_offline=Marcar la copia de trabajo como offline |
|
367 |
_Offline=Desconectada |
org.gvsig.vcsgis/trunk/org.gvsig.vcsgis/org.gvsig.vcsgis.app/org.gvsig.vcsgis.app.mainplugin/src/main/resources-plugin/i18n/text_en.properties | ||
---|---|---|
349 | 349 |
|
350 | 350 |
_Select_entities_in_use=Select entities in use |
351 | 351 |
|
352 |
_VCS_Set_Working_copy_offline=Set working copy offline |
|
353 |
_Offline=Offline |
org.gvsig.vcsgis/trunk/org.gvsig.vcsgis/org.gvsig.vcsgis.app/org.gvsig.vcsgis.app.mainplugin/src/main/resources-plugin/config.xml | ||
---|---|---|
235 | 235 |
accelerator="" |
236 | 236 |
/> |
237 | 237 |
|
238 |
<action |
|
239 |
name="tools-vcsgis-setworkingcopyoffline" |
|
240 |
label="_VCS_Set_Working_copy_offline" |
|
241 |
tooltip="_VCS_Set_Working_copy_offline" |
|
242 |
position="900700103" |
|
243 |
action-command="tools-vcsgis-setworkingcopyoffline" |
|
244 |
icon="tools-vcsgis-setworkingcopyoffline" |
|
245 |
accelerator="" |
|
246 |
/> |
|
238 | 247 |
|
239 |
|
|
240 | 248 |
<menu text="tools/_VCSGis/_Administration/_VCS_Initialize_repository" name="tools-vcsgis-init-server" /> |
249 |
<menu text="tools/_VCSGis/_Administration/_VCS_Set_Working_copy_offline" name="tools-vcsgis-setworkingcopyoffline" /> |
|
241 | 250 |
<!-- |
242 | 251 |
<menu text="tools/_VCSGis/_Administration/_VCS_Registration_workingcopies" name="tools-vcsgis-register-workspace" /> |
243 | 252 |
--> |
org.gvsig.vcsgis/trunk/org.gvsig.vcsgis/org.gvsig.vcsgis.app/org.gvsig.vcsgis.app.mainplugin/src/main/java/org/gvsig/vcsgis/app/VCSGisExtension.java | ||
---|---|---|
79 | 79 |
import org.gvsig.vcsgis.swing.VCSGisJShowServerTableForm; |
80 | 80 |
import org.gvsig.vcsgis.swing.VCSGisSwingLocator; |
81 | 81 |
import org.gvsig.vcsgis.swing.VCSGisSwingManager; |
82 |
import org.gvsig.vcsgis.swing.VCSGisJSetWorkingCopyOffline; |
|
82 | 83 |
|
83 | 84 |
/** |
84 | 85 |
* |
... | ... | |
255 | 256 |
break; |
256 | 257 |
case "tools-vcsgis-repositoryentityfeaturetypeeditor": |
257 | 258 |
showRepositoryEntityFeatureTypeEditorImplDialog(); |
258 |
break; |
|
259 |
break; |
|
260 |
case "tools-vcsgis-setworkingcopyoffline": |
|
261 |
showSetWorkingCopyOfflineDialog(); |
|
259 | 262 |
} |
260 | 263 |
} |
261 | 264 |
|
... | ... | |
767 | 770 |
dialog.show(); |
768 | 771 |
} |
769 | 772 |
|
773 |
private void showSetWorkingCopyOfflineDialog() { |
|
774 |
VCSGisSwingManager swingManager = VCSGisSwingLocator.getVCSGisSwingManager(); |
|
775 |
|
|
776 |
VCSGisDialogInfo dialog = this.dialogsHelper.getOrCreateDialog( |
|
777 |
"SetWorkingCopyOffline", |
|
778 |
swingManager.createSetWorkingCopyOfflinePanel(), |
|
779 |
"_VCS_Set_Working_copy_offline", |
|
780 |
"_VCS_Set_Working_copy_offline", |
|
781 |
"_VCS_Set_Working_copy_offline", |
|
782 |
() -> { |
|
783 |
VCSGisJSetWorkingCopyOffline setWorkingCopyOffline = (VCSGisJSetWorkingCopyOffline) this.dialogsHelper.getDialog("SetWorkingCopyOffline").getPanel(); |
|
784 |
setWorkingCopyOffline.setOffline(); |
|
785 |
} |
|
786 |
); |
|
787 |
dialog.show( |
|
788 |
Collections.singletonMap("align", GridBagConstraints.CENTER) |
|
789 |
); |
|
790 |
} |
|
791 |
|
|
770 | 792 |
@Override |
771 | 793 |
public IPreference[] getPreferencesPages() { |
772 | 794 |
List<IPreference> prefs = new ArrayList<>(); |
Also available in: Unified diff