include/vcl/treelistbox.hxx | 4 +--- vcl/source/treelist/svimpbox.cxx | 2 +- vcl/source/treelist/treelistbox.cxx | 13 +------------ 3 files changed, 3 insertions(+), 16 deletions(-)
New commits: commit ccf40c0efcc371e3d5818df20af18bc10c3601bd Author: Noel Grandin <noel.gran...@collabora.co.uk> AuthorDate: Fri Apr 24 11:34:45 2020 +0200 Commit: Noel Grandin <noel.gran...@collabora.co.uk> CommitDate: Fri Apr 24 14:49:19 2020 +0200 loplugin:unusedenumconstants DragDropMode Change-Id: Ifb42ec521bcd74d54cc3e90a7720964340104174 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/92844 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.gran...@collabora.co.uk> diff --git a/include/vcl/treelistbox.hxx b/include/vcl/treelistbox.hxx index f00e5ac78582..bbb77cc7a43e 100644 --- a/include/vcl/treelistbox.hxx +++ b/include/vcl/treelistbox.hxx @@ -149,9 +149,7 @@ enum class DragDropMode NONE = 0x0000, CTRL_MOVE = 0x0001, CTRL_COPY = 0x0002, - APP_MOVE = 0x0004, APP_COPY = 0x0008, - APP_DROP = 0x0010, // Entries may be dropped via the uppermost Entry // The DropTarget is 0 in that case ENABLE_TOP = 0x0020, @@ -159,7 +157,7 @@ enum class DragDropMode }; namespace o3tl { - template<> struct typed_flags<DragDropMode> : is_typed_flags<DragDropMode, 0x003f> {}; + template<> struct typed_flags<DragDropMode> : is_typed_flags<DragDropMode, 0x003b> {}; } enum class SvTreeListBoxFlags diff --git a/vcl/source/treelist/svimpbox.cxx b/vcl/source/treelist/svimpbox.cxx index 3f52d42ad49b..64016e99b691 100644 --- a/vcl/source/treelist/svimpbox.cxx +++ b/vcl/source/treelist/svimpbox.cxx @@ -2824,7 +2824,7 @@ void SvImpLBox::SetSelectionMode( SelectionMode eSelMode ) void SvImpLBox::SetDragDropMode( DragDropMode eDDMode ) { - if( eDDMode != DragDropMode::NONE && eDDMode != DragDropMode::APP_DROP ) + if( eDDMode != DragDropMode::NONE ) { m_aSelEng.ExpandSelectionOnMouseMove( false ); m_aSelEng.EnableDrag( true ); diff --git a/vcl/source/treelist/treelistbox.cxx b/vcl/source/treelist/treelistbox.cxx index e295308dbd5b..5d84d716e6ae 100644 --- a/vcl/source/treelist/treelistbox.cxx +++ b/vcl/source/treelist/treelistbox.cxx @@ -479,18 +479,7 @@ bool SvTreeListBox::CheckDragAndDropMode( SvTreeListBox const * pSource, sal_Int } else { - if ( !(nDragDropMode & DragDropMode::APP_DROP ) ) - return false; // no drop - if ( DND_ACTION_MOVE == nAction ) - { - if ( !(nDragDropMode & DragDropMode::APP_MOVE) ) - return false; // no global move - } - else - { - if ( !(nDragDropMode & DragDropMode::APP_COPY)) - return false; // no global copy - } + return false; // no drop } return true; } _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits