Re: RFR: 8273101: Eliminate the usage of threadgroup sandboxing in the java.util.logging

2021-09-06 Thread Sergey Bylokhov
On Mon, 6 Sep 2021 09:39:58 GMT, Alan Bateman wrote: > As I see it, this is just one piece of the overall cleanup and I assume there > are more substantive changes to the java.desktop module coming, is that right? Yes, you are right. - PR: https://git.openjdk.java.net/jdk/pull/532

Re: RFR: 8273355: Lanai: Flickering on tooltip appearance IntelliJ IDEA 2021.2.1

2021-09-04 Thread Sergey Bylokhov
On Sat, 4 Sep 2021 19:54:55 GMT, Alexey Ushakov wrote: > Used setOpaque() method to set correct background of platform window Is it possible that the problem is in the performance, what happens if you just add a delay at that place to wait while the metal layer will be updated from the previou

Re: RFR: 8273355: Lanai: Flickering on tooltip appearance IntelliJ IDEA 2021.2.1

2021-09-04 Thread Sergey Bylokhov
On Sat, 4 Sep 2021 19:54:55 GMT, Alexey Ushakov wrote: > Used setOpaque() method to set correct background of platform window Calling "platformWindow.setOpaque(!isTranslucent());" is equvivalent of calling these three methods: setOpaque(getTarget().isOpaque()); applyShape(Region.getInstanc

Re: RFR: 8271603: Unnecessary Vector usage in java.desktop [v7]

2021-09-03 Thread Sergey Bylokhov
On Fri, 3 Sep 2021 08:04:52 GMT, Andrey Turbanov wrote: >> Usage of thread-safe collection `Vector` is unnecessary. It's recommended to >> use `ArrayList` if a thread-safe implementation is not needed. In >> post-BiasedLocking times, this is gets worse, as every access is >> synchronized. >>

Re: RFR: 8273101: Eliminate the usage of threadgroup sandboxing in the java.util.logging

2021-09-03 Thread Sergey Bylokhov
On Thu, 2 Sep 2021 09:59:51 GMT, Daniel Fuchs wrote: >> The "java.util.logging.LogManager" class uses the "threadgroup sandboxing" >> via an AppContext to support "applet logging isolation". The AppContext >> class became useless since the plugin and webstart are no longer supported >> and rem

Re: RFR: 8273101: Eliminate the usage of threadgroup sandboxing in the java.util.logging

2021-09-03 Thread Sergey Bylokhov
On Fri, 3 Sep 2021 17:19:05 GMT, Phil Race wrote: > Perhaps this isn't the change that requires the CSR but it then leaves an > inconsistent state where desktop supports AppContext still but other modules > don't ... Even java.desktop does not support it fully, since for a couple of years nobo

Re: RFR: 8271603: Unnecessary Vector usage in java.desktop [v6]

2021-09-02 Thread Sergey Bylokhov
On Wed, 1 Sep 2021 19:46:51 GMT, Andrey Turbanov wrote: >> Usage of thread-safe collection `Vector` is unnecessary. It's recommended to >> use `ArrayList` if a thread-safe implementation is not needed. In >> post-BiasedLocking times, this is gets worse, as every access is >> synchronized. >>

RFR: 8273101: Eliminate the usage of threadgroup sandboxing in the java.util.logging

2021-09-02 Thread Sergey Bylokhov
The "java.util.logging.LogManager" class uses the "threadgroup sandboxing" via an AppContext to support "applet logging isolation". The AppContext class became useless since the plugin and webstart are no longer supported and removed in jdk11. This is the request to delete the usage of AppConte

Re: RFR: 8271603: Unnecessary Vector usage in java.desktop [v4]

2021-08-27 Thread Sergey Bylokhov
On Fri, 27 Aug 2021 17:52:19 GMT, Andrey Turbanov wrote: >> src/java.desktop/share/classes/javax/swing/JMenu.java line 1340: >> >>> 1338: } >>> 1339: MenuElement[] me = new MenuElement[elements.size()]; >>> 1340: elements.toArray(me); >> >> Implementation of the "toArra

Re: RFR: 8271603: Unnecessary Vector usage in java.desktop [v4]

2021-08-27 Thread Sergey Bylokhov
On Wed, 25 Aug 2021 17:53:00 GMT, Andrey Turbanov wrote: >> Usage of thread-safe collection `Vector` is unnecessary. It's recommended to >> use `ArrayList` if a thread-safe implementation is not needed. In >> post-BiasedLocking times, this is gets worse, as every access is >> synchronized. >>

Re: RFR: 8272481: [macos] javax/swing/JFrame/NSTexturedJFrame/NSTexturedJFrame.java fails [v4]

2021-08-25 Thread Sergey Bylokhov
On Wed, 25 Aug 2021 17:32:46 GMT, Alexey Ushakov wrote: >> Update opacity only if the component is visible > > Alexey Ushakov has updated the pull request incrementally with one additional > commit since the last revision: > > 8272481: [macos] javax/swing/JFrame/NSTexturedJFrame/NSTexturedJFr

Re: RFR: 8272481: [macos] javax/swing/JFrame/NSTexturedJFrame/NSTexturedJFrame.java fails [v3]

2021-08-24 Thread Sergey Bylokhov
On Tue, 24 Aug 2021 15:09:51 GMT, Alexey Ushakov wrote: >> Update opacity only if the component is visible > > Alexey Ushakov has updated the pull request incrementally with one additional > commit since the last revision: > > 8272481: [macos] javax/swing/JFrame/NSTexturedJFrame/NSTexturedJFr

Re: RFR: 8271603: Unnecessary Vector usage in java.desktop [v2]

