change stayontable-status handling from gui to engine code
This commit is contained in:
+6
-2
@@ -196,7 +196,8 @@ HEADERS += src/engine/game.h \
|
||||
src/engine/local_engine/replay.h \
|
||||
src/gui/qt/gamelobbydialog/mynicklistsortfilterproxymodel.h \
|
||||
src/gui/qt/gametable/myslider.h \
|
||||
src/gui/qt/gametable/mycashlabel.h
|
||||
src/gui/qt/gametable/mycashlabel.h \
|
||||
src/gui/qt/sound/soundevents.h
|
||||
|
||||
!gui_800x480 {
|
||||
FORMS += src/gui/qt/gametable.ui \
|
||||
@@ -270,7 +271,8 @@ SOURCES += src/pokerth.cpp \
|
||||
src/engine/local_engine/replay.cpp \
|
||||
src/gui/qt/gamelobbydialog/mynicklistsortfilterproxymodel.cpp \
|
||||
src/net/common/servermanagerfactoryclient.cpp \
|
||||
src/gui/qt/gametable/mycashlabel.cpp
|
||||
src/gui/qt/gametable/mycashlabel.cpp \
|
||||
src/gui/qt/sound/soundevents.cpp
|
||||
TRANSLATIONS = ts/pokerth_af.ts \
|
||||
ts/pokerth_bg.ts \
|
||||
ts/pokerth_zhcn.ts \
|
||||
@@ -591,3 +593,5 @@ gui_800x480 {
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -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();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -0,0 +1,8 @@
|
||||
#include "sdlplayer.h"
|
||||
#include "configfile.h"
|
||||
#include "soundevents.h"
|
||||
|
||||
SoundEvents::SoundEvents(ConfigFile *c): myConfig(c)
|
||||
{
|
||||
mySDLPlayer = new SDLPlayer(myConfig);
|
||||
}
|
||||
@@ -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
|
||||
Reference in New Issue
Block a user