Apache OpenOffice (AOO) Bugzilla – Issue 124525
Undo from different slide jumps to slide one
Last modified: 2014-03-28 14:27:26 UTC
Created attachment 83004 [details] test screenshot See attached test 575 - step 7 AOO410m14(Build:9760) - Rev. 1581281 2014-03-26_04:11:07 - Rev. 1581686 Debian
Created attachment 83005 [details] sample presentation
Reproducible with server installation of "AOO 4.1.0-dev – English UI / German locale - [AOO410m14(Build:9760) - Rev. 1577236 2014-03-15]" on German WIN7 Home Premium (64bit)", own separate user profile. No need toi do so many steps 1. Open sample document -> Slide 3 2. to Chart Add Animation "Entrance - Appear" 3. In Slides pane click Slide 4 > View changes to slide 4 4. 'Click Undo Icon' Expected: Nothing or jumps to slide 3 where undo will be done Actual: Jumps to Slide 1 Additional Info: ----------------- (a) Has nothing to do with animation. Any undo will jump to slide 1 if current slide is not the one where undo will be done. Try with deleting a word in table (b) More Simple: Create new Presentation with 3 slides with title, Type a nonsense word into Title slide 2 In slides pane click Slide 3 Undo: undo done correct, but focus changes to slide 1 (c) Already reproducible with server installation of "AOO 4.1.0-Beta – German UI / German locale - [AOO410m14(Build:9760) - Rev. 1573601 2014-03-03 17:47:48]" on German WIN7 Home Premium (64bit)", own separate user profile. (d) Was still ok with Revision 1560760_2014-02-26 (e) With 4.1 you see that focus for a very short moment changes to the slide where the undo has effect, then changes to slide 1
oops
Comment on attachment 83004 [details] test screenshot not required
The PageChange to show the SdrPage to which the Undo is related is triggered by SdrUndoObj::ImpShowPageOfThisObject() which triggers a SdrPaintView::ShowSdrPage(SdrPage* pPage), this is correct. But then SlideSorter PageSelector::UpdateCurrentPage is triggered and there no selected page is found; thus pCurrentPageDescriptor = mrModel.GetPageDescriptor(0); is executed which selects 1st page. Adding Andre to CC, he knows that stuff better. @Andre: Looks as if SlideSorter does not yet know which page is selected or gets unlocked too early.
I also can confirm the described defect on Windows 7 in AOO 4.1.0 Beta and in AOO410m1(Build:9750) - Rev. 1571677 (build from the Windows buildbot) Not reproducible in AOO 4.0.1 and AOO410m1(Build:9750) - Rev. 156659
(In reply to Oliver-Rainer Wittmann from comment #6) > I also can confirm the described defect on Windows 7 in AOO 4.1.0 Beta and > in AOO410m1(Build:9750) - Rev. 1571677 (build from the Windows buildbot) > > Not reproducible in AOO 4.0.1 and AOO410m1(Build:9750) - Rev. 156659 sorry - copy-and-paste did not went well: It is "Rev. 1566593" not "Rev. 156659"
This bug is caused by the many ways of storing the current page and the many ways to notify changes of the current page. The slide sorter tries its best to keep track and coordinate these but, sometimes, fails to do so. In this special case the code to look at can be found in SlotManager::FuSupport() where the SID_UNDO and SID_REDO slots are processed. A SelectionObserver::Context is created before the actual undo or redo is executed that listens for newly inserted slides. If there are any then these slides are selected afterwards. The first of these, per standing rule of the slidesorter, becomes the new current page. In this case, however, there are no new slides. Therefore the SelectionObserver just deselects all pages when the Context is destroyed. The result is that the default slide (the first slide) is made the current slide.