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

Eike Rathke (via logerrit) logerrit at kemper.freedesktop.org
Thu Oct 7 10:53:41 UTC 2021


 sc/source/core/data/documen5.cxx |    4 ++--
 sc/source/ui/docshell/docsh4.cxx |    2 +-
 sc/source/ui/view/gridwin.cxx    |    3 ++-
 3 files changed, 5 insertions(+), 4 deletions(-)

New commits:
commit 852292feee08b4d256f8255926e1f84b4c6fd4b6
Author:     Eike Rathke <erack at redhat.com>
AuthorDate: Wed Oct 6 22:16:30 2021 +0200
Commit:     Eike Rathke <erack at redhat.com>
CommitDate: Thu Oct 7 12:53:09 2021 +0200

    Related: tdf#144970 Make Drag&Drop of Chart range work with UI representation
    
    Drag&Drop of cell range onto an existing Chart worked with Calc A1
    but not Excel A1 or R1C1 address syntax conventions.
    
    Change-Id: I1cd1a134f284ef5b28237589c544f93cb4aca841
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/123197
    Reviewed-by: Eike Rathke <erack at redhat.com>
    Tested-by: Jenkins

diff --git a/sc/source/core/data/documen5.cxx b/sc/source/core/data/documen5.cxx
index 60d6d6cf068b..68bb7b4a7444 100644
--- a/sc/source/core/data/documen5.cxx
+++ b/sc/source/core/data/documen5.cxx
@@ -229,7 +229,7 @@ void ScDocument::GetOldChartParameters( std::u16string_view rName,
                     OUString aRangesStr;
                     lcl_GetChartParameters( xChartDoc, aRangesStr, eDataRowSource, bHasCategories, bFirstCellAsLabel );
 
-                    rRanges.Parse( aRangesStr, *this );
+                    rRanges.Parse( aRangesStr, *this, GetAddressConvention());
                     if ( eDataRowSource == chart::ChartDataRowSource_COLUMNS )
                     {
                         rRowHeaders = bHasCategories;
@@ -285,7 +285,7 @@ void ScDocument::UpdateChartArea( const OUString& rChartName,
                         // append to old ranges, keep other settings
 
                         aNewRanges = new ScRangeList;
-                        aNewRanges->Parse( aRangesStr, *this );
+                        aNewRanges->Parse( aRangesStr, *this, GetAddressConvention());
 
                         for ( size_t nAdd = 0, nAddCount = rNewList->size(); nAdd < nAddCount; ++nAdd )
                             aNewRanges->push_back( (*rNewList)[nAdd] );
diff --git a/sc/source/ui/docshell/docsh4.cxx b/sc/source/ui/docshell/docsh4.cxx
index 951f0fe96823..bba2d90a0a71 100644
--- a/sc/source/ui/docshell/docsh4.cxx
+++ b/sc/source/ui/docshell/docsh4.cxx
@@ -384,7 +384,7 @@ void ScDocShell::Execute( SfxRequest& rReq )
                 if (!bValid)
                 {
                     aRangeListRef = new ScRangeList;
-                    aRangeListRef->Parse( aRangeName, rDoc );
+                    aRangeListRef->Parse( aRangeName, rDoc, rDoc.GetAddressConvention());
                     if ( !aRangeListRef->empty() )
                     {
                         bMultiRange = true;
diff --git a/sc/source/ui/view/gridwin.cxx b/sc/source/ui/view/gridwin.cxx
index 4f65327b4a4d..facbba012fe2 100644
--- a/sc/source/ui/view/gridwin.cxx
+++ b/sc/source/ui/view/gridwin.cxx
@@ -4230,7 +4230,8 @@ sal_Int8 ScGridWindow::DropTransferObj( ScTransferObj* pTransObj, SCCOL nDestPos
             OUString aChartName;
             if (rThisDoc.HasChartAtPoint( nThisTab, rLogicPos, aChartName ))
             {
-                OUString aRangeName(aSource.Format(rThisDoc, ScRefFlags::RANGE_ABS_3D));
+                OUString aRangeName(aSource.Format(rThisDoc, ScRefFlags::RANGE_ABS_3D,
+                            rThisDoc.GetAddressConvention()));
                 SfxStringItem aNameItem( SID_CHART_NAME, aChartName );
                 SfxStringItem aRangeItem( SID_CHART_SOURCE, aRangeName );
                 sal_uInt16 nId = bIsMove ? SID_CHART_SOURCE : SID_CHART_ADDSOURCE;


More information about the Libreoffice-commits mailing list