[dfb,422221] Gtk/DirectFB misc build stuff

This commit is contained in:
Vladimir Vukicevic 2008-08-06 13:48:55 -07:00
parent 67fa7ce818
commit ad49e66ee8
6 changed files with 23 additions and 1 deletions

View File

@ -84,8 +84,11 @@ MOZ_CHROME_FILE_FORMAT = @MOZ_CHROME_FILE_FORMAT@
MOZ_WIDGET_TOOLKIT = @MOZ_WIDGET_TOOLKIT@ MOZ_WIDGET_TOOLKIT = @MOZ_WIDGET_TOOLKIT@
MOZ_GFX_TOOLKIT = @MOZ_GFX_TOOLKIT@ MOZ_GFX_TOOLKIT = @MOZ_GFX_TOOLKIT@
MOZ_DFB = @MOZ_DFB@
MOZ_X11 = @MOZ_X11@ MOZ_X11 = @MOZ_X11@
MOZ_PANGO = @MOZ_PANGO@
MOZ_JS_LIBS = @MOZ_JS_LIBS@ MOZ_JS_LIBS = @MOZ_JS_LIBS@
MOZ_DEBUG = @MOZ_DEBUG@ MOZ_DEBUG = @MOZ_DEBUG@

View File

@ -80,7 +80,6 @@ cairo-atsui.h
cairo-beos.h cairo-beos.h
cairo-ft.h cairo-ft.h
cairo-glitz.h cairo-glitz.h
cairo-nquartz.h
cairo-os2.h cairo-os2.h
cairo-pdf.h cairo-pdf.h
cairo-ps.h cairo-ps.h
@ -88,6 +87,8 @@ cairo-quartz.h
cairo-win32.h cairo-win32.h
cairo-xlib.h cairo-xlib.h
cairo-xlib-xrender.h cairo-xlib-xrender.h
cairo-directfb.h
cairo-qpainter.h
#endif #endif
callconv.h callconv.h
Carbon/Carbon.h Carbon/Carbon.h

View File

@ -277,8 +277,10 @@ endif
endif endif
ifdef MOZ_ENABLE_GTK2 ifdef MOZ_ENABLE_GTK2
ifdef MOZ_X11
STATIC_LIBS += gtkxtbin STATIC_LIBS += gtkxtbin
endif endif
endif
ifdef MOZ_IPCD ifdef MOZ_IPCD
DEFINES += -DMOZ_IPCD DEFINES += -DMOZ_IPCD

View File

@ -84,8 +84,10 @@ tier_gecko_dirs += \
$(NULL) $(NULL)
ifdef MOZ_ENABLE_GTK2 ifdef MOZ_ENABLE_GTK2
ifdef MOZ_X11
tier_gecko_dirs += widget/src/gtkxtbin tier_gecko_dirs += widget/src/gtkxtbin
endif endif
endif
ifdef MOZ_IPCD ifdef MOZ_IPCD
tier_gecko_dirs += ipc/ipcd tier_gecko_dirs += ipc/ipcd

View File

