1 | while (e.hasMoreElements()) {↵ | | 1 | while (e.hasMoreElements()) {↵
|
2 | IExtension extension = (IExtension) e.nextElement();↵ | | 2 | IExtension extension = (IExtension) e.nextElement();↵
|
3 | String stateString = extension.getMetadata().getAttribute("state");↵ | | 3 | String stateString = extension.getMetadata().getAttribute("state");↵
|
4 | try {↵ | | 4 | try {↵
|
5 | AbstractFolderOptionsPlugin plugin = (AbstractFolderOptionsPlugin) extension↵ | | 5 | AbstractFolderOptionsPlugin plugin = (AbstractFolderOptionsPlugin) extension↵
|
6 | .instanciateExtension(new Object[] { mediator });↵ | | 6 | .instanciateExtension(new Object[] { mediator });↵
|
|
7 | if ((state == STATE_BEFORE) && (stateString.equals("before"))) {↵ | | 7 | if ((state == STATE_BEFORE) && (stateString.equals("before"))) {↵
|
8 | plugin.loadOptionsFromXml(null);↵ | | 8 | plugin.loadOptionsFromXml(null);↵
|
9 | } else if ((state == STATE_AFTER)↵ | | 9 | } else if ((state == STATE_AFTER)↵
|
10 | && (stateString.equals("after"))) {↵ | | 10 | && (stateString.equals("after"))) {↵
|
11 | plugin.loadOptionsFromXml(folder);↵ | | 11 | plugin.loadOptionsFromXml(null);↵
|
12 | }↵ | | 12 | }↵
|
13 | } catch (PluginException e1) {↵ | | 13 | } catch (Exception e1) {↵
|
14 | ↵ | | 14 | // TODO (@author fdietz): add error dialog↵
|
15 | e1.printStackTrace();↵ | | 15 | e1.printStackTrace();↵
|
16 | | | 16 |
|