summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndras Timar <andras.timar@collabora.com>2015-10-28 12:39:56 -0700
committerMichael Stahl <mstahl@redhat.com>2015-10-28 20:14:47 +0000
commita66bd32b78a8e88f24690452a96bf3f248bfa004 (patch)
tree1329da8810e099595914f3fdfc4dbf013233acd3
parent93a007b1b02c13025b08bcefe19dd54e24e2b80f (diff)
tdf#91270 fix crash on exit (Windows)
dynamic atexit destructor and const static variables reportedly cause crash, let's avoid this. Change-Id: I24234084f810854606dde9914bee1c98ebc2e3dd Reviewed-on: https://gerrit.libreoffice.org/19656 Reviewed-by: Michael Stahl <mstahl@redhat.com> Tested-by: Michael Stahl <mstahl@redhat.com>
-rw-r--r--sw/source/uibase/inc/redlndlg.hxx7
-rw-r--r--sw/source/uibase/misc/redlndlg.cxx16
2 files changed, 15 insertions, 8 deletions
diff --git a/sw/source/uibase/inc/redlndlg.hxx b/sw/source/uibase/inc/redlndlg.hxx
index 3c7b4810f97a..7180373da52b 100644
--- a/sw/source/uibase/inc/redlndlg.hxx
+++ b/sw/source/uibase/inc/redlndlg.hxx
@@ -89,6 +89,13 @@ class SW_DLLPUBLIC SwRedlineAcceptDlg
// prevent update dialog data during longer operations (cf #102657#)
bool bInhibitActivate;
+ Image aInserted;
+ Image aDeleted;
+ Image aFormated;
+ Image aTableChgd;
+ Image aFormatCollSet;
+ Image aAutoFormat;
+
DECL_DLLPRIVATE_LINK_TYPED( AcceptHdl, SvxTPView*, void );
DECL_DLLPRIVATE_LINK_TYPED( AcceptAllHdl, SvxTPView*, void );
DECL_DLLPRIVATE_LINK_TYPED( RejectHdl, SvxTPView*, void );
diff --git a/sw/source/uibase/misc/redlndlg.cxx b/sw/source/uibase/misc/redlndlg.cxx
index 9bf3477a8833..81429200ab72 100644
--- a/sw/source/uibase/misc/redlndlg.cxx
+++ b/sw/source/uibase/misc/redlndlg.cxx
@@ -160,7 +160,14 @@ SwRedlineAcceptDlg::SwRedlineAcceptDlg(vcl::Window *pParent, VclBuilderContainer
bOnlyFormatedRedlines( false ),
bHasReadonlySel ( false ),
bRedlnAutoFormat (bAutoFormat),
- bInhibitActivate( false )
+ bInhibitActivate( false ),
+ aInserted (SW_RES(IMG_REDLINE_INSERTED)),
+ aDeleted (SW_RES(IMG_REDLINE_DELETED)),
+ aFormated (SW_RES(IMG_REDLINE_FORMATED)),
+ aTableChgd (SW_RES(IMG_REDLINE_TABLECHG)),
+ aFormatCollSet (SW_RES(IMG_REDLINE_FMTCOLLSET)),
+ aAutoFormat (SW_RES(IMG_REDLINE_AUTOFMT))
+
{
aTabPagesCTRL->SetHelpId(HID_REDLINE_CTRL);
pTPView = aTabPagesCTRL->GetViewPage();
@@ -338,13 +345,6 @@ OUString SwRedlineAcceptDlg::GetRedlineText(const SwRangeRedline& rRedln, DateTi
Image SwRedlineAcceptDlg::GetActionImage(const SwRangeRedline& rRedln, sal_uInt16 nStack)
{
- const static Image aInserted(SW_RES(IMG_REDLINE_INSERTED));
- const static Image aDeleted(SW_RES(IMG_REDLINE_DELETED));
- const static Image aFormated(SW_RES(IMG_REDLINE_FORMATED));
- const static Image aTableChgd(SW_RES(IMG_REDLINE_TABLECHG));
- const static Image aFormatCollSet(SW_RES(IMG_REDLINE_FMTCOLLSET));
- const static Image aAutoFormat(SW_RES(IMG_REDLINE_AUTOFMT));
-
switch (rRedln.GetType(nStack))
{
case nsRedlineType_t::REDLINE_INSERT: return aInserted;