Statistics
| Revision:

gvsig-projects-pool / org.gvsig.vcsgis / trunk / org.gvsig.vcsgis / org.gvsig.vcsgis.swing / org.gvsig.vcsgis.swing.impl / src / main / java / org / gvsig / vcsgis / swing / impl / changes / VCSGisJChangesView.java @ 3379

History | View | Annotate | Download (28.2 KB)

1
package org.gvsig.vcsgis.swing.impl.changes;
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.JComboBox;
14
import javax.swing.JFrame;
15
import javax.swing.JLabel;
16
import javax.swing.JList;
17
import javax.swing.JPanel;
18
import javax.swing.JProgressBar;
19
import javax.swing.JScrollPane;
20
import javax.swing.JTabbedPane;
21
import javax.swing.JTable;
22
import javax.swing.JTextField;
23
import javax.swing.JTree;
24
import javax.swing.border.EmptyBorder;
25

    
26

    
27
public class VCSGisJChangesView extends JPanel
28
{
29
   JLabel lblWorkspace = new JLabel();
30
   JComboBox cboWorkspace = new JComboBox();
31
   JTabbedPane tabLocalAndRemote = new JTabbedPane();
32
   JTable tblLocalChanges = new JTable();
33
   JButton btnLocalCheckAll = new JButton();
34
   JButton btnLocalUnCheckAll = new JButton();
35
   JButton btnLocalShowForm = new JButton();
36
   JButton btnLocalRefresh = new JButton();
37
   JButton btnLocalCommit = new JButton();
38
   JButton btnLocalRevert = new JButton();
39
   JButton btnLocalZoom = new JButton();
40
   JButton btnLocalCenter = new JButton();
41
   JButton btnLocalCleanHighligthed = new JButton();
42
   JLabel lblLocalEffectiveDate = new JLabel();
43
   JTextField txtLocalEffectiveDate = new JTextField();
44
   JTextField txtLocalComment = new JTextField();
45
   JButton btnLocalEffectiveDate = new JButton();
46
   JLabel lblLocalComment = new JLabel();
47
   JLabel lblLocalChangesCount = new JLabel();
48
   JButton btnLocalCheckAllEntities = new JButton();
49
   JButton btnLocalUnCheckAll1 = new JButton();
50
   JTextField txtLocalTablesFilter = new JTextField();
51
   JButton btnLocalTable = new JButton();
52
   JTree treeLocalTables = new JTree();
53
   JTable tblRemoteChanges = new JTable();
54
   JList lstRemoteTables = new JList();
55
   JLabel lblRemoteChangesCount = new JLabel();
56
   JButton btnRemoteShowForm = new JButton();
57
   JButton btnRemoteCheckAll = new JButton();
58
   JButton btnRemoteUncheckAll = new JButton();
59
   JButton btnRemoteCleanChanges = new JButton();
60
   JButton btnRemoteReloadChanges = new JButton();
61
   JButton btnRemoteMerge = new JButton();
62
   JButton btnRemoteUpdate = new JButton();
63
   JButton btnRemoteZoom = new JButton();
64
   JButton btnRemoteCenter = new JButton();
65
   JButton btnRemoteCleanHighligthed = new JButton();
66
   JButton btnRemoteTablesReload = new JButton();
67
   JButton btnRemoteDownloadChanges = new JButton();
68
   JButton btnRemoteCheckout = new JButton();
69
   JButton btnWorkspace = new JButton();
70
   JLabel lblStatusCaption = new JLabel();
71
   JLabel lblStatusMessages = new JLabel();
72
   JProgressBar pbStatus = new JProgressBar();
73

    
74
   /**
75
    * Default constructor
76
    */
77
   public VCSGisJChangesView()
78
   {
79
      initializePanel();
80
   }
81

    
82
   /**
83
    * Adds fill components to empty cells in the first row and first column of the grid.
84
    * This ensures that the grid spacing will be the same as shown in the designer.
85
    * @param cols an array of column indices in the first row where fill components should be added.
86
    * @param rows an array of row indices in the first column where fill components should be added.
87
    */
88
   void addFillComponents( Container panel, int[] cols, int[] rows )
89
   {
90
      Dimension filler = new Dimension(10,10);
91

    
92
      boolean filled_cell_11 = false;
93
      CellConstraints cc = new CellConstraints();
94
      if ( cols.length > 0 && rows.length > 0 )
95
      {
96
         if ( cols[0] == 1 && rows[0] == 1 )
97
         {
98
            /** add a rigid area  */
99
            panel.add( Box.createRigidArea( filler ), cc.xy(1,1) );
100
            filled_cell_11 = true;
101
         }
102
      }
103

    
104
      for( int index = 0; index < cols.length; index++ )
105
      {
106
         if ( cols[index] == 1 && filled_cell_11 )
107
         {
108
            continue;
109
         }
110
         panel.add( Box.createRigidArea( filler ), cc.xy(cols[index],1) );
111
      }
112

    
113
      for( int index = 0; index < rows.length; index++ )
114
      {
115
         if ( rows[index] == 1 && filled_cell_11 )
116
         {
117
            continue;
118
         }
119
         panel.add( Box.createRigidArea( filler ), cc.xy(1,rows[index]) );
120
      }
121

    
122
   }
123

    
124
   /**
125
    * Helper method to load an image file from the CLASSPATH
126
    * @param imageName the package and name of the file to load relative to the CLASSPATH
127
    * @return an ImageIcon instance with the specified image file
128
    * @throws IllegalArgumentException if the image resource cannot be loaded.
129
    */
130
   public ImageIcon loadImage( String imageName )
131
   {
132
      try
133
      {
134
         ClassLoader classloader = getClass().getClassLoader();
135
         java.net.URL url = classloader.getResource( imageName );
136
         if ( url != null )
137
         {
138
            ImageIcon icon = new ImageIcon( url );
139
            return icon;
140
         }
141
      }
142
      catch( Exception e )
143
      {
144
         e.printStackTrace();
145
      }
146
      throw new IllegalArgumentException( "Unable to load image: " + imageName );
147
   }
148

    
149
   /**
150
    * Method for recalculating the component orientation for 
151
    * right-to-left Locales.
152
    * @param orientation the component orientation to be applied
153
    */
154
   public void applyComponentOrientation( ComponentOrientation orientation )
155
   {
156
      // Not yet implemented...
157
      // I18NUtils.applyComponentOrientation(this, orientation);
158
      super.applyComponentOrientation(orientation);
159
   }
160

    
161
   public JPanel createPanel()
162
   {
163
      JPanel jpanel1 = new JPanel();
164
      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,FILL:DEFAULT:GROW(1.0),CENTER:2DLU:NONE,CENTER:DEFAULT:NONE,CENTER:2DLU:NONE");
165
      CellConstraints cc = new CellConstraints();
166
      jpanel1.setLayout(formlayout1);
167

    
168
      lblWorkspace.setName("lblWorkspace");
169
      lblWorkspace.setText("_Working_copy");
170
      jpanel1.add(lblWorkspace,cc.xy(2,2));
171

    
172
      cboWorkspace.setName("cboWorkspace");
173
      jpanel1.add(cboWorkspace,cc.xy(4,2));
174

    
175
      tabLocalAndRemote.setName("tabLocalAndRemote");
176
      tabLocalAndRemote.addTab("_Working_copy",loadImage("datos/devel/org.gvsig.vcsgis/org.gvsig.vcsgis.swing/org.gvsig.vcsgis.swing.impl/src/main/resources/org/gvsig/vcsgis/swing/impl/images/vcsgis-show-local-changes.png"),createPanel1());
177
      tabLocalAndRemote.addTab("_Repository",loadImage("datos/devel/org.gvsig.vcsgis/org.gvsig.vcsgis.swing/org.gvsig.vcsgis.swing.impl/src/main/resources/org/gvsig/vcsgis/swing/impl/images/vcsgis-show-remote-changes.png"),createPanel6());
178
      jpanel1.add(tabLocalAndRemote,cc.xywh(2,4,5,1));
179

    
180
      btnWorkspace.setActionCommand("...");
181
      btnWorkspace.setName("btnWorkspace");
182
      btnWorkspace.setOpaque(false);
183
      btnWorkspace.setText("...");
184
      EmptyBorder emptyborder1 = new EmptyBorder(2,2,2,2);
185
      btnWorkspace.setBorder(emptyborder1);
186
      jpanel1.add(btnWorkspace,cc.xy(6,2));
187

    
188
      jpanel1.add(createPanel9(),cc.xywh(2,6,5,1));
189
      addFillComponents(jpanel1,new int[]{ 1,2,3,4,5,6,7 },new int[]{ 1,2,3,4,5,6,7 });
190
      return jpanel1;
191
   }
192

    
193
   public JPanel createPanel1()
194
   {
195
      JPanel jpanel1 = new JPanel();
196
      FormLayout formlayout1 = new FormLayout("FILL:4DLU:NONE,FILL:DEFAULT:GROW(0.2),FILL:4DLU:NONE,FILL:DEFAULT:GROW(1.0),FILL:4DLU:NONE","CENTER:2DLU:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:2DLU:NONE,FILL:DEFAULT:GROW(1.0),CENTER:DEFAULT:NONE,CENTER:2DLU:NONE,CENTER:DEFAULT:NONE,CENTER:2DLU:NONE");
197
      CellConstraints cc = new CellConstraints();
198
      jpanel1.setLayout(formlayout1);
199

    
200
      tblLocalChanges.setName("tblLocalChanges");
201
      JScrollPane jscrollpane1 = new JScrollPane();
202
      jscrollpane1.setViewportView(tblLocalChanges);
203
      jscrollpane1.setVerticalScrollBarPolicy(JScrollPane.VERTICAL_SCROLLBAR_AS_NEEDED);
204
      jscrollpane1.setHorizontalScrollBarPolicy(JScrollPane.HORIZONTAL_SCROLLBAR_AS_NEEDED);
205
      jpanel1.add(jscrollpane1,cc.xy(4,5));
206

    
207
      jpanel1.add(createPanel2(),cc.xy(4,3));
208
      jpanel1.add(createPanel3(),cc.xywh(2,8,3,1));
209
      lblLocalChangesCount.setName("lblLocalChangesCount");
210
      lblLocalChangesCount.setText("0");
211
      lblLocalChangesCount.setHorizontalAlignment(JLabel.RIGHT);
212
      jpanel1.add(lblLocalChangesCount,cc.xywh(2,6,3,1));
213

    
214
      jpanel1.add(createPanel4(),cc.xy(2,3));
215
      jpanel1.add(createPanel5(),cc.xy(2,5));
216
      addFillComponents(jpanel1,new int[]{ 1,2,3,4,5 },new int[]{ 1,2,3,4,5,6,7,8,9 });
217
      return jpanel1;
218
   }
219

    
220
   public JPanel createPanel2()
221
   {
222
      JPanel jpanel1 = new JPanel();
223
      FormLayout formlayout1 = new FormLayout("FILL:DEFAULT:NONE,FILL:DEFAULT:NONE,FILL:DEFAULT:GROW(1.0),FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:DEFAULT:NONE,FILL:8DLU:NONE,FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:DEFAULT:NONE","CENTER:DEFAULT:NONE");
224
      CellConstraints cc = new CellConstraints();
225
      jpanel1.setLayout(formlayout1);
226

    
227
      btnLocalCheckAll.setActionCommand("...");
228
      btnLocalCheckAll.setEnabled(false);
229
      btnLocalCheckAll.setIcon(loadImage("src/main/resources/org/gvsig/vcsgis/swing/impl/images/common-check-on.png"));
230
      btnLocalCheckAll.setName("btnLocalCheckAll");
231
      btnLocalCheckAll.setOpaque(false);
232
      btnLocalCheckAll.setToolTipText("_Select_all");
233
      EmptyBorder emptyborder1 = new EmptyBorder(1,1,1,1);
234
      btnLocalCheckAll.setBorder(emptyborder1);
235
      jpanel1.add(btnLocalCheckAll,cc.xy(1,1));
236

    
237
      btnLocalUnCheckAll.setActionCommand("...");
238
      btnLocalUnCheckAll.setEnabled(false);
239
      btnLocalUnCheckAll.setIcon(loadImage("src/main/resources/org/gvsig/vcsgis/swing/impl/images/common-check-off.png"));
240
      btnLocalUnCheckAll.setName("btnLocalUnCheckAll");
241
      btnLocalUnCheckAll.setOpaque(false);
242
      btnLocalUnCheckAll.setToolTipText("_Unselect_all");
243
      EmptyBorder emptyborder2 = new EmptyBorder(1,1,1,1);
244
      btnLocalUnCheckAll.setBorder(emptyborder2);
245
      jpanel1.add(btnLocalUnCheckAll,cc.xy(2,1));
246

    
247
      btnLocalShowForm.setActionCommand("...");
248
      btnLocalShowForm.setIcon(loadImage("src/main/resources/org/gvsig/vcsgis/swing/impl/images/common-showform.png"));
249
      btnLocalShowForm.setName("btnLocalShowForm");
250
      btnLocalShowForm.setOpaque(false);
251
      btnLocalShowForm.setToolTipText("_Show_form");
252
      EmptyBorder emptyborder3 = new EmptyBorder(2,2,2,2);
253
      btnLocalShowForm.setBorder(emptyborder3);
254
      jpanel1.add(btnLocalShowForm,cc.xy(16,1));
255

    
256
      JLabel jlabel1 = new JLabel();
257
      jpanel1.add(jlabel1,cc.xy(3,1));
258

    
259
      btnLocalRefresh.setActionCommand("...");
260
      btnLocalRefresh.setIcon(loadImage("src/main/resources/org/gvsig/vcsgis/swing/impl/images/vcsgis-refresh-status.png"));
261
      btnLocalRefresh.setName("btnLocalRefresh");
262
      btnLocalRefresh.setOpaque(false);
263
      btnLocalRefresh.setToolTipText("_Refresh");
264
      EmptyBorder emptyborder4 = new EmptyBorder(2,2,2,2);
265
      btnLocalRefresh.setBorder(emptyborder4);
266
      jpanel1.add(btnLocalRefresh,cc.xy(4,1));
267

    
268
      btnLocalCommit.setActionCommand("...");
269
      btnLocalCommit.setIcon(loadImage("src/main/resources/org/gvsig/vcsgis/swing/impl/images/vcsgis-commit-all.png"));
270
      btnLocalCommit.setName("btnLocalCommit");
271
      btnLocalCommit.setOpaque(false);
272
      btnLocalCommit.setToolTipText("_Commit");
273
      EmptyBorder emptyborder5 = new EmptyBorder(2,2,2,2);
274
      btnLocalCommit.setBorder(emptyborder5);
275
      jpanel1.add(btnLocalCommit,cc.xy(8,1));
276

    
277
      btnLocalRevert.setActionCommand("...");
278
      btnLocalRevert.setEnabled(false);
279
      btnLocalRevert.setIcon(loadImage("src/main/resources/org/gvsig/vcsgis/swing/impl/images/vcsgis-revert.png"));
280
      btnLocalRevert.setName("btnLocalRevert");
281
      btnLocalRevert.setOpaque(false);
282
      btnLocalRevert.setToolTipText("_Revert");
283
      EmptyBorder emptyborder6 = new EmptyBorder(2,2,2,2);
284
      btnLocalRevert.setBorder(emptyborder6);
285
      jpanel1.add(btnLocalRevert,cc.xy(6,1));
286

    
287
      btnLocalZoom.setActionCommand("...");
288
      btnLocalZoom.setEnabled(false);
289
      btnLocalZoom.setIcon(loadImage("src/main/resources/org/gvsig/vcsgis/swing/impl/images/vcsgis-zoom-context.png"));
290
      btnLocalZoom.setName("btnLocalZoom");
291
      btnLocalZoom.setOpaque(false);
292
      btnLocalZoom.setToolTipText("_Zoom");
293
      EmptyBorder emptyborder7 = new EmptyBorder(2,2,2,2);
294
      btnLocalZoom.setBorder(emptyborder7);
295
      jpanel1.add(btnLocalZoom,cc.xy(12,1));
296

    
297
      btnLocalCenter.setActionCommand("...");
298
      btnLocalCenter.setEnabled(false);
299
      btnLocalCenter.setIcon(loadImage("src/main/resources/org/gvsig/vcsgis/swing/impl/images/vcsgis-center-context.png"));
300
      btnLocalCenter.setName("btnLocalCenter");
301
      btnLocalCenter.setOpaque(false);
302
      btnLocalCenter.setToolTipText("_Center");
303
      EmptyBorder emptyborder8 = new EmptyBorder(2,2,2,2);
304
      btnLocalCenter.setBorder(emptyborder8);
305
      jpanel1.add(btnLocalCenter,cc.xy(10,1));
306

    
307
      btnLocalCleanHighligthed.setActionCommand("...");
308
      btnLocalCleanHighligthed.setEnabled(false);
309
      btnLocalCleanHighligthed.setIcon(loadImage("src/main/resources/org/gvsig/vcsgis/swing/impl/images/vcsgis-clean-highlighted.png"));
310
      btnLocalCleanHighligthed.setName("btnLocalCleanHighligthed");
311
      btnLocalCleanHighligthed.setOpaque(false);
312
      btnLocalCleanHighligthed.setToolTipText("_Clean_highlighted");
313
      EmptyBorder emptyborder9 = new EmptyBorder(2,2,2,2);
314
      btnLocalCleanHighligthed.setBorder(emptyborder9);
315
      jpanel1.add(btnLocalCleanHighligthed,cc.xy(14,1));
316

    
317
      addFillComponents(jpanel1,new int[]{ 5,7,9,11,13,15 },new int[0]);
318
      return jpanel1;
319
   }
320

    
321
   public JPanel createPanel3()
322
   {
323
      JPanel jpanel1 = new JPanel();
324
      FormLayout formlayout1 = new FormLayout("FILL:4DLU:NONE,FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:MIN(12DLU;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");
325
      CellConstraints cc = new CellConstraints();
326
      jpanel1.setLayout(formlayout1);
327

    
328
      lblLocalEffectiveDate.setName("lblLocalEffectiveDate");
329
      lblLocalEffectiveDate.setText("_Effective_date");
330
      lblLocalEffectiveDate.setToolTipText("_Date_when_the_changes_made_will_take_effect");
331
      jpanel1.add(lblLocalEffectiveDate,cc.xy(2,2));
332

    
333
      txtLocalEffectiveDate.setName("txtLocalEffectiveDate");
334
      jpanel1.add(txtLocalEffectiveDate,cc.xy(4,2));
335

    
336
      txtLocalComment.setName("txtLocalComment");
337
      jpanel1.add(txtLocalComment,cc.xywh(4,4,3,1));
338

    
339
      btnLocalEffectiveDate.setActionCommand("...");
340
      btnLocalEffectiveDate.setName("btnLocalEffectiveDate");
341
      btnLocalEffectiveDate.setOpaque(false);
342
      btnLocalEffectiveDate.setText("...");
343
      EmptyBorder emptyborder1 = new EmptyBorder(2,2,2,2);
344
      btnLocalEffectiveDate.setBorder(emptyborder1);
345
      jpanel1.add(btnLocalEffectiveDate,cc.xy(6,2));
346

    
347
      lblLocalComment.setName("lblLocalComment");
348
      lblLocalComment.setText("_Comment");
349
      jpanel1.add(lblLocalComment,cc.xy(2,4));
350

    
351
      addFillComponents(jpanel1,new int[]{ 1,2,3,4,5,6,7 },new int[]{ 1,2,3,4 });
352
      return jpanel1;
353
   }
354

    
355
   public JPanel createPanel4()
356
   {
357
      JPanel jpanel1 = new JPanel();
358
      FormLayout formlayout1 = new FormLayout("FILL:DEFAULT:NONE,FILL:DEFAULT:NONE,FILL:DEFAULT:GROW(1.0)","CENTER:DEFAULT:NONE");
359
      CellConstraints cc = new CellConstraints();
360
      jpanel1.setLayout(formlayout1);
361

    
362
      btnLocalCheckAllEntities.setActionCommand("...");
363
      btnLocalCheckAllEntities.setEnabled(false);
364
      btnLocalCheckAllEntities.setIcon(loadImage("src/main/resources/org/gvsig/vcsgis/swing/impl/images/common-check-on.png"));
365
      btnLocalCheckAllEntities.setName("btnLocalCheckAllEntities");
366
      btnLocalCheckAllEntities.setOpaque(false);
367
      btnLocalCheckAllEntities.setToolTipText("_Select_all");
368
      EmptyBorder emptyborder1 = new EmptyBorder(1,1,1,1);
369
      btnLocalCheckAllEntities.setBorder(emptyborder1);
370
      jpanel1.add(btnLocalCheckAllEntities,cc.xy(1,1));
371

    
372
      btnLocalUnCheckAll1.setActionCommand("...");
373
      btnLocalUnCheckAll1.setEnabled(false);
374
      btnLocalUnCheckAll1.setIcon(loadImage("src/main/resources/org/gvsig/vcsgis/swing/impl/images/common-check-off.png"));
375
      btnLocalUnCheckAll1.setName("btnLocalUnCheckAll");
376
      btnLocalUnCheckAll1.setOpaque(false);
377
      btnLocalUnCheckAll1.setToolTipText("_Unselect_all");
378
      EmptyBorder emptyborder2 = new EmptyBorder(1,1,1,1);
379
      btnLocalUnCheckAll1.setBorder(emptyborder2);
380
      jpanel1.add(btnLocalUnCheckAll1,cc.xy(2,1));
381

    
382
      addFillComponents(jpanel1,new int[]{ 3 },new int[0]);
383
      return jpanel1;
384
   }
385

    
386
   public JPanel createPanel5()
387
   {
388
      JPanel jpanel1 = new JPanel();
389
      FormLayout formlayout1 = new FormLayout("FILL:DEFAULT:GROW(1.0),FILL:4DLU:NONE,FILL:DEFAULT:NONE","CENTER:DEFAULT:NONE,CENTER:2DLU:NONE,FILL:DEFAULT:GROW(1.0)");
390
      CellConstraints cc = new CellConstraints();
391
      jpanel1.setLayout(formlayout1);
392

    
393
      txtLocalTablesFilter.setName("txtLocalTablesFilter");
394
      jpanel1.add(txtLocalTablesFilter,cc.xy(1,1));
395

    
396
      btnLocalTable.setActionCommand("...");
397
      btnLocalTable.setName("btnLocalTable");
398
      btnLocalTable.setOpaque(false);
399
      btnLocalTable.setText("...");
400
      EmptyBorder emptyborder1 = new EmptyBorder(2,2,2,2);
401
      btnLocalTable.setBorder(emptyborder1);
402
      jpanel1.add(btnLocalTable,cc.xy(3,1));
403

    
404
      treeLocalTables.setName("treeLocalTables");
405
      JScrollPane jscrollpane1 = new JScrollPane();
406
      jscrollpane1.setViewportView(treeLocalTables);
407
      jscrollpane1.setVerticalScrollBarPolicy(JScrollPane.VERTICAL_SCROLLBAR_AS_NEEDED);
408
      jscrollpane1.setHorizontalScrollBarPolicy(JScrollPane.HORIZONTAL_SCROLLBAR_AS_NEEDED);
409
      jpanel1.add(jscrollpane1,cc.xywh(1,3,3,1));
410

    
411
      addFillComponents(jpanel1,new int[]{ 2 },new int[]{ 2 });
412
      return jpanel1;
413
   }
414

    
415
   public JPanel createPanel6()
416
   {
417
      JPanel jpanel1 = new JPanel();
418
      FormLayout formlayout1 = new FormLayout("FILL:4DLU:NONE,FILL:DEFAULT:GROW(0.2),FILL:4DLU:NONE,FILL:DEFAULT:GROW(0.8),FILL:4DLU:NONE","CENTER:2DLU:NONE,CENTER:DEFAULT:NONE,CENTER:2DLU:NONE,FILL:DEFAULT:GROW(1.0),CENTER:DEFAULT:NONE,CENTER:2DLU:NONE");
419
      CellConstraints cc = new CellConstraints();
420
      jpanel1.setLayout(formlayout1);
421

    
422
      tblRemoteChanges.setName("tblRemoteChanges");
423
      JScrollPane jscrollpane1 = new JScrollPane();
424
      jscrollpane1.setViewportView(tblRemoteChanges);
425
      jscrollpane1.setVerticalScrollBarPolicy(JScrollPane.VERTICAL_SCROLLBAR_AS_NEEDED);
426
      jscrollpane1.setHorizontalScrollBarPolicy(JScrollPane.HORIZONTAL_SCROLLBAR_AS_NEEDED);
427
      jpanel1.add(jscrollpane1,cc.xy(4,4));
428

    
429
      lstRemoteTables.setName("lstRemoteTables");
430
      JScrollPane jscrollpane2 = new JScrollPane();
431
      jscrollpane2.setViewportView(lstRemoteTables);
432
      jscrollpane2.setVerticalScrollBarPolicy(JScrollPane.VERTICAL_SCROLLBAR_AS_NEEDED);
433
      jscrollpane2.setHorizontalScrollBarPolicy(JScrollPane.HORIZONTAL_SCROLLBAR_AS_NEEDED);
434
      jpanel1.add(jscrollpane2,cc.xywh(2,4,1,2));
435

    
436
      lblRemoteChangesCount.setName("lblRemoteChangesCount");
437
      lblRemoteChangesCount.setText("0");
438
      lblRemoteChangesCount.setHorizontalAlignment(JLabel.RIGHT);
439
      jpanel1.add(lblRemoteChangesCount,cc.xy(4,5));
440

    
441
      jpanel1.add(createPanel7(),cc.xy(4,2));
442
      jpanel1.add(createPanel8(),cc.xy(2,2));
443
      addFillComponents(jpanel1,new int[]{ 1,2,3,4,5 },new int[]{ 1,2,3,4,5,6 });
444
      return jpanel1;
445
   }
446

    
447
   public JPanel createPanel7()
448
   {
449
      JPanel jpanel1 = new JPanel();
450
      FormLayout formlayout1 = new FormLayout("FILL:DEFAULT:NONE,FILL:DEFAULT:NONE,FILL:DEFAULT:NONE,FILL:DEFAULT:GROW(1.0),FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:DEFAULT:NONE,FILL:8DLU:NONE,FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:DEFAULT:NONE,FILL:DEFAULT:NONE,FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:DEFAULT:NONE","CENTER:DEFAULT:NONE");
451
      CellConstraints cc = new CellConstraints();
452
      jpanel1.setLayout(formlayout1);
453

    
454
      btnRemoteShowForm.setActionCommand("...");
455
      btnRemoteShowForm.setIcon(loadImage("src/main/resources/org/gvsig/vcsgis/swing/impl/images/common-showform.png"));
456
      btnRemoteShowForm.setName("btnRemoteShowForm");
457
      btnRemoteShowForm.setOpaque(false);
458
      btnRemoteShowForm.setToolTipText("_Show_form");
459
      EmptyBorder emptyborder1 = new EmptyBorder(2,2,2,2);
460
      btnRemoteShowForm.setBorder(emptyborder1);
461
      jpanel1.add(btnRemoteShowForm,cc.xy(21,1));
462

    
463
      btnRemoteCheckAll.setActionCommand("...");
464
      btnRemoteCheckAll.setEnabled(false);
465
      btnRemoteCheckAll.setIcon(loadImage("src/main/resources/org/gvsig/vcsgis/swing/impl/images/common-check-on.png"));
466
      btnRemoteCheckAll.setName("btnRemoteCheckAll");
467
      btnRemoteCheckAll.setOpaque(false);
468
      btnRemoteCheckAll.setToolTipText("_Select_all");
469
      EmptyBorder emptyborder2 = new EmptyBorder(1,1,1,1);
470
      btnRemoteCheckAll.setBorder(emptyborder2);
471
      jpanel1.add(btnRemoteCheckAll,cc.xy(1,1));
472

    
473
      btnRemoteUncheckAll.setActionCommand("...");
474
      btnRemoteUncheckAll.setEnabled(false);
475
      btnRemoteUncheckAll.setIcon(loadImage("src/main/resources/org/gvsig/vcsgis/swing/impl/images/common-check-off.png"));
476
      btnRemoteUncheckAll.setName("btnRemoteUncheckAll");
477
      btnRemoteUncheckAll.setOpaque(false);
478
      btnRemoteUncheckAll.setToolTipText("_Unselect_all");
479
      EmptyBorder emptyborder3 = new EmptyBorder(1,1,1,1);
480
      btnRemoteUncheckAll.setBorder(emptyborder3);
481
      jpanel1.add(btnRemoteUncheckAll,cc.xy(2,1));
482

    
483
      btnRemoteCleanChanges.setActionCommand("...");
484
      btnRemoteCleanChanges.setIcon(loadImage("src/main/resources/org/gvsig/vcsgis/swing/impl/images/vcsgis-remotechanges-clear.png"));
485
      btnRemoteCleanChanges.setName("btnRemoteCleanChanges");
486
      btnRemoteCleanChanges.setOpaque(false);
487
      btnRemoteCleanChanges.setToolTipText("_Clean_remote_changes");
488
      EmptyBorder emptyborder4 = new EmptyBorder(2,2,2,2);
489
      btnRemoteCleanChanges.setBorder(emptyborder4);
490
      jpanel1.add(btnRemoteCleanChanges,cc.xy(9,1));
491

    
492
      btnRemoteReloadChanges.setActionCommand("...");
493
      btnRemoteReloadChanges.setIcon(loadImage("src/main/resources/org/gvsig/vcsgis/swing/impl/images/vcsgis-remotechanges-reload.png"));
494
      btnRemoteReloadChanges.setName("btnRemoteReloadChanges");
495
      btnRemoteReloadChanges.setOpaque(false);
496
      btnRemoteReloadChanges.setToolTipText("_Reload_remote_changes");
497
      EmptyBorder emptyborder5 = new EmptyBorder(2,2,2,2);
498
      btnRemoteReloadChanges.setBorder(emptyborder5);
499
      jpanel1.add(btnRemoteReloadChanges,cc.xy(7,1));
500

    
501
      btnRemoteMerge.setActionCommand("...");
502
      btnRemoteMerge.setIcon(loadImage("src/main/resources/org/gvsig/vcsgis/swing/impl/images/vcsgis-merge.png"));
503
      btnRemoteMerge.setName("btnRemoteMerge");
504
      btnRemoteMerge.setOpaque(false);
505
      btnRemoteMerge.setToolTipText("_Merge_tables_with_remote_changes");
506
      EmptyBorder emptyborder6 = new EmptyBorder(2,2,2,2);
507
      btnRemoteMerge.setBorder(emptyborder6);
508
      jpanel1.add(btnRemoteMerge,cc.xy(13,1));
509

    
510
      btnRemoteUpdate.setActionCommand("...");
511
      btnRemoteUpdate.setIcon(loadImage("src/main/resources/org/gvsig/vcsgis/swing/impl/images/vcsgis-update-all.png"));
512
      btnRemoteUpdate.setName("btnRemoteUpdate");
513
      btnRemoteUpdate.setOpaque(false);
514
      btnRemoteUpdate.setToolTipText("_Update_tables_with_remote_changes");
515
      EmptyBorder emptyborder7 = new EmptyBorder(2,2,2,2);
516
      btnRemoteUpdate.setBorder(emptyborder7);
517
      jpanel1.add(btnRemoteUpdate,cc.xy(11,1));
518

    
519
      btnRemoteZoom.setActionCommand("...");
520
      btnRemoteZoom.setEnabled(false);
521
      btnRemoteZoom.setIcon(loadImage("src/main/resources/org/gvsig/vcsgis/swing/impl/images/vcsgis-zoom-context.png"));
522
      btnRemoteZoom.setName("btnRemoteZoom");
523
      btnRemoteZoom.setOpaque(false);
524
      btnRemoteZoom.setToolTipText("_Zoom");
525
      EmptyBorder emptyborder8 = new EmptyBorder(2,2,2,2);
526
      btnRemoteZoom.setBorder(emptyborder8);
527
      jpanel1.add(btnRemoteZoom,cc.xy(17,1));
528

    
529
      btnRemoteCenter.setActionCommand("...");
530
      btnRemoteCenter.setEnabled(false);
531
      btnRemoteCenter.setIcon(loadImage("src/main/resources/org/gvsig/vcsgis/swing/impl/images/vcsgis-center-context.png"));
532
      btnRemoteCenter.setName("btnRemoteCenter");
533
      btnRemoteCenter.setOpaque(false);
534
      btnRemoteCenter.setToolTipText("_Center");
535
      EmptyBorder emptyborder9 = new EmptyBorder(2,2,2,2);
536
      btnRemoteCenter.setBorder(emptyborder9);
537
      jpanel1.add(btnRemoteCenter,cc.xy(15,1));
538

    
539
      btnRemoteCleanHighligthed.setActionCommand("...");
540
      btnRemoteCleanHighligthed.setEnabled(false);
541
      btnRemoteCleanHighligthed.setIcon(loadImage("src/main/resources/org/gvsig/vcsgis/swing/impl/images/vcsgis-clean-highlighted.png"));
542
      btnRemoteCleanHighligthed.setName("btnRemoteCleanHighligthed");
543
      btnRemoteCleanHighligthed.setOpaque(false);
544
      btnRemoteCleanHighligthed.setToolTipText("_Clean_highlighted");
545
      EmptyBorder emptyborder10 = new EmptyBorder(2,2,2,2);
546
      btnRemoteCleanHighligthed.setBorder(emptyborder10);
547
      jpanel1.add(btnRemoteCleanHighligthed,cc.xy(19,1));
548

    
549
      addFillComponents(jpanel1,new int[]{ 3,4,5,6,8,10,12,14,16,18,20 },new int[0]);
550
      return jpanel1;
551
   }
552

    
553
   public JPanel createPanel8()
554
   {
555
      JPanel jpanel1 = new JPanel();
556
      FormLayout formlayout1 = new FormLayout("FILL:DEFAULT:GROW(1.0),FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:DEFAULT:NONE","CENTER:DEFAULT:NONE");
557
      CellConstraints cc = new CellConstraints();
558
      jpanel1.setLayout(formlayout1);
559

    
560
      btnRemoteTablesReload.setActionCommand("...");
561
      btnRemoteTablesReload.setIcon(loadImage("src/main/resources/org/gvsig/vcsgis/swing/impl/images/vcsgis-refresh-status.png"));
562
      btnRemoteTablesReload.setName("btnRemoteTablesReload");
563
      btnRemoteTablesReload.setOpaque(false);
564
      btnRemoteTablesReload.setToolTipText("_Refresh");
565
      EmptyBorder emptyborder1 = new EmptyBorder(2,2,2,2);
566
      btnRemoteTablesReload.setBorder(emptyborder1);
567
      jpanel1.add(btnRemoteTablesReload,cc.xy(2,1));
568

    
569
      btnRemoteDownloadChanges.setActionCommand("...");
570
      btnRemoteDownloadChanges.setIcon(loadImage("src/main/resources/org/gvsig/vcsgis/swing/impl/images/vcsgis-remotechanges-download.png"));
571
      btnRemoteDownloadChanges.setName("btnRemoteDownloadChanges");
572
      btnRemoteDownloadChanges.setOpaque(false);
573
      btnRemoteDownloadChanges.setToolTipText("_Download_remote_changes_of_selected_table");
574
      EmptyBorder emptyborder2 = new EmptyBorder(2,2,2,2);
575
      btnRemoteDownloadChanges.setBorder(emptyborder2);
576
      jpanel1.add(btnRemoteDownloadChanges,cc.xy(6,1));
577

    
578
      btnRemoteCheckout.setActionCommand("...");
579
      btnRemoteCheckout.setIcon(loadImage("src/main/resources/org/gvsig/vcsgis/swing/impl/images/vcsgis-checkout.png"));
580
      btnRemoteCheckout.setName("btnRemoteCheckout");
581
      btnRemoteCheckout.setOpaque(false);
582
      btnRemoteCheckout.setToolTipText("_VCS_Checkout");
583
      EmptyBorder emptyborder3 = new EmptyBorder(2,2,2,2);
584
      btnRemoteCheckout.setBorder(emptyborder3);
585
      jpanel1.add(btnRemoteCheckout,cc.xy(4,1));
586

    
587
      addFillComponents(jpanel1,new int[]{ 1,3,5 },new int[]{ 1 });
588
      return jpanel1;
589
   }
590

    
591
   public JPanel createPanel9()
592
   {
593
      JPanel jpanel1 = new JPanel();
594
      FormLayout formlayout1 = new FormLayout("FILL:DEFAULT:GROW(1.0),FILL:DEFAULT:NONE","CENTER:MIN(16PX;DEFAULT):NONE,CENTER:MIN(16PX;DEFAULT):NONE,CENTER:MIN(16PX;DEFAULT):NONE");
595
      CellConstraints cc = new CellConstraints();
596
      jpanel1.setLayout(formlayout1);
597

    
598
      lblStatusCaption.setName("lblStatusCaption");
599
      jpanel1.add(lblStatusCaption,cc.xy(1,1));
600

    
601
      lblStatusMessages.setName("lblStatusMessages");
602
      jpanel1.add(lblStatusMessages,cc.xy(1,3));
603

    
604
      pbStatus.setName("pbStatus");
605
      pbStatus.setValue(25);
606
      jpanel1.add(pbStatus,cc.xy(1,2));
607

    
608
      JLabel jlabel1 = new JLabel();
609
      jlabel1.setText(" ");
610
      jpanel1.add(jlabel1,cc.xy(2,1));
611

    
612
      JLabel jlabel2 = new JLabel();
613
      jlabel2.setText(" ");
614
      jpanel1.add(jlabel2,cc.xy(2,2));
615

    
616
      JLabel jlabel3 = new JLabel();
617
      jlabel3.setText(" ");
618
      jpanel1.add(jlabel3,cc.xy(2,3));
619

    
620
      addFillComponents(jpanel1,new int[0],new int[0]);
621
      return jpanel1;
622
   }
623

    
624
   /**
625
    * Initializer
626
    */
627
   protected void initializePanel()
628
   {
629
      setLayout(new BorderLayout());
630
      add(createPanel(), BorderLayout.CENTER);
631
   }
632

    
633

    
634
}