- Timestamp:
- 12/15/05 10:32:30 (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/org.modelica.mdt/src/org/modelica/mdt/editor/ModelicaCompletionProcessor.java
r221 r224 65 65 //TODO comment the class, remar ! 66 66 /** 67 * This class is responsible for proposing completions and giving 68 * context information about functions. These functions kick in when . 69 * and ( are typed. 70 * 71 * computeCompletionProposals() takes care of proposing classnames when 72 * typing after a . 73 * 74 * computeContextInformation() takes care of showing the definitions of 75 * the parameters of classes that have parameters. 67 76 * 68 77 * @author Andreas Remar … … 106 115 int pos = stringTyped.indexOf('('); 107 116 108 System.out.println(pos);109 110 117 /* Match parens to see if we're done typing. */ 111 118 int pardepth = 0; … … 149 156 private void newProposals(String className) 150 157 { 151 proposals.clear(); 152 narrowedProposals.clear(); 158 if(proposals != null) 159 proposals.clear(); 160 else 161 proposals = new Vector<Object>(); 162 if(narrowedProposals != null) 163 narrowedProposals.clear(); 164 else 165 narrowedProposals = new Vector<Object>(); 166 153 167 typeAhead = 0; 154 168 … … 167 181 finally 168 182 { 169 narrowedProposals = proposals;183 narrowedProposals.addAll(proposals); 170 184 } 171 185 } … … 268 282 elementsInfo = OMCProxy.getElementsInfo(functionName); 269 283 } 270 catch (ConnectionException e){ e.printStackTrace();}271 catch (InvocationError e){ e.printStackTrace();}272 catch (UnexpectedReplyException e){ e.printStackTrace();}284 catch (ConnectionException e){ErrorManager.showCompilerError(e);return;} 285 catch (InvocationError e){/* class wasn't found or something */ return;} 286 catch (UnexpectedReplyException e){/* strange reply from omc? */return;} 273 287 274 288 functionProposal = functionName; … … 419 433 } 420 434 435 if(proposal == "") 436 return null; 437 421 438 IContextInformation[] result = new IContextInformation[1]; 422 439
Note: See TracChangeset
for help on using the changeset viewer.