• Skip to content
  • Skip to link menu
Trinity API Reference
  • Trinity API Reference
  • libtdegames
 

libtdegames

Public Slots | Public Member Functions | Protected Member Functions | List of all members
KGameErrorDialog Class Reference

#include <kgameerrordialog.h>

Inherits TQObject.

Public Slots

void slotError (int error, TQString text)
 
void slotServerConnectionLost ()
 
void slotClientConnectionLost (TQ_UINT32 clientID, bool broken)
 
void slotUnsetKGame ()
 

Public Member Functions

 KGameErrorDialog (TQWidget *parent)
 
void setKGame (const KGame *g)
 
void connectionError (TQString s=TQString())
 

Protected Member Functions

void error (const TQString &errorText, TQWidget *parent=0)
 

Detailed Description

Use error(), warning() and information() to display the information about a network game.

Maybe a better solution is to use KMessageBoxes You can connect to the public slots, too - they will call the static functions, so that you can always have a KGameErrorDialog object lying around without losing much memory (a KGameErrorMessageDialog Object will be created) Error handling for KGame

Author
Andreas Beckermann b_man.nosp@m.n@gm.nosp@m.x.de

Definition at line 39 of file kgameerrordialog.h.

Member Function Documentation

◆ connectionError()

void KGameErrorDialog::connectionError ( TQString  s = TQString())

KGame couldn't establish a connection.

Use this if KGame::initConnection returns false

Parameters
sA string that describes the error further (like port is already in use). Will be ignored if TQString()

Definition at line 103 of file kgameerrordialog.cpp.

◆ setKGame()

void KGameErrorDialog::setKGame ( const KGame *  g)

Automatically connects the KGame object to all error dependant slots.

Create a KGameErrorDialog object, call this function and forget everything.

Parameters
gThe KGame which will emit the erorrs (or not ;-) )

Definition at line 50 of file kgameerrordialog.cpp.

◆ slotClientConnectionLost

void KGameErrorDialog::slotClientConnectionLost ( TQ_UINT32  clientID,
bool  broken 
)
slot

The connection to a client has been lost by accident.

See KGameNetwork::signalClientDisconnected

Definition at line 84 of file kgameerrordialog.cpp.

◆ slotServerConnectionLost

void KGameErrorDialog::slotServerConnectionLost ( )
slot

The connection to the KMessageServer has been lost.

See KGameNetwork::signalConnectionBroken

Definition at line 77 of file kgameerrordialog.cpp.

◆ slotUnsetKGame

void KGameErrorDialog::slotUnsetKGame ( )
slot

Unsets a KGame which has been set using setKGame before.

This is called automatically when the KGame object is destroyed and you normally don't have to call this yourself.

Note that setKGame also unsets an already existing KGame object if exising.

Definition at line 66 of file kgameerrordialog.cpp.


The documentation for this class was generated from the following files:
  • kgameerrordialog.h
  • kgameerrordialog.cpp

libtdegames

Skip menu "libtdegames"
  • Main Page
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Class Members
  • Related Pages

libtdegames

Skip menu "libtdegames"
  • libtdegames
Generated for libtdegames by doxygen 1.8.13
This website is maintained by Timothy Pearson.