use of org.eclipse.titan.log.viewer.views.ILogViewerView in project titan.EclipsePlug-ins by eclipse.
the class ActionUtils method closeView.
private static void closeView(IFile file, IWorkbenchPage activePage, IViewReference reference) {
IViewPart view = reference.getView(false);
// a restored view with faulty content
if (view == null) {
activePage.hideView(reference);
return;
}
if (!(view instanceof ILogViewerView)) {
return;
}
final ILogViewerView logViewerView = (ILogViewerView) view;
final LogFileMetaData metadata = logViewerView.getLogFileMetaData();
if (metadata == null) {
activePage.hideView(reference);
return;
}
if (file.getLocationURI().equals(metadata.getFilePath())) {
if (logViewerView instanceof DetailsView) {
((DetailsView) logViewerView).setData(null, false);
}
activePage.hideView(reference);
}
}
use of org.eclipse.titan.log.viewer.views.ILogViewerView in project titan.EclipsePlug-ins by eclipse.
the class ActionUtils method closeView.
private static void closeView(IProject project, IWorkbenchPage activePage, IViewReference reference, IViewPart view) {
// a restored view with faulty content
if (view == null) {
activePage.hideView(reference);
return;
}
if (!(view instanceof ILogViewerView)) {
return;
}
final ILogViewerView logViewerView = (ILogViewerView) view;
final LogFileMetaData metaData = logViewerView.getLogFileMetaData();
if (metaData == null) {
activePage.hideView(reference);
return;
}
if (project.getName().equals(metaData.getProjectName())) {
activePage.hideView(reference);
}
}
Aggregations