change stayontable-status handling from gui to engine code

This commit is contained in:
doitux
2011-12-23 19:22:04 +00:00
parent bf81ba1d98
commit 4961e79ea1
4 changed files with 34 additions and 11 deletions
+3 -9
View File
@@ -3768,17 +3768,11 @@ void gameTableImpl::restoreGameTableGeometry()
}
}
void gameTableImpl::netClientPlayerLeft(unsigned playerId)
void gameTableImpl::netClientPlayerLeft(unsigned /*playerId*/)
{
if (myStartWindow->getSession()->getCurrentGame() && myStartWindow->getSession()->isNetworkClientRunning()) {
boost::shared_ptr<PlayerInterface> tmpPlayer = myStartWindow->getSession()->getCurrentGame()->getPlayerByUniqueId(playerId);
if (tmpPlayer.get()) {
tmpPlayer->setMyStayOnTableStatus(0);
refreshPlayerAvatar();
refreshPlayerName();
}
refreshPlayerAvatar();
refreshPlayerName();
}
}
+8
View File
@@ -0,0 +1,8 @@
#include "sdlplayer.h"
#include "configfile.h"
#include "soundevents.h"
SoundEvents::SoundEvents(ConfigFile *c): myConfig(c)
{
mySDLPlayer = new SDLPlayer(myConfig);
}
+17
View File
@@ -0,0 +1,17 @@
#ifndef SOUNDEVENTS_H
#define SOUNDEVENTS_H
class SDLPlayer;
class ConfigFile;
class SoundEvents
{
public:
SoundEvents(ConfigFile*);
private:
SDLPlayer *mySDLPlayer;
ConfigFile *myConfig;
};
#endif // SOUNDEVENTS_H