Hide widget annotations from the user (some other checks)

This patch also prevents the popup window from being opened on
double-click and the annotation tooltip from being shown.
remotes/origin/KDE/4.10
Fabio D'Urso 13 years ago
parent 38861f5f57
commit 7cdc42a682
  1. 4
      ui/pageview.cpp

@ -2916,7 +2916,7 @@ void PageView::mouseDoubleClickEvent( QMouseEvent * e )
const Okular::ObjectRect * orect = pageItem->page()->objectRect( Okular::ObjectRect::OAnnotation, nX, nY, itemRect.width(), itemRect.height() );
if ( orect )
ann = ( (Okular::AnnotationObjectRect *)orect )->annotation();
if ( ann )
if ( ann && ann->subType() != Okular::Annotation::AWidget )
{
openAnnotationWindow( ann, pageItem->pageNumber() );
}
@ -3026,7 +3026,7 @@ bool PageView::viewportEvent( QEvent * e )
}
}
if ( ann )
if ( ann && ann->subType() != Okular::Annotation::AWidget )
{
QRect r = rect->boundingRect( pageItem->uncroppedWidth(), pageItem->uncroppedHeight() );
r.translate( pageItem->uncroppedGeometry().topLeft() );

Loading…
Cancel
Save