diff options
author | Oliver Bolte <obo@openoffice.org> | 2008-07-25 06:01:43 +0000 |
---|---|---|
committer | Oliver Bolte <obo@openoffice.org> | 2008-07-25 06:01:43 +0000 |
commit | 8fe15f6efc27dfa197a572ce3aa1ddb41789a342 (patch) | |
tree | 6a9bd0cdcaebb2426c7c3a17e4dc6b381e21d8c4 /sd | |
parent | e2f975752e7255c145cde5a339a39a8b2cc86362 (diff) |
INTEGRATION: CWS impress148 (1.28.74); FILE MERGED
2008/07/08 08:19:23 af 1.28.74.1: #i91462# In AnimationWindow prevent iteration from leaving valid range.
Diffstat (limited to 'sd')
-rw-r--r-- | sd/source/ui/dlg/animobjs.cxx | 21 |
1 files changed, 17 insertions, 4 deletions
diff --git a/sd/source/ui/dlg/animobjs.cxx b/sd/source/ui/dlg/animobjs.cxx index 8b43f554d41a..c48c7b1def07 100644 --- a/sd/source/ui/dlg/animobjs.cxx +++ b/sd/source/ui/dlg/animobjs.cxx @@ -7,7 +7,7 @@ * OpenOffice.org - a multi-platform office productivity suite * * $RCSfile: animobjs.cxx,v $ - * $Revision: 1.28 $ + * $Revision: 1.29 $ * * This file is part of OpenOffice.org. * @@ -350,18 +350,31 @@ IMPL_LINK( AnimationWindow, ClickPlayHdl, void *, p ) if( bReverse ) { i--; - bCount = i >= 0; + if (i < 0) + { + // Terminate loop. + bCount = false; + // Move i back into valid range. + i = 0; + } } else { i++; - bCount = i < (long) nCount; + if (i >= (long) nCount) + { + // Terminate loop. + bCount = false; + // Move i back into valid range. + i = nCount - 1; + } } } // Um die Controls wieder zu enablen bMovie = FALSE; - UpdateControl( i - 1 ); + if (nCount > 0) + UpdateControl(i); if( pProgress ) { |