diff options
author | tkellner <tkellner@3a0b52a2-8410-0410-bc02-ff6273a87459> | 2012-10-31 16:36:55 +0000 |
---|---|---|
committer | tkellner <tkellner@3a0b52a2-8410-0410-bc02-ff6273a87459> | 2012-10-31 16:36:55 +0000 |
commit | 2981345a1efccd0ee0a1b74f986161ea2c4b881b (patch) | |
tree | 772bf079195a0b5a8918b2197f03371c0d78001e /trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/MainWindow.java | |
parent | 0d8f4da43d19ea8e0fb520c5c5d29caa51707251 (diff) | |
download | pdf-over-2981345a1efccd0ee0a1b74f986161ea2c4b881b.tar.gz pdf-over-2981345a1efccd0ee0a1b74f986161ea2c4b881b.tar.bz2 pdf-over-2981345a1efccd0ee0a1b74f986161ea2c4b881b.zip |
Move constants to separate class
git-svn-id: https://svn.iaik.tugraz.at/svn/egiz/prj/current/12PDF-OVER-4.0@12743 3a0b52a2-8410-0410-bc02-ff6273a87459
Diffstat (limited to 'trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/MainWindow.java')
-rw-r--r-- | trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/MainWindow.java | 14 |
1 files changed, 5 insertions, 9 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 a69d7096..c3f9b529 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 @@ -61,10 +61,6 @@ public class MainWindow { **/ static final Logger log = LoggerFactory.getLogger(MainWindow.class); - /** Main bar height */ - private static final int MAINBAR_HEIGHT = 60; - - private Shell shell; private Composite mainbar; private FormData mainBarFormData; @@ -173,7 +169,7 @@ public class MainWindow { */ protected void createContents() { this.shell = new Shell(); - getShell().setSize(550, 768); + getShell().setSize(Constants.MAINWINDOW_WIDTH, Constants.MAINWINDOW_HEIGHT); try { Display display = Display.getCurrent(); Monitor primary = display.getPrimaryMonitor(); @@ -202,7 +198,7 @@ public class MainWindow { this.mainBarFormData.left = new FormAttachment(0, 10); this.mainBarFormData.right = new FormAttachment(100, -10); this.mainBarFormData.top = new FormAttachment(0, 10); - this.mainBarFormData.bottom = new FormAttachment(0, MAINBAR_HEIGHT); + this.mainBarFormData.bottom = new FormAttachment(0, Constants.MAINBAR_HEIGHT); this.mainbar.setLayoutData(this.mainBarFormData); this.btn_config = new MainBarRectangleButton(this.mainbar, SWT.NONE); @@ -303,7 +299,7 @@ public class MainWindow { this.containerFormData = new FormData(); this.containerFormData.bottom = new FormAttachment(100, -10); this.containerFormData.right = new FormAttachment(100, -10); - this.containerFormData.top = new FormAttachment(0, MAINBAR_HEIGHT + 10); + this.containerFormData.top = new FormAttachment(0, Constants.MAINBAR_HEIGHT + 10); this.containerFormData.left = new FormAttachment(0, 10); this.container.setLayoutData(this.containerFormData); this.stack = new StackLayout(); @@ -332,8 +328,8 @@ public class MainWindow { } if (behavior.getMainBarVisible()) { - this.mainBarFormData.bottom = new FormAttachment(0, MAINBAR_HEIGHT); - this.containerFormData.top = new FormAttachment(0, MAINBAR_HEIGHT + 10); + this.mainBarFormData.bottom = new FormAttachment(0, Constants.MAINBAR_HEIGHT); + this.containerFormData.top = new FormAttachment(0, Constants.MAINBAR_HEIGHT + 10); } else { this.mainBarFormData.bottom = new FormAttachment(0, 0); this.containerFormData.top = new FormAttachment(0, 10); |