2021-08-24 Thread Sergey Bylokhov
On Tue, 24 Aug 2021 21:13:57 GMT, Andrey Turbanov wrote: >> Usage of thread-safe collection `Vector` is unnecessary. It's recommended to >> use `ArrayList` if a thread-safe implementation is not needed. In >> post-BiasedLocking times, this is gets worse, as every access is >> synchronized. >>

Re: RFR: 8272863: Replace usages of Collections.sort with List.sort call in public java modules

2021-08-23 Thread Sergey Bylokhov
On Mon, 23 Aug 2021 21:01:48 GMT, Andrey Turbanov wrote: > Collections.sort is just a wrapper, so it is better to use an instance method > directly. The changes in the src/java.desktop/ looks fine. Filed: https://bugs.openjdk.java.net/browse/JDK-8272863 - Marked as reviewed by s

Re: RFR: 8272806: [macOS] "Apple AWT Internal Exception" when input method is changed

2021-08-23 Thread Sergey Bylokhov
On Sun, 22 Aug 2021 19:46:49 GMT, Phil Race wrote: > There's a long eval in the bug report : > https://bugs.openjdk.java.net/browse/JDK-8272806 but here's the summary > > When focus is lost by the app a message is sent down to native setting a > native reference to the input method to null > w

Re: RFR: 8272481: [macos] javax/swing/JFrame/NSTexturedJFrame/NSTexturedJFrame.java fails [v2]

2021-08-23 Thread Sergey Bylokhov
On Mon, 23 Aug 2021 17:57:45 GMT, Alexey Ushakov wrote: >> Update opacity only if the component is visible > > Alexey Ushakov has updated the pull request incrementally with one additional > commit since the last revision: > > 8272481: [macos] javax/swing/JFrame/NSTexturedJFrame/NSTexturedJFr

Re: RFR: 8272756: Remove unnecessary explicit initialization of volatile variables in java.desktop

2021-08-23 Thread Sergey Bylokhov
On Mon, 23 Aug 2021 13:08:02 GMT, Alexey Ivanov wrote: >> Looks like there's no purpose, `tags` is not used after assignment > > Maybe it's kind of a protection from a race. Yet it's possible either way: > another thread could see `essentialTags == null` before this one initialises > the field.

Re: RFR: 8272756: Remove unnecessary explicit initialization of volatile variables in java.desktop

2021-08-20 Thread Sergey Bylokhov
On Fri, 20 Aug 2021 09:41:15 GMT, Сергей Цыпанов wrote: > This is a continuation of > > - https://bugs.openjdk.java.net/browse/JDK-6736490 > - https://bugs.openjdk.java.net/browse/JDK-8035284 > - https://bugs.openjdk.java.net/browse/JDK-8145680 > - https://bugs.openjdk.java.net/browse/JDK-82515

Re: RFR: 8272602: [macos] not all KEY_PRESSED events sent when control modifier is used

2021-08-19 Thread Sergey Bylokhov
On Wed, 18 Aug 2021 23:57:38 GMT, Phil Race wrote: > When Ctrl+Space is pressed mac generates a string that contains the single > unicode code point zero. > The fn that converts it from an NSString to a Java String is using > NewStringUTF. > The input to that is a null terminated string which a

Re: RFR: 8272481: [macos] javax/swing/JFrame/NSTexturedJFrame/NSTexturedJFrame.java fails

2021-08-19 Thread Sergey Bylokhov
On Wed, 18 Aug 2021 21:07:28 GMT, Alexey Ushakov wrote: > Update opacity only if the component is visible src/java.desktop/macosx/classes/sun/lwawt/LWWindowPeer.java line 524: > 522: if (textured != isTextured) { > 523: textured = isTextured; > 524: if (isVisible

Re: RFR: 8269951: [macos] Focus not painted in JButton when setBorderPainted(false) is invoked [v6]

2021-08-17 Thread Sergey Bylokhov
On Tue, 17 Aug 2021 06:09:51 GMT, Alexander Zuev wrote: >> Initial implementation and a test case. >> >> The problem is that Aqua LaF shows the focused component with the glow on >> the border, hence when the border is not painted the foxus is not displayed. >> The idea is to paint the glowing

Re: RFR: 8269951: [macos] Focus not painted in JButton when setBorderPainted(false) is invoked [v4]

2021-08-16 Thread Sergey Bylokhov
On Mon, 16 Aug 2021 23:39:05 GMT, Alexander Zuev wrote: >> What about the color property? > >> What about the color property? > > That would be unnecessary, whoever does painting does not just assumes that > the color is set to his preferred choice, everywhere in the code color is set > up bef

Re: RFR: 8269951: [macos] Focus not painted in JButton when setBorderPainted(false) is invoked [v4]

2021-08-16 Thread Sergey Bylokhov
On Mon, 16 Aug 2021 19:45:11 GMT, Alexander Zuev wrote: >> src/java.desktop/macosx/classes/com/apple/laf/AquaButtonUI.java line 340: >> >>> 338: Color ringColor = UIManager.getColor("Focus.color"); >>> 339: g.setColor(ringColor); >>> 340: g.drawRoundRect(5, 3, b.getWidth(

Re: RFR: 8267161 : Write automated test case for JDK-4479161 [v3]

2021-08-16 Thread Sergey Bylokhov
On Mon, 16 Aug 2021 20:05:58 GMT, lawrence.andrews wrote: >> 1) Automated the manual test case. >> 2) Removed html dependent file >> 3) Removed javax.swing.JApplet dependent. >> 4) Test case can be executed independently as well with jtreg framework. >> 5) Added methods to know that JFrame and

Re: RFR: 8267161 : Write automated test case for JDK-4479161 [v2]

