You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@netbeans.apache.org by GitBox <gi...@apache.org> on 2018/01/23 08:25:16 UTC

[GitHub] geertjanw closed pull request #377: [NETBEANS-292] PropertyDescriptor.getValue(enumerationValues) may ret?

geertjanw closed pull request #377: [NETBEANS-292] PropertyDescriptor.getValue(enumerationValues) may ret?
URL: https://github.com/apache/incubator-netbeans/pull/377
 
 
   

This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:

As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):

diff --git a/form/src/org/netbeans/modules/form/RADProperty.java b/form/src/org/netbeans/modules/form/RADProperty.java
index 8c940ec8e..95767f883 100644
--- a/form/src/org/netbeans/modules/form/RADProperty.java
+++ b/form/src/org/netbeans/modules/form/RADProperty.java
@@ -277,6 +277,12 @@ protected PropertyEditor createEnumEditor(PropertyDescriptor descriptor) {
         {   // get the enumeration values by standard means
             enumerationValues = (Object[])
                                 descriptor.getValue("enumerationValues"); // NOI18N
+            if (enumerationValues != null && enumerationValues.length == 0) {
+                //JDK-8131347: For @BeanProperty annotation,
+                //if there are no enumerationValues, an empty array is returned.
+                //But an EnumEditor shouldn't be created for it:
+                enumerationValues = null;
+            }
         }
         else { // hack: debugGraphicsOptions is problematic because its
                // default value (0) does not correspond to any of the


 

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists