diff options
author | Caolán McNamara <caolanm@redhat.com> | 2016-05-24 20:44:11 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2016-05-24 20:57:57 +0100 |
commit | c5ab14e2bca0cc4fabd25b27f078a1c38fda4fa7 (patch) | |
tree | 4253c9d03a08906c5774f8ce65ab5bea433da5aa | |
parent | 6c419129f27d61295508d14448351f62e994806b (diff) |
Resolves: tdf#100024 CRASH when setting a background image
possibly triggered by changes like...
commit bb3671180eb7327be9ac178e0d8341322f63d72a
Author: Caolán McNamara <caolanm@redhat.com>
Date: Tue May 17 20:38:37 2016 +0100
Related: tdf#99523 NotifyPageEvent ultimately comes from HINT_PAGEORDERCHG...
which is called for removepage, insertpage *and* change page number. e.g.
ctrl+shift+end and similar *move* the page, in those cases not removing before
adding results in duplicate pages/slides in the list, causing inconsistencies
on what gets selected on undo
which made things not get arbitrarily duplicated during page changes
Change-Id: I0acf241947c9688f3512b54cc3d8f6892126495b
-rw-r--r-- | sd/source/ui/slidesorter/model/SlideSorterModel.cxx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sd/source/ui/slidesorter/model/SlideSorterModel.cxx b/sd/source/ui/slidesorter/model/SlideSorterModel.cxx index dae17c57fb8d..cd8c2df16de4 100644 --- a/sd/source/ui/slidesorter/model/SlideSorterModel.cxx +++ b/sd/source/ui/slidesorter/model/SlideSorterModel.cxx @@ -557,7 +557,7 @@ void SlideSorterModel::InsertSlide (SdPage* pPage) if (nIndex>0) if (GetPage(nIndex-1) != GetPageDescriptor(nIndex-1)->GetPage()) return; - if (size_t(nIndex)<maPageDescriptors.size()-1) + if (nIndex < static_cast<sal_Int32>(maPageDescriptors.size()) -1) if (GetPage(nIndex+1) != GetPageDescriptor(nIndex)->GetPage()) return; |