diff options
Diffstat (limited to 'include/svtools/treelistbox.hxx')
-rw-r--r-- | include/svtools/treelistbox.hxx | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/include/svtools/treelistbox.hxx b/include/svtools/treelistbox.hxx index 3f74b4c7fa37..7d55c17ad403 100644 --- a/include/svtools/treelistbox.hxx +++ b/include/svtools/treelistbox.hxx @@ -373,6 +373,7 @@ public: SvTreeListBox( vcl::Window* pParent, WinBits nWinStyle=0 ); SvTreeListBox( vcl::Window* pParent, const ResId& rResId ); virtual ~SvTreeListBox(); + virtual void dispose() SAL_OVERRIDE; SvTreeList* GetModel() const { @@ -385,11 +386,11 @@ public: sal_uLong GetEntryCount() const { - return pModel->GetEntryCount(); + return pModel ? pModel->GetEntryCount() : 0; } SvTreeListEntry* First() const { - return pModel->First(); + return pModel ? pModel->First() : NULL; } SvTreeListEntry* Next( SvTreeListEntry* pEntry, sal_uInt16* pDepth = 0 ) const { @@ -401,7 +402,7 @@ public: } SvTreeListEntry* Last() const { - return pModel->Last(); + return pModel ? pModel->Last() : NULL; } SvTreeListEntry* FirstChild( SvTreeListEntry* pParent ) const; @@ -820,7 +821,7 @@ public: struct SvLBoxDDInfo { Application* pApp; - SvTreeListBox* pSource; + VclPtr<SvTreeListBox> pSource; SvTreeListEntry* pDDStartEntry; // Relative position in the Entry at DragBeginn (IconView) long nMouseRelX,nMouseRelY; @@ -833,7 +834,7 @@ class SvInplaceEdit2 Accelerator aAccReturn; Accelerator aAccEscape; Idle aIdle; - Edit* pEdit; + VclPtr<Edit> pEdit; bool bCanceled; bool bAlreadyInCallBack; |