use of com.twinsoft.convertigo.engine.studio.views.projectexplorer.model.WrapDatabaseObject in project convertigo by convertigo.
the class DatabaseObjectDeleteAction method delete.
private void delete(WrapDatabaseObject treeObject) throws ConvertigoException, IOException {
WrapDatabaseObject parentTreeObject = null;
WrapObject treeParent = treeObject.getParent();
DatabaseObject databaseObject = (DatabaseObject) treeObject.getObject();
DatabaseObject parent = databaseObject.getParent();
while ((treeParent != null) && (!(treeParent instanceof WrapDatabaseObject))) {
treeParent = treeParent.getParent();
}
if (treeParent != null) {
parentTreeObject = (WrapDatabaseObject) treeParent;
}
delete(databaseObject);
// Do not save after a deletion anymore
if (parent != null) {
parentTreeObject.hasBeenModified(true);
}
if ((parentTreeObject != null) && !treeNodesToUpdate.contains(parentTreeObject)) {
treeNodesToUpdate.add(parentTreeObject);
}
}
use of com.twinsoft.convertigo.engine.studio.views.projectexplorer.model.WrapDatabaseObject in project convertigo by convertigo.
the class DisableExtractionRuleAction method run2.
@Override
protected void run2() throws Exception {
try {
WrapObject[] treeObjects = studio.getSelectedObjects().toArray(new WrapObject[0]);
for (int i = treeObjects.length - 1; i >= 0; --i) {
WrapDatabaseObject treeObject = (WrapDatabaseObject) treeObjects[i];
if (treeObject.instanceOf(ExtractionRule.class)) {
// StepView stepTreeObject = (StepView) treeObject;
ExtractionRule extractionRule = (ExtractionRule) treeObject.getObject();
extractionRule.setEnabled(false);
// stepTreeObject.setEnabled(true);
// stepTreeObject.hasBeenModified(true);
// TreeObjectEvent treeObjectEvent = new TreeObjectEvent(stepTreeObject, "isEnable", false, true);
// explorerView.fireTreeObjectPropertyChanged(treeObjectEvent);
}
}
// explorerView.refreshSelectedTreeObjects();
} catch (Throwable e) {
throw e;
// ConvertigoPlugin.logException(e, "Unable to enable step!");
}
// finally {
// shell.setCursor(null);
// waitCursor.dispose();
}
use of com.twinsoft.convertigo.engine.studio.views.projectexplorer.model.WrapDatabaseObject in project convertigo by convertigo.
the class DisableListenerAction method run2.
@Override
protected void run2() throws Exception {
try {
WrapObject[] treeObjects = studio.getSelectedObjects().toArray(new WrapObject[0]);
for (int i = treeObjects.length - 1; i >= 0; --i) {
WrapDatabaseObject treeObject = (WrapDatabaseObject) treeObjects[i];
if (treeObject.instanceOf(Listener.class)) {
// StepView stepTreeObject = (StepView) treeObject;
Listener listener = (Listener) treeObject.getObject();
listener.setEnabled(false);
// stepTreeObject.setEnabled(true);
// stepTreeObject.hasBeenModified(true);
// TreeObjectEvent treeObjectEvent = new TreeObjectEvent(stepTreeObject, "isEnable", false, true);
// explorerView.fireTreeObjectPropertyChanged(treeObjectEvent);
}
}
// explorerView.refreshSelectedTreeObjects();
} catch (Throwable e) {
throw e;
// ConvertigoPlugin.logException(e, "Unable to enable step!");
}
// finally {
// shell.setCursor(null);
// waitCursor.dispose();
}
use of com.twinsoft.convertigo.engine.studio.views.projectexplorer.model.WrapDatabaseObject in project convertigo by convertigo.
the class DisableMobileRouteActionComponentAction method run2.
@Override
protected void run2() throws Exception {
try {
WrapObject[] treeObjects = studio.getSelectedObjects().toArray(new WrapObject[0]);
for (int i = treeObjects.length - 1; i >= 0; --i) {
WrapDatabaseObject treeObject = (WrapDatabaseObject) treeObjects[i];
if (treeObject.instanceOf(RouteActionComponent.class)) {
// StepView stepTreeObject = (StepView) treeObject;
RouteActionComponent component = (RouteActionComponent) treeObject.getObject();
component.setEnabled(false);
// stepTreeObject.setEnabled(true);
// stepTreeObject.hasBeenModified(true);
// TreeObjectEvent treeObjectEvent = new TreeObjectEvent(stepTreeObject, "isEnable", false, true);
// explorerView.fireTreeObjectPropertyChanged(treeObjectEvent);
}
}
// explorerView.refreshSelectedTreeObjects();
} catch (Throwable e) {
throw e;
// ConvertigoPlugin.logException(e, "Unable to enable step!");
}
// finally {
// shell.setCursor(null);
// waitCursor.dispose();
}
use of com.twinsoft.convertigo.engine.studio.views.projectexplorer.model.WrapDatabaseObject in project convertigo by convertigo.
the class DisableMobileRouteComponentAction method run2.
@Override
protected void run2() throws Exception {
try {
WrapObject[] treeObjects = studio.getSelectedObjects().toArray(new WrapObject[0]);
for (int i = treeObjects.length - 1; i >= 0; --i) {
WrapDatabaseObject treeObject = (WrapDatabaseObject) treeObjects[i];
if (treeObject.instanceOf(RouteComponent.class)) {
// StepView stepTreeObject = (StepView) treeObject;
RouteComponent component = (RouteComponent) treeObject.getObject();
component.setEnabled(false);
// stepTreeObject.setEnabled(true);
// stepTreeObject.hasBeenModified(true);
// TreeObjectEvent treeObjectEvent = new TreeObjectEvent(stepTreeObject, "isEnable", false, true);
// explorerView.fireTreeObjectPropertyChanged(treeObjectEvent);
}
}
// explorerView.refreshSelectedTreeObjects();
} catch (Throwable e) {
throw e;
// ConvertigoPlugin.logException(e, "Unable to enable step!");
}
// finally {
// shell.setCursor(null);
// waitCursor.dispose();
}
Aggregations