Re: [jdk17] RFR: 8269269: [macos11] SystemIconTest fails with ClassCastException

2021-06-29 Thread Sergey Bylokhov
On Wed, 30 Jun 2021 04:23:45 GMT, Alexander Zuev wrote: >> test/jdk/javax/swing/JFileChooser/FileSystemView/SystemIconTest.java line 76: >> >>> 74: int[] sizes = new int[] {16, 32, 48, 64, 128}; >>> 75: for (int size : sizes) { >>> 76: ImageIcon icon = (ImageIcon)

Re: [jdk17] RFR: 8269269: [macos11] SystemIconTest fails with ClassCastException

2021-06-29 Thread Sergey Bylokhov
On Wed, 30 Jun 2021 04:22:37 GMT, Alexander Zuev wrote: > No, the native code will fail to load the icon So what call will fail? Is the "sf.getIcon()" return null? in what line of code? >> But you cannot change the return type later, so all these instanceof+casts >> will be there forever. > >>

Re: [jdk17] RFR: 8268775: Password is being converted to String in AccessibleJPasswordField

2021-06-29 Thread Sergey Bylokhov
On Thu, 24 Jun 2021 04:39:12 GMT, Alexander Zuev wrote: >> src/java.desktop/share/classes/javax/swing/JPasswordField.java line 634: >> >>> 632: Arrays.fill(password, getEchoChar()); >>> 633: String text = new String(password); >>> 634: return new

Re: [jdk17] RFR: 8269269: [macos11] SystemIconTest fails with ClassCastException

2021-06-29 Thread Alexander Zuev
On Wed, 30 Jun 2021 03:01:03 GMT, Sergey Bylokhov wrote: > * but what happens if the file cannot be read? We will call the "sf = > ShellFolder.getShellFolder" and then we call "sf.getIcon()" and it returns > what? As far as I understand it always return MultiResolutionIconImage, no? > * No,

Re: [jdk17] RFR: 8269269: [macos11] SystemIconTest fails with ClassCastException

2021-06-29 Thread Alexander Zuev
On Tue, 29 Jun 2021 23:47:27 GMT, Sergey Bylokhov wrote: > Probably we can wrap the "UIManager.getIcon" in the "ImageIcon"? Why? In some LaFs that might be a procedural image that generates it content every time paint() is called on it - i do not think wrapping it in the ImageIcon will solve

Re: [jdk17] RFR: 8269269: [macos11] SystemIconTest fails with ClassCastException

2021-06-29 Thread Alexander Zuev
On Wed, 30 Jun 2021 02:54:21 GMT, Sergey Bylokhov wrote: > But you cannot change the return type later, so all these instanceof+casts > will be there forever. Well, if there is a reason the API can be amended in the future version of Java. It is not cast in stone. Yes, it will require some

Re: [jdk17] RFR: 8268775: Password is being converted to String in AccessibleJPasswordField

2021-06-29 Thread Victor Dyakov
On Wed, 23 Jun 2021 17:20:27 GMT, Alexander Zuev wrote: > 8268775: Password is being converted to String in AccessibleJPasswordField @mrserb please review - PR: https://git.openjdk.java.net/jdk17/pull/127

Re: [jdk17] RFR: 8269269: [macos11] SystemIconTest fails with ClassCastException

2021-06-29 Thread Sergey Bylokhov
On Wed, 30 Jun 2021 01:13:29 GMT, Alexander Zuev wrote: >> test/jdk/javax/swing/JFileChooser/FileSystemView/SystemIconTest.java line 75: >> >>> 73: static void testSystemIcon(File file, boolean implComplete) { >>> 74: int[] sizes = new int[] {16, 32, 48, 64, 128}; >>> 75: if

Re: RFR: Merge jdk17 [v2]

2021-06-29 Thread Jesper Wilhelmsson
> Forwardport JDK 17 -> JDK 18 Jesper Wilhelmsson has updated the pull request with a new target base due to a merge or a rebase. The pull request now contains 113 commits: - Merge - 8269615: Fix for 8263640 broke Windows build Reviewed-by: iklam, dcubed - 8269268: JDWP: Properly fix

Integrated: Merge jdk17

2021-06-29 Thread Jesper Wilhelmsson
On Wed, 30 Jun 2021 00:31:34 GMT, Jesper Wilhelmsson wrote: > Forwardport JDK 17 -> JDK 18 This pull request has now been integrated. Changeset: ee526a2e Author:Jesper Wilhelmsson URL: https://git.openjdk.java.net/jdk/commit/ee526a2ea840aedb97b23538f9d624acbccebc97 Stats: 127

Re: [jdk17] RFR: 8269269: [macos11] SystemIconTest fails with ClassCastException

2021-06-29 Thread Alexander Zuev
On Tue, 29 Jun 2021 23:51:06 GMT, Sergey Bylokhov wrote: > One more time would like to highlight that to get the data of the requested > image the user need to do one "if" and two "instanceof". Still hope that we > can improve this. We might when the implementation will be complete on all the

Re: [jdk17] RFR: 8269269: [macos11] SystemIconTest fails with ClassCastException

2021-06-29 Thread Alexander Zuev
On Tue, 29 Jun 2021 23:44:04 GMT, Sergey Bylokhov wrote: > If this file is not accessible the "getSystemIcon" should return "null" you > can check it here. If file is not accessible we still return default icon for file or folder - if we, for example, looking at the folder in file explorer

RFR: Merge jdk17

2021-06-29 Thread Jesper Wilhelmsson
Forwardport JDK 17 -> JDK 18 - Commit messages: - Merge - 8269034: AccessControlException for SunPKCS11 daemon threads - 8269529: javax/swing/reliability/HangDuringStaticInitialization.java fails in Windows debug build - 8269232: assert(!is_jweak(handle)) failed: wrong method

Re: [jdk17] RFR: 8269269: [macos11] SystemIconTest fails with ClassCastException

2021-06-29 Thread Sergey Bylokhov
On Tue, 29 Jun 2021 22:10:46 GMT, Alexander Zuev wrote: > Added check for the icon class type > Added check if file or folder we are testing against exists and > accessible > Removed test from problem list test/jdk/javax/swing/JFileChooser/FileSystemView/SystemIconTest.java line 75: > 73:

Re: [jdk17] RFR: 8269269: [macos11] SystemIconTest fails with ClassCastException

2021-06-29 Thread Victor Dyakov
On Tue, 29 Jun 2021 22:10:46 GMT, Alexander Zuev wrote: > Added check for the icon class type > Added check if file or folder we are testing against exists and > accessible > Removed test from problem list @prsadhuk @azvegint please review - PR:

Re: [jdk17] RFR: 8269269: [macos11] SystemIconTest fails with ClassCastException [v2]

2021-06-29 Thread Victor Dyakov
On Tue, 29 Jun 2021 22:06:37 GMT, Alexander Zuev wrote: >> 8268280: javax/swing/JFileChooser/FileSystemView/SystemIconTest.java fails >> on windows > > Alexander Zuev has updated the pull request with a new target base due to a > merge or a rebase. The incremental webrev excludes the unrelated

[jdk17] RFR: 8269269: [macos11] SystemIconTest fails with ClassCastException

2021-06-29 Thread Alexander Zuev
Added check for the icon class type Added check if file or folder we are testing against exists and accessible Removed test from problem list - Commit messages: - 8269269: [macos11] SystemIconTest fails with ClassCastException Changes:

[jdk17] Withdrawn: 8269269: [macos11] SystemIconTest fails with ClassCastException

2021-06-29 Thread Alexander Zuev
On Tue, 29 Jun 2021 19:11:32 GMT, Alexander Zuev wrote: > 8268280: javax/swing/JFileChooser/FileSystemView/SystemIconTest.java fails on > windows This pull request has been closed without being integrated. - PR: https://git.openjdk.java.net/jdk17/pull/176

Re: [jdk17] RFR: 8269269: [macos11] SystemIconTest fails with ClassCastException [v2]

2021-06-29 Thread Alexander Zuev
> 8268280: javax/swing/JFileChooser/FileSystemView/SystemIconTest.java fails on > windows Alexander Zuev 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

Re: [jdk17] RFR: 8269529: javax/swing/reliability/HangDuringStaticInitialization.java fails in Windows debug build [v3]

2021-06-29 Thread Christoph Langer
On Tue, 29 Jun 2021 08:29:29 GMT, Christoph Langer wrote: >> Exclude test on Windows if VM is from a debug build. > > Christoph Langer has updated the pull request incrementally with one > additional commit since the last revision: > > Update Copyright year Thanks for the reviews.

[jdk17] Integrated: 8269529: javax/swing/reliability/HangDuringStaticInitialization.java fails in Windows debug build

2021-06-29 Thread Christoph Langer
On Mon, 28 Jun 2021 15:29:25 GMT, Christoph Langer wrote: > Exclude test on Windows if VM is from a debug build. This pull request has now been integrated. Changeset: d0420295 Author:Christoph Langer URL:

Re: [jdk17] RFR: 8269269: [macos11] SystemIconTest fails with ClassCastException

2021-06-29 Thread Alexander Zuev
On Tue, 29 Jun 2021 19:11:32 GMT, Alexander Zuev wrote: > 8268280: javax/swing/JFileChooser/FileSystemView/SystemIconTest.java fails on > windows test/jdk/javax/swing/JFileChooser/FileSystemView/SystemIconTest.java line 75: > 73: static void testSystemIcon(File file, boolean implComplete)

[jdk17] RFR: 8269269: [macos11] SystemIconTest fails with ClassCastException

2021-06-29 Thread Alexander Zuev
8268280: javax/swing/JFileChooser/FileSystemView/SystemIconTest.java fails on windows - Commit messages: - 8269269: [macos11] SystemIconTest fails with ClassCastException Changes: https://git.openjdk.java.net/jdk17/pull/176/files Webrev:

Re: [jdk17] RFR: 8269529: javax/swing/reliability/HangDuringStaticInitialization.java fails in Windows debug build [v3]

2021-06-29 Thread Prasanta Sadhukhan
On Tue, 29 Jun 2021 08:29:29 GMT, Christoph Langer wrote: >> Exclude test on Windows if VM is from a debug build. > > Christoph Langer has updated the pull request incrementally with one > additional commit since the last revision: > > Update Copyright year Marked as reviewed by psadhukhan

Re: [jdk17] RFR: 8269529: javax/swing/reliability/HangDuringStaticInitialization.java fails in Windows debug build [v3]

2021-06-29 Thread Pankaj Bansal
On Tue, 29 Jun 2021 08:29:29 GMT, Christoph Langer wrote: >> Exclude test on Windows if VM is from a debug build. > > Christoph Langer has updated the pull request incrementally with one > additional commit since the last revision: > > Update Copyright year Marked as reviewed by pbansal

Re: [jdk17] RFR: 8269529: javax/swing/reliability/HangDuringStaticInitialization.java fails in Windows debug build [v2]

2021-06-29 Thread Christoph Langer
On Tue, 29 Jun 2021 08:18:46 GMT, Prasanta Sadhukhan wrote: > looks ok. It will be good to update the copyright date too... You're right, thanks for the hint... updated. - PR: https://git.openjdk.java.net/jdk17/pull/160

Re: [jdk17] RFR: 8269529: javax/swing/reliability/HangDuringStaticInitialization.java fails in Windows debug build [v3]

2021-06-29 Thread Christoph Langer
> Exclude test on Windows if VM is from a debug build. Christoph Langer has updated the pull request incrementally with one additional commit since the last revision: Update Copyright year - Changes: - all: https://git.openjdk.java.net/jdk17/pull/160/files - new:

Re: [jdk17] RFR: 8269529: javax/swing/reliability/HangDuringStaticInitialization.java fails in Windows debug build [v2]

2021-06-29 Thread Prasanta Sadhukhan
On Mon, 28 Jun 2021 15:43:35 GMT, Christoph Langer wrote: >> Exclude test on Windows if VM is from a debug build. > > Christoph Langer has refreshed the contents of this pull request, and > previous commits have been removed. The incremental views will show > differences compared to the