Revision 41642 trunk/org.gvsig.desktop/org.gvsig.desktop.library/org.gvsig.exportto/org.gvsig.exportto.swing/org.gvsig.exportto.swing.prov/org.gvsig.exportto.swing.prov.jdbc/src/main/java/org/gvsig/exportto/swing/prov/jdbc/panel/PermissionsPanel.java
PermissionsPanel.java | ||
---|---|---|
1 | 1 |
|
2 | 2 |
package org.gvsig.exportto.swing.prov.jdbc.panel; |
3 | 3 |
|
4 |
import java.awt.event.ActionEvent; |
|
5 |
import java.awt.event.ActionListener; |
|
4 | 6 |
import javax.swing.JComponent; |
5 | 7 |
import org.apache.commons.lang3.StringUtils; |
6 | 8 |
import org.gvsig.exportto.swing.prov.jdbc.ExporttoJDBCOptions; |
... | ... | |
21 | 23 |
} |
22 | 24 |
|
23 | 25 |
private void initComponents() { |
26 |
ActionListener listener = new ActionListener() { |
|
27 |
public void actionPerformed(ActionEvent ae) { |
|
28 |
doUpdateState(); |
|
29 |
} |
|
30 |
}; |
|
31 |
this.chkAll.addActionListener(listener); |
|
32 |
this.chkSelect.addActionListener(listener); |
|
33 |
this.chkUpdate.addActionListener(listener); |
|
34 |
this.chkInsert.addActionListener(listener); |
|
35 |
this.chkDelete.addActionListener(listener); |
|
36 |
this.chkTruncate.addActionListener(listener); |
|
37 |
this.chkTrigger.addActionListener(listener); |
|
38 |
this.chkReference.addActionListener(listener); |
|
39 |
} |
|
40 |
|
|
41 |
protected void doUpdateState() { |
|
42 |
this.txtRoleAll.setEnabled(this.chkAll.isSelected()); |
|
43 |
this.txtRoleSelect.setEnabled(this.chkSelect.isSelected()); |
|
44 |
this.txtRoleUpdate.setEnabled(this.chkUpdate.isSelected()); |
|
45 |
this.txtRoleInsert.setEnabled(this.chkInsert.isSelected()); |
|
46 |
this.txtRoleDelete.setEnabled(this.chkDelete.isSelected()); |
|
47 |
this.txtRoleTruncate.setEnabled(this.chkTruncate.isSelected()); |
|
48 |
this.txtRoleTrigger.setEnabled(this.chkTrigger.isSelected()); |
|
49 |
this.txtRoleReference.setEnabled(this.chkReference.isSelected()); |
|
24 | 50 |
} |
25 |
|
|
51 |
|
|
26 | 52 |
public String getPanelTitle() { |
27 | 53 |
I18nManager i18nManager = ToolsLocator.getI18nManager(); |
28 | 54 |
return i18nManager.getTranslation("Permissions"); |
Also available in: Unified diff