-
Notifications
You must be signed in to change notification settings - Fork 36
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add method in enum to get boolean value of button state
- Loading branch information
1 parent
efa0e49
commit e3f43c6
Showing
3 changed files
with
15 additions
and
21 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
14 changes: 12 additions & 2 deletions
14
src/main/java/org/opendatakit/suitcase/utils/ButtonState.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,16 @@ | ||
package org.opendatakit.suitcase.utils; | ||
|
||
public enum ButtonState { | ||
ENABLED, | ||
DISABLED | ||
ENABLED(true), | ||
DISABLED(false); | ||
|
||
boolean state; | ||
|
||
public boolean getButtonStateBooleanValue() { | ||
return this.state; | ||
} | ||
|
||
ButtonState(boolean b) { | ||
this.state = b; | ||
} | ||
} |