make it possible to select the local port number for client, too
This commit is contained in:
parent
65ec067763
commit
c50dd2fc56
4 changed files with 6 additions and 5 deletions
|
@ -26,7 +26,8 @@
|
||||||
|
|
||||||
|
|
||||||
/* Implementation *************************************************************/
|
/* Implementation *************************************************************/
|
||||||
CClient::CClient() : bRun ( false ), Socket ( &Channel ),
|
CClient::CClient ( const quint16 iPortNumber ) : bRun ( false ),
|
||||||
|
Socket ( &Channel, iPortNumber ),
|
||||||
iAudioInFader ( AUD_FADER_IN_MAX / 2 ),
|
iAudioInFader ( AUD_FADER_IN_MAX / 2 ),
|
||||||
iReverbLevel ( AUD_REVERB_MAX / 6 ),
|
iReverbLevel ( AUD_REVERB_MAX / 6 ),
|
||||||
bReverbOnLeftChan ( false ),
|
bReverbOnLeftChan ( false ),
|
||||||
|
|
|
@ -61,7 +61,7 @@ class CClient : public QThread
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
CClient();
|
CClient ( const quint16 iPortNumber );
|
||||||
virtual ~CClient() {}
|
virtual ~CClient() {}
|
||||||
|
|
||||||
void Init();
|
void Init();
|
||||||
|
|
|
@ -142,7 +142,7 @@ int main ( int argc, char** argv )
|
||||||
{
|
{
|
||||||
// client
|
// client
|
||||||
// actual client object
|
// actual client object
|
||||||
CClient Client;
|
CClient Client ( iPortNumber );
|
||||||
|
|
||||||
// load settings from init-file
|
// load settings from init-file
|
||||||
CSettings Settings ( &Client );
|
CSettings Settings ( &Client );
|
||||||
|
|
|
@ -46,8 +46,8 @@ class CSocket : public QObject
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
CSocket ( CChannel* pNewChannel ) : pChannel( pNewChannel ), bIsClient ( true )
|
CSocket ( CChannel* pNewChannel, const quint16 iPortNumber ) :
|
||||||
{ Init(); }
|
pChannel( pNewChannel ), bIsClient ( true ) { Init ( iPortNumber ); }
|
||||||
CSocket ( CChannelSet* pNewChannelSet, QObject* pNServP, const quint16 iPortNumber ) :
|
CSocket ( CChannelSet* pNewChannelSet, QObject* pNServP, const quint16 iPortNumber ) :
|
||||||
pChannelSet(pNewChannelSet), pServer ( pNServP ), bIsClient ( false )
|
pChannelSet(pNewChannelSet), pServer ( pNServP ), bIsClient ( false )
|
||||||
{ Init ( iPortNumber ); }
|
{ Init ( iPortNumber ); }
|
||||||
|
|
Loading…
Reference in a new issue