Introduce disabling of markup validation.
authorMathieu Baudier <mbaudier@argeo.org>
Wed, 21 Jul 2021 08:38:44 +0000 (10:38 +0200)
committerMathieu Baudier <mbaudier@argeo.org>
Wed, 21 Jul 2021 08:38:44 +0000 (10:38 +0200)
org.argeo.cms.ui/src/org/argeo/cms/ui/util/CmsUiUtils.java
org.argeo.eclipse.ui.rap/src/org/argeo/eclipse/ui/specific/EclipseUiSpecificUtils.java

index 8b10ef123a3bb9a62122496bfb848e94bf3ee790..c305fa0db6b684159ebc42cf2271e726c0f8bdd2 100644 (file)
@@ -224,6 +224,12 @@ public class CmsUiUtils implements CmsConstants {
                return widget;
        }
 
+       /** Disable markup validation. */
+       public static <T extends Widget> T disableMarkupValidation(T widget) {
+               EclipseUiSpecificUtils.setMarkupValidationDisabledData(widget);
+               return widget;
+       }
+
        /**
         * Apply markup and set text on {@link Label}, {@link Button}, {@link Text}.
         * 
index f79c7fd88ab910ca16702d3e1ccdcdf4226e98d0..a89b921cdf6a9012bd38107ed647f046d07644f2 100644 (file)
@@ -22,6 +22,10 @@ public class EclipseUiSpecificUtils {
                widget.setData(RWT.MARKUP_ENABLED, true);
        }
 
+       public static void setMarkupValidationDisabledData(Widget widget) {
+               widget.setData("org.eclipse.rap.rwt.markupValidationDisabled", Boolean.TRUE);
+       }
+
        /**
         * TootlTip support is supported only for {@link AbstractTableViewer} in RAP
         */