[openoffice.org] adjust patch
Caolan McNamara
caolanm at fedoraproject.org
Fri Sep 17 12:44:12 UTC 2010
commit fbe00aafc7d17825a8a28e962949256c69886efa
Author: Caolán McNamara <caolanm at redhat.com>
Date: Fri Sep 17 13:44:05 2010 +0100
adjust patch
workspace.gtk3.patch | 580 ++++++++++----------------------------------------
1 files changed, 109 insertions(+), 471 deletions(-)
---
diff --git a/workspace.gtk3.patch b/workspace.gtk3.patch
index 29a08fe..2373e6e 100644
--- a/workspace.gtk3.patch
+++ b/workspace.gtk3.patch
@@ -273,43 +273,6 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::StringPair>& _rFilters );
void updateCurrentFilterFromName(const gchar* filtername);
void unselect_type();
---- vcl.orig/unx/gtk/a11y/makefile.mk 2010-05-29 11:29:16.000000000 +0100
-+++ vcl/unx/gtk/a11y/makefile.mk 2010-05-29 11:30:47.000000000 +0100
-@@ -50,7 +50,7 @@
-
- .IF "$(ENABLE_GTK)" != ""
-
--PKGCONFIG_MODULES=gtk+-2.0
-+PKGCONFIG_MODULES=gtk+-3.0
- .INCLUDE : pkg_config.mk
-
- CFLAGS+=-DVERSION=$(EMQ)"$(UPD)$(LAST_MINOR)$(EMQ)"
---- vcl.orig/unx/gtk/app/makefile.mk 2010-05-29 11:29:17.000000000 +0100
-+++ vcl/unx/gtk/app/makefile.mk 2010-05-29 11:30:40.000000000 +0100
-@@ -50,7 +50,7 @@
-
- .IF "$(ENABLE_GTK)" != ""
-
--PKGCONFIG_MODULES=gtk+-2.0
-+PKGCONFIG_MODULES=gtk+-3.0
- .INCLUDE : pkg_config.mk
-
- SLOFILES=\
---- vcl.orig/unx/gtk/gdi/makefile.mk 2010-05-29 11:29:17.000000000 +0100
-+++ vcl/unx/gtk/gdi/makefile.mk 2010-05-29 11:30:44.000000000 +0100
-@@ -47,9 +47,11 @@
-
- .IF "$(ENABLE_GTK)" != ""
-
--PKGCONFIG_MODULES=gtk+-2.0
-+PKGCONFIG_MODULES=gtk+-3.0
- .INCLUDE : pkg_config.mk
-
-+CFLAGS+=-UGSEAL_ENABLE
-+
- SLOFILES=$(SLO)$/salnativewidgets-gtk.obj
- EXCEPTIONSFILES=$(SLO)$/salnativewidgets-gtk.obj
-
--- vcl.orig/unx/gtk/window/gtkframe.cxx 2010-05-29 11:29:16.000000000 +0100
+++ vcl/unx/gtk/window/gtkframe.cxx 2010-05-29 12:02:19.000000000 +0100
@@ -79,6 +79,14 @@
@@ -332,7 +295,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
if( m_pRegion )
- gdk_region_destroy( m_pRegion );
-+ cairo_region_destroy( m_pRegion );
++ gdk_region_destroy( m_pRegion );
if( m_hBackgroundPixmap )
{
@@ -432,7 +395,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
getDisplay()->getWMAdaptor()->switchToWorkArea( m_pParent->m_nWorkArea );
if( isFloatGrabWindow() &&
-@@ -1363,7 +1373,7 @@
+@@ -1363,7 +1372,7 @@
nUserTime= getDisplay()->GetLastUserEventTime( true );
//nUserTime = gdk_x11_get_server_time(GTK_WIDGET (m_pWindow)->window);
}
@@ -441,7 +404,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
if( bHack && ! bNoActivate && (m_nStyle & SAL_FRAME_STYLE_TOOLWINDOW) )
m_bSetFocusOnMap = true;
-@@ -1466,7 +1476,7 @@
+@@ -1472,7 +1481,7 @@
{
m_aMaxSize = Size( nWidth, nHeight );
// Show does a setMinMaxSize
@@ -450,7 +413,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
setMinMaxSize();
}
}
-@@ -1479,7 +1489,7 @@
+@@ -1485,7 +1494,7 @@
{
gtk_widget_set_size_request( m_pWindow, nWidth, nHeight );
// Show does a setMinMaxSize
@@ -459,7 +422,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
setMinMaxSize();
}
}
-@@ -1731,7 +1741,7 @@
+@@ -1737,7 +1746,7 @@
gtk_widget_realize( m_pWindow );
// update system data
GtkSalDisplay* pDisp = getDisplay();
@@ -468,7 +431,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
m_aSystemData.pVisual = pDisp->GetVisual( m_nScreen ).GetVisual();
m_aSystemData.nScreen = nScreen;
m_aSystemData.nDepth = pDisp->GetVisual( m_nScreen ).GetDepth();
-@@ -1742,7 +1752,7 @@
+@@ -1748,7 +1757,7 @@
for( unsigned int i = 0; i < sizeof(m_aGraphics)/sizeof(m_aGraphics[0]); i++ )
{
if( m_aGraphics[i].bInUse )
@@ -477,7 +440,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
}
updateScreenNumber();
}
-@@ -1771,7 +1781,7 @@
+@@ -1777,7 +1786,7 @@
Rectangle aOldScreenRect( pDisp->GetXineramaScreens()[maGeometry.nScreenNumber] );
Rectangle aNewScreenRect( pDisp->GetXineramaScreens()[nNewScreen] );
@@ -486,7 +449,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
if( bVisible )
Show( FALSE );
maGeometry.nX = aNewScreenRect.Left() + (maGeometry.nX - aOldScreenRect.Left());
-@@ -1803,7 +1813,7 @@
+@@ -1809,7 +1818,7 @@
{
m_aRestorePosSize = Rectangle( Point( maGeometry.nX, maGeometry.nY ),
Size( maGeometry.nWidth, maGeometry.nHeight ) );
@@ -495,7 +458,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
if( bVisible )
Show( FALSE );
m_nStyle |= SAL_FRAME_STYLE_PARTIAL_FULLSCREEN;
-@@ -1836,7 +1846,7 @@
+@@ -1838,7 +1847,7 @@
}
else
{
@@ -504,7 +467,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
if( ! getDisplay()->getWMAdaptor()->isLegacyPartialFullscreen() )
gtk_window_unfullscreen( GTK_WINDOW(m_pWindow) );
if( bVisible )
-@@ -2044,7 +2054,7 @@
+@@ -2052,7 +2061,7 @@
}
#ifdef ENABLE_DBUS
m_nGSMCookie = dbus_inhibit_gsm(g_get_application_name(), "presentation",
@@ -513,7 +476,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
#endif
}
else
-@@ -2070,7 +2080,7 @@
+@@ -2078,7 +2087,7 @@
{
if( isChild( false, true ) )
gtk_widget_grab_focus( m_pWindow );
@@ -522,7 +485,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
{
if( ! (nFlags & SAL_FRAME_TOTOP_GRABFOCUS_ONLY) )
gtk_window_present( GTK_WINDOW(m_pWindow) );
-@@ -2079,7 +2089,7 @@
+@@ -2087,7 +2096,7 @@
// gdk_window_focus( m_pWindow->window, gdk_x11_get_server_time(GTK_WIDGET (m_pWindow)->window) );
/* #i99360# ugly workaround an X11 library bug */
guint32 nUserTime= getDisplay()->GetLastUserEventTime( true );
@@ -531,7 +494,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
}
/* need to do an XSetInputFocus here because
* gdk_window_focus will ask a EWMH compliant WM to put the focus
-@@ -2091,7 +2101,7 @@
+@@ -2099,7 +2108,7 @@
// sad but true: this can cause an XError, we need to catch that
// to do this we need to synchronize with the XServer
getDisplay()->GetXLib()->PushXErrorLevel( true );
@@ -540,7 +503,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
XSync( getDisplay()->GetDisplay(), False );
getDisplay()->GetXLib()->PopXErrorLevel();
}
-@@ -2110,7 +2120,7 @@
+@@ -2118,7 +2127,7 @@
{
m_ePointerStyle = ePointerStyle;
GdkCursor *pCursor = getDisplay()->getCursor( ePointerStyle );
@@ -549,7 +512,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
m_pCurrentCursor = pCursor;
// #i80791# use grabPointer the same way as CaptureMouse, respective float grab
-@@ -2145,7 +2155,7 @@
+@@ -2153,7 +2162,7 @@
{
const int nMask = ( GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK | GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK );
@@ -558,7 +521,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
(GdkEventMask) nMask, NULL, m_pCurrentCursor,
GDK_CURRENT_TIME );
}
-@@ -2158,7 +2168,7 @@
+@@ -2166,7 +2175,7 @@
// this is of course a bad hack, especially as we cannot
// set the right cursor this way
XGrabPointer( getDisplay()->GetDisplay(),
@@ -567,7 +530,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
bOwnerEvents,
PointerMotionMask | ButtonPressMask | ButtonReleaseMask,
GrabModeAsync,
-@@ -2206,7 +2216,7 @@
+@@ -2214,7 +2223,7 @@
// #i38648# ask for the next motion hint
gint x, y;
GdkModifierType mask;
@@ -576,7 +539,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
}
void GtkSalFrame::Flush()
-@@ -2292,7 +2302,7 @@
+@@ -2300,7 +2309,7 @@
return NULL;
X11SalBitmap *pBmp = new X11SalBitmap;
@@ -585,7 +548,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
if( pBmp->SnapShot( GDK_DISPLAY_XDISPLAY( getGdkDisplay() ),
GDK_WINDOW_XID( pWin ) ) )
return pBmp;
-@@ -2354,7 +2364,7 @@
+@@ -2362,7 +2371,7 @@
void GtkSalFrame::createNewWindow( XLIB_Window aNewParent, bool bXEmbed, int nScreen )
{
@@ -594,16 +557,16 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
if( bWasVisible )
Show( FALSE );
-@@ -2399,7 +2409,7 @@
+@@ -2407,7 +2416,7 @@
m_pIMHandler = NULL;
}
if( m_pRegion )
- gdk_region_destroy( m_pRegion );
-+ cairo_region_destroy( m_pRegion );
++ gdk_region_destroy( m_pRegion );
if( m_pFixedContainer )
gtk_widget_destroy( GTK_WIDGET(m_pFixedContainer) );
if( m_pWindow )
-@@ -2427,7 +2437,7 @@
+@@ -2435,7 +2444,7 @@
{
if( m_aGraphics[i].bInUse )
{
@@ -612,7 +575,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
m_aGraphics[i].pGraphics->SetWindow( m_pWindow );
}
}
-@@ -2457,14 +2467,14 @@
+@@ -2465,14 +2474,14 @@
void GtkSalFrame::ResetClipRegion()
{
if( m_pWindow )
@@ -625,17 +588,17 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
if( m_pRegion )
- gdk_region_destroy( m_pRegion );
- m_pRegion = gdk_region_new();
-+ cairo_region_destroy( m_pRegion );
-+ m_pRegion = cairo_region_create();
++ gdk_region_destroy( m_pRegion );
++ m_pRegion = gdk_region_new();
}
void GtkSalFrame::UnionClipRegion( long nX, long nY, long nWidth, long nHeight )
-@@ -2477,14 +2487,14 @@
+@@ -2485,14 +2494,14 @@
aRect.width = nWidth;
aRect.height = nHeight;
- gdk_region_union_with_rect( m_pRegion, &aRect );
-+ cairo_region_union_rectangle( m_pRegion, &aRect );
++ gdk_region_union_with_rect( m_pRegion, &aRect );
}
}
@@ -647,7 +610,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
}
bool GtkSalFrame::Dispatch( const XEvent* pEvent )
-@@ -2498,7 +2508,7 @@
+@@ -2506,7 +2515,7 @@
if( pEvent->xproperty.atom == nDesktopAtom &&
pEvent->xproperty.state == PropertyNewValue )
{
@@ -656,7 +619,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
}
}
else if( pEvent->type == ConfigureNotify )
-@@ -2525,7 +2535,7 @@
+@@ -2533,7 +2542,7 @@
int x = 0, y = 0;
XLIB_Window aChild;
XTranslateCoordinates( getDisplay()->GetDisplay(),
@@ -665,7 +628,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
getDisplay()->GetRootWindow( getDisplay()->GetDefaultScreenNumber() ),
0, 0,
&x, &y,
-@@ -2540,7 +2550,7 @@
+@@ -2548,7 +2557,7 @@
}
else if( pEvent->type == ClientMessage &&
pEvent->xclient.message_type == getDisplay()->getWMAdaptor()->getAtom( vcl_sal::WMAdaptor::XEMBED ) &&
@@ -674,7 +637,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
m_bWindowIsGtkPlug
)
{
-@@ -2552,7 +2562,7 @@
+@@ -2560,7 +2569,7 @@
{
GdkEventFocus aEvent;
aEvent.type = GDK_FOCUS_CHANGE;
@@ -683,7 +646,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
aEvent.send_event = TRUE;
aEvent.in = (pEvent->xclient.data.l[1] == 1);
signalFocus( m_pWindow, &aEvent, this );
-@@ -2567,7 +2577,7 @@
+@@ -2575,7 +2584,7 @@
if( m_hBackgroundPixmap )
{
XSetWindowBackgroundPixmap( getDisplay()->GetDisplay(),
@@ -692,7 +655,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
None );
XFreePixmap( getDisplay()->GetDisplay(), m_hBackgroundPixmap );
m_hBackgroundPixmap = None;
-@@ -2580,7 +2590,7 @@
+@@ -2588,7 +2597,7 @@
{
m_hBackgroundPixmap =
XCreatePixmap( getDisplay()->GetDisplay(),
@@ -701,7 +664,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
aSize.Width(),
aSize.Height(),
getDisplay()->GetVisual(m_nScreen).GetDepth() );
-@@ -2596,7 +2606,7 @@
+@@ -2604,7 +2613,7 @@
aTwoRect,
getDisplay()->GetCopyGC(m_nScreen) );
XSetWindowBackgroundPixmap( getDisplay()->GetDisplay(),
@@ -710,7 +673,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
m_hBackgroundPixmap );
}
}
-@@ -2769,7 +2779,7 @@
+@@ -2777,7 +2786,7 @@
// ask for the next hint
gint x, y;
GdkModifierType mask;
@@ -719,16 +682,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
}
}
-@@ -2854,7 +2864,7 @@
- XEvent aEvent;
- aEvent.type = ClientMessage;
- aEvent.xclient.display = getDisplay()->GetDisplay();
-- aEvent.xclient.window = GDK_WINDOW_XWINDOW(m_pWindow->window);
-+ aEvent.xclient.window = GDK_WINDOW_XWINDOW(widget_get_window(m_pWindow));
- aEvent.xclient.message_type = nStateAtom;
- aEvent.xclient.format = 32;
- aEvent.xclient.data.l[0] = 1;
-@@ -2904,7 +2914,7 @@
+@@ -2872,7 +2881,7 @@
if( bSetFocus )
{
XSetInputFocus( pThis->getDisplay()->GetDisplay(),
@@ -737,7 +691,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
RevertToParent, CurrentTime );
}
-@@ -2952,7 +2962,7 @@
+@@ -2920,7 +2929,7 @@
*/
XLIB_Window aChild;
XTranslateCoordinates( pThis->getDisplay()->GetDisplay(),
@@ -746,7 +700,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
pThis->getDisplay()->GetRootWindow( pThis->getDisplay()->GetDefaultScreenNumber() ),
0, 0,
&x, &y,
-@@ -2986,7 +2996,7 @@
+@@ -2954,7 +2963,7 @@
if( ! (pThis->m_nStyle & SAL_FRAME_STYLE_PLUG) )
{
GdkRectangle aRect;
@@ -755,7 +709,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
pThis->maGeometry.nTopDecoration = y - aRect.y;
pThis->maGeometry.nBottomDecoration = aRect.y + aRect.height - y - pEvent->height;
pThis->maGeometry.nLeftDecoration = x - aRect.x;
-@@ -3197,7 +3207,7 @@
+@@ -3165,7 +3174,7 @@
* some time on the Xserver as well as prevent
* some paint issues
*/
@@ -764,7 +718,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
if( pWin )
{
XLIB_Window aWin = GDK_WINDOW_XWINDOW(pWin);
-@@ -3301,7 +3311,7 @@
+@@ -3269,7 +3278,7 @@
G_CALLBACK (signalIMPreeditEnd), this );
m_pFrame->getDisplay()->GetXLib()->PushXErrorLevel( true );
@@ -773,72 +727,6 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
gtk_im_context_focus_in( m_pIMContext );
m_pFrame->getDisplay()->GetXLib()->PopXErrorLevel();
m_bFocused = true;
---- vcl.orig/unx/gtk/window/makefile.mk 2010-05-29 11:29:16.000000000 +0100
-+++ vcl/unx/gtk/window/makefile.mk 2010-05-29 11:30:51.000000000 +0100
-@@ -50,7 +50,7 @@
-
- .IF "$(ENABLE_GTK)" != ""
-
--PKGCONFIG_MODULES=gtk+-2.0
-+PKGCONFIG_MODULES=gtk+-3.0
- .IF "$(ENABLE_DBUS)" != ""
- CDEFS+=-DENABLE_DBUS
- PKGCONFIG_MODULES+= dbus-glib-1
---- vcl.orig/util/makefile.mk 2010-05-29 11:28:58.000000000 +0100
-+++ vcl/util/makefile.mk 2010-05-29 11:30:59.000000000 +0100
-@@ -350,7 +350,7 @@
-
- # gtk plugin
- .IF "$(ENABLE_GTK)" != ""
--PKGCONFIG_MODULES=gtk+-2.0 gthread-2.0
-+PKGCONFIG_MODULES=gtk+-3.0 gthread-2.0
- .IF "$(ENABLE_DBUS)" != ""
- PKGCONFIG_MODULES+= dbus-glib-1
- .ENDIF
---- extensions.orig/source/nsplugin/source/makefile.mk 2010-05-29 21:22:06.000000000 +0100
-+++ extensions/source/nsplugin/source/makefile.mk 2010-05-29 21:23:13.000000000 +0100
-@@ -52,7 +52,7 @@
- .IF "$(OS)"=="LINUX" || "$(OS)"=="FREEBSD"
- INC+= -DNP_LINUX
- .ENDIF
--PKGCONFIG_MODULES=gtk+-2.0
-+PKGCONFIG_MODULES=gtk+-3.0
- .INCLUDE: pkg_config.mk
- .ENDIF # "$(ENABLE_GTK)"==""
- .ENDIF # "$(GUI)"=="UNX"
---- extensions.orig/source/plugin/util/makefile.pmk 2010-05-29 21:22:06.000000000 +0100
-+++ extensions/source/plugin/util/makefile.pmk 2010-05-29 21:23:16.000000000 +0100
-@@ -35,7 +35,7 @@
-
- .IF "$(GUIBASE)" == "unx" && "$(ENABLE_GTK)" == "TRUE"
- CDEFS+=-DENABLE_GTK
--PKGCONFIG_MODULES+=gtk+-2.0 gthread-2.0
-+PKGCONFIG_MODULES+=gtk+-3.0 gthread-2.0
- .ENDIF
-
- .IF "$(GUIBASE)" == "aqua"
---- fpicker.orig/source/unx/gnome/makefile.mk 2010-05-29 21:22:49.000000000 +0100
-+++ fpicker/source/unx/gnome/makefile.mk 2010-05-29 21:24:14.000000000 +0100
-@@ -46,16 +46,16 @@
-
- .ELSE # we build for GNOME
-
--PKGCONFIG_MODULES=gtk+-2.0
-+PKGCONFIG_MODULES=gtk+-3.0
- .INCLUDE : pkg_config.mk
-
- # check gtk version
--GTK_TWO_FOUR:=$(shell @$(PKG_CONFIG) --exists 'gtk+-2.0 >= 2.4.0' && echo ok)
-+GTK_TWO_FOUR:=$(shell @$(PKG_CONFIG) --exists 'gtk+-3.0 >= 2.4.0' && echo ok)
- .IF "$(GTK_TWO_FOUR)" != "ok"
-
- dummy:
- @echo "Cannot build gtk filepicker because"
-- @$(PKG_CONFIG) --print-errors --exists 'gtk+-2.0 >= 2.4.0'
-+ @$(PKG_CONFIG) --print-errors --exists 'gtk+-3.0 >= 2.4.0'
-
- .ELSE
-
--- fpicker.orig/source/unx/gnome/SalGtkFilePicker.cxx 2010-05-29 21:22:49.000000000 +0100
+++ fpicker/source/unx/gnome/SalGtkFilePicker.cxx 2010-05-29 21:26:05.000000000 +0100
@@ -602,7 +602,11 @@
@@ -902,7 +790,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
+#if GTK_CHECK_VERSION(2,90,0)
+ return gtk_widget_get_window(widget);
+#else
-+ return widget->window
++ return widget->window;
+#endif
+}
+
@@ -990,42 +878,6 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
#ifdef GDK_WINDOWING_X11
#include <gdk/gdkx.h>
#endif
---- libegg.orig/source/makefile.mk 2010-05-29 21:27:29.000000000 +0100
-+++ libegg/source/makefile.mk 2010-05-30 12:45:54.000000000 +0100
-@@ -40,7 +40,7 @@
- .IF "$(L10N_framework)"==""
- .IF "$(ENABLE_GTK)"!=""
-
--PKGCONFIG_MODULES=gtk+-2.0 gdk-2.0
-+PKGCONFIG_MODULES=gtk+-3.0 gdk-3.0
- .INCLUDE: pkg_config.mk
- CFLAGS+=$(PKGCONFIG_CFLAGS)
-
---- scp2.orig/source/ooo/makefile.mk 2010-05-29 21:24:45.000000000 +0100
-+++ scp2/source/ooo/makefile.mk 2010-05-29 21:26:42.000000000 +0100
-@@ -63,9 +63,9 @@
- .IF "$(GUI)"=="UNX"
- .IF "$(ENABLE_GTK)" != ""
- SCPDEFS+=-DENABLE_GTK
--PKGCONFIG_MODULES=gtk+-2.0
-+PKGCONFIG_MODULES=gtk+-3.0
- .INCLUDE: pkg_config.mk
--GTK_TWO_FOUR=$(shell @+-$(PKG_CONFIG) --exists 'gtk+-2.0 >= 2.4.0' && echo YES)
-+GTK_TWO_FOUR=$(shell @+-$(PKG_CONFIG) --exists 'gtk+-3.0 >= 2.4.0' && echo YES)
- .IF "$(GTK_TWO_FOUR)" != ""
- SCPDEFS+=-DGTK_TWO_FOUR
- .ENDIF
---- sfx2.orig/source/appl/makefile.mk 2010-05-29 21:22:29.000000000 +0100
-+++ sfx2/source/appl/makefile.mk 2010-05-30 12:54:53.000000000 +0100
-@@ -52,7 +52,7 @@
- .IF "$(GUI)"=="UNX"
- CDEFS+=-DDLL_NAME=libsfx$(DLLPOSTFIX)$(DLLPOST)
- .IF "$(ENABLE_SYSTRAY_GTK)"=="TRUE"
-- PKGCONFIG_MODULES=gtk+-2.0
-+ PKGCONFIG_MODULES=gtk+-3.0
- .INCLUDE: pkg_config.mk
- CFLAGS+=$(PKGCONFIG_CFLAGS)
- CFLAGS+=-DENABLE_QUICKSTART_APPLET
--- sfx2.orig/source/appl/shutdowniconunx.cxx 2010-05-29 21:22:29.000000000 +0100
+++ sfx2/source/appl/shutdowniconunx.cxx 2010-05-30 12:59:35.000000000 +0100
@@ -302,18 +302,34 @@
@@ -1077,46 +929,6 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
GtkWidget *pIconImage = gtk_image_new();
gtk_container_add( GTK_CONTAINER( pParent ), pIconImage );
---- sfx2.orig/util/makefile.mk 2010-05-29 21:22:29.000000000 +0100
-+++ sfx2/util/makefile.mk 2010-05-30 12:54:56.000000000 +0100
-@@ -140,7 +140,7 @@
- # gtk quick-starter
- .IF "$(GUI)"=="UNX"
- .IF "$(ENABLE_SYSTRAY_GTK)"=="TRUE"
--PKGCONFIG_MODULES=gtk+-2.0
-+PKGCONFIG_MODULES=gtk+-3.0
- .INCLUDE: pkg_config.mk
- CFLAGS+=$(PKGCONFIG_CFLAGS)
-
---- configure.in 2010-05-27 08:08:18.000000000 +0100
-+++ configure.in 2010-05-29 11:33:43.000000000 +0100
-@@ -4574,7 +4577,7 @@
- elif test "$_os" = "Darwin"; then
- if test "$MOZILLA_TOOLKIT" = "gtk2"; then
- AC_MSG_NOTICE([checking whether mozilla can be built...])
-- PKG_CHECK_MODULES(MOZGTK2, gtk+-2.0 >= 2.4 libIDL-2.0 >= 0.8, AC_MSG_NOTICE([OK - can build mozilla]), AC_MSG_ERROR([Prerequisites to build mozilla not met. Either use the precompiled mozilla binaries or install the missing packages]))
-+ PKG_CHECK_MODULES(MOZGTK2, gtk+-3.0 >= 2.4 libIDL-2.0 >= 0.8, AC_MSG_NOTICE([OK - can build mozilla]), AC_MSG_ERROR([Prerequisites to build mozilla not met. Either use the precompiled mozilla binaries or install the missing packages]))
- else
- PKG_CHECK_MODULES(MOZLIBREQ, libIDL-2.0 >= 0.6.3, MOZIDL="TRUE", MOZIDL="")
- if test -z "$MOZIDL"; then
-@@ -4584,7 +4587,7 @@
- else
- # Generic Unix/Linux section
- if test "$MOZILLA_TOOLKIT" = "gtk2"; then
-- PKG_CHECK_MODULES(MOZLIBREQ, gtk+-2.0, MOZGTK="TRUE", MOZGTK="")
-+ PKG_CHECK_MODULES(MOZLIBREQ, gtk+-3.0, MOZGTK="TRUE", MOZGTK="")
- if test -z "$MOZGTK"; then
- AC_MSG_ERROR([GTK2 is needed to build mozilla.])
- fi
-@@ -5643,7 +5641,7 @@
- if test "$test_gtk" = "yes"; then
-
- if test "$ENABLE_GTK" = "TRUE" ; then
-- PKG_CHECK_MODULES(GTK, gtk+-2.0 >= 2.4 gdk-pixbuf-xlib-2.0 >= 2.2 ,,AC_MSG_ERROR([requirements to build the gtk-plugin not met. Use --disable-gtk or install the missing packages]))
-+ PKG_CHECK_MODULES(GTK, gtk+-3.0 >= 2.4 gdk-pixbuf-xlib-2.0 >= 2.2 ,,AC_MSG_ERROR([requirements to build the gtk-plugin not met. Use --disable-gtk or install the missing packages]))
- BUILD_TYPE="$BUILD_TYPE GTK"
-
- if test "x$enable_systray" = "xyes"; then
--- vcl.orig/unx/gtk/app/gtkdata.cxx 2010-06-14 19:51:39.500810695 +0100
+++ vcl/unx/gtk/app/gtkdata.cxx 2010-06-15 10:07:16.669799057 +0100
@@ -217,11 +217,12 @@
@@ -1744,22 +1556,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
aValue, rCaption );
rNativeContentRegion = rNativeBoundingRegion;
-@@ -1102,8 +1107,12 @@
- GtkRequisition aReq;
- gtk_widget_size_request( widget, &aReq );
- Rectangle aEditRect = rControlRegion;
-- aEditRect = Rectangle( aEditRect.TopLeft(),
-- Size( aEditRect.GetWidth(), aReq.height+1 ) );
-+ //Don't grow past space available
-+ if ((aReq.height+1) < aEditRect.GetHeight())
-+ {
-+ aEditRect = Rectangle( aEditRect.TopLeft(),
-+ Size( aEditRect.GetWidth(), aReq.height+1 ) );
-+ }
- rNativeBoundingRegion = aEditRect;
- rNativeContentRegion = rNativeBoundingRegion;
- returnVal = TRUE;
-@@ -1133,7 +1142,7 @@
+@@ -1134,7 +1139,7 @@
returnVal = TRUE;
}
@@ -1768,7 +1565,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
}
-@@ -1143,67 +1152,67 @@
+@@ -1144,67 +1149,67 @@
BOOL GtkSalGraphics::NWPaintGTKButton(
GdkDrawable* gdkDrawable,
ControlType, ControlPart,
@@ -1883,7 +1680,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
for( clipList::const_iterator it = rClipList.begin(); it != rClipList.end(); ++it)
{
-@@ -1224,88 +1233,88 @@
+@@ -1225,88 +1230,88 @@
if ( (GTK_BUTTON(gWidgetData[m_nScreen].gBtnWidget)->relief != GTK_RELIEF_NONE)
|| (nState & CTRL_STATE_PRESSED)
@@ -2036,7 +1833,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
}
//-------------------------------------
-@@ -1318,15 +1327,15 @@
+@@ -1319,15 +1324,15 @@
const ImplControlValue& aValue,
const OUString& )
{
@@ -2059,7 +1856,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
gint indicator_size;
gtk_widget_style_get( gWidgetData[m_nScreen].gRadioWidget, "indicator_size", &indicator_size, (char *)NULL);
-@@ -1334,22 +1343,22 @@
+@@ -1335,22 +1340,22 @@
x = rControlRectangle.Left() + (rControlRectangle.GetWidth()-indicator_size)/2;
y = rControlRectangle.Top() + (rControlRectangle.GetHeight()-indicator_size)/2;
@@ -2091,7 +1888,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
for( clipList::const_iterator it = rClipList.begin(); it != rClipList.end(); ++it )
{
-@@ -1363,7 +1372,7 @@
+@@ -1364,7 +1369,7 @@
x, y, indicator_size, indicator_size );
}
@@ -2100,7 +1897,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
}
//-------------------------------------
-@@ -1376,15 +1385,15 @@
+@@ -1377,15 +1382,15 @@
const ImplControlValue& aValue,
const OUString& )
{
@@ -2124,7 +1921,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
gint indicator_size;
gtk_widget_style_get( gWidgetData[m_nScreen].gCheckWidget, "indicator_size", &indicator_size, (char *)NULL);
-@@ -1392,10 +1401,10 @@
+@@ -1393,10 +1398,10 @@
x = rControlRectangle.Left() + (rControlRectangle.GetWidth()-indicator_size)/2;
y = rControlRectangle.Top() + (rControlRectangle.GetHeight()-indicator_size)/2;
@@ -2139,7 +1936,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
for( clipList::const_iterator it = rClipList.begin(); it != rClipList.end(); ++it )
{
-@@ -1409,17 +1418,17 @@
+@@ -1410,17 +1415,17 @@
x, y, indicator_size, indicator_size );
}
@@ -2160,7 +1957,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
rButton.Left() + ( rButton.GetWidth() - rArrow.GetWidth() ) / 2,
rButton.Top() + ( rButton.GetHeight() - rArrow.GetHeight() ) / 2
) );
-@@ -1469,54 +1478,54 @@
+@@ -1470,54 +1475,54 @@
button12BoundRect.Move( -rControlRectangle.Left(), -rControlRectangle.Top() );
button21BoundRect.Move( -rControlRectangle.Left(), -rControlRectangle.Top() );
@@ -2245,7 +2042,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
if ( has_backward )
{
-@@ -1541,33 +1550,33 @@
+@@ -1542,33 +1547,33 @@
button21BoundRect.SetSize( Size( stepper_size, slider_width ) );
button22BoundRect.SetSize( Size( stepper_size, slider_width ) );
@@ -2300,7 +2097,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
if ( has_backward )
{
-@@ -1576,7 +1585,7 @@
+@@ -1577,7 +1582,7 @@
}
button11BoundRect.Move( (scrollbarRect.GetWidth() - slider_width) / 2, trough_border );
button11BoundRect.SetSize( Size( slider_width, stepper_size ) );
@@ -2309,7 +2106,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
if ( has_backward2 )
{
-@@ -1591,41 +1600,41 @@
+@@ -1592,41 +1597,41 @@
button21BoundRect.SetSize( Size( slider_width, stepper_size ) );
button22BoundRect.SetSize( Size( slider_width, stepper_size ) );
@@ -2379,7 +2176,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
// as multiple paints are required for the scrollbar
// painting them directly to the window flickers
-@@ -1640,81 +1649,81 @@
+@@ -1641,81 +1646,81 @@
GdkDrawable* const &gdkDrawable = GDK_DRAWABLE( pixmap );
GdkRectangle* gdkRect = NULL;
@@ -2491,7 +2288,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
gtk_paint_arrow( style, gdkDrawable, stateType, shadowType,
gdkRect, GTK_WIDGET(scrollbarWidget), scrollbarTag, button1Type, TRUE,
x+hShim+arrowRect.Left(), y+vShim+arrowRect.Top(),
-@@ -1723,13 +1732,13 @@
+@@ -1724,13 +1729,13 @@
if ( has_forward )
{
NWConvertVCLStateToGTKState( pScrollbarVal->mnButton2State, &stateType, &shadowType );
@@ -2508,7 +2305,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
gtk_paint_arrow( style, gdkDrawable, stateType, shadowType,
gdkRect, GTK_WIDGET(scrollbarWidget), scrollbarTag, button2Type, TRUE,
x+hShim+arrowRect.Left(), y+vShim+arrowRect.Top(),
-@@ -1743,12 +1752,12 @@
+@@ -1744,12 +1749,12 @@
}
g_object_unref( pixmap );
@@ -2523,7 +2320,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
{
gint slider_width;
gint stepper_size;
-@@ -1757,26 +1766,26 @@
+@@ -1758,26 +1763,26 @@
NWEnsureGTKScrollbars( nScreen );
@@ -2562,7 +2359,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
gint nFirst = 0;
gint nSecond = 0;
-@@ -1826,7 +1835,7 @@
+@@ -1827,7 +1832,7 @@
buttonRect.SetSize( Size( buttonWidth, buttonHeight ) );
@@ -2571,7 +2368,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
}
//-------------------------------------
-@@ -1839,7 +1848,7 @@
+@@ -1840,7 +1845,7 @@
const ImplControlValue& aValue,
const OUString& rCaption )
{
@@ -2580,7 +2377,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
GdkRectangle clipRect;
// Find the overall bounding rect of the buttons's drawing area,
-@@ -1856,7 +1865,7 @@
+@@ -1857,7 +1862,7 @@
NWPaintOneEditBox( m_nScreen, gdkDrawable, &clipRect, nType, nPart, pixmapRect, nState, aValue, rCaption );
}
@@ -2589,7 +2386,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
}
-@@ -1866,31 +1875,31 @@
+@@ -1867,31 +1872,31 @@
*/
static Rectangle NWGetEditBoxPixmapRect(int nScreen,
ControlType,
@@ -2637,7 +2434,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
}
-@@ -1898,67 +1907,66 @@
+@@ -1899,67 +1904,66 @@
* All coordinates should be local to the Pixmap, NOT
* screen/window coordinates.
*/
@@ -2740,7 +2537,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
gdkRect, widget, "entry",
aEditBoxRect.Left(), aEditBoxRect.Top(),
aEditBoxRect.GetWidth(), aEditBoxRect.GetHeight() );
-@@ -2067,33 +2075,33 @@
+@@ -2068,33 +2072,33 @@
static Rectangle NWGetSpinButtonRect( int nScreen,
ControlType,
@@ -2794,7 +2591,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
else
{
buttonRect.Right() = buttonRect.Left()-1;
-@@ -2102,7 +2110,7 @@
+@@ -2103,7 +2107,7 @@
buttonRect.Bottom() = aAreaRect.Bottom();
}
@@ -2803,7 +2600,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
}
//---
-@@ -2136,22 +2144,24 @@
+@@ -2137,22 +2141,24 @@
arrowSize = (buttonRect.GetWidth() - (2 * gWidgetData[nScreen].gSpinButtonWidget->style->xthickness)) - 4;
arrowSize -= arrowSize % 2 - 1; /* force odd */
arrowRect.SetSize( Size( arrowSize, arrowSize ) );
@@ -2838,7 +2635,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
ControlType nType, ControlPart nPart,
const Rectangle& rControlRectangle,
const clipList& rClipList,
-@@ -2159,40 +2169,37 @@
+@@ -2160,40 +2166,37 @@
const ImplControlValue& aValue,
const OUString& rCaption )
{
@@ -2901,7 +2698,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
buttonRect.Top() + (gint)((buttonRect.GetHeight() - arrowRect.GetHeight()) / 2) ) );
for( clipList::const_iterator it = rClipList.begin(); it != rClipList.end(); ++it )
-@@ -2212,48 +2219,163 @@
+@@ -2213,48 +2216,163 @@
x+(buttonRect.Left() - pixmapRect.Left()),
y+(buttonRect.Top() - pixmapRect.Top()),
buttonRect.GetWidth(), buttonRect.GetHeight() );
@@ -3085,7 +2882,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
if( nPart == PART_BUTTON_DOWN )
{
aButtonRect.SetSize( Size( nButtonWidth, aAreaRect.GetHeight() ) );
-@@ -2262,13 +2384,11 @@
+@@ -2263,13 +2381,11 @@
}
else if( nPart == PART_SUB_EDIT )
{
@@ -3102,12 +2899,8 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
aButtonRect.SetSize( Size( aAreaRect.GetWidth() - nButtonWidth - 2 * adjust_x,
aAreaRect.GetHeight() - 2 * adjust_y ) );
Point aEditPos = aAreaRect.TopLeft();
-@@ -2277,27 +2397,92 @@
- aButtonRect.SetPos( aEditPos );
- }
-
-- return( aButtonRect );
-+ return( aButtonRect );
+@@ -2281,22 +2397,86 @@
+ return( aButtonRect );
}
-//-------------------------------------
@@ -3126,6 +2919,10 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
+ gint nFocusPad;
+ NWEnsureGTKComboBox ( nScreen );
++ // Grab some button style attributes
++ gtk_widget_style_get( gWidgetData[nScreen].gComboBox_ButtonWidget,
++ "focus-line-width", &nFocusWidth,
++ "focus-padding", &nFocusPad, (char *)NULL );
-
-BOOL GtkSalGraphics::NWPaintGTKTabItem( ControlType nType, ControlPart,
@@ -3135,18 +2932,11 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
- const ImplControlValue& aValue,
- const OUString& )
-{
-- OSL_ASSERT( aValue.getType() == CTRL_TAB_ITEM );
+- OSL_ASSERT( nType != CTRL_TAB_ITEM || aValue.getType() == CTRL_TAB_ITEM );
- GdkPixmap * pixmap;
- Rectangle pixmapRect;
- Rectangle tabRect;
-- const TabitemValue * pTabitemValue = static_cast<const TabitemValue *>(&aValue);
- GtkStateType stateType;
-- GtkShadowType shadowType;
-+ // Grab some button style attributes
-+ gtk_widget_style_get( gWidgetData[nScreen].gComboBox_ButtonWidget,
-+ "focus-line-width", &nFocusWidth,
-+ "focus-padding", &nFocusPad, (char *)NULL );
-+
+ nArrowWidth = MIN_ARROW_SIZE + (GTK_MISC(gWidgetData[nScreen].gComboBox_ArrowWidget)->xpad * 2);
+
+ gint nSeparatorWidth = 0;
@@ -3202,100 +2992,15 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
+ const ImplControlValue& aValue,
+ const OUString& )
+{
-+ OSL_ASSERT( aValue.getType() == CTRL_TAB_ITEM );
++ OSL_ASSERT( nType != CTRL_TAB_ITEM || aValue.getType() == CTRL_TAB_ITEM );
+ GdkPixmap * pixmap;
+ Rectangle pixmapRect;
+ Rectangle tabRect;
-+ const TabitemValue * pTabitemValue = static_cast<const TabitemValue *>(&aValue);
+ GtkStateType stateType;
-+ GtkShadowType shadowType;
+ GtkShadowType shadowType;
if( ! gWidgetData[ m_nScreen ].gCacheTabItems )
{
- gWidgetData[ m_nScreen ].gCacheTabItems = new NWPixmapCache( m_nScreen );
-@@ -2311,48 +2496,48 @@
- if( !aCachePage.GetSize() )
- aCachePage.SetSize( 1 );
-
-- if ( !pTabitemValue && (nType==CTRL_TAB_ITEM) )
-- {
-+ if ( !pTabitemValue && (nType==CTRL_TAB_ITEM) )
-+ {
- std::fprintf( stderr, "NWPaintGTKTabItem() received a NULL TabitemValue. Cannot draw native tab\n" );
-- return( false );
-- }
-+ return( false );
-+ }
-
-- NWEnsureGTKButton( m_nScreen );
-- NWEnsureGTKNotebook( m_nScreen );
-- NWConvertVCLStateToGTKState( nState, &stateType, &shadowType );
-+ NWEnsureGTKButton( m_nScreen );
-+ NWEnsureGTKNotebook( m_nScreen );
-+ NWConvertVCLStateToGTKState( nState, &stateType, &shadowType );
-
-- // Find the overall bounding rect of the buttons's drawing area,
-- // plus its actual draw rect excluding adornment
-- pixmapRect = rControlRectangle;
-- if ( nType == CTRL_TAB_ITEM )
-- {
-- if ( !pTabitemValue->isFirst() )
-- {
-- // GTK+ tabs overlap on the right edge (the top tab obscures the
-- // left edge of the tab right "below" it, so adjust the rectangle
-- // to draw tabs slightly large so the overlap happens
-- pixmapRect.Move( -2, 0 );
-- pixmapRect.SetSize( Size( pixmapRect.GetWidth() + 2, pixmapRect.GetHeight() ) );
-- }
-- if ( nState & CTRL_STATE_SELECTED )
-- {
-- // In GTK+, the selected tab is 2px taller than all other tabs
-- pixmapRect.Move( 0, -2 );
-- pixmapRect.Bottom() += 2;
-- tabRect = pixmapRect;
-- // Only draw over 1 pixel of the tab pane that this tab is drawn on top of.
-- tabRect.Bottom() -= 1;
-- }
-- else
-- tabRect = pixmapRect;
-+ // Find the overall bounding rect of the buttons's drawing area,
-+ // plus its actual draw rect excluding adornment
-+ pixmapRect = rControlRectangle;
-+ if ( nType == CTRL_TAB_ITEM )
-+ {
-+ if ( !pTabitemValue->isFirst() )
-+ {
-+ // GTK+ tabs overlap on the right edge (the top tab obscures the
-+ // left edge of the tab right "below" it, so adjust the rectangle
-+ // to draw tabs slightly large so the overlap happens
-+ pixmapRect.Move( -2, 0 );
-+ pixmapRect.SetSize( Size( pixmapRect.GetWidth() + 2, pixmapRect.GetHeight() ) );
-+ }
-+ if ( nState & CTRL_STATE_SELECTED )
-+ {
-+ // In GTK+, the selected tab is 2px taller than all other tabs
-+ pixmapRect.Move( 0, -2 );
-+ pixmapRect.Bottom() += 2;
-+ tabRect = pixmapRect;
-+ // Only draw over 1 pixel of the tab pane that this tab is drawn on top of.
-+ tabRect.Bottom() -= 1;
-+ }
-+ else
-+ tabRect = pixmapRect;
-
-- // Allow the tab to draw a right border if needed
-- tabRect.Right() -= 1;
-+ // Allow the tab to draw a right border if needed
-+ tabRect.Right() -= 1;
-
- // #129732# avoid degenerate cases which might lead to crashes
- if( tabRect.GetWidth() <= 1 || tabRect.GetHeight() <= 1 )
- return false;
-- }
-+ }
-
- if( nType == CTRL_TAB_ITEM )
- {
-@@ -2366,7 +2551,7 @@
+@@ -2366,7 +2546,7 @@
}
@@ -3304,7 +3009,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
pixmap = gdk_pixmap_new( NULL, pixmapRect.GetWidth(), pixmapRect.GetHeight(),
GetX11SalData()->GetDisplay()->GetVisual( m_nScreen ).GetDepth() );
-@@ -2376,42 +2561,42 @@
+@@ -2376,42 +2556,42 @@
paintRect.height = pixmapRect.GetHeight();
gtk_paint_flat_box( m_pWindow->style, pixmap, GTK_STATE_NORMAL,
@@ -3353,10 +3058,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
- }
+ case CTRL_TAB_ITEM:
+ stateType = ( nState & CTRL_STATE_SELECTED ) ? GTK_STATE_NORMAL : GTK_STATE_ACTIVE;
-
-- // Crux seems to think it can make the pane without a left edge
-- if ( nType == CTRL_FIXEDBORDER )
-- pixmapRect.Move( 1, 0 );
++
+ gtk_paint_extension( gWidgetData[m_nScreen].gNotebookWidget->style, pixmap, stateType, GTK_SHADOW_OUT, NULL, gWidgetData[m_nScreen].gNotebookWidget,
+ (char *)"tab", (tabRect.Left() - pixmapRect.Left()), (tabRect.Top() - pixmapRect.Top()),
+ tabRect.GetWidth(), tabRect.GetHeight(), GTK_POS_BOTTOM );
@@ -3371,14 +3073,17 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
+ default:
+ break;
+ }
-+
+
+- // Crux seems to think it can make the pane without a left edge
+- if ( nType == CTRL_FIXEDBORDER )
+- pixmapRect.Move( 1, 0 );
+ // Crux seems to think it can make the pane without a left edge
+ if ( nType == CTRL_FIXEDBORDER )
+ pixmapRect.Move( 1, 0 );
// cache data
if( nType == CTRL_TAB_ITEM )
-@@ -2419,152 +2604,65 @@
+@@ -2419,152 +2599,65 @@
else
aCachePage.Fill( nType, nState, pixmapRect, pixmap );
@@ -3554,7 +3259,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
GTK_WIDGET_UNSET_FLAGS( gWidgetData[m_nScreen].gHandleBoxWidget, GTK_SENSITIVE );
if ( nState & CTRL_STATE_ENABLED )
-@@ -2588,7 +2686,7 @@
+@@ -2588,7 +2681,7 @@
bPaintButton =
(GTK_BUTTON(pButtonWidget)->relief != GTK_RELIEF_NONE)
|| (nState & CTRL_STATE_PRESSED)
@@ -3563,7 +3268,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
if( aValue.getTristateVal() == BUTTONVALUE_ON )
{
pButtonWidget = gWidgetData[m_nScreen].gToolbarToggleWidget;
-@@ -2662,7 +2760,7 @@
+@@ -2662,7 +2755,7 @@
}
}
@@ -3572,7 +3277,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
}
//----
-@@ -2670,24 +2768,24 @@
+@@ -2670,24 +2763,24 @@
BOOL GtkSalGraphics::NWPaintGTKMenubar(
GdkDrawable* gdkDrawable,
ControlType, ControlPart nPart,
@@ -3607,7 +3312,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
if( nPart == PART_MENU_ITEM )
{
-@@ -2749,13 +2847,13 @@
+@@ -2749,13 +2842,13 @@
}
}
@@ -3623,7 +3328,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
const clipList& rClipList,
ControlState nState, const ImplControlValue&,
const OUString& )
-@@ -2765,19 +2863,19 @@
+@@ -2765,19 +2858,19 @@
if( nPart == PART_MENU_ITEM && ! (nState & CTRL_STATE_ENABLED) )
return FALSE;
@@ -3652,7 +3357,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
if( nPart == PART_MENU_ITEM &&
( nState & (CTRL_STATE_SELECTED|CTRL_STATE_ROLLOVER) ) )
-@@ -2879,26 +2977,26 @@
+@@ -2879,26 +2972,26 @@
}
}
@@ -3686,7 +3391,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
for( clipList::const_iterator it = rClipList.begin(); it != rClipList.end(); ++it )
{
-@@ -2917,13 +3015,13 @@
+@@ -2917,13 +3010,13 @@
x, y, w, h );
}
@@ -3702,7 +3407,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
const clipList&,
ControlState nState, const ImplControlValue& rValue,
const OUString& )
-@@ -2935,13 +3033,13 @@
+@@ -2935,13 +3028,13 @@
aRect.Right() += 2;
aRect.Top() -= 2;
aRect.Bottom() += 2;
@@ -3723,7 +3428,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
ButtonValue aButtonValue = rValue.getTristateVal();
GtkExpanderStyle eStyle = GTK_EXPANDER_EXPANDED;
-@@ -2968,25 +3066,25 @@
+@@ -2968,25 +3061,25 @@
w/2, h/2,
eStyle );
@@ -3755,7 +3460,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
long nProgressWidth = rValue.getNumericVal();
-@@ -3158,120 +3256,10 @@
+@@ -3158,120 +3251,10 @@
}
#endif
@@ -3878,7 +3583,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
}
static Rectangle NWGetToolbarRect( int nScreen,
-@@ -3477,7 +3465,7 @@
+@@ -3477,7 +3460,7 @@
// make the "light" color lighter than the menu color and the "shadow"
// color darker than it.
if ( aStyleSet.GetMenuColor().GetLuminance() >= 32 &&
@@ -3887,7 +3592,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
{
Color temp = aStyleSet.GetMenuColor();
temp.IncreaseLuminance( 8 );
-@@ -3495,10 +3483,10 @@
+@@ -3495,10 +3478,10 @@
aStyleSet.SetMenuHighlightTextColor( aHighlightTextColor );
// UI font
@@ -3902,7 +3607,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
PangoStretch eStretch = pango_font_description_get_stretch( pStyle->font_desc );
psp::FastPrintFontInfo aInfo;
-@@ -3507,9 +3495,9 @@
+@@ -3507,9 +3490,9 @@
// set italic
switch( eStyle )
{
@@ -3915,7 +3620,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
}
// set weight
if( eWeight <= PANGO_WEIGHT_ULTRALIGHT )
-@@ -3525,15 +3513,15 @@
+@@ -3525,15 +3508,15 @@
// set width
switch( eStretch )
{
@@ -3940,7 +3645,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
}
#if OSL_DEBUG_LEVEL > 1
-@@ -3627,18 +3615,18 @@
+@@ -3627,18 +3610,18 @@
g_free( pIconThemeName );
// FIXME: need some way of fetching toolbar icon size.
@@ -3963,7 +3668,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
}
aStyleSet.SetCairoFontOptions( pNewOptions );
-@@ -3698,8 +3686,8 @@
+@@ -3698,8 +3681,8 @@
GdkPixmap* GtkSalGraphics::NWGetPixmapFromScreen( Rectangle srcRect )
{
// Create a new pixmap to hold the composite of the window background and the control
@@ -3974,7 +3679,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
if( !pPixmap || !pPixmapGC )
{
-@@ -3760,29 +3748,29 @@
+@@ -3760,29 +3743,29 @@
* State conversion
************************************************************************/
static void NWConvertVCLStateToGTKState( ControlState nVCLState,
@@ -4025,7 +3730,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
}
/************************************************************************
-@@ -3790,19 +3778,19 @@
+@@ -3790,19 +3773,19 @@
************************************************************************/
static void NWSetWidgetState( GtkWidget* widget, ControlState nState, GtkStateType nGtkState )
{
@@ -4058,7 +3763,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
}
/************************************************************************
-@@ -3814,179 +3802,279 @@
+@@ -3814,179 +3797,279 @@
static void NWAddWidgetToCacheWindow( GtkWidget* widget, int nScreen )
{
NWFWidgetData& rData = gWidgetData[nScreen];
@@ -4435,7 +4140,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
}
//-------------------------------------
-@@ -4003,7 +4091,7 @@
+@@ -4003,7 +4086,7 @@
GtkReliefStyle aRelief = GTK_RELIEF_NORMAL;
gtk_widget_ensure_style( gWidgetData[nScreen].gToolbarWidget );
gtk_widget_style_get( gWidgetData[nScreen].gToolbarWidget,
@@ -4444,7 +4149,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
(char *)NULL);
gtk_button_set_relief( GTK_BUTTON(gWidgetData[nScreen].gToolbarButtonWidget), aRelief );
-@@ -4102,7 +4190,7 @@
+@@ -4102,7 +4185,7 @@
if( !gWidgetData[nScreen].gProgressBar )
{
gWidgetData[nScreen].gProgressBar = gtk_progress_bar_new ();
@@ -4453,7 +4158,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
}
}
-@@ -4111,7 +4199,7 @@
+@@ -4111,7 +4194,7 @@
if( !gWidgetData[nScreen].gTreeView )
{
gWidgetData[nScreen].gTreeView = gtk_tree_view_new ();
@@ -4462,7 +4167,7 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
}
}
-@@ -4120,11 +4208,13 @@
+@@ -4120,11 +4203,13 @@
if( !gWidgetData[nScreen].gHScale )
{
gWidgetData[nScreen].gHScale = gtk_hscale_new_with_range(0, 10, 1);
@@ -4506,51 +4211,6 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
m_aSystemData.pShellWidget = GTK_WIDGET(pParent->getWindow());
g_signal_connect( G_OBJECT(m_pSocket), "button-press-event", G_CALLBACK(signalButton), this );
-@@ -83,7 +84,7 @@
- GtkSalObject::~GtkSalObject()
- {
- if( m_pRegion )
-- gdk_region_destroy( m_pRegion );
-+ cairo_region_destroy( m_pRegion );
- if( m_pSocket )
- {
- // remove socket from parent frame's fixed container
-@@ -101,7 +102,7 @@
- void GtkSalObject::ResetClipRegion()
- {
- if( m_pSocket )
-- gdk_window_shape_combine_region( m_pSocket->window, NULL, 0, 0 );
-+ gdk_window_shape_combine_region( widget_get_window(m_pSocket), NULL, 0, 0 );
- }
-
- USHORT GtkSalObject::GetClipRegionType()
-@@ -112,8 +113,8 @@
- void GtkSalObject::BeginSetClipRegion( ULONG )
- {
- if( m_pRegion )
-- gdk_region_destroy( m_pRegion );
-- m_pRegion = gdk_region_new();
-+ cairo_region_destroy( m_pRegion );
-+ m_pRegion = cairo_region_create();
- }
-
- void GtkSalObject::UnionClipRegion( long nX, long nY, long nWidth, long nHeight )
-@@ -124,13 +125,13 @@
- aRect.width = nWidth;
- aRect.height = nHeight;
-
-- gdk_region_union_with_rect( m_pRegion, &aRect );
-+ cairo_region_union_rectangle( m_pRegion, &aRect );
- }
-
- void GtkSalObject::EndSetClipRegion()
- {
- if( m_pSocket )
-- gdk_window_shape_combine_region( m_pSocket->window, m_pRegion, 0, 0 );
-+ gdk_window_shape_combine_region( widget_get_window(m_pSocket), m_pRegion, 0, 0 );
- }
-
- void GtkSalObject::SetPosSize( long nX, long nY, long nWidth, long nHeight )
--- fpicker.orig/source/unx/gnome/SalGtkPicker.cxx 2010-05-26 17:30:44.000000000 +0100
+++ fpicker/source/unx/gnome/SalGtkPicker.cxx 2010-07-01 12:51:05.000000000 +0100
@@ -155,7 +157,11 @@
@@ -4631,25 +4291,3 @@ diff -ru fpicker.orig/source/unx/gnome/SalGtkFilePicker.hxx fpicker/source/unx/g
static GdkFilterReturn filterGdkEvent( GdkXEvent* sys_event,
GdkEvent* event,
gpointer data );
---- vcl.orig/unx/inc/plugins/gtk/gtkframe.hxx 2010-07-13 16:17:08.000000000 +0100
-+++ vcl/unx/inc/plugins/gtk/gtkframe.hxx 2010-07-13 16:16:56.000000000 +0100
-@@ -195,7 +195,7 @@
- Size m_aMinSize;
- Rectangle m_aRestorePosSize;
-
-- GdkRegion* m_pRegion;
-+ cairo_region_t* m_pRegion;
-
- void Init( SalFrame* pParent, ULONG nStyle );
- void Init( SystemParentData* pSysData );
---- vcl.orig/unx/inc/plugins/gtk/gtkobject.hxx 2010-07-13 16:18:03.000000000 +0100
-+++ vcl/unx/inc/plugins/gtk/gtkobject.hxx 2010-07-13 16:17:47.000000000 +0100
-@@ -37,7 +37,7 @@
- {
- SystemChildData m_aSystemData;
- GtkWidget* m_pSocket;
-- GdkRegion* m_pRegion;
-+ cairo_region_t* m_pRegion;
-
- // signals
- static gboolean signalButton( GtkWidget*, GdkEventButton*, gpointer );
More information about the scm-commits
mailing list