summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorclemenso <clemenso@8a26b1a7-26f0-462f-b9ef-d0e30c41f5a4>2008-11-04 12:03:15 +0000
committerclemenso <clemenso@8a26b1a7-26f0-462f-b9ef-d0e30c41f5a4>2008-11-04 12:03:15 +0000
commit9fcce6749092eb6c5d266dd1dd7099e88014fbd7 (patch)
tree7ddf99875943edf468c04e1da55ff9171842c580
parente9aa3cfecde0a9e765507d0cc6b01341e7315860 (diff)
downloadmocca-9fcce6749092eb6c5d266dd1dd7099e88014fbd7.tar.gz
mocca-9fcce6749092eb6c5d266dd1dd7099e88014fbd7.tar.bz2
mocca-9fcce6749092eb6c5d266dd1dd7099e88014fbd7.zip
simplegui messages on top
git-svn-id: https://joinup.ec.europa.eu/svn/mocca/trunk@143 8a26b1a7-26f0-462f-b9ef-d0e30c41f5a4
-rw-r--r--BKUCommonGUI/src/main/java/at/gv/egiz/bku/gui/BKUGUI.java6
-rw-r--r--BKUCommonGUI/src/main/java/at/gv/egiz/bku/gui/SimpleGUI.java93
-rw-r--r--bkucommon/src/main/java/at/gv/egiz/bku/binding/BindingProcessorManagerImpl.java5
-rw-r--r--smcc/pom.xml35
4 files changed, 59 insertions, 80 deletions
diff --git a/BKUCommonGUI/src/main/java/at/gv/egiz/bku/gui/BKUGUI.java b/BKUCommonGUI/src/main/java/at/gv/egiz/bku/gui/BKUGUI.java
index 9f733a14..cb99a872 100644
--- a/BKUCommonGUI/src/main/java/at/gv/egiz/bku/gui/BKUGUI.java
+++ b/BKUCommonGUI/src/main/java/at/gv/egiz/bku/gui/BKUGUI.java
@@ -14,10 +14,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-/*
- * To change this template, choose Tools | Templates
- * and open the template in the editor.
- */
package at.gv.egiz.bku.gui;
import at.gv.egiz.smcc.PINSpec;
@@ -819,7 +815,7 @@ public class BKUGUI implements BKUGUIFacade {
mainPanel.removeAll();
buttonPanel.removeAll();
-// titleLabel.setText(messages.getString(TITLE_WAIT));
+ titleLabel.setText(messages.getString(TITLE_WAIT));
helpListener.setHelpTopic(HELP_WAIT);
diff --git a/BKUCommonGUI/src/main/java/at/gv/egiz/bku/gui/SimpleGUI.java b/BKUCommonGUI/src/main/java/at/gv/egiz/bku/gui/SimpleGUI.java
index a005292e..6bf6df84 100644
--- a/BKUCommonGUI/src/main/java/at/gv/egiz/bku/gui/SimpleGUI.java
+++ b/BKUCommonGUI/src/main/java/at/gv/egiz/bku/gui/SimpleGUI.java
@@ -312,15 +312,14 @@ public class SimpleGUI implements BKUGUIFacade {
mainPanel.setLayout(mainPanelLayout);
mainPanelLayout.setHorizontalGroup(
- mainPanelLayout.createParallelGroup(GroupLayout.Alignment.LEADING)
- .addGroup(mainPanelLayout.createSequentialGroup()
+ mainPanelLayout.createSequentialGroup()
+ .addComponent(welcomeMsgLabel)
.addPreferredGap(LayoutStyle.ComponentPlacement.UNRELATED, 0, Short.MAX_VALUE)
- .addComponent(helpLabel))
- .addComponent(welcomeMsgLabel));
+ .addComponent(helpLabel));
mainPanelLayout.setVerticalGroup(
- mainPanelLayout.createSequentialGroup()
- .addComponent(helpLabel)
- .addComponent(welcomeMsgLabel));
+ mainPanelLayout.createParallelGroup(GroupLayout.Alignment.LEADING)
+ .addComponent(welcomeMsgLabel)
+ .addComponent(helpLabel));
contentPanel.validate();
@@ -355,15 +354,14 @@ public class SimpleGUI implements BKUGUIFacade {
mainPanel.setLayout(mainPanelLayout);
mainPanelLayout.setHorizontalGroup(
- mainPanelLayout.createParallelGroup(GroupLayout.Alignment.LEADING)
- .addGroup(mainPanelLayout.createSequentialGroup()
+ mainPanelLayout.createSequentialGroup()
+ .addComponent(insertCardMsgLabel)
.addPreferredGap(LayoutStyle.ComponentPlacement.UNRELATED, 0, Short.MAX_VALUE)
- .addComponent(helpLabel))
- .addComponent(insertCardMsgLabel));
+ .addComponent(helpLabel));
mainPanelLayout.setVerticalGroup(
- mainPanelLayout.createSequentialGroup()
- .addComponent(helpLabel)
- .addComponent(insertCardMsgLabel));
+ mainPanelLayout.createParallelGroup(GroupLayout.Alignment.LEADING)
+ .addComponent(insertCardMsgLabel)
+ .addComponent(helpLabel));
// JButton cancelButton = new JButton();
// cancelButton.setText(messages.getString(BUTTON_CANCEL));
@@ -418,15 +416,14 @@ public class SimpleGUI implements BKUGUIFacade {
mainPanel.setLayout(mainPanelLayout);
mainPanelLayout.setHorizontalGroup(
- mainPanelLayout.createParallelGroup(GroupLayout.Alignment.LEADING)
- .addGroup(mainPanelLayout.createSequentialGroup()
+ mainPanelLayout.createSequentialGroup()
+ .addComponent(insertCardMsgLabel)
.addPreferredGap(LayoutStyle.ComponentPlacement.UNRELATED, 0, Short.MAX_VALUE)
- .addComponent(helpLabel))
- .addComponent(insertCardMsgLabel));
+ .addComponent(helpLabel));
mainPanelLayout.setVerticalGroup(
- mainPanelLayout.createSequentialGroup()
- .addComponent(helpLabel)
- .addComponent(insertCardMsgLabel));
+ mainPanelLayout.createParallelGroup(GroupLayout.Alignment.LEADING)
+ .addComponent(insertCardMsgLabel)
+ .addComponent(helpLabel));
// JButton cancelButton = new JButton();
// cancelButton.setText(messages.getString(BUTTON_CANCEL));
@@ -764,6 +761,11 @@ public class SimpleGUI implements BKUGUIFacade {
helpListener.setHelpTopic(errorMsgKey);
+ JLabel errorTitleLabel = new JLabel();
+ errorTitleLabel.setFont(errorTitleLabel.getFont().deriveFont(errorTitleLabel.getFont().getStyle() | java.awt.Font.BOLD));
+ errorTitleLabel.setText(messages.getString(TITLE_ERROR));
+ errorTitleLabel.setForeground(ERROR_COLOR);
+
String errorMsgPattern = messages.getString(errorMsgKey);
String errorMsg = MessageFormat.format(errorMsgPattern, errorMsgParams);
@@ -778,12 +780,15 @@ public class SimpleGUI implements BKUGUIFacade {
mainPanelLayout.setHorizontalGroup(
mainPanelLayout.createParallelGroup(GroupLayout.Alignment.LEADING)
.addGroup(mainPanelLayout.createSequentialGroup()
+ .addComponent(errorTitleLabel)
.addPreferredGap(LayoutStyle.ComponentPlacement.UNRELATED, 0, Short.MAX_VALUE)
.addComponent(helpLabel))
.addComponent(errorMsgLabel));
mainPanelLayout.setVerticalGroup(
mainPanelLayout.createSequentialGroup()
- .addComponent(helpLabel)
+ .addGroup(mainPanelLayout.createParallelGroup(GroupLayout.Alignment.LEADING)
+ .addComponent(errorTitleLabel)
+ .addComponent(helpLabel))
.addComponent(errorMsgLabel));
JButton okButton = new JButton();
@@ -827,27 +832,34 @@ public class SimpleGUI implements BKUGUIFacade {
helpListener.setHelpTopic(errorMsgKey);
+ JLabel errorTitleLabel = new JLabel();
+ errorTitleLabel.setFont(errorTitleLabel.getFont().deriveFont(errorTitleLabel.getFont().getStyle() | java.awt.Font.BOLD));
+ errorTitleLabel.setText(messages.getString(TITLE_ERROR));
+ errorTitleLabel.setForeground(ERROR_COLOR);
+
String errorMsgPattern = messages.getString(errorMsgKey);
String errorMsg = MessageFormat.format(errorMsgPattern, errorMsgParams);
JLabel errorMsgLabel = new JLabel();
errorMsgLabel.setFont(errorMsgLabel.getFont().deriveFont(errorMsgLabel.getFont().getStyle() & ~java.awt.Font.BOLD));
errorMsgLabel.setText(errorMsg);
- errorMsgLabel.setForeground(ERROR_COLOR);
-
+
GroupLayout mainPanelLayout = new GroupLayout(mainPanel);
mainPanel.setLayout(mainPanelLayout);
mainPanelLayout.setHorizontalGroup(
- mainPanelLayout.createParallelGroup(GroupLayout.Alignment.LEADING)
- .addGroup(mainPanelLayout.createSequentialGroup()
- .addPreferredGap(LayoutStyle.ComponentPlacement.UNRELATED, 0, Short.MAX_VALUE)
- .addComponent(helpLabel))
- .addComponent(errorMsgLabel));
- mainPanelLayout.setVerticalGroup(
- mainPanelLayout.createSequentialGroup()
- .addComponent(helpLabel)
- .addComponent(errorMsgLabel));
+ mainPanelLayout.createParallelGroup(GroupLayout.Alignment.LEADING)
+ .addGroup(mainPanelLayout.createSequentialGroup()
+ .addComponent(errorTitleLabel)
+ .addPreferredGap(LayoutStyle.ComponentPlacement.UNRELATED, 0, Short.MAX_VALUE)
+ .addComponent(helpLabel))
+ .addComponent(errorMsgLabel));
+ mainPanelLayout.setVerticalGroup(
+ mainPanelLayout.createSequentialGroup()
+ .addGroup(mainPanelLayout.createParallelGroup(GroupLayout.Alignment.LEADING)
+ .addComponent(errorTitleLabel)
+ .addComponent(helpLabel))
+ .addComponent(errorMsgLabel));
contentPanel.validate();
}
@@ -885,16 +897,15 @@ public class SimpleGUI implements BKUGUIFacade {
mainPanel.setLayout(mainPanelLayout);
mainPanelLayout.setHorizontalGroup(
- mainPanelLayout.createParallelGroup(GroupLayout.Alignment.LEADING)
- .addGroup(mainPanelLayout.createSequentialGroup()
+ mainPanelLayout.createSequentialGroup()
+ .addComponent(waitMsgLabel)
.addPreferredGap(LayoutStyle.ComponentPlacement.UNRELATED, 0, Short.MAX_VALUE)
- .addComponent(helpLabel))
- .addComponent(waitMsgLabel));
+ .addComponent(helpLabel));
mainPanelLayout.setVerticalGroup(
- mainPanelLayout.createSequentialGroup()
- .addComponent(helpLabel)
- .addComponent(waitMsgLabel));
-
+ mainPanelLayout.createParallelGroup(GroupLayout.Alignment.LEADING)
+ .addComponent(waitMsgLabel)
+ .addComponent(helpLabel));
+
contentPanel.validate();
}
});
diff --git a/bkucommon/src/main/java/at/gv/egiz/bku/binding/BindingProcessorManagerImpl.java b/bkucommon/src/main/java/at/gv/egiz/bku/binding/BindingProcessorManagerImpl.java
index cc1b7532..9757f7cc 100644
--- a/bkucommon/src/main/java/at/gv/egiz/bku/binding/BindingProcessorManagerImpl.java
+++ b/bkucommon/src/main/java/at/gv/egiz/bku/binding/BindingProcessorManagerImpl.java
@@ -285,16 +285,19 @@ public class BindingProcessorManagerImpl implements BindingProcessorManager {
log.debug("Removing binding processor: " + sessionId);
ProcessingContext ctx = contextMap.get(sessionId);
if (ctx == null) {
+ log.warn("no processing context to remove for session " + sessionId);
return;
}
Future f = ctx.getFuture();
-
+
// MapEntityWrapper wrapper = bindingProcessorMap.get(sessionId);
// if (wrapper == null) {
// return;
// }
// Future<?> f = wrapper.getFuture();
+
if (!f.isDone()) {
+ log.trace("canceling " + sessionId);
f.cancel(true);
}
contextMap.remove(sessionId);
diff --git a/smcc/pom.xml b/smcc/pom.xml
index 3e3dfe14..9fa81387 100644
--- a/smcc/pom.xml
+++ b/smcc/pom.xml
@@ -1,6 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<parent>
<artifactId>bku</artifactId>
<groupId>at.gv.egiz</groupId>
@@ -16,36 +15,6 @@
<build>
<plugins>
<plugin>
- <artifactId>maven-jar-plugin</artifactId>
- <executions>
- <execution>
- <goals>
- <goal>sign</goal>
- </goals>
- </execution>
- </executions>
- <configuration>
- <archive>
- <addMavenDescriptor>false</addMavenDescriptor>
- <index>false</index>
- <manifest>
- <addClasspath>false</addClasspath>
- </manifest>
- </archive>
- <alias>test-applet signer</alias>
- <keystore>keystore.ks</keystore>
- <storepass>storepass</storepass>
- <keypass>keypass</keypass>
- <verify>true</verify>
- </configuration>
- </plugin>
- <plugin>
- <artifactId>maven-compiler-plugin</artifactId>
- <configuration>
- <encoding>UTF-8</encoding>
- </configuration>
- </plugin>
- <plugin>
<artifactId>maven-resources-plugin</artifactId>
<configuration>
<encoding>UTF-8</encoding>
@@ -70,4 +39,4 @@
<artifactId>iaik_jce_full_signed</artifactId>
</dependency> -->
</dependencies>
-</project> \ No newline at end of file
+</project>