Re: RFR: 8284444: Sting typo

2022-04-06 Thread Alexey Ivanov
On Wed, 6 Apr 2022 12:07:30 GMT, Daniel Jeliński wrote: > This patch adds missing `r` in `string`s src/java.desktop/share/native/liblcms/cmstypes.c line 3668: > 3666: // Auxiliary, read an string specified as count + string > 3667: static > 3668: cmsBool ReadCountAndString(struct _cms_typehand

Re: RFR: 8284444: Sting typo [v3]

2022-04-06 Thread Alexey Ivanov
On Wed, 6 Apr 2022 16:47:17 GMT, Daniel Jeliński wrote: >> This patch adds missing `r` in `string`s > > Daniel Jeliński has updated the pull request incrementally with two > additional commits since the last revision: > > - revert xalan changes > - revert icu changes The changes look fine to

Re: RFR: 8285306: Fix typos in java.desktop

2022-04-28 Thread Alexey Ivanov
On Thu, 21 Apr 2022 08:35:36 GMT, Magnus Ihse Bursie wrote: > I ran `codespell` on the `src/java.desktop` directory, and accepted those > changes where it indeed discovered real typos. > > I ignored typos in public methods and variables. Maybe they can be fixed > later on without much fanfare,

Re: RFR: 8285306: Fix typos in java.desktop [v6]

2022-05-13 Thread Alexey Ivanov
On Fri, 13 May 2022 16:53:31 GMT, Magnus Ihse Bursie wrote: >> Nearly 500 files are too many. Smaller chunks would be easier to review. >> >> Some of the native code files could come from upstream libraries. > > @aivanov-jdk While I approve of finding and fixing spelling mistakes, > grammatical

Re: RFR: 8285306: Fix typos in java.desktop [v6]

