diff options
| author | 2008-06-03 17:01:18 +0000 | |
|---|---|---|
| committer | 2008-06-03 17:01:18 +0000 | |
| commit | f8bc886e0de4f367b377ff2a77c1016c74bd14c1 (patch) | |
| tree | 496c256be276b49b6b26d7be45b2a7c530bdd857 /src/modules/dcc/marshal.cpp | |
| parent | updated doc (diff) | |
| download | KVIrc-f8bc886e0de4f367b377ff2a77c1016c74bd14c1.tar.gz KVIrc-f8bc886e0de4f367b377ff2a77c1016c74bd14c1.tar.bz2 KVIrc-f8bc886e0de4f367b377ff2a77c1016c74bd14c1.zip | |
more QT4 port
git-svn-id: https://svn.kvirc.de/svn/trunk/kvirc@1900 17fca916-40b9-46aa-a4ea-0a15b648b75c
Diffstat (limited to 'src/modules/dcc/marshal.cpp')
| -rw-r--r-- | src/modules/dcc/marshal.cpp | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/src/modules/dcc/marshal.cpp b/src/modules/dcc/marshal.cpp index 06a947583..b970f6334 100644 --- a/src/modules/dcc/marshal.cpp +++ b/src/modules/dcc/marshal.cpp @@ -35,8 +35,9 @@ KviDccMarshal::KviDccMarshal(KviDccMarshalOutputContext * ctx) -: QObject(0,"dcc_marshal") +: QObject(0) { + setObjectName("dcc_marshal"); m_pSn = 0; m_fd = KVI_INVALID_SOCKET; m_pTimeoutTimer = 0; @@ -121,7 +122,9 @@ int KviDccMarshal::dccListen(const QString &ip,const QString &port,bool bUseTime if(m_pTimeoutTimer)delete m_pTimeoutTimer; m_pTimeoutTimer = new QTimer(); connect(m_pTimeoutTimer,SIGNAL(timeout()),this,SLOT(doListen())); - m_pTimeoutTimer->start(100,true); +// m_pTimeoutTimer->start(100,true); + m_pTimeoutTimer->setInterval(199); + m_pTimeoutTimer->setSingleShot(true); return KviError_success; } @@ -284,7 +287,9 @@ void KviDccMarshal::doListen() { m_pTimeoutTimer = new QTimer(); connect(m_pTimeoutTimer,SIGNAL(timeout()),this,SLOT(connectionTimedOut())); - m_pTimeoutTimer->start(KVI_OPTION_UINT(KviOption_uintDccSocketTimeout) * 1000,true); + //m_pTimeoutTimer->start(KVI_OPTION_UINT(KviOption_uintDccSocketTimeout) * 1000,true); + m_pTimeoutTimer->setInterval(KVI_OPTION_UINT(KviOption_uintDccSocketTimeout) * 1000); + m_pTimeoutTimer->setSingleShot(true); } // and wait for connect @@ -309,8 +314,9 @@ int KviDccMarshal::dccConnect(const char * ip,const char * port,bool bUseTimeout if(m_pTimeoutTimer)delete m_pTimeoutTimer; m_pTimeoutTimer = new QTimer(); connect(m_pTimeoutTimer,SIGNAL(timeout()),this,SLOT(doConnect())); - m_pTimeoutTimer->start(100,true); - +// m_pTimeoutTimer->start(100,true); + m_pTimeoutTimer->setInterval(100); + m_pTimeoutTimer->setSingleShot(true); return KviError_success; } |
