cayenne-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From abulat...@apache.org
Subject [cayenne] branch master updated: CAY-2561 Modeler: cgen type combobox doesn't set templates.
Date Tue, 09 Apr 2019 06:58:06 GMT
This is an automated email from the ASF dual-hosted git repository.

abulatski pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/cayenne.git


The following commit(s) were added to refs/heads/master by this push:
     new 1bc35c3  CAY-2561 Modeler: cgen type combobox doesn't set templates.
1bc35c3 is described below

commit 1bc35c3f9cf95e10b57ccd126a331b487e4ec868
Author: Arseni Bulatski <ancarseni@gmail.com>
AuthorDate: Tue Apr 9 09:55:38 2019 +0300

    CAY-2561 Modeler: cgen type combobox doesn't set templates.
---
 RELEASE-NOTES.txt                                        |  1 +
 .../modeler/editor/cgen/CustomModeController.java        | 16 +++++++++-------
 2 files changed, 10 insertions(+), 7 deletions(-)

diff --git a/RELEASE-NOTES.txt b/RELEASE-NOTES.txt
index b1eee3a0..df5df34 100644
--- a/RELEASE-NOTES.txt
+++ b/RELEASE-NOTES.txt
@@ -40,6 +40,7 @@ CAY-2537 Modeler: Schema Generation Complete popup window is hidden
 CAY-2544 Possible name clash of ivar and property name in generated class
 CAY-2547 CayenneDataObject serialization issue
 CAY-2559 Modeler: Warning dialog shows wrong information after changing target entity in
dbRelationship
+CAY-2561 Modeler: cgen type combobox doesn't set templates
 
 ----------------------------------
 Release: 4.1.B1
diff --git a/modeler/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/editor/cgen/CustomModeController.java
b/modeler/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/editor/cgen/CustomModeController.java
index e2d8408..f1d807b 100644
--- a/modeler/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/editor/cgen/CustomModeController.java
+++ b/modeler/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/editor/cgen/CustomModeController.java
@@ -19,13 +19,6 @@
 
 package org.apache.cayenne.modeler.editor.cgen;
 
-import org.apache.cayenne.gen.CgenConfiguration;
-import org.apache.cayenne.gen.ClassGenerationAction;
-import org.apache.cayenne.modeler.CodeTemplateManager;
-import org.apache.cayenne.modeler.dialog.cgen.TemplateDialog;
-import org.apache.cayenne.modeler.dialog.pref.PreferenceDialog;
-import org.apache.cayenne.swing.BindingBuilder;
-
 import javax.swing.DefaultComboBoxModel;
 import java.awt.Component;
 import java.nio.file.Paths;
@@ -33,6 +26,13 @@ import java.util.ArrayList;
 import java.util.Collections;
 import java.util.List;
 
+import org.apache.cayenne.gen.CgenConfiguration;
+import org.apache.cayenne.gen.ClassGenerationAction;
+import org.apache.cayenne.modeler.CodeTemplateManager;
+import org.apache.cayenne.modeler.dialog.cgen.TemplateDialog;
+import org.apache.cayenne.modeler.dialog.pref.PreferenceDialog;
+import org.apache.cayenne.swing.BindingBuilder;
+
 /**
  * @since 4.1
  * A controller for the custom generation mode.
@@ -184,5 +184,7 @@ public class CustomModeController extends GeneratorController {
     @Override
     public void updateConfiguration(CgenConfiguration cgenConfiguration) {
         cgenConfiguration.setClient(false);
+        cgenConfiguration.setTemplate(ClassGenerationAction.SUBCLASS_TEMPLATE);
+        cgenConfiguration.setSuperTemplate(ClassGenerationAction.SUPERCLASS_TEMPLATE);
     }
 }


Mime
View raw message