diff options
author | Eike Rathke <erack@redhat.com> | 2013-03-04 19:32:42 +0100 |
---|---|---|
committer | Fridrich Strba <fridrich@documentfoundation.org> | 2013-03-07 08:32:16 +0000 |
commit | 726767fe5fe006ad5b5f656981ab077088b2db84 (patch) | |
tree | 3342c9507996f166b0d7ab1ba8985d1c99e8664c /sc | |
parent | 07b2b5ee619e123652bca2d18d4b61a94f94e00a (diff) |
resolved rhbz#916936 allow also input line for read-only
Allow activation of input line and cell activation in read-only
documents regardless whether it's part of an array or not.
Change-Id: Id2dc9de9e60b58f4b471fb232e899c9ea75e83f1
(cherry picked from commit 9c51646541846317777b00dc6ad2e30cb1c07950)
Reviewed-on: https://gerrit.libreoffice.org/2548
Reviewed-by: Muthu Subramanian K <muthusuba@gmail.com>
Reviewed-by: Fridrich Strba <fridrich@documentfoundation.org>
Tested-by: Fridrich Strba <fridrich@documentfoundation.org>
Diffstat (limited to 'sc')
-rw-r--r-- | sc/source/ui/app/inputhdl.cxx | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/sc/source/ui/app/inputhdl.cxx b/sc/source/ui/app/inputhdl.cxx index 727799a99476..3ec6bcfd7d26 100644 --- a/sc/source/ui/app/inputhdl.cxx +++ b/sc/source/ui/app/inputhdl.cxx @@ -1962,10 +1962,12 @@ bool ScInputHandler::StartTable( sal_Unicode cTyped, bool bFromCommand, bool bIn if (!aTester.IsEditable()) { bProtected = true; - // We allow read-only input mode activation when explicit cell - // activation is requested (double-click or F2) and if it's not - // part of an array. - bool bShowError = !bInputActivated || aTester.GetMessageId() != STR_PROTECTIONERR; + // We allow read-only input mode activation regardless + // whether it's part of an array or not or whether explicit cell + // activation is requested (double-click or F2) or a click in input + // line. + bool bShowError = (!bInputActivated || aTester.GetMessageId() != STR_PROTECTIONERR) && + !pActiveViewSh->GetViewData()->GetDocShell()->IsReadOnly(); if (bShowError) { eMode = SC_INPUT_NONE; |