コード例 #1
0
ファイル: qiodevice.cpp プロジェクト: Acidburn0zzz/doxygen
bool QIODevice::atEnd() const
{
    if ( isSequentialAccess() || isTranslated() ) {
	QIODevice* that = (QIODevice*)this;
	int c = that->getch();
	bool result = c < 0;
	that->ungetch(c);
	return result;
    } else {
	return at() == (int)size();
    }
}
コード例 #2
0
ファイル: qiodevice.cpp プロジェクト: aroraujjwal/qt3
bool QIODevice::atEnd() const
{
    if ( isSequentialAccess() || isTranslated() ) {
	QIODevice* that = (QIODevice*)this;
        const int oldStatus = ioSt;
	int c = that->getch();
	bool result = c < 0;
	that->ungetch(c);
        if (ioSt != oldStatus)
            that->ioSt = oldStatus;
	return result;
    } else {
	return at() == size();
    }
}