/[gzz]/gzz/lava/gzz/client/PotionFallbackBinder.java
ViewVC logotype

Diff of /gzz/lava/gzz/client/PotionFallbackBinder.java

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.5 by benja, Mon Jan 6 11:57:29 2003 UTC revision 1.6 by benja, Mon Jan 6 12:11:46 2003 UTC
# Line 10  public class PotionFallbackBinder implem Line 10  public class PotionFallbackBinder implem
10      public static boolean dbg = false;      public static boolean dbg = false;
11      private static void pa(String s) { System.out.println(s); }      private static void pa(String s) { System.out.println(s); }
12    
13        public FunctionExpression currentFunctionExpression;
14      public CommandCall currentCommand;      public CommandCall currentCommand;
15      public int currentWin;      public int currentWin;
16    
# Line 63  public class PotionFallbackBinder implem Line 64  public class PotionFallbackBinder implem
64              // no binding for this key: clear pending              // no binding for this key: clear pending
65              currentCommand = null;              currentCommand = null;
66              AbstractUpdateManager.chg();              AbstractUpdateManager.chg();
67            } else if(binding instanceof FunctionExpression){
68                FunctionExpression f = (FunctionExpression)binding;  
69                if(currentCommand==null){
70                    currentFunctionExpression = f;
71                } else {
72                    Map context = getContext(fallback.windows[currentWin], k);
73                    currentCommand = (CommandCall)currentCommand.setNextParam(f);
74                    if(currentCommand.isComplete()) {
75                        if(dbg) pa("Execute: "+currentCommand);
76                        currentCommand.execute(context);
77                        currentCommand = null;
78                    }
79                }
80          } else if(binding instanceof Action) {          } else if(binding instanceof Action) {
81              Action action = (Action)binding;              Action action = (Action)binding;
82              currentCommand = action.command;              currentCommand = action.command;
83              currentWin = action.window;              currentWin = action.window;
84              if(dbg) pa("Replaced currentCommand.");              if(dbg) pa("Replaced currentCommand.");
85                if(currentFunctionExpression!=null)
86                    currentCommand = (CommandCall)currentCommand.setNextParam(currentFunctionExpression);
87                currentFunctionExpression=null;
88              if(currentCommand.isComplete()) {              if(currentCommand.isComplete()) {
89                  if(dbg) pa("Execute: "+currentCommand);                  if(dbg) pa("Execute: "+currentCommand);
90                  Map context = getContext(fallback.windows[currentWin], k);                  Map context = getContext(fallback.windows[currentWin], k);

Legend:
Removed from v.1.5  
changed lines
  Added in v.1.6

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26