Search in sources :

Example 1 with ModelObserver

use of org.whole.lang.ui.editparts.ModelObserver in project whole by wholeplatform.

the class E4GraphicalViewer method updateModelObserver.

protected void updateModelObserver(IEntity entity) {
    ICompoundModel model = entity.wGetModel().getCompoundModel();
    if (modelObserver != null && modelObserver.getModel() != model) {
        modelObserver.dispose();
        modelObserver = null;
    }
    if (modelObserver == null)
        modelObserver = new ModelObserver(model, this);
}
Also used : ModelObserver(org.whole.lang.ui.editparts.ModelObserver) ICompoundModel(org.whole.lang.model.ICompoundModel)

Example 2 with ModelObserver

use of org.whole.lang.ui.editparts.ModelObserver in project whole by wholeplatform.

the class E4TreeViewer method updateModelObserver.

protected void updateModelObserver(IEntity entity) {
    ICompoundModel model = entity.wGetModel().getCompoundModel();
    if (modelObserver != null && modelObserver.getModel() != model) {
        modelObserver.dispose();
        modelObserver = null;
    }
    if (modelObserver == null)
        modelObserver = new ModelObserver(model, this);
}
Also used : ModelObserver(org.whole.lang.ui.editparts.ModelObserver) ICompoundModel(org.whole.lang.model.ICompoundModel)

Aggregations

ICompoundModel (org.whole.lang.model.ICompoundModel)2 ModelObserver (org.whole.lang.ui.editparts.ModelObserver)2