summaryrefslogtreecommitdiff
path: root/pdf-over-gui/src/main/java/at/asit/pdfover/gui
diff options
context:
space:
mode:
authortkellner <tkellner@174cde9d-5d70-4d2a-aa98-46368bc2aaf7>2013-04-10 19:34:35 +0000
committertkellner <tkellner@174cde9d-5d70-4d2a-aa98-46368bc2aaf7>2013-04-10 19:34:35 +0000
commit8aca86f7eb5ff72c201f1029393292088ff5ec55 (patch)
tree5e2137153c3550890fe7a3864d62e6420a173c80 /pdf-over-gui/src/main/java/at/asit/pdfover/gui
parentd65427e43c30e17cd0368115f7aaeb2d690e1b6e (diff)
downloadpdf-over-8aca86f7eb5ff72c201f1029393292088ff5ec55.tar.gz
pdf-over-8aca86f7eb5ff72c201f1029393292088ff5ec55.tar.bz2
pdf-over-8aca86f7eb5ff72c201f1029393292088ff5ec55.zip
Add theme constant
git-svn-id: https://joinup.ec.europa.eu/svn/pdf-over/trunk@390 174cde9d-5d70-4d2a-aa98-46368bc2aaf7
Diffstat (limited to 'pdf-over-gui/src/main/java/at/asit/pdfover/gui')
-rw-r--r--pdf-over-gui/src/main/java/at/asit/pdfover/gui/Constants.java28
1 files changed, 20 insertions, 8 deletions
diff --git a/pdf-over-gui/src/main/java/at/asit/pdfover/gui/Constants.java b/pdf-over-gui/src/main/java/at/asit/pdfover/gui/Constants.java
index a91a1ea4..efb2819b 100644
--- a/pdf-over-gui/src/main/java/at/asit/pdfover/gui/Constants.java
+++ b/pdf-over-gui/src/main/java/at/asit/pdfover/gui/Constants.java
@@ -31,6 +31,10 @@ public class Constants {
/** Current display - used for Colors */
private static Display display = Display.getCurrent();
+ private static enum Themes { DEFAULT, GEMPLUSH };
+
+ private static Themes theme = Themes.DEFAULT;
+
/** Supported locales */
public static final Locale[] SUPPORTED_LOCALES = { Locale.GERMAN, Locale.ENGLISH };
@@ -44,16 +48,22 @@ public class Constants {
public static final int MAINBAR_HEIGHT = 60;
/** Main bar active background - light start of gradient */
- public static final Color MAINBAR_ACTIVE_BACK_LIGHT = new Color(display, 0xB4, 0xCD, 0xEC);
-// public static final Color MAINBAR_ACTIVE_BACK_LIGHT = new Color(display, 0xEC, 0xAD, 0xE7);
+ public static final Color MAINBAR_ACTIVE_BACK_LIGHT =
+ theme == Themes.DEFAULT ?
+ new Color(display, 0xB4, 0xCD, 0xEC) :
+ new Color(display, 0xEC, 0xAD, 0xE7);
/** Main bar active background - dark end of gradient */
- public static final Color MAINBAR_ACTIVE_BACK_DARK = new Color(display, 0x6B, 0xA5, 0xD9);
-// public static final Color MAINBAR_ACTIVE_BACK_DARK = new Color(display, 0xD9, 0x53, 0x9C);
+ public static final Color MAINBAR_ACTIVE_BACK_DARK =
+ theme == Themes.DEFAULT ?
+ new Color(display, 0x6B, 0xA5, 0xD9) :
+ new Color(display, 0xD9, 0x53, 0x9C);
/** Main bar inactive background */
- public static final Color MAINBAR_INACTIVE_BACK = new Color(display, 0xD4, 0xE7, 0xF1);
-// public static final Color MAINBAR_INACTIVE_BACK = new Color(display, 0xF1, 0xD1, 0xE8);
+ public static final Color MAINBAR_INACTIVE_BACK =
+ theme == Themes.DEFAULT ?
+ new Color(display, 0xD4, 0xE7, 0xF1) :
+ new Color(display, 0xF1, 0xD1, 0xE8);
/** Main bar active text color */
public static final Color MAINBAR_ACTIVE_TEXTCOLOR = new Color(display, 0x00, 0x00, 0x00);
@@ -83,8 +93,10 @@ public class Constants {
public static final String RES_ICON = "/icons/icon.png"; //$NON-NLS-1$
/** Config image resource */
- public static final String RES_IMG_CONFIG = "/img/config.png"; //$NON-NLS-1$
-// public static final String RES_IMG_CONFIG = "/img/config_p.png"; //$NON-NLS-1$
+ public static final String RES_IMG_CONFIG =
+ theme == Themes.DEFAULT ?
+ "/img/config.png" : //$NON-NLS-1$
+ "/img/config_p.png"; //$NON-NLS-1$
/** Error image resource */
public static final String RES_IMG_ERROR = "/img/error.png"; //$NON-NLS-1$