summaryrefslogtreecommitdiff
path: root/noncore/unsupported/mail2/bend/bendimpl.cpp
blob: e616c68d6541319cdf7d7d85e7476d71870c074e (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
#include "bendimpl.h"
#include "bend.h"

BenDImpl::BenDImpl()
	: _benD(0), ref(0)
{

}

BenDImpl::~BenDImpl()
{
	delete _benD;
}

QWidget *BenDImpl::applet(QWidget *parent)
{
	if (!_benD) _benD = new BenD(parent);
	return _benD;
}

int BenDImpl::position() const
{
	return 4;
}

QRESULT BenDImpl::queryInterface(const QUuid &uuid, QUnknownInterface **iface)
{
	*iface = 0;
	if (uuid == IID_QUnknown) *iface = this;
	else if (uuid == IID_TaskbarApplet) *iface = this;

	if (*iface) (*iface)->addRef();
	return QS_OK;
}

Q_EXPORT_INTERFACE()
{
	Q_CREATE_INSTANCE(BenDImpl)
}