2021-08-16 Thread Sergey Bylokhov
On Thu, 12 Aug 2021 15:46:43 GMT, lawrence.andrews wrote: >> 1) Automated the manual test case. >> 2) Removed html dependent file >> 3) Removed javax.swing.JApplet dependent. >> 4) Test case can be executed independently as well with jtreg framework. >> 5) Added methods to know that JFrame and

Re: RFR: 8269951: [macos] Focus not painted in JButton when setBorderPainted(false) is invoked [v4]

2021-08-16 Thread Sergey Bylokhov
On Fri, 13 Aug 2021 19:17:13 GMT, Alexander Zuev wrote: >> Initial implementation and a test case. >> >> The problem is that Aqua LaF shows the focused component with the glow on >> the border, hence when the border is not painted the foxus is not displayed. >> The idea is to paint the glowing

Re: RFR: 8269951: [macos] Focus not painted in JButton when setBorderPainted(false) is invoked [v4]

2021-08-15 Thread Sergey Bylokhov
On Fri, 13 Aug 2021 19:17:13 GMT, Alexander Zuev wrote: >> Initial implementation and a test case. >> >> The problem is that Aqua LaF shows the focused component with the glow on >> the border, hence when the border is not painted the foxus is not displayed. >> The idea is to paint the glowing

Re: RFR: 8266079: Lanai: AlphaComposite shows differences on Metal compared to OpenGL [v4]

2021-08-13 Thread Sergey Bylokhov
On Fri, 13 Aug 2021 14:30:58 GMT, Alexey Ushakov wrote: >> Keep MTLLayer opacity in sync with window content view >> Keep layer translucent for translucent windows > > Alexey Ushakov has updated the pull request incrementally with one additional > commit since the last revision: > > 8266079:

Re: RFR: 8266079: Lanai: AlphaComposite shows differences on Metal compared to OpenGL [v3]

2021-08-12 Thread Sergey Bylokhov
On Thu, 12 Aug 2021 23:33:51 GMT, Alexey Ushakov wrote: >> Then you can roll back this change to the default opaque layer? > > Did you mean to make MTLLayer opaque by default? Yes, I did it in the latest > version. Then why do you need " platformWindow.setOpaque(!isTranslucent());" above?

Re: RFR: 8266079: Lanai: AlphaComposite shows differences on Metal compared to OpenGL [v3]

2021-08-12 Thread Sergey Bylokhov
On Thu, 12 Aug 2021 18:58:59 GMT, Alexey Ushakov wrote: >> Interesting, now I'm also able to reproduce this problem with the latest >> version of the fix. Actually, looks like the problem exists even without the >> fix. We get invalid background with the same scenario. It's not so visible >> b

Re: RFR: 8269951: [macos] Focus not painted in JButton when setBorderPainted(false) is invoked

2021-08-12 Thread Sergey Bylokhov
On Wed, 11 Aug 2021 11:22:50 GMT, Alexander Zuev wrote: > Initial implementation and a test case. > > The problem is that Aqua LaF shows the focused component with the glow on the > border, hence when the border is not painted the foxus is not displayed. The > idea is to paint the glowing bord

Re: RFR: 8269951: [macos] Focus not painted in JButton when setBorderPainted(false) is invoked

2021-08-12 Thread Sergey Bylokhov
On Wed, 11 Aug 2021 11:22:50 GMT, Alexander Zuev wrote: > Initial implementation and a test case. > > The problem is that Aqua LaF shows the focused component with the glow on the > border, hence when the border is not painted the foxus is not displayed. The > idea is to paint the glowing bord

Re: RFR: 8269951: [macos] Focus not painted in JButton when setBorderPainted(false) is invoked

2021-08-12 Thread Sergey Bylokhov
On Wed, 11 Aug 2021 11:22:50 GMT, Alexander Zuev wrote: > Initial implementation and a test case. > > The problem is that Aqua LaF shows the focused component with the glow on the > border, hence when the border is not painted the foxus is not displayed. The > idea is to paint the glowing bord

Re: RFR: 8269951: [macos] Focus not painted in JButton when setBorderPainted(false) is invoked

2021-08-11 Thread Sergey Bylokhov
On Wed, 11 Aug 2021 11:22:50 GMT, Alexander Zuev wrote: > Initial implementation and a test case. > > The problem is that Aqua LaF shows the focused component with the glow on the > border, hence when the border is not painted the foxus is not displayed. The > idea is to paint the glowing bord

Re: RFR: 8267161 : Write automated test case for JDK-4479161

2021-08-11 Thread Sergey Bylokhov
On Mon, 9 Aug 2021 18:36:07 GMT, lawrence.andrews wrote: > 1) Automated the manual test case. > 2) Removed html dependent file > 3) Removed javax.swing.JApplet dependent. > 4) Test case can be executed independently as well with jtreg framework. > 5) Added methods to know that JFrame and Other

Re: RFR: 8267161 : Write automated test case for JDK-4479161

2021-08-10 Thread Sergey Bylokhov
On Mon, 9 Aug 2021 18:36:07 GMT, lawrence.andrews wrote: > 1) Automated the manual test case. > 2) Removed html dependent file > 3) Removed javax.swing.JApplet dependent. > 4) Test case can be executed independently as well with jtreg framework. > 5) Added methods to know that JFrame and Other

Re: RFR: 8271603: Unnecessary Vector usage in java.desktop

2021-08-09 Thread Sergey Bylokhov
On Mon, 5 Jul 2021 14:00:07 GMT, Сергей Цыпанов wrote: >> Usage of thread-safe collection `Vector` is unnecessary. It's recommended to >> use `ArrayList` if a thread-safe implementation is not needed. In >> post-BiasedLocking times, this is gets worse, as every access is >> synchronized. >> I

Re: RFR: 8271603: Unnecessary Vector usage in java.desktop

