summaryrefslogtreecommitdiff
path: root/sc/source/ui/app/inputhdl.cxx
diff options
context:
space:
mode:
authorPranam Lashkari <lpranam@collabora.com>2021-02-23 20:35:34 +0530
committerPranam Lashkari <lpranam@collabora.com>2021-02-24 10:31:47 +0100
commitd03f4f5838093013ddb201e352f0cb7aaaa26453 (patch)
tree743a32cc0906b0e0b291143e1575564779279097 /sc/source/ui/app/inputhdl.cxx
parent7a6c6712698efc4cdf4b941db565634aae73279c (diff)
show reference range specific to only selected calc sheet
Problem: when switching tab in online reference range would not change according to tabs this would show incorrect reference range Change-Id: I07e072a74b2925a25b7a4a50ce0c238308d99ebf Reviewed-on: https://gerrit.libreoffice.org/c/core/+/111409 Tested-by: Jenkins Reviewed-by: Pranam Lashkari <lpranam@collabora.com>
Diffstat (limited to 'sc/source/ui/app/inputhdl.cxx')
-rw-r--r--sc/source/ui/app/inputhdl.cxx5
1 files changed, 4 insertions, 1 deletions
diff --git a/sc/source/ui/app/inputhdl.cxx b/sc/source/ui/app/inputhdl.cxx
index 81c434a7055f..7465205fa089 100644
--- a/sc/source/ui/app/inputhdl.cxx
+++ b/sc/source/ui/app/inputhdl.cxx
@@ -502,7 +502,10 @@ void ScInputHandler::UpdateLokReferenceMarks()
tools::Long nX2 = rViewData.GetRefEndX();
tools::Long nY1 = rViewData.GetRefStartY();
tools::Long nY2 = rViewData.GetRefEndY();
- tools::Long nTab = rViewData.GetTabNo();
+ tools::Long nTab = rViewData.GetRefStartZ();
+
+ if (rViewData.GetRefEndZ() == rViewData.GetTabNo())
+ nTab = rViewData.GetRefEndZ();
PutInOrder(nX1, nX2);
PutInOrder(nY1, nY2);