summaryrefslogtreecommitdiff
path: root/pdf-over-gui/src/main/java/at/asit/pdfover/gui/MainWindowBehavior.java
diff options
context:
space:
mode:
authortkellner <tkellner@174cde9d-5d70-4d2a-aa98-46368bc2aaf7>2013-04-10 18:57:07 +0000
committertkellner <tkellner@174cde9d-5d70-4d2a-aa98-46368bc2aaf7>2013-04-10 18:57:07 +0000
commita8222b9d16145d8b2f8803d13e5afe2b99d47fc0 (patch)
tree36637499e140a59d6e43f74eaceb3e23ec3e1f07 /pdf-over-gui/src/main/java/at/asit/pdfover/gui/MainWindowBehavior.java
parent9f07d0ac1f3d53d03a4f105b1b99dccd4ac2d473 (diff)
downloadpdf-over-a8222b9d16145d8b2f8803d13e5afe2b99d47fc0.tar.gz
pdf-over-a8222b9d16145d8b2f8803d13e5afe2b99d47fc0.tar.bz2
pdf-over-a8222b9d16145d8b2f8803d13e5afe2b99d47fc0.zip
Configuration and Main Bar Buttons
git-svn-id: https://joinup.ec.europa.eu/svn/pdf-over/trunk@53 174cde9d-5d70-4d2a-aa98-46368bc2aaf7
Diffstat (limited to 'pdf-over-gui/src/main/java/at/asit/pdfover/gui/MainWindowBehavior.java')
-rw-r--r--pdf-over-gui/src/main/java/at/asit/pdfover/gui/MainWindowBehavior.java39
1 files changed, 39 insertions, 0 deletions
diff --git a/pdf-over-gui/src/main/java/at/asit/pdfover/gui/MainWindowBehavior.java b/pdf-over-gui/src/main/java/at/asit/pdfover/gui/MainWindowBehavior.java
index 1d0094c9..a2f53e63 100644
--- a/pdf-over-gui/src/main/java/at/asit/pdfover/gui/MainWindowBehavior.java
+++ b/pdf-over-gui/src/main/java/at/asit/pdfover/gui/MainWindowBehavior.java
@@ -24,8 +24,19 @@ import at.asit.pdfover.gui.MainWindow.Buttons;
* Behavior manipulation for Main Window
*/
public class MainWindowBehavior {
+ /**
+ * Enabled buttons map
+ */
protected Map<Buttons, Boolean> buttonsEnabled;
+
+ /**
+ * active buttons map
+ */
protected Map<Buttons, Boolean> buttonsActive;
+
+ /**
+ * Main bar visible
+ */
protected boolean mainBarVisible;
/**
@@ -37,18 +48,38 @@ public class MainWindowBehavior {
reset();
}
+ /**
+ * set active buttons
+ * @param button
+ * @param active
+ */
public void setActive(Buttons button, boolean active) {
this.buttonsActive.put(button, active);
}
+ /**
+ * Gets the active state of a button from main bar
+ * @param button the button
+ * @return the active state
+ */
public boolean getActive(Buttons button) {
return this.buttonsActive.get(button);
}
+ /**
+ * Sets the enabled buttons in the main bar
+ * @param button
+ * @param enabled
+ */
public void setEnabled(Buttons button, boolean enabled) {
this.buttonsEnabled.put(button, enabled);
}
+ /**
+ * Get the enabled state of a button in main bar
+ * @param button the button
+ * @return the enabled state
+ */
public boolean getEnabled(Buttons button) {
return this.buttonsEnabled.get(button);
}
@@ -67,10 +98,18 @@ public class MainWindowBehavior {
setMainBarVisible(true);
}
+ /**
+ * Sets the main bar visible
+ * @param visible
+ */
public void setMainBarVisible(boolean visible) {
this.mainBarVisible = visible;
}
+ /**
+ * Gets wether the main bar is visible
+ * @return the visibility of the main bar
+ */
public boolean getMainBarVisible() {
return this.mainBarVisible;
}