2022-05-13 Thread Alexey Ivanov
On Fri, 13 May 2022 16:48:35 GMT, Magnus Ihse Bursie wrote: >> src/java.desktop/share/classes/sun/swing/text/TextComponentPrintable.java >> line 772: >> >>> 770: /* >>> 771: * we do not store the same value as previous. >>> in our >>> 772:

Re: RFR: 8285306: Fix typos in java.desktop

2022-05-13 Thread Alexey Ivanov
On Wed, 27 Apr 2022 03:38:09 GMT, Phil Race wrote: > Please exclude ALL 3rd party libraries from this PR. Are these the only files to be excluded? src/java.desktop/share/native/libfreetype/src/autofit/afcjk.c src/java.desktop/share/native/libfreetype/src/autofit/aflatin.c src/java.desktop/shar

RFR: 8284191: Replace usages of 'a the' in hotspot and java.base

2022-05-18 Thread Alexey Ivanov
Replaces usages of articles that follow each other in all combinations: a/the, an?/an?, the/the… Also, I fixed a couple of spelling mistakes. - Commit messages: - 8284191: Replace usages of 'the an' in hotspot and java.base - 8284191: Replace usages of 'the an' in hotspot and java

RFR: 8284209: Replace remaining usages of 'a the' in source code

2022-05-18 Thread Alexey Ivanov
Replaces usages of articles that follow each other in all combinations: a/the, an?/an?, the/the… It's the last issue in the series, and it still touches different areas of the code. - Commit messages: - 8284209: Replace remaining usages of 'the a' in source code - 8284209: Replac

Re: RFR: 8284191: Replace usages of 'a the' in hotspot and java.base [v2]

2022-05-19 Thread Alexey Ivanov
> Replaces usages of articles that follow each other in all combinations: > a/the, an?/an?, the/the… > > Also, I fixed a couple of spelling mistakes. Alexey Ivanov has updated the pull request incrementally with seven additional commits since the last revision: - ...set t

Re: RFR: 8284191: Replace usages of 'a the' in hotspot and java.base [v2]

2022-05-19 Thread Alexey Ivanov
On Thu, 19 May 2022 08:47:47 GMT, Kevin Walls wrote: >> Alexey Ivanov has updated the pull request incrementally with seven >> additional commits since the last revision: >> >> - ...set to the values... >> - ...will result in a Zip64 Extra (EXT) header &g

Re: RFR: 8284191: Replace usages of 'a the' in hotspot and java.base [v2]

2022-05-19 Thread Alexey Ivanov
On Thu, 19 May 2022 09:38:40 GMT, Kevin Walls wrote: >> Alexey Ivanov has updated the pull request incrementally with seven >> additional commits since the last revision: >> >> - ...set to the values... >> - ...will result in a Zip64 Extra (EXT) header &g

Re: RFR: 8284191: Replace usages of 'a the' in hotspot and java.base [v3]

2022-05-23 Thread Alexey Ivanov
> Replaces usages of articles that follow each other in all combinations: > a/the, an?/an?, the/the… > > Also, I fixed a couple of spelling mistakes. Alexey Ivanov has updated the pull request incrementally with one additional commit since the last revision: Update copyr

Re: RFR: 8284209: Replace remaining usages of 'a the' in source code [v2]

2022-05-23 Thread Alexey Ivanov
> Replaces usages of articles that follow each other in all combinations: > a/the, an?/an?, the/the… > > It's the last issue in the series, and it still touches different areas of > the code. Alexey Ivanov has updated the pull request with a new target base due to a me

Re: RFR: 8284209: Replace remaining usages of 'a the' in source code [v3]

2022-05-24 Thread Alexey Ivanov
> Replaces usages of articles that follow each other in all combinations: > a/the, an?/an?, the/the… > > It's the last issue in the series, and it still touches different areas of > the code. Alexey Ivanov has updated the pull request incrementally with one additional c

Integrated: 8284191: Replace usages of 'a the' in hotspot and java.base

2022-05-24 Thread Alexey Ivanov
On Wed, 18 May 2022 13:27:24 GMT, Alexey Ivanov wrote: > Replaces usages of articles that follow each other in all combinations: > a/the, an?/an?, the/the… > > Also, I fixed a couple of spelling mistakes. This pull request has now been integrated. Changeset: e0d361ce Author:A

Integrated: 8284209: Replace remaining usages of 'a the' in source code

2022-05-24 Thread Alexey Ivanov
On Wed, 18 May 2022 14:46:42 GMT, Alexey Ivanov wrote: > Replaces usages of articles that follow each other in all combinations: > a/the, an?/an?, the/the… > > It's the last issue in the series, and it still touches different areas of > the code. This pull request has

Re: RFR: 8211958: Broken links in java.desktop files

2020-11-02 Thread Alexey Ivanov
On Mon, 2 Nov 2020 09:04:39 GMT, Sergey Bylokhov wrote: > Most of the broken links were fixed already by the JDK-8225368 and JDK-8214817 > This change fix just a few. > > Also two cleanups are applied: > - The `../../java/awt/doc-files/` in some cases simplified to `doc-files/` > - The html li

Re: RFR: 8259522: Apply java.io.Serial annotations in java.desktop

2021-01-12 Thread Alexey Ivanov
On Mon, 11 Jan 2021 06:21:52 GMT, Sergey Bylokhov wrote: > Please review the application of @java.io.Serial annotation (JDK-8202385) to > types in the desktop module to enable stricter compile-time checking of > serialization-related declarations. > > This annotation can be applied to these me

Re: RFR: 8259522: Apply java.io.Serial annotations in java.desktop [v2]

2021-01-12 Thread Alexey Ivanov
On Tue, 12 Jan 2021 20:36:21 GMT, Sergey Bylokhov wrote: >> src/java.desktop/share/classes/com/sun/media/sound/InvalidDataException.java >> line 42: >> >>> 40: */ >>> 41: @Serial >>> 42: private static final long serialVersionUID = 1L; >> >> This is the standard wording, yet shoul

Re: RFR: 8258805: Japanese characters not entered by mouse click on Windows 10

2021-01-19 Thread Alexey Ivanov
On Tue, 19 Jan 2021 11:10:35 GMT, Dmitry Markov wrote: > Fix: > It is necessary to take care of unconfirmed composition string once the IME > is going to be disabled. The fix commits the unconfirmed composition string. Committing is better than discarding. Is it possible to preserve the state

Re: RFR: 8258805: Japanese characters not entered by mouse click on Windows 10

