Skip to content

UI: enter edit mode in write protected file with edit button(mobile)#13090

Merged
caolanm merged 1 commit intoCollaboraOnline:masterfrom
lpranam:wirte_protected_mobile
Oct 13, 2025
Merged

UI: enter edit mode in write protected file with edit button(mobile)#13090
caolanm merged 1 commit intoCollaboraOnline:masterfrom
lpranam:wirte_protected_mobile

Conversation

@lpranam
Copy link
Copy Markdown
Member

@lpranam lpranam commented Oct 5, 2025

by default documents are opened in read only mode in mobile
to prevent accidental editing.
This read only mode is different from when file is actually
set with permission read-only(in desktop Edit -> Edit mode)

Currently online does not have any button equivalent to the desktop
to enter the edit mode, neither in desktop browser nor in mobile.

Without this patch if file is read only and user presses the pencil button,
UI changes to edit mode but file still can not be edited because of
restricted permissions.

Change-Id: Id2f9b787e4a6f6456c4d192987d2650a3b2b27d0

  • Target version: master

Checklist

  • I have run make prettier-write and formatted the code.
  • All commits have Change-Id
  • I have run tests with make check
  • I have issued make run and manually verified that everything looks okay
  • Documentation (manuals or wiki) has been updated or is not required

Copy link
Copy Markdown
Contributor

@pedropintosilva pedropintosilva left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This seems to be only affecting Tablet & Mobile ( I think how the other PR was also meant for that #10657 ),

I have tested and it seems to work as expected (similarly as it works on LO): if a user sets a document to open as view-only it can be switch to edit mode upon pressing a button (in the case on online pencil button)

UI: enter edit mode in write protected file with edit button

This only works on Tablet/mobile as on desktop the edit button doesn't appear in that situation, (I will file this as a follow up: #13125 ).

having pencil edit button and another button in menu to enter
the edit mode is redundant

I'm confused about this sentence. Which other button in menu? It seems by reading the commit message that a menu entry of some kind was removed but that is not the case by looking at the code.

Can you please re-write the commit message so it's a bit more clear?


test document:
Write_protect.odt

Before:

Peek_2024-09-26_09-48.mp4

After: Now, Pressing the pencil button effectively switches to edit mode.

@github-project-automation github-project-automation Bot moved this from To Review to In Progress in Collabora Online Oct 8, 2025
@lpranam lpranam force-pushed the wirte_protected_mobile branch from d2430e3 to d7d57e0 Compare October 10, 2025 00:47
@lpranam lpranam changed the title UI: enter edit mode in write protected file with edit button UI: enter edit mode in write protected file with edit button(mobile) Oct 10, 2025
by default documents are opened in read only mode in mobile
to prevent accidental editing.
This read only mode is different from when file is actually
set with permission read-only(in desktop Edit -> Edit mode)

Currently online does not have any button equivalent to the desktop
to enter the edit mode, neither in desktop browser nor in mobile.

Without this patch if file is read only and user presses the pencil button,
UI changes to edit mode but file still can not be edited because of
restricted permissions.

Signed-off-by: Pranam Lashkari <lpranam@collabora.com>
Change-Id: Id2f9b787e4a6f6456c4d192987d2650a3b2b27d0
@lpranam lpranam force-pushed the wirte_protected_mobile branch from d7d57e0 to 34f5f61 Compare October 10, 2025 00:48
@lpranam
Copy link
Copy Markdown
Member Author

lpranam commented Oct 10, 2025

Updated description and commit message, hopefully it makes things clear.

Copy link
Copy Markdown
Contributor

@pedropintosilva pedropintosilva left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It works, now on mobile when opening a Write_protect.odt the user can press the edit FAB to edit the file.

This only works on Tablet/mobile as on desktop the edit button doesn't appear in that situation, (I will file this as a follow up: #13125 ).

So, We should also add the pencil FAB for when opening the file in Collabora Online Desktop/laptop -> possible follow up

@github-project-automation github-project-automation Bot moved this from In Progress to To Test in Collabora Online Oct 13, 2025
Copy link
Copy Markdown
Contributor

@caolanm caolanm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems to make sense to me

@caolanm caolanm merged commit e904309 into CollaboraOnline:master Oct 13, 2025
13 checks passed
@github-project-automation github-project-automation Bot moved this from To Test to Done in Collabora Online Oct 13, 2025
@lpranam lpranam deleted the wirte_protected_mobile branch October 13, 2025 17:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

3 participants