On 5/28/19 1:55 PM, Sergey Bylokhov wrote:
On 28/05/2019 09:19, semyon.sadet...@oracle.com wrote:
Hi Sergey,
I think your understanding of the lightWeightPopupEnabled property purpose is not fully correct. The specification of the property is very clear on that:
    /**
* Sets the value of the <code>lightWeightPopupEnabled</code> property,
      * which by default is <code>true</code>.
      * By default, when a look and feel displays a popup,
      * it can choose to
      * use a lightweight (all-Java) popup.
      * Lightweight popup windows are more efficient than heavyweight
      * (native peer) windows,
* but lightweight and heavyweight components do not mix well in a GUI. * If your application mixes lightweight and heavyweight components,
      * you should disable lightweight popups.
      * Some look and feels might always use heavyweight popups,
      * no matter what the value of this property.
      */
So, there is nothing to implement in Aqua L&F about it.

I guess the spec above is from the different method, which is not used in the test? But as of the spec for setDefaultLightWeightPopupEnabled()/getDefaultLightWeightPopupEnabled() we of course work according to the specification, but it does not mean that we should not implement/change the optional part.
Did you mean that *the default* value of some property has more priority then the value of the property it-self? This sounds very strange to me. This'd mean that if we setDefaultLightWeightPopupEnabled() to some value than we cannot use setLightWeightPopupEnabled() to change the value. This contradicts to the current implementation which uses the default as initial property value only:
    public JPopupMenu(String label) {
        this.label = label;
        lightWeightPopup = getDefaultLightWeightPopupEnabled();
        ...
I see no reason to change that behavior.

Reply via email to