cayenne-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kmen...@apache.org
Subject svn commit: r640214 - in /cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler: action/ dialog/
Date Sun, 23 Mar 2008 15:05:01 GMT
Author: kmenard
Date: Sun Mar 23 08:04:58 2008
New Revision: 640214

URL: http://svn.apache.org/viewvc?rev=640214&view=rev
Log:
CAY-1011: Add confirmation dialog for delete actions.

Rename the dialog to match the action name.

Added:
    cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/dialog/ConfirmRemoveDialog.java
      - copied, changed from r640213, cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/dialog/ConfirmDeleteDialog.java
Removed:
    cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/dialog/ConfirmDeleteDialog.java
Modified:
    cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/action/AbstractRemoveCallbackMethodAction.java
    cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/action/RemoveAction.java
    cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/action/RemoveAttributeAction.java
    cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/action/RemoveEntityListenerAction.java
    cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/action/RemoveEntityListenerForDataMapAction.java
    cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/action/RemoveProcedureParameterAction.java
    cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/action/RemoveRelationshipAction.java

Modified: cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/action/AbstractRemoveCallbackMethodAction.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/action/AbstractRemoveCallbackMethodAction.java?rev=640214&r1=640213&r2=640214&view=diff
==============================================================================
--- cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/action/AbstractRemoveCallbackMethodAction.java
(original)
+++ cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/action/AbstractRemoveCallbackMethodAction.java
Sun Mar 23 08:04:58 2008
@@ -24,10 +24,9 @@
 import org.apache.cayenne.map.event.MapEvent;
 import org.apache.cayenne.modeler.Application;
 import org.apache.cayenne.modeler.ProjectController;
-import org.apache.cayenne.modeler.dialog.ConfirmDeleteDialog;
+import org.apache.cayenne.modeler.dialog.ConfirmRemoveDialog;
 import org.apache.cayenne.modeler.editor.CallbackType;
 import org.apache.cayenne.modeler.event.CallbackMethodEvent;
