|
@ -0,0 +1,34 @@ |
|
|
|
|
|
package solitaer; |
|
|
|
|
|
|
|
|
|
|
|
import java.awt.Graphics; |
|
|
|
|
|
import java.awt.Image; |
|
|
|
|
|
import java.util.ArrayList; |
|
|
|
|
|
|
|
|
|
|
|
import javax.swing.ImageIcon; |
|
|
|
|
|
import javax.swing.JPanel; |
|
|
|
|
|
|
|
|
|
|
|
public class StartStack extends JPanel { |
|
|
|
|
|
|
|
|
|
|
|
private static final long serialVersionUID = 1L; |
|
|
|
|
|
private Image im; |
|
|
|
|
|
private ArrayList<Card> Stack = new ArrayList<Card>(); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public StartStack(int _x, int _y) { |
|
|
|
|
|
super.setLocation(_x, _y); |
|
|
|
|
|
super.setSize(72,450); |
|
|
|
|
|
super.setOpaque(false); |
|
|
|
|
|
super.setLayout(null); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
@Override |
|
|
|
|
|
protected void paintComponent(Graphics g) { |
|
|
|
|
|
// TODO Auto-generated method stub |
|
|
|
|
|
super.paintComponent(g); |
|
|
|
|
|
ImageIcon ii = new ImageIcon(getClass().getResource("images/back.png")); |
|
|
|
|
|
im = ii.getImage(); |
|
|
|
|
|
g.drawImage(im, 0, 0, this.getWidth(), 96, this); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
} |