[prev in list] [next in list] [prev in thread] [next in thread]
List: atlantik-devel
Subject: [atlantik-cvs]
From: kde () office ! kde ! org
Date: 2003-07-14 1:29:53
[Download RAW message or body]
Update of /home/kde/kdegames/atlantik/client
In directory office:/tmp/cvs-serv5255/client
Modified Files:
atlantik.cpp atlantik.h
Log Message:
move playerSelf to core, fixes some token issues
Index: atlantik.cpp
===================================================================
RCS file: /home/kde/kdegames/atlantik/client/atlantik.cpp,v
retrieving revision 1.153
retrieving revision 1.154
diff -u -d -r1.153 -r1.154
--- atlantik.cpp 13 Jul 2003 04:41:40 -0000 1.153
+++ atlantik.cpp 14 Jul 2003 01:29:50 -0000 1.154
@@ -65,7 +65,6 @@
m_selectServer = 0;
m_selectGame = 0;
m_selectConfiguration = 0;
- m_playerSelf = 0;
m_atlantikNetwork = 0;
// Game and network core
@@ -184,7 +183,7 @@
playerChanged(player);
if (player->isSelf())
- m_playerSelf = player;
+ m_atlanticCore->setPlayerSelf(player);
connect(player, SIGNAL(changed(Player *)), this, SLOT(playerChanged(Player *)));
connect(player, SIGNAL(changed(Player *)), m_board, SLOT(playerChanged(Player *)));
@@ -243,7 +242,6 @@
}
m_atlanticCore->reset(true);
- m_playerSelf = 0;
initNetworkObject();
@@ -307,8 +305,9 @@
if (m_selectConfiguration)
return;
+ Player *playerSelf = m_atlanticCore->playerSelf();
m_selectConfiguration = new SelectConfiguration(m_mainWidget, "selectConfiguration");
- m_selectConfiguration->setCanStart(m_playerSelf ? m_playerSelf->master() : false);
+ m_selectConfiguration->setCanStart(playerSelf ? playerSelf->master() : false);
m_mainLayout->addMultiCellWidget(m_selectConfiguration, 0, 2, 1, 1);
m_selectConfiguration->show();
@@ -553,7 +552,8 @@
if (!portfolioView)
portfolioView = addPortfolioView(player);
- if (player == m_playerSelf)
+ Player *playerSelf = m_atlanticCore->playerSelf();
+ if (player == playerSelf)
{
// We changed ourselves, see if other players (that we know
// about) have the same gameId..
@@ -563,7 +563,7 @@
if ((portfolioView = dynamic_cast<PortfolioView*>(*it)))
{
Player *pTmp = portfolioView->player();
- if (pTmp->gameId() == m_playerSelf->gameId())
+ if (pTmp->gameId() == playerSelf->gameId())
portfolioView->show();
else
portfolioView->hide();
@@ -586,9 +586,9 @@
{
// Another player changed, check if we need to show or hide
// his/her portfolioView.
- if (m_playerSelf)
+ if (playerSelf)
{
- if (player->gameId() == m_playerSelf->gameId())
+ if (player->gameId() == playerSelf->gameId())
portfolioView->show();
else
portfolioView->hide();
Index: atlantik.h
===================================================================
RCS file: /home/kde/kdegames/atlantik/client/atlantik.h,v
retrieving revision 1.59
retrieving revision 1.60
diff -u -d -r1.59 -r1.60
--- atlantik.h 13 Jul 2003 04:41:40 -0000 1.59
+++ atlantik.h 14 Jul 2003 01:29:50 -0000 1.60
@@ -212,8 +212,6 @@
AtlantikNetwork *m_atlantikNetwork;
AtlantikConfig m_config;
- Player *m_playerSelf;
-
ConfigDialog *m_configDialog;
AtlantikBoard *m_board;
SelectServer *m_selectServer;
_______________________________________________
atlantik-cvs mailing list
atlantik-cvs@mail.kde.org
http://mail.kde.org/mailman/listinfo/atlantik-cvs
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic