-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathSplash.java
More file actions
36 lines (27 loc) · 847 Bytes
/
Splash.java
File metadata and controls
36 lines (27 loc) · 847 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
package employee.management.stystem;
import javax.swing.*;
import java.awt.*;
public class Splash extends JFrame {
Splash(){
ImageIcon i1 = new ImageIcon(ClassLoader.getSystemResource("icons/front.gif"));
Image i2 = i1.getImage().getScaledInstance(1170,650, Image.SCALE_DEFAULT);
ImageIcon i3 = new ImageIcon(i2);
JLabel image = new JLabel(i3);
image.setBounds(0,0,1170,650);
add(image);
setSize(1170,650);
setLocation(200,50);
setLayout(null);
setVisible(true);
try{
Thread.sleep(5000);
setVisible(false);
new Login();
}catch (Exception e){
e.printStackTrace();
}
}
public static void main(String[] args) {
new Splash();
}
}