Bug 342998 Refactor ESelectionService into multiple classes
While there is a master/slave relationship "enforced" by the current implementation, it is non-obvious as the code is quite convoluted. The implementation needs to be refactored to enhance readability.
tests/org.eclipse.e4.ui.tests/src/org/eclipse/e4/ui/tests/application/ESelectionServiceTest.java
partOneImpl.setSelection(selection);
		UseSelectionHandler handler = new UseSelectionHandler();
		assertNull(handler.selection);
		ContextInjectionFactory.invoke(handler, Execute.class,
				applicationContext, null);
		assertEquals(selection, handler.selection);
		handler.selection = null;
		ContextInjectionFactory.invoke(handler, Execute.class, windowContext,
				null);
		assertEquals(selection, handler.selection);
		handler.selection = null;
		ContextInjectionFactory.invoke(handler, Execute.class, partContextA,
				null);
		assertEquals(selection, handler.selection);
		handler.selection = null;
		ContextInjectionFactory.invoke(handler, Execute.class, partContextB,
				null);
		assertNull(handler.selection);
		EPartService partService = (EPartService) windowContext
				.get(EPartService.class.getName());
		partService.activate(partB);
		ContextInjectionFactory.invoke(handler, Execute.class,
				applicationContext, null);
		assertNull(handler.selection);
		handler.selection = null;
		ContextInjectionFactory.invoke(handler, Execute.class, windowContext,
				null);
		assertNull(handler.selection);
		handler.selection = null;
		ContextInjectionFactory.invoke(handler, Execute.class, partContextA,