Changeset 185
- Timestamp:
- 10/30/02 18:47:25 (20 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/j/src/org/armedbear/j/Editor.java
r123 r185 3 3 * 4 4 * Copyright (C) 1998-2002 Peter Graves 5 * $Id: Editor.java,v 1.1 1 2002-10-13 16:56:42piso Exp $5 * $Id: Editor.java,v 1.12 2002-10-30 18:47:25 piso Exp $ 6 6 * 7 7 * This program is free software; you can redistribute it and/or … … 6141 6141 setFocusToTextField(); 6142 6142 } 6143 6144 private static Method evaluateMethod; 6143 6145 6144 6146 public void executeCommand(String input) 6145 6147 { 6148 input = input.trim(); 6149 if (input.length() == 0) 6150 return; 6151 if (input.charAt(0) == '(') { 6152 // Lisp form. 6153 try { 6154 if (evaluateMethod == null) { 6155 Class c = Class.forName("org.armedbear.lisp.Interpreter"); 6156 if (c != null) { 6157 Class[] parameterTypes = new Class[] { 6158 Class.forName("java.lang.String") 6159 }; 6160 evaluateMethod = c.getMethod("evaluate", parameterTypes); 6161 } 6162 } 6163 if (evaluateMethod != null) 6164 invoke(evaluateMethod, input); 6165 } 6166 catch (Throwable t) { 6167 Log.debug(t); 6168 return; 6169 } 6170 } 6146 6171 int index = input.indexOf('='); 6147 6172 if (index >= 0) {
Note: See TracChangeset
for help on using the changeset viewer.