Bug 52159 [ActivityMgmt] Activity entry in window menu needs to be defined in object contribution
We should move the activity configuration menu entry to an object contribution in the IDE plug-in so that other applications do not have to have it or hack the UI.
bundles/org.eclipse.ui.ide/src/org/eclipse/ui/internal/ide/WorkbenchActionBuilder.java
/**
	 * Constructs a new action builder which contributes actions
	 * to the given window.
	 * 
	 * @param window the window
	 */
	public WorkbenchActionBuilder(IWorkbenchWindow window) {
		this.window = window;
	}
	/**
	 * Returns the window to which this action builder is contributing.
	 */
	private IWorkbenchWindow getWindow() {
		return window;
	}
	
	/**
	 * Hooks listeners on the preference store and the window's page, perspective and selection services.
	 */
	private void hookListeners() {
		
		
		getWindow().addPageListener(new IPageListener() {
			public void pageActivated(IWorkbenchPage page) {
				enableActions(page.getPerspective() != null);
			}
			public void pageClosed(IWorkbenchPage page) {
				IWorkbenchPage pg = getWindow().getActivePage();
				enableActions(pg != null && pg.getPerspective() != null);
			}