2021-08-09 Thread Sergey Bylokhov
On Sun, 4 Jul 2021 20:42:41 GMT, Andrey Turbanov wrote: > Usage of thread-safe collection `Vector` is unnecessary. It's recommended to > use `ArrayList` if a thread-safe implementation is not needed. In > post-BiasedLocking times, this is gets worse, as every access is synchronized. > I checke

Re: RFR: 8272123: Problem list 4 jtreg tests which regularly fail on macos-aach64

2021-08-08 Thread Sergey Bylokhov
On Mon, 9 Aug 2021 03:17:20 GMT, Phil Race wrote: > As per the bug comments, these tests fail too often on macOS arm. > This will be too noisy for CI. So I would like to problem list them for > mac-arm test/jdk/ProblemList.txt line 532: > 530: > 531: java/awt/Window/GetScreenLocation/GetScre

Re: RFR: 8266079: Lanai: AlphaComposite shows differences on Metal compared to OpenGL [v2]

2021-08-08 Thread Sergey Bylokhov
On Wed, 4 Aug 2021 23:06:54 GMT, Sergey Bylokhov wrote: >> 1. Run SwingSet2 >> 2. Click on all tabs starting from the second one >> 3. On the tab with swing tree control try to expand some tree nodes -> >> you'll see black rectangles while performing the clicks

Re: RFR: 8267385: Create NSAccessibilityElement implementation for JavaComponentAccessibility [v9]

2021-08-06 Thread Sergey Bylokhov
On Mon, 2 Aug 2021 09:00:14 GMT, Artem Semenov wrote: >> 8267385: Create NSAccessibilityElement implementation for >> JavaComponentAccessibility >> This pull request contains solutions for the following tickets: >> * JDK-8267385 Create NSAccessibilityElement implementation for >> JavaComponent

Re: RFR: 8268824: Remove unused jdk.accessibility APIs deprecated for removal in JDK 9 [v2]

2021-08-04 Thread Sergey Bylokhov
On Wed, 4 Aug 2021 20:10:50 GMT, Phil Race wrote: >> These fields >> - have not been used by the implementation since JDK8, >> - are not supposed to be used by applications, >> - have been deprecated for removal since JDK 9 >> - are non-standard, JDK not Java, classes >> - very few clients are e

Re: RFR: 8266079: Lanai: AlphaComposite shows differences on Metal compared to OpenGL [v2]

2021-08-04 Thread Sergey Bylokhov
On Tue, 3 Aug 2021 20:04:14 GMT, Alexey Ushakov wrote: >> How to reproduce that artifact? > > 1. Run SwingSet2 > 2. Click on all tabs starting from the second one > 3. On the tab with swing tree control try to expand some tree nodes -> you'll > see black rectangles while performing the clicks

Integrated: 8271456: Avoid looking up standard charsets in "java.desktop" module