2021-01-20 Thread Alexey Ivanov
On Tue, 19 Jan 2021 13:18:22 GMT, Dmitry Markov wrote: > > The fix commits the unconfirmed composition string. Committing is better > > than discarding. Is it possible to preserve the > > state and to leave the string uncommitted? > > The fix reverts the previous (correct) behaviour back. Acco

Re: RFR: 8258805: Japanese characters not entered by mouse click on Windows 10

2021-01-21 Thread Alexey Ivanov
On Thu, 21 Jan 2021 13:47:30 GMT, Dmitry Markov wrote: > Now we will commit the composition string if there is an active client. That > changes eliminates the issue described in JDK-8258805. Also the behaviour of > AWTTextTest1 is the same as it used to be on the previous versions w/o the > fi

Re: RFR: 8258805: Japanese characters not entered by mouse click on Windows 10

2021-01-21 Thread Alexey Ivanov
On Thu, 21 Jan 2021 14:54:34 GMT, Dmitry Markov wrote: >>> Now we will commit the composition string if there is an active client. >>> That changes eliminates the issue described in JDK-8258805. Also the >>> behaviour of AWTTextTest1 is the same as it used to be on the previous >>> versions w/

Re: RFR: 8258805: Japanese characters not entered by mouse click on Windows 10 [v2]

2021-01-21 Thread Alexey Ivanov
On Thu, 21 Jan 2021 13:51:58 GMT, Dmitry Markov wrote: >> Problem description: >> The IME behaviour has changed starting from recent Windows 10 builds. In >> particular if the complex characters (Japanese, Chinese, etc.) are entered >> to some component and the focus is transferred to another c

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

