blob: a2fa477e71dc065176fa9553cafaeb4ce299cc7c (
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
50
|
//
//
// C++ Interface: $MODULE$
//
// Description:
//
//
// Author: Gav Wood <gav@kde.org>, (C) 2003
//
// Copyright: See COPYING file that comes with this distribution
//
//
#ifndef MODE_H
#define MODE_H
#include <tqstring.h>
#include "remoteserver.h"
/**
@author Gav Wood
*/
class KConfig;
class Mode
{
TQString theName, theRemote, theIconFile;
public:
void setName(const TQString &a) { theName = a; }
void setRemote(const TQString &a) { theRemote = a; }
void setIconFile(const TQString &a) { theIconFile = a; }
const TQString &name() const { return theName; }
const TQString &remote() const { return theRemote; }
const TQString &iconFile() const { return theIconFile; }
const TQString &remoteName() const { return RemoteServer::remoteServer()->getRemoteName(theRemote); }
const Mode &loadFromConfig(KConfig &theConfig, int index);
void saveToConfig(KConfig &theConfig, int index);
bool operator==(const Mode &mode) const { return mode.theName == theName && mode.theRemote == theRemote; }
Mode();
Mode(const TQString &remote, const TQString &name, const TQString &iconFile = TQString());
~Mode();
};
#endif
|