Details
-
Type:
Bug
-
Status: Closed
-
Priority:
P2
-
Resolution: Fixed
-
Affects Version/s: 7
-
Fix Version/s: 7
-
Component/s: client-libs
-
Labels:
-
Subcomponent:
-
Resolved In Build:b114
-
CPU:generic
-
OS:linux
-
Verification:Verified
Description
Testcase
api/javax_swing/JDesktopPane/descriptions.html#getset[JDesktopPane2002]
fails on
Platforms: Linux, Solaris
JDK: 6, 7
L&F: -Dswing.defaultlaf=com.sun.java.swing.plaf.gtk.GTKLookAndFeel
Methods JDesktopPane.setDesktopManager/getDesktopManager are not consistent under GTK L&F
Please see the following code sample:
-----------------------------------------------------------------------------------------
import javax.swing.*;
public class TestJDPane {
public static void main(String[] args) {
JDesktopPane desktopPane = new JDesktopPane();
DesktopManager installed = new DefaultDesktopManager();
desktopPane.setDesktopManager(installed);
DesktopManager returned = desktopPane.getDesktopManager();
if (!returned.equals(installed)) {
System.out.println("installed = " + installed);
System.out.println("returned = " + returned);
}
}
}
-----------------------------------------------------------------------------------------
with -Dswing.defaultlaf=com.sun.java.swing.plaf.gtk.GTKLookAndFeel
the output will be like the following
installed = javax.swing.DefaultDesktopManager@82764b
returned = javax.swing.plaf.synth.SynthDesktopPaneUI$SynthDesktopManager@12452e8
api/javax_swing/JDesktopPane/descriptions.html#getset[JDesktopPane2002]
fails on
Platforms: Linux, Solaris
JDK: 6, 7
L&F: -Dswing.defaultlaf=com.sun.java.swing.plaf.gtk.GTKLookAndFeel
Methods JDesktopPane.setDesktopManager/getDesktopManager are not consistent under GTK L&F
Please see the following code sample:
-----------------------------------------------------------------------------------------
import javax.swing.*;
public class TestJDPane {
public static void main(String[] args) {
JDesktopPane desktopPane = new JDesktopPane();
DesktopManager installed = new DefaultDesktopManager();
desktopPane.setDesktopManager(installed);
DesktopManager returned = desktopPane.getDesktopManager();
if (!returned.equals(installed)) {
System.out.println("installed = " + installed);
System.out.println("returned = " + returned);
}
}
}
-----------------------------------------------------------------------------------------
with -Dswing.defaultlaf=com.sun.java.swing.plaf.gtk.GTKLookAndFeel
the output will be like the following
installed = javax.swing.DefaultDesktopManager@82764b
returned = javax.swing.plaf.synth.SynthDesktopPaneUI$SynthDesktopManager@12452e8