aboutsummaryrefslogtreecommitdiff
path: root/JBriscola/all_versions/0.3/0.3.2/src/PannelloCartePassate.java
blob: fef96663956009a4662225223ae465081d022053 (plain)
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
37
38
39
40
41
42
43
44
45
46
47
48
49
/*
Copyright 2009-2010 Sebastiano Tronto <sebastiano@luganega.org>

This file is part of JBriscola.

    JBriscola is free software; you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
    the Free Software Foundation; either version 2 of the License, or
    (at your option) any later version.

    JBriscola is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU General Public License for more details.

    You should have received a copy of the GNU General Public License
    along with JBriscola; if not, write to the Free Software
    Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA

*/

import javax.swing.*;
import java.awt.*;

public class PannelloCartePassate extends JPanel {

	public static int posto[][] = new int[40][2];
	
	public static Main main;
	
	public PannelloCartePassate() {	}
	
	public void paint( Graphics g ) {

		super.paint( g );

		for( int i = 0; i < 40; i++ ) {
			posto[i][0] = ( i % 10 ) * 70;
			posto[i][1] = ( i / 10 ) * 136;
		}

		for ( int i = 0; i < main.mano*2; i++ )
			if ( main.frame.arrayCartePassate[i] != null )
				main.frame.arrayCartePassate[i].paintIcon( this, g, posto[i][0], posto[i][1] );


	}

}

Generated with cgit - Back to sebastiano.tronto.net