Fit frames to frames rect.

This commit is contained in:
Bartosz Taudul 2017-09-19 00:36:28 +02:00
parent 2ba44bc0bc
commit 3ee4a72076

View File

@ -454,7 +454,7 @@ void View::DrawFrames()
const int fwidth = m_frameScale == 0 ? 4 : 1; const int fwidth = m_frameScale == 0 ? 4 : 1;
const int group = m_frameScale < 2 ? 1 : ( 1 << ( m_frameScale - 1 ) ); const int group = m_frameScale < 2 ? 1 : ( 1 << ( m_frameScale - 1 ) );
const int total = m_frames.size(); const int total = m_frames.size();
const int onScreen = ( w + fwidth-1 ) / fwidth * group; const int onScreen = ( w - 2 ) / fwidth * group;
if( !m_pause ) m_frameStart = total < onScreen ? 0 : total - onScreen; if( !m_pause ) m_frameStart = total < onScreen ? 0 : total - onScreen;
int i = 0, idx = 0; int i = 0, idx = 0;