[Okular-devel] [Bug 265002] New: Unreachable code in okular/ui/pageview.cpp (related to drag scroll)

Denis Pesotsky aka Obey-Kun obey at obey.su
Mon Jan 31 21:15:51 CET 2011


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

           Summary: Unreachable code in okular/ui/pageview.cpp (related to
                    drag scroll)
           Product: okular
           Version: unspecified
          Platform: Unlisted Binaries
        OS/Version: Linux
            Status: UNCONFIRMED
          Severity: normal
          Priority: NOR
         Component: general
        AssignedTo: okular-devel at kde.org
        ReportedBy: obey at obey.su


Version:           unspecified
OS:                Linux

Following code is probably unreachable in pageview.cpp:

// If the delta is huge it probably means we just wrapped in that direction
const QPoint absDelta(abs(delta.x()), abs(delta.y()));
if ( absDelta.y() > mouseContainer.height() / 2 )
{
   delta.setY(mouseContainer.height() - absDelta.y());
}
if ( absDelta.x() > mouseContainer.width() / 2 )
{
   delta.setX(mouseContainer.width() - absDelta.x());
}

It's unreachable coze delta is equal to d->mouseGrabPos - mousePos, and
d->mouseGrabPos is updated anyways when we wrapped.

Haven't tested it however.

Reproducible: Didn't try

-- 
Configure bugmail: https://bugs.kde.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.


More information about the Okular-devel mailing list