2021-08-23 Thread Alexey Ivanov
On Mon, 23 Aug 2021 06:35:34 GMT, Сергей Цыпанов wrote: >> src/java.desktop/share/classes/com/sun/imageio/plugins/tiff/TIFFIFD.java >> line 64: >> >>> 62: Set tags = essentialTags; >>> 63: if (tags == null) { >>> 64: essentialTags = Set.of( >> >> What is the purpos

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

2021-08-23 Thread Alexey Ivanov
On Mon, 23 Aug 2021 17:57:52 GMT, Sergey Bylokhov wrote: >> 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. > > I think we can drop it completely. Agree. - PR:

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

2021-10-08 Thread Alexey Ivanov
On Sat, 25 Sep 2021 19:30:31 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

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

2021-10-08 Thread Alexey Ivanov
On Fri, 8 Oct 2021 18:35:53 GMT, Sergey Bylokhov wrote: >> I still suggest to remove the local tag completely. > > @jayathirthrao @stsypanov Looks like this was not addressed? It will be > good to include it in some future cleanup. As far as I can see, it was. [Line 64](https://github.com/st

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

2021-10-08 Thread Alexey Ivanov
On Fri, 8 Oct 2021 19:15:39 GMT, Sergey Bylokhov wrote: >> As far as I can see, it was. [Line >> 64](https://github.com/stsypanov/jdk/blob/d13ca9004b8e45f7df57c849271f3cfda5c43ec9/src/java.desktop/share/classes/com/sun/imageio/plugins/tiff/TIFFIFD.java#L64): >> >> essentialTags = Se

Re: RFR: 8276794: Change nested classes in java.desktop to static nested classes

2021-11-17 Thread Alexey Ivanov
On Thu, 14 Oct 2021 07:47:33 GMT, Andrey Turbanov wrote: > Non-static classes hold a link to their parent classes, which in many cases > can be avoided. > I updated only private and package-private classes. Didn't touch > public/protected to not break external code. > Similar cleanup in java.ba

Re: RFR: 8276794: Change nested classes in java.desktop to static nested classes [v2]

2021-11-17 Thread Alexey Ivanov
On Wed, 17 Nov 2021 19:21:49 GMT, Andrey Turbanov wrote: >> Non-static classes hold a link to their parent classes, which in many cases >> can be avoided. >> I updated only private and package-private classes. Didn't touch >> public/protected to not break external code. >> Similar cleanup in ja

Re: RFR: 8274640: Cleanup unnecessary null comparison before instanceof check in java.desktop

2021-11-27 Thread Alexey Ivanov
On Sat, 11 Sep 2021 14:59:21 GMT, Andrey Turbanov wrote: > Updated code checks both non-null and instance of a class in java.desktop > module classes. > The checks and explicit casts could also be replaced with pattern matching > for the instanceof operator. > Similar cleanups > 1. [JDK-827348

Re: RFR: 8274640: Cleanup unnecessary null comparison before instanceof check in java.desktop [v2]

2021-11-29 Thread Alexey Ivanov
On Mon, 29 Nov 2021 08:00:19 GMT, Andrey Turbanov wrote: >> src/java.desktop/unix/classes/sun/awt/X11/XWindow.java line 312: >> >>> 310: } >>> 311: >>> 312: return window.getContentWindow(); >> >> Is the branch where 0 was returned impossible? > > Yes. It was impossible. > Only

Re: RFR: 8274640: Cleanup unnecessary null comparison before instanceof check in java.desktop [v2]

2021-11-29 Thread Alexey Ivanov
On Mon, 29 Nov 2021 08:17:41 GMT, Andrey Turbanov wrote: >> Updated code checks both non-null and instance of a class in java.desktop >> module classes. >> The checks and explicit casts could also be replaced with pattern matching >> for the instanceof operator. >> Similar cleanups >> 1. [JDK-

Re: RFR: 8274640: Cleanup unnecessary null comparison before instanceof check in java.desktop [v2]

2021-11-29 Thread Alexey Ivanov
On Mon, 29 Nov 2021 08:01:56 GMT, Andrey Turbanov wrote: >> src/java.desktop/macosx/classes/com/apple/laf/AquaRootPaneUI.java line 78: >> >>> 76: final Component parent = c.getParent(); >>> 77: >>> 78: if (parent instanceof JFrame frameParent) { >> >> The `frameParent` variable

Re: RFR: 8277868: Use Comparable.compare() instead of surrogate code [v2]

2021-12-07 Thread Alexey Ivanov
On Tue, 7 Dec 2021 08:16:08 GMT, Сергей Цыпанов wrote: >> src/java.desktop/share/classes/java/awt/geom/Line2D.java line 115: >> >>> 113: */ >>> 114: public double getX1() { >>> 115: return x1; >> >> What do these changes have to do with the subject of the PR ? > > J

Re: RFR: 8277868: Use Comparable.compare() instead of surrogate code [v3]

2021-12-07 Thread Alexey Ivanov
On Tue, 7 Dec 2021 08:28:47 GMT, Сергей Цыпанов wrote: >> Instead of something like >> >> long x; >> long y; >> return (x < y) ? -1 : ((x == y) ? 0 : 1); >> >> we can use `return Long.compare(x, y);` >> >> All replacements are done with IDE. > > Сергей Цыпанов has updated the pull request incr

Re: RFR: 8278254: Cleanup doclint warnings in java.desktop module [v2]

2022-01-18 Thread Alexey Ivanov
On Mon, 17 Jan 2022 05:31:00 GMT, Prasanta Sadhukhan wrote: >> The changes done under JDK-8278175 suppress on a per-file basis various >> missing comments that would otherwise trigger doclint warnings. Fixed them >> so as to remove the doclint:missing warnings. > > Prasanta Sadhukhan has updat

Re: RFR: 8278254: Cleanup doclint warnings in java.desktop module [v2]

2022-01-18 Thread Alexey Ivanov
On Mon, 17 Jan 2022 05:26:47 GMT, Prasanta Sadhukhan wrote: >> src/java.desktop/share/classes/javax/swing/undo/UndoableEditSupport.java >> line 150: >> >>> 148: >>> 149: /** >>> 150: * Start UndoableEdit. >> >> What does it mean? Is it clear enough for the class which "managing >>

Re: RFR: 8278254: Cleanup doclint warnings in java.desktop module [v2]

2022-01-19 Thread Alexey Ivanov
On Tue, 18 Jan 2022 16:30:07 GMT, Alexey Ivanov wrote: >> Prasanta Sadhukhan has updated the pull request incrementally with one >> additional commit since the last revision: >> >> review fix > > src/java.desktop/share/classes/javax/swing/JScrollBar.java line

Re: RFR: 8278254: Cleanup doclint warnings in java.desktop module [v4]

2022-01-20 Thread Alexey Ivanov
On Thu, 20 Jan 2022 15:11:37 GMT, Alexey Ivanov wrote: > Shall we indent `serialVersionUID`? It's for `BCSChild` but its indentation > suggests it's for the surrounding class. It's right below the class declaration. - PR: https://git.openjdk.java.net/jdk/pull/7004

Re: RFR: 8278254: Cleanup doclint warnings in java.desktop module [v4]

2022-01-20 Thread Alexey Ivanov
On Thu, 20 Jan 2022 06:12:29 GMT, Prasanta Sadhukhan wrote: >> The changes done under JDK-8278175 suppress on a per-file basis various >> missing comments that would otherwise trigger doclint warnings. Fixed them >> so as to remove the doclint:missing warnings. > > Prasanta Sadhukhan has updat

Re: RFR: 8278254: Cleanup doclint warnings in java.desktop module [v4]

2022-01-24 Thread Alexey Ivanov
On Mon, 24 Jan 2022 06:00:02 GMT, Prasanta Sadhukhan wrote: >> src/java.desktop/share/classes/javax/swing/filechooser/FileSystemView.java >> line 353: >> >>> 351: * File(parent, fileName) except when the parent and child >>> are both >>> 352: * special folders, in which case the Fil

Re: RFR: 8278254: Cleanup doclint warnings in java.desktop module [v4]

2022-01-24 Thread Alexey Ivanov
On Mon, 24 Jan 2022 11:28:06 GMT, Prasanta Sadhukhan wrote: >> If `ShellFolder` remains mentioned, I'd rather use >> `ShellFolder` as it was done originally. >> >> I guess Sergey challenged the fact of referencing `ShellFolder`. The fact >> that it could be `ShellFolder` rather than `File` is

Re: RFR: 8278254: Cleanup doclint warnings in java.desktop module [v4]

2022-01-24 Thread Alexey Ivanov
On Mon, 24 Jan 2022 11:34:04 GMT, Alexey Ivanov wrote: >> Since it is mentioned in other places, I would rather not scrap it. Also, >> since in most places it is mentioned as a non-link value, I chose to modify >> it. > > The `` element does not create a link, it uses

Re: RFR: JDK-8280492: Use cross-module syntax for cross-module links

2022-01-24 Thread Alexey Ivanov
On Sat, 22 Jan 2022 21:09:03 GMT, Joe Darcy wrote: > Use presumed syntax that will be introduced by JDK-8280488. Marked as reviewed by aivanov (Reviewer). - PR: https://git.openjdk.java.net/jdk/pull/7189

Re: RFR: 8278254: Cleanup doclint warnings in java.desktop module [v5]

2022-01-24 Thread Alexey Ivanov
On Mon, 24 Jan 2022 06:03:42 GMT, Prasanta Sadhukhan wrote: >> The changes done under JDK-8278175 suppress on a per-file basis various >> missing comments that would otherwise trigger doclint warnings. Fixed them >> so as to remove the doclint:missing warnings. > > Prasanta Sadhukhan has updat

Re: RFR: 8278254: Cleanup doclint warnings in java.desktop module [v5]

2022-01-28 Thread Alexey Ivanov
On Mon, 24 Jan 2022 06:03:42 GMT, Prasanta Sadhukhan wrote: >> The changes done under JDK-8278175 suppress on a per-file basis various >> missing comments that would otherwise trigger doclint warnings. Fixed them >> so as to remove the doclint:missing warnings. > > Prasanta Sadhukhan has updat

Re: RFR: 8278254: Cleanup doclint warnings in java.desktop module [v7]

2022-02-01 Thread Alexey Ivanov
On Tue, 1 Feb 2022 09:40:10 GMT, Prasanta Sadhukhan wrote: >> The changes done under JDK-8278175 suppress on a per-file basis various >> missing comments that would otherwise trigger doclint warnings. Fixed them >> so as to remove the doclint:missing warnings. > > Prasanta Sadhukhan has update