[isidorus-cvs] r725 - in branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets: base button complexData container environment isidorus text view
lgiessmann at common-lisp.net
lgiessmann at common-lisp.net
Mon Aug 15 07:59:53 UTC 2011
Author: lgiessmann
Date: Mon Aug 15 00:59:52 2011
New Revision: 725
Log:
gdl-frontend: Widgets: chaged the public construcgtors of GdlVisibleObject(s) to the signature (Topic tmRepresentative, Construct receivedData), so the consuming of received Topic Maps data can be implemented in each class
Modified:
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/base/GdlSpace.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/base/GdlVisibleObject.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/button/GdlActionButton.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/button/GdlButton.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/button/GdlCheckBox.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/button/GdlCommitButton.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/button/GdlCreateButton.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/button/GdlDeleteButton.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/button/GdlInputButton.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/button/GdlRadioButton.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/button/GdlValidateButton.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/complexData/GdlAudio.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/complexData/GdlComplexData.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/complexData/GdlDatePicker.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/complexData/GdlDateTimePicker.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/complexData/GdlImage.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/complexData/GdlTimePicker.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/complexData/GdlVideo.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/container/GdlList.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/container/GdlUnit.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/environment/GdlInstantiator.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/isidorus/LoadSchemaCallback.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/text/GdlInfo.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/text/GdlListBox.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/text/GdlReference.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/text/GdlText.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/text/GdlTextObject.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/text/GdlTitle.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlAssociationView.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlCreatorAssociationView.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlDefaultCreatorTopicView.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlDefaultEditorTopicView.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlDefaultTopicView.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlEditorAssociationView.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlSpecialCreatorTopicView.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlSpecialEditorTopicView.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlSpecialTopicView.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlTopicView.java
branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlView.java
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/base/GdlSpace.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/base/GdlSpace.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/base/GdlSpace.java Mon Aug 15 00:59:52 2011 (r725)
@@ -1,5 +1,6 @@
package us.isidor.gdl.anaToMia.Widgets.base;
+import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Construct;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Topic;
import us.isidor.gdl.anaToMia.Widgets.environment.ExecutionException;
import us.isidor.gdl.anaToMia.Widgets.environment.InvalidGdlSchemaException;
@@ -11,8 +12,8 @@
}
- public GdlSpace(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException{
- super(tmRepresentative);
+ public GdlSpace(Topic tmRepresentative, Construct receivedData) throws InvalidGdlSchemaException, ExecutionException{
+ super(tmRepresentative, receivedData);
this.setGdlStyle(this);
}
}
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/base/GdlVisibleObject.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/base/GdlVisibleObject.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/base/GdlVisibleObject.java Mon Aug 15 00:59:52 2011 (r725)
@@ -1,6 +1,9 @@
package us.isidor.gdl.anaToMia.Widgets.base;
import java.util.ArrayList;
+
+import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Association;
+import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Construct;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Occurrence;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Topic;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.TopicMap;
@@ -72,6 +75,7 @@
protected ArrayList<Pair<Widget, ArrayList<EventHandler>>> eventHandlers = new ArrayList<Pair<Widget, ArrayList<EventHandler>>>();
protected ArrayList<Pair<Topic, Integer>> actionButtonsAndPositions = null;
protected ArrayList<GdlInfo> infoElements = new ArrayList<GdlInfo>();
+ protected Construct receivedData = null;
// some constructors
@@ -81,10 +85,13 @@
}
- public GdlVisibleObject(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException{
+ public GdlVisibleObject(Topic tmRepresentative, Construct receivedData) throws InvalidGdlSchemaException, ExecutionException{
this();
this.tmRepresentative = tmRepresentative;
this.tm = this.tmRepresentative.getTopicMap();
+
+ if(!(receivedData instanceof Topic) && !(receivedData instanceof Association) && receivedData != null) throw new ExecutionException("receivedData must be either a Topic or an Association, but is: " + receivedData.getClass());
+ this.receivedData = receivedData;
this.setId(this.getId());
this.setGdlStyle();
@@ -102,7 +109,7 @@
ArrayList<Topic> infos = TmHelper.topicContainsInfo(this.tmRepresentative);
for (Topic info : infos){
- GdlInfo elem = (GdlInfo)GdlInstantiator.instantiate(info);
+ GdlInfo elem = (GdlInfo)GdlInstantiator.instantiate(info, this.receivedData);
this.infoElements.add(elem);
elem.setPosition(this);
}
@@ -151,7 +158,7 @@
// add buttons that are not bound to the current sub element, but belong to it
for (Topic currentButton : currentButtons)
- if(!((ButtonableObject)this.subElements.get(i)).containsButton(currentButton)) ((ButtonableObject)this.subElements.get(i)).addButton((GdlActionButton)GdlInstantiator.instantiate(currentButton));
+ if(!((ButtonableObject)this.subElements.get(i)).containsButton(currentButton)) ((ButtonableObject)this.subElements.get(i)).addButton((GdlActionButton)GdlInstantiator.instantiate(currentButton, null));
}
}
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/button/GdlActionButton.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/button/GdlActionButton.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/button/GdlActionButton.java Mon Aug 15 00:59:52 2011 (r725)
@@ -4,6 +4,8 @@
import com.google.gwt.event.dom.client.ClickHandler;
import com.google.gwt.user.client.DOM;
import com.google.gwt.user.client.ui.Button;
+
+import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Construct;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Occurrence;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Topic;
import us.isidor.gdl.anaToMia.Widgets.base.GdlPanel;
@@ -25,8 +27,8 @@
}
- public GdlActionButton(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException{
- super(tmRepresentative);
+ public GdlActionButton(Topic tmRepresentative, Construct receivedData) throws InvalidGdlSchemaException, ExecutionException{
+ super(tmRepresentative, receivedData);
// TODO: set all tm values
this.createButton().setText("Action-Button"); // TODO: remove set text
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/button/GdlButton.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/button/GdlButton.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/button/GdlButton.java Mon Aug 15 00:59:52 2011 (r725)
@@ -1,5 +1,6 @@
package us.isidor.gdl.anaToMia.Widgets.button;
+import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Construct;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Topic;
import us.isidor.gdl.anaToMia.Widgets.environment.ExecutionException;
import us.isidor.gdl.anaToMia.Widgets.environment.InvalidGdlSchemaException;
@@ -11,7 +12,7 @@
}
- public GdlButton(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException{
- super(tmRepresentative);
+ public GdlButton(Topic tmRepresentative, Construct receivedData) throws InvalidGdlSchemaException, ExecutionException{
+ super(tmRepresentative, receivedData);
}
}
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/button/GdlCheckBox.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/button/GdlCheckBox.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/button/GdlCheckBox.java Mon Aug 15 00:59:52 2011 (r725)
@@ -1,6 +1,8 @@
package us.isidor.gdl.anaToMia.Widgets.button;
import com.google.gwt.user.client.ui.CheckBox;
+
+import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Construct;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Topic;
import us.isidor.gdl.anaToMia.Widgets.environment.ExecutionException;
import us.isidor.gdl.anaToMia.Widgets.environment.InvalidGdlSchemaException;
@@ -11,8 +13,8 @@
}
- public GdlCheckBox(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException{
- super(tmRepresentative);
+ public GdlCheckBox(Topic tmRepresentative, Construct receivedData) throws InvalidGdlSchemaException, ExecutionException{
+ super(tmRepresentative, receivedData);
// TODO: create a check box for each tm construct
this.createcheckBox().setText("Check Box 1");
this.createcheckBox().setText("Check Box 2");
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/button/GdlCommitButton.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/button/GdlCommitButton.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/button/GdlCommitButton.java Mon Aug 15 00:59:52 2011 (r725)
@@ -1,5 +1,6 @@
package us.isidor.gdl.anaToMia.Widgets.button;
+import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Construct;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Topic;
import us.isidor.gdl.anaToMia.Widgets.environment.ExecutionException;
import us.isidor.gdl.anaToMia.Widgets.environment.InvalidGdlSchemaException;
@@ -13,8 +14,8 @@
}
- public GdlCommitButton(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException{
- super(tmRepresentative);
+ public GdlCommitButton(Topic tmRepresentative, Construct receivedData) throws InvalidGdlSchemaException, ExecutionException{
+ super(tmRepresentative, receivedData);
((Button)this.subElements.get(0)).setText("commit");
}
}
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/button/GdlCreateButton.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/button/GdlCreateButton.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/button/GdlCreateButton.java Mon Aug 15 00:59:52 2011 (r725)
@@ -1,5 +1,6 @@
package us.isidor.gdl.anaToMia.Widgets.button;
+import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Construct;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Topic;
import us.isidor.gdl.anaToMia.Widgets.environment.ExecutionException;
import us.isidor.gdl.anaToMia.Widgets.environment.InvalidGdlSchemaException;
@@ -13,8 +14,8 @@
}
- public GdlCreateButton(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException{
- super(tmRepresentative);
+ public GdlCreateButton(Topic tmRepresentative, Construct receivedData) throws InvalidGdlSchemaException, ExecutionException{
+ super(tmRepresentative, receivedData);
((Button)this.subElements.get(0)).setText("create");
}
}
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/button/GdlDeleteButton.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/button/GdlDeleteButton.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/button/GdlDeleteButton.java Mon Aug 15 00:59:52 2011 (r725)
@@ -3,6 +3,7 @@
import com.google.gwt.user.client.ui.Button;
+import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Construct;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Topic;
import us.isidor.gdl.anaToMia.Widgets.environment.ExecutionException;
import us.isidor.gdl.anaToMia.Widgets.environment.InvalidGdlSchemaException;
@@ -15,8 +16,8 @@
}
- public GdlDeleteButton(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException{
- super(tmRepresentative);
+ public GdlDeleteButton(Topic tmRepresentative, Construct receivedData) throws InvalidGdlSchemaException, ExecutionException{
+ super(tmRepresentative, receivedData);
((Button)this.subElements.get(0)).setText("delete");
}
}
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/button/GdlInputButton.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/button/GdlInputButton.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/button/GdlInputButton.java Mon Aug 15 00:59:52 2011 (r725)
@@ -1,5 +1,6 @@
package us.isidor.gdl.anaToMia.Widgets.button;
+import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Construct;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Topic;
import us.isidor.gdl.anaToMia.Widgets.environment.ExecutionException;
import us.isidor.gdl.anaToMia.Widgets.environment.InvalidGdlSchemaException;
@@ -10,8 +11,8 @@
}
- public GdlInputButton(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException{
- super(tmRepresentative);
+ public GdlInputButton(Topic tmRepresentative, Construct receivedData) throws InvalidGdlSchemaException, ExecutionException{
+ super(tmRepresentative, receivedData);
}
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/button/GdlRadioButton.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/button/GdlRadioButton.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/button/GdlRadioButton.java Mon Aug 15 00:59:52 2011 (r725)
@@ -2,6 +2,8 @@
import com.google.gwt.user.client.ui.RadioButton;
+
+import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Construct;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Topic;
import us.isidor.gdl.anaToMia.Widgets.environment.ExecutionException;
import us.isidor.gdl.anaToMia.Widgets.environment.InvalidGdlSchemaException;
@@ -12,8 +14,8 @@
}
- public GdlRadioButton(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException{
- super(tmRepresentative);
+ public GdlRadioButton(Topic tmRepresentative, Construct receivedData) throws InvalidGdlSchemaException, ExecutionException{
+ super(tmRepresentative, receivedData);
// TODO: create a radio button for each tm construct
this.createRadioButton().setText("Radio Button 1");
this.createRadioButton().setText("Radio Button 2");
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/button/GdlValidateButton.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/button/GdlValidateButton.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/button/GdlValidateButton.java Mon Aug 15 00:59:52 2011 (r725)
@@ -2,6 +2,7 @@
import com.google.gwt.user.client.ui.Button;
+import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Construct;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Topic;
import us.isidor.gdl.anaToMia.Widgets.environment.ExecutionException;
import us.isidor.gdl.anaToMia.Widgets.environment.InvalidGdlSchemaException;
@@ -14,8 +15,8 @@
}
- public GdlValidateButton(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException{
- super(tmRepresentative);
+ public GdlValidateButton(Topic tmRepresentative, Construct receivedData) throws InvalidGdlSchemaException, ExecutionException{
+ super(tmRepresentative, receivedData);
((Button)this.subElements.get(0)).setText("validate");
}
}
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/complexData/GdlAudio.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/complexData/GdlAudio.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/complexData/GdlAudio.java Mon Aug 15 00:59:52 2011 (r725)
@@ -1,5 +1,6 @@
package us.isidor.gdl.anaToMia.Widgets.complexData;
+import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Construct;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Topic;
import us.isidor.gdl.anaToMia.Widgets.base.GdlPsis;
import us.isidor.gdl.anaToMia.Widgets.environment.ExecutionException;
@@ -12,7 +13,7 @@
}
- public GdlAudio(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException{
+ public GdlAudio(Topic tmRepresentative, Construct receivedData) throws InvalidGdlSchemaException, ExecutionException{
this();
}
}
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/complexData/GdlComplexData.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/complexData/GdlComplexData.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/complexData/GdlComplexData.java Mon Aug 15 00:59:52 2011 (r725)
@@ -1,5 +1,6 @@
package us.isidor.gdl.anaToMia.Widgets.complexData;
+import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Construct;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Topic;
import us.isidor.gdl.anaToMia.Widgets.base.GdlVisibleObject;
import us.isidor.gdl.anaToMia.Widgets.environment.ExecutionException;
@@ -12,7 +13,7 @@
}
- public GdlComplexData(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException{
- super(tmRepresentative);
+ public GdlComplexData(Topic tmRepresentative, Construct receivedData) throws InvalidGdlSchemaException, ExecutionException{
+ super(tmRepresentative, receivedData);
}
}
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/complexData/GdlDatePicker.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/complexData/GdlDatePicker.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/complexData/GdlDatePicker.java Mon Aug 15 00:59:52 2011 (r725)
@@ -22,6 +22,8 @@
import com.google.gwt.event.shared.HandlerRegistration;
import com.google.gwt.user.client.DOM;
import com.google.gwt.user.datepicker.client.DatePicker;
+
+import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Construct;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Topic;
import us.isidor.gdl.anaToMia.Widgets.base.ButtonableObject;
import us.isidor.gdl.anaToMia.Widgets.environment.ActiveStyleHandler;
@@ -40,8 +42,8 @@
}
- public GdlDatePicker(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException{
- super(tmRepresentative);
+ public GdlDatePicker(Topic tmRepresentative, Construct receivedData) throws InvalidGdlSchemaException, ExecutionException{
+ super(tmRepresentative, receivedData);
// create a date widget for each tm-construct
this.createDateWidget();
this.setNthButtons();
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/complexData/GdlDateTimePicker.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/complexData/GdlDateTimePicker.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/complexData/GdlDateTimePicker.java Mon Aug 15 00:59:52 2011 (r725)
@@ -1,5 +1,6 @@
package us.isidor.gdl.anaToMia.Widgets.complexData;
+import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Construct;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Topic;
import us.isidor.gdl.anaToMia.Widgets.environment.ExecutionException;
import us.isidor.gdl.anaToMia.Widgets.environment.InvalidGdlSchemaException;
@@ -14,8 +15,8 @@
}
- public GdlDateTimePicker(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException{
- super(tmRepresentative);
+ public GdlDateTimePicker(Topic tmRepresentative, Construct receivedData) throws InvalidGdlSchemaException, ExecutionException{
+ super(tmRepresentative, receivedData);
// create a date-time widget for each tm-construct
}
}
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/complexData/GdlImage.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/complexData/GdlImage.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/complexData/GdlImage.java Mon Aug 15 00:59:52 2011 (r725)
@@ -1,5 +1,6 @@
package us.isidor.gdl.anaToMia.Widgets.complexData;
+import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Construct;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Topic;
import us.isidor.gdl.anaToMia.Widgets.base.GdlPsis;
import us.isidor.gdl.anaToMia.Widgets.environment.ExecutionException;
@@ -12,7 +13,7 @@
}
- public GdlImage(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException{
+ public GdlImage(Topic tmRepresentative, Construct receivedData) throws InvalidGdlSchemaException, ExecutionException{
this();
}
}
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/complexData/GdlTimePicker.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/complexData/GdlTimePicker.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/complexData/GdlTimePicker.java Mon Aug 15 00:59:52 2011 (r725)
@@ -1,5 +1,6 @@
package us.isidor.gdl.anaToMia.Widgets.complexData;
+import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Construct;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Topic;
import us.isidor.gdl.anaToMia.Widgets.environment.ExecutionException;
import us.isidor.gdl.anaToMia.Widgets.environment.InvalidGdlSchemaException;
@@ -14,8 +15,8 @@
}
- public GdlTimePicker(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException{
- super(tmRepresentative);
+ public GdlTimePicker(Topic tmRepresentative, Construct receivedData) throws InvalidGdlSchemaException, ExecutionException{
+ super(tmRepresentative, receivedData);
// create a time widget for each tm-construct
}
}
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/complexData/GdlVideo.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/complexData/GdlVideo.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/complexData/GdlVideo.java Mon Aug 15 00:59:52 2011 (r725)
@@ -1,5 +1,6 @@
package us.isidor.gdl.anaToMia.Widgets.complexData;
+import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Construct;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Topic;
import us.isidor.gdl.anaToMia.Widgets.base.GdlPsis;
import us.isidor.gdl.anaToMia.Widgets.environment.ExecutionException;
@@ -12,7 +13,7 @@
}
- public GdlVideo(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException{
+ public GdlVideo(Topic tmRepresentative, Construct receivedData) throws InvalidGdlSchemaException, ExecutionException{
this();
}
}
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/container/GdlList.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/container/GdlList.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/container/GdlList.java Mon Aug 15 00:59:52 2011 (r725)
@@ -26,6 +26,8 @@
import com.google.gwt.event.dom.client.MouseUpEvent;
import com.google.gwt.event.dom.client.MouseUpHandler;
import com.google.gwt.event.shared.HandlerRegistration;
+
+import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Construct;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Occurrence;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Topic;
import us.isidor.gdl.anaToMia.Widgets.base.ButtonableObject;
@@ -56,8 +58,8 @@
}
- public GdlList(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException{
- super(tmRepresentative);
+ public GdlList(Topic tmRepresentative, Construct receivedData) throws InvalidGdlSchemaException, ExecutionException{
+ super(tmRepresentative, receivedData);
this.createList();
ArrayList<Topic> objectsContained = this.contains();
@@ -407,7 +409,7 @@
for (Pair<Topic, Integer> pair : this.storedItems) if(pair.getFirst().equals(current)) idx = pair.getSecond();
ListWidget list = (ListWidget)((ButtonableObject)this.subElements.get(0)).getMainObject();
- GdlVisibleObject newObj = GdlInstantiator.instantiate(current);
+ GdlVisibleObject newObj = GdlInstantiator.instantiate(current, this.receivedData);
list.insertWidget(newObj, idx);
return newObj;
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/container/GdlUnit.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/container/GdlUnit.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/container/GdlUnit.java Mon Aug 15 00:59:52 2011 (r725)
@@ -26,6 +26,8 @@
import com.google.gwt.user.client.ui.CaptionPanel;
import com.google.gwt.user.client.ui.Composite;
import com.google.gwt.user.client.ui.Widget;
+
+import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Construct;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Occurrence;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Topic;
import us.isidor.gdl.anaToMia.Widgets.base.ButtonableObject;
@@ -53,8 +55,8 @@
}
- public GdlUnit(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException{
- super(tmRepresentative);
+ public GdlUnit(Topic tmRepresentative, Construct receivedData) throws InvalidGdlSchemaException, ExecutionException{
+ super(tmRepresentative, receivedData);
// create a unit for each tm-element
this.createUnit();
this.setNthButtons();
@@ -221,7 +223,7 @@
if(ancestor == null || current == null) throw new ExecutionException("to append \"" + TmHelper.getAnyIdOfTopic(current) + "\" on \"" + TmHelper.getAnyIdOfTopic(ancestor) + "\" both topics must be present");
GdlPosition position = new GdlPosition(TmHelper.getPositionOf(ancestor, current));
- GdlVisibleObject newObj = GdlInstantiator.instantiate(current);
+ GdlVisibleObject newObj = GdlInstantiator.instantiate(current, GdlUnit.this.receivedData);
GdlVisibleObject oldObj = null;
for (Widget widget : this.subElements){
if(((GdlVisibleObject)widget).getTmRepresentative().equals(ancestor)){
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/environment/GdlInstantiator.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/environment/GdlInstantiator.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/environment/GdlInstantiator.java Mon Aug 15 00:59:52 2011 (r725)
@@ -2,6 +2,9 @@
import java.util.ArrayList;
+
+import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Association;
+import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Construct;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Topic;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.TopicMap;
import us.isidor.gdl.anaToMia.Widgets.base.GdlSpace;
@@ -40,61 +43,67 @@
public class GdlInstantiator {
// returns a java instance of a GdlVisibleObject that corresponds to the
// set topic type of the passed topic instance
- public static GdlVisibleObject instantiate(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException{
+ public static GdlVisibleObject instantiate(Topic tmRepresentative, Construct receivedData) throws InvalidGdlSchemaException, ExecutionException{
+ if(!(receivedData instanceof Topic) && !(receivedData instanceof Association) && receivedData != null) throw new ExecutionException("receivedData must be either a Topic or an Association, but is: " + receivedData.getClass());
+
if(TmHelper.isInstanceOf(tmRepresentative, GdlPsis.TopicType.gdlSpace)){
- return new GdlSpace(tmRepresentative);
+ return new GdlSpace(tmRepresentative, receivedData);
}else if(TmHelper.isInstanceOf(tmRepresentative, GdlPsis.TopicType.gdlTitle)){
- return new GdlTitle(tmRepresentative);
+ return new GdlTitle(tmRepresentative, receivedData);
}else if(TmHelper.isInstanceOf(tmRepresentative, GdlPsis.TopicType.gdlInfo)){
- return new GdlInfo(tmRepresentative);
+ return new GdlInfo(tmRepresentative, receivedData);
}else if(TmHelper.isInstanceOf(tmRepresentative, GdlPsis.TopicType.gdlReference)){
- return new GdlReference(tmRepresentative);
+ return new GdlReference(tmRepresentative, receivedData);
}else if(TmHelper.isInstanceOf(tmRepresentative, GdlPsis.TopicType.gdlRadioButton)){
- return new GdlRadioButton(tmRepresentative);
+ return new GdlRadioButton(tmRepresentative, receivedData);
}else if(TmHelper.isInstanceOf(tmRepresentative, GdlPsis.TopicType.gdlCheckBox)){
- return new GdlCheckBox(tmRepresentative);
+ return new GdlCheckBox(tmRepresentative, receivedData);
}else if(TmHelper.isInstanceOf(tmRepresentative, GdlPsis.TopicType.gdlValidateButton)){
- return new GdlValidateButton(tmRepresentative);
+ return new GdlValidateButton(tmRepresentative, receivedData);
}else if(TmHelper.isInstanceOf(tmRepresentative, GdlPsis.TopicType.gdlCreateButton)){
- return new GdlCreateButton(tmRepresentative);
+ return new GdlCreateButton(tmRepresentative, receivedData);
}else if(TmHelper.isInstanceOf(tmRepresentative, GdlPsis.TopicType.gdlDeleteButton)){
- return new GdlDeleteButton(tmRepresentative);
+ return new GdlDeleteButton(tmRepresentative, receivedData);
}else if(TmHelper.isInstanceOf(tmRepresentative, GdlPsis.TopicType.gdlCommitButton)){
- return new GdlCommitButton(tmRepresentative);
+ return new GdlCommitButton(tmRepresentative, receivedData);
}else if(TmHelper.isInstanceOf(tmRepresentative, GdlPsis.TopicType.gdlActionButton)){
- return new GdlActionButton(tmRepresentative);
+ return new GdlActionButton(tmRepresentative, receivedData);
}else if(TmHelper.isInstanceOf(tmRepresentative, GdlPsis.TopicType.gdlImage)){
- return new GdlImage(tmRepresentative);
+ return new GdlImage(tmRepresentative, receivedData);
}else if(TmHelper.isInstanceOf(tmRepresentative, GdlPsis.TopicType.gdlVideo)){
- return new GdlVideo(tmRepresentative);
+ return new GdlVideo(tmRepresentative, receivedData);
}else if(TmHelper.isInstanceOf(tmRepresentative, GdlPsis.TopicType.gdlAudio)){
- return new GdlAudio(tmRepresentative);
+ return new GdlAudio(tmRepresentative, receivedData);
}else if(TmHelper.isInstanceOf(tmRepresentative, GdlPsis.TopicType.gdlDatePicker)){
- return new GdlDatePicker(tmRepresentative);
+ return new GdlDatePicker(tmRepresentative, receivedData);
}else if(TmHelper.isInstanceOf(tmRepresentative, GdlPsis.TopicType.gdlTimePicker)){
- return new GdlTimePicker(tmRepresentative);
+ return new GdlTimePicker(tmRepresentative, receivedData);
}else if(TmHelper.isInstanceOf(tmRepresentative, GdlPsis.TopicType.gdlDateTimePicker)){
- return new GdlDateTimePicker(tmRepresentative);
+ return new GdlDateTimePicker(tmRepresentative, receivedData);
}else if(TmHelper.isInstanceOf(tmRepresentative, GdlPsis.TopicType.gdlUnit)){
- return new GdlUnit(tmRepresentative);
+ return new GdlUnit(tmRepresentative, receivedData);
}else if(TmHelper.isInstanceOf(tmRepresentative, GdlPsis.TopicType.gdlText)){
- return new GdlText(tmRepresentative);
+ return new GdlText(tmRepresentative, receivedData);
}else if(TmHelper.isInstanceOf(tmRepresentative, GdlPsis.TopicType.gdlList)){
- return new GdlList(tmRepresentative);
+ return new GdlList(tmRepresentative, receivedData);
}else if(TmHelper.isInstanceOf(tmRepresentative, GdlPsis.TopicType.gdlListBox)){
- return new GdlListBox(tmRepresentative);
+ return new GdlListBox(tmRepresentative, receivedData);
}else if(TmHelper.isInstanceOf(tmRepresentative, GdlPsis.TopicType.gdlDefaultCreatorTopicView)){
return new GdlDefaultCreatorTopicView(tmRepresentative);
}else if(TmHelper.isInstanceOf(tmRepresentative, GdlPsis.TopicType.gdlDefaultEditorTopicView)){
- return new GdlDefaultEditorTopicView(tmRepresentative);
+ if(!(receivedData instanceof Topic)) throw new ExecutionException("receivedData must be of type Topic when used with " + GdlPsis.TopicType.gdlDefaultEditorTopicView);
+ return new GdlDefaultEditorTopicView(tmRepresentative, (Topic)receivedData);
}else if(TmHelper.isInstanceOf(tmRepresentative, GdlPsis.TopicType.gdlSpecialCreatorTopicView)){
return new GdlSpecialCreatorTopicView(tmRepresentative);
}else if(TmHelper.isInstanceOf(tmRepresentative, GdlPsis.TopicType.gdlSpecialEditorTopicView)){
- return new GdlSpecialEditorTopicView(tmRepresentative);
+ if(!(receivedData instanceof Topic)) throw new ExecutionException("receivedData must be of type Topic when used with " + GdlPsis.TopicType.gdlSpecialEditorTopicView);
+ return new GdlSpecialEditorTopicView(tmRepresentative, (Topic)receivedData);
}else if(TmHelper.isInstanceOf(tmRepresentative, GdlPsis.TopicType.gdlCreatorAssociationview)){
- return new GdlCreatorAssociationView(tmRepresentative);
+ if(!(receivedData instanceof Topic)) throw new ExecutionException("receivedData must be of type Association when used with " + GdlPsis.TopicType.gdlCreatorAssociationview);
+ return new GdlCreatorAssociationView(tmRepresentative, (Association)receivedData);
}else if(TmHelper.isInstanceOf(tmRepresentative, GdlPsis.TopicType.gdlEditorAssociationView)){
- return new GdlEditorAssociationView(tmRepresentative);
+ if(!(receivedData instanceof Topic)) throw new ExecutionException("receivedData must be of type Associaiton when used with " + GdlPsis.TopicType.gdlEditorAssociationView);
+ return new GdlEditorAssociationView(tmRepresentative, (Association)receivedData);
}else{
String values = "";
for(int i = 0; i != tmRepresentative.getTypes().length(); ++i){
@@ -205,7 +214,7 @@
}
if(views.size() == 1){
- return new GdlDefaultEditorTopicView(views.get(0));
+ return new GdlDefaultEditorTopicView(views.get(0), requestedTop);
}else if(views.size() > 1){
String bindings = "";
for (Topic top : views)
@@ -232,7 +241,7 @@
throw new InvalidGdlSchemaException("the combination of topic types (" + values + ") for the requested topic " + requestedTopic.getFirst() + " must be bound exactly once to a " + GdlPsis.TopicType.gdlDefaultEditorTopicView + " but is bound to " + bindings);
}
- return new GdlDefaultEditorTopicView(views.get(0));
+ return new GdlDefaultEditorTopicView(views.get(0), requestedTop);
}
}
}
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/isidorus/LoadSchemaCallback.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/isidorus/LoadSchemaCallback.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/isidorus/LoadSchemaCallback.java Mon Aug 15 00:59:52 2011 (r725)
@@ -23,7 +23,7 @@
// this class can be used as a callback that requests the Topic Map data
// addressable by the URI isidorusUrl
public class LoadSchemaCallback implements ILoadSchemaCallback{
- private final String isidorusUrl = URL.encode(GWT.getModuleBaseURL() + "test.gdl.2.jtm"); // TODO: replace with the correct URL
+ private final String isidorusUrl = URL.encode(GWT.getModuleBaseURL() + "test.gdl.jtm"); //"TextGrid.jtm"); // TODO: replace with the correct URL
private ArrayList<Pair<String, TopicIdentifierTypes>> requestedTopicsToCreate = new ArrayList<Pair<String,TopicIdentifierTypes>>();
private Pair<String, TopicIdentifierTypes> requestedTopicToEdit = null;
private RequestBuilder requestBuilder = new RequestBuilder(RequestBuilder.GET, isidorusUrl);
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/text/GdlInfo.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/text/GdlInfo.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/text/GdlInfo.java Mon Aug 15 00:59:52 2011 (r725)
@@ -7,6 +7,8 @@
import com.google.gwt.user.client.DOM;
import com.google.gwt.user.client.ui.Label;
import com.google.gwt.user.client.ui.RootPanel;
+
+import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Construct;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Topic;
import us.isidor.gdl.anaToMia.Widgets.base.GdlVisibleObject;
import us.isidor.gdl.anaToMia.Widgets.environment.ExecutionException;
@@ -23,8 +25,8 @@
}
- public GdlInfo(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException{
- super(tmRepresentative);
+ public GdlInfo(Topic tmRepresentative, Construct receivedData) throws InvalidGdlSchemaException, ExecutionException{
+ super(tmRepresentative, receivedData);
RootPanel.get().add(this);
super.setGdlStyle();
// TODO: create an info element for each tm construct
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/text/GdlListBox.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/text/GdlListBox.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/text/GdlListBox.java Mon Aug 15 00:59:52 2011 (r725)
@@ -6,6 +6,8 @@
import com.google.gwt.user.client.DOM;
import com.google.gwt.user.client.ui.ListBox;
import com.google.gwt.user.client.ui.Widget;
+
+import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Construct;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Occurrence;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Topic;
import us.isidor.gdl.anaToMia.Widgets.base.GdlPsis;
@@ -23,8 +25,8 @@
}
- public GdlListBox(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException{
- super(tmRepresentative);
+ public GdlListBox(Topic tmRepresentative, Construct receivedData) throws InvalidGdlSchemaException, ExecutionException{
+ super(tmRepresentative, receivedData);
// TODO: create a ListBox element for each TM-elem
this.createNewListBox().addItem("List-Box");
this.setNthButtons();
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/text/GdlReference.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/text/GdlReference.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/text/GdlReference.java Mon Aug 15 00:59:52 2011 (r725)
@@ -12,6 +12,8 @@
import com.google.gwt.user.client.DOM;
import com.google.gwt.user.client.Window;
import com.google.gwt.user.client.ui.Label;
+
+import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Construct;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Occurrence;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Topic;
import us.isidor.gdl.anaToMia.Widgets.base.GdlPsis;
@@ -31,8 +33,8 @@
super();
}
- public GdlReference(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException{
- super(tmRepresentative);
+ public GdlReference(Topic tmRepresentative, Construct receivedData) throws InvalidGdlSchemaException, ExecutionException{
+ super(tmRepresentative, receivedData);
// TODO: create a Reference element for each TM-elem
ReferenceWidget ref = this.createReference(); // TODO: remove
ref.setText("Reference"); // TODO: remove
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/text/GdlText.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/text/GdlText.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/text/GdlText.java Mon Aug 15 00:59:52 2011 (r725)
@@ -58,8 +58,8 @@
}
- public GdlText(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException{
- super(tmRepresentative);
+ public GdlText(Topic tmRepresentative, Construct receivedData) throws InvalidGdlSchemaException, ExecutionException{
+ super(tmRepresentative, receivedData);
// TODO: create a text element for each TM-elem
this.createNewTextArea().setText("Text"); // TODO: remove only for debugging
this.setNthButtons();
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/text/GdlTextObject.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/text/GdlTextObject.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/text/GdlTextObject.java Mon Aug 15 00:59:52 2011 (r725)
@@ -2,6 +2,8 @@
import com.google.gwt.dom.client.Style.FontStyle;
import com.google.gwt.user.client.ui.Widget;
+
+import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Construct;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Occurrence;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Topic;
import us.isidor.gdl.anaToMia.Widgets.base.GdlPsis;
@@ -25,8 +27,8 @@
}
- public GdlTextObject(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException{
- super(tmRepresentative);
+ public GdlTextObject(Topic tmRepresentative, Construct receivedData) throws InvalidGdlSchemaException, ExecutionException{
+ super(tmRepresentative, receivedData);
super.setGdlStyle();
}
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/text/GdlTitle.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/text/GdlTitle.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/text/GdlTitle.java Mon Aug 15 00:59:52 2011 (r725)
@@ -1,6 +1,8 @@
package us.isidor.gdl.anaToMia.Widgets.text;
import java.util.ArrayList;
+
+import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Construct;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Occurrence;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Topic;
import us.isidor.gdl.anaToMia.Widgets.base.GdlPsis;
@@ -55,8 +57,8 @@
}
- public GdlTitle(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException{
- super(tmRepresentative);
+ public GdlTitle(Topic tmRepresentative, Construct receivedData) throws InvalidGdlSchemaException, ExecutionException{
+ super(tmRepresentative, receivedData);
// TODO: create a Title element for each TM-elem
this.createTitle().setText("Title");
this.setNthButtons();
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlAssociationView.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlAssociationView.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlAssociationView.java Mon Aug 15 00:59:52 2011 (r725)
@@ -1,5 +1,6 @@
package us.isidor.gdl.anaToMia.Widgets.view;
+import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Association;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Topic;
import us.isidor.gdl.anaToMia.Widgets.environment.ExecutionException;
import us.isidor.gdl.anaToMia.Widgets.environment.InvalidGdlSchemaException;
@@ -7,8 +8,8 @@
public abstract class GdlAssociationView extends GdlView {
- public GdlAssociationView(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException {
- super(tmRepresentative);
+ public GdlAssociationView(Topic tmRepresentative, Association receivedData) throws InvalidGdlSchemaException, ExecutionException {
+ super(tmRepresentative, receivedData);
// TODO Auto-generated constructor stub
}
// TODO: implement
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlCreatorAssociationView.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlCreatorAssociationView.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlCreatorAssociationView.java Mon Aug 15 00:59:52 2011 (r725)
@@ -1,5 +1,6 @@
package us.isidor.gdl.anaToMia.Widgets.view;
+import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Association;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Topic;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.TopicMap;
import us.isidor.gdl.anaToMia.Widgets.environment.ExecutionException;
@@ -8,8 +9,8 @@
public class GdlCreatorAssociationView extends GdlAssociationView {
- public GdlCreatorAssociationView(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException {
- super(tmRepresentative);
+ public GdlCreatorAssociationView(Topic tmRepresentative, Association receivedData) throws InvalidGdlSchemaException, ExecutionException {
+ super(tmRepresentative, receivedData);
// TODO Auto-generated constructor stub
}
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlDefaultCreatorTopicView.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlDefaultCreatorTopicView.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlDefaultCreatorTopicView.java Mon Aug 15 00:59:52 2011 (r725)
@@ -11,7 +11,7 @@
// TODO: implement
public GdlDefaultCreatorTopicView(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException {
- super(tmRepresentative);
+ super(tmRepresentative, null);
// TODO Auto-generated constructor stub
}
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlDefaultEditorTopicView.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlDefaultEditorTopicView.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlDefaultEditorTopicView.java Mon Aug 15 00:59:52 2011 (r725)
@@ -8,8 +8,8 @@
public class GdlDefaultEditorTopicView extends GdlDefaultTopicView {
- public GdlDefaultEditorTopicView(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException {
- super(tmRepresentative);
+ public GdlDefaultEditorTopicView(Topic tmRepresentative, Topic receivedData) throws InvalidGdlSchemaException, ExecutionException {
+ super(tmRepresentative, receivedData);
// TODO Auto-generated constructor stub
}
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlDefaultTopicView.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlDefaultTopicView.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlDefaultTopicView.java Mon Aug 15 00:59:52 2011 (r725)
@@ -6,8 +6,8 @@
public abstract class GdlDefaultTopicView extends GdlTopicView {
- public GdlDefaultTopicView(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException {
- super(tmRepresentative);
+ public GdlDefaultTopicView(Topic tmRepresentative, Topic receivedData) throws InvalidGdlSchemaException, ExecutionException {
+ super(tmRepresentative, receivedData);
// TODO Auto-generated constructor stub
}
// TODO: implement
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlEditorAssociationView.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlEditorAssociationView.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlEditorAssociationView.java Mon Aug 15 00:59:52 2011 (r725)
@@ -1,6 +1,7 @@
package us.isidor.gdl.anaToMia.Widgets.view;
+import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Association;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Topic;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.TopicMap;
import us.isidor.gdl.anaToMia.Widgets.environment.ExecutionException;
@@ -9,8 +10,8 @@
public class GdlEditorAssociationView extends GdlAssociationView {
- public GdlEditorAssociationView(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException {
- super(tmRepresentative);
+ public GdlEditorAssociationView(Topic tmRepresentative, Association receivedData) throws InvalidGdlSchemaException, ExecutionException {
+ super(tmRepresentative, receivedData);
// TODO Auto-generated constructor stub
}
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlSpecialCreatorTopicView.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlSpecialCreatorTopicView.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlSpecialCreatorTopicView.java Mon Aug 15 00:59:52 2011 (r725)
@@ -10,7 +10,7 @@
// TODO: implement
public GdlSpecialCreatorTopicView(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException {
- super(tmRepresentative);
+ super(tmRepresentative, null);
// TODO Auto-generated constructor stub
}
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlSpecialEditorTopicView.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlSpecialEditorTopicView.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlSpecialEditorTopicView.java Mon Aug 15 00:59:52 2011 (r725)
@@ -10,8 +10,8 @@
// TODO: implement
- public GdlSpecialEditorTopicView(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException {
- super(tmRepresentative);
+ public GdlSpecialEditorTopicView(Topic tmRepresentative, Topic receivedData) throws InvalidGdlSchemaException, ExecutionException {
+ super(tmRepresentative, receivedData);
// TODO Auto-generated constructor stub
}
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlSpecialTopicView.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlSpecialTopicView.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlSpecialTopicView.java Mon Aug 15 00:59:52 2011 (r725)
@@ -6,8 +6,8 @@
public abstract class GdlSpecialTopicView extends GdlTopicView {
- public GdlSpecialTopicView(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException {
- super(tmRepresentative);
+ public GdlSpecialTopicView(Topic tmRepresentative, Topic receivedData) throws InvalidGdlSchemaException, ExecutionException {
+ super(tmRepresentative, receivedData);
// TODO Auto-generated constructor stub
}
// TODO: implement
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlTopicView.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlTopicView.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlTopicView.java Mon Aug 15 00:59:52 2011 (r725)
@@ -7,7 +7,7 @@
public abstract class GdlTopicView extends GdlView {
- public GdlTopicView(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException{
- super(tmRepresentative);
+ public GdlTopicView(Topic tmRepresentative, Topic receivedData) throws InvalidGdlSchemaException, ExecutionException{
+ super(tmRepresentative, receivedData);
}
}
Modified: branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlView.java
==============================================================================
--- branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlView.java Fri Aug 12 11:06:46 2011 (r724)
+++ branches/gdl-frontend/src/anaToMia/GDL_Widgets/src/us/isidor/gdl/anaToMia/Widgets/view/GdlView.java Mon Aug 15 00:59:52 2011 (r725)
@@ -3,6 +3,8 @@
import java.util.ArrayList;
import com.google.gwt.core.client.JsArray;
import com.google.gwt.user.client.ui.Widget;
+
+import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Construct;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Name;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.Topic;
import us.isidor.gdl.anaToMia.TopicMaps.TopicMapsModel.TopicMap;
@@ -24,8 +26,8 @@
}
- public GdlView(Topic tmRepresentative) throws InvalidGdlSchemaException, ExecutionException{
- super(tmRepresentative);
+ public GdlView(Topic tmRepresentative, Construct receivedData) throws InvalidGdlSchemaException, ExecutionException{
+ super(tmRepresentative, receivedData);
ArrayList<Topic> objectsContained = this.contains();
Topic currentTopic = this.getStartElement(objectsContained);
@@ -96,7 +98,7 @@
if(ancestor == null || current == null) throw new ExecutionException("to append \"" + TmHelper.getAnyIdOfTopic(current) + "\" on \"" + TmHelper.getAnyIdOfTopic(ancestor) + "\" both topics must be present");
GdlPosition position = new GdlPosition(TmHelper.getPositionOf(ancestor, current));
- GdlVisibleObject newObj = GdlInstantiator.instantiate(current);
+ GdlVisibleObject newObj = GdlInstantiator.instantiate(current, this.receivedData);
GdlVisibleObject oldObj = null;
for (Widget widget : super.subElements){
if(((GdlVisibleObject)widget).getTmRepresentative().equals(ancestor)){
More information about the Isidorus-cvs
mailing list