root / import / ext3D / trunk / install-extension3d / IzPack / src / lib / com / izforge / izpack / panels / PacksPanel.java @ 15280
History | View | Annotate | Download (2.97 KB)
1 |
/*
|
---|---|
2 |
* $Id: PacksPanel.java,v 1.1 2006/06/14 07:29:07 cesar Exp $
|
3 |
* IzPack
|
4 |
* Copyright (C) 2001-2004 Julien Ponge
|
5 |
*
|
6 |
* File : PacksPanel.java
|
7 |
* Description : A panel to select the packs to install.
|
8 |
* Author's email : julien@izforge.com
|
9 |
* Author's Website : http://www.izforge.com
|
10 |
*
|
11 |
* Portions are Copyright (C) 2002 Marcus Wolschon
|
12 |
* Portions are Copyright (C) 2002 Jan Blok (jblok@profdata.nl - PDM - www.profdata.nl)
|
13 |
*
|
14 |
* This program is free software; you can redistribute it and/or
|
15 |
* modify it under the terms of the GNU General Public License
|
16 |
* as published by the Free Software Foundation; either version 2
|
17 |
* of the License, or any later version.
|
18 |
*
|
19 |
* This program is distributed in the hope that it will be useful,
|
20 |
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
21 |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
22 |
* GNU General Public License for more details.
|
23 |
*
|
24 |
* You should have received a copy of the GNU General Public License
|
25 |
* along with this program; if not, write to the Free Software
|
26 |
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
27 |
*/
|
28 |
package com.izforge.izpack.panels; |
29 |
|
30 |
import java.awt.Dimension; |
31 |
|
32 |
import javax.swing.Box; |
33 |
import javax.swing.BoxLayout; |
34 |
import javax.swing.JScrollPane; |
35 |
|
36 |
import com.izforge.izpack.installer.InstallData; |
37 |
import com.izforge.izpack.installer.InstallerFrame; |
38 |
import com.izforge.izpack.util.IoHelper; |
39 |
|
40 |
/**
|
41 |
* The packs selection panel class.
|
42 |
* This class handles only the layout. Common
|
43 |
* stuff are handled by the base class.
|
44 |
*
|
45 |
* @author Julien Ponge
|
46 |
* @author Jan Blok
|
47 |
* @author Klaus Bartz
|
48 |
*/
|
49 |
public class PacksPanel extends PacksPanelBase |
50 |
{ |
51 |
|
52 |
/**
|
53 |
* The constructor.
|
54 |
*
|
55 |
* @param parent The parent window.
|
56 |
* @param idata The installation data.
|
57 |
*/
|
58 |
public PacksPanel(InstallerFrame parent, InstallData idata)
|
59 |
{ |
60 |
super(parent, idata);
|
61 |
} |
62 |
|
63 |
/* (non-Javadoc)
|
64 |
* @see com.izforge.izpack.panels.PacksPanelBase#createNormalLayout()
|
65 |
*/
|
66 |
protected void createNormalLayout() |
67 |
{ |
68 |
setLayout(new BoxLayout(this, BoxLayout.Y_AXIS)); |
69 |
createLabel( "PacksPanel.info", "preferences", null, null); |
70 |
add(Box.createRigidArea(new Dimension(0, 3))); |
71 |
createLabel( "PacksPanel.tip", "tip", null, null); |
72 |
add(Box.createRigidArea(new Dimension(0, 5))); |
73 |
tableScroller = new JScrollPane(); |
74 |
packsTable = createPacksTable(300, tableScroller, null, null ); |
75 |
if( dependenciesExist )
|
76 |
dependencyArea = createTextArea("PacksPanel.dependencyList", null, null, null ); |
77 |
descriptionArea = createTextArea("PacksPanel.description", null, null, null ); |
78 |
spaceLabel = createPanelWithLabel( "PacksPanel.space", null, null ); |
79 |
if( IoHelper.supported("getFreeSpace")) |
80 |
{ |
81 |
add(Box.createRigidArea(new Dimension(0, 3))); |
82 |
freeSpaceLabel = createPanelWithLabel( "PacksPanel.freespace", null, null ); |
83 |
} |
84 |
} |
85 |
|
86 |
} |