Added new improvements
This commit is contained in:
parent
960fdaa593
commit
c260044cb4
@ -11,6 +11,12 @@ import java.awt.HeadlessException;
|
||||
public class TimeCalcWindow extends JFrame {
|
||||
public TimeCalcWindow() throws HeadlessException {
|
||||
setFocusable(true);
|
||||
addWindowListener(new java.awt.event.WindowAdapter() {
|
||||
@Override
|
||||
public void windowClosing(java.awt.event.WindowEvent e) {
|
||||
System.exit(0);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
public Component[] addAll(Component... comp) {
|
||||
|
@ -135,7 +135,7 @@ public class TimeCalcManager {
|
||||
}
|
||||
});
|
||||
JTextPane text = new JTextPane();
|
||||
text.setBounds(10, 10 + 210 + 10, 500, 250);
|
||||
text.setBounds(MARGIN, MARGIN + 210 + MARGIN, 500, 250);
|
||||
text.setFont(new Font(Font.MONOSPACED, Font.PLAIN, 12));
|
||||
text.setForeground(Color.GRAY);
|
||||
text.setBackground(new Color(238, 238, 238));
|
||||
@ -192,12 +192,6 @@ public class TimeCalcManager {
|
||||
window.setTitle(windowTitle);
|
||||
window.setDefaultCloseOperation(JFrame.DO_NOTHING_ON_CLOSE);
|
||||
|
||||
window.addWindowListener(new java.awt.event.WindowAdapter() {
|
||||
@Override
|
||||
public void windowClosing(java.awt.event.WindowEvent e) {
|
||||
System.exit(0);
|
||||
}
|
||||
});
|
||||
weatherButton
|
||||
.addActionListener(e -> new WeatherWindow().setVisible(true));
|
||||
commandButton
|
||||
|
Loading…
x
Reference in New Issue
Block a user