diff options
| author | Caolán McNamara <caolanm@redhat.com> | 2015-04-03 14:18:04 +0100 |
|---|---|---|
| committer | Caolán McNamara <caolanm@redhat.com> | 2015-04-20 10:14:48 +0000 |
| commit | 0bf980c174040474178b308425dc894ad26c3533 (patch) | |
| tree | 3205f30a7b7565929f53aa87419057f6778a5a94 | |
| parent | dd9084729d4a9c50e5bad02be7e3897d2b893852 (diff) | |
Related: tdf#82998 assume VALUE_CHANGED makes sense only for windows
jdiggs: I believe [VALUE_CHANGED] is expected for Windows' accessibility APIs.
However for ATK/AT-SPI2, value-change events are expected only for the sorts of
things which implement AtkValue (scrollbars, progressbars, sliders,
spinbuttons, etc.) Combo boxes, lists, and the like should not be emitting this
event.
Change-Id: I9dcab7fb4004a24f88915f904eb508dfee2d4ae5
(cherry picked from commit 835fcfacc66601299aa73cd5423e8277ccd8fc34)
Reviewed-on: https://gerrit.libreoffice.org/15387
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
| -rw-r--r-- | accessibility/source/standard/vclxaccessiblebox.cxx | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/accessibility/source/standard/vclxaccessiblebox.cxx b/accessibility/source/standard/vclxaccessiblebox.cxx index c75e8b431a70..c1bfdea41ca2 100644 --- a/accessibility/source/standard/vclxaccessiblebox.cxx +++ b/accessibility/source/standard/vclxaccessiblebox.cxx @@ -124,10 +124,12 @@ void VCLXAccessibleBox::ProcessWindowEvent (const VclWindowEvent& rVclWindowEven if ( pList != NULL ) { pList->ProcessWindowEvent (rVclWindowEvent, m_bIsDropDownBox); +#if defined WNT if (m_bIsDropDownBox) { NotifyAccessibleEvent(AccessibleEventId::VALUE_CHANGED, Any(), Any()); } +#endif } break; } @@ -179,8 +181,10 @@ void VCLXAccessibleBox::ProcessWindowEvent (const VclWindowEvent& rVclWindowEven if ( sText.isEmpty() ) sText = xText->getText(); pList->UpdateSelection_Acc(sText, m_bIsDropDownBox); +#if defined WNT if (m_bIsDropDownBox || ( !m_bIsDropDownBox && m_aBoxType==COMBOBOX)) NotifyAccessibleEvent(AccessibleEventId::VALUE_CHANGED, Any(), Any()); +#endif } } break; @@ -545,7 +549,7 @@ void VCLXAccessibleBox::FillAccessibleStateSet( utl::AccessibleStateSetHelper& r ListBox* pListBox = static_cast< ListBox* >( GetWindow() ); if (pListBox != NULL && pListBox->GetEntryCount() > 0) { - nSelectedEntryCount = pListBox->GetSelectEntryCount(); + nSelectedEntryCount = pListBox->GetSelectEntryCount(); if ( nSelectedEntryCount == 0) rStateSet.AddState(AccessibleStateType::INDETERMINATE); } |
