Subversion Repository Public Repository

litesoft

Diff Revisions 949 vs 950 for /trunk/Java/GWT/OldClient/src/org/litesoft/GWT/client/commands/DisableableCommand.java

Diff revisions: vs.
  @@ -1,24 +1,24 @@
1 - // This Source Code is in the Public Domain per: http://unlicense.org
2 - package org.litesoft.GWT.client.commands;
3 -
4 - import com.google.gwt.user.client.*;
5 -
6 - public abstract class DisableableCommand implements Command {
7 - private boolean mEnabled = true;
8 -
9 - public boolean isEnabled() {
10 - return mEnabled;
11 - }
12 -
13 - public void setEnabled( boolean pEnabled ) {
14 - mEnabled = pEnabled;
15 - }
16 -
17 - public final void execute() {
18 - if ( mEnabled ) {
19 - enabledExecute();
20 - }
21 - }
22 -
23 - abstract public void enabledExecute();
24 - }
1 + // This Source Code is in the Public Domain per: http://unlicense.org
2 + package org.litesoft.GWT.client.commands;
3 +
4 + import com.google.gwt.user.client.*;
5 +
6 + public abstract class DisableableCommand implements Command {
7 + private boolean mEnabled = true;
8 +
9 + public boolean isEnabled() {
10 + return mEnabled;
11 + }
12 +
13 + public void setEnabled( boolean pEnabled ) {
14 + mEnabled = pEnabled;
15 + }
16 +
17 + public final void execute() {
18 + if ( mEnabled ) {
19 + enabledExecute();
20 + }
21 + }
22 +
23 + abstract public void enabledExecute();
24 + }