Bug 125106 - Calc Cell Protection - unable to change protection state of a mixed group of cells
Summary: Calc Cell Protection - unable to change protection state of a mixed group of ...
Status: VERIFIED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
6.2.0.1 rc
Hardware: All All
: medium normal
Assignee: Caolán McNamara
URL:
Whiteboard: target:6.3.0 target:6.2.5 target:6.2.4
Keywords: bibisected, bisected, regression
Depends on:
Blocks:
 
Reported: 2019-05-03 14:40 UTC by rosma
Modified: 2019-05-22 13:51 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:
Regression By:


Attachments
sample file (6.95 KB, application/vnd.oasis.opendocument.spreadsheet)
2019-05-03 15:26 UTC, Xisco Faulí
Details

Note You need to log in before you can comment on or make changes to this bug.
Description rosma 2019-05-03 14:40:27 UTC
Description:
With the sheet protection turned off, selecting a group which contains both protected and unprotected cells, then trying to use Format Cells - Cell Protection to either change all cells to the protected or unprotected state does not work.

The Protected box in the Cell Protection menu is fixed as a horizontal dash, in earlier versions of LibreOffice this could be toggled between ticked and cleared so all cells were changed to the same protection state.

Steps to Reproduce:
1. Use Tools and untick Protect Sheet...
2. Select some cells which have been protected and some which are unprotected.
3. Select Format Cells.. and then Cell Protection.
4. Click on the Protected box.

Actual Results:
The Protected box shows a fixed horizontal dash (-). This does not change if you keep clicking on it.

Expected Results:
When you repeatedly click on the Protected box this cycles through a clear state (all cells unprotected), a dash (some cells in both states) and a ticked state (all cells protected).


Reproducible: Always


User Profile Reset: Yes



Additional Info:
All of the boxes - Hide All, Protected, Hide formula and Hide when printing - show the same problem.

Earliest release version with the problem is
Version: 6.2.0.1
Build ID: 0412ee99e862f384c1106d0841a950c4cfaa9df1
CPU threads: 2; OS: Linux 4.15; UI render: default; VCL: gtk3; 
Locale: en-GB (en_GB.UTF-8); UI-Language: en-GB
Calc: threaded

Problem still exists on the two versions shown below.

Version: 6.2.4.0.0+
Build ID: df02927207ad19532f5c1ac5a5cf745559e47c22

Version: 6.3.0.0.alpha0+
Build ID: 96ab20756316b25b7f2343a15596bc5114ea5a68

Version 6.1.5.2 works correctly as expected.
Comment 1 Xisco Faulí 2019-05-03 15:25:27 UTC
Regression introduced by:

author	Caolán McNamara <caolanm@redhat.com>	2018-09-25 12:30:21 +0100
committer	Caolán McNamara <caolanm@redhat.com>	2018-09-28 15:35:22 +0200
commit 3c11aa745cc78f1bde4efacccb22fa818df825c7 (patch)
tree 09135c2ec9f77b09d371418476a5b6fd6acc54d0
parent a98058199410bdb183acd0ec5e7899ea4baf6c5a (diff)
weld ScAttrDlg

https://cgit.freedesktop.org/libreoffice/core/commit/?id=3c11aa745cc78f1bde4efacccb22fa818df825c7

Bisected with: bibisect-linux64-6.2

Adding Cc: to Caolán McNamara
Comment 2 Xisco Faulí 2019-05-03 15:26:06 UTC
Created attachment 151163 [details]
sample file

How to reproduce it:
1. Open attached file
2. Select all
3. Format - Cell
4. Protected cell
Comment 3 Commit Notification 2019-05-07 15:17:27 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/+/eef7b7c467c44f86ce77f1ec483ca05f176440a7%5E%21

Resolves: tdf#125106 fix cell protect TriState toggles

It will be available in 6.3.0.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 4 Caolán McNamara 2019-05-07 15:18:12 UTC
fixed in master, backport to 6-2 in gerrit
Comment 5 Xisco Faulí 2019-05-08 10:59:04 UTC
Verified in

Version: 6.3.0.0.alpha0+
Build ID: 299e34275574d4fa0d9b175231f5cfdbb49c4f4c
CPU threads: 4; OS: Linux 4.15; UI render: default; VCL: gtk3; 
Locale: ca-ES (ca_ES.UTF-8); UI-Language: en-US
Calc: threaded

@Caolán, thanks for fixing this issue!!
Comment 6 Commit Notification 2019-05-08 11:11:25 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "libreoffice-6-2":

https://git.libreoffice.org/core/+/2376db068d8194d3455681a559369e50743e29f3%5E%21

Resolves: tdf#125106 fix cell protect TriState toggles

It will be available in 6.2.5.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 7 Commit Notification 2019-05-17 19:14:46 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "libreoffice-6-2-4":

https://git.libreoffice.org/core/+/64576639c4f2d42268692dde8edb53d6791354cd%5E%21

Resolves: tdf#125106 fix cell protect TriState toggles

It will be available in 6.2.4.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 8 rosma 2019-05-21 11:37:38 UTC
This cell protection problem is confirmed as fixed in the two versions shown below.

Thanks for your efforts in resolving this, I would have reported the fix earlier but Linux daily builds stopped updating after 4 May. The 6.2.5 build updated last night and the 6.3.0 is from a link on the LibreOffice QA blog.

Version: 6.2.5.0.0+
Build ID: 2b95e5bdf91204ecc03bcf98375c2620b71f1c3d
CPU threads: 2; OS: Linux 4.15; UI render: default; VCL: gtk3; 
TinderBox: Linux-rpm_deb-x86_64@86-TDF, Branch:libreoffice-6-2, Time: 2019-05-20_12:23:52
Locale: en-GB (en_GB.UTF-8); UI-Language: en-GB
Calc: threaded

Version: 6.3.0.0.alpha1
Build ID: 547edd20e527fb02900f6174973770d26306e2e7
CPU threads: 2; OS: Linux 4.15; UI render: default; VCL: gtk3; 
Locale: en-GB (en_GB.UTF-8); UI-Language: en-GB
Calc: threaded
Comment 9 rosma 2019-05-22 13:51:08 UTC
I have found that unfortunately the problem is NOT fixed in 6.2.4.2 despite the Commit Notification on 2019-05-17 as per Comment 7.

Version: 6.2.4.2
Build ID: 2412653d852ce75f65fbfa83fb7e7b669a126d64
CPU threads: 2; OS: Linux 4.15; UI render: default; VCL: gtk3; 
Locale: en-GB (en_GB.UTF-8); UI-Language: en-GB
Calc: threaded