[Libreoffice-commits] core.git: sc/source

Caolán McNamara (via logerrit) logerrit at kemper.freedesktop.org
Wed Jan 13 14:36:43 UTC 2021


 sc/source/ui/navipi/content.cxx |    8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

New commits:
commit 1095b7bdf1bb33b3dc0fb5ae73342ae6ca0396fc
Author:     Caolán McNamara <caolanm at redhat.com>
AuthorDate: Wed Jan 13 10:15:19 2021 +0000
Commit:     Caolán McNamara <caolanm at redhat.com>
CommitDate: Wed Jan 13 15:35:58 2021 +0100

    Resolves: tdf#138972 dnd is moving instead of copying the data
    
    Change-Id: Icb2a3882704bf38c14b7a46154d51c3171268ca6
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109220
    Tested-by: Jenkins
    Reviewed-by: Caolán McNamara <caolanm at redhat.com>

diff --git a/sc/source/ui/navipi/content.cxx b/sc/source/ui/navipi/content.cxx
index 0ad984f3a25a..27308f4bc9eb 100644
--- a/sc/source/ui/navipi/content.cxx
+++ b/sc/source/ui/navipi/content.cxx
@@ -143,7 +143,7 @@ ScContentTree::ScContentTree(std::unique_ptr<weld::TreeView> xTreeView, ScNaviga
     m_xTreeView->connect_query_tooltip(LINK(this, ScContentTree, QueryTooltipHdl));
 
     rtl::Reference<TransferDataContainer> xHelper(m_xTransferObj.get());
-    m_xTreeView->enable_drag_source(xHelper, DND_ACTION_COPYMOVE | DND_ACTION_LINK);
+    m_xTreeView->enable_drag_source(xHelper, DND_ACTION_COPY | DND_ACTION_LINK);
 
     m_xTreeView->connect_drag_begin(LINK(this, ScContentTree, DragBeginHdl));
 }
@@ -1176,7 +1176,7 @@ static bool lcl_DoDragObject( ScDocShell* pSrcShell, std::u16string_view rName,
             SC_MOD()->SetDragObject( nullptr, pTransferObj.get() );
 
             rtl::Reference<TransferDataContainer> xHelper(pTransferObj.get());
-            rTreeView.enable_drag_source(xHelper, DND_ACTION_COPYMOVE | DND_ACTION_LINK);
+            rTreeView.enable_drag_source(xHelper, DND_ACTION_COPY | DND_ACTION_LINK);
 
             bDisallow = false;
         }
@@ -1216,7 +1216,7 @@ static bool lcl_DoDragCells( ScDocShell* pSrcShell, const ScRange& rRange, ScDra
         SC_MOD()->SetDragObject( pTransferObj.get(), nullptr );      // for internal D&D
 
         rtl::Reference<TransferDataContainer> xHelper(pTransferObj.get());
-        rTreeView.enable_drag_source(xHelper, DND_ACTION_COPYMOVE | DND_ACTION_LINK);
+        rTreeView.enable_drag_source(xHelper, DND_ACTION_COPY | DND_ACTION_LINK);
 
         bDisallow = false;
     }
@@ -1370,7 +1370,7 @@ IMPL_LINK(ScContentTree, DragBeginHdl, bool&, rUnsetDragIcon, bool)
                 m_xTransferObj->SetLinkURL(aLinkURL, aLinkText);
 
             rtl::Reference<TransferDataContainer> xHelper(m_xTransferObj.get());
-            m_xTreeView->enable_drag_source(xHelper, DND_ACTION_COPYMOVE | DND_ACTION_LINK);
+            m_xTreeView->enable_drag_source(xHelper, DND_ACTION_COPY | DND_ACTION_LINK);
 
             bDisallow = false;
         }


More information about the Libreoffice-commits mailing list