summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNiklas Johansson <sleeping.pillow@gmail.com>2015-01-26 23:16:07 +0100
committerCaolán McNamara <caolanm@redhat.com>2015-01-27 09:34:06 +0000
commit9b7b1774459edb93f2d3a11b2441851f4355a613 (patch)
tree59e25cb854f6f26372f86cf414de480799fd23d5
parent06679dc5fa35fd0ac0e9c18427b869225435c581 (diff)
tdf#88702 ACCESSIBILITY Toggle buttons state not reliably updated
We need to adapt the accessibility code to handle VCLEVENT_TOOLBOX_ITEMUPDATED, since it is now sent from vcl/source/window/toolbox2.cxx. I have tested the patch successfully on Windows and Fedora. Change-Id: Ia4328d3c34547cc28ce9a3946f90223442ee84e3 Reviewed-on: https://gerrit.libreoffice.org/14190 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
-rw-r--r--accessibility/source/standard/vclxaccessibletoolbox.cxx7
-rw-r--r--vcl/source/window/toolbox2.cxx3
2 files changed, 4 insertions, 6 deletions
diff --git a/accessibility/source/standard/vclxaccessibletoolbox.cxx b/accessibility/source/standard/vclxaccessibletoolbox.cxx
index c3042fbe67a4..a8a7cdfd5e3f 100644
--- a/accessibility/source/standard/vclxaccessibletoolbox.cxx
+++ b/accessibility/source/standard/vclxaccessibletoolbox.cxx
@@ -551,18 +551,17 @@ void VCLXAccessibleToolBox::ProcessWindowEvent( const VclWindowEvent& rVclWindow
case VCLEVENT_TOOLBOX_DEACTIVATE:
//case VCLEVENT_TOOLBOX_SELECT:
break;
- // IA2 CWS. MT: Still using VCLEVENT_TOOLBOX_CLICK, see comment in vcl/source/window/toolbox2.cxx
- /*
+
case VCLEVENT_TOOLBOX_ITEMUPDATED:
{
if ( rVclWindowEvent.GetData() )
{
UpdateChecked_Impl( TOOLBOX_ITEM_NOTFOUND );
- UpdateIndeterminate_Impl( (sal_Int32)rVclWindowEvent.GetData() );
+ UpdateIndeterminate_Impl( (sal_Int32)reinterpret_cast<sal_IntPtr>(rVclWindowEvent.GetData()) );
}
break;
}
- */
+
case VCLEVENT_TOOLBOX_HIGHLIGHT:
UpdateFocus_Impl();
break;
diff --git a/vcl/source/window/toolbox2.cxx b/vcl/source/window/toolbox2.cxx
index e1cad517c76d..247aaefcfe03 100644
--- a/vcl/source/window/toolbox2.cxx
+++ b/vcl/source/window/toolbox2.cxx
@@ -1458,8 +1458,7 @@ void ToolBox::SetItemState( sal_uInt16 nItemId, TriState eState )
// Notify button changed event to prepare accessibility bridge
CallEventListeners( VCLEVENT_TOOLBOX_BUTTONSTATECHANGED, reinterpret_cast< void* >( nPos ) );
- // Notify
- //Solution:Call accessible listener to notify state_changed event
+ // Call accessible listener to notify state_changed event
CallEventListeners( VCLEVENT_TOOLBOX_ITEMUPDATED, reinterpret_cast< void* >(nPos) );
}
}