[atlantik-cvs] CVS: kdegames/atlantik/libatlantikclient atlantik_network.cpp,1.75,1.76 atlantik_network.h,1.39,1.40
[email protected] Mon, 23 Dec 2002 05:03:57 +0100 (CET)
Newsgroups
gmane.comp.kde.devel.atlantik
Message-ID
<[email protected] >
Update of /home/kde/kdegames/atlantik/libatlantikclient
In directory office:/tmp/cvs-serv2934/libatlantikclient
Modified Files:
atlantik_network.cpp atlantik_network.h
Log Message:
API: make use of cleartext/clearbuttons attributes in display
Index: atlantik_network.cpp
===================================================================
RCS file: /home/kde/kdegames/atlantik/libatlantikclient/atlantik_network.cpp,v
retrieving revision 1.75
retrieving revision 1.76
diff -u -d -r1.75 -r1.76
--- atlantik_network.cpp 23 Dec 2002 01:34:47 -0000 1.75
+++ atlantik_network.cpp 23 Dec 2002 04:03:54 -0000 1.76
@@ -210,11 +210,12 @@
void AtlantikNetwork::writeData(QString msg)
{
+ kdDebug() << "sending [" << msg << "]" << endl;
msg.append("\n");
if (socketStatus() == KExtendedSocket::connected)
writeBlock(msg.latin1(), strlen(msg.latin1()));
else
- kdDebug() << "could not send [" << msg << "]" << endl;
+ kdDebug() << "warning: socket not connected!" << endl;
}
void AtlantikNetwork::slotRead()
@@ -286,7 +287,7 @@
Estate *estate;
estate = m_atlanticCore->findEstate(a.value().toInt());
- emit displayDetails(e.attributeNode(QString("text")).value(), estate);
+ emit displayDetails(e.attributeNode(QString("text")).value(), e.attributeNode(QString("cleartext")).value().toInt(), e.attributeNode(QString("clearbuttons")).value().toInt(), estate);
bool hasButtons = false;
for( QDomNode nButtons = n.firstChild() ; !nButtons.isNull() ; nButtons = nButtons.nextSibling() )
Index: atlantik_network.h
===================================================================
RCS file: /home/kde/kdegames/atlantik/libatlantikclient/atlantik_network.h,v
retrieving revision 1.39
retrieving revision 1.40
diff -u -d -r1.39 -r1.40
--- atlantik_network.h 19 Dec 2002 21:34:41 -0000 1.39
+++ atlantik_network.h 23 Dec 2002 04:03:55 -0000 1.40
@@ -116,7 +116,7 @@
void msgError(QString);
void msgChat(QString, QString);
- void displayDetails(QString text, Estate *estate = 0);
+ void displayDetails(QString text, bool clearText, bool clearButtons, Estate *estate = 0);
void addCommandButton(QString command, QString caption, bool enabled);
void addCloseButton();