org.simantics.project;bundle-version="1.0.1",
org.simantics.scenegraph.loader;bundle-version="1.0.0";visibility:=reexport,
org.simantics.scenegraph.ontology;bundle-version="1.0.0",
- org.simantics.utils.thread.swt;bundle-version="1.1.0"
+ org.simantics.utils.thread.swt;bundle-version="1.1.0",
+ org.slf4j.api;bundle-version="1.7.25"
Export-Package: org.simantics.views.swt
Bundle-Activator: org.simantics.views.swt.Activator
Bundle-Vendor: Semantum Oy
import org.simantics.db.WriteGraph;
import org.simantics.db.common.request.WriteRequest;
import org.simantics.db.common.request.WriteResultRequest;
-import org.simantics.db.common.utils.Logger;
import org.simantics.db.exception.DatabaseException;
-import org.simantics.db.exception.ServiceNotFoundException;
+import org.simantics.db.exception.RuntimeDatabaseException;
import org.simantics.db.layer0.util.RemoverUtil;
import org.simantics.db.layer0.variable.Variable;
import org.simantics.db.management.ISessionContext;
import org.simantics.ui.workbench.IPropertyPage;
import org.simantics.utils.ui.jface.ActiveSelectionProvider;
import org.simantics.views.swt.client.base.SWTRoot;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
/**
* To use this class, first model your view contents in .pgraph files according
*/
public class ModelledView extends SimanticsView implements IPartListener2 {
+ private static final Logger LOGGER = LoggerFactory.getLogger(ModelledView.class);
+
public static final int TIME_BEFORE_DISPOSE_WHEN_HIDDEN = 30000; // ms
private static final boolean DEBUG = false;
return runtime;
}
});
- } catch (ServiceNotFoundException e) {
- Logger.defaultLogError(e);
- } catch (DatabaseException e) {
- Logger.defaultLogError(e);
+ } catch (RuntimeDatabaseException | DatabaseException e) {
+ LOGGER.error("Failed to initialize modelled widget support runtime scenegraph", e);
}
support = new ModelledSupport(this);
} catch (DatabaseException e) {
- e.printStackTrace();
- Logger.defaultLogError(e);
+ LOGGER.error("Failed to create modelled controls", e);
}
RemoverUtil.remove(graph, rt);
}
});
- } catch (ServiceNotFoundException e) {
- Logger.defaultLogError(e);
- } catch (DatabaseException e) {
- Logger.defaultLogError(e);
+ } catch (RuntimeDatabaseException | DatabaseException e) {
+ LOGGER.error("Failed to dispose of the modelled widget support runtime scenegraph", e);
}
}