Project

General

Profile

Download (1.31 KB) Statistics
| Branch: | Tag: | Revision:
1
package eu.etaxonomy.taxeditor;
2

    
3
import org.eclipse.rwt.lifecycle.IEntryPoint;
4
import org.eclipse.swt.widgets.Display;
5
import org.eclipse.ui.PlatformUI;
6
import org.eclipse.ui.application.WorkbenchAdvisor;
7

    
8
import eu.etaxonomy.taxeditor.editor.EditorStateManager;
9
import eu.etaxonomy.taxeditor.navigation.NavigatorStateManager;
10
import eu.etaxonomy.taxeditor.preference.PreferencesUtil;
11
import eu.etaxonomy.taxeditor.store.CdmStore;
12

    
13
public class EntryPoint implements IEntryPoint {
14

    
15
	public EntryPoint() {
16
		System.out.println("In EntryPoint.constructor");
17
		// TODO Auto-generated constructor stub
18
	}
19

    
20
	@Override
21
	public int createUI() {
22
		
23
		Display display = PlatformUI.createDisplay();
24
		System.out.println("In EntryPoint.createUI(): Display.getDefault()" + Display.getDefault());
25
	    WorkbenchAdvisor advisor = new ApplicationWorkbenchAdvisor();
26
		PreferencesUtil.setDefaults();
27
/**** RAPInclude from NavigatorPlugin
28
 * 
29
 */
30
		NavigatorStateManager navStateManager = new NavigatorStateManager();
31
		CdmStore.getContextManager().addContextListener(navStateManager);
32
/**** RAPInclude from TaxeditorEditorPlugin
33
 * 
34
 */
35
		EditorStateManager editStateManager = new EditorStateManager();
36
		CdmStore.getContextManager().addContextListener(editStateManager);
37

    
38

    
39
	    PlatformUI.createAndRunWorkbench(display, advisor);
40
	    return 0;
41
    }
42

    
43
}
    (1-1/1)