diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2017-05-23 16:58:18 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2017-05-24 08:46:48 +0200 |
commit | bfafda5829f75091c9db798f953d617cde688a1f (patch) | |
tree | 0f0c4eb9c4e53d7d726e2cb4de0488a396a7945e /sw | |
parent | 12fc1372f0e581348c70ad9d817b54c390f0e1cc (diff) |
tdf#107866 - Changing table column width with Alt+arrow key strokes is broken
regression from commit 890d6790715c4c3f3565b476d538643f04dc6936
"convert TableChgWidthHeightType to o3tl::typed_flags"
Change-Id: Ia1c3ec09d23ffe502dd8cb0ab673e45935bd4909
Reviewed-on: https://gerrit.libreoffice.org/37956
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sw')
-rw-r--r-- | sw/inc/tblenum.hxx | 2 | ||||
-rw-r--r-- | sw/source/core/frmedt/fetab.cxx | 3 |
2 files changed, 3 insertions, 2 deletions
diff --git a/sw/inc/tblenum.hxx b/sw/inc/tblenum.hxx index 327d0ea52e37..bf9570f17fec 100644 --- a/sw/inc/tblenum.hxx +++ b/sw/inc/tblenum.hxx @@ -45,7 +45,7 @@ namespace o3tl { template<> struct typed_flags<TableChgWidthHeightType> : is_typed_flags<TableChgWidthHeightType, 0xc00f> {}; } constexpr TableChgWidthHeightType extractPosition(TableChgWidthHeightType e) { - return static_cast<TableChgWidthHeightType>(static_cast<int>(e) & 0xf); + return static_cast<TableChgWidthHeightType>(static_cast<sal_uInt16>(e) & 0xf); } enum class TableChgMode diff --git a/sw/source/core/frmedt/fetab.cxx b/sw/source/core/frmedt/fetab.cxx index 62e84aaeef01..3162adff5e6d 100644 --- a/sw/source/core/frmedt/fetab.cxx +++ b/sw/source/core/frmedt/fetab.cxx @@ -2190,7 +2190,8 @@ bool SwFEShell::SetColRowWidthHeight( TableChgWidthHeightType eType, sal_uInt16 pTab->GetFormat()->SetFormatAttr( aSz ); } - if( eType & (TableChgWidthHeightType::BiggerMode | TableChgWidthHeightType::InsertDeleteMode) ) + if( extractPosition(eType) == TableChgWidthHeightType::ColLeft && + (eType & (TableChgWidthHeightType::BiggerMode | TableChgWidthHeightType::InsertDeleteMode)) ) { nDiff = sal_uInt16(aRectFnSet.GetWidth(pFrame->Frame())); |