Line | Hits | Source |
---|---|---|
1 | /******************************************************************************* | |
2 | * InternetCafe is a software solution that helps the management of Cybercafes | |
3 | * according with the ITALIAN DECREE LAW ON ANTI-TERROR MEASURES, 27 JULY 2005. | |
4 | * Copyright (C) 2006 Guido Angelo Ingenito | |
5 | ||
6 | * This program is free software; you can redistribute it and/or | |
7 | * modify it under the terms of the GNU General Public License | |
8 | * as published by the Free Software Foundation; either version 2 | |
9 | * of the License, or (at your option) any later version. | |
10 | ||
11 | * This program is distributed in the hope that it will be useful, | |
12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | |
13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
14 | * GNU General Public License for more details. | |
15 | * | |
16 | * You should have received a copy of the GNU General Public License | |
17 | * along with this program; if not, write to the Free Software | |
18 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. | |
19 | *******************************************************************************/ | |
20 | package ui.panel; | |
21 | ||
22 | import java.awt.BorderLayout; | |
23 | ||
24 | import javax.swing.ImageIcon; | |
25 | import javax.swing.JPanel; | |
26 | import javax.swing.JTabbedPane; | |
27 | ||
28 | import ui.Messages; | |
29 | ||
30 | @SuppressWarnings("serial") //$NON-NLS-1$ | |
31 | public class ICNetworkPanel extends JPanel { | |
32 | ||
33 | private JTabbedPane tabbedPanel; | |
34 | ||
35 | private JPanel clientPanel; | |
36 | ||
37 | 0 | private JPanel serverPanel; |
38 | 0 | |
39 | 0 | public ICNetworkPanel() { |
40 | 0 | initialize(); |
41 | 0 | } |
42 | 0 | |
43 | 0 | protected void initialize() { |
44 | 0 | this.setName(Messages.getString("common.network")); //$NON-NLS-1$ |
45 | 0 | this.setLayout(new BorderLayout()); |
46 | 0 | this.add(getTabbedPanel(), BorderLayout.CENTER); |
47 | 0 | } |
48 | ||
49 | /** | |
50 | * @return Returns the clientPanel. | |
51 | 0 | */ |
52 | 0 | protected JPanel getClientPanel() { |
53 | 0 | if (clientPanel == null) { |
54 | 0 | clientPanel = new TabledClientWorkstationPanel(); |
55 | } | |
56 | 0 | return clientPanel; |
57 | } | |
58 | ||
59 | /** | |
60 | * @return Returns the serverPanel. | |
61 | 0 | */ |
62 | 0 | protected JPanel getServerPanel() { |
63 | 0 | if (serverPanel == null) { |
64 | 0 | serverPanel = new TabledServerWorkstationPanel(); |
65 | } | |
66 | 0 | return serverPanel; |
67 | } | |
68 | ||
69 | /** | |
70 | * @return Returns the tabbedPanel. | |
71 | 0 | */ |
72 | 0 | protected JTabbedPane getTabbedPanel() { |
73 | 0 | if (tabbedPanel == null) { |
74 | 0 | tabbedPanel = new JTabbedPane(); |
75 | 0 | tabbedPanel.addTab(Messages.getString("common.clientworkstations"), //$NON-NLS-1$ |
76 | 0 | new ImageIcon(this.getClass().getResource( |
77 | 0 | "/icon/16x16/devices/computer.png")), //$NON-NLS-1$ |
78 | 0 | getClientPanel(), Messages.getString("panel.icnetworkpanel.manageclientworkstations")); //$NON-NLS-1$ |
79 | 0 | tabbedPanel.addTab(Messages.getString("common.serverworkstations"), new ImageIcon(this //$NON-NLS-1$ |
80 | 0 | .getClass().getResource( |
81 | 0 | "/icon/16x16/places/network-server.png")), //$NON-NLS-1$ |
82 | 0 | getServerPanel(), Messages.getString("panel.icnetworkpanel.manageserverworkstations")); //$NON-NLS-1$ |
83 | } | |
84 | 0 | return tabbedPanel; |
85 | } | |
86 | } |
this report was generated by version 1.0.5 of jcoverage. |
copyright © 2003, jcoverage ltd. all rights reserved. |