private void templateController_TemplateModelObjectChanged(object sender, TemplateControllerModelObjectReplacedEventArgs e)
 {
     EnableButtons();
 }
		private void templateController_TemplateModelObjectChanged(object sender, TemplateControllerModelObjectReplacedEventArgs e) {
			Debug.Assert(templateController != null && templateController.IsInitialized);
			if (templateController.WorkTemplate.Shape != null && templateController.WorkTemplate.Shape.ModelObject != null) {
				// Select appropiate Type in the newModelObject list
				int cnt = templateController.ModelObjects.Count;
				ModelObjectType modelObjectType = templateController.WorkTemplate.Shape.ModelObject.Type;
				foreach (IModelObject modelObject in templateController.ModelObjects) {
					if (modelObject.Type == modelObjectType) {
						modelObjectComboBox.SelectedItem = modelObject;
						break;
					}
				}
			}
		}