diff options
author | tkellner <tkellner@174cde9d-5d70-4d2a-aa98-46368bc2aaf7> | 2014-02-03 15:22:51 +0000 |
---|---|---|
committer | tkellner <tkellner@174cde9d-5d70-4d2a-aa98-46368bc2aaf7> | 2014-02-03 15:22:51 +0000 |
commit | 521431920bb0079a618ffe5d72bd6280608fc13f (patch) | |
tree | 5b8ebc426fc124faae8dc9e3d3d4bc9fdf5147ac /pdf-over-gui/src/main/java/at/asit/pdfover/gui/Constants.java | |
parent | 45e0bd8a3b2153e910719e6a6ceea94e0e32c2ca (diff) | |
download | mocca-521431920bb0079a618ffe5d72bd6280608fc13f.tar.gz mocca-521431920bb0079a618ffe5d72bd6280608fc13f.tar.bz2 mocca-521431920bb0079a618ffe5d72bd6280608fc13f.zip |
Add Application Version Constant
git-svn-id: https://joinup.ec.europa.eu/svn/pdf-over/trunk@505 174cde9d-5d70-4d2a-aa98-46368bc2aaf7
Diffstat (limited to 'pdf-over-gui/src/main/java/at/asit/pdfover/gui/Constants.java')
-rw-r--r-- | pdf-over-gui/src/main/java/at/asit/pdfover/gui/Constants.java | 9 |
1 files changed, 8 insertions, 1 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 a9492f0e..aae15703 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 @@ -33,10 +33,17 @@ public class Constants { /** Application name */ public static final String APP_NAME = "PDF-Over"; //$NON-NLS-1$ + /** Application version */ + public static final String APP_VERSION = Constants.class.getPackage().getImplementationVersion(); + + /** Application name + version */ + public static final String APP_NAME_VERSION = (APP_VERSION == null ? APP_NAME : APP_NAME + " v" + APP_VERSION); //$NON-NLS-1$ + static { // Has to be set before (implicitly) initializing Display Display.setAppName(APP_NAME); } + /** Current display - used for Colors */ private static Display display = Display.getCurrent(); @@ -68,7 +75,7 @@ public class Constants { public static final int SIGNATURE_KEYBOARD_POSITIONING_OFFSET = 15; /** PDF-Over User Agent string */ - public static final String USER_AGENT_STRING = "PDF-Over 4.0"; //$NON-NLS-1$ + public static final String USER_AGENT_STRING = "PDF-Over " + (APP_VERSION == null ? "4.0" : APP_VERSION); //$NON-NLS-1$ //$NON-NLS-2$ /* Configuration parameters */ |