我为主要课程设置了以下外观。
基类代码:
static
{
try
{
UIManager.setLookAndFeel("com.sun.java.swing.plaf.windows.WindowsLookAndFeel");
}
catch (Exception exception)
{
logger.error("Error setting look and feel!", exception);
}
}
子类代码:
int result = JOptionPane.showOptionDialog(panel,
message,
"",
JOptionPane.YES_NO_CANCEL_OPTION,
JOptionPane.QUESTION_MESSAGE,
null,
formattedOptions,
formattedOptions[0]);
窗口外观没有设置为 JOptionPane 的窗口,而是显示 java 默认外观。
你能帮帮我吗?