Re: [15] RFR JDK-8216329: Cannot resize CheckBoxItemMenu in Synth L&F with setHorizontalTextPosition

2020-01-29 Thread Sergey Bylokhov
On 1/29/20 2:25 am, Pankaj Bansal wrote: One more point, I am able to reproduce the current issue with Synth LookAndFeel in all platforms without fix and it works fine with the fix. ok. Do we need to remove the listener added to the menuItem? I guess it will be added every time we change L&F

Re: Remove System.out.println from ImageIcon.loadImage

2020-01-29 Thread Jason Mehrens
1. Agreed. 2. I was just pulling from the jdk8 source (because I'm lazy) to express the idea. Feel free to adjust. 3. Reasserting in the finally ensure we are not forcefully setting the interrupted status on the current thread and calling 'statusID' and 'removeImage'. It also ensures that the

Re: Remove System.out.println from ImageIcon.loadImage

2020-01-29 Thread Volodin, Vladislav
Hi Jason, I have few questions: 1. The second assignment is probably redundant: } catch (InterruptedException e1) { wasInterrupted = true; // line #2, see comment below try { mTracker.waitForID(id, 0); } catch (InterruptedException e2) { lo

Re: Remove System.out.println from ImageIcon.loadImage

2020-01-29 Thread Jason Mehrens
Bug in that last version: Thread.currentThread().isInterrupted(); -> Thread.currentThread().interrupt(); === protected void loadImage(Image image) { MediaTracker mTracker = getTracker(); synchronized (mTracker) { int id = getNextID();

Re: Remove System.out.println from ImageIcon.loadImage

2020-01-29 Thread Jason Mehrens
A shorter version is just to reassert at the end of catch e1. It is safer to just reassert as the last statement in the finally. === protected void loadImage(Image image) { MediaTracker mTracker = getTracker(); synchronized (mTracker) { int

Re: [15] RFR JDK-8216329: Cannot resize CheckBoxItemMenu in Synth L&F with setHorizontalTextPosition

2020-01-29 Thread Pankaj Bansal
<< Can you please double check that it is not possible to reproduce JDK-8152981 even if the test is modified in some way? < [15] RFR JDK-8216329: Cannot resize CheckBoxItemMenu in Synth L&F with setHorizontalTextPosition Hello Sergey, << Can you please double check that it is not possible to re

Re: [15] RFR JDK-8216329: Cannot resize CheckBoxItemMenu in Synth L&F with setHorizontalTextPosition

2020-01-29 Thread Pankaj Bansal
Hello Sergey, << Can you please double check that it is not possible to reproduce JDK-8152981 even if the test is modified in some way? < [15] RFR JDK-8216329: Cannot resize CheckBoxItemMenu in Synth L&F with setHorizontalTextPosition On 1/28/20 4:33 pm, Sergey Bylokhov wrote: > On 1/27/20 7:15