[Libreoffice-commits] core.git: sc/source
Stephan Bergmann
sbergman at redhat.com
Thu May 18 13:15:43 UTC 2017
sc/source/ui/pagedlg/tptable.cxx | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
New commits:
commit 4544256d6e9fd502ec3cb94a834a8ca804b963d8
Author: Stephan Bergmann <sbergman at redhat.com>
Date: Thu May 18 15:13:59 2017 +0200
Replace macro with function
Change-Id: I005622c607a5a3dcd31b46f6e819546b7ece630b
diff --git a/sc/source/ui/pagedlg/tptable.cxx b/sc/source/ui/pagedlg/tptable.cxx
index 1190ef82fbc7..90754c32d1cc 100644
--- a/sc/source/ui/pagedlg/tptable.cxx
+++ b/sc/source/ui/pagedlg/tptable.cxx
@@ -68,7 +68,13 @@ static bool lcl_PutBoolItem( sal_uInt16 nWhich,
#define PAGENO_HDL LINK(this,ScTablePage,PageNoHdl)
#define PAGEDIR_HDL LINK(this,ScTablePage,PageDirHdl)
-#define WAS_DEFAULT(w,s) (SfxItemState::DEFAULT==(s).GetItemState((w)))
+namespace {
+
+bool WAS_DEFAULT(sal_uInt16 w, SfxItemSet const & s)
+{ return SfxItemState::DEFAULT==s.GetItemState(w); }
+
+}
+
#define GET_BOOL(sid,set) static_cast<const SfxBoolItem&>((set).Get(GetWhich((sid)))).GetValue()
#define GET_USHORT(sid,set) static_cast<const SfxUInt16Item&>((set).Get(GetWhich((sid)))).GetValue()
#define GET_SHOW(sid,set) ( ScVObjMode( static_cast<const ScViewObjectModeItem&>((set).Get(GetWhich((sid)))).GetValue() ) \
More information about the Libreoffice-commits
mailing list