summaryrefslogtreecommitdiff
path: root/accessibility
diff options
context:
space:
mode:
authorMichael Weghorn <m.weghorn@posteo.de>2024-02-15 09:43:54 +0100
committerMichael Weghorn <m.weghorn@posteo.de>2024-02-16 09:10:10 +0100
commit694670e13143f41e211dd0e183516d08008dd12b (patch)
treeedf96d4f8eaacf3bf2ec5f83cb4a0ae26be5525b /accessibility
parent9572354fedf3d521c8fe123c402ccab20b824815 (diff)
tdf#159213 a11y: Only send child event if there's a child
When reviewing all the places sending an `AccessibleEventId::CHILD` event as described in tdf#159213 comment 8, this here looks like one where the child might not be set. Add a corresponding check to avoid sending an invalid event. Change-Id: I6fea72e8a0619eeec7ac7c9d38dec996ab34752f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/163427 Tested-by: Jenkins Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
Diffstat (limited to 'accessibility')
-rw-r--r--accessibility/source/standard/vclxaccessiblebox.cxx3
1 files changed, 2 insertions, 1 deletions
diff --git a/accessibility/source/standard/vclxaccessiblebox.cxx b/accessibility/source/standard/vclxaccessiblebox.cxx
index 84855ca096cf..93e49f90c285 100644
--- a/accessibility/source/standard/vclxaccessiblebox.cxx
+++ b/accessibility/source/standard/vclxaccessiblebox.cxx
@@ -70,7 +70,8 @@ void VCLXAccessibleBox::ProcessWindowChildEvent( const VclWindowEvent& rVclWindo
if (m_aBoxType==COMBOBOX)
{
VclPtr< ComboBox > pComboBox = GetAs< ComboBox >();
- if (pComboBox && pChildWindow && pChildWindow == pComboBox->GetSubEdit())
+ if (pComboBox && pChildWindow && pChildWindow == pComboBox->GetSubEdit()
+ && m_xText.is())
{
if (rVclWindowEvent.GetId() == VclEventId::WindowShow)
{