[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    branches/KDE/4.3/kdegraphics/okular/ui
From:       Albert Astals Cid <tsdgeos () terra ! es>
Date:       2009-11-20 20:55:06
Message-ID: 1258750506.160724.6570.nullmailer () svn ! kde ! org
[Download RAW message or body]

SVN commit 1052139 by aacid:

Backport r1052137 | aacid | 2009-11-20 21:52:51 +0100 (Fri, 20 Nov 2009) | 3 lines

Get the viewport before resizing the canvas otherwise the canvas resizal makes the \
                viewport change and later we end up with an incorrect viewport
BUGS: 215463


 M  +1 -1      pageview.cpp  


--- branches/KDE/4.3/kdegraphics/okular/ui/pageview.cpp #1052138:1052139
@@ -2971,6 +2971,7 @@
     bool wasUpdatesEnabled = viewport()->updatesEnabled();
     if ( fullWidth != widget()->width() || fullHeight != widget()->height() )
     {
+        const Okular::DocumentViewport vp = d->document->viewport();
         // disable updates and resize the viewportContents
         if ( wasUpdatesEnabled )
             viewport()->setUpdatesEnabled( false );
@@ -2981,7 +2982,6 @@
         // restore previous viewport if defined and updates enabled
         if ( wasUpdatesEnabled )
         {
-            const Okular::DocumentViewport & vp = d->document->viewport();
             if ( vp.pageNumber >= 0 )
             {
                 int prevX = horizontalScrollBar()->value(),


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic