4 import com
.easysw
.cups
.*;
8 // Current selected server name or address.
9 public static String cupsServerName
= null;
11 // Current selected printer name.
12 public static String selectedPrinterName
= null;
14 // Current user name and password.
15 public static String cupsUser
= "root";
16 public static String cupsPasswd
= "Frak998";
18 // So we can access the tabs from other classes.
19 public static JTabbedPane mainGLPPanel
= null;
20 public static GLPtabs tabs
= null;
22 // List of servers found using search.
23 protected static List serverList
= null;
25 // So we can update the search results from the search classes.
26 public static GLPjobTableModel searchTM
= null;
27 public static JTable searchTable
= null;
29 // What kind of jobs to list.
30 public static boolean showMyJobs
= false;
31 public static boolean showCompletedJobs
= false;
36 cupsServerName
= "localhost";
37 serverList
= new ArrayList();
40 public static void init()
42 cupsServerName
= "localhost";
43 serverList
= new ArrayList();
47 public static String
getServerName()
49 return(cupsServerName
);
52 public static void setServerName( String name
)
54 cupsServerName
= name
;
59 // Reset the server list.
61 public static void clearServerList()
68 // Add a cups server to the server list.
70 public static void addToServerList( String serverName
)
72 if (serverList
!= null)
73 serverList
.add(serverName
);
77 // Get the full server list (if any).
79 public static String
[] getServerList()
81 if (serverList
!= null)
83 String
[] servers
= new String
[serverList
.size()];
84 for (int i
=0; i
< serverList
.size(); i
++)
85 servers
[i
] = (String
)serverList
.get(i
);