[Libreoffice-commits] core.git: Branch 'feature/vclref' - 5 commits - avmedia/inc avmedia/source basic/source framework/inc framework/source include/avmedia include/sfx2 include/svx sfx2/inc sfx2/source svx/inc svx/source
Noel Grandin
noel at peralex.com
Tue Jan 13 04:53:20 PST 2015
avmedia/inc/mediacontrol.hxx | 13
avmedia/source/framework/mediacontrol.cxx | 276 +++++----
avmedia/source/framework/mediaplayer.cxx | 6
avmedia/source/framework/mediatoolbox.cxx | 7
avmedia/source/viewer/mediawindow_impl.cxx | 18
avmedia/source/viewer/mediawindow_impl.hxx | 3
basic/source/runtime/inputbox.cxx | 61 +-
basic/source/runtime/iosys.cxx | 38 -
framework/inc/classes/fwktabwindow.hxx | 6
framework/inc/uielement/statusbar.hxx | 1
framework/source/classes/fwktabwindow.cxx | 51 +
framework/source/uielement/comboboxtoolbarcontroller.cxx | 7
framework/source/uielement/dropdownboxtoolbarcontroller.cxx | 7
framework/source/uielement/edittoolbarcontroller.cxx | 7
framework/source/uielement/spinfieldtoolbarcontroller.cxx | 7
framework/source/uielement/statusbar.cxx | 4
include/avmedia/mediaplayer.hxx | 1
include/sfx2/basedlgs.hxx | 4
include/sfx2/dinfdlg.hxx | 54 -
include/sfx2/dockwin.hxx | 1
include/sfx2/infobar.hxx | 2
include/sfx2/mgetempl.hxx | 1
include/sfx2/new.hxx | 1
include/sfx2/newstyle.hxx | 3
include/sfx2/printopt.hxx | 1
include/sfx2/prnmon.hxx | 1
include/sfx2/recentdocsview.hxx | 1
include/sfx2/securitypage.hxx | 1
include/sfx2/sidebar/SidebarToolBox.hxx | 1
include/sfx2/styledlg.hxx | 1
include/sfx2/tabdlg.hxx | 2
include/sfx2/taskpane.hxx | 7
include/sfx2/tbxctrl.hxx | 1
include/sfx2/templateabstractview.hxx | 7
include/sfx2/templatedefaultview.hxx | 1
include/sfx2/templatedlg.hxx | 3
include/sfx2/templateinfodlg.hxx | 3
include/sfx2/templatelocalview.hxx | 1
include/sfx2/templateremoteview.hxx | 2
include/sfx2/templdlg.hxx | 1
include/sfx2/thumbnailview.hxx | 1
include/sfx2/titledockwin.hxx | 14
include/svx/bmpmask.hxx | 1
include/svx/charmap.hxx | 6
include/svx/checklbx.hxx | 1
include/svx/compressgraphicdialog.hxx | 2
include/svx/connctrl.hxx | 1
include/svx/contdlg.hxx | 1
include/svx/ctredlin.hxx | 3
include/svx/dialcontrol.hxx | 2
include/svx/dlgctl3d.hxx | 17
include/svx/dlgctrl.hxx | 8
include/svx/float3d.hxx | 25
include/svx/fmgridcl.hxx | 1
include/svx/fntctrl.hxx | 1
include/svx/fontwork.hxx | 31 -
include/svx/fontworkgallery.hxx | 1
include/svx/frmdirlbox.hxx | 1
include/svx/frmsel.hxx | 1
include/svx/galctrl.hxx | 4
include/svx/graphctl.hxx | 5
include/svx/gridctrl.hxx | 31 -
include/svx/hdft.hxx | 1
include/svx/imapdlg.hxx | 1
include/svx/langbox.hxx | 2
include/svx/linkwarn.hxx | 1
include/svx/measctrl.hxx | 1
include/svx/pagectrl.hxx | 1
include/svx/passwd.hxx | 1
include/svx/prtqry.hxx | 1
include/svx/rubydialog.hxx | 3
include/svx/ruler.hxx | 1
include/svx/srchdlg.hxx | 1
include/svx/stddlg.hxx | 1
sfx2/inc/srchdlg.hxx | 7
sfx2/source/appl/newhelp.cxx | 172 +++---
sfx2/source/appl/newhelp.hxx | 27
sfx2/source/control/recentdocsview.cxx | 4
sfx2/source/control/templateabstractview.cxx | 36 -
sfx2/source/control/templatedefaultview.cxx | 4
sfx2/source/control/templatelocalview.cxx | 18
sfx2/source/control/templateremoteview.cxx | 6
sfx2/source/control/templatesearchview.cxx | 4
sfx2/source/control/thumbnailview.cxx | 6
sfx2/source/control/thumbnailviewitem.cxx | 5
sfx2/source/dialog/alienwarn.cxx | 6
sfx2/source/dialog/backingwindow.cxx | 6
sfx2/source/dialog/backingwindow.hxx | 1
sfx2/source/dialog/basedlgs.cxx | 36 -
sfx2/source/dialog/dinfdlg.cxx | 338 ++++++------
sfx2/source/dialog/dockwin.cxx | 15
sfx2/source/dialog/infobar.cxx | 18
sfx2/source/dialog/mgetempl.cxx | 11
sfx2/source/dialog/newstyle.cxx | 13
sfx2/source/dialog/partwnd.cxx | 6
sfx2/source/dialog/printopt.cxx | 4
sfx2/source/dialog/recfloat.cxx | 6
sfx2/source/dialog/securitypage.cxx | 4
sfx2/source/dialog/splitwin.cxx | 9
sfx2/source/dialog/srchdlg.cxx | 6
sfx2/source/dialog/styledlg.cxx | 6
sfx2/source/dialog/tabdlg.cxx | 14
sfx2/source/dialog/taskpane.cxx | 66 +-
sfx2/source/dialog/templateinfodlg.cxx | 6
sfx2/source/dialog/templdlg.cxx | 235 ++++----
sfx2/source/dialog/titledockwin.cxx | 45 -
sfx2/source/dialog/versdlg.cxx | 12
sfx2/source/doc/doctemplates.cxx | 9
sfx2/source/doc/new.cxx | 6
sfx2/source/doc/templatedlg.cxx | 8
sfx2/source/inc/alienwarn.hxx | 1
sfx2/source/inc/partwnd.hxx | 1
sfx2/source/inc/recfloat.hxx | 1
sfx2/source/inc/splitwin.hxx | 1
sfx2/source/inc/templatesearchview.hxx | 2
sfx2/source/inc/templdgi.hxx | 13
sfx2/source/inc/versdlg.hxx | 2
sfx2/source/sidebar/Deck.cxx | 15
sfx2/source/sidebar/Deck.hxx | 2
sfx2/source/sidebar/DeckTitleBar.cxx | 17
sfx2/source/sidebar/DeckTitleBar.hxx | 1
sfx2/source/sidebar/MenuButton.cxx | 7
sfx2/source/sidebar/MenuButton.hxx | 1
sfx2/source/sidebar/Panel.cxx | 11
sfx2/source/sidebar/Panel.hxx | 1
sfx2/source/sidebar/PanelTitleBar.cxx | 23
sfx2/source/sidebar/PanelTitleBar.hxx | 1
sfx2/source/sidebar/SidebarDockingWindow.cxx | 6
sfx2/source/sidebar/SidebarDockingWindow.hxx | 1
sfx2/source/sidebar/SidebarToolBox.cxx | 8
sfx2/source/sidebar/TabBar.cxx | 8
sfx2/source/sidebar/TabBar.hxx | 1
sfx2/source/sidebar/TabItem.cxx | 7
sfx2/source/sidebar/TabItem.hxx | 1
sfx2/source/sidebar/TitleBar.cxx | 24
sfx2/source/sidebar/TitleBar.hxx | 7
sfx2/source/toolbox/tbxitem.cxx | 6
sfx2/source/view/frame2.cxx | 5
sfx2/source/view/printer.cxx | 6
svx/inc/GalleryControl.hxx | 1
svx/inc/galbrws2.hxx | 10
svx/inc/svdibrow.hxx | 13
svx/source/dialog/_bmpmask.cxx | 6
svx/source/dialog/_contdlg.cxx | 10
svx/source/dialog/charmap.cxx | 55 +
svx/source/dialog/checklbx.cxx | 6
svx/source/dialog/compressgraphicdialog.cxx | 4
svx/source/dialog/connctrl.cxx | 6
svx/source/dialog/contimp.hxx | 1
svx/source/dialog/contwnd.cxx | 4
svx/source/dialog/contwnd.hxx | 1
svx/source/dialog/ctredlin.cxx | 18
svx/source/dialog/dialcontrol.cxx | 4
svx/source/dialog/dlgctl3d.cxx | 142 ++---
svx/source/dialog/dlgctrl.cxx | 44 +
svx/source/dialog/docrecovery.cxx | 21
svx/source/dialog/fntctrl.cxx | 6
svx/source/dialog/fontwork.cxx | 322 ++++++-----
svx/source/dialog/frmdirlbox.cxx | 4
svx/source/dialog/frmsel.cxx | 5
svx/source/dialog/graphctl.cxx | 6
svx/source/dialog/hdft.cxx | 6
svx/source/dialog/imapdlg.cxx | 6
svx/source/dialog/imapwnd.cxx | 6
svx/source/dialog/imapwnd.hxx | 1
svx/source/dialog/langbox.cxx | 10
svx/source/dialog/linkwarn.cxx | 6
svx/source/dialog/measctrl.cxx | 6
svx/source/dialog/pagectrl.cxx | 6
svx/source/dialog/passwd.cxx | 7
svx/source/dialog/prtqry.cxx | 5
svx/source/dialog/rubydialog.cxx | 6
svx/source/dialog/srchdlg.cxx | 6
svx/source/dialog/stddlg.cxx | 4
svx/source/dialog/svxruler.cxx | 6
svx/source/engine3d/float3d.cxx | 105 ++-
svx/source/fmcomp/fmgridcl.cxx | 6
svx/source/fmcomp/gridctrl.cxx | 328 ++++++-----
svx/source/form/datanavi.cxx | 48 +
svx/source/form/fmexpl.cxx | 6
svx/source/form/navigatortree.cxx | 6
svx/source/form/tbxform.cxx | 5
svx/source/gallery2/GalleryControl.cxx | 18
svx/source/gallery2/galbrws1.cxx | 29 -
svx/source/gallery2/galbrws1.hxx | 5
svx/source/gallery2/galbrws2.cxx | 112 ++-
svx/source/gallery2/galctrl.cxx | 8
svx/source/inc/datanavi.hxx | 11
svx/source/inc/docrecovery.hxx | 10
svx/source/inc/fmexpl.hxx | 2
svx/source/inc/tbxform.hxx | 1
svx/source/svdraw/svdibrow.cxx | 28
svx/source/svdraw/svdpntv.cxx | 1
svx/source/tbxctrls/colorwindow.hxx | 1
svx/source/tbxctrls/fontworkgallery.cxx | 6
svx/source/tbxctrls/tbcontrl.cxx | 134 ++--
196 files changed, 2146 insertions(+), 1635 deletions(-)
New commits:
commit 71c75635291a2027c9f34f126ad6404a00bf049d
Author: Noel Grandin <noel at peralex.com>
Date: Tue Jan 13 14:52:40 2015 +0200
vcl: VclPtr conversion in svx (part1)
Change-Id: I3a1000baa049b11728c46efbc2f0af0d8f34cf2b
diff --git a/include/avmedia/mediaplayer.hxx b/include/avmedia/mediaplayer.hxx
index 101c6c6..bb24bd0 100644
--- a/include/avmedia/mediaplayer.hxx
+++ b/include/avmedia/mediaplayer.hxx
@@ -45,6 +45,7 @@ public:
MediaFloater( SfxBindings* pBindings, SfxChildWindow* pCW, vcl::Window* pParent );
virtual ~MediaFloater();
+ virtual void dispose() SAL_OVERRIDE;
void setURL( const OUString& rURL, const OUString& rReferer, bool bPlayImmediately );
diff --git a/include/svx/bmpmask.hxx b/include/svx/bmpmask.hxx
index 8ee7e7c..52e4f15 100644
--- a/include/svx/bmpmask.hxx
+++ b/include/svx/bmpmask.hxx
@@ -139,6 +139,7 @@ public:
SvxBmpMask(SfxBindings *pBindinx, SfxChildWindow *pCW, vcl::Window* pParent);
virtual ~SvxBmpMask();
+ virtual void dispose() SAL_OVERRIDE;
void SetColor( const Color& rColor );
void PipetteClicked();
diff --git a/include/svx/charmap.hxx b/include/svx/charmap.hxx
index 7810dda..1fc36bc 100644
--- a/include/svx/charmap.hxx
+++ b/include/svx/charmap.hxx
@@ -22,6 +22,7 @@
#include <vcl/ctrl.hxx>
#include <vcl/metric.hxx>
#include <vcl/scrbar.hxx>
+#include <vcl/vclptr.hxx>
#include <boost/shared_ptr.hpp>
#include <map>
#include <svx/svxdllapi.h>
@@ -44,6 +45,7 @@ class SVX_DLLPUBLIC SvxShowCharSet : public Control
public:
SvxShowCharSet( vcl::Window* pParent );
virtual ~SvxShowCharSet();
+ virtual void dispose() SAL_OVERRIDE;
void SetFont( const vcl::Font& rFont );
@@ -71,7 +73,7 @@ public:
sal_uInt16 GetRowPos(sal_uInt16 _nPos) const;
sal_uInt16 GetColumnPos(sal_uInt16 _nPos) const;
- ScrollBar& getScrollBar() { return aVscrollSB;}
+ ScrollBar& getScrollBar() { return *aVscrollSB.get();}
void ReleaseAccessible();
sal_Int32 getMaxCharCount() const;
@@ -112,7 +114,7 @@ private:
sal_Int32 nSelectedIndex;
FontCharMapPtr mpFontCharMap;
- ScrollBar aVscrollSB;
+ VclPtr<ScrollBar> aVscrollSB;
private:
void DrawChars_Impl( int n1, int n2);
diff --git a/include/svx/checklbx.hxx b/include/svx/checklbx.hxx
index a709487..46abeaf 100644
--- a/include/svx/checklbx.hxx
+++ b/include/svx/checklbx.hxx
@@ -46,6 +46,7 @@ public:
SvxCheckListBox( vcl::Window* pParent, WinBits nWinStyle = 0 );
void SetNormalStaticImage(const Image& rNormalStaticImage);
virtual ~SvxCheckListBox();
+ virtual void dispose() SAL_OVERRIDE;
void InsertEntry ( const OUString& rStr,
sal_uLong nPos = TREELIST_APPEND,
diff --git a/include/svx/compressgraphicdialog.hxx b/include/svx/compressgraphicdialog.hxx
index b8dcf80..83e1f66 100644
--- a/include/svx/compressgraphicdialog.hxx
+++ b/include/svx/compressgraphicdialog.hxx
@@ -84,8 +84,6 @@ public:
CompressGraphicsDialog( vcl::Window* pParent, SdrGrafObj* pGraphicObj, SfxBindings& rBindings );
CompressGraphicsDialog( vcl::Window* pParent, Graphic& rGraphic, Size rViewSize100mm, Rectangle& rCropRectangle, SfxBindings& rBindings );
- virtual ~CompressGraphicsDialog();
-
SdrGrafObj* GetCompressedSdrGrafObj();
Graphic GetCompressedGraphic();
diff --git a/include/svx/connctrl.hxx b/include/svx/connctrl.hxx
index 6caac03..f052915 100644
--- a/include/svx/connctrl.hxx
+++ b/include/svx/connctrl.hxx
@@ -46,6 +46,7 @@ private:
public:
SvxXConnectionPreview( vcl::Window* pParent, WinBits nStyle);
virtual ~SvxXConnectionPreview();
+ virtual void dispose() SAL_OVERRIDE;
virtual void Paint( const Rectangle& rRect ) SAL_OVERRIDE;
virtual void Resize() SAL_OVERRIDE;
diff --git a/include/svx/contdlg.hxx b/include/svx/contdlg.hxx
index f1192de..064d003 100644
--- a/include/svx/contdlg.hxx
+++ b/include/svx/contdlg.hxx
@@ -75,7 +75,6 @@ public:
SvxContourDlg(SfxBindings *pBindings, SfxChildWindow *pCW,
vcl::Window* pParent);
- virtual ~SvxContourDlg();
const Graphic& GetGraphic() const;
bool IsGraphicChanged() const;
diff --git a/include/svx/ctredlin.hxx b/include/svx/ctredlin.hxx
index 8d0f3191..f5fb266 100644
--- a/include/svx/ctredlin.hxx
+++ b/include/svx/ctredlin.hxx
@@ -114,6 +114,7 @@ public:
SvxRedlinTable(SvSimpleTableContainer& rParent, WinBits nBits = WB_BORDER);
virtual ~SvxRedlinTable();
+ virtual void dispose() SAL_OVERRIDE;
// For FilterPage only {
void SetFilterDate(bool bFlag=true);
@@ -316,6 +317,7 @@ private:
public:
SvxTPView(vcl::Window * pParent, VclBuilderContainer *pTopLevel);
virtual ~SvxTPView();
+ virtual void dispose() SAL_OVERRIDE;
void InsertWriterHeader();
void InsertCalcHeader();
@@ -376,6 +378,7 @@ public:
SvxAcceptChgCtr(vcl::Window* pParent, VclBuilderContainer* pTopLevel);
virtual ~SvxAcceptChgCtr();
+ virtual void dispose() SAL_OVERRIDE;
void ShowFilterPage();
void ShowViewPage();
diff --git a/include/svx/dialcontrol.hxx b/include/svx/dialcontrol.hxx
index 46ca48a..f322614 100644
--- a/include/svx/dialcontrol.hxx
+++ b/include/svx/dialcontrol.hxx
@@ -82,8 +82,6 @@ class SVX_DLLPUBLIC DialControl : public Control
public:
explicit DialControl( vcl::Window* pParent, WinBits nBits );
- virtual ~DialControl();
-
virtual void Paint( const Rectangle& rRect ) SAL_OVERRIDE;
virtual void StateChanged( StateChangedType nStateChange ) SAL_OVERRIDE;
diff --git a/include/svx/dlgctl3d.hxx b/include/svx/dlgctl3d.hxx
index 8d3901b..4513452 100644
--- a/include/svx/dlgctl3d.hxx
+++ b/include/svx/dlgctl3d.hxx
@@ -58,6 +58,7 @@ public:
Svx3DPreviewControl(vcl::Window* pParent, const ResId& rResId);
Svx3DPreviewControl(vcl::Window* pParent, WinBits nStyle = 0);
virtual ~Svx3DPreviewControl();
+ virtual void dispose() SAL_OVERRIDE;
virtual void Paint( const Rectangle& rRect ) SAL_OVERRIDE;
virtual void MouseButtonDown( const MouseEvent& rMEvt ) SAL_OVERRIDE;
@@ -112,7 +113,6 @@ class SVX_DLLPUBLIC Svx3DLightControl : public Svx3DPreviewControl
public:
Svx3DLightControl(vcl::Window* pParent, WinBits nStyle = 0);
- virtual ~Svx3DLightControl();
virtual void Paint(const Rectangle& rRect) SAL_OVERRIDE;
virtual void MouseButtonDown(const MouseEvent& rMEvt) SAL_OVERRIDE;
@@ -155,19 +155,20 @@ class SVX_DLLPUBLIC SvxLightCtl3D : public Control
{
private:
// local controls
- Svx3DLightControl maLightControl;
- ScrollBar maHorScroller;
- ScrollBar maVerScroller;
- PushButton maSwitcher;
+ VclPtr<Svx3DLightControl> maLightControl;
+ VclPtr<ScrollBar> maHorScroller;
+ VclPtr<ScrollBar> maVerScroller;
+ VclPtr<PushButton> maSwitcher;
// callback for interactive changes
- Link maUserInteractiveChangeCallback;
- Link maUserSelectionChangeCallback;
+ Link maUserInteractiveChangeCallback;
+ Link maUserSelectionChangeCallback;
public:
SvxLightCtl3D( vcl::Window* pParent, const ResId& rResId);
SvxLightCtl3D( vcl::Window* pParent);
virtual ~SvxLightCtl3D();
+ virtual void dispose() SAL_OVERRIDE;
// react to size changes
virtual void Resize() SAL_OVERRIDE;
@@ -177,7 +178,7 @@ public:
void CheckSelection();
// bring further settings to the outside world
- Svx3DLightControl& GetSvx3DLightControl() { return maLightControl; }
+ Svx3DLightControl& GetSvx3DLightControl() { return *maLightControl.get(); }
// register user callback
void SetUserInteractiveChangeCallback(Link aNew) { maUserInteractiveChangeCallback = aNew; }
diff --git a/include/svx/dlgctrl.hxx b/include/svx/dlgctrl.hxx
index 21cba25..e18d4d6 100644
--- a/include/svx/dlgctrl.hxx
+++ b/include/svx/dlgctrl.hxx
@@ -100,6 +100,7 @@ public:
void SetControlSettings(RECT_POINT eRpt = RP_MM, sal_uInt16 nBorder = 200,
sal_uInt16 nCircle = 80, CTL_STYLE eStyle = CS_RECT);
virtual ~SvxRectCtl();
+ virtual void dispose() SAL_OVERRIDE;
virtual void Paint( const Rectangle& rRect ) SAL_OVERRIDE;
virtual void MouseButtonDown( const MouseEvent& rMEvt ) SAL_OVERRIDE;
@@ -179,6 +180,7 @@ public:
SvxPixelCtl( vcl::Window* pParent, sal_uInt16 nNumber = 8 );
virtual ~SvxPixelCtl();
+ virtual void dispose() SAL_OVERRIDE;
virtual void Paint( const Rectangle& rRect ) SAL_OVERRIDE;
virtual void MouseButtonDown( const MouseEvent& rMEvt ) SAL_OVERRIDE;
@@ -322,7 +324,6 @@ private:
public:
LineLB(vcl::Window* pParent, WinBits aWB);
- virtual ~LineLB();
virtual void Fill(const XDashListRef &pList);
bool getAddStandardFields() const { return mbAddStandardFields; }
@@ -341,7 +342,6 @@ class SVX_DLLPUBLIC LineEndLB : public ListBox
public:
LineEndLB( vcl::Window* pParent, WinBits aWB );
- virtual ~LineEndLB (void);
virtual void Fill( const XLineEndListRef &pList, bool bStart = true );
@@ -373,6 +373,7 @@ protected:
public:
SvxPreviewBase(vcl::Window* pParent);
virtual ~SvxPreviewBase();
+ virtual void dispose() SAL_OVERRIDE;
// change support
virtual void StateChanged(StateChangedType nStateChange) SAL_OVERRIDE;
@@ -403,6 +404,7 @@ private:
public:
SvxXLinePreview( vcl::Window* pParent );
virtual ~SvxXLinePreview();
+ virtual void dispose() SAL_OVERRIDE;
void SetLineAttributes(const SfxItemSet& rItemSet);
@@ -429,6 +431,7 @@ private:
public:
SvxXRectPreview(vcl::Window* pParent);
virtual ~SvxXRectPreview();
+ virtual void dispose() SAL_OVERRIDE;
void SetAttributes(const SfxItemSet& rItemSet);
@@ -454,6 +457,7 @@ public:
SvxXShadowPreview(vcl::Window *pParent);
virtual ~SvxXShadowPreview();
+ virtual void dispose() SAL_OVERRIDE;
void SetRectangleAttributes(const SfxItemSet& rItemSet);
void SetShadowAttributes(const SfxItemSet& rItemSet);
diff --git a/include/svx/float3d.hxx b/include/svx/float3d.hxx
index 610ec06..398fd69 100644
--- a/include/svx/float3d.hxx
+++ b/include/svx/float3d.hxx
@@ -60,13 +60,13 @@ class SVX_DLLPUBLIC Svx3DWin : public SfxDockingWindow
using Window::Update;
private:
- ImageButton aBtnGeo;
- ImageButton aBtnRepresentation;
- ImageButton aBtnLight;
- ImageButton aBtnTexture;
- ImageButton aBtnMaterial;
- ImageButton aBtnUpdate;
- ImageButton aBtnAssign;
+ VclPtr<ImageButton> aBtnGeo;
+ VclPtr<ImageButton> aBtnRepresentation;
+ VclPtr<ImageButton> aBtnLight;
+ VclPtr<ImageButton> aBtnTexture;
+ VclPtr<ImageButton> aBtnMaterial;
+ VclPtr<ImageButton> aBtnUpdate;
+ VclPtr<ImageButton> aBtnAssign;
// geometry
FixedLine aFLGeometrie;
@@ -78,13 +78,13 @@ private:
MetricField aMtrEndAngle;
FixedText aFtDepth;
MetricField aMtrDepth;
- FixedLine aFLSegments;
+ FixedLine aFLSegments;
FixedText aFtHorizontal;
NumericField aNumHorizontal;
FixedText aFtVertical;
NumericField aNumVertical;
- FixedLine aFLNormals;
+ FixedLine aFLNormals;
ImageButton aBtnNormalsObj;
ImageButton aBtnNormalsFlat;
@@ -135,7 +135,7 @@ private:
ColorLB aLbAmbientlight; // ListBox
ImageButton aBtnAmbientColor; // color button
- FixedLine aFLTexture;
+ FixedLine aFLTexture;
// Textures
FixedText aFtTexKind;
@@ -158,7 +158,7 @@ private:
// material
// material editor
- FixedLine aFLMaterial;
+ FixedLine aFLMaterial;
FixedText aFtMatFavorites;
ListBox aLbMatFavorites;
FixedText aFtMatColor;
@@ -167,7 +167,7 @@ private:
FixedText aFtMatEmission;
ColorLB aLbMatEmission;
ImageButton aBtnEmissionColor;
- FixedLine aFLMatSpecular;
+ FixedLine aFLMatSpecular;
FixedText aFtMatSpecular;
ColorLB aLbMatSpecular;
ImageButton aBtnSpecularColor;
@@ -240,6 +240,7 @@ public:
Svx3DWin( SfxBindings* pBindings, SfxChildWindow *pCW,
vcl::Window* pParent );
virtual ~Svx3DWin();
+ virtual void dispose() SAL_OVERRIDE;
void InitColorLB( const SdrModel* pDoc );
bool IsUpdateMode() const { return bUpdate; }
diff --git a/include/svx/fmgridcl.hxx b/include/svx/fmgridcl.hxx
index f373f5e..5517a27 100644
--- a/include/svx/fmgridcl.hxx
+++ b/include/svx/fmgridcl.hxx
@@ -43,6 +43,7 @@ protected:
public:
FmGridHeader( BrowseBox* pParent, WinBits nWinBits = WB_STDHEADERBAR | WB_DRAG );
virtual ~FmGridHeader();
+ virtual void dispose() SAL_OVERRIDE;
public:
struct AccessControl { friend class FmGridControl; private: AccessControl() { } };
diff --git a/include/svx/fntctrl.hxx b/include/svx/fntctrl.hxx
index 0c9461f..1a2c1db 100644
--- a/include/svx/fntctrl.hxx
+++ b/include/svx/fntctrl.hxx
@@ -49,6 +49,7 @@ public:
SvxFontPrevWindow( vcl::Window* pParent, const ResId& rId );
SvxFontPrevWindow(vcl::Window* pParent, WinBits nStyle);
virtual ~SvxFontPrevWindow();
+ virtual void dispose() SAL_OVERRIDE;
virtual void StateChanged( StateChangedType nStateChange ) SAL_OVERRIDE;
virtual void DataChanged( const DataChangedEvent& rDCEvt ) SAL_OVERRIDE;
diff --git a/include/svx/fontwork.hxx b/include/svx/fontwork.hxx
index ac91d4c..e425742 100644
--- a/include/svx/fontwork.hxx
+++ b/include/svx/fontwork.hxx
@@ -91,29 +91,29 @@ class SVX_DLLPUBLIC SvxFontWorkDialog : public SfxDockingWindow
SvxFontWorkControllerItem* pCtrlItems[CONTROLLER_COUNT];
- ToolBox aTbxStyle;
- ToolBox aTbxAdjust;
+ VclPtr<ToolBox> aTbxStyle;
+ VclPtr<ToolBox> aTbxAdjust;
- FixedImage aFbDistance;
- MetricField aMtrFldDistance;
- FixedImage aFbTextStart;
- MetricField aMtrFldTextStart;
+ VclPtr<FixedImage> aFbDistance;
+ VclPtr<MetricField> aMtrFldDistance;
+ VclPtr<FixedImage> aFbTextStart;
+ VclPtr<MetricField> aMtrFldTextStart;
- ToolBox aTbxShadow;
+ VclPtr<ToolBox> aTbxShadow;
- FixedImage aFbShadowX;
- MetricField aMtrFldShadowX;
- FixedImage aFbShadowY;
- MetricField aMtrFldShadowY;
+ VclPtr<FixedImage> aFbShadowX;
+ VclPtr<MetricField> aMtrFldShadowX;
+ VclPtr<FixedImage> aFbShadowY;
+ VclPtr<MetricField> aMtrFldShadowY;
- ColorLB aShadowColorLB;
+ VclPtr<ColorLB> aShadowColorLB;
SfxBindings& rBindings;
Idle aInputIdle;
- sal_uInt16 nLastStyleTbxId;
- sal_uInt16 nLastAdjustTbxId;
- sal_uInt16 nLastShadowTbxId;
+ sal_uInt16 nLastStyleTbxId;
+ sal_uInt16 nLastAdjustTbxId;
+ sal_uInt16 nLastShadowTbxId;
long nSaveShadowX;
long nSaveShadowY;
long nSaveShadowAngle;
@@ -161,6 +161,7 @@ class SVX_DLLPUBLIC SvxFontWorkDialog : public SfxDockingWindow
vcl::Window* pParent,
const ResId& rResId );
virtual ~SvxFontWorkDialog();
+ virtual void dispose() SAL_OVERRIDE;
void SetColorList(const XColorListRef &pTable);
void SetActive(bool bActivate = true);
diff --git a/include/svx/fontworkgallery.hxx b/include/svx/fontworkgallery.hxx
index 7bd4534..c2521a7 100644
--- a/include/svx/fontworkgallery.hxx
+++ b/include/svx/fontworkgallery.hxx
@@ -98,7 +98,6 @@ class SVX_DLLPUBLIC FontWorkGalleryDialog : public ModalDialog
public:
FontWorkGalleryDialog( SdrView* pView, vcl::Window* pParent, sal_uInt16 nSID );
- virtual ~FontWorkGalleryDialog();
// SJ: if the SdrObject** is set, the SdrObject is not inserted into the page when executing the dialog
void SetSdrObjectRef( SdrObject**, SdrModel* pModel );
diff --git a/include/svx/frmdirlbox.hxx b/include/svx/frmdirlbox.hxx
index 80bd1b1..c7145e8 100644
--- a/include/svx/frmdirlbox.hxx
+++ b/include/svx/frmdirlbox.hxx
@@ -40,7 +40,6 @@ class SVX_DLLPUBLIC FrameDirectionListBox : public ListBox
{
public:
explicit FrameDirectionListBox( vcl::Window* pParent, WinBits nBits );
- virtual ~FrameDirectionListBox();
/** Inserts a string with corresponding direction enum into the listbox. */
void InsertEntryValue(
diff --git a/include/svx/frmsel.hxx b/include/svx/frmsel.hxx
index e92271b..61b3615 100644
--- a/include/svx/frmsel.hxx
+++ b/include/svx/frmsel.hxx
@@ -84,7 +84,6 @@ class SVX_DLLPUBLIC FrameSelector : public Control
{
public:
FrameSelector(vcl::Window* pParent);
- virtual ~FrameSelector();
/** Initializes the control, enables/disables frame borders according to flags. */
void Initialize( FrameSelFlags nFlags );
diff --git a/include/svx/galctrl.hxx b/include/svx/galctrl.hxx
index 4abfde1..98cda40 100644
--- a/include/svx/galctrl.hxx
+++ b/include/svx/galctrl.hxx
@@ -109,7 +109,6 @@ private:
public:
GalleryIconView( GalleryBrowser2* pParent, GalleryTheme* pTheme );
- virtual ~GalleryIconView();
};
class GalleryListView : public BrowseBox
@@ -121,7 +120,7 @@ private:
Link maSelectHdl;
GalleryTheme* mpTheme;
- sal_uIntPtr mnCurRow;
+ sal_uIntPtr mnCurRow;
void InitSettings();
@@ -144,7 +143,6 @@ private:
public:
GalleryListView( GalleryBrowser2* pParent, GalleryTheme* pTheme );
- virtual ~GalleryListView();
void SetSelectHdl( const Link& rSelectHdl ) { maSelectHdl = rSelectHdl; }
diff --git a/include/svx/graphctl.hxx b/include/svx/graphctl.hxx
index a2863d0..2b6c440 100644
--- a/include/svx/graphctl.hxx
+++ b/include/svx/graphctl.hxx
@@ -80,8 +80,9 @@ protected:
public:
- GraphCtrl( vcl::Window* pParent, WinBits nStyle );
- virtual ~GraphCtrl();
+ GraphCtrl( vcl::Window* pParent, WinBits nStyle );
+ virtual ~GraphCtrl();
+ virtual void dispose() SAL_OVERRIDE;
void SetWinStyle( WinBits nWinBits );
WinBits GetWinStyle() const { return nWinStyle; }
diff --git a/include/svx/gridctrl.hxx b/include/svx/gridctrl.hxx
index 3aaecfe..d43b1ee 100644
--- a/include/svx/gridctrl.hxx
+++ b/include/svx/gridctrl.hxx
@@ -151,20 +151,20 @@ public:
friend class NavigationBar::AbsolutePos;
// zusaetzliche Controls
- FixedText m_aRecordText;
- AbsolutePos m_aAbsolute; // absolute positioning
- FixedText m_aRecordOf;
- FixedText m_aRecordCount;
+ VclPtr<FixedText> m_aRecordText;
+ VclPtr<AbsolutePos> m_aAbsolute; // absolute positioning
+ VclPtr<FixedText> m_aRecordOf;
+ VclPtr<FixedText> m_aRecordCount;
- ImageButton m_aFirstBtn; // ImageButton for 'go to the first record'
- ImageButton m_aPrevBtn; // ImageButton for 'go to the previous record'
- ImageButton m_aNextBtn; // ImageButton for 'go to the next record'
- ImageButton m_aLastBtn; // ImageButton for 'go to the last record'
- ImageButton m_aNewBtn; // ImageButton for 'go to a new record'
- sal_uInt16 m_nDefaultWidth;
- sal_Int32 m_nCurrentPos;
+ VclPtr<ImageButton> m_aFirstBtn; // ImageButton for 'go to the first record'
+ VclPtr<ImageButton> m_aPrevBtn; // ImageButton for 'go to the previous record'
+ VclPtr<ImageButton> m_aNextBtn; // ImageButton for 'go to the next record'
+ VclPtr<ImageButton> m_aLastBtn; // ImageButton for 'go to the last record'
+ VclPtr<ImageButton> m_aNewBtn; // ImageButton for 'go to a new record'
+ sal_uInt16 m_nDefaultWidth;
+ sal_Int32 m_nCurrentPos;
- bool m_bPositioning; // protect PositionDataSource against recursion
+ bool m_bPositioning; // protect PositionDataSource against recursion
public:
// StatusIds for Controls of the Bar
@@ -183,6 +183,8 @@ public:
};
NavigationBar(vcl::Window* pParent, WinBits nStyle = 0);
+ virtual ~NavigationBar();
+ virtual void dispose() SAL_OVERRIDE;
// Status methods for Controls
void InvalidateAll(sal_Int32 nCurrentPos = -1, bool bAll = false);
@@ -225,7 +227,7 @@ private:
::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext > m_xContext;
DbGridColumns m_aColumns; // Column description
- NavigationBar m_aBar;
+ VclPtr<NavigationBar> m_aBar;
DbGridRowRef m_xDataRow; // Row which can be modified
// comes from the data cursor
DbGridRowRef m_xSeekRow, // Row to which the iterator can set
@@ -370,6 +372,7 @@ public:
WinBits nBits = WB_BORDER);
virtual ~DbGridControl();
+ virtual void dispose() SAL_OVERRIDE;
virtual void Init() SAL_OVERRIDE;
virtual void InitColumnsByFields(const ::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexAccess >& xFields) = 0;
@@ -431,7 +434,7 @@ public:
bool HasNavigationBar() const {return m_bNavigationBar;}
sal_uInt16 GetOptions() const {return m_nOptions;}
- NavigationBar& GetNavigationBar() {return m_aBar;}
+ NavigationBar& GetNavigationBar() {return *m_aBar.get();}
sal_uInt16 SetOptions(sal_uInt16 nOpt);
// The new options are interpreted with respect to the current data source. If it is unable
// to update, to insert or to restore, the according options are ignored. If the grid isn't
diff --git a/include/svx/hdft.hxx b/include/svx/hdft.hxx
index d7f15be..f03cdfa 100644
--- a/include/svx/hdft.hxx
+++ b/include/svx/hdft.hxx
@@ -52,6 +52,7 @@ public:
virtual void Reset( const SfxItemSet* rSet ) SAL_OVERRIDE;
virtual ~SvxHFPage();
+ virtual void dispose() SAL_OVERRIDE;
void DisableDeleteQueryBox() { mbDisableQueryBox = true; }
void EnableBackgroundSelector(bool bNew) { mbEnableBackgroundSelector = bNew; }
diff --git a/include/svx/imapdlg.hxx b/include/svx/imapdlg.hxx
index 5530488..e717b73 100644
--- a/include/svx/imapdlg.hxx
+++ b/include/svx/imapdlg.hxx
@@ -136,6 +136,7 @@ public:
SvxIMapDlg( SfxBindings *pBindings, SfxChildWindow *pCW,
vcl::Window* pParent );
virtual ~SvxIMapDlg();
+ virtual void dispose() SAL_OVERRIDE;
void SetExecState( bool bEnable );
diff --git a/include/svx/langbox.hxx b/include/svx/langbox.hxx
index da82e90..f6010ad 100644
--- a/include/svx/langbox.hxx
+++ b/include/svx/langbox.hxx
@@ -115,7 +115,6 @@ class SVX_DLLPUBLIC SvxLanguageBox : public ListBox, public SvxLanguageBoxBase
{
public:
SvxLanguageBox( vcl::Window* pParent, WinBits nBits, bool bCheck = false );
- virtual ~SvxLanguageBox();
private:
SVX_DLLPRIVATE virtual sal_Int32 ImplInsertImgEntry( const OUString& rEntry, sal_Int32 nPos, bool bChecked ) SAL_OVERRIDE;
@@ -142,7 +141,6 @@ class SVX_DLLPUBLIC SvxLanguageComboBox : public ComboBox, public SvxLanguageBox
{
public:
SvxLanguageComboBox( vcl::Window* pParent, WinBits nBits, bool bCheck = false );
- virtual ~SvxLanguageComboBox();
enum EditedAndValid
{
diff --git a/include/svx/linkwarn.hxx b/include/svx/linkwarn.hxx
index 8fc66af..395b1b6 100644
--- a/include/svx/linkwarn.hxx
+++ b/include/svx/linkwarn.hxx
@@ -32,6 +32,7 @@ private:
public:
SvxLinkWarningDialog(vcl::Window* pParent, const OUString& _rFileName);
virtual ~SvxLinkWarningDialog();
+ virtual void dispose() SAL_OVERRIDE;
};
#endif // INCLUDED_SVX_LINKWARN_HXX
diff --git a/include/svx/measctrl.hxx b/include/svx/measctrl.hxx
index 83161ca..4753ab1 100644
--- a/include/svx/measctrl.hxx
+++ b/include/svx/measctrl.hxx
@@ -43,6 +43,7 @@ private:
public:
SvxXMeasurePreview(vcl::Window* pParent, WinBits nStyle);
virtual ~SvxXMeasurePreview();
+ virtual void dispose() SAL_OVERRIDE;
virtual void Paint(const Rectangle& rRect) SAL_OVERRIDE;
virtual void Resize() SAL_OVERRIDE;
diff --git a/include/svx/pagectrl.hxx b/include/svx/pagectrl.hxx
index 8b6da4d..007d4ca 100644
--- a/include/svx/pagectrl.hxx
+++ b/include/svx/pagectrl.hxx
@@ -89,6 +89,7 @@ protected:
public:
SvxPageWindow( vcl::Window* pParent );
virtual ~SvxPageWindow();
+ virtual void dispose() SAL_OVERRIDE;
//UUUU
void setHeaderFillAttributes(const drawinglayer::attribute::SdrAllFillAttributesHelperPtr& rFillAttributes) { maHeaderFillAttributes = rFillAttributes; }
diff --git a/include/svx/passwd.hxx b/include/svx/passwd.hxx
index 920fa19..901488c 100644
--- a/include/svx/passwd.hxx
+++ b/include/svx/passwd.hxx
@@ -52,7 +52,6 @@ private:
public:
SvxPasswordDialog( vcl::Window* pParent, bool bAllowEmptyPasswords = false, bool bDisableOldPassword = false );
- virtual ~SvxPasswordDialog();
OUString GetOldPassword() const { return m_pOldPasswdED->GetText(); }
OUString GetNewPassword() const { return m_pNewPasswdED->GetText(); }
diff --git a/include/svx/prtqry.hxx b/include/svx/prtqry.hxx
index afe6b9b..a2f4e92 100644
--- a/include/svx/prtqry.hxx
+++ b/include/svx/prtqry.hxx
@@ -26,7 +26,6 @@ class SVX_DLLPUBLIC SvxPrtQryBox : public MessBox
{
public:
SvxPrtQryBox(vcl::Window* pParent);
- virtual ~SvxPrtQryBox();
};
#endif
diff --git a/include/svx/rubydialog.hxx b/include/svx/rubydialog.hxx
index bd605a1..793fa88 100644
--- a/include/svx/rubydialog.hxx
+++ b/include/svx/rubydialog.hxx
@@ -143,7 +143,7 @@ class SvxRubyDialog : public SfxModelessDialog
void AssertOneEntry();
void Update();
- virtual bool Close() SAL_OVERRIDE;
+ virtual bool Close() SAL_OVERRIDE;
long GetLastPos() const {return nLastPos;}
void SetLastPos(long nSet) {nLastPos = nSet;}
@@ -163,6 +163,7 @@ public:
SvxRubyDialog(SfxBindings *pBindings, SfxChildWindow *pCW,
vcl::Window* pParent);
virtual ~SvxRubyDialog();
+ virtual void dispose() SAL_OVERRIDE;
virtual void Activate() SAL_OVERRIDE;
virtual void Deactivate() SAL_OVERRIDE;
diff --git a/include/svx/ruler.hxx b/include/svx/ruler.hxx
index 96f3012..6c22d58 100644
--- a/include/svx/ruler.hxx
+++ b/include/svx/ruler.hxx
@@ -254,6 +254,7 @@ public:
SvxRuler(vcl::Window* pParent, vcl::Window *pEditWin, sal_uInt16 nRulerFlags,
SfxBindings &rBindings, WinBits nWinStyle = WB_STDRULER);
virtual ~SvxRuler();
+ virtual void dispose() SAL_OVERRIDE;
void SetMinFrameSize(long lSize);
long GetMinFrameSize() const ;
diff --git a/include/svx/srchdlg.hxx b/include/svx/srchdlg.hxx
index 15d221b..35e259b 100644
--- a/include/svx/srchdlg.hxx
+++ b/include/svx/srchdlg.hxx
@@ -120,6 +120,7 @@ friend class SvxJSearchOptionsDialog;
public:
SvxSearchDialog( vcl::Window* pParent, SfxChildWindow* pChildWin, SfxBindings& rBind );
virtual ~SvxSearchDialog();
+ virtual void dispose() SAL_OVERRIDE;
virtual bool Close() SAL_OVERRIDE;
diff --git a/include/svx/stddlg.hxx b/include/svx/stddlg.hxx
index 85cdf46..a3e3df0 100644
--- a/include/svx/stddlg.hxx
+++ b/include/svx/stddlg.hxx
@@ -28,7 +28,6 @@ class SVX_DLLPUBLIC SvxStandardDialog: public SfxModalDialog
{
public:
SvxStandardDialog( vcl::Window* pParent, const OUString& rID, const OUString& rUIXMLDescription );
- virtual ~SvxStandardDialog();
short Execute() SAL_OVERRIDE;
diff --git a/svx/inc/GalleryControl.hxx b/svx/inc/GalleryControl.hxx
index 8b58d76..11445db 100644
--- a/svx/inc/GalleryControl.hxx
+++ b/svx/inc/GalleryControl.hxx
@@ -43,7 +43,6 @@ public:
GalleryControl (
SfxBindings* pBindings,
vcl::Window* pParentWindow);
- virtual ~GalleryControl (void);
bool GalleryKeyInput( const KeyEvent& rKEvt, vcl::Window* pWindow);
diff --git a/svx/inc/galbrws2.hxx b/svx/inc/galbrws2.hxx
index 4a77603..5d1b8a9 100644
--- a/svx/inc/galbrws2.hxx
+++ b/svx/inc/galbrws2.hxx
@@ -80,7 +80,6 @@ private:
public:
GalleryToolBox( GalleryBrowser2* pParent );
- virtual ~GalleryToolBox();
};
@@ -113,11 +112,11 @@ private:
GalleryIconView* mpIconView;
GalleryListView* mpListView;
GalleryPreview* mpPreview;
- GalleryToolBox maViewBox;
- FixedLine maSeparator;
- FixedText maInfoBar;
+ VclPtr<GalleryToolBox> maViewBox;
+ VclPtr<FixedLine> maSeparator;
+ VclPtr<FixedText> maInfoBar;
Point maDragStartPos;
- sal_uIntPtr mnCurActionPos;
+ sal_uIntPtr mnCurActionPos;
GalleryBrowserMode meMode;
GalleryBrowserMode meLastMode;
@@ -154,6 +153,7 @@ public:
GalleryBrowser2(vcl::Window* pParent, Gallery* pGallery);
virtual ~GalleryBrowser2();
+ virtual void dispose() SAL_OVERRIDE;
void SelectTheme( const OUString& rThemeName );
diff --git a/svx/inc/svdibrow.hxx b/svx/inc/svdibrow.hxx
index c2a032c..60426a3 100644
--- a/svx/inc/svdibrow.hxx
+++ b/svx/inc/svdibrow.hxx
@@ -68,6 +68,7 @@ protected:
public:
_SdrItemBrowserControl(vcl::Window* pParent, WinBits nBits=WB_3DLOOK|WB_BORDER|WB_TABSTOP);
virtual ~_SdrItemBrowserControl();
+ virtual void dispose() SAL_OVERRIDE;
void Clear();
void SetAttributes(const SfxItemSet* pAttr, const SfxItemSet* p2ndSet=NULL);
sal_uIntPtr GetCurrentPos() const;
@@ -98,17 +99,17 @@ public:
#define WB_STDSIZEABLEFLOATWIN (WB_STDFLOATWIN|WB_3DLOOK|WB_CLOSEABLE|WB_SIZEMOVE)
class _SdrItemBrowserWindow: public FloatingWindow {
- _SdrItemBrowserControl aBrowse;
+ VclPtr<_SdrItemBrowserControl> aBrowse;
public:
_SdrItemBrowserWindow(vcl::Window* pParent, WinBits nBits=WB_STDSIZEABLEDOCKWIN);
virtual ~_SdrItemBrowserWindow();
+ virtual void dispose() SAL_OVERRIDE;
virtual void Resize() SAL_OVERRIDE;
virtual void GetFocus() SAL_OVERRIDE;
- void Clear() { aBrowse.Clear(); }
- void SetAttributes(const SfxItemSet* pAttr, const SfxItemSet* p2ndSet=NULL) { aBrowse.SetAttributes(pAttr,p2ndSet); }
- void SetFloatingMode(bool /*bOn*/) {}
- const _SdrItemBrowserControl& GetBrowserControl() const { return aBrowse; }
- _SdrItemBrowserControl& GetBrowserControl() { return aBrowse; }
+ void Clear() { aBrowse->Clear(); }
+ void SetAttributes(const SfxItemSet* pAttr, const SfxItemSet* p2ndSet=NULL) { aBrowse->SetAttributes(pAttr,p2ndSet); }
+ const _SdrItemBrowserControl& GetBrowserControl() const { return *aBrowse.get(); }
+ _SdrItemBrowserControl& GetBrowserControl() { return *aBrowse.get(); }
};
class SdrView;
diff --git a/svx/source/dialog/_bmpmask.cxx b/svx/source/dialog/_bmpmask.cxx
index 75668ce..a03d482 100644
--- a/svx/source/dialog/_bmpmask.cxx
+++ b/svx/source/dialog/_bmpmask.cxx
@@ -485,12 +485,18 @@ SvxBmpMask::SvxBmpMask(SfxBindings *pBindinx, SfxChildWindow *pCW, vcl::Window*
SvxBmpMask::~SvxBmpMask()
{
+ dispose();
+}
+
+void SvxBmpMask::dispose()
+{
delete m_pQSet1;
delete m_pQSet2;
delete m_pQSet3;
delete m_pQSet4;
delete m_pCtlPipette;
delete pData;
+ SfxDockingWindow::dispose();
}
/** is called by a MaskSet when it is selected */
diff --git a/svx/source/dialog/_contdlg.cxx b/svx/source/dialog/_contdlg.cxx
index a2e3df8..58accc1 100644
--- a/svx/source/dialog/_contdlg.cxx
+++ b/svx/source/dialog/_contdlg.cxx
@@ -86,10 +86,6 @@ SvxContourDlg::SvxContourDlg(SfxBindings* _pBindings, SfxChildWindow* pCW,
{
}
-SvxContourDlg::~SvxContourDlg()
-{
-}
-
tools::PolyPolygon SvxContourDlg::CreateAutoContour( const Graphic& rGraphic,
const Rectangle* pRect,
const sal_uIntPtr nFlags )
@@ -282,9 +278,15 @@ SvxSuperContourDlg::SvxSuperContourDlg(SfxBindings *_pBindings, SfxChildWindow *
SvxSuperContourDlg::~SvxSuperContourDlg()
{
+ dispose();
+}
+
+void SvxSuperContourDlg::dispose()
+{
SvtMiscOptions aMiscOptions;
aMiscOptions.RemoveListenerLink( LINK(this, SvxSuperContourDlg, MiscHdl) );
delete m_pContourWnd;
+ SvxContourDlg::dispose();
}
bool SvxSuperContourDlg::Close()
diff --git a/svx/source/dialog/charmap.cxx b/svx/source/dialog/charmap.cxx
index d50bc44..fa098b1 100644
--- a/svx/source/dialog/charmap.cxx
+++ b/svx/source/dialog/charmap.cxx
@@ -56,7 +56,7 @@ sal_uInt32& SvxShowCharSet::getSelectedChar()
SvxShowCharSet::SvxShowCharSet(vcl::Window* pParent)
: Control(pParent, WB_TABSTOP | WB_BORDER)
, m_pAccessible(NULL)
- , aVscrollSB( this, WB_VERT)
+ , aVscrollSB( new ScrollBar(this, WB_VERT) )
{
init();
InitSettings( true, true );
@@ -69,8 +69,8 @@ void SvxShowCharSet::init()
m_nYGap = 0;
SetStyle( GetStyle() | WB_CLIPCHILDREN );
- aVscrollSB.SetScrollHdl( LINK( this, SvxShowCharSet, VscrollHdl ) );
- aVscrollSB.EnableDrag( true );
+ aVscrollSB->SetScrollHdl( LINK( this, SvxShowCharSet, VscrollHdl ) );
+ aVscrollSB->EnableDrag( true );
// other settings like aVscroll depend on selected font => see SetFont
bDrag = false;
@@ -190,7 +190,7 @@ void SvxShowCharSet::MouseMove( const MouseEvent& rMEvt )
void SvxShowCharSet::Command( const CommandEvent& rCEvt )
{
- if( !HandleScrollCommand( rCEvt, 0, &aVscrollSB ) )
+ if( !HandleScrollCommand( rCEvt, 0, aVscrollSB.get() ) )
Control::Command( rCEvt );
}
@@ -213,8 +213,8 @@ sal_uInt16 SvxShowCharSet::GetColumnPos(sal_uInt16 _nPos) const
int SvxShowCharSet::FirstInView( void ) const
{
int nIndex = 0;
- if( aVscrollSB.IsVisible() )
- nIndex += aVscrollSB.GetThumbPos() * COLUMN_COUNT;
+ if( aVscrollSB->IsVisible() )
+ nIndex += aVscrollSB->GetThumbPos() * COLUMN_COUNT;
return nIndex;
}
@@ -365,8 +365,8 @@ void SvxShowCharSet::DrawChars_Impl( int n1, int n2 )
return;
Size aOutputSize = GetOutputSizePixel();
- if (aVscrollSB.IsVisible())
- aOutputSize.Width() -= aVscrollSB.GetOptimalSize().Width();
+ if (aVscrollSB->IsVisible())
+ aOutputSize.Width() -= aVscrollSB->GetOptimalSize().Width();
int i;
for ( i = 1; i < COLUMN_COUNT; ++i )
@@ -513,7 +513,7 @@ void SvxShowCharSet::SetFont( const vcl::Font& rFont )
getSelectedChar() = mpFontCharMap->GetCharFromIndex( nSelectedIndex );
Size aSize = GetOutputSizePixel();
- long nSBWidth = aVscrollSB.GetOptimalSize().Width();
+ long nSBWidth = aVscrollSB->GetOptimalSize().Width();
aSize.Width() -= nSBWidth;
vcl::Font aFont = rFont;
@@ -528,18 +528,18 @@ void SvxShowCharSet::SetFont( const vcl::Font& rFont )
nX = aSize.Width() / COLUMN_COUNT;
nY = aSize.Height() / ROW_COUNT;
- aVscrollSB.setPosSizePixel( aSize.Width(), 0, nSBWidth, aSize.Height() );
- aVscrollSB.SetRangeMin( 0 );
+ aVscrollSB->setPosSizePixel( aSize.Width(), 0, nSBWidth, aSize.Height() );
+ aVscrollSB->SetRangeMin( 0 );
int nLastRow = (mpFontCharMap->GetCharCount() - 1 + COLUMN_COUNT) / COLUMN_COUNT;
- aVscrollSB.SetRangeMax( nLastRow );
- aVscrollSB.SetPageSize( ROW_COUNT-1 );
- aVscrollSB.SetVisibleSize( ROW_COUNT );
+ aVscrollSB->SetRangeMax( nLastRow );
+ aVscrollSB->SetPageSize( ROW_COUNT-1 );
+ aVscrollSB->SetVisibleSize( ROW_COUNT );
// restore last selected unicode
int nMapIndex = mpFontCharMap->GetIndexFromChar( getSelectedChar() );
SelectIndex( nMapIndex );
- aVscrollSB.Show();
+ aVscrollSB->Show();
// rearrange CharSet element in sync with nX- and nY-multiples
Size aDrawSize(nX * COLUMN_COUNT, nY * ROW_COUNT);
@@ -559,7 +559,7 @@ void SvxShowCharSet::SelectIndex( int nNewIndex, bool bFocus )
sal_uInt32 cPrev = mpFontCharMap->GetPrevChar( getSelectedChar() );
int nMapIndex = mpFontCharMap->GetIndexFromChar( cPrev );
int nNewPos = nMapIndex / COLUMN_COUNT;
- aVscrollSB.SetThumbPos( nNewPos );
+ aVscrollSB->SetThumbPos( nNewPos );
nSelectedIndex = bFocus ? nMapIndex+1 : -1;
Invalidate();
Update();
@@ -567,9 +567,9 @@ void SvxShowCharSet::SelectIndex( int nNewIndex, bool bFocus )
else if( nNewIndex < FirstInView() )
{
// need to scroll up to see selected item
- int nOldPos = aVscrollSB.GetThumbPos();
+ int nOldPos = aVscrollSB->GetThumbPos();
int nDelta = (FirstInView() - nNewIndex + COLUMN_COUNT-1) / COLUMN_COUNT;
- aVscrollSB.SetThumbPos( nOldPos - nDelta );
+ aVscrollSB->SetThumbPos( nOldPos - nDelta );
nSelectedIndex = nNewIndex;
Invalidate();
if( nDelta )
@@ -578,15 +578,15 @@ void SvxShowCharSet::SelectIndex( int nNewIndex, bool bFocus )
else if( nNewIndex > LastInView() )
{
// need to scroll down to see selected item
- int nOldPos = aVscrollSB.GetThumbPos();
+ int nOldPos = aVscrollSB->GetThumbPos();
int nDelta = (nNewIndex - LastInView() + COLUMN_COUNT) / COLUMN_COUNT;
- aVscrollSB.SetThumbPos( nOldPos + nDelta );
+ aVscrollSB->SetThumbPos( nOldPos + nDelta );
if( nNewIndex < mpFontCharMap->GetCharCount() )
{
nSelectedIndex = nNewIndex;
Invalidate();
}
- if( nOldPos != aVscrollSB.GetThumbPos() )
+ if( nOldPos != aVscrollSB->GetThumbPos() )
{
Invalidate();
Update();
@@ -603,8 +603,8 @@ void SvxShowCharSet::SelectIndex( int nNewIndex, bool bFocus )
Point aOldPixel = MapIndexToPixel( nSelectedIndex );
aOldPixel.Move( +1, +1);
Size aOutputSize = GetOutputSizePixel();
- if (aVscrollSB.IsVisible())
- aOutputSize.Width() -= aVscrollSB.GetOptimalSize().Width();
+ if (aVscrollSB->IsVisible())
+ aOutputSize.Width() -= aVscrollSB->GetOptimalSize().Width();
DrawRect( getGridRectangle(aOldPixel, aOutputSize) );
SetLineColor( aLineCol );
SetFillColor( aFillCol );
@@ -655,7 +655,7 @@ void SvxShowCharSet::SelectCharacter( sal_UCS4 cNew, bool bFocus )
if( !bFocus )
{
// move selected item to top row if not in focus
- aVscrollSB.SetThumbPos( nMapIndex / COLUMN_COUNT );
+ aVscrollSB->SetThumbPos( nMapIndex / COLUMN_COUNT );
Invalidate();
}
}
@@ -691,8 +691,15 @@ IMPL_LINK_NOARG(SvxShowCharSet, VscrollHdl)
SvxShowCharSet::~SvxShowCharSet()
{
+ dispose();
+}
+
+void SvxShowCharSet::dispose()
+{
if ( m_pAccessible )
ReleaseAccessible();
+ aVscrollSB.disposeAndClear();
+ Control::dispose();
}
void SvxShowCharSet::ReleaseAccessible()
diff --git a/svx/source/dialog/checklbx.cxx b/svx/source/dialog/checklbx.cxx
index e7f3542..514e3de 100644
--- a/svx/source/dialog/checklbx.cxx
+++ b/svx/source/dialog/checklbx.cxx
@@ -50,7 +50,13 @@ void SvxCheckListBox::SetNormalStaticImage(const Image& rNormalStaticImage)
SvxCheckListBox::~SvxCheckListBox()
{
+ dispose();
+}
+
+void SvxCheckListBox::dispose()
+{
delete pCheckButton;
+ SvTreeListBox::dispose();
}
void SvxCheckListBox::Init_Impl()
diff --git a/svx/source/dialog/compressgraphicdialog.cxx b/svx/source/dialog/compressgraphicdialog.cxx
index 70b82e5..336bfdc 100644
--- a/svx/source/dialog/compressgraphicdialog.cxx
+++ b/svx/source/dialog/compressgraphicdialog.cxx
@@ -105,10 +105,6 @@ void CompressGraphicsDialog::Initialize()
Update();
}
-CompressGraphicsDialog::~CompressGraphicsDialog()
-{
-}
-
void CompressGraphicsDialog::Update()
{
GfxLinkType aLinkType = m_aGraphic.GetLink().GetType();
diff --git a/svx/source/dialog/connctrl.cxx b/svx/source/dialog/connctrl.cxx
index 4d2ca79..2e49543 100644
--- a/svx/source/dialog/connctrl.cxx
+++ b/svx/source/dialog/connctrl.cxx
@@ -57,7 +57,13 @@ extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvxXConnectionPreview(
SvxXConnectionPreview::~SvxXConnectionPreview()
{
+ dispose();
+}
+
+void SvxXConnectionPreview::dispose()
+{
delete pObjList;
+ Control::dispose();
}
void SvxXConnectionPreview::Resize()
diff --git a/svx/source/dialog/contimp.hxx b/svx/source/dialog/contimp.hxx
index 2e999e85..c436661 100644
--- a/svx/source/dialog/contimp.hxx
+++ b/svx/source/dialog/contimp.hxx
@@ -83,6 +83,7 @@ public:
SvxSuperContourDlg(SfxBindings *pBindings, SfxChildWindow *pCW,
vcl::Window* pParent);
virtual ~SvxSuperContourDlg();
+ virtual void dispose() SAL_OVERRIDE;
void SetExecState( bool bEnable );
diff --git a/svx/source/dialog/contwnd.cxx b/svx/source/dialog/contwnd.cxx
index 7587a24..ae19144 100644
--- a/svx/source/dialog/contwnd.cxx
+++ b/svx/source/dialog/contwnd.cxx
@@ -43,10 +43,6 @@ ContourWindow::ContourWindow( vcl::Window* pParent, WinBits nBits ) :
SetWinStyle( WB_SDRMODE );
}
-ContourWindow::~ContourWindow()
-{
-}
-
void ContourWindow::SetPolyPolygon( const tools::PolyPolygon& rPolyPoly )
{
SdrPage* pPage = (SdrPage*) pModel->GetPage( 0 );
diff --git a/svx/source/dialog/contwnd.hxx b/svx/source/dialog/contwnd.hxx
index 2bbf9a6..e96118c 100644
--- a/svx/source/dialog/contwnd.hxx
+++ b/svx/source/dialog/contwnd.hxx
@@ -50,7 +50,6 @@ protected:
public:
ContourWindow(vcl::Window* pParent, WinBits nBits);
- virtual ~ContourWindow();
void SetPolyPolygon( const tools::PolyPolygon& rPolyPoly );
const tools::PolyPolygon& GetPolyPolygon();
diff --git a/svx/source/dialog/ctredlin.cxx b/svx/source/dialog/ctredlin.cxx
index a6165b5..67c3d95 100644
--- a/svx/source/dialog/ctredlin.cxx
+++ b/svx/source/dialog/ctredlin.cxx
@@ -135,7 +135,13 @@ SvxRedlinTable::SvxRedlinTable(SvSimpleTableContainer& rParent, WinBits nBits)
SvxRedlinTable::~SvxRedlinTable()
{
+ dispose();
+}
+
+void SvxRedlinTable::dispose()
+{
delete pCommentSearcher;
+ SvSimpleTable::dispose();
}
sal_Int32 SvxRedlinTable::ColCompare(SvTreeListEntry* pLeft,SvTreeListEntry* pRight)
@@ -428,7 +434,13 @@ void SvxTPView::DeactivatePage()
SvxTPView::~SvxTPView()
{
+ dispose();
+}
+
+void SvxTPView::dispose()
+{
delete m_pViewData;
+ TabPage::dispose();
}
void SvxTPView::InsertWriterHeader()
@@ -1077,8 +1089,14 @@ SvxAcceptChgCtr::SvxAcceptChgCtr(vcl::Window* pParent, VclBuilderContainer* pTop
SvxAcceptChgCtr::~SvxAcceptChgCtr()
{
+ dispose();
+}
+
+void SvxAcceptChgCtr::dispose()
+{
delete pTPView;
delete pTPFilter;
+ TabControl::dispose();
}
void SvxAcceptChgCtr::ShowFilterPage()
diff --git a/svx/source/dialog/dialcontrol.cxx b/svx/source/dialog/dialcontrol.cxx
index e826363..abb3f53 100644
--- a/svx/source/dialog/dialcontrol.cxx
+++ b/svx/source/dialog/dialcontrol.cxx
@@ -271,10 +271,6 @@ DialControl::DialControl( vcl::Window* pParent, WinBits nBits ) :
Init( GetOutputSizePixel() );
}
-DialControl::~DialControl()
-{
-}
-
extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeDialControl(vcl::Window *pParent, VclBuilder::stringmap &)
{
return new DialControl(pParent, WB_TABSTOP);
diff --git a/svx/source/dialog/dlgctl3d.cxx b/svx/source/dialog/dlgctl3d.cxx
index 4711b30..446114a 100644
--- a/svx/source/dialog/dlgctl3d.cxx
+++ b/svx/source/dialog/dlgctl3d.cxx
@@ -75,8 +75,14 @@ Svx3DPreviewControl::Svx3DPreviewControl(vcl::Window* pParent, WinBits nStyle)
Svx3DPreviewControl::~Svx3DPreviewControl()
{
+ dispose();
+}
+
+void Svx3DPreviewControl::dispose()
+{
delete mp3DView;
delete mpModel;
+ Control::dispose();
}
void Svx3DPreviewControl::Construct()
@@ -278,12 +284,6 @@ Svx3DLightControl::Svx3DLightControl(vcl::Window* pParent, WinBits nStyle)
Construct2();
}
-Svx3DLightControl::~Svx3DLightControl()
-{
- // SdrObjects like mpExpansionObject and mpLampBottomObject/mpLampShaftObject get deleted
- // with deletion of the DrawingLayer and model
-}
-
void Svx3DLightControl::Construct2()
{
{
@@ -956,10 +956,10 @@ basegfx::B3DVector Svx3DLightControl::GetLightDirection(sal_uInt32 nNum) const
SvxLightCtl3D::SvxLightCtl3D( vcl::Window* pParent, const ResId& rResId)
: Control(pParent, rResId),
- maLightControl(this, 0),
- maHorScroller(this, WB_HORZ | WB_DRAG),
- maVerScroller(this, WB_VERT | WB_DRAG),
- maSwitcher(this, 0)
+ maLightControl(new Svx3DLightControl(this, 0)),
+ maHorScroller(new ScrollBar(this, WB_HORZ | WB_DRAG)),
+ maVerScroller(new ScrollBar(this, WB_VERT | WB_DRAG)),
+ maSwitcher(new PushButton(this, 0))
{
// init members
Init();
@@ -967,10 +967,10 @@ SvxLightCtl3D::SvxLightCtl3D( vcl::Window* pParent, const ResId& rResId)
SvxLightCtl3D::SvxLightCtl3D( vcl::Window* pParent)
: Control(pParent, WB_BORDER | WB_TABSTOP),
- maLightControl(this, 0),
- maHorScroller(this, WB_HORZ | WB_DRAG),
- maVerScroller(this, WB_VERT | WB_DRAG),
- maSwitcher(this, 0)
+ maLightControl(new Svx3DLightControl(this, 0)),
+ maHorScroller(new ScrollBar(this, WB_HORZ | WB_DRAG)),
+ maVerScroller(new ScrollBar(this, WB_VERT | WB_DRAG)),
+ maSwitcher(new PushButton(this, 0))
{
// init members
Init();
@@ -990,33 +990,33 @@ extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvxLightCtl3D(vcl::Win
void SvxLightCtl3D::Init()
{
// #i58240# set HelpIDs for scrollbars and switcher
- maHorScroller.SetHelpId(HID_CTRL3D_HSCROLL);
- maVerScroller.SetHelpId(HID_CTRL3D_VSCROLL);
- maSwitcher.SetHelpId(HID_CTRL3D_SWITCHER);
- maSwitcher.SetAccessibleName(SVX_RESSTR(STR_SWITCH));
+ maHorScroller->SetHelpId(HID_CTRL3D_HSCROLL);
+ maVerScroller->SetHelpId(HID_CTRL3D_VSCROLL);
+ maSwitcher->SetHelpId(HID_CTRL3D_SWITCHER);
+ maSwitcher->SetAccessibleName(SVX_RESSTR(STR_SWITCH));
// Light preview
- maLightControl.Show();
- maLightControl.SetChangeCallback( LINK(this, SvxLightCtl3D, InternalInteractiveChange) );
- maLightControl.SetSelectionChangeCallback( LINK(this, SvxLightCtl3D, InternalSelectionChange) );
+ maLightControl->Show();
+ maLightControl->SetChangeCallback( LINK(this, SvxLightCtl3D, InternalInteractiveChange) );
+ maLightControl->SetSelectionChangeCallback( LINK(this, SvxLightCtl3D, InternalSelectionChange) );
// Horiz Scrollbar
- maHorScroller.Show();
- maHorScroller.SetRange(Range(0, 36000));
- maHorScroller.SetLineSize(100);
- maHorScroller.SetPageSize(1000);
- maHorScroller.SetScrollHdl( LINK(this, SvxLightCtl3D, ScrollBarMove) );
+ maHorScroller->Show();
+ maHorScroller->SetRange(Range(0, 36000));
+ maHorScroller->SetLineSize(100);
+ maHorScroller->SetPageSize(1000);
+ maHorScroller->SetScrollHdl( LINK(this, SvxLightCtl3D, ScrollBarMove) );
// Vert Scrollbar
- maVerScroller.Show();
- maVerScroller.SetRange(Range(0, 18000));
- maVerScroller.SetLineSize(100);
- maVerScroller.SetPageSize(1000);
- maVerScroller.SetScrollHdl( LINK(this, SvxLightCtl3D, ScrollBarMove) );
+ maVerScroller->Show();
+ maVerScroller->SetRange(Range(0, 18000));
+ maVerScroller->SetLineSize(100);
+ maVerScroller->SetPageSize(1000);
+ maVerScroller->SetScrollHdl( LINK(this, SvxLightCtl3D, ScrollBarMove) );
// Switch Button
- maSwitcher.Show();
- maSwitcher.SetClickHdl( LINK(this, SvxLightCtl3D, ButtonPress) );
+ maSwitcher->Show();
+ maSwitcher->SetClickHdl( LINK(this, SvxLightCtl3D, ButtonPress) );
// check selection
CheckSelection();
@@ -1027,6 +1027,16 @@ void SvxLightCtl3D::Init()
SvxLightCtl3D::~SvxLightCtl3D()
{
+ dispose();
+}
+
+void SvxLightCtl3D::dispose()
+{
+ maLightControl.disposeAndClear();
+ maHorScroller.disposeAndClear();
+ maVerScroller.disposeAndClear();
+ maSwitcher.disposeAndClear();
+ Control::dispose();
}
void SvxLightCtl3D::Resize()
@@ -1042,43 +1052,43 @@ void SvxLightCtl3D::NewLayout()
{
// Layout members
const Size aSize(GetOutputSizePixel());
- const sal_Int32 nScrollSize(maHorScroller.GetSizePixel().Height());
+ const sal_Int32 nScrollSize(maHorScroller->GetSizePixel().Height());
// Preview control
Point aPoint(0, 0);
Size aDestSize(aSize.Width() - nScrollSize, aSize.Height() - nScrollSize);
- maLightControl.SetPosSizePixel(aPoint, aDestSize);
+ maLightControl->SetPosSizePixel(aPoint, aDestSize);
// hor scrollbar
aPoint.Y() = aSize.Height() - nScrollSize;
aDestSize.Height() = nScrollSize;
- maHorScroller.SetPosSizePixel(aPoint, aDestSize);
+ maHorScroller->SetPosSizePixel(aPoint, aDestSize);
// vert scrollbar
aPoint.X() = aSize.Width() - nScrollSize;
aPoint.Y() = 0;
aDestSize.Width() = nScrollSize;
aDestSize.Height() = aSize.Height() - nScrollSize;
- maVerScroller.SetPosSizePixel(aPoint, aDestSize);
+ maVerScroller->SetPosSizePixel(aPoint, aDestSize);
// button
aPoint.Y() = aSize.Height() - nScrollSize;
aDestSize.Height() = nScrollSize;
- maSwitcher.SetPosSizePixel(aPoint, aDestSize);
+ maSwitcher->SetPosSizePixel(aPoint, aDestSize);
}
void SvxLightCtl3D::CheckSelection()
{
- const bool bSelectionValid(maLightControl.IsSelectionValid() || maLightControl.IsGeometrySelected());
- maHorScroller.Enable(bSelectionValid);
- maVerScroller.Enable(bSelectionValid);
+ const bool bSelectionValid(maLightControl->IsSelectionValid() || maLightControl->IsGeometrySelected());
+ maHorScroller->Enable(bSelectionValid);
+ maVerScroller->Enable(bSelectionValid);
if(bSelectionValid)
{
double fHor(0.0), fVer(0.0);
- maLightControl.GetPosition(fHor, fVer);
- maHorScroller.SetThumbPos( sal_Int32(fHor * 100.0) );
- maVerScroller.SetThumbPos( 18000 - sal_Int32((fVer + 90.0) * 100.0) );
+ maLightControl->GetPosition(fHor, fVer);
+ maHorScroller->SetThumbPos( sal_Int32(fHor * 100.0) );
+ maVerScroller->SetThumbPos( 18000 - sal_Int32((fVer + 90.0) * 100.0) );
}
}
@@ -1086,7 +1096,7 @@ void SvxLightCtl3D::move( double fDeltaHor, double fDeltaVer )
{
double fHor(0.0), fVer(0.0);
- maLightControl.GetPosition(fHor, fVer);
+ maLightControl->GetPosition(fHor, fVer);
fHor += fDeltaHor;
fVer += fDeltaVer;
@@ -1096,9 +1106,9 @@ void SvxLightCtl3D::move( double fDeltaHor, double fDeltaVer )
if ( fVer < -90.0 )
return;
- maLightControl.SetPosition(fHor, fVer);
- maHorScroller.SetThumbPos( sal_Int32(fHor * 100.0) );
- maVerScroller.SetThumbPos( 18000 - sal_Int32((fVer + 90.0) * 100.0) );
+ maLightControl->SetPosition(fHor, fVer);
+ maHorScroller->SetThumbPos( sal_Int32(fHor * 100.0) );
+ maVerScroller->SetThumbPos( 18000 - sal_Int32((fVer + 90.0) * 100.0) );
if(maUserInteractiveChangeCallback.IsSet())
{
@@ -1144,9 +1154,9 @@ void SvxLightCtl3D::KeyInput( const KeyEvent& rKEvt )
}
case KEY_PAGEUP:
{
- sal_Int32 nLight(maLightControl.GetSelectedLight() - 1);
+ sal_Int32 nLight(maLightControl->GetSelectedLight() - 1);
- while((nLight >= 0) && !maLightControl.GetLightOnOff(nLight))
+ while((nLight >= 0) && !maLightControl->GetLightOnOff(nLight))
{
nLight--;
}
@@ -1155,7 +1165,7 @@ void SvxLightCtl3D::KeyInput( const KeyEvent& rKEvt )
{
nLight = 7;
- while((nLight >= 0) && !maLightControl.GetLightOnOff(nLight))
+ while((nLight >= 0) && !maLightControl->GetLightOnOff(nLight))
{
nLight--;
}
@@ -1163,7 +1173,7 @@ void SvxLightCtl3D::KeyInput( const KeyEvent& rKEvt )
if(nLight >= 0)
{
- maLightControl.SelectLight(nLight);
+ maLightControl->SelectLight(nLight);
CheckSelection();
if(maUserSelectionChangeCallback.IsSet())
@@ -1176,9 +1186,9 @@ void SvxLightCtl3D::KeyInput( const KeyEvent& rKEvt )
}
case KEY_PAGEDOWN:
{
- sal_Int32 nLight(maLightControl.GetSelectedLight() - 1);
+ sal_Int32 nLight(maLightControl->GetSelectedLight() - 1);
- while(nLight <= 7 && !maLightControl.GetLightOnOff(nLight))
+ while(nLight <= 7 && !maLightControl->GetLightOnOff(nLight))
{
nLight++;
}
@@ -1187,7 +1197,7 @@ void SvxLightCtl3D::KeyInput( const KeyEvent& rKEvt )
{
nLight = 0;
- while(nLight <= 7 && !maLightControl.GetLightOnOff(nLight))
+ while(nLight <= 7 && !maLightControl->GetLightOnOff(nLight))
{
nLight++;
}
@@ -1195,7 +1205,7 @@ void SvxLightCtl3D::KeyInput( const KeyEvent& rKEvt )
if(nLight <= 7)
{
- maLightControl.SelectLight(nLight);
+ maLightControl->SelectLight(nLight);
CheckSelection();
if(maUserSelectionChangeCallback.IsSet())
@@ -1222,16 +1232,16 @@ void SvxLightCtl3D::GetFocus()
{
CheckSelection();
- Size aFocusSize = maLightControl.GetOutputSizePixel();
+ Size aFocusSize = maLightControl->GetOutputSizePixel();
aFocusSize.Width() -= 4;
aFocusSize.Height() -= 4;
Rectangle aFocusRect( Point( 2, 2 ), aFocusSize );
- aFocusRect = maLightControl.PixelToLogic( aFocusRect );
+ aFocusRect = maLightControl->PixelToLogic( aFocusRect );
- maLightControl.ShowFocus( aFocusRect );
+ maLightControl->ShowFocus( aFocusRect );
}
}
@@ -1239,15 +1249,15 @@ void SvxLightCtl3D::LoseFocus()
{
Control::LoseFocus();
- maLightControl.HideFocus();
+ maLightControl->HideFocus();
}
IMPL_LINK_NOARG(SvxLightCtl3D, ScrollBarMove)
{
- const sal_Int32 nHor(maHorScroller.GetThumbPos());
- const sal_Int32 nVer(maVerScroller.GetThumbPos());
+ const sal_Int32 nHor(maHorScroller->GetThumbPos());
+ const sal_Int32 nVer(maVerScroller->GetThumbPos());
- maLightControl.SetPosition(
+ maLightControl->SetPosition(
((double)nHor) / 100.0,
((double)((18000 - nVer) - 9000)) / 100.0);
@@ -1277,9 +1287,9 @@ IMPL_LINK_NOARG(SvxLightCtl3D, InternalInteractiveChange)
{
double fHor(0.0), fVer(0.0);
- maLightControl.GetPosition(fHor, fVer);
- maHorScroller.SetThumbPos( sal_Int32(fHor * 100.0) );
- maVerScroller.SetThumbPos( 18000 - sal_Int32((fVer + 90.0) * 100.0) );
+ maLightControl->GetPosition(fHor, fVer);
+ maHorScroller->SetThumbPos( sal_Int32(fHor * 100.0) );
+ maVerScroller->SetThumbPos( 18000 - sal_Int32((fVer + 90.0) * 100.0) );
if(maUserInteractiveChangeCallback.IsSet())
{
diff --git a/svx/source/dialog/dlgctrl.cxx b/svx/source/dialog/dlgctrl.cxx
index f4d7d8b..9ac6df8 100644
--- a/svx/source/dialog/dlgctrl.cxx
+++ b/svx/source/dialog/dlgctrl.cxx
@@ -106,10 +106,16 @@ extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvxRectCtl(vcl::Window
SvxRectCtl::~SvxRectCtl()
{
+ dispose();
+}
+
+void SvxRectCtl::dispose()
+{
delete pBitmap;
if( pAccContext )
pAccContext->release();
+ Control::dispose();
}
@@ -841,7 +847,13 @@ extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvxPixelCtl(vcl::Windo
SvxPixelCtl::~SvxPixelCtl( )
{
+ dispose();
+}
+
+void SvxPixelCtl::dispose()
+{
delete []pPixel;
+ Control::dispose();
}
// Changes the foreground or Background color
@@ -1600,10 +1612,6 @@ extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeLineLB(vcl::Window *pP
return pListBox;
}
-LineLB::~LineLB()
-{
-}
-
void LineLB::setAddStandardFields(bool bNew)
{
if(getAddStandardFields() != bNew)
@@ -1703,10 +1711,6 @@ extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeLineEndLB(vcl::Window
return pListBox;
}
-LineEndLB::~LineEndLB(void)
-{
-}
-
void LineEndLB::Fill( const XLineEndListRef &pList, bool bStart )
{
if( !pList.is() )
@@ -1841,8 +1845,14 @@ SvxPreviewBase::SvxPreviewBase(vcl::Window* pParent)
SvxPreviewBase::~SvxPreviewBase()
{
+ dispose();
+}
+
+void SvxPreviewBase::dispose()
+{
delete mpModel;
delete mpBufferDevice;
+ Control::dispose();
}
void SvxPreviewBase::LocalPrePaint()
@@ -1996,12 +2006,18 @@ Size SvxXLinePreview::GetOptimalSize() const
SvxXLinePreview::~SvxXLinePreview()
{
+ dispose();
+}
+
+void SvxXLinePreview::dispose()
+{
SdrObject *pFoo = mpLineObjA;
SdrObject::Free( pFoo );
pFoo = mpLineObjB;
SdrObject::Free( pFoo );
pFoo = mpLineObjC;
SdrObject::Free( pFoo );
+ SvxPreviewBase::dispose();
}
@@ -2102,7 +2118,13 @@ extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvxXRectPreview(vcl::W
SvxXRectPreview::~SvxXRectPreview()
{
+ dispose();
+}
+
+void SvxXRectPreview::dispose()
+{
SdrObject::Free(mpRectangleObject);
+ SvxPreviewBase::dispose();
}
void SvxXRectPreview::SetAttributes(const SfxItemSet& rItemSet)
@@ -2157,8 +2179,14 @@ extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvxXShadowPreview (vcl
SvxXShadowPreview::~SvxXShadowPreview()
{
+ dispose();
+}
+
+void SvxXShadowPreview::dispose()
+{
SdrObject::Free(mpRectangleObject);
SdrObject::Free(mpRectangleShadow);
+ SvxPreviewBase::dispose();
}
void SvxXShadowPreview::SetRectangleAttributes(const SfxItemSet& rItemSet)
diff --git a/svx/source/dialog/docrecovery.cxx b/svx/source/dialog/docrecovery.cxx
index fda7a3c..8400907 100644
--- a/svx/source/dialog/docrecovery.cxx
+++ b/svx/source/dialog/docrecovery.cxx
@@ -539,8 +539,14 @@ PluginProgressWindow::PluginProgressWindow( vcl::Window*
PluginProgressWindow::~PluginProgressWindow()
{
+ dispose();
+}
+
+void PluginProgressWindow::dispose()
+{
if (m_xProgress.is())
m_xProgress->dispose();
+ vcl::Window::dispose();
}
@@ -808,10 +814,6 @@ RecovDocList::RecovDocList(SvSimpleTableContainer& rParent, ResMgr &rResMgr)
{
}
-RecovDocList::~RecovDocList()
-{
-}
-
void RecovDocList::InitEntry(SvTreeListEntry* pEntry,
const OUString& rText,
const Image& rImage1,
@@ -901,7 +903,13 @@ RecoveryDialog::RecoveryDialog(vcl::Window* pParent, RecoveryCore* pCore)
RecoveryDialog::~RecoveryDialog()
{
+ dispose();
+}
+
+void RecoveryDialog::dispose()
+{
delete m_pFileListLB;
+ Dialog::dispose();
}
short RecoveryDialog::execute()
@@ -1232,11 +1240,6 @@ BrokenRecoveryDialog::BrokenRecoveryDialog(vcl::Window* pParent ,
}
-BrokenRecoveryDialog::~BrokenRecoveryDialog()
-{
-}
-
-
void BrokenRecoveryDialog::impl_refresh()
{
m_bExecutionNeeded = false;
diff --git a/svx/source/dialog/fntctrl.cxx b/svx/source/dialog/fntctrl.cxx
index 5188cd0..a72f212 100644
--- a/svx/source/dialog/fntctrl.cxx
+++ b/svx/source/dialog/fntctrl.cxx
@@ -502,7 +502,13 @@ extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvxFontPrevWindow(vcl:
SvxFontPrevWindow::~SvxFontPrevWindow()
{
+ dispose();
+}
+
+void SvxFontPrevWindow::dispose()
+{
delete pImpl;
+ vcl::Window::dispose();
}
diff --git a/svx/source/dialog/fontwork.cxx b/svx/source/dialog/fontwork.cxx
index 660869c..bfc941b 100644
--- a/svx/source/dialog/fontwork.cxx
+++ b/svx/source/dialog/fontwork.cxx
@@ -182,22 +182,22 @@ SvxFontWorkDialog::SvxFontWorkDialog( SfxBindings *pBindinx,
const ResId& rResId ) :
SfxDockingWindow( pBindinx, pCW, _pParent, rResId ),
- aTbxStyle (this, ResId(TBX_STYLE,*rResId.GetResMgr())),
- aTbxAdjust (this, ResId(TBX_ADJUST,*rResId.GetResMgr())),
+ aTbxStyle (new ToolBox(this, ResId(TBX_STYLE,*rResId.GetResMgr()))),
+ aTbxAdjust (new ToolBox(this, ResId(TBX_ADJUST,*rResId.GetResMgr()))),
- aFbDistance (this, ResId(FB_DISTANCE,*rResId.GetResMgr())),
- aMtrFldDistance (this, ResId(MTR_FLD_DISTANCE,*rResId.GetResMgr())),
- aFbTextStart (this, ResId(FB_TEXTSTART,*rResId.GetResMgr())),
- aMtrFldTextStart(this, ResId(MTR_FLD_TEXTSTART,*rResId.GetResMgr())),
+ aFbDistance (new FixedImage(this, ResId(FB_DISTANCE,*rResId.GetResMgr()))),
+ aMtrFldDistance (new MetricField(this, ResId(MTR_FLD_DISTANCE,*rResId.GetResMgr()))),
+ aFbTextStart (new FixedImage(this, ResId(FB_TEXTSTART,*rResId.GetResMgr()))),
+ aMtrFldTextStart(new MetricField(this, ResId(MTR_FLD_TEXTSTART,*rResId.GetResMgr()))),
- aTbxShadow (this, ResId(TBX_SHADOW,*rResId.GetResMgr())),
+ aTbxShadow (new ToolBox(this, ResId(TBX_SHADOW,*rResId.GetResMgr()))),
- aFbShadowX (this, ResId(FB_SHADOW_X,*rResId.GetResMgr())),
- aMtrFldShadowX (this, ResId(MTR_FLD_SHADOW_X,*rResId.GetResMgr())),
- aFbShadowY (this, ResId(FB_SHADOW_Y,*rResId.GetResMgr())),
- aMtrFldShadowY (this, ResId(MTR_FLD_SHADOW_Y,*rResId.GetResMgr())),
+ aFbShadowX (new FixedImage(this, ResId(FB_SHADOW_X,*rResId.GetResMgr()))),
+ aMtrFldShadowX (new MetricField(this, ResId(MTR_FLD_SHADOW_X,*rResId.GetResMgr()))),
+ aFbShadowY (new FixedImage(this, ResId(FB_SHADOW_Y,*rResId.GetResMgr()))),
+ aMtrFldShadowY (new MetricField(this, ResId(MTR_FLD_SHADOW_Y,*rResId.GetResMgr()))),
- aShadowColorLB (this, ResId(CLB_SHADOW_COLOR,*rResId.GetResMgr())),
+ aShadowColorLB (new ColorLB(this, ResId(CLB_SHADOW_COLOR,*rResId.GetResMgr()))),
rBindings (*pBindinx),
nLastStyleTbxId(0),
@@ -226,44 +226,44 @@ SvxFontWorkDialog::SvxFontWorkDialog( SfxBindings *pBindinx,
pCtrlItems[9] = new SvxFontWorkControllerItem(SID_FORMTEXT_SHDWXVAL, *this, rBindings);
pCtrlItems[10] = new SvxFontWorkControllerItem(SID_FORMTEXT_SHDWYVAL, *this, rBindings);
- Size aSize = aTbxStyle.CalcWindowSizePixel();
- aTbxStyle.SetSizePixel(aSize);
- aTbxStyle.SetSelectHdl( LINK(this, SvxFontWorkDialog, SelectStyleHdl_Impl) );
+ Size aSize = aTbxStyle->CalcWindowSizePixel();
+ aTbxStyle->SetSizePixel(aSize);
+ aTbxStyle->SetSelectHdl( LINK(this, SvxFontWorkDialog, SelectStyleHdl_Impl) );
- aTbxAdjust.SetSizePixel(aSize);
- aTbxAdjust.SetSelectHdl( LINK(this, SvxFontWorkDialog, SelectAdjustHdl_Impl) );
+ aTbxAdjust->SetSizePixel(aSize);
+ aTbxAdjust->SetSelectHdl( LINK(this, SvxFontWorkDialog, SelectAdjustHdl_Impl) );
- aTbxShadow.SetSizePixel(aSize);
- aTbxShadow.SetSelectHdl( LINK(this, SvxFontWorkDialog, SelectShadowHdl_Impl) );
+ aTbxShadow->SetSizePixel(aSize);
+ aTbxShadow->SetSelectHdl( LINK(this, SvxFontWorkDialog, SelectShadowHdl_Impl) );
Link aLink = LINK(this, SvxFontWorkDialog, ModifyInputHdl_Impl);
- aMtrFldDistance.SetModifyHdl( aLink );
- aMtrFldTextStart.SetModifyHdl( aLink );
- aMtrFldShadowX.SetModifyHdl( aLink );
- aMtrFldShadowY.SetModifyHdl( aLink );
+ aMtrFldDistance->SetModifyHdl( aLink );
+ aMtrFldTextStart->SetModifyHdl( aLink );
+ aMtrFldShadowX->SetModifyHdl( aLink );
+ aMtrFldShadowY->SetModifyHdl( aLink );
// Set System metric
const FieldUnit eDlgUnit = rBindings.GetDispatcher()->GetModule()->GetFieldUnit();
- SetFieldUnit( aMtrFldDistance, eDlgUnit, true );
- SetFieldUnit( aMtrFldTextStart, eDlgUnit, true );
- SetFieldUnit( aMtrFldShadowX, eDlgUnit, true );
- SetFieldUnit( aMtrFldShadowY, eDlgUnit, true );
+ SetFieldUnit( *aMtrFldDistance.get(), eDlgUnit, true );
+ SetFieldUnit( *aMtrFldTextStart.get(), eDlgUnit, true );
+ SetFieldUnit( *aMtrFldShadowX.get(), eDlgUnit, true );
+ SetFieldUnit( *aMtrFldShadowY.get(), eDlgUnit, true );
if( eDlgUnit == FUNIT_MM )
{
- aMtrFldDistance.SetSpinSize( 50 );
- aMtrFldTextStart.SetSpinSize( 50 );
- aMtrFldShadowX.SetSpinSize( 50 );
- aMtrFldShadowY.SetSpinSize( 50 );
+ aMtrFldDistance->SetSpinSize( 50 );
+ aMtrFldTextStart->SetSpinSize( 50 );
+ aMtrFldShadowX->SetSpinSize( 50 );
+ aMtrFldShadowY->SetSpinSize( 50 );
}
else
{
- aMtrFldDistance.SetSpinSize( 10 );
- aMtrFldTextStart.SetSpinSize( 10 );
- aMtrFldShadowX.SetSpinSize( 10 );
- aMtrFldShadowY.SetSpinSize( 10 );
+ aMtrFldDistance->SetSpinSize( 10 );
+ aMtrFldTextStart->SetSpinSize( 10 );
+ aMtrFldShadowX->SetSpinSize( 10 );
+ aMtrFldShadowY->SetSpinSize( 10 );
}
- aShadowColorLB.SetSelectHdl( LINK(this, SvxFontWorkDialog, ColorSelectHdl_Impl) );
+ aShadowColorLB->SetSelectHdl( LINK(this, SvxFontWorkDialog, ColorSelectHdl_Impl) );
aInputIdle.SetPriority(VCL_IDLE_PRIORITY_LOWEST);
aInputIdle.SetIdleHdl(LINK(this, SvxFontWorkDialog, InputTimoutHdl_Impl));
@@ -271,8 +271,26 @@ SvxFontWorkDialog::SvxFontWorkDialog( SfxBindings *pBindinx,
SvxFontWorkDialog::~SvxFontWorkDialog()
{
+ dispose();
+}
+
+void SvxFontWorkDialog::dispose()
+{
for (sal_uInt16 i = 0; i < CONTROLLER_COUNT; i++)
DELETEZ(pCtrlItems[i]);
+ aTbxStyle.disposeAndClear();
+ aTbxAdjust.disposeAndClear();
+ aFbDistance.disposeAndClear();
+ aMtrFldDistance.disposeAndClear();
+ aFbTextStart.disposeAndClear();
+ aMtrFldTextStart.disposeAndClear();
+ aTbxShadow.disposeAndClear();
+ aFbShadowX.disposeAndClear();
+ aMtrFldShadowX.disposeAndClear();
+ aFbShadowY.disposeAndClear();
+ aMtrFldShadowY.disposeAndClear();
+ aShadowColorLB.disposeAndClear();
+ SfxDockingWindow::dispose();
}
void SvxFontWorkDialog::Zoom()
@@ -335,28 +353,28 @@ void SvxFontWorkDialog::SetStyle_Impl(const XFormTextStyleItem* pItem)
case XFT_SLANTY : nId = TBI_STYLE_SLANTY; break;
default: ;//prevent warning
}
- aTbxStyle.Enable();
+ aTbxStyle->Enable();
// Make sure that there is always exactly one checked toolbox item.
if ( pItem->GetValue() == XFT_NONE )
{
- aTbxStyle.CheckItem(TBI_STYLE_ROTATE, false);
- aTbxStyle.CheckItem(TBI_STYLE_UPRIGHT, false);
- aTbxStyle.CheckItem(TBI_STYLE_SLANTX, false);
- aTbxStyle.CheckItem(TBI_STYLE_SLANTY, false);
+ aTbxStyle->CheckItem(TBI_STYLE_ROTATE, false);
+ aTbxStyle->CheckItem(TBI_STYLE_UPRIGHT, false);
+ aTbxStyle->CheckItem(TBI_STYLE_SLANTX, false);
+ aTbxStyle->CheckItem(TBI_STYLE_SLANTY, false);
- aTbxStyle.CheckItem(TBI_STYLE_OFF, true);
+ aTbxStyle->CheckItem(TBI_STYLE_OFF, true);
}
else
{
- aTbxStyle.CheckItem(TBI_STYLE_OFF, false);
- aTbxStyle.CheckItem(nId);
+ aTbxStyle->CheckItem(TBI_STYLE_OFF, false);
+ aTbxStyle->CheckItem(nId);
}
nLastStyleTbxId = nId;
}
else
- aTbxStyle.Disable();
+ aTbxStyle->Disable();
}
// Set adjust buttons
@@ -367,33 +385,33 @@ void SvxFontWorkDialog::SetAdjust_Impl(const XFormTextAdjustItem* pItem)
{
sal_uInt16 nId;
- aTbxAdjust.Enable();
- aMtrFldDistance.Enable();
+ aTbxAdjust->Enable();
+ aMtrFldDistance->Enable();
if ( pItem->GetValue() == XFT_LEFT || pItem->GetValue() == XFT_RIGHT )
{
if ( pItem->GetValue() == XFT_LEFT ) nId = TBI_ADJUST_LEFT;
else nId = TBI_ADJUST_RIGHT;
- aMtrFldTextStart.Enable();
+ aMtrFldTextStart->Enable();
}
else
{
if ( pItem->GetValue() == XFT_CENTER ) nId = TBI_ADJUST_CENTER;
else nId = TBI_ADJUST_AUTOSIZE;
- aMtrFldTextStart.Disable();
+ aMtrFldTextStart->Disable();
}
- if ( !aTbxAdjust.IsItemChecked(nId) )
+ if ( !aTbxAdjust->IsItemChecked(nId) )
{
- aTbxAdjust.CheckItem(nId);
+ aTbxAdjust->CheckItem(nId);
}
nLastAdjustTbxId = nId;
}
else
{
- aTbxAdjust.Disable();
- aMtrFldTextStart.Disable();
- aMtrFldDistance.Disable();
+ aTbxAdjust->Disable();
+ aMtrFldTextStart->Disable();
+ aMtrFldDistance->Disable();
}
}
@@ -402,9 +420,9 @@ void SvxFontWorkDialog::SetAdjust_Impl(const XFormTextAdjustItem* pItem)
void SvxFontWorkDialog::SetDistance_Impl(const XFormTextDistanceItem* pItem)
{
// Use HasChildPathFocus() instead of HasFocus() at SpinFields
- if ( pItem && !aMtrFldDistance.HasChildPathFocus() )
+ if ( pItem && !aMtrFldDistance->HasChildPathFocus() )
{
- SetMetricValue( aMtrFldDistance, pItem->GetValue(), SFX_MAPUNIT_100TH_MM );
+ SetMetricValue( *aMtrFldDistance.get(), pItem->GetValue(), SFX_MAPUNIT_100TH_MM );
}
}
@@ -413,9 +431,9 @@ void SvxFontWorkDialog::SetDistance_Impl(const XFormTextDistanceItem* pItem)
void SvxFontWorkDialog::SetStart_Impl(const XFormTextStartItem* pItem)
{
// Use HasChildPathFocus() instead of HasFocus() at SpinFields
- if ( pItem && !aMtrFldTextStart.HasChildPathFocus() )
+ if ( pItem && !aMtrFldTextStart->HasChildPathFocus() )
{
- SetMetricValue( aMtrFldTextStart, pItem->GetValue(), SFX_MAPUNIT_100TH_MM );
+ SetMetricValue( *aMtrFldTextStart.get(), pItem->GetValue(), SFX_MAPUNIT_100TH_MM );
}
}
@@ -424,7 +442,7 @@ void SvxFontWorkDialog::SetStart_Impl(const XFormTextStartItem* pItem)
void SvxFontWorkDialog::SetMirror_Impl(const XFormTextMirrorItem* pItem)
{
if ( pItem )
- aTbxAdjust.CheckItem(TBI_ADJUST_MIRROR, pItem->GetValue());
+ aTbxAdjust->CheckItem(TBI_ADJUST_MIRROR, pItem->GetValue());
}
// Set button for contour display
@@ -432,7 +450,7 @@ void SvxFontWorkDialog::SetMirror_Impl(const XFormTextMirrorItem* pItem)
void SvxFontWorkDialog::SetShowForm_Impl(const XFormTextHideFormItem* pItem)
{
if ( pItem )
- aTbxShadow.CheckItem(TBI_SHOWFORM, !pItem->GetValue());
+ aTbxShadow->CheckItem(TBI_SHOWFORM, !pItem->GetValue());
}
// Set button for text border
@@ -440,7 +458,7 @@ void SvxFontWorkDialog::SetShowForm_Impl(const XFormTextHideFormItem* pItem)
void SvxFontWorkDialog::SetOutline_Impl(const XFormTextOutlineItem* pItem)
{
if ( pItem )
- aTbxShadow.CheckItem(TBI_OUTLINE, pItem->GetValue());
+ aTbxShadow->CheckItem(TBI_OUTLINE, pItem->GetValue());
}
// Set shadow buttons
@@ -452,52 +470,52 @@ void SvxFontWorkDialog::SetShadow_Impl(const XFormTextShadowItem* pItem,
{
sal_uInt16 nId;
- aTbxShadow.Enable();
+ aTbxShadow->Enable();
if ( pItem->GetValue() == XFTSHADOW_NONE )
{
nId = TBI_SHADOW_OFF;
- aFbShadowX.Hide();
- aFbShadowY.Hide();
- aMtrFldShadowX.Disable();
- aMtrFldShadowY.Disable();
- aShadowColorLB.Disable();
+ aFbShadowX->Hide();
+ aFbShadowY->Hide();
+ aMtrFldShadowX->Disable();
+ aMtrFldShadowY->Disable();
+ aShadowColorLB->Disable();
}
else
{
- aFbShadowX.Show();
- aFbShadowY.Show();
- aMtrFldShadowX.Enable();
- aMtrFldShadowY.Enable();
- aShadowColorLB.Enable();
+ aFbShadowX->Show();
+ aFbShadowY->Show();
+ aMtrFldShadowX->Enable();
+ aMtrFldShadowY->Enable();
+ aShadowColorLB->Enable();
if ( pItem->GetValue() == XFTSHADOW_NORMAL )
{
nId = TBI_SHADOW_NORMAL;
const FieldUnit eDlgUnit = rBindings.GetDispatcher()->GetModule()->GetFieldUnit();
- aMtrFldShadowX.SetUnit( eDlgUnit );
- aMtrFldShadowX.SetDecimalDigits(2);
- aMtrFldShadowX.SetMin(LONG_MIN);
- aMtrFldShadowX.SetMax(LONG_MAX);
+ aMtrFldShadowX->SetUnit( eDlgUnit );
+ aMtrFldShadowX->SetDecimalDigits(2);
+ aMtrFldShadowX->SetMin(LONG_MIN);
+ aMtrFldShadowX->SetMax(LONG_MAX);
if( eDlgUnit == FUNIT_MM )
- aMtrFldShadowX.SetSpinSize( 50 );
+ aMtrFldShadowX->SetSpinSize( 50 );
else
- aMtrFldShadowX.SetSpinSize( 10 );
+ aMtrFldShadowX->SetSpinSize( 10 );
- aMtrFldShadowY.SetUnit( eDlgUnit );
- aMtrFldShadowY.SetDecimalDigits(2);
- aMtrFldShadowY.SetMin(LONG_MIN);
- aMtrFldShadowY.SetMax(LONG_MAX);
+ aMtrFldShadowY->SetUnit( eDlgUnit );
+ aMtrFldShadowY->SetDecimalDigits(2);
+ aMtrFldShadowY->SetMin(LONG_MIN);
+ aMtrFldShadowY->SetMax(LONG_MAX);
if( eDlgUnit == FUNIT_MM )
- aMtrFldShadowY.SetSpinSize( 50 );
+ aMtrFldShadowY->SetSpinSize( 50 );
else
- aMtrFldShadowY.SetSpinSize( 10 );
+ aMtrFldShadowY->SetSpinSize( 10 );
if ( bRestoreValues )
{
- SetMetricValue( aMtrFldShadowX, nSaveShadowX, SFX_MAPUNIT_100TH_MM );
- SetMetricValue( aMtrFldShadowY, nSaveShadowY, SFX_MAPUNIT_100TH_MM );
+ SetMetricValue( *aMtrFldShadowX.get(), nSaveShadowX, SFX_MAPUNIT_100TH_MM );
+ SetMetricValue( *aMtrFldShadowY.get(), nSaveShadowY, SFX_MAPUNIT_100TH_MM );
XFormTextShadowXValItem aXItem( nSaveShadowX );
XFormTextShadowYValItem aYItem( nSaveShadowY );
@@ -510,22 +528,22 @@ void SvxFontWorkDialog::SetShadow_Impl(const XFormTextShadowItem* pItem,
{
nId = TBI_SHADOW_SLANT;
- aMtrFldShadowX.SetUnit(FUNIT_CUSTOM);
- aMtrFldShadowX.SetDecimalDigits(1);
- aMtrFldShadowX.SetMin(-1800);
- aMtrFldShadowX.SetMax( 1800);
- aMtrFldShadowX.SetSpinSize(10);
+ aMtrFldShadowX->SetUnit(FUNIT_CUSTOM);
+ aMtrFldShadowX->SetDecimalDigits(1);
+ aMtrFldShadowX->SetMin(-1800);
+ aMtrFldShadowX->SetMax( 1800);
+ aMtrFldShadowX->SetSpinSize(10);
- aMtrFldShadowY.SetUnit(FUNIT_PERCENT);
- aMtrFldShadowY.SetDecimalDigits(0);
- aMtrFldShadowY.SetMin(-999);
- aMtrFldShadowY.SetMax( 999);
- aMtrFldShadowY.SetSpinSize(10);
+ aMtrFldShadowY->SetUnit(FUNIT_PERCENT);
+ aMtrFldShadowY->SetDecimalDigits(0);
+ aMtrFldShadowY->SetMin(-999);
+ aMtrFldShadowY->SetMax( 999);
+ aMtrFldShadowY->SetSpinSize(10);
if ( bRestoreValues )
{
- aMtrFldShadowX.SetValue(nSaveShadowAngle);
- aMtrFldShadowY.SetValue(nSaveShadowSize);
+ aMtrFldShadowX->SetValue(nSaveShadowAngle);
+ aMtrFldShadowY->SetValue(nSaveShadowSize);
XFormTextShadowXValItem aXItem(nSaveShadowAngle);
XFormTextShadowYValItem aYItem(nSaveShadowSize);
GetBindings().GetDispatcher()->Execute(
@@ -534,9 +552,9 @@ void SvxFontWorkDialog::SetShadow_Impl(const XFormTextShadowItem* pItem,
}
}
- if ( !aTbxShadow.IsItemChecked(nId) )
+ if ( !aTbxShadow->IsItemChecked(nId) )
{
- aTbxShadow.CheckItem(nId);
+ aTbxShadow->CheckItem(nId);
}
nLastShadowTbxId = nId;
@@ -544,10 +562,10 @@ void SvxFontWorkDialog::SetShadow_Impl(const XFormTextShadowItem* pItem,
}
else
{
- aTbxShadow.Disable();
- aMtrFldShadowX.Disable();
- aMtrFldShadowY.Disable();
- aShadowColorLB.Disable();
+ aTbxShadow->Disable();
+ aMtrFldShadowX->Disable();
+ aMtrFldShadowY->Disable();
+ aShadowColorLB->Disable();
}
}
@@ -556,7 +574,7 @@ void SvxFontWorkDialog::SetShadow_Impl(const XFormTextShadowItem* pItem,
void SvxFontWorkDialog::SetShadowColor_Impl(const XFormTextShadowColorItem* pItem)
{
if ( pItem )
- aShadowColorLB.SelectEntry(pItem->GetColorValue());
+ aShadowColorLB->SelectEntry(pItem->GetColorValue());
}
// Enter X-value for shadow in edit field
@@ -564,7 +582,7 @@ void SvxFontWorkDialog::SetShadowColor_Impl(const XFormTextShadowColorItem* pIte
void SvxFontWorkDialog::SetShadowXVal_Impl(const XFormTextShadowXValItem* pItem)
{
// Use HasChildPathFocus() instead of HasFocus() at SpinFields
- if ( pItem && !aMtrFldShadowX.HasChildPathFocus() )
+ if ( pItem && !aMtrFldShadowX->HasChildPathFocus() )
{
// #i19251#
// sal_Int32 nValue = pItem->GetValue();
@@ -573,7 +591,7 @@ void SvxFontWorkDialog::SetShadowXVal_Impl(const XFormTextShadowXValItem* pItem)
// The two involved fields/items are used double and contain/give different
// values regarding to the access method. Thus, here we need to separate the access
// methos regarding to the kind of value accessed.
- if(aTbxShadow.IsItemChecked(TBI_SHADOW_SLANT))
+ if(aTbxShadow->IsItemChecked(TBI_SHADOW_SLANT))
{
// #i19251#
// There is no value correction necessary at all, i think this
@@ -581,11 +599,11 @@ void SvxFontWorkDialog::SetShadowXVal_Impl(const XFormTextShadowXValItem* pItem)
// involved fields/items are used double and contain/give different
// values regarding to the access method.
// nValue = nValue - ( int( float( nValue ) / 360.0 ) * 360 );
- aMtrFldShadowX.SetValue(pItem->GetValue());
+ aMtrFldShadowX->SetValue(pItem->GetValue());
}
else
{
- SetMetricValue( aMtrFldShadowX, pItem->GetValue(), SFX_MAPUNIT_100TH_MM );
+ SetMetricValue( *aMtrFldShadowX.get(), pItem->GetValue(), SFX_MAPUNIT_100TH_MM );
}
}
}
@@ -595,26 +613,26 @@ void SvxFontWorkDialog::SetShadowXVal_Impl(const XFormTextShadowXValItem* pItem)
void SvxFontWorkDialog::SetShadowYVal_Impl(const XFormTextShadowYValItem* pItem)
{
// Use HasChildPathFocus() instead of HasFocus() at SpinFields
- if ( pItem && !aMtrFldShadowY.HasChildPathFocus() )
+ if ( pItem && !aMtrFldShadowY->HasChildPathFocus() )
{
// #i19251#
// The two involved fields/items are used double and contain/give different
// values regarding to the access method. Thus, here we need to separate the access
// methos regarding to the kind of value accessed.
- if(aTbxShadow.IsItemChecked(TBI_SHADOW_SLANT))
+ if(aTbxShadow->IsItemChecked(TBI_SHADOW_SLANT))
{
- aMtrFldShadowY.SetValue(pItem->GetValue());
+ aMtrFldShadowY->SetValue(pItem->GetValue());
}
else
{
- SetMetricValue( aMtrFldShadowY, pItem->GetValue(), SFX_MAPUNIT_100TH_MM );
+ SetMetricValue( *aMtrFldShadowY.get(), pItem->GetValue(), SFX_MAPUNIT_100TH_MM );
}
}
}
IMPL_LINK_NOARG(SvxFontWorkDialog, SelectStyleHdl_Impl)
{
- sal_uInt16 nId = aTbxStyle.GetCurItemId();
+ sal_uInt16 nId = aTbxStyle->GetCurItemId();
// Execute this block when a different toolbox item has been clicked or
// when the off item has been clicked. The later is necessary to
@@ -642,11 +660,11 @@ IMPL_LINK_NOARG(SvxFontWorkDialog, SelectStyleHdl_Impl)
IMPL_LINK_NOARG(SvxFontWorkDialog, SelectAdjustHdl_Impl)
{
- sal_uInt16 nId = aTbxAdjust.GetCurItemId();
+ sal_uInt16 nId = aTbxAdjust->GetCurItemId();
if ( nId == TBI_ADJUST_MIRROR )
{
- XFormTextMirrorItem aItem(aTbxAdjust.IsItemChecked(nId));
+ XFormTextMirrorItem aItem(aTbxAdjust->IsItemChecked(nId));
GetBindings().GetDispatcher()->Execute( SID_FORMTEXT_MIRROR, SfxCallMode::SLOT, &aItem, 0L );
}
else if ( nId != nLastAdjustTbxId )
@@ -669,16 +687,16 @@ IMPL_LINK_NOARG(SvxFontWorkDialog, SelectAdjustHdl_Impl)
IMPL_LINK_NOARG(SvxFontWorkDialog, SelectShadowHdl_Impl)
{
- sal_uInt16 nId = aTbxShadow.GetCurItemId();
+ sal_uInt16 nId = aTbxShadow->GetCurItemId();
if ( nId == TBI_SHOWFORM )
{
- XFormTextHideFormItem aItem(!aTbxShadow.IsItemChecked(nId));
+ XFormTextHideFormItem aItem(!aTbxShadow->IsItemChecked(nId));
GetBindings().GetDispatcher()->Execute( SID_FORMTEXT_HIDEFORM, SfxCallMode::RECORD, &aItem, 0L );
}
else if ( nId == TBI_OUTLINE )
{
- XFormTextOutlineItem aItem(aTbxShadow.IsItemChecked(nId));
+ XFormTextOutlineItem aItem(aTbxShadow->IsItemChecked(nId));
GetBindings().GetDispatcher()->Execute( SID_FORMTEXT_OUTLINE, SfxCallMode::RECORD, &aItem, 0L );
}
else if ( nId != nLastShadowTbxId )
@@ -687,13 +705,13 @@ IMPL_LINK_NOARG(SvxFontWorkDialog, SelectShadowHdl_Impl)
if ( nLastShadowTbxId == TBI_SHADOW_NORMAL )
{
- nSaveShadowX = GetCoreValue( aMtrFldShadowX, SFX_MAPUNIT_100TH_MM );
- nSaveShadowY = GetCoreValue( aMtrFldShadowY, SFX_MAPUNIT_100TH_MM );
+ nSaveShadowX = GetCoreValue( *aMtrFldShadowX.get(), SFX_MAPUNIT_100TH_MM );
+ nSaveShadowY = GetCoreValue( *aMtrFldShadowY.get(), SFX_MAPUNIT_100TH_MM );
}
else if ( nLastShadowTbxId == TBI_SHADOW_SLANT )
{
- nSaveShadowAngle = static_cast<long>(aMtrFldShadowX.GetValue());
- nSaveShadowSize = static_cast<long>(aMtrFldShadowY.GetValue());
+ nSaveShadowAngle = static_cast<long>(aMtrFldShadowX->GetValue());
+ nSaveShadowSize = static_cast<long>(aMtrFldShadowY->GetValue());
}
nLastShadowTbxId = nId;
@@ -720,25 +738,25 @@ IMPL_LINK_NOARG(SvxFontWorkDialog, InputTimoutHdl_Impl)
// listen, this is however not possible at the moment due to compabillity
// issues.
const FieldUnit eDlgUnit = rBindings.GetDispatcher()->GetModule()->GetFieldUnit();
- if( eDlgUnit != aMtrFldDistance.GetUnit() )
+ if( eDlgUnit != aMtrFldDistance->GetUnit() )
{
- SetFieldUnit( aMtrFldDistance, eDlgUnit, true );
- SetFieldUnit( aMtrFldTextStart, eDlgUnit, true );
- aMtrFldDistance.SetSpinSize( eDlgUnit == FUNIT_MM ? 50 : 10 );
- aMtrFldTextStart.SetSpinSize( eDlgUnit == FUNIT_MM ? 50 : 10 );
+ SetFieldUnit( *aMtrFldDistance.get(), eDlgUnit, true );
+ SetFieldUnit( *aMtrFldTextStart.get(), eDlgUnit, true );
+ aMtrFldDistance->SetSpinSize( eDlgUnit == FUNIT_MM ? 50 : 10 );
+ aMtrFldTextStart->SetSpinSize( eDlgUnit == FUNIT_MM ? 50 : 10 );
}
- if( eDlgUnit != aMtrFldShadowX.GetUnit() &&
- aTbxShadow.IsItemChecked( TBI_SHADOW_NORMAL ) )
+ if( eDlgUnit != aMtrFldShadowX->GetUnit() &&
+ aTbxShadow->IsItemChecked( TBI_SHADOW_NORMAL ) )
{
- SetFieldUnit( aMtrFldShadowX, eDlgUnit, true );
- SetFieldUnit( aMtrFldShadowY, eDlgUnit, true );
- aMtrFldShadowX.SetSpinSize( eDlgUnit == FUNIT_MM ? 50 : 10 );
- aMtrFldShadowY.SetSpinSize( eDlgUnit == FUNIT_MM ? 50 : 10 );
+ SetFieldUnit( *aMtrFldShadowX.get(), eDlgUnit, true );
+ SetFieldUnit( *aMtrFldShadowY.get(), eDlgUnit, true );
+ aMtrFldShadowX->SetSpinSize( eDlgUnit == FUNIT_MM ? 50 : 10 );
+ aMtrFldShadowY->SetSpinSize( eDlgUnit == FUNIT_MM ? 50 : 10 );
}
- long nValue = GetCoreValue( aMtrFldDistance, SFX_MAPUNIT_100TH_MM );
+ long nValue = GetCoreValue( *aMtrFldDistance.get(), SFX_MAPUNIT_100TH_MM );
XFormTextDistanceItem aDistItem( nValue );
- nValue = GetCoreValue( aMtrFldTextStart, SFX_MAPUNIT_100TH_MM );
+ nValue = GetCoreValue( *aMtrFldTextStart.get(), SFX_MAPUNIT_100TH_MM );
XFormTextStartItem aStartItem( nValue );
sal_Int32 nValueX(0L);
@@ -750,13 +768,13 @@ IMPL_LINK_NOARG(SvxFontWorkDialog, InputTimoutHdl_Impl)
// methos regarding to the kind of value accessed.
if(nLastShadowTbxId == TBI_SHADOW_NORMAL)
{
- nValueX = GetCoreValue( aMtrFldShadowX, SFX_MAPUNIT_100TH_MM );
- nValueY = GetCoreValue( aMtrFldShadowY, SFX_MAPUNIT_100TH_MM );
+ nValueX = GetCoreValue( *aMtrFldShadowX.get(), SFX_MAPUNIT_100TH_MM );
+ nValueY = GetCoreValue( *aMtrFldShadowY.get(), SFX_MAPUNIT_100TH_MM );
}
else if(nLastShadowTbxId == TBI_SHADOW_SLANT)
{
- nValueX = static_cast<long>(aMtrFldShadowX.GetValue());
- nValueY = static_cast<long>(aMtrFldShadowY.GetValue());
+ nValueX = static_cast<long>(aMtrFldShadowX->GetValue());
+ nValueY = static_cast<long>(aMtrFldShadowY->GetValue());
}
XFormTextShadowXValItem aShadowXItem( nValueX );
@@ -770,7 +788,7 @@ IMPL_LINK_NOARG(SvxFontWorkDialog, InputTimoutHdl_Impl)
IMPL_LINK_NOARG(SvxFontWorkDialog, ColorSelectHdl_Impl)
{
- XFormTextShadowColorItem aItem( "", aShadowColorLB.GetSelectEntryColor() );
+ XFormTextShadowColorItem aItem( "", aShadowColorLB->GetSelectEntryColor() );
GetBindings().GetDispatcher()->Execute( SID_FORMTEXT_SHDWCOLOR, SfxCallMode::RECORD, &aItem, 0L );
return 0;
}
@@ -780,8 +798,8 @@ void SvxFontWorkDialog::SetColorList(const XColorListRef &pList)
if ( pList.is() && pList != pColorList )
{
pColorList = pList;
- aShadowColorLB.Clear();
- aShadowColorLB.Fill(pColorList);
+ aShadowColorLB->Clear();
+ aShadowColorLB->Fill(pColorList);
}
}
@@ -801,24 +819,24 @@ void SvxFontWorkDialog::ApplyImageList()
{
ImageList& rImgLst = maImageList;
- aTbxStyle.SetImageList( rImgLst );
- aTbxAdjust.SetImageList( rImgLst );
- aTbxShadow.SetImageList( rImgLst );
+ aTbxStyle->SetImageList( rImgLst );
+ aTbxAdjust->SetImageList( rImgLst );
+ aTbxShadow->SetImageList( rImgLst );
switch( nLastShadowTbxId )
{
case TBI_SHADOW_SLANT:
- aFbShadowX.SetImage( rImgLst.GetImage( TBI_SHADOW_ANGLE ) );
- aFbShadowY.SetImage( rImgLst.GetImage( TBI_SHADOW_SIZE ) );
+ aFbShadowX->SetImage( rImgLst.GetImage( TBI_SHADOW_ANGLE ) );
+ aFbShadowY->SetImage( rImgLst.GetImage( TBI_SHADOW_SIZE ) );
break;
default:
- aFbShadowX.SetImage( rImgLst.GetImage( TBI_SHADOW_XDIST ) );
- aFbShadowY.SetImage( rImgLst.GetImage( TBI_SHADOW_YDIST ) );
+ aFbShadowX->SetImage( rImgLst.GetImage( TBI_SHADOW_XDIST ) );
+ aFbShadowY->SetImage( rImgLst.GetImage( TBI_SHADOW_YDIST ) );
break;
}
- aFbDistance.SetImage( rImgLst.GetImage( TBI_DISTANCE ) );
- aFbTextStart.SetImage( rImgLst.GetImage( TBI_TEXTSTART ) );
+ aFbDistance->SetImage( rImgLst.GetImage( TBI_DISTANCE ) );
+ aFbTextStart->SetImage( rImgLst.GetImage( TBI_TEXTSTART ) );
}
diff --git a/svx/source/dialog/frmdirlbox.cxx b/svx/source/dialog/frmdirlbox.cxx
index de7ff69..5c2465d 100644
--- a/svx/source/dialog/frmdirlbox.cxx
+++ b/svx/source/dialog/frmdirlbox.cxx
@@ -44,10 +44,6 @@ FrameDirectionListBox::FrameDirectionListBox( vcl::Window* pParent, WinBits nBit
{
}
-FrameDirectionListBox::~FrameDirectionListBox()
-{
-}
-
extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeFrameDirectionListBox(vcl::Window *pParent, VclBuilder::stringmap &)
{
FrameDirectionListBox* pListBox = new FrameDirectionListBox(pParent, WB_LEFT|WB_DROPDOWN|WB_VCENTER|WB_3DLOOK|WB_TABSTOP);
diff --git a/svx/source/dialog/frmsel.cxx b/svx/source/dialog/frmsel.cxx
index 86772ce..46f04c1 100644
--- a/svx/source/dialog/frmsel.cxx
+++ b/svx/source/dialog/frmsel.cxx
@@ -269,6 +269,7 @@ FrameSelectorImpl::FrameSelectorImpl( FrameSelector& rFrameSel ) :
}
FrameSelectorImpl::~FrameSelectorImpl()
+
{
if( mpAccess )
mpAccess->Invalidate();
@@ -794,10 +795,6 @@ extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvxFrameSelector(vcl::
return new FrameSelector(pParent);
}
-FrameSelector::~FrameSelector()
-{
-}
-
void FrameSelector::Initialize( FrameSelFlags nFlags )
{
mxImpl->Initialize( nFlags );
diff --git a/svx/source/dialog/graphctl.cxx b/svx/source/dialog/graphctl.cxx
index 61f5a31..338dd71 100644
--- a/svx/source/dialog/graphctl.cxx
+++ b/svx/source/dialog/graphctl.cxx
@@ -84,6 +84,11 @@ extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeGraphCtrl(vcl::Window
GraphCtrl::~GraphCtrl()
{
+ dispose();
+}
+
+void GraphCtrl::dispose()
+{
if( mpAccContext )
{
mpAccContext->disposing();
@@ -92,6 +97,7 @@ GraphCtrl::~GraphCtrl()
delete pView;
delete pModel;
delete pUserCall;
+ Control::dispose();
}
void GraphCtrl::SetWinStyle( WinBits nWinBits )
diff --git a/svx/source/dialog/hdft.cxx b/svx/source/dialog/hdft.cxx
index 7c93eea..3a5f73d 100644
--- a/svx/source/dialog/hdft.cxx
+++ b/svx/source/dialog/hdft.cxx
@@ -220,7 +220,13 @@ SvxHFPage::SvxHFPage( vcl::Window* pParent, const SfxItemSet& rSet, sal_uInt16 n
SvxHFPage::~SvxHFPage()
{
+ dispose();
+}
+
+void SvxHFPage::dispose()
+{
delete pBBSet;
+ SfxTabPage::dispose();
}
diff --git a/svx/source/dialog/imapdlg.cxx b/svx/source/dialog/imapdlg.cxx
index 4e241c6..e1738e6 100644
--- a/svx/source/dialog/imapdlg.cxx
+++ b/svx/source/dialog/imapdlg.cxx
@@ -217,9 +217,15 @@ SvxIMapDlg::SvxIMapDlg(SfxBindings *_pBindings, SfxChildWindow *pCW, vcl::Window
SvxIMapDlg::~SvxIMapDlg()
{
+ dispose();
+}
+
+void SvxIMapDlg::dispose()
+{
// Delete URL-List
delete pIMapWnd;
delete pOwnData;
+ SfxModelessDialog::dispose();
}
bool SvxIMapDlg::Close()
diff --git a/svx/source/dialog/imapwnd.cxx b/svx/source/dialog/imapwnd.cxx
index 054b674..b76b1b3 100644
--- a/svx/source/dialog/imapwnd.cxx
+++ b/svx/source/dialog/imapwnd.cxx
@@ -72,8 +72,14 @@ IMapWindow::IMapWindow( vcl::Window* pParent, WinBits nBits, const Reference< XF
IMapWindow::~IMapWindow()
{
+ dispose();
+}
+
+void IMapWindow::dispose()
+{
SfxItemPool::Free(pIMapPool);
delete[] pItemInfo;
+ GraphCtrl::dispose();
}
Size IMapWindow::GetOptimalSize() const
diff --git a/svx/source/dialog/imapwnd.hxx b/svx/source/dialog/imapwnd.hxx
index 3d88924..9969c56 100644
--- a/svx/source/dialog/imapwnd.hxx
+++ b/svx/source/dialog/imapwnd.hxx
@@ -134,6 +134,7 @@ public:
IMapWindow( vcl::Window* pParent, WinBits nBits, const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& rxDocumentFrame );
virtual ~IMapWindow();
+ virtual void dispose() SAL_OVERRIDE;
bool ReplaceActualIMapInfo( const NotifyInfo& rNewInfo );
diff --git a/svx/source/dialog/langbox.cxx b/svx/source/dialog/langbox.cxx
index e8a0128..0e8770f 100644
--- a/svx/source/dialog/langbox.cxx
+++ b/svx/source/dialog/langbox.cxx
@@ -502,11 +502,6 @@ SvxLanguageBox::SvxLanguageBox( vcl::Window* pParent, WinBits nBits, bool bCheck
ImplLanguageBoxBaseInit();
}
-SvxLanguageBox::~SvxLanguageBox()
-{
-}
-
-
SvxLanguageComboBox::SvxLanguageComboBox( vcl::Window* pParent, WinBits nBits, bool bCheck )
: ComboBox( pParent, nBits )
, SvxLanguageBoxBase( bCheck )
@@ -523,11 +518,6 @@ SvxLanguageComboBox::SvxLanguageComboBox( vcl::Window* pParent, WinBits nBits, b
SetModifyHdl( LINK( this, SvxLanguageComboBox, EditModifyHdl ) );
}
-SvxLanguageComboBox::~SvxLanguageComboBox()
-{
-}
-
-
sal_Int32 SvxLanguageBox::ImplInsertImgEntry( const OUString& rEntry, sal_Int32 nPos, bool bChecked )
{
return InsertEntry( rEntry, (bChecked ? m_aCheckedImage : m_aNotCheckedImage), nPos );
diff --git a/svx/source/dialog/linkwarn.cxx b/svx/source/dialog/linkwarn.cxx
index 9015d1a..a256374 100644
--- a/svx/source/dialog/linkwarn.cxx
+++ b/svx/source/dialog/linkwarn.cxx
@@ -43,11 +43,17 @@ SvxLinkWarningDialog::SvxLinkWarningDialog( vcl::Window* pParent, const OUString
SvxLinkWarningDialog::~SvxLinkWarningDialog()
{
+ dispose();
+}
+
+void SvxLinkWarningDialog::dispose()
+{
// save value of "warning off" checkbox, if necessary
SvtMiscOptions aMiscOpt;
bool bChecked = m_pWarningOnBox->IsChecked();
if ( aMiscOpt.ShowLinkWarningDialog() != bChecked )
aMiscOpt.SetShowLinkWarningDialog( bChecked );
+ MessageDialog::dispose();
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/measctrl.cxx b/svx/source/dialog/measctrl.cxx
index 8810a87..3476dc7 100644
--- a/svx/source/dialog/measctrl.cxx
+++ b/svx/source/dialog/measctrl.cxx
@@ -78,6 +78,11 @@ Size SvxXMeasurePreview::GetOptimalSize() const
SvxXMeasurePreview::~SvxXMeasurePreview()
{
+ dispose();
+}
+
+void SvxXMeasurePreview::dispose()
+{
// No one is deleting the MeasureObj? This is not only an error but also
// a memory leak (!). Main problem is that this object is still listening to
// a StyleSheet of the model which was set. Thus, if You want to keep the obnject,
@@ -86,6 +91,7 @@ SvxXMeasurePreview::~SvxXMeasurePreview()
delete pMeasureObj;
delete pModel;
+ Control::dispose();
}
void SvxXMeasurePreview::Paint( const Rectangle& )
diff --git a/svx/source/dialog/pagectrl.cxx b/svx/source/dialog/pagectrl.cxx
index 08a7e9c..6b6c245 100644
--- a/svx/source/dialog/pagectrl.cxx
+++ b/svx/source/dialog/pagectrl.cxx
@@ -90,8 +90,14 @@ SvxPageWindow::SvxPageWindow(vcl::Window* pParent)
SvxPageWindow::~SvxPageWindow()
{
+ dispose();
+}
+
+void SvxPageWindow::dispose()
+{
delete pHdBorder;
delete pFtBorder;
+ vcl::Window::dispose();
}
extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSvxPageWindow(vcl::Window *pParent, VclBuilder::stringmap &)
diff --git a/svx/source/dialog/passwd.cxx b/svx/source/dialog/passwd.cxx
index c794ebb..8f80ab8 100644
--- a/svx/source/dialog/passwd.cxx
+++ b/svx/source/dialog/passwd.cxx
@@ -99,11 +99,4 @@ SvxPasswordDialog::SvxPasswordDialog(vcl::Window* pParent, bool bAllowEmptyPassw
-SvxPasswordDialog::~SvxPasswordDialog()
-{
-}
-
-
-
-
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/prtqry.cxx b/svx/source/dialog/prtqry.cxx
index 14a2c9a..0b831f8 100644
--- a/svx/source/dialog/prtqry.cxx
+++ b/svx/source/dialog/prtqry.cxx
@@ -37,9 +37,4 @@ SvxPrtQryBox::SvxPrtQryBox(vcl::Window* pParent) :
SetButtonHelpText( RET_OK, OUString() );
}
-SvxPrtQryBox::~SvxPrtQryBox()
-{
-}
-
-
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/rubydialog.cxx b/svx/source/dialog/rubydialog.cxx
index c44d7b2..ce331c8 100644
--- a/svx/source/dialog/rubydialog.cxx
+++ b/svx/source/dialog/rubydialog.cxx
@@ -263,9 +263,15 @@ SvxRubyDialog::SvxRubyDialog(SfxBindings *pBind, SfxChildWindow *pCW,
SvxRubyDialog::~SvxRubyDialog()
{
+ dispose();
+}
+
+void SvxRubyDialog::dispose()
+{
ClearCharStyleList();
EventObject aEvent;
xImpl->disposing(aEvent);
+ SfxModelessDialog::dispose();
}
void SvxRubyDialog::ClearCharStyleList()
diff --git a/svx/source/dialog/srchdlg.cxx b/svx/source/dialog/srchdlg.cxx
index 1118a09..7d07a6b 100644
--- a/svx/source/dialog/srchdlg.cxx
+++ b/svx/source/dialog/srchdlg.cxx
@@ -344,6 +344,11 @@ SvxSearchDialog::SvxSearchDialog( vcl::Window* pParent, SfxChildWindow* pChildWi
SvxSearchDialog::~SvxSearchDialog()
{
+ dispose();
+}
+
+void SvxSearchDialog::dispose()
+{
Hide();
rBindings.EnterRegistrations();
@@ -358,6 +363,7 @@ SvxSearchDialog::~SvxSearchDialog()
delete pImpl;
delete pSearchList;
delete pReplaceList;
+ SfxModelessDialog::dispose();
}
void SvxSearchDialog::Construct_Impl()
diff --git a/svx/source/dialog/stddlg.cxx b/svx/source/dialog/stddlg.cxx
index d06e524..9ae4ca2 100644
--- a/svx/source/dialog/stddlg.cxx
+++ b/svx/source/dialog/stddlg.cxx
@@ -35,8 +35,4 @@ SvxStandardDialog::SvxStandardDialog(vcl::Window *pParent, const OUString& rID,
{
}
-SvxStandardDialog::~SvxStandardDialog()
-{
-}
-
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/svxruler.cxx b/svx/source/dialog/svxruler.cxx
index a7b287a..287c643 100644
--- a/svx/source/dialog/svxruler.cxx
+++ b/svx/source/dialog/svxruler.cxx
@@ -316,6 +316,11 @@ SvxRuler::SvxRuler(
SvxRuler::~SvxRuler()
{
+ dispose();
+}
+
+void SvxRuler::dispose()
+{
/* Destructor ruler; release internal buffer */
REMOVE_DEBUG_WINDOW
if(bListening)
@@ -328,6 +333,7 @@ SvxRuler::~SvxRuler()
delete[] pCtrlItem;
pBindings->LeaveRegistrations();
+ Ruler::dispose();
}
long SvxRuler::MakePositionSticky(long aPosition, long aPointOfReference, bool aSnapToFrameMargin) const
diff --git a/svx/source/engine3d/float3d.cxx b/svx/source/engine3d/float3d.cxx
index b584e5d..d054e39 100644
--- a/svx/source/engine3d/float3d.cxx
+++ b/svx/source/engine3d/float3d.cxx
@@ -87,13 +87,13 @@ Svx3DWin::Svx3DWin( SfxBindings* pInBindings,
SfxChildWindow *pCW, vcl::Window* pParent ) :
SfxDockingWindow ( pInBindings, pCW, pParent,
SVX_RES( RID_SVXFLOAT_3D ) ),
- aBtnGeo ( this, SVX_RES( BTN_GEO ) ),
- aBtnRepresentation ( this, SVX_RES( BTN_REPRESENTATION ) ),
- aBtnLight ( this, SVX_RES( BTN_LIGHT ) ),
- aBtnTexture ( this, SVX_RES( BTN_TEXTURE ) ),
- aBtnMaterial ( this, SVX_RES( BTN_MATERIAL ) ),
- aBtnUpdate ( this, SVX_RES( BTN_UPDATE ) ),
- aBtnAssign ( this, SVX_RES( BTN_ASSIGN ) ),
+ aBtnGeo ( new ImageButton(this, SVX_RES( BTN_GEO ) ) ),
... etc. - the rest is truncated
More information about the Libreoffice-commits
mailing list