qt a11y: Clear QtXAccessible's ref to XAccessible once passed on
commitf2371a7d9b306ce217689bd69c920c9f780f1ee3
authorMichael Weghorn <m.weghorn@posteo.de>
Tue, 16 Aug 2022 12:13:20 +0000 (16 14:13 +0200)
committerMichael Weghorn <m.weghorn@posteo.de>
Tue, 16 Aug 2022 20:29:15 +0000 (16 22:29 +0200)
tree96c2898408c0785c6fce58f336aa8ef55c1432c5
parenta65719ec67523cdfc294aeeda527b51ba4d2e17c
qt a11y: Clear QtXAccessible's ref to XAccessible once passed on

The `QtXAccessible` only needs to hold a reference to
the `XAccessible` in order to pass it to the
`QtAccessibleWidget` ctor in `QtAccessibleWidget::customFactory`
(which gets called via `QAccessible::queryAccessibleInterface`).

After that has happened, the `QtAccessibleWidget` holds
its own reference in its `m_xAccessible` member and is the
only class in the context of the qt a11y bridge that needs
access to the `XAccessible`, so drop the reference
in the `QtXAccessible` to avoid any references being
held even after `QtAccessibleEventListener::disposing`
has been called, s.a.
Change-Id I077dffe6ca3e887707d1f578e947ccf3c2c2a492
"qt a11y: Clear XAccessible reference when disposing" for
some more context.

Change-Id: Ief80b2939e4c509fc4bc68e67500dbad66498506
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138365
Tested-by: Jenkins
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
vcl/inc/qt5/QtXAccessible.hxx
vcl/qt5/QtAccessibleWidget.cxx