@ -269,7 +269,9 @@ static char **gRestartArgv;
#if defined(MOZ_WIDGET_GTK2) #if defined(MOZ_WIDGET_GTK2)
#include <gtk/gtk.h> #include <gtk/gtk.h>
#ifdef MOZ_X11
#include <gdk/gdkx.h> #include <gdk/gdkx.h>
#endif /* MOZ_X11 */
#include "nsGTKToolkit.h" #include "nsGTKToolkit.h"
#endif #endif
@ -2386,6 +2388,7 @@ static void MOZ_gdk_display_close(GdkDisplay *display)
// gdk_display_manager_set_default_display (gdk_display_manager_get(), NULL) // gdk_display_manager_set_default_display (gdk_display_manager_get(), NULL)
// was also broken. // was also broken.
if (gtk_check_version(2,10,0) != NULL) { if (gtk_check_version(2,10,0) != NULL) {
#ifdef MOZ_X11
// Version check failed - broken gdk_display_close. // Version check failed - broken gdk_display_close.
// //
// Let the gdk structures leak but at least close the Display, // Let the gdk structures leak but at least close the Display,
@ -2393,6 +2396,9 @@ static void MOZ_gdk_display_close(GdkDisplay *display)
Display* dpy = GDK_DISPLAY_XDISPLAY(display); Display* dpy = GDK_DISPLAY_XDISPLAY(display);
if (!theme_is_qt) if (!theme_is_qt)
XCloseDisplay(dpy); XCloseDisplay(dpy);
#else
gdk_display_close(display);
#endif /* MOZ_X11 */
} }
else { else {
if (!theme_is_qt) if (!theme_is_qt)

View File

@ -297,6 +297,8 @@ nsNativeAppSupportUnix::Start(PRBool *aRetVal)
*aRetVal = PR_TRUE; *aRetVal = PR_TRUE;
#ifdef MOZ_X11
PRLibrary *gnomeuiLib = PR_LoadLibrary("libgnomeui-2.so.0"); PRLibrary *gnomeuiLib = PR_LoadLibrary("libgnomeui-2.so.0");
if (!gnomeuiLib) if (!gnomeuiLib)
return NS_OK; return NS_OK;
@ -316,6 +318,8 @@ nsNativeAppSupportUnix::Start(PRBool *aRetVal)
return NS_OK; return NS_OK;
} }
#endif /* MOZ_X11 */
#ifdef ACCESSIBILITY #ifdef ACCESSIBILITY
// We will load gail, atk-bridge by ourself later // We will load gail, atk-bridge by ourself later
// We can't run atk-bridge init here, because gail get the control // We can't run atk-bridge init here, because gail get the control
@ -325,7 +329,9 @@ nsNativeAppSupportUnix::Start(PRBool *aRetVal)
setenv(accEnv, "0", 1); setenv(accEnv, "0", 1);
#endif #endif
#ifdef MOZ_X11
gnome_program_init("Gecko", "1.0", libgnomeui_module_info_get(), gArgc, gArgv, NULL); gnome_program_init("Gecko", "1.0", libgnomeui_module_info_get(), gArgc, gArgv, NULL);
#endif /* MOZ_X11 */
#ifdef ACCESSIBILITY #ifdef ACCESSIBILITY
if (accOldValue) { if (accOldValue) {
@ -339,6 +345,7 @@ nsNativeAppSupportUnix::Start(PRBool *aRetVal)
// gnome_program_init causes atexit handlers to be registered. Strange // gnome_program_init causes atexit handlers to be registered. Strange
// crashes will occur if these libraries are unloaded. // crashes will occur if these libraries are unloaded.
#ifdef MOZ_X11
gnome_client_request_interaction = (_gnome_client_request_interaction_fn) gnome_client_request_interaction = (_gnome_client_request_interaction_fn)
PR_FindFunctionSymbol(gnomeuiLib, "gnome_client_request_interaction"); PR_FindFunctionSymbol(gnomeuiLib, "gnome_client_request_interaction");
gnome_interaction_key_return = (_gnome_interaction_key_return_fn) gnome_interaction_key_return = (_gnome_interaction_key_return_fn)
@ -352,6 +359,7 @@ nsNativeAppSupportUnix::Start(PRBool *aRetVal)
GnomeClient *client = gnome_master_client(); GnomeClient *client = gnome_master_client();
g_signal_connect(client, "save-yourself", G_CALLBACK(save_yourself_cb), NULL); g_signal_connect(client, "save-yourself", G_CALLBACK(save_yourself_cb), NULL);
g_signal_connect(client, "die", G_CALLBACK(die_cb), NULL); g_signal_connect(client, "die", G_CALLBACK(die_cb), NULL);
#endif /* MOZ_X11 */
return NS_OK; return NS_OK;
} }