You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@isis.apache.org by ah...@apache.org on 2022/05/18 11:36:35 UTC

[isis] branch master updated (bd738fea69 -> 3ec6a298ac)

This is an automated email from the ASF dual-hosted git repository.

ahuber pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/isis.git


    from bd738fea69 ISIS-2965: updates docs for SudoService
     new 74ce124b18 ISIS-3053: Tooltip demo: create toasts on no-arg actions, so we can see whether executed
     new 76eeb10bdc Merge remote-tracking branch 'origin/master'
     new 3ec6a298ac ISIS-3058: xray message processing fix

The 3 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 .../org/apache/isis/commons/internal/debug/_XrayEvent.java   | 12 +++++++++++-
 .../dom/featured/layout/describedAs/DescribedAsVm.java       | 11 ++++++++++-
 2 files changed, 21 insertions(+), 2 deletions(-)


[isis] 01/03: ISIS-3053: Tooltip demo: create toasts on no-arg actions, so we can see whether executed

Posted by ah...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

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

commit 74ce124b189a1b4884ade3eb8a9b8dae51680096
Author: Andi Huber <ah...@apache.org>
AuthorDate: Wed May 18 06:46:29 2022 +0200

    ISIS-3053: Tooltip demo: create toasts on no-arg actions, so we can see
    whether executed
---
 .../dom/featured/layout/describedAs/DescribedAsVm.java        | 11 ++++++++++-
 1 file changed, 10 insertions(+), 1 deletion(-)

diff --git a/examples/demo/domain/src/main/java/demoapp/dom/featured/layout/describedAs/DescribedAsVm.java b/examples/demo/domain/src/main/java/demoapp/dom/featured/layout/describedAs/DescribedAsVm.java
index fedb6e9bcf..e2aaa7d784 100644
--- a/examples/demo/domain/src/main/java/demoapp/dom/featured/layout/describedAs/DescribedAsVm.java
+++ b/examples/demo/domain/src/main/java/demoapp/dom/featured/layout/describedAs/DescribedAsVm.java
@@ -21,9 +21,11 @@ package demoapp.dom.featured.layout.describedAs;
 import java.util.ArrayList;
 import java.util.List;
 
+import javax.inject.Inject;
 import javax.xml.bind.annotation.XmlAccessType;
 import javax.xml.bind.annotation.XmlAccessorType;
 import javax.xml.bind.annotation.XmlRootElement;
+import javax.xml.bind.annotation.XmlTransient;
 import javax.xml.bind.annotation.XmlType;
 
 import org.apache.isis.applib.annotation.Action;
@@ -43,6 +45,7 @@ import org.apache.isis.applib.annotation.PromptStyle;
 import org.apache.isis.applib.annotation.Property;
 import org.apache.isis.applib.annotation.PropertyLayout;
 import org.apache.isis.applib.annotation.SemanticsOf;
+import org.apache.isis.applib.services.message.MessageService;
 import org.apache.isis.applib.value.Markup;
 
 import lombok.Getter;
@@ -57,6 +60,9 @@ import demoapp.dom.domain.actions.progmodel.assoc.DemoItem;
 @DomainObject(nature=Nature.VIEW_MODEL, logicalTypeName = "demo.Tooltip")
 public class DescribedAsVm implements HasAsciiDocDescription {
 
+    @XmlTransient
+    @Inject MessageService messageService;
+
     @ObjectSupport public String title() {
         return "Tooltip Demo";
     }
@@ -68,6 +74,7 @@ public class DescribedAsVm implements HasAsciiDocDescription {
             named = "No Arguments",
             describedAs="This is a no-arg action with a tooltip.")
     public DescribedAsVm noArgAction(){
+        messageService.informUser("clicked on noArgAction");
         return this;
     }
 
@@ -75,8 +82,10 @@ public class DescribedAsVm implements HasAsciiDocDescription {
     @ActionLayout(
             named = "No Arguments With Confirm",
             cssClass="btn-danger",
-            describedAs="This is a no-arg action with a tooltip and 'are you sure' semantics.")
+            describedAs="This is a no-arg action with a tooltip and 'are you sure' semantics."
+            )
     public DescribedAsVm noArgActionWithConfirm(){
+        messageService.informUser("clicked on noArgActionWithConfirm");
         return this;
     }
 


[isis] 03/03: ISIS-3058: xray message processing fix

Posted by ah...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

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

commit 3ec6a298acc320bc6fe412614fda40fcc55fc915
Author: Andi Huber <ah...@apache.org>
AuthorDate: Wed May 18 13:36:28 2022 +0200

    ISIS-3058: xray message processing fix
---
 .../org/apache/isis/commons/internal/debug/_XrayEvent.java   | 12 +++++++++++-
 1 file changed, 11 insertions(+), 1 deletion(-)

diff --git a/commons/src/main/java/org/apache/isis/commons/internal/debug/_XrayEvent.java b/commons/src/main/java/org/apache/isis/commons/internal/debug/_XrayEvent.java
index ccbe4f6f92..6e0bedfc89 100644
--- a/commons/src/main/java/org/apache/isis/commons/internal/debug/_XrayEvent.java
+++ b/commons/src/main/java/org/apache/isis/commons/internal/debug/_XrayEvent.java
@@ -22,6 +22,7 @@ import java.util.stream.Collectors;
 
 import org.apache.isis.commons.collections.Can;
 import org.apache.isis.commons.handler.ChainOfResponsibility;
+import org.apache.isis.commons.internal.base._NullSafe;
 import org.apache.isis.commons.internal.debug.xray.XrayUi;
 import org.apache.isis.commons.internal.exceptions._Exceptions;
 
@@ -86,7 +87,16 @@ public class _XrayEvent {
                 .collect(Can.toCan());
                 //.reverse();
 
-        val logMessage = String.format(format, args);
+        var logMessage = "???";
+        if(_NullSafe.isEmpty(args)) {
+            logMessage = format;
+        } else {
+            try {
+                logMessage = String.format(format, args);
+            } catch (Throwable e) {
+                logMessage = "" + format + " <- " + args;
+            }
+        }
 
         _Xray.recordDebugLogEvent(icon, logMessage, stackTrace);
 


[isis] 02/03: Merge remote-tracking branch 'origin/master'

Posted by ah...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

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

commit 76eeb10bdc2e110294df6e767e75fae60843a6bc
Merge: 74ce124b18 bd738fea69
Author: Andi Huber <ah...@apache.org>
AuthorDate: Wed May 18 13:32:48 2022 +0200

    Merge remote-tracking branch 'origin/master'

 .../hooks/SudoService_020-examples-and-usage.adoc  | 36 +++++++---------------
 1 file changed, 11 insertions(+), 25 deletions(-)