-
Bug
-
Resolution: Not an Issue
-
P3
-
8, 9, 10
-
x86
-
linux
FULL PRODUCT VERSION :
$ java -version
java version "1.8.0_161"
Java(TM) SE Runtime Environment (build 1.8.0_161-b12)
Java HotSpot(TM) 64-Bit Server VM (build 25.161-b12, mixed mode)
$
ADDITIONAL OS VERSION INFORMATION :
$ uname -a
Linux vxbox-lnx 3.10.0-693.11.1.el7.x86_64 #1 SMP Mon Dec 4 23:52:40 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux
$
EXTRA RELEVANT SYSTEM CONFIGURATION :
I'm testing my app on VirtualBox.
A DESCRIPTION OF THE PROBLEM :
was testing JColorChooser in my Java application using macOS, Windows and Linux (CentOS 7).
In CentOS the Minimize, Maximize and Close Buttons are shown, in macOS only Maximize and Close Buttons, finally in Windows only Close Button.
The problem was when I pressed Minimize button on CentOS and I need to kill my application.
In my opinion that button should not be shown, because when you press the application it locks and does not allow you to operate anymore.
it is only happens in CentOS?
Is this considered bug?
For me it is a bad implementation of JColorChooser and JFileChooser or its parents class JDialog in Linux.
Here link with question: https://stackoverflow.com/questions/49205083/linux-centos-7-jdialog-jcolorchooser-jfilechooser-showing-minimize-button
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
Create an application with JDialog (JFileChooser or JColorChooser) open it and look in CentOS 7, verify the behaviour in Windows and macOS.
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
In windows and macOS, the minimize button is not shown, in Linux this button must be disabled or hidden.
ACTUAL -
The Minimize button is shown and Enabled on JDialog. (JColorChooser)
REPRODUCIBILITY :
This bug can be reproduced always.
---------- BEGIN SOURCE ----------
import javax.swing.*;
import java.awt.*;
import java.awt.event.*;
public class JDialogMinimizeButtonLinux extends JFrame {
public JDialogMinimizeButtonLinux() {
JButton button = new JButton("JDialog showing Minimize Button On Linux");
button.addActionListener(new ActionListener() {
@Override public void actionPerformed( ActionEvent evt) {
new JColorChooser().showDialog(
JDialogMinimizeButtonLinux.this,
"Minimize Button Locks this Example on Linux", Color.gray);
}
});
JPanel outer = new JPanel();
outer.setLayout(new BoxLayout(outer, BoxLayout.LINE_AXIS));
outer.add(button);
add(outer);
setSize(600, 300);
setVisible(true);
}
public static void main( String args[] ) {
try {
UIManager.setLookAndFeel("javax.swing.plaf.nimbus.NimbusLookAndFeel");
} catch (ClassNotFoundException | InstantiationException |
IllegalAccessException | UnsupportedLookAndFeelException ex) {
System.out.println("ex:" + ex.toString());
}
JDialogMinimizeButtonLinux app = new JDialogMinimizeButtonLinux();
app.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);
}
}
---------- END SOURCE ----------
CUSTOMER SUBMITTED WORKAROUND :
I haven't.
$ java -version
java version "1.8.0_161"
Java(TM) SE Runtime Environment (build 1.8.0_161-b12)
Java HotSpot(TM) 64-Bit Server VM (build 25.161-b12, mixed mode)
$
ADDITIONAL OS VERSION INFORMATION :
$ uname -a
Linux vxbox-lnx 3.10.0-693.11.1.el7.x86_64 #1 SMP Mon Dec 4 23:52:40 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux
$
EXTRA RELEVANT SYSTEM CONFIGURATION :
I'm testing my app on VirtualBox.
A DESCRIPTION OF THE PROBLEM :
was testing JColorChooser in my Java application using macOS, Windows and Linux (CentOS 7).
In CentOS the Minimize, Maximize and Close Buttons are shown, in macOS only Maximize and Close Buttons, finally in Windows only Close Button.
The problem was when I pressed Minimize button on CentOS and I need to kill my application.
In my opinion that button should not be shown, because when you press the application it locks and does not allow you to operate anymore.
it is only happens in CentOS?
Is this considered bug?
For me it is a bad implementation of JColorChooser and JFileChooser or its parents class JDialog in Linux.
Here link with question: https://stackoverflow.com/questions/49205083/linux-centos-7-jdialog-jcolorchooser-jfilechooser-showing-minimize-button
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
Create an application with JDialog (JFileChooser or JColorChooser) open it and look in CentOS 7, verify the behaviour in Windows and macOS.
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
In windows and macOS, the minimize button is not shown, in Linux this button must be disabled or hidden.
ACTUAL -
The Minimize button is shown and Enabled on JDialog. (JColorChooser)
REPRODUCIBILITY :
This bug can be reproduced always.
---------- BEGIN SOURCE ----------
import javax.swing.*;
import java.awt.*;
import java.awt.event.*;
public class JDialogMinimizeButtonLinux extends JFrame {
public JDialogMinimizeButtonLinux() {
JButton button = new JButton("JDialog showing Minimize Button On Linux");
button.addActionListener(new ActionListener() {
@Override public void actionPerformed( ActionEvent evt) {
new JColorChooser().showDialog(
JDialogMinimizeButtonLinux.this,
"Minimize Button Locks this Example on Linux", Color.gray);
}
});
JPanel outer = new JPanel();
outer.setLayout(new BoxLayout(outer, BoxLayout.LINE_AXIS));
outer.add(button);
add(outer);
setSize(600, 300);
setVisible(true);
}
public static void main( String args[] ) {
try {
UIManager.setLookAndFeel("javax.swing.plaf.nimbus.NimbusLookAndFeel");
} catch (ClassNotFoundException | InstantiationException |
IllegalAccessException | UnsupportedLookAndFeelException ex) {
System.out.println("ex:" + ex.toString());
}
JDialogMinimizeButtonLinux app = new JDialogMinimizeButtonLinux();
app.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);
}
}
---------- END SOURCE ----------
CUSTOMER SUBMITTED WORKAROUND :
I haven't.