* @see org.eclipse.ui.IPartListener2#partVisible(org.eclipse.ui.IWorkbenchPartReference)
*/
@SuppressWarnings("unchecked")
public void partVisible( IWorkbenchPartReference partRef ) {
if (partRef.getPart(false) instanceof IUDIGView) {
IUDIGView udigview = (IUDIGView) partRef.getPart(false);
if (!views.contains(udigview))
views.add(udigview);
SimpleFeature editFeature;
ToolContext copy;
synchronized (this) {
if (!validateContext(currentContext))
return;
copy = currentContext.copy();
editFeature = currentContext.getEditManager().getEditFeature();
}
try {
udigview.setContext(copy);
if (editFeature != null)
udigview.editFeatureChanged(editFeature);
} catch (Throwable e) {
UiPlugin.log(udigview + " threw an exception", e); //$NON-NLS-1$
}
} else if (partRef.getPart(false) instanceof MapPart) {