From 98b22c11b756de3b32e723e1d888d2f2dbe5df5e Mon Sep 17 00:00:00 2001 From: Patrick Plitzner Date: Mon, 3 Apr 2017 12:24:08 +0200 Subject: [PATCH] fix #6549 Fix ClassCastException --- .../java/eu/etaxonomy/taxeditor/model/AbstractUtility.java | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/model/AbstractUtility.java b/eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/model/AbstractUtility.java index a490390a6..f1ffe8abe 100644 --- a/eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/model/AbstractUtility.java +++ b/eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/model/AbstractUtility.java @@ -38,7 +38,6 @@ import org.eclipse.jface.action.IStatusLineManager; import org.eclipse.jface.operation.IRunnableWithProgress; import org.eclipse.jface.resource.ColorRegistry; import org.eclipse.jface.resource.FontRegistry; -import org.eclipse.jface.window.ApplicationWindow; import org.eclipse.swt.graphics.Color; import org.eclipse.swt.graphics.Font; import org.eclipse.swt.widgets.Display; @@ -167,11 +166,11 @@ public abstract class AbstractUtility { * * @return a {@link org.eclipse.jface.window.ApplicationWindow} object. */ - public static ApplicationWindow getWorkbenchWindow() { + public static IWorkbenchWindow getWorkbenchWindow() { if (getWorkbench().getWorkbenchWindowCount() > 1) { throw new IllegalStateException("More than one workbench window"); } - return (ApplicationWindow) getWorkbench().getWorkbenchWindows()[0]; + return getWorkbench().getWorkbenchWindows()[0]; } /** -- 2.34.1