summaryrefslogtreecommitdiff
path: root/protocols/Sametime/src/places.cpp
blob: 2fd862d70deb8b86fe6e4fcfb9eb80a9e5591660 (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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
#include "StdAfx.h"
#include "sametime.h"

/* Stubs, NOT IMPLEMENTED NOW */

void mwServicePlace_opened(struct mwPlace*)
{
}

void mwServicePlace_closed(struct mwPlace*, guint32)
{
}

void mwServicePlace_peerJoined(struct mwPlace*, const struct mwIdBlock*)
{
}


void mwServicePlace_peerParted(struct mwPlace*, const struct mwIdBlock*)
{
}


void mwServicePlace_peerSetAttribute(struct mwPlace*, const struct mwIdBlock*, guint32, struct mwOpaque*)
{
}


void mwServicePlace_peerUnsetAttribute(struct mwPlace*, const struct mwIdBlock*, guint32)
{
}


void mwServicePlace_message(struct mwPlace*, const struct mwIdBlock*, const char*)
{
}


void mwServicePlace_clear(struct mwServicePlace*)
{
}


mwPlaceHandler mwPlace_handler = {
	mwServicePlace_opened,
	mwServicePlace_closed,
	mwServicePlace_peerJoined,
	mwServicePlace_peerParted,
	mwServicePlace_peerSetAttribute,
	mwServicePlace_peerUnsetAttribute,
	mwServicePlace_message,
	mwServicePlace_clear
};

void CSametimeProto::InitPlaces(mwSession* pSession)
{
	debugLogW(L"CSametimeProto::InitPlaces()");
	mwSession_addService(pSession, (mwService*)(service_places = mwServicePlace_new(pSession, &mwPlace_handler)));
}

void CSametimeProto::DeinitPlaces(mwSession* pSession)
{
	debugLogW(L"CSametimeProto::DeinitPlaces()");
	mwSession_removeService(pSession, mwService_PLACE);
	mwService_free((mwService*)service_places);
	service_places = nullptr;
}