Révision 1525
tmp/org.txm.rcp/src/main/java/org/txm/rcp/ApplicationWorkbenchAdvisor.java (revision 1525) | ||
---|---|---|
466 | 466 |
*/ |
467 | 467 |
@Override |
468 | 468 |
public void postShutdown() { |
469 |
callPreStopScript(); |
|
470 |
|
|
471 |
Toolbox.shutdown(); |
|
472 |
|
|
469 | 473 |
callStopScript(); |
470 |
Toolbox.shutdown(); |
|
471 | 474 |
} |
472 | 475 |
|
473 | 476 |
/** |
... | ... | |
1045 | 1048 |
Log.printStackTrace(e); |
1046 | 1049 |
} |
1047 | 1050 |
} |
1051 |
|
|
1052 |
/** |
|
1053 |
* Called just before Toolbox is stop call |
|
1054 |
*/ |
|
1055 |
private void callPreStopScript() { |
|
1056 |
try { |
|
1057 |
File stopScript = new File(Toolbox.getTxmHomePath(), "scripts/groovy/user/prestop.groovy"); //$NON-NLS-1$ |
|
1058 |
if (stopScript.exists() && stopScript.canRead()) { |
|
1048 | 1059 |
|
1060 |
ExecuteGroovyScript.executeScript(stopScript.getAbsolutePath(), null, null, true, ""); |
|
1061 |
} |
|
1062 |
} catch(Exception e) { |
|
1063 |
System.out.println(TXMCoreMessages.bind("Fail to execute 'stop.groovy' script: {0}.", e)); |
|
1064 |
Log.printStackTrace(e); |
|
1065 |
} |
|
1066 |
} |
|
1067 |
|
|
1049 | 1068 |
/** |
1050 | 1069 |
* Called just after Toolbox is stop call |
1051 | 1070 |
*/ |
Formats disponibles : Unified diff