summaryrefslogtreecommitdiff
path: root/sc/inc/autoform.hxx
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2018-02-02 12:41:42 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2018-02-03 16:04:17 +0100
commite3308af401013713bbfe27b6df9952586c52f4aa (patch)
treed498f4a3bfefef5a4c964986cf76d86201ba58e8 /sc/inc/autoform.hxx
parenta4fbb496ef001d62fce0ad3cdd7a829f99aa182e (diff)
TypedWhichId in sc
Change-Id: I43558191f65bfb07abfbc92970629d5dd561a04e Reviewed-on: https://gerrit.libreoffice.org/49141 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sc/inc/autoform.hxx')
-rw-r--r--sc/inc/autoform.hxx4
1 files changed, 4 insertions, 0 deletions
diff --git a/sc/inc/autoform.hxx b/sc/inc/autoform.hxx
index bb9b886f3e44..b1559dc264de 100644
--- a/sc/inc/autoform.hxx
+++ b/sc/inc/autoform.hxx
@@ -290,6 +290,10 @@ public:
void SetIncludeWidthHeight( bool bWidthHeight ) { bIncludeWidthHeight = bWidthHeight; }
const SfxPoolItem* GetItem( sal_uInt16 nIndex, sal_uInt16 nWhich ) const;
+ template<class T> const T* GetItem( sal_uInt16 nIndex, TypedWhichId<T> nWhich ) const
+ {
+ return static_cast<const T*>(GetItem(nIndex, sal_uInt16(nWhich)));
+ }
void PutItem( sal_uInt16 nIndex, const SfxPoolItem& rItem );
void CopyItem( sal_uInt16 nToIndex, sal_uInt16 nFromIndex, sal_uInt16 nWhich );