summaryrefslogtreecommitdiff
path: root/vcl
diff options
context:
space:
mode:
authorVladimir Glazounov <vg@openoffice.org>2008-04-15 12:28:46 +0000
committerVladimir Glazounov <vg@openoffice.org>2008-04-15 12:28:46 +0000
commit9aa3b662378ddec78b48423ffec4f125641b3631 (patch)
tree54c16aa45f392fd9f6674a80ed0c34087a9156be /vcl
parent4051dcc6f33aa2f64dabaf887690d4b1df74ab0d (diff)
INTEGRATION: CWS aqua11y01 (1.74.32); FILE MERGED
2008/03/12 12:16:05 obr 1.74.32.2: RESYNC: (1.74-1.75); FILE MERGED 2008/02/19 21:53:23 obr 1.74.32.1: #i85830# check parent instead of child window for filtering
Diffstat (limited to 'vcl')
-rw-r--r--vcl/unx/gtk/window/gtkframe.cxx24
1 files changed, 16 insertions, 8 deletions
diff --git a/vcl/unx/gtk/window/gtkframe.cxx b/vcl/unx/gtk/window/gtkframe.cxx
index 914f8f00cefc..08c4de18b811 100644
--- a/vcl/unx/gtk/window/gtkframe.cxx
+++ b/vcl/unx/gtk/window/gtkframe.cxx
@@ -7,7 +7,7 @@
* OpenOffice.org - a multi-platform office productivity suite
*
* $RCSfile: gtkframe.cxx,v $
- * $Revision: 1.79 $
+ * $Revision: 1.80 $
*
* This file is part of OpenOffice.org.
*
@@ -752,16 +752,24 @@ GtkSalFrame::GetAtkRole( GtkWindow* window )
role = ATK_ROLE_FRAME;
break;
- // Ignore window objects for sub-menus, which are exposed
- // as children of their parent menu
+ /* Ignore window objects for sub-menus, combo- and list boxes,
+ * which are exposed as children of their parents.
+ */
case accessibility::AccessibleRole::WINDOW:
{
- Window *pChild = pWindow->GetChild( 0 );
- if( pChild )
+ USHORT type = WINDOW_WINDOW;
+ bool parentIsMenuFloatingWindow = false;
+
+ Window *pParent = pWindow->GetParent();
+ if( pParent ) {
+ type = pParent->GetType();
+ parentIsMenuFloatingWindow = ( TRUE == pParent->IsMenuFloatingWindow() );
+ }
+
+ if( (WINDOW_LISTBOX != type) && (WINDOW_COMBOBOX != type) &&
+ (WINDOW_MENUBARWINDOW != type) && ! parentIsMenuFloatingWindow )
{
- uno::Reference< accessibility::XAccessible > xAccessible( pChild->GetAccessible( true ) );
- if( xAccessible.is() )
- role = ATK_ROLE_WINDOW;
+ role = ATK_ROLE_WINDOW;
}
}
break;