24.04 readonly mode bits ...

* Present
  + Gokay, Michael, Miklos

* Found the UI readonly option
  + can set the UI to readonly
  + if it is readonly currently
    + edit view needs to be set to readonly.
    + set - if a view performs an action
  + readonly UI
    + listeners are disabled
    + enabled when the mode is added again.
  + couldn't use a global variable

* What about the comment-only semantic ?
  + readonly UI - doesn't allow you to edit

* coolwsd crash
AI: + fix this as a priority- it should never crash
    + if it's a debugging assert: ok perhaps.
    + should shut connections to the Kit
      if necessary and kill it if we get
      suspicious stuff.

* table re-sizing:
AI: + Poke at the SDI files to ensure that the
    related UNO commands are set right for
    readonly mode

* readonly mode
AI: + wsd/ClientSession.cpp - event filtering:
    + should retain much of this on top of
      readonly mode
    + only allow through:
      + mouse move & click events
      + arrow keys + modifiers for
        keyboard movement / selection
      + expect 'Copy' to go through
        UNO commands - allow that too
        if copy is not disabled.

  + we should push through the 'can comment'
    permission into readonly mode in LOK core

* core problems:
  + with one readonly view - can't select shapes
  + since one disables it, and another doens't enable it again.
  + we should assume that the setReadOnlyView thing is called
    just once at constrution or the earliest time we make something.
    + perhaps we should use:

  kit/Kit.cpp: _loKitDocument->createView(options.c_str());

    + so this state is all present as we
      create the SfxViewFoo.

* Performance:
  + 'mode changed' event is broadcasted on the core side
    + disabling and enabling listening to some events
  + concerned about this
    + we badly want to set the ReadOnly option once at
      view creation, and then not again.
    + certainly at view strobing time.
  + need to do some QA / test of where readonly-ness is checked.

  + SwViewShell is not shared
    => no problem.

  + SfxObjectShell is shared
    + using the same pointer.
    + hits the drawing-layer stuff ...

  AI: + SfxObjectShell::SetReadOnlyUI should not be called with 'true'
      + ObjectShell should be read-write.
      + SfxViewShells - should be readonly-only (or not)

  AI: + add a permissions enum: ReadWrite, CanComment, ReadOnly
2 and thread it through everywhere.

  AI: + need to switch call-sites that fetch read-only-ness
      to not use SfxObjectShell instead ask it to the SfxViewShell (Gokay)

  AI: + Audit listeners listening to ModeChanged to ensure they
      filter in the callbacks in readonly mode.
      $ git grep SfxHintId::ModeChanged
        + 8 hits
      $ git grep on.*ModeChanged
        + 6 hits outside the IDE

* Keeping the model read-write
  + avoids complexity with SfxMedium and associated horrors =)

* Target this for 24.04
  + not merging this into 23.05