comparison mde/setup/Init.d @ 132:264028f4115a

Cleaned up mde.imde and a couple of widget functions. New mde.menus module to add default menus. The input singleton is now created in mde.input.Input instead of mde.imde.
author Diggory Hardy <diggory.hardy@gmail.com>
date Fri, 23 Jan 2009 14:59:05 +0000
parents 3328c6fb77ca
children 7ababdf97748
comparison
equal deleted inserted replaced
131:9cff74f68b84 132:264028f4115a
327 327
328 // Do a job: 328 // Do a job:
329 try { 329 try {
330 static if (startup) { 330 static if (startup) {
331 debug logger.trace ("({}) InitStage {}: starting init", threadNum, stage.name); 331 debug logger.trace ("({}) InitStage {}: starting init", threadNum, stage.name);
332 stage.state = (*stage).init(); // init is a property of a pointer (oh no!) 332 stage.state = (*stage).init(); // init is a property too :-(
333 } else { 333 } else {
334 debug logger.trace ("({}) InitStage {}: starting cleanup", threadNum, stage.name); 334 debug logger.trace ("({}) InitStage {}: starting cleanup", threadNum, stage.name);
335 stage.state = stage.cleanup(); 335 stage.state = stage.cleanup();
336 } 336 }
337 debug logger.trace ("({}) InitStage {}: completed; state: {}", threadNum, stage.name, stage.state); 337 debug logger.trace ("({}) InitStage {}: completed; state: {}", threadNum, stage.name, stage.state);
338 } catch (InitStageException e) { 338 } catch (InitStageException e) {
339 debug logger.trace ("({}) InitStage {}: failed: "~e.msg, threadNum, stage.name); 339 debug logger.error ("({}) InitStage {}: failed: "~e.msg, threadNum, stage.name);
340 else logger.error ("InitStage {}: failed: "~e.msg, stage.name);
340 stage.state = e.state; 341 stage.state = e.state;
341 doneInit = STATE.ABORT; 342 doneInit = STATE.ABORT;
342 break threadLoop; 343 break threadLoop;
343 } catch (Exception e) { 344 } catch (Exception e) {
344 debug logger.trace ("({}) InitStage {}: failed: "~e.msg, threadNum, stage.name); 345 debug logger.error ("({}) InitStage {}: failed: "~e.msg, threadNum, stage.name);
346 else logger.error ("InitStage {}: failed: "~e.msg, stage.name);
345 doneInit = STATE.ABORT; 347 doneInit = STATE.ABORT;
346 break threadLoop; 348 break threadLoop;
347 } 349 }
348 } 350 }
349 } catch (Exception e) { 351 } catch (Exception e) {