plugin.h 707 Bytes
Newer Older
Pierre Kraemer's avatar
Pierre Kraemer committed
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
#ifndef _PLUGIN_H_
#define _PLUGIN_H_

#include <QtPlugin>
#include <QAction>

#include "types.h"

namespace CGoGN
{

namespace SCHNApps
{

class Plugin : public QObject
{
	Q_OBJECT

	friend class SCHNApps;

public:
22
23
	Plugin();
	virtual ~Plugin();
Pierre Kraemer's avatar
Pierre Kraemer committed
24
25

public slots:
26
27
28
	QString getName();
	QString getFilePath();
	SCHNApps* getSCHNApps();
Pierre Kraemer's avatar
Pierre Kraemer committed
29
30

private:
31
32
33
	void setName(const QString& name);
	void setFilePath(const QString& f);
	void setSCHNApps(SCHNApps* s);
Pierre Kraemer's avatar
Pierre Kraemer committed
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50

	virtual bool enable() = 0;
	virtual void disable() = 0;

protected:
	QString m_name;
	QString m_filePath;
	SCHNApps* m_schnapps;
};

} // namespace SCHNApps

} // namespace CGoGN

Q_DECLARE_INTERFACE(CGoGN::SCHNApps::Plugin, "CGoGN.SCHNapps.Plugin")

#endif