Hello. I would like to contribute a small patch for bug: https://bugs.openjdk.java.net/browse/JDK-6573239
Index: src/demo/share/jfc/SwingSet2/resources/tree.txt IDEA additional info: Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP <+>UTF-8 =================================================================== --- src/demo/share/jfc/SwingSet2/resources/tree.txt (revision dab3f5ab5c94975769e34b8139fe892a86085635) +++ src/demo/share/jfc/SwingSet2/resources/tree.txt (date 1560450025564) @@ -8,7 +8,7 @@ # A = Artist / Composer # # R = Record / Style # # S = Song Name / Composition # -# C = Catagory # +# C = Category # # # ################################################################################ C Classical Index: test/jdk/sanity/client/lib/SwingSet3/src/com/sun/swingset3/demos/tree/resources/tree.txt IDEA additional info: Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP <+>UTF-8 =================================================================== --- test/jdk/sanity/client/lib/SwingSet3/src/com/sun/swingset3/demos/tree/resources/tree.txt (revision dab3f5ab5c94975769e34b8139fe892a86085635) +++ test/jdk/sanity/client/lib/SwingSet3/src/com/sun/swingset3/demos/tree/resources/tree.txt (date 1560450025589) @@ -8,7 +8,7 @@ # A = Artist / Composer # # R = Record / Style # # S = Song Name / Composition # -# C = Catagory # +# C = Category # # # ################################################################################ C Classical Index: test/jdk/sanity/client/lib/SwingSet3/src/com/sun/swingset3/demos/tree/TreeDemo.java IDEA additional info: Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP <+>UTF-8 =================================================================== --- test/jdk/sanity/client/lib/SwingSet3/src/com/sun/swingset3/demos/tree/TreeDemo.java (revision dab3f5ab5c94975769e34b8139fe892a86085635) +++ test/jdk/sanity/client/lib/SwingSet3/src/com/sun/swingset3/demos/tree/TreeDemo.java (date 1560450025588) @@ -1,5 +1,5 @@ /* - * Copyright (c) 2007, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2007, 2019, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -83,7 +83,7 @@ private JTree createTree() { DefaultMutableTreeNode top = new DefaultMutableTreeNode(resourceManager.getString("TreeDemo.music")); - DefaultMutableTreeNode catagory = null; + DefaultMutableTreeNode category = null; DefaultMutableTreeNode artist = null; DefaultMutableTreeNode record = null; @@ -103,12 +103,12 @@ char linetype = line.charAt(0); switch (linetype) { case 'C': - catagory = new DefaultMutableTreeNode(line.substring(2)); - top.add(catagory); + category = new DefaultMutableTreeNode(line.substring(2)); + top.add(category); break; case 'A': - if (catagory != null) { - catagory.add(artist = new DefaultMutableTreeNode(line.substring(2))); + if (category != null) { + category.add(artist = new DefaultMutableTreeNode(line.substring(2))); } break; case 'R': Index: src/demo/share/jfc/SwingSet2/TreeDemo.java IDEA additional info: Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP <+>UTF-8 =================================================================== --- src/demo/share/jfc/SwingSet2/TreeDemo.java (revision dab3f5ab5c94975769e34b8139fe892a86085635) +++ src/demo/share/jfc/SwingSet2/TreeDemo.java (date 1560450025563) @@ -1,6 +1,6 @@ /* * - * Copyright (c) 2007, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2007, 2019 Oracle and/or its affiliates. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -74,7 +74,7 @@ public JScrollPane createTree() { DefaultMutableTreeNode top = new DefaultMutableTreeNode(getString("TreeDemo.music")); - DefaultMutableTreeNode catagory = null ; + DefaultMutableTreeNode category = null; DefaultMutableTreeNode artist = null; DefaultMutableTreeNode record = null; @@ -94,12 +94,12 @@ char linetype = line.charAt(0); switch(linetype) { case 'C': - catagory = new DefaultMutableTreeNode(line.substring(2)); - top.add(catagory); + category = new DefaultMutableTreeNode(line.substring(2)); + top.add(category); break; case 'A': - if(catagory != null) { - catagory.add(artist = new DefaultMutableTreeNode(line.substring(2))); + if(category != null) { + category.add(artist = new DefaultMutableTreeNode(line.substring(2))); } break; case 'R': Andrey Turbanov