label.setText("Name");\r
\r
name = new TextWidget(composite, support, SWT.BORDER);\r
- name.setTextFactory(new StringPropertyFactory(context, Builtins.URIs.HasName));\r
+ name.setTextFactory(new StringPropertyFactory(Builtins.URIs.HasName));\r
name.addFocusListener(new SaveListener());\r
name.addVerifyListener(new VerifyListener() {\r
\r
label.setText("Start time");\r
\r
startTime = new TextWidget(composite, support, SWT.BORDER | SWT.RIGHT);\r
- startTime.setTextFactory(new DoublePropertyFactory(context, SysdynResource.URIs.HasStartTime));\r
+ startTime.setTextFactory(new DoublePropertyFactory(SysdynResource.URIs.HasStartTime));\r
startTime.addVerifyListener(new DoubleVerify());\r
startTime.addFocusListener(new SaveListener());\r
GridDataFactory.fillDefaults().hint(200, SWT.DEFAULT).applyTo(startTime.getTextWidget());\r
label.setText("Stop time");\r
\r
stopTime = new TextWidget(composite, support, SWT.BORDER | SWT.RIGHT);\r
- stopTime.setTextFactory(new DoublePropertyFactory(context, SysdynResource.URIs.HasStopTime));\r
+ stopTime.setTextFactory(new DoublePropertyFactory(SysdynResource.URIs.HasStopTime));\r
stopTime.addVerifyListener(new DoubleVerify());\r
stopTime.addFocusListener(new SaveListener());\r
GridDataFactory.fillDefaults().hint(200, SWT.DEFAULT).applyTo(stopTime.getTextWidget());\r
GridDataFactory.fillDefaults().grab(true, true).applyTo(composite);\r
GridLayoutFactory.fillDefaults().margins(3, 3).numColumns(6).applyTo(composite);\r
nameWidget = new VariableNameWidget(composite, support, SWT.BORDER);\r
- nameWidget.setTextFactory(new StringPropertyFactory(context, Builtins.URIs.HasName));\r
+ nameWidget.setTextFactory(new StringPropertyFactory(Builtins.URIs.HasName));\r
\r
\r
Label label = new Label(composite, SWT.SINGLE );\r
GridDataFactory.fillDefaults().align(SWT.END, SWT.CENTER).applyTo(label);\r
\r
unitWidget = new UnitWidget(composite, support, SWT.DROP_DOWN | SWT.BORDER);\r
- unitWidget.setTextFactory(new StringPropertyFactory(context, SysdynResource.URIs.HasUnit));\r
+ unitWidget.setTextFactory(new StringPropertyFactory(SysdynResource.URIs.HasUnit));\r
\r
shortcutTabWidget = new ShortcutTabWidget(composite, support, SWT.NONE);\r
\r
GridLayoutFactory.fillDefaults().margins(3, 3).applyTo(informationGroup);\r
\r
information = new TextWidget(informationGroup, support, SWT.MULTI | SWT.BORDER);\r
- information.setTextFactory(new StringPropertyFactory(context, Builtins.URIs.HasDescription));\r
+ information.setTextFactory(new StringPropertyFactory(Builtins.URIs.HasDescription));\r
information.addFocusListener(new SaveListener());\r
GridDataFactory.fillDefaults().grab(true, true).applyTo(information.getTextWidget());\r
\r
label.setText("Start");\r
\r
rangeStart = new TextWidget(rangeGroup, support, SWT.BORDER | SWT.RIGHT);\r
- rangeStart.setTextFactory(new DoublePropertyFactory(context, SysdynResource.URIs.HasRangeStart));\r
+ rangeStart.setTextFactory(new DoublePropertyFactory(SysdynResource.URIs.HasRangeStart));\r
rangeStart.addFocusListener(new SaveListener());\r
rangeStart.addVerifyListener(new DoubleVerify());\r
\r
label.setText("End");\r
\r
rangeEnd = new TextWidget(rangeGroup, support, SWT.BORDER | SWT.RIGHT);\r
- rangeEnd.setTextFactory(new DoublePropertyFactory(context, SysdynResource.URIs.HasRangeEnd));\r
+ rangeEnd.setTextFactory(new DoublePropertyFactory(SysdynResource.URIs.HasRangeEnd));\r
rangeEnd.addFocusListener(new SaveListener());\r
rangeEnd.addVerifyListener(new DoubleVerify());\r
\r
label.setText("Step");\r
\r
rangeStep = new TextWidget(rangeGroup, support, SWT.BORDER | SWT.RIGHT);\r
- rangeStep.setTextFactory(new DoublePropertyFactory(context, SysdynResource.URIs.HasRangeStep));\r
+ rangeStep.setTextFactory(new DoublePropertyFactory(SysdynResource.URIs.HasRangeStep));\r
rangeStep.addFocusListener(new SaveListener());\r
rangeStep.addVerifyListener(new DoubleVerify());\r
\r
import org.simantics.db.Resource;\r
import org.simantics.db.common.request.ReadRequest;\r
import org.simantics.db.exception.DatabaseException;\r
+import org.simantics.db.management.ISessionContext;\r
import org.simantics.sysdyn.SysdynResource;\r
import org.simantics.sysdyn.ui.properties.widgets.ExpressionTypes.ExpressionType;\r
import org.simantics.ui.SimanticsUI;\r
}\r
\r
@Override\r
- public void setInput(Object input) {\r
+ public void setInput(ISessionContext context, Object input) {\r
if(input instanceof IStructuredSelection) {\r
final Resource variable = ISelectionUtils.filterSingleSelection((IStructuredSelection)input, Resource.class);\r
if(variable != null) {\r
import org.simantics.db.ReadGraph;\r
import org.simantics.db.Resource;\r
import org.simantics.db.exception.DatabaseException;\r
+import org.simantics.db.management.ISessionContext;\r
import org.simantics.db.request.Read;\r
import org.simantics.sysdyn.ui.properties.widgets.ExpressionTypes.ExpressionType;\r
import org.simantics.sysdyn.ui.properties.widgets.expressions.AuxiliaryExpression;\r
}\r
\r
@Override\r
- public void setInput(Object input) {\r
+ public void setInput(ISessionContext context, Object input) {\r
if(input instanceof ISelection) {\r
ISelection selection = (ISelection)input;\r
if(selection instanceof IStructuredSelection) {\r
import org.simantics.db.ReadGraph;\r
import org.simantics.db.Resource;\r
import org.simantics.db.exception.DatabaseException;\r
+import org.simantics.db.management.ISessionContext;\r
import org.simantics.db.request.Read;\r
import org.simantics.sysdyn.SysdynResource;\r
import org.simantics.ui.SimanticsUI;\r
}\r
\r
@Override\r
- public void setInput(Object input) {\r
+ public void setInput(ISessionContext context, Object input) {\r
if(input instanceof IStructuredSelection) {\r
final Resource variable = ISelectionUtils.filterSingleSelection((IStructuredSelection)input, Resource.class);\r
if(variable != null) {\r
import org.simantics.db.WriteGraph;\r
import org.simantics.db.common.request.WriteRequest;\r
import org.simantics.db.exception.DatabaseException;\r
+import org.simantics.db.management.ISessionContext;\r
import org.simantics.db.procedure.Listener;\r
import org.simantics.sysdyn.ui.properties.widgets.factories.DoublePropertyFactory;\r
import org.simantics.ui.SimanticsUI;\r
}\r
\r
@Override\r
- public void setInput(Object input) {\r
+ public void setInput(ISessionContext context, Object input) {\r
if(input instanceof ISelection)\r
resource = ISelectionUtils.filterSingleSelection((ISelection)input, Resource.class);\r
\r
if(readFactory != null) {\r
- readFactory.listen(input, new Listener<String>() {\r
+ readFactory.listen(context, input, new Listener<String>() {\r
\r
@Override\r
public void exception(Throwable t) {\r
import org.simantics.db.WriteGraph;\r
import org.simantics.db.common.request.WriteRequest;\r
import org.simantics.db.exception.DatabaseException;\r
+import org.simantics.db.management.ISessionContext;\r
import org.simantics.db.procedure.Listener;\r
import org.simantics.db.request.Read;\r
import org.simantics.sysdyn.SysdynResource;\r
}\r
\r
@Override\r
- public void setInput(final Object input) {\r
+ public void setInput(ISessionContext context, final Object input) {\r
if(input instanceof ISelection)\r
variable = ISelectionUtils.filterSingleSelection((ISelection)input, Resource.class);\r
if(textFactory != null) {\r
- textFactory.listen(input, new Listener<String>() {\r
+ textFactory.listen(context, input, new Listener<String>() {\r
\r
@Override\r
public void exception(Throwable t) {\r
import org.simantics.db.common.request.ReadRequest;\r
import org.simantics.db.common.request.WriteRequest;\r
import org.simantics.db.exception.DatabaseException;\r
+import org.simantics.db.management.ISessionContext;\r
import org.simantics.db.procedure.Listener;\r
import org.simantics.sysdyn.manager.SysdynModel;\r
import org.simantics.sysdyn.manager.SysdynModelManager;\r
}\r
\r
@Override\r
- public void setInput(Object input) {\r
+ public void setInput(ISessionContext context, Object input) {\r
if(input instanceof ISelection) {\r
variable = ISelectionUtils.filterSingleSelection((ISelection)input, Resource.class);\r
SimanticsUI.getSession().asyncRequest(new ReadRequest() {\r
\r
}\r
if(textFactory != null) {\r
- textFactory.listen(input, new Listener<String>() {\r
+ textFactory.listen(context, input, new Listener<String>() {\r
\r
@Override\r
public void exception(Throwable t) {\r
\r
final private String propertyURI;\r
\r
- public DoublePropertyFactory(ISessionContext context, String propertyURI) {\r
- super(context);\r
+ public DoublePropertyFactory(String propertyURI) {\r
this.propertyURI = propertyURI;\r
}\r
\r