2021-08-04 Thread Sergey Bylokhov
On Sun, 1 Aug 2021 07:07:21 GMT, Sergey Bylokhov wrote: > This is a request to clean up a desktop module as was done in JDK-8233884 for > "java.base" module. > > In many places standard charsets are looked up via their names, for example: > absolutePath.getBytes(&qu

Re: RFR: 8271456: Avoid looking up standard charsets in "java.desktop" module [v4]

2021-08-03 Thread Sergey Bylokhov
efficiently(x20 time faster) with use of > java.nio.charset.StandardCharsets: > absolutePath.getBytes(StandardCharsets.UTF_8); > > The later variant also makes the code cleaner, as it is known not to throw > UnsupportedEncodingException in contrary to the former variant. > > Tested b

Re: RFR: 8271456: Avoid looking up standard charsets in "java.desktop" module [v2]

2021-08-03 Thread Sergey Bylokhov
On Tue, 3 Aug 2021 22:42:55 GMT, Alexey Ivanov wrote: >> I am fine to do that, if there are no objections I can change the whole fix. > >> >> I am fine to do that, if there are no objections I can change the whole fix. > > Modifying the entire changeset seems like an overkill. > Using static im

Re: RFR: 8271456: Avoid looking up standard charsets in "java.desktop" module [v3]

2021-08-03 Thread Sergey Bylokhov
efficiently(x20 time faster) with use of > java.nio.charset.StandardCharsets: > absolutePath.getBytes(StandardCharsets.UTF_8); > > The later variant also makes the code cleaner, as it is known not to throw > UnsupportedEncodingException in contrary to the former variant. > > Tested b

Re: RFR: 8271456: Avoid looking up standard charsets in "java.desktop" module [v2]

2021-08-03 Thread Sergey Bylokhov
On Tue, 3 Aug 2021 21:54:08 GMT, Alexey Ivanov wrote: >> it is aligned already, the StandardCharsets.UTF_8 is parameter of "new >> String()", not the getTransferData. > > Ah, right! > But it's confusing: it looks as if `StandardCharsets.UTF_8` is a parameter to > `getTransferData`. Maybe avoid

Re: RFR: 8271456: Avoid looking up standard charsets in "java.desktop" module [v2]

2021-08-03 Thread Sergey Bylokhov
On Tue, 3 Aug 2021 21:18:40 GMT, Alexey Ivanov wrote: >> Sergey Bylokhov has updated the pull request with a new target base due to a >> merge or a rebase. The incremental webrev excludes the unrelated changes >> brought in by the merge/rebase. The pull request conta

Re: RFR: 8266079: Lanai: AlphaComposite shows differences on Metal compared to OpenGL

2021-08-03 Thread Sergey Bylokhov
On Tue, 3 Aug 2021 19:51:30 GMT, Alexey Ushakov wrote: >> Yes, sounds reasonable. Moreover, It was my initial attempt but I faced with >> some regressions in SwingSet2 demo. In some cases background of tree nodes >> become black and this artifact was reproducible only if some other tabs were

Re: RFR: 8271456: Avoid looking up standard charsets in "java.desktop" module [v2]

2021-08-03 Thread Sergey Bylokhov
efficiently(x20 time faster) with use of > java.nio.charset.StandardCharsets: > absolutePath.getBytes(StandardCharsets.UTF_8); > > The later variant also makes the code cleaner, as it is known not to throw > UnsupportedEncodingException in contrary to the former variant. > > Tested b

Re: RFR: 8271456: Avoid looking up standard charsets in "java.desktop" module

2021-08-03 Thread Sergey Bylokhov
On Tue, 3 Aug 2021 13:30:28 GMT, Alexander Zvegintsev wrote: >> This is a request to clean up a desktop module as was done in JDK-8233884 >> for "java.base" module. >> >> In many places standard charsets are looked up via their names, for example: >> absolutePath.getBytes("UTF-8"); >> >> This

Re: RFR: 8267385: Create NSAccessibilityElement implementation for JavaComponentAccessibility [v9]

2021-08-02 Thread Sergey Bylokhov
On Mon, 2 Aug 2021 10:00:10 GMT, Artem Semenov wrote: >> In the example, you use a JList class, and the checks in the code above >> works, but if some other "AccessibleJList" class will be used then it will >> not work, right? This is the reason why implementations of a11y classes >> usually

Re: RFR: 8266079: Lanai: AlphaComposite shows differences on Metal compared to OpenGL

2021-08-02 Thread Sergey Bylokhov
On Mon, 2 Aug 2021 20:04:43 GMT, Alexey Ushakov wrote: >> src/java.desktop/macosx/classes/sun/lwawt/LWWindowPeer.java line 199: >> >>> 197: >>> 198: platformWindow.initialize(target, this, ownerDelegate); >>> 199: platformWindow.setOpaque(!isTranslucent()); >> >> !isTranslucent

Re: RFR: 8266079: Lanai: AlphaComposite shows differences on Metal compared to OpenGL

2021-08-02 Thread Sergey Bylokhov
On Fri, 30 Jul 2021 15:39:19 GMT, Alexey Ushakov wrote: > Keep MTLLayer opacity in sync with window content view > Keep layer translucent for translucent windows src/java.desktop/macosx/classes/sun/lwawt/LWWindowPeer.java line 199: > 197: > 198: platformWindow.initialize(target, this,

Re: RFR: 8267385: Create NSAccessibilityElement implementation for JavaComponentAccessibility [v8]

2021-08-01 Thread Sergey Bylokhov
On Wed, 21 Jul 2021 17:25:48 GMT, Artem Semenov wrote: >> src/java.desktop/macosx/classes/sun/lwawt/macosx/CAccessibility.java line >> 556: >> >>> 554: ((JList) parent).setSelectedIndex(i); >>> 555: return; >>> 556: } >> >> Looks like th

Re: RFR: 8267385: Create NSAccessibilityElement implementation for JavaComponentAccessibility [v8]

2021-08-01 Thread Sergey Bylokhov
On Wed, 21 Jul 2021 13:16:46 GMT, Artem Semenov wrote: >> The comment states that it is not necessary to call ExceptionCheck, but it >> will be done before by the CHECK_EXCEPTION. The macro also will log it when >> necessary. > > Done I suggest doing the opposite, leave the CHECK_EXCEPTION an

Re: RFR: 8269130: Replace usages of Collection.toArray() with Collection.toArray(T[]) to avoid redundant array copying

2021-08-01 Thread Sergey Bylokhov
On Mon, 14 Jun 2021 17:00:29 GMT, Andrey Turbanov wrote: > I found few places, where code initially perform `Object[] > Colleciton.toArray()` call and then manually copy array into another array > with required type. > This PR cleanups such places to more shorter call `T[] > Collection.toArra

RFR: 8271456: Avoid looking up standard charsets in "java.desktop" module

2021-08-01 Thread Sergey Bylokhov
This is a request to clean up a desktop module as was done in JDK-8233884 for "java.base" module. In many places standard charsets are looked up via their names, for example: absolutePath.getBytes("UTF-8"); This could be done more efficiently(x20 time faster) with use of java.nio.charset.Standa

Re: RFR: 8269130: Replace usages of Collection.toArray() with Collection.toArray(T[]) to avoid redundant array copying

2021-07-26 Thread Sergey Bylokhov
On Mon, 14 Jun 2021 17:00:29 GMT, Andrey Turbanov wrote: > I found few places, where code initially perform `Object[] > Colleciton.toArray()` call and then manually copy array into another array > with required type. > This PR cleanups such places to more shorter call `T[] > Collection.toArra

Re: [jdk17] RFR: 8015886: java/awt/Focus/DeiconifiedFrameLoosesFocus/DeiconifiedFrameLoosesFocus.java sometimes failed on ubuntu [v4]

2021-07-23 Thread Sergey Bylokhov
On Fri, 23 Jul 2021 12:56:32 GMT, Alexander Zvegintsev wrote: >> This test can fail pretty consistently on some slow systems. Increased delay >> fixes the issue. >> We do have similar fix in #260 > > Alexander Zvegintsev has updated the pull request incrementally with one > additional commit

Re: [jdk17] RFR: 8015886: java/awt/Focus/DeiconifiedFrameLoosesFocus/DeiconifiedFrameLoosesFocus.java sometimes failed on ubuntu [v2]

2021-07-22 Thread Sergey Bylokhov
On Thu, 22 Jul 2021 20:49:36 GMT, Alexander Zvegintsev wrote: >> This test can fail pretty consistently on some slow systems. Increased delay >> fixes the issue. >> We do have similar fix in #260 > > Alexander Zvegintsev has updated the pull request incrementally with one > additional commit

Re: RFR: 8270859: Post JEP 411 refactoring: client libs with maximum covering > 10K

2021-07-16 Thread Sergey Bylokhov
On Fri, 16 Jul 2021 20:52:08 GMT, Weijun Wang wrote: > This is the last part of Post JEP 411 refactoring that makes > `@SuppressWarnings("removal")` more fine grained. This fix deals with all > client libs annotations that cover more than 10K bytes of code. After the requested change to the Pr

Re: [jdk17] RFR: 8266079: Lanai: AlphaComposite shows differences on Metal compared to OpenGL [v5]

2021-07-05 Thread Sergey Bylokhov
On Mon, 5 Jul 2021 15:55:20 GMT, Alexey Ushakov wrote: >> Implemented blit via compute kernel > > Alexey Ushakov has updated the pull request incrementally with one additional > commit since the last revision: > > 8266079: Lanai: AlphaComposite shows differences on Metal compared to OpenGL >

Re: RFR: 8267385: Create NSAccessibilityElement implementation for JavaComponentAccessibility [v2]

2021-07-02 Thread Sergey Bylokhov
On Fri, 2 Jul 2021 14:05:40 GMT, Artem Semenov wrote: >> src/java.desktop/macosx/classes/sun/lwawt/macosx/CAccessibility.java line >> 130: >> >>> 128: if (c != null) { >>> 129: try { >>> 130: value = EventQueue.isDispatchThread() ? >>> callable.call() : LWC

Re: RFR: 8267385: Create NSAccessibilityElement implementation for JavaComponentAccessibility

2021-07-01 Thread Sergey Bylokhov
On Tue, 8 Jun 2021 13:06:53 GMT, Artem Semenov wrote: > 8267385: Create NSAccessibilityElement implementation for > JavaComponentAccessibility > This pull request contains solutions for the following tickets: > * JDK-8267385 Create NSAccessibilityElement implementation for > JavaComponentAcces

Re: RFR: 8267385: Create NSAccessibilityElement implementation for JavaComponentAccessibility

2021-06-29 Thread Sergey Bylokhov
On Tue, 29 Jun 2021 13:26:29 GMT, Artem Semenov wrote: >> test/jdk/java/awt/a11y/AccessibleJComboboxTest.java line 30: >> >>> 28: * @summary Create implementation for NSAccessibilityComboBox protocol >>> peer >>> 29: * @author artem.seme...@jetbrains.com >>> 30: * @run main/manual Accessibl

Re: [jdk17] RFR: 8266079: Lanai: AlphaComposite shows differences on Metal compared to OpenGL [v2]

2021-06-28 Thread Sergey Bylokhov
On Wed, 23 Jun 2021 12:15:03 GMT, Alexey Ushakov wrote: >> Implemented blit via compute kernel > > Alexey Ushakov has refreshed the contents of this pull request, and previous > commits have been removed. The incremental views will show differences > compared to the previous content of the PR.

Re: [jdk17] RFR: 8266079: Lanai: AlphaComposite shows differences on Metal compared to OpenGL

2021-06-17 Thread Sergey Bylokhov
On Wed, 16 Jun 2021 10:34:50 GMT, Alexey Ushakov wrote: >> src/java.desktop/macosx/native/libawt_lwawt/java2d/metal/MTLLayer.m line 159: >> >>> 157: [computeEncoder endEncoding]; >>> 158: [cb commit]; >>> 159: #endif >> >> This is better than changing the background color, but s

Re: RFR: 8267385: Create NSAccessibilityElement implementation for JavaComponentAccessibility

2021-06-16 Thread Sergey Bylokhov
On Tue, 8 Jun 2021 13:06:53 GMT, Artem Semenov wrote: > 8267385: Create NSAccessibilityElement implementation for > JavaComponentAccessibility > This pull request contains solutions for the following tickets: > * JDK-8267385 Create NSAccessibilityElement implementation for > JavaComponentAcces

Re: [jdk17] RFR: 8266079: Lanai: AlphaComposite shows differences on Metal compared to OpenGL

2021-06-15 Thread Sergey Bylokhov
On Tue, 15 Jun 2021 16:57:00 GMT, Alexey Ushakov wrote: > Implemented blit via compute kernel Marked as reviewed by serb (Reviewer). src/java.desktop/macosx/native/libawt_lwawt/java2d/metal/MTLLayer.m line 159: > 157: [computeEncoder endEncoding]; > 158: [cb commit]; > 159: #en

Integrated: 8268620: InfiniteLoopException test may fail on x86 platforms

2021-06-15 Thread Sergey Bylokhov
On Mon, 14 Jun 2021 17:18:15 GMT, Sergey Bylokhov wrote: > Small test update. > > This test posts lots of events to EDT from the different threads, and it > checks that the robot.waitForIdle() on the main thread will not hang or throw > an exception. And this test fails on x

RFR: 8268620: InfiniteLoopException test may fail on x86 platforms

2021-06-14 Thread Sergey Bylokhov
Small test update. This test posts lots of events to EDT from the different threads, and it checks that the robot.waitForIdle() on the main thread will not hang or throw an exception. And this test fails on x86. The post of events are implemented via wait/notifyAll, and the robot.waitForIdle()

Integrated: 8268481: Delete JAWT test files for mac

2021-06-10 Thread Sergey Bylokhov
On Wed, 9 Jun 2021 19:49:28 GMT, Sergey Bylokhov wrote: > Due to some issues, we need to delete these files. Later this test case will > be updated and reintegrated. This pull request has now been integrated. Changeset: ea19b044 Author:Sergey Bylokhov URL:

Re: RFR: 8267430: GraphicsDevice.setDisplayMode(REFRESH_RATE_UNKNOWN) throws AE: Unable to set display mode! [v4]

2021-06-09 Thread Sergey Bylokhov
On Tue, 8 Jun 2021 21:45:43 GMT, Phil Race wrote: >> There are two issues here, both macOS specific. >> First the original reported one that occurs when running on a shared remote >> VNC type desktop on macOS. >> Only a single supported display mode is returned and it is also the current >> mod

RFR: 8268481: Delete JAWT test files for mac

2021-06-09 Thread Sergey Bylokhov
Due to some issues, we need to delete these files. Later this test case will be updated and reintegrated. - Commit messages: - Revert "8263928: Add JAWT test files for mac" Changes: https://git.openjdk.java.net/jdk/pull/4440/files Webrev: https://webrevs.openjdk.java.net/?repo=jdk

Re: RFR: 8267307: Introduce new client property for XAWT: xawt.mwm_decor_title [v3]

2021-06-09 Thread Sergey Bylokhov
On Mon, 7 Jun 2021 10:30:33 GMT, Maxim Kartashev wrote: >> This commit introduces a new client property xawt.mwm_decor_title >> implementing JDK-8267307. The property can be set prior to showing a window >> or after the window has been displayed, in which case the window will have >> to be hi

Re: RFR: 8267307: Introduce new client property for XAWT: xawt.mwm_decor_title [v3]

2021-06-08 Thread Sergey Bylokhov
On Mon, 7 Jun 2021 10:30:33 GMT, Maxim Kartashev wrote: >> This commit introduces a new client property xawt.mwm_decor_title >> implementing JDK-8267307. The property can be set prior to showing a window >> or after the window has been displayed, in which case the window will have >> to be hi

Re: RFR: 8267430: GraphicsDevice.setDisplayMode(REFRESH_RATE_UNKNOWN) throws AE: Unable to set display mode!

2021-06-08 Thread Sergey Bylokhov
On Mon, 7 Jun 2021 15:13:27 GMT, Phil Race wrote: >> There are two issues here, both macOS specific. >> First the original reported one that occurs when running on a shared remote >> VNC type desktop on macOS. >> Only a single supported display mode is returned and it is also the current >> mod

Re: RFR: 8267430: GraphicsDevice.setDisplayMode(REFRESH_RATE_UNKNOWN) throws AE: Unable to set display mode! [v2]

2021-06-08 Thread Sergey Bylokhov
On Mon, 7 Jun 2021 19:50:33 GMT, Sergey Bylokhov wrote: >> Phil Race has updated the pull request incrementally with one additional >> commit since the last revision: >> >> 8267430: GraphicsDevice.setDisplayMode(REFRESH_RATE_UNKNOWN) throws IAE: >> Unable to

Re: RFR: 8267430: GraphicsDevice.setDisplayMode(REFRESH_RATE_UNKNOWN) throws AE: Unable to set display mode! [v2]

2021-06-07 Thread Sergey Bylokhov
On Mon, 7 Jun 2021 15:17:48 GMT, Phil Race wrote: >> There are two issues here, both macOS specific. >> First the original reported one that occurs when running on a shared remote >> VNC type desktop on macOS. >> Only a single supported display mode is returned and it is also the current >> mod

Re: RFR: 8267430: GraphicsDevice.setDisplayMode(REFRESH_RATE_UNKNOWN) throws AE: Unable to set display mode! [v2]

2021-06-07 Thread Sergey Bylokhov
On Mon, 7 Jun 2021 15:17:48 GMT, Phil Race wrote: >> There are two issues here, both macOS specific. >> First the original reported one that occurs when running on a shared remote >> VNC type desktop on macOS. >> Only a single supported display mode is returned and it is also the current >> mod

Re: RFR: 8256465: [macos] Java frame and dialog presented full screen freeze application [v11]

2021-06-04 Thread Sergey Bylokhov
On Fri, 4 Jun 2021 14:25:31 GMT, Tejpal Rebari wrote: >> Hi All, >> Please review the following fix for jdk17. >> >> Issue : On MacOS 11 Java Frame and JDialog application is freezing in Full >> Screen when the System Preference -> General -> Prefer Tabs is set to "Full >> Screen". It is als

Re: RFR: 8267307: Introduce new client property for XAWT: xawt.mwm_decor_title [v2]

2021-06-04 Thread Sergey Bylokhov
On Fri, 4 Jun 2021 08:44:22 GMT, Maxim Kartashev wrote: >> This commit introduces a new client property xawt.mwm_decor_title >> implementing JDK-8267307. The property can be set prior to showing a window >> or after the window has been displayed, in which case the window will have >> to be hi

Re: RFR: 8267307: Introduce new client property for XAWT: xawt.mwm_decor_title

2021-06-03 Thread Sergey Bylokhov
On Wed, 19 May 2021 10:23:01 GMT, Maxim Kartashev wrote: > This commit introduces a new client property xawt.mwm_decor_title > implementing JDK-8267307. The property can be set prior to showing a window > or after the window has been displayed, in which case the window will have to > be hidde

Re: RFR: 8266079: Lanai: AlphaComposite shows differences on Metal compared to OpenGL

2021-06-03 Thread Sergey Bylokhov
On Thu, 3 Jun 2021 13:59:57 GMT, Alexey Ushakov wrote: > AFAIK, we don't have any control over composing the layer content on top of > the window surface. We just get drawable for the layer that has a texture > attached and then blits our content into it. Probably I missed your point, but ther

Re: RFR: 8267307: Introduce new client property for XAWT: xawt.mwm_decor_title

2021-06-02 Thread Sergey Bylokhov
On Wed, 19 May 2021 10:23:01 GMT, Maxim Kartashev wrote: > This commit introduces a new client property xawt.mwm_decor_title > implementing JDK-8267307. The property can be set prior to showing a window > or after the window has been displayed, in which case the window will have to > be hidde

Re: RFR: 8266079: Lanai: AlphaComposite shows differences on Metal compared to OpenGL

2021-06-01 Thread Sergey Bylokhov
On Wed, 26 May 2021 13:49:24 GMT, Alexey Ushakov wrote: > Set black color for underlying window background to perform correct blending > operations in metal with window surface destination I guess the bug happens when we blit our "layer" surface to the window? So there is no way to set a kind

Re: RFR: 8267307: Introduce new client property for XAWT: xawt.mwm_decor_title

2021-06-01 Thread Sergey Bylokhov
On Wed, 19 May 2021 10:23:01 GMT, Maxim Kartashev wrote: > This commit introduces a new client property xawt.mwm_decor_title > implementing JDK-8267307. The property can be set prior to showing a window > or after the window has been displayed, in which case the window will have to > be hidde

Re: RFR: 8182043: Access to Windows Large Icons [v16]

2021-05-27 Thread Sergey Bylokhov
On Fri, 7 May 2021 17:53:49 GMT, Alexander Zuev wrote: >> This comment is also about the case of not fetching icons of sizes smaller >> than requested size. > > Sorry, missed that in my latest fix. Indeed there is no legitimate ways to > set scaling factor to less than 100% on Windows so yes, o

Re: RFR: 8182043: Access to Windows Large Icons [v15]

2021-05-27 Thread Sergey Bylokhov
On Thu, 27 May 2021 16:38:02 GMT, Alexander Zuev wrote: >> Is this requirement is so important? can we return an MRI(same as on >> Windows) which will have just one resolution? Otherwise what the user should >> do if the requested size was 32x32 but returned image will be 21x21? Paint >> the s

Re: RFR: 8182043: Access to Windows Large Icons [v15]

2021-05-27 Thread Sergey Bylokhov
On Wed, 26 May 2021 21:39:19 GMT, Alexander Zuev wrote: >> test/jdk/javax/swing/JFileChooser/FileSystemView/SystemIconTest.java line 87: >> >>> 85: } >>> 86: >>> 87: if (implComplete && icon.getIconWidth() != size) { >> >> Why the size of the returned images might be di

Re: RFR: 8182043: Access to Windows Large Icons [v15]

2021-05-26 Thread Sergey Bylokhov
On Wed, 26 May 2021 16:52:38 GMT, Alexander Zuev wrote: >> Fix updated after first round of review. > > Alexander Zuev has updated the pull request incrementally with two additional > commits since the last revision: > > - Fixed small errors >Adjustments in the test > - Grammar fix in met

Re: RFR: 8182043: Access to Windows Large Icons [v7]

2021-05-26 Thread Sergey Bylokhov
On Fri, 21 May 2021 19:37:19 GMT, Alexander Zuev wrote: >> Didn't you answer your question already? If `FileSystemView.getRoots()` >> returns Desktop in Windows shell namespace. Otherwise, I don't know a way to >> get a reference to a *virtual* folder in Windows shell namespace which >> doesn'

Re: RFR: 8182043: Access to Windows Large Icons [v15]

2021-05-26 Thread Sergey Bylokhov
On Wed, 26 May 2021 16:52:38 GMT, Alexander Zuev wrote: >> Fix updated after first round of review. > > Alexander Zuev has updated the pull request incrementally with two additional > commits since the last revision: > > - Fixed small errors >Adjustments in the test > - Grammar fix in met

Re: RFR: 8266079: Lanai: AlphaComposite shows differences on Metal compared to OpenGL

2021-05-26 Thread Sergey Bylokhov
On Wed, 26 May 2021 13:49:24 GMT, Alexey Ushakov wrote: > Set black color for underlying window background to perform correct blending > operations in metal with window surface destination I think this will resurrect the JDK-8033786, but with a different color - black instead of white. --

Re: RFR: 8182043: Access to Windows Large Icons [v10]

2021-05-21 Thread Sergey Bylokhov
On Fri, 21 May 2021 01:11:38 GMT, Sergey Bylokhov wrote: >>> But this is shared code, which has a specification it should work >>> everywhere, so even if on Linux and macOS it is not implemented in the best >>> way it should return something. >> >> T

Re: RFR: 8182043: Access to Windows Large Icons [v7]

2021-05-21 Thread Sergey Bylokhov
On Fri, 21 May 2021 06:32:02 GMT, Alexander Zuev wrote: >> It is accessible from the "JFileChooser" drop-down menu. On my system, the >> Libraries at that drop down menu contain "GIT", "Documents", "Music". >> https://docs.microsoft.com/en-us/windows/client-management/windows-libraries >> >> T

Re: RFR: 8182043: Access to Windows Large Icons [v7]

2021-05-20 Thread Sergey Bylokhov
On Fri, 21 May 2021 04:15:41 GMT, Alexander Zuev wrote: >> Maybe we can test this case by just reusing this method where the >> "sf.getIcon(largeicon)" previously used in the WindowsPlacesBar class? That >> old method has the special code for "folder.isLibrary()" so I assume it >> supported th

Re: RFR: 8182043: Access to Windows Large Icons [v7]

2021-05-20 Thread Sergey Bylokhov
On Fri, 21 May 2021 02:45:15 GMT, Sergey Bylokhov wrote: >> No, libraries are not supported. >> >> I see no contradiction here: `JFileChooser` uses Windows Shell API to >> enumerate objects and navigate the shell namespace. But it does not return >> non-file ob

  1   2   3   4   5   6   7   8   9   10   >