summaryrefslogtreecommitdiff
path: root/trunk/pdf-over-gui
diff options
context:
space:
mode:
authorAndreas Fitzek <andreas.fitzek@iaik.tugraz.at>2012-10-24 14:45:00 +0200
committerAndreas Fitzek <andreas.fitzek@iaik.tugraz.at>2012-10-24 14:45:00 +0200
commit1b35ac9c8f28392a0e157355b4b73fbb6886a9f9 (patch)
tree9946bf9788c1b256356818824b3e7879609f6412 /trunk/pdf-over-gui
parentceef4ee0c2efe466f1f754d2aa56804fd086ce24 (diff)
downloadpdf-over-1b35ac9c8f28392a0e157355b4b73fbb6886a9f9.tar.gz
pdf-over-1b35ac9c8f28392a0e157355b4b73fbb6886a9f9.tar.bz2
pdf-over-1b35ac9c8f28392a0e157355b4b73fbb6886a9f9.zip
+ Mobile icon added
+ main window shell icon added
Diffstat (limited to 'trunk/pdf-over-gui')
-rw-r--r--trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/MainWindow.java6
-rw-r--r--trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/composites/MobileBKUEnterNumberComposite.java27
-rw-r--r--trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/composites/MobileBKUEnterTANComposite.java25
3 files changed, 50 insertions, 8 deletions
diff --git a/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/MainWindow.java b/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/MainWindow.java
index d981189d..d9bfe86f 100644
--- a/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/MainWindow.java
+++ b/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/MainWindow.java
@@ -191,6 +191,12 @@ public class MainWindow {
getShell().setSize(1024, 768);
getShell().setText(Messages.getString("main.title")); //$NON-NLS-1$
+ ImageData data = new ImageData(this.getClass().getResourceAsStream("/img/icon.png"));//$NON-NLS-1$
+ Image shellicon = new Image(this.shell.getDisplay(), data);
+
+ this.shell.setImage(shellicon);
+
+
getShell().setLayout(new FormLayout());
this.mainbar = new Composite(getShell(), SWT.NONE);
diff --git a/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/composites/MobileBKUEnterNumberComposite.java b/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/composites/MobileBKUEnterNumberComposite.java
index da685f62..fb716104 100644
--- a/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/composites/MobileBKUEnterNumberComposite.java
+++ b/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/composites/MobileBKUEnterNumberComposite.java
@@ -24,6 +24,8 @@ import org.eclipse.swt.events.SelectionListener;
import org.eclipse.swt.events.TraverseEvent;
import org.eclipse.swt.events.TraverseListener;
import org.eclipse.swt.graphics.Color;
+import org.eclipse.swt.graphics.Image;
+import org.eclipse.swt.graphics.ImageData;
import org.eclipse.swt.graphics.Rectangle;
import org.eclipse.swt.layout.FormAttachment;
import org.eclipse.swt.layout.FormData;
@@ -192,8 +194,8 @@ public class MobileBKUEnterNumberComposite extends StateComposite {
FormData fd_containerComposite = new FormData();
fd_containerComposite.top = new FormAttachment(50, -100);
fd_containerComposite.bottom = new FormAttachment(50, 100);
- fd_containerComposite.left = new FormAttachment(50, -250);
- fd_containerComposite.right = new FormAttachment(50, 250);
+ fd_containerComposite.left = new FormAttachment(50, -200);
+ fd_containerComposite.right = new FormAttachment(50, 200);
containerComposite.setLayoutData(fd_containerComposite);
@@ -206,15 +208,31 @@ public class MobileBKUEnterNumberComposite extends StateComposite {
this.txt_number.setLayoutData(fd_number);
this.txt_number.setEditable(true);
+
Label lbl_number = new Label(containerComposite, SWT.NATIVE);
+ lbl_number.setAlignment(SWT.RIGHT);
lbl_number.setText(Messages.getString("mobileBKU.number")); //$NON-NLS-1$
FormData fd_lbl_number = new FormData();
//fd_lbl_number.top = new FormAttachment(30, -15);
fd_lbl_number.bottom = new FormAttachment(50, -10);
- fd_lbl_number.left = new FormAttachment(0, 20);
+ //fd_lbl_number.left = new FormAttachment(0, 20);
fd_lbl_number.right = new FormAttachment(50, -10);
lbl_number.setLayoutData(fd_lbl_number);
+ Label lbl_image = new Label(containerComposite, SWT.NATIVE);
+
+ ImageData data = new ImageData(this.getClass().getResourceAsStream("/img/handy.gif"));//$NON-NLS-1$
+ Image mobile = new Image(getDisplay(), data);
+
+ FormData fd_lbl_image = new FormData();
+ fd_lbl_image.top = new FormAttachment(50, -1 * (data.width / 2));
+ fd_lbl_image.bottom = new FormAttachment(50, data.width / 2);
+ fd_lbl_image.left = new FormAttachment(0, 10);
+ fd_lbl_image.width = data.width;
+ lbl_image.setLayoutData(fd_lbl_image);
+ lbl_image.setImage(mobile);
+
+
this.txt_password = new Text(containerComposite, SWT.SINGLE | SWT.PASSWORD
| SWT.BORDER | SWT.NATIVE);
FormData fd_password = new FormData();
@@ -235,11 +253,12 @@ public class MobileBKUEnterNumberComposite extends StateComposite {
});
Label lbl_password = new Label(containerComposite, SWT.NATIVE);
+ lbl_password.setAlignment(SWT.RIGHT);
lbl_password.setText(Messages.getString("mobileBKU.password")); //$NON-NLS-1$
FormData fd_lbl_password = new FormData();
fd_lbl_password.top = new FormAttachment(50, 10);
//fd_lbl_password.bottom = new FormAttachment(50, 15);
- fd_lbl_password.left = new FormAttachment(0, 20);
+ //fd_lbl_password.left = new FormAttachment(0, 20);
fd_lbl_password.right = new FormAttachment(50, -10);
lbl_password.setLayoutData(fd_lbl_password);
diff --git a/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/composites/MobileBKUEnterTANComposite.java b/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/composites/MobileBKUEnterTANComposite.java
index 683ebd12..833d2670 100644
--- a/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/composites/MobileBKUEnterTANComposite.java
+++ b/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/composites/MobileBKUEnterTANComposite.java
@@ -26,6 +26,8 @@ import org.eclipse.swt.events.SelectionEvent;
import org.eclipse.swt.events.TraverseEvent;
import org.eclipse.swt.events.TraverseListener;
import org.eclipse.swt.graphics.Color;
+import org.eclipse.swt.graphics.Image;
+import org.eclipse.swt.graphics.ImageData;
import org.eclipse.swt.graphics.Rectangle;
import org.eclipse.swt.layout.FormAttachment;
import org.eclipse.swt.layout.FormData;
@@ -198,20 +200,34 @@ public class MobileBKUEnterTANComposite extends StateComposite {
FormData fd_containerComposite = new FormData();
fd_containerComposite.top = new FormAttachment(50, -100);
fd_containerComposite.bottom = new FormAttachment(50, 100);
- fd_containerComposite.left = new FormAttachment(50, -250);
- fd_containerComposite.right = new FormAttachment(50, 250);
+ fd_containerComposite.left = new FormAttachment(50, -200);
+ fd_containerComposite.right = new FormAttachment(50, 200);
containerComposite.setLayoutData(fd_containerComposite);
Label lblVergleichswert = new Label(containerComposite, SWT.NATIVE);
+ lblVergleichswert.setAlignment(SWT.RIGHT);
FormData fd_lblVergleichswert = new FormData();
- fd_lblVergleichswert.left = new FormAttachment(0, 20);
+ //fd_lblVergleichswert.left = new FormAttachment(0, 20);
fd_lblVergleichswert.right = new FormAttachment(50, -10);
//fd_lblVergleichswert.top = new FormAttachment(30, -15);
fd_lblVergleichswert.bottom = new FormAttachment(50, -10);
lblVergleichswert.setLayoutData(fd_lblVergleichswert);
lblVergleichswert.setText(Messages.getString("tanEnter.ReferenceValue")); //$NON-NLS-1$
+ Label lbl_image = new Label(containerComposite, SWT.NATIVE);
+
+ ImageData data = new ImageData(this.getClass().getResourceAsStream("/img/handy.gif"));//$NON-NLS-1$
+ Image mobile = new Image(getDisplay(), data);
+
+ FormData fd_lbl_image = new FormData();
+ fd_lbl_image.top = new FormAttachment(50, -1 * (data.width / 2));
+ fd_lbl_image.bottom = new FormAttachment(50, data.width / 2);
+ fd_lbl_image.left = new FormAttachment(0, 10);
+ fd_lbl_image.width = data.width;
+ lbl_image.setLayoutData(fd_lbl_image);
+ lbl_image.setImage(mobile);
+
this.lblvergleich = new Label(containerComposite, SWT.NATIVE);
FormData fd_lblvergleich = new FormData();
fd_lblvergleich.left = new FormAttachment(50, 10);
@@ -222,8 +238,9 @@ public class MobileBKUEnterTANComposite extends StateComposite {
this.lblvergleich.setText(""); //$NON-NLS-1$
Label lblTan = new Label(containerComposite, SWT.NATIVE);
+ lblTan.setAlignment(SWT.RIGHT);
FormData fd_lblTan = new FormData();
- fd_lblTan.left = new FormAttachment(0, 20);
+ //fd_lblTan.left = new FormAttachment(0, 20);
fd_lblTan.right = new FormAttachment(50, -10);
fd_lblTan.top = new FormAttachment(50, 10);
//fd_lblTan.bottom = new FormAttachment(50, 15);