summaryrefslogtreecommitdiff
path: root/accessibility/source/standard/vclxaccessibletoolbox.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'accessibility/source/standard/vclxaccessibletoolbox.cxx')
-rw-r--r--accessibility/source/standard/vclxaccessibletoolbox.cxx27
1 files changed, 27 insertions, 0 deletions
diff --git a/accessibility/source/standard/vclxaccessibletoolbox.cxx b/accessibility/source/standard/vclxaccessibletoolbox.cxx
index 52b7a7f83cab..ce796af77ab4 100644
--- a/accessibility/source/standard/vclxaccessibletoolbox.cxx
+++ b/accessibility/source/standard/vclxaccessibletoolbox.cxx
@@ -441,6 +441,26 @@ void VCLXAccessibleToolBox::UpdateAllItems_Impl()
}
}
}
+
+// -----------------------------------------------------------------------------
+
+void VCLXAccessibleToolBox::UpdateCustomPopupItemp_Impl( Window* pWindow, bool bOpen )
+{
+ ToolBox* pToolBox = static_cast< ToolBox* >( GetWindow() );
+ if( pWindow && pToolBox )
+ {
+ Reference< XAccessible > xChild( pWindow->GetAccessible() );
+ if( xChild.is() )
+ {
+ Reference< XAccessible > xChildItem( getAccessibleChild( static_cast< sal_Int32 >( pToolBox->GetItemPos( pToolBox->GetDownItemId() ) ) ) );
+ VCLXAccessibleToolBoxItem* pItem = static_cast< VCLXAccessibleToolBoxItem* >( xChildItem.get() );
+
+ pItem->SetChild( xChild );
+ pItem->NotifyChildEvent( xChild, bOpen );
+ }
+ }
+}
+
// -----------------------------------------------------------------------------
void VCLXAccessibleToolBox::UpdateItemName_Impl( sal_Int32 _nPos )
{
@@ -582,6 +602,13 @@ void VCLXAccessibleToolBox::ProcessWindowEvent( const VclWindowEvent& rVclWindow
break;
}
+ case VCLEVENT_DROPDOWN_OPEN:
+ case VCLEVENT_DROPDOWN_CLOSE:
+ {
+ UpdateCustomPopupItemp_Impl( static_cast< Window* >( rVclWindowEvent.GetData() ), rVclWindowEvent.GetId() == VCLEVENT_DROPDOWN_OPEN );
+ break;
+ }
+
case VCLEVENT_OBJECT_DYING :
{
// if this toolbox is a subtoolbox, we have to relese it from its parent