3
// Copyright (C) 2008 [name of author]
5
// This program is free software; you can redistribute it and/or modify
6
// it under the terms of the GNU General Public License as published by
7
// the Free Software Foundation; either version 2 of the License, or
8
// (at your option) any later version.
10
// This program is distributed in the hope that it will be useful,
11
// but WITHOUT ANY WARRANTY; without even the implied warranty of
12
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13
// GNU General Public License for more details.
15
// You should have received a copy of the GNU General Public License
16
// along with this program; if not, write to the Free Software
17
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
25
public class ArchiveTypeItem : IItem
27
private string archiveName;
28
private string archiveDescription;
29
private int archiveId;
30
private string archiveIcon;
32
public ArchiveTypeItem (Archive.ArchiveType archiveType)
34
this.archiveId = (int)archiveType;
37
case (int)Archive.ArchiveType.GZIP:
38
this.archiveName = "Tar.gz";
39
this.archiveDescription = "Tar compressed with GZIP (.tar.gz)";
40
this.archiveIcon = "tgz";
42
case (int)Archive.ArchiveType.BZIP2:
43
this.archiveName = "Tar.bz2";
44
this.archiveDescription = "Tar compressed with BZIP2 (.tar.bz2)";
45
this.archiveIcon = "tar";
47
case (int)Archive.ArchiveType.TAR:
48
this.archiveName = "Tar";
49
this.archiveDescription = "Tar uncompressed (.tar)";
50
this.archiveIcon = "tar";
52
case (int)Archive.ArchiveType.ZIP:
53
this.archiveName = ".zip";
54
this.archiveDescription = "Zip (.zip)";
55
this.archiveIcon = "zip";
58
this.archiveName = ".tar.gz";
59
this.archiveDescription = "Tar compressed with GZIP (.tar.gz)";
60
this.archiveIcon = "tgz";
65
public int ArchiveType {
66
get { return archiveId; }
70
get { return archiveName; }
73
public string Description {
74
get { return archiveDescription; }
78
get { return archiveIcon; }