[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: branches/KDE/3.4/kdegraphics/kpdf/ui
From: Albert Astals Cid <tsdgeos () terra ! es>
Date: 2005-05-12 10:12:44
Message-ID: 1115892764.811354.14172.nullmailer () svn ! kde ! org
[Download RAW message or body]
SVN commit 412667 by aacid:
Fix bug introduced when fixing 101648
BUGS: 105454
M +7 -7 branches/KDE/3.4/kdegraphics/kpdf/ui/pageview.cpp
--- branches/KDE/3.4/kdegraphics/kpdf/ui/pageview.cpp #412666:412667
@@ -876,22 +876,22 @@
{
double nX = (double)(e->x() - pageItem->geometry().left()) / (double)pageItem->width(),
nY = (double)(e->y() - pageItem->geometry().top()) / (double)pageItem->height();
- const ObjectRect * rect;
- rect = pageItem->page()->hasObject( ObjectRect::Link, nX, nY );
- if ( rect )
+ const ObjectRect * linkRect, * imageRect;
+ linkRect = pageItem->page()->hasObject( ObjectRect::Link, nX, nY );
+ if ( linkRect )
{
// handle click over a link
- const KPDFLink * link = static_cast< const KPDFLink * >( rect->pointer() );
+ const KPDFLink * link = static_cast< const KPDFLink * >( linkRect->pointer() );
d->document->processLink( link );
}
- rect = pageItem->page()->hasObject( ObjectRect::Image, nX, nY );
- if ( rect )
+ imageRect = pageItem->page()->hasObject( ObjectRect::Image, nX, nY );
+ if ( imageRect )
{
// handle click over a image
}
- if (!rect)
+ if (!linkRect && !imageRect)
{
// if not on a rect, the click selects the page
d->document->setViewportPage( pageItem->pageNumber(), PAGEVIEW_ID );
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic