summaryrefslogtreecommitdiff
path: root/patches/a11y/a11y-gtk-frame.diff
diff options
context:
space:
mode:
Diffstat (limited to 'patches/a11y/a11y-gtk-frame.diff')
-rw-r--r--patches/a11y/a11y-gtk-frame.diff136
1 files changed, 0 insertions, 136 deletions
diff --git a/patches/a11y/a11y-gtk-frame.diff b/patches/a11y/a11y-gtk-frame.diff
deleted file mode 100644
index 001066543..000000000
--- a/patches/a11y/a11y-gtk-frame.diff
+++ /dev/null
@@ -1,136 +0,0 @@
-Index: vcl/unx/inc/plugins/gtk/gtkframe.hxx
-===================================================================
-RCS file: /cvs/gsl/vcl/unx/inc/plugins/gtk/gtkframe.hxx,v
-retrieving revision 1.13
-diff -u -r1.13 gtkframe.hxx
---- vcl/unx/inc/plugins/gtk/gtkframe.hxx 30 Mar 2005 09:09:03 -0000 1.13
-+++ vcl/unx/inc/plugins/gtk/gtkframe.hxx 12 Apr 2005 15:53:55 -0000
-@@ -69,6 +69,9 @@
- #include <gdk/gdkkeysyms.h>
- #include <postx.h>
-
-+#include <com/sun/star/uno/Reference.hxx>
-+#include <com/sun/star/accessibility/XAccessible.hdl>
-+
- #ifndef _SV_SALFRAME_HXX
- #include <salframe.hxx>
- #endif
-@@ -355,6 +358,9 @@
- virtual bool SetPluginParent( SystemParentData* pNewParent );
-
- virtual void SetBackgroundBitmap( SalBitmap* );
-+
-+ static GtkSalFrame *getFromWindow( GtkWindow *pWindow );
-+ ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessible > getAccessible( bool bCreate = true );
- };
-
-
-Index: vcl/unx/gtk/window/gtkframe.cxx
-===================================================================
-RCS file: /cvs/gsl/vcl/unx/gtk/window/gtkframe.cxx,v
-retrieving revision 1.26
-diff -u -r1.26 gtkframe.cxx
---- vcl/unx/gtk/window/gtkframe.cxx 30 Mar 2005 09:11:10 -0000 1.26
-+++ vcl/unx/gtk/window/gtkframe.cxx 12 Apr 2005 15:53:58 -0000
-@@ -63,6 +63,7 @@
- #include <plugins/gtk/gtkdata.hxx>
- #include <plugins/gtk/gtkinst.hxx>
- #include <plugins/gtk/gtkgdi.hxx>
-+#include <plugins/gtk/atkfactory.hxx>
- #include <keycodes.hxx>
- #include <wmadaptor.hxx>
- #include <sm.hxx>
-@@ -71,6 +72,7 @@
- #include <floatwin.hxx>
- #include <salprn.h>
- #include <svapp.hxx>
-+#include <window.hxx>
-
- #include <prex.h>
- #include <X11/Xatom.h>
-@@ -271,7 +273,10 @@
- if( m_pFixedContainer )
- gtk_widget_destroy( GTK_WIDGET(m_pFixedContainer) );
- if( m_pWindow )
-+ {
-+ g_object_set_data( G_OBJECT( m_pWindow ), "SalFrame", NULL );
- gtk_widget_destroy( GTK_WIDGET(m_pWindow) );
-+ }
- if( m_pForeignParent )
- g_object_unref( G_OBJECT(m_pForeignParent) );
- if( m_pForeignTopLevel )
-@@ -485,6 +490,64 @@
- }
- }
-
-+// Always use a sub-class of GtkWindow we can tag for a11yx
-+static GType
-+ooo_window_get_type()
-+{
-+ static GType t = 0;
-+
-+ if (!t) {
-+ static const GTypeInfo tinfo =
-+ {
-+ sizeof( GtkWindowClass ),
-+ NULL, NULL, NULL, NULL, NULL,
-+ sizeof( GtkWindow ), 0, NULL, NULL
-+ };
-+
-+ t = g_type_register_static(
-+ GTK_TYPE_WINDOW, "OOoWindow", &tinfo, (GTypeFlags) 0);
-+ RegisterAtkFactory( t );
-+ }
-+
-+ return t;
-+}
-+
-+static GtkWindow *
-+createWindow( GtkSalFrame *pThis, ULONG nStyle )
-+{
-+ GtkWindow *pWindow;
-+ GtkWindowType eType = ( (nStyle & SAL_FRAME_STYLE_FLOAT) &&
-+ ! (nStyle & SAL_FRAME_STYLE_OWNERDRAWDECORATION) ) ?
-+ GTK_WINDOW_POPUP : GTK_WINDOW_TOPLEVEL;
-+
-+ // FIXME - we should really sub-class instead of doing
-+ // tens of expensive signal connections ... and this:
-+
-+ static int nCount = 0;
-+ if( eType == GTK_WINDOW_TOPLEVEL )
-+ fprintf( stderr, "Create toplevel %d\n", ++nCount );
-+
-+ pWindow = GTK_WINDOW( g_object_new( ooo_window_get_type(),
-+ "type", eType, "visible", FALSE, NULL ) );
-+ g_object_set_data( G_OBJECT( pWindow ), "SalFrame", pThis );
-+
-+ return pWindow;
-+}
-+
-+GtkSalFrame *GtkSalFrame::getFromWindow( GtkWindow *pWindow )
-+{
-+ return (GtkSalFrame *) g_object_get_data( G_OBJECT( pWindow ), "SalFrame" );
-+}
-+
-+::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessible >
-+GtkSalFrame::getAccessible( bool bCreate )
-+{
-+ // Yes - this is a hack - but: this abstraction seems totally useless to me
-+ Window *pWindow = static_cast<Window *>(GetInstance());
-+ if( pWindow )
-+ return pWindow->GetAccessible( bCreate );
-+}
-+
- void GtkSalFrame::Init( SalFrame* pParent, ULONG nStyle )
- {
- if( nStyle & SAL_FRAME_STYLE_DEFAULT ) // ensure default style
-@@ -493,7 +556,8 @@
- nStyle &= ~SAL_FRAME_STYLE_FLOAT;
- }
-
-- m_pWindow = GTK_WINDOW( gtk_widget_new( GTK_TYPE_WINDOW, "type", ((nStyle & SAL_FRAME_STYLE_FLOAT) && ! (nStyle & SAL_FRAME_STYLE_OWNERDRAWDECORATION)) ? GTK_WINDOW_POPUP : GTK_WINDOW_TOPLEVEL, "visible", FALSE, NULL ) );
-+ m_pWindow = createWindow( this, nStyle );
-+
- m_pParent = static_cast<GtkSalFrame*>(pParent);
- m_pForeignParent = NULL;
- m_aForeignParentWindow = None;