summaryrefslogtreecommitdiffstats
path: root/sd/inc
diff options
context:
space:
mode:
authormst <mst@openoffice.org>2011-09-17 22:43:23 +0000
committerThorsten Behrens <tbehrens@suse.com>2011-11-29 17:57:33 +0100
commitbdfbbb33a491f3ce34375de14ba33436b047e88b (patch)
tree574a4192bd8091e22f9067f08e78d47bc5779198 /sd/inc
parentslidesorter1: #i114252# Fixed selection in slidesorter. (diff)
downloadcore-bdfbbb33a491f3ce34375de14ba33436b047e88b.tar.gz
core-bdfbbb33a491f3ce34375de14ba33436b047e88b.zip
slidesorter1: #i116014# Outliner holds ViewShell as weak_ptr.
* found as LGPLv3-only fix at svn rev 1172131 (http://svn.apache.org/viewvc?view=revision&revision=1172131)
Diffstat (limited to 'sd/inc')
-rw-r--r--sd/inc/Outliner.hxx17
1 files changed, 9 insertions, 8 deletions
diff --git a/sd/inc/Outliner.hxx b/sd/inc/Outliner.hxx
index aa75c763a459..805b1ef1516e 100644
--- a/sd/inc/Outliner.hxx
+++ b/sd/inc/Outliner.hxx
@@ -36,6 +36,8 @@
#include <editeng/SpellPortions.hxx>
#include <memory>
#include <boost/shared_ptr.hpp>
+#include <boost/weak_ptr.hpp>
+#include <boost/noncopyable.hpp>
class Dialog;
class SdPage;
@@ -105,7 +107,8 @@ class Window;
</p>
*/
class Outliner
- : public SdrOutliner
+ : public SdrOutliner,
+ public ::boost::noncopyable
{
public:
friend class ::sd::outliner::OutlinerContainer;
@@ -194,8 +197,11 @@ private:
/// The view which displays the searched objects.
::sd::View* mpView;
- /// The view shell containing the view.
- ::boost::shared_ptr<ViewShell> mpViewShell;
+ /** The view shell containing the view. It is held as weak
+ pointer to avoid keeping it alive when the view is changed
+ during searching.
+ */
+ ::boost::weak_ptr<ViewShell> mpWeakViewShell;
/// This window contains the view.
::sd::Window* mpWindow;
/// The document on whose objects and pages this class operates.
@@ -347,11 +353,6 @@ private:
*/
bool mbPrepareSpellingPending;
- /** In this flag we store whether the view shell is valid and may be
- accessed.
- */
- bool mbViewShellValid;
-
/** Initialize the object iterator. Call this method after being
invoked from the search or spellcheck dialog. It creates a new
iterator pointing at the current object when this has not been done