-import org.apache.cayenne.modeler.util.CayenneAction;
 
 /**
  * Base class for removing callback methofs
@@ -64,7 +63,7 @@
      * @param e event
      */
     public final void performAction(ActionEvent e) {
-        ConfirmDeleteDialog dialog = getConfirmDeleteDialog();        
+        ConfirmRemoveDialog dialog = getConfirmDeleteDialog();
 
         if (getProjectController().getCurrentCallbackMethod() != null) {
             if (dialog.shouldDelete("callback method", getProjectController()

Modified: cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/action/RemoveAction.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/action/RemoveAction.java?rev=640214&r1=640213&r2=640214&view=diff
==============================================================================
--- cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/action/RemoveAction.java
(original)
+++ cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/action/RemoveAction.java
Sun Mar 23 08:04:58 2008
@@ -47,7 +47,7 @@
 import org.apache.cayenne.map.event.QueryEvent;
 import org.apache.cayenne.modeler.Application;
 import org.apache.cayenne.modeler.ProjectController;
-import org.apache.cayenne.modeler.dialog.ConfirmDeleteDialog;
+import org.apache.cayenne.modeler.dialog.ConfirmRemoveDialog;
 import org.apache.cayenne.modeler.util.CayenneAction;
 import org.apache.cayenne.project.ApplicationProject;
 import org.apache.cayenne.project.ProjectPath;
@@ -80,15 +80,15 @@
         return KeyStroke.getKeyStroke(KeyEvent.VK_D, Toolkit.getDefaultToolkit().getMenuShortcutKeyMask());
     }
 
-    public ConfirmDeleteDialog getConfirmDeleteDialog() {
-        return new ConfirmDeleteDialog();
+    public ConfirmRemoveDialog getConfirmDeleteDialog() {
+        return new ConfirmRemoveDialog();
     }
 
     public void performAction(ActionEvent e) {
 
         ProjectController mediator = getProjectController();
 
-        ConfirmDeleteDialog dialog = getConfirmDeleteDialog();
+        ConfirmRemoveDialog dialog = getConfirmDeleteDialog();
 
         if (mediator.getCurrentObjEntity() != null) {
             if (dialog.shouldDelete("ObjEntity", mediator.getCurrentObjEntity().getName()))
{

Modified: cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/action/RemoveAttributeAction.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/action/RemoveAttributeAction.java?rev=640214&r1=640213&r2=640214&view=diff
==============================================================================
--- cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/action/RemoveAttributeAction.java
(original)
+++ cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/action/RemoveAttributeAction.java
Sun Mar 23 08:04:58 2008
@@ -31,7 +31,7 @@
 import org.apache.cayenne.map.event.MapEvent;
 import org.apache.cayenne.modeler.Application;
 import org.apache.cayenne.modeler.ProjectController;
-import org.apache.cayenne.modeler.dialog.ConfirmDeleteDialog;
+import org.apache.cayenne.modeler.dialog.ConfirmRemoveDialog;
 import org.apache.cayenne.modeler.util.ProjectUtil;
 import org.apache.cayenne.project.ProjectPath;
 
@@ -65,7 +65,7 @@
     }
 
     public void performAction(ActionEvent e) {
-        ConfirmDeleteDialog dialog = getConfirmDeleteDialog();
+        ConfirmRemoveDialog dialog = getConfirmDeleteDialog();
 
         if (getProjectController().getCurrentObjAttribute() != null) {
             if (dialog.shouldDelete("ObjAttribute", getProjectController()

Modified: cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/action/RemoveEntityListenerAction.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/action/RemoveEntityListenerAction.java?rev=640214&r1=640213&r2=640214&view=diff
==============================================================================
--- cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/action/RemoveEntityListenerAction.java
(original)
+++ cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/action/RemoveEntityListenerAction.java
Sun Mar 23 08:04:58 2008
@@ -23,9 +23,8 @@
 import org.apache.cayenne.map.ObjEntity;
 import org.apache.cayenne.map.event.MapEvent;
 import org.apache.cayenne.modeler.Application;
-import org.apache.cayenne.modeler.dialog.ConfirmDeleteDialog;
+import org.apache.cayenne.modeler.dialog.ConfirmRemoveDialog;
 import org.apache.cayenne.modeler.event.EntityListenerEvent;
-import org.apache.cayenne.modeler.util.CayenneAction;
 
 
 /**
@@ -68,7 +67,7 @@
      * @param e event
      */
     public void performAction(ActionEvent e) {
-        ConfirmDeleteDialog dialog = getConfirmDeleteDialog();
+        ConfirmRemoveDialog dialog = getConfirmDeleteDialog();
 
         if ((getProjectController().getCurrentObjEntity() != null) &&
             (getProjectController().getCurrentListenerClass() != null)) {

Modified: cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/action/RemoveEntityListenerForDataMapAction.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/action/RemoveEntityListenerForDataMapAction.java?rev=640214&r1=640213&r2=640214&view=diff
==============================================================================
--- cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/action/RemoveEntityListenerForDataMapAction.java
(original)
+++ cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/action/RemoveEntityListenerForDataMapAction.java
Sun Mar 23 08:04:58 2008
@@ -22,9 +22,8 @@
 
 import org.apache.cayenne.map.event.MapEvent;
 import org.apache.cayenne.modeler.Application;
-import org.apache.cayenne.modeler.dialog.ConfirmDeleteDialog;
+import org.apache.cayenne.modeler.dialog.ConfirmRemoveDialog;
 import org.apache.cayenne.modeler.event.EntityListenerEvent;
-import org.apache.cayenne.modeler.util.CayenneAction;
 
 
 /**
@@ -67,7 +66,7 @@
      * @param e event
      */
     public void performAction(ActionEvent e) {
-        ConfirmDeleteDialog dialog = getConfirmDeleteDialog();
+        ConfirmRemoveDialog dialog = getConfirmDeleteDialog();
 
         if (getProjectController().getCurrentListenerClass() != null) {
             if (dialog.shouldDelete("entity listener", getProjectController()

Modified: cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/action/RemoveProcedureParameterAction.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/action/RemoveProcedureParameterAction.java?rev=640214&r1=640213&r2=640214&view=diff
==============================================================================
--- cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/action/RemoveProcedureParameterAction.java
(original)
+++ cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/action/RemoveProcedureParameterAction.java
Sun Mar 23 08:04:58 2008
@@ -27,7 +27,7 @@
 import org.apache.cayenne.map.event.ProcedureParameterEvent;
 import org.apache.cayenne.modeler.Application;
 import org.apache.cayenne.modeler.ProjectController;
-import org.apache.cayenne.modeler.dialog.ConfirmDeleteDialog;
+import org.apache.cayenne.modeler.dialog.ConfirmRemoveDialog;
 import org.apache.cayenne.project.ProjectPath;
 
 /**
@@ -60,7 +60,7 @@
     }
 
     public void performAction(ActionEvent e) {
-        ConfirmDeleteDialog dialog = getConfirmDeleteDialog();
+        ConfirmRemoveDialog dialog = getConfirmDeleteDialog();
 
         if (getProjectController().getCurrentProcedureParameter() != null) {
             if (dialog.shouldDelete("procedure parameter", getProjectController()

Modified: cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/action/RemoveRelationshipAction.java
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/action/RemoveRelationshipAction.java?rev=640214&r1=640213&r2=640214&view=diff
==============================================================================
--- cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/action/RemoveRelationshipAction.java
(original)
+++ cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/action/RemoveRelationshipAction.java
Sun Mar 23 08:04:58 2008
@@ -31,7 +31,7 @@
 import org.apache.cayenne.map.event.RelationshipEvent;
 import org.apache.cayenne.modeler.Application;
 import org.apache.cayenne.modeler.ProjectController;
-import org.apache.cayenne.modeler.dialog.ConfirmDeleteDialog;
+import org.apache.cayenne.modeler.dialog.ConfirmRemoveDialog;
 import org.apache.cayenne.modeler.util.ProjectUtil;
 import org.apache.cayenne.project.ProjectPath;
 
@@ -65,7 +65,7 @@
     }
 
     public void performAction(ActionEvent e) {
-        ConfirmDeleteDialog dialog = getConfirmDeleteDialog();
+        ConfirmRemoveDialog dialog = getConfirmDeleteDialog();
 
         if (getProjectController().getCurrentObjRelationship() != null) {
             if (dialog.shouldDelete("ObjRelationship", getProjectController()

Copied: cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/dialog/ConfirmRemoveDialog.java
(from r640213, cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/dialog/ConfirmDeleteDialog.java)
URL: http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/dialog/ConfirmRemoveDialog.java?p2=cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/dialog/ConfirmRemoveDialog.java&p1=cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/dialog/ConfirmDeleteDialog.java&r1=640213&r2=640214&rev=640214&view=diff
==============================================================================
--- cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/dialog/ConfirmDeleteDialog.java
(original)
+++ cayenne/main/trunk/framework/cayenne-modeler/src/main/java/org/apache/cayenne/modeler/dialog/ConfirmRemoveDialog.java
Sun Mar 23 08:04:58 2008
@@ -11,7 +11,7 @@
  *
  * @author Kevin Menard
  */
-public class ConfirmDeleteDialog {
+public class ConfirmRemoveDialog {
     private boolean shouldDelete = true;
 
     private void showDialog(String type, String name) {



Mime
View raw message