KGameDialogNetworkConfig Class Reference

Inheritance diagram for KGameDialogNetworkConfig:

KGameDialogConfig List of all members.

Detailed Description

Definition at line 211 of file kgamedialogconfig.h.


Signals

void signalServerTypeChanged (int)

Public Member Functions

 KGameDialogNetworkConfig (QWidget *parent=0)
virtual ~KGameDialogNetworkConfig ()
void disableInitConnection ()
virtual void submitToKGame (KGame *g, KPlayer *p)
virtual void setKGame (KGame *g)
void setDefaultNetworkInfo (const QString &host, unsigned short int port, bool server=true)
void setDiscoveryInfo (const QString &type, const QString &name=QString::null)

Protected Slots

void slotInitConnection ()
void slotExitConnection ()
void slotConnectionBroken ()

Protected Member Functions

void setConnected (bool connected, bool master=false)

Member Function Documentation

void KGameDialogNetworkConfig::submitToKGame ( KGame g,
KPlayer p 
) [virtual]

Called by KGameDialog to submit all settings to the KGame Object.

You have to replace this if you add your own widgets!

Parameters:
g A pointer to your KGame.
p A pointer to the player owning this dialog

Implements KGameDialogConfig.

Definition at line 214 of file kgamedialogconfig.cpp.

void KGameDialogNetworkConfig::setKGame ( KGame g  )  [virtual]

The KGame object of the dialog has been changed.

The default implementation changes the pointer for game so don't forget to call the default implementation if you overwrite this!

You can use this e.g. to re-read the min/max player settings.

Parameters:
g The KGame object

Reimplemented from KGameDialogConfig.

Definition at line 218 of file kgamedialogconfig.cpp.

void KGameDialogNetworkConfig::setDefaultNetworkInfo ( const QString &  host,
unsigned short int  port,
bool  server = true 
)

This sets the default port and host used in KGameConnectDialog.

The user will be able to change these defaults!

If you don't call this then host "localhost" and port "0" is used. You are strongly encouraged to change at least the port!

Parameters:
port The default port to connect to / listen on
host The default host to connect to

Definition at line 228 of file kgamedialogconfig.cpp.

void KGameDialogNetworkConfig::setDiscoveryInfo ( const QString &  type,
const QString &  name = QString::null 
)

Set service type that will be published or browsed for and game name that will be displayed in server browser.

Without this publishing and discovery of LAN servers will not be enabled.

Parameters:
name Game name. Important only for server mode. If not set hostname will be used. In case of name conflict -2, -3 and so on will be added to name.
type Service type (something like _kwin4._tcp). It should be unique for application.
Since:
3.4

Definition at line 243 of file kgamedialogconfig.cpp.

void KGameDialogNetworkConfig::signalServerTypeChanged ( int   )  [signal]

This signal is emmited if the user changes the server type (client/server) in the network configuration dialog.

Parameters:
t - type type (0/1) of the connection


The documentation for this class was generated from the following files:
KDE Home | KDE Accessibility Home | Description of Access Keys