Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public class pladenPanel extends JPanel implements MouseAdapter {
- JPanel Pladen = new JPanel(new GridLayout(10,10));
- public void lavPladen() {
- for(int i=0; i<10; i++) {
- for(int y=0; y<10; y++) {
- int placering = y+i;
- Pladen.add(new JButton().putClientProperty(placering , Point(y,i)));
- }
- }
- addMouseAdapter(this);
- }
- }
- public void mouseClicked(MouseEvent e) {
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement