Changeset View
Changeset View
Standalone View
Standalone View
source/lobby/glooxwrapper/glooxwrapper.cpp
/* Copyright (C) 2015 Wildfire Games. | /* Copyright (C) 2017 Wildfire Games. | ||||
* This file is part of 0 A.D. | * This file is part of 0 A.D. | ||||
* | * | ||||
* 0 A.D. is free software: you can redistribute it and/or modify | * 0 A.D. is free software: you can redistribute it and/or modify | ||||
* it under the terms of the GNU General Public License as published by | * it under the terms of the GNU General Public License as published by | ||||
* the Free Software Foundation, either version 2 of the License, or | * the Free Software Foundation, either version 2 of the License, or | ||||
* (at your option) any later version. | * (at your option) any later version. | ||||
* | * | ||||
* 0 A.D. is distributed in the hope that it will be useful, | * 0 A.D. is distributed in the hope that it will be useful, | ||||
▲ Show 20 Lines • Show All 126 Lines • ▼ Show 20 Lines | virtual void handleMUCParticipantPresence(gloox::MUCRoom* UNUSED(room), const gloox::MUCRoomParticipant participant, const gloox::Presence& presence) | ||||
part.reason = participant.reason; | part.reason = participant.reason; | ||||
part.actor = participant.actor ? &actor : NULL; | part.actor = participant.actor ? &actor : NULL; | ||||
part.newNick = participant.newNick; | part.newNick = participant.newNick; | ||||
part.status = participant.status; | part.status = participant.status; | ||||
part.alternate = participant.alternate ? &alternate : NULL; | part.alternate = participant.alternate ? &alternate : NULL; | ||||
/* MUCRoom not supported */ | /* MUCRoom not supported */ | ||||
m_Wrapped->handleMUCParticipantPresence(NULL, part, glooxwrapper::Presence(presence.presence())); | m_Wrapped->handleMUCParticipantPresence(NULL, part, glooxwrapper::Presence(presence.presence())); | ||||
/* gloox 1.0 leaks some JIDs (fixed in 1.0.1), so clean them up */ | |||||
#if GLOOXVERSION == 0x10000 | |||||
delete participant.jid; | |||||
delete participant.actor; | |||||
delete participant.alternate; | |||||
#endif | |||||
leper: Removing this without erroring out if the version used is not new enough is just asking for… | |||||
Not Done Inline ActionsAs the build instructions say 1.0.9 is the minimum verison required, I had hoped for a compile error with earlier versions. Thanks! elexis: As the build instructions say 1.0.9 is the minimum verison required, I had hoped for a compile… | |||||
} | } | ||||
virtual void handleMUCMessage(gloox::MUCRoom* UNUSED(room), const gloox::Message& msg, bool priv) | virtual void handleMUCMessage(gloox::MUCRoom* UNUSED(room), const gloox::Message& msg, bool priv) | ||||
{ | { | ||||
glooxwrapper::Message msgWrapper(const_cast<gloox::Message*>(&msg), false); | glooxwrapper::Message msgWrapper(const_cast<gloox::Message*>(&msg), false); | ||||
/* MUCRoom not supported */ | /* MUCRoom not supported */ | ||||
m_Wrapped->handleMUCMessage(NULL, msgWrapper, priv); | m_Wrapped->handleMUCMessage(NULL, msgWrapper, priv); | ||||
▲ Show 20 Lines • Show All 581 Lines • Show Last 20 Lines |
Wildfire Games · Phabricator
Removing this without erroring out if the version used is not new enough is just asking for trouble.