You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@isis.apache.org by da...@apache.org on 2016/02/24 00:40:07 UTC

[04/13] isis git commit: ISIS-993: removing support for "isis.viewer.wicket.disableModalDialogs".

ISIS-993: removing support for "isis.viewer.wicket.disableModalDialogs".

Also:
- adding stub release and migration notes for 1.12.0.


Project: http://git-wip-us.apache.org/repos/asf/isis/repo
Commit: http://git-wip-us.apache.org/repos/asf/isis/commit/bf389208
Tree: http://git-wip-us.apache.org/repos/asf/isis/tree/bf389208
Diff: http://git-wip-us.apache.org/repos/asf/isis/diff/bf389208

Branch: refs/heads/ISIS-993
Commit: bf389208534eb8827892592a68659fd899f55437
Parents: 69ed9c5
Author: Dan Haywood <da...@haywood-associates.co.uk>
Authored: Wed Feb 17 16:49:01 2016 +0000
Committer: Dan Haywood <da...@haywood-associates.co.uk>
Committed: Wed Feb 17 16:49:01 2016 +0000

----------------------------------------------------------------------
 .../_migration-notes_1.11.0-to-1.12.0.adoc      | 20 ++++++++++++++++++++
 .../main/asciidoc/_release-notes_1.12.0.adoc    | 13 +++++++++++++
 .../guides/_ugvw_configuration-properties.adoc  |  4 +---
 .../src/main/asciidoc/migration-notes.adoc      |  1 +
 .../src/main/asciidoc/release-notes.adoc        |  9 +++++++++
 .../actionprompt/ActionPromptModalWindow.java   | 15 +--------------
 .../actions/ActionParametersFormPanel.java      |  8 ++------
 .../StandaloneCollectionPanel.java              |  2 +-
 .../viewer/wicket/ui/pages/PageAbstract.java    |  2 +-
 .../webapp/WEB-INF/viewer_wicket.properties     |  6 ------
 10 files changed, 49 insertions(+), 31 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/isis/blob/bf389208/adocs/documentation/src/main/asciidoc/_migration-notes_1.11.0-to-1.12.0.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/_migration-notes_1.11.0-to-1.12.0.adoc b/adocs/documentation/src/main/asciidoc/_migration-notes_1.11.0-to-1.12.0.adoc
new file mode 100644
index 0000000..803b91f
--- /dev/null
+++ b/adocs/documentation/src/main/asciidoc/_migration-notes_1.11.0-to-1.12.0.adoc
@@ -0,0 +1,20 @@
+[[_migration-notes_1.11.0-to-1.12.0]]
+= From v1.11.0 to 1.12.0
+:Notice: Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at. http://www.apache.org/licenses/LICENSE-2.0 . Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR  CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
+:_basedir: ../
+:_imagesdir: images/
+
+
+Apache Isis 1.12.0-SNAPSHOT is still in development.
+
+
+
+== `isis.viewer.wicket.disableModalDialogs` removed
+
+The Apache Isis Wicket viewer uses a modal dialog for action parameters.  Before this feature was implemented (prior
+to 1.4.0), action parameters were rendered on their own page.  This property was provided to re-enable the old
+behaviour.
+
+The property has now been removed and this feature removed; actions parameters are always now always shown in a
+ modal dialog.
+

http://git-wip-us.apache.org/repos/asf/isis/blob/bf389208/adocs/documentation/src/main/asciidoc/_release-notes_1.12.0.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/_release-notes_1.12.0.adoc b/adocs/documentation/src/main/asciidoc/_release-notes_1.12.0.adoc
new file mode 100644
index 0000000..b535b72
--- /dev/null
+++ b/adocs/documentation/src/main/asciidoc/_release-notes_1.12.0.adoc
@@ -0,0 +1,13 @@
+[[r1.12.0]]
+= 1.12.0-SNAPSHOT
+:notice: licensed to the apache software foundation (asf) under one or more contributor license agreements. see the notice file distributed with this work for additional information regarding copyright ownership. the asf licenses this file to you under the apache license, version 2.0 (the "license"); you may not use this file except in compliance with the license. you may obtain a copy of the license at. http://www.apache.org/licenses/license-2.0 . unless required by applicable law or agreed to in writing, software distributed under the license is distributed on an "as is" basis, without warranties or  conditions of any kind, either express or implied. see the license for the specific language governing permissions and limitations under the license.
+:_basedir: ./
+:_imagesdir: images/
+:toc: right
+
+
+Apache Isis 1.12.0-SNAPSHOT is still in development.
+
+
+
+

http://git-wip-us.apache.org/repos/asf/isis/blob/bf389208/adocs/documentation/src/main/asciidoc/guides/_ugvw_configuration-properties.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/guides/_ugvw_configuration-properties.adoc b/adocs/documentation/src/main/asciidoc/guides/_ugvw_configuration-properties.adoc
index f4bb645..87b1c0d 100644
--- a/adocs/documentation/src/main/asciidoc/guides/_ugvw_configuration-properties.adoc
+++ b/adocs/documentation/src/main/asciidoc/guides/_ugvw_configuration-properties.adoc
@@ -50,9 +50,7 @@ If you prefer you can place all configuration properties into `WEB-INF/isis.prop
 |`isis.viewer.wicket.` +
 `disableModalDialogs`
 | `true`,`false` (`_false_`)
-| By default the Apache Isis Wicket viewer uses a modal dialog for action parameters.  Before this feature was implemented (prior to 1.4.0), Apache Isis rendered action parameters on its own page.  This property re-enables the old behaviour.
-
-Note that action pages are still used for bookmarked actions.
+|(`1.12.0-SNAPSHOT`), no longer supported.
 
 |`isis.viewer.wicket.` +
 `maxTitleLengthInParentedTables`

http://git-wip-us.apache.org/repos/asf/isis/blob/bf389208/adocs/documentation/src/main/asciidoc/migration-notes.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/migration-notes.adoc b/adocs/documentation/src/main/asciidoc/migration-notes.adoc
index 0506693..1fcd2fd 100644
--- a/adocs/documentation/src/main/asciidoc/migration-notes.adoc
+++ b/adocs/documentation/src/main/asciidoc/migration-notes.adoc
@@ -7,6 +7,7 @@
 
 
 
+include::_migration-notes_1.11.0-to-1.12.0.adoc[leveloffset=+1]
 include::_migration-notes_1.10.0-to-1.11.0.adoc[leveloffset=+1]
 include::_migration-notes_1.9.0-to-1.10.0.adoc[leveloffset=+1]
 include::_migration-notes_1.8.0-to-1.9.0.adoc[leveloffset=+1]

http://git-wip-us.apache.org/repos/asf/isis/blob/bf389208/adocs/documentation/src/main/asciidoc/release-notes.adoc
----------------------------------------------------------------------
diff --git a/adocs/documentation/src/main/asciidoc/release-notes.adoc b/adocs/documentation/src/main/asciidoc/release-notes.adoc
index a279f2b..355550f 100644
--- a/adocs/documentation/src/main/asciidoc/release-notes.adoc
+++ b/adocs/documentation/src/main/asciidoc/release-notes.adoc
@@ -21,6 +21,14 @@ This table summarises all releases of Apache Isis to date.
 | Improves
 | Bugs
 
+| xref:r1.12.0[1.12.0]
+|
+|
+| `1.12.0-SNAPSHOT` is still in development
+|
+|
+|
+
 | xref:r1.11.1[1.11.1]
 | 17-jan-2016
 | * https://issues.apache.org/jira/secure/ReleaseNote.jspa?projectId=12311171&version=12334640[1.11.1]
@@ -218,6 +226,7 @@ This table summarises all releases of Apache Isis to date.
 
 
 
+include::_release-notes_1.12.0.adoc[leveloffset=+1]
 include::_release-notes_1.11.1.adoc[leveloffset=+1]
 include::_release-notes_1.11.0.adoc[leveloffset=+1]
 include::_release-notes_1.10.0.adoc[leveloffset=+1]

http://git-wip-us.apache.org/repos/asf/isis/blob/bf389208/core/viewer-wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/actionprompt/ActionPromptModalWindow.java
----------------------------------------------------------------------
diff --git a/core/viewer-wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/actionprompt/ActionPromptModalWindow.java b/core/viewer-wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/actionprompt/ActionPromptModalWindow.java
index 8c0bc85..0a57ffe 100644
--- a/core/viewer-wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/actionprompt/ActionPromptModalWindow.java
+++ b/core/viewer-wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/actionprompt/ActionPromptModalWindow.java
@@ -18,26 +18,13 @@ package org.apache.isis.viewer.wicket.ui.components.actionprompt;
 
 import org.apache.wicket.markup.head.IHeaderResponse;
 import org.apache.wicket.markup.head.OnDomReadyHeaderItem;
-import org.apache.isis.core.commons.config.IsisConfiguration;
-import org.apache.isis.core.runtime.system.context.IsisContext;
+
 import org.apache.isis.viewer.wicket.ui.components.widgets.bootstrap.ModalDialog;
 
 public class ActionPromptModalWindow extends ModalDialog<Void> {
 
     private static final long serialVersionUID = 1L;
 
-    public static ActionPromptModalWindow getActionPromptModalWindowIfEnabled(ActionPromptModalWindow modalWindow) {
-        return !isActionPromptModalDialogDisabled() ? modalWindow : null;
-    }
-
-    public static boolean isActionPromptModalDialogDisabled() {
-        return getConfiguration().getBoolean("isis.viewer.wicket.disableModalDialogs", false);
-    }
-
-    private static IsisConfiguration getConfiguration() {
-        return IsisContext.getConfiguration();
-    }
-
     public static ActionPromptModalWindow newModalWindow(String id) {
         return new ActionPromptModalWindow(id);
     }

http://git-wip-us.apache.org/repos/asf/isis/blob/bf389208/core/viewer-wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/actions/ActionParametersFormPanel.java
----------------------------------------------------------------------
diff --git a/core/viewer-wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/actions/ActionParametersFormPanel.java b/core/viewer-wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/actions/ActionParametersFormPanel.java
index 931d10f..b6820cc 100644
--- a/core/viewer-wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/actions/ActionParametersFormPanel.java
+++ b/core/viewer-wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/actions/ActionParametersFormPanel.java
@@ -40,13 +40,12 @@ import org.apache.isis.core.metamodel.spec.feature.ObjectAction;
 import org.apache.isis.core.runtime.system.context.IsisContext;
 import org.apache.isis.viewer.wicket.model.hints.IsisActionCompletedEvent;
 import org.apache.isis.viewer.wicket.model.mementos.ActionParameterMemento;
-import org.apache.isis.viewer.wicket.model.models.ExecutingPanel;
 import org.apache.isis.viewer.wicket.model.models.ActionModel;
 import org.apache.isis.viewer.wicket.model.models.ActionPrompt;
 import org.apache.isis.viewer.wicket.model.models.ActionPromptProvider;
+import org.apache.isis.viewer.wicket.model.models.ExecutingPanel;
 import org.apache.isis.viewer.wicket.model.models.ScalarModel;
 import org.apache.isis.viewer.wicket.ui.ComponentType;
-import org.apache.isis.viewer.wicket.ui.components.actionprompt.ActionPromptModalWindow;
 import org.apache.isis.viewer.wicket.ui.components.scalars.ScalarModelSubscriber;
 import org.apache.isis.viewer.wicket.ui.components.scalars.ScalarPanelAbstract;
 import org.apache.isis.viewer.wicket.ui.components.scalars.TextFieldValueModel.ScalarModelProvider;
@@ -204,10 +203,7 @@ public class ActionParametersFormPanel extends PanelAbstract<ActionModel> {
             cancelButton.setDefaultFormProcessing(false);
             add(cancelButton);
             
-            // TODO: hide cancel button if dialogs disabled, as not yet implemented.
-            if(ActionPromptModalWindow.isActionPromptModalDialogDisabled()) {
-                cancelButton.setVisible(false);
-            }
+            cancelButton.setVisible(false);
         }
 
         /**

http://git-wip-us.apache.org/repos/asf/isis/blob/bf389208/core/viewer-wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/standalonecollection/StandaloneCollectionPanel.java
----------------------------------------------------------------------
diff --git a/core/viewer-wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/standalonecollection/StandaloneCollectionPanel.java b/core/viewer-wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/standalonecollection/StandaloneCollectionPanel.java
index 196f061..58fb960 100644
--- a/core/viewer-wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/standalonecollection/StandaloneCollectionPanel.java
+++ b/core/viewer-wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/components/standalonecollection/StandaloneCollectionPanel.java
@@ -114,7 +114,7 @@ public class StandaloneCollectionPanel extends PanelAbstract<EntityCollectionMod
     //region > ActionPromptModalWindowProvider
 
     public ActionPromptModalWindow getActionPrompt() {
-        return ActionPromptModalWindow.getActionPromptModalWindowIfEnabled(actionPromptModalWindow);
+        return actionPromptModalWindow;
     }
 
     //endregion

http://git-wip-us.apache.org/repos/asf/isis/blob/bf389208/core/viewer-wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/pages/PageAbstract.java
----------------------------------------------------------------------
diff --git a/core/viewer-wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/pages/PageAbstract.java b/core/viewer-wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/pages/PageAbstract.java
index c285004..30197af 100644
--- a/core/viewer-wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/pages/PageAbstract.java
+++ b/core/viewer-wicket-ui/src/main/java/org/apache/isis/viewer/wicket/ui/pages/PageAbstract.java
@@ -385,7 +385,7 @@ public abstract class PageAbstract extends WebPage implements ActionPromptProvid
     private ActionPromptModalWindow actionPromptModalWindow;
 
     public ActionPrompt getActionPrompt() {
-        return ActionPromptModalWindow.getActionPromptModalWindowIfEnabled(actionPromptModalWindow);
+        return actionPromptModalWindow;
     }
 
     private void addActionPromptModalWindow(final MarkupContainer parent) {

http://git-wip-us.apache.org/repos/asf/isis/blob/bf389208/example/application/simpleapp/webapp/src/main/webapp/WEB-INF/viewer_wicket.properties
----------------------------------------------------------------------
diff --git a/example/application/simpleapp/webapp/src/main/webapp/WEB-INF/viewer_wicket.properties b/example/application/simpleapp/webapp/src/main/webapp/WEB-INF/viewer_wicket.properties
index ba9eaaf..6cbb981 100644
--- a/example/application/simpleapp/webapp/src/main/webapp/WEB-INF/viewer_wicket.properties
+++ b/example/application/simpleapp/webapp/src/main/webapp/WEB-INF/viewer_wicket.properties
@@ -61,12 +61,6 @@ isis.viewer.wicket.maxTitleLengthInParentedTables=0
 
 
 #
-# whether to show action dialogs on their own page rather than as a modal dialog (default is false)
-#
-#isis.viewer.wicket.disableModalDialogs=false
-
-
-#
 # the maximum number of pages to list in bookmark (default is 15)
 #
 #isis.viewer.wicket.bookmarkedPages.maxSize=15