summaryrefslogtreecommitdiffstats
path: root/src/corelib/io/qwindowspipereader_p.h
diff options
context:
space:
mode:
authorJoerg Bornemann <joerg.bornemann@nokia.com>2012-01-16 12:26:40 +0100
committerQt by Nokia <qt-info@nokia.com>2012-01-24 14:40:32 +0100
commit3bc42e860d039147de0c22c0db0ad756ccc060de (patch)
treec729a9aa48fb29edb85c91ba66c353a71db915f2 /src/corelib/io/qwindowspipereader_p.h
parent096b49bc1e66af2e6347bafc435b361a15639872 (diff)
use QWinOverlappedIoNotifier in QWindowsPipeReader
Change-Id: I71d5feaa07e8febd6c562be1dc6d7790e3a1606c Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Diffstat (limited to 'src/corelib/io/qwindowspipereader_p.h')
-rw-r--r--src/corelib/io/qwindowspipereader_p.h12
1 files changed, 7 insertions, 5 deletions
diff --git a/src/corelib/io/qwindowspipereader_p.h b/src/corelib/io/qwindowspipereader_p.h
index 132c3540c0..2d979c337b 100644
--- a/src/corelib/io/qwindowspipereader_p.h
+++ b/src/corelib/io/qwindowspipereader_p.h
@@ -66,7 +66,7 @@ QT_BEGIN_NAMESPACE
QT_MODULE(Core)
-class QWinEventNotifier;
+class QWinOverlappedIoNotifier;
class Q_CORE_EXPORT QWindowsPipeReader : public QObject
{
@@ -89,7 +89,7 @@ public:
bool waitForPipeClosed(int msecs);
void startAsyncRead();
- bool completeAsyncRead();
+ bool isReadOperationActive() const { return readSequenceStarted; }
Q_SIGNALS:
void winError(ulong, const QString &);
@@ -97,22 +97,24 @@ Q_SIGNALS:
void pipeClosed();
private Q_SLOTS:
- bool readEventSignalled();
+ void notified(DWORD numberOfBytesRead, DWORD errorCode);
private:
+ bool completeAsyncRead(DWORD bytesRead, DWORD errorCode);
DWORD checkPipeState();
private:
HANDLE handle;
OVERLAPPED overlapped;
- QWinEventNotifier *dataReadNotifier;
+ QWinOverlappedIoNotifier *dataReadNotifier;
qint64 readBufferMaxSize;
QRingBuffer readBuffer;
int actualReadBufferSize;
bool readSequenceStarted;
QTimer *emitReadyReadTimer;
bool pipeBroken;
- static const qint64 initialReadBufferSize = 4096;
+ bool readyReadEmitted;
+ static const DWORD minReadBufferSize = 4096;
};
QT_END_NAMESPACE