Community
Participate
Working Groups
}
});
// watch for windows' widget being set, once they've been set, we
// need to create a WorkbenchWindow
eventBroker.subscribe(UIEvents.UIElement.TOPIC_WIDGET, new EventHandler() {
public void handleEvent(org.osgi.service.event.Event event) {
Object element = event.getProperty(UIEvents.EventTags.ELEMENT);
if (element instanceof MWindow && UIEvents.isSET(event)
&& event.getProperty(UIEvents.EventTags.NEW_VALUE) instanceof Shell) {
MWindow window = (MWindow) element;
createWorkbenchWindow(getDefaultPageInput(), null, window, false);
boolean found = false;
List<MPartDescriptor> currentDescriptors = application.getDescriptors();
for (MPartDescriptor desc : currentDescriptors) {
throw new IllegalArgumentException();
windowTitle = title;
// FIXME: should be TextProcessor.process'd?
window.getModel().setLabel(title);
Shell shell = window.getShell();
if (shell != null && !shell.isDisposed()) {
shell.setText(TextProcessor.process(title, WorkbenchWindow.TEXT_DELIMITERS));