https://bugs.kde.org/show_bug.cgi?id=451082

Tobias Leupold <t...@l3u.de> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |t...@l3u.de

--- Comment #1 from Tobias Leupold <t...@l3u.de> ---
The problem seems to be that, as soon as the "source" option contains something
that looks like the device had an ADF, multi page scanning is activated:

    void KSaneCorePrivate::determineMultiPageScanning(const QVariant &value)
    {
        const QString sourceString = value.toString();

        m_executeMultiPageScanning =
sourceString.contains(QStringLiteral("Automatic Document Feeder")) ||
        sourceString.contains(sane_i18n("Automatic Document Feeder")) || 
        sourceString.contains(QStringLiteral("ADF")) ||
        sourceString.contains(QStringLiteral("Duplex"));
    }

And here, it's started automatically:

    void KSaneCorePrivate::imageScanFinished()
    {
        Q_EMIT q->scanProgress(100);
        if (m_scanThread->frameStatus() == KSaneScanThread::ReadReady) {
            Q_EMIT q->scannedImageReady(*m_scanThread->scanImage());
            // now check if we should have automatic ADF batch scanning
            if (m_executeMultiPageScanning && !m_cancelMultiPageScan) {
                // in batch mode only one area can be scanned per page
                Q_EMIT q->scanProgress(-1);
                m_scanThread->start();
                return;
            }
    ...

m_cancelMultiPageScan can, as far as I could see it, only be set to true by
calling KSaneCore::stopScan().

Can we even fix this within libksane? Or is this something upstream should care
about?

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to