Commit 5830bf89 authored by Owen Taylor's avatar Owen Taylor Committed by Owen Taylor
Browse files

Add a singleton object that we can use to get notification when displays

Thu Jun 20 16:49:00 2002  Owen Taylor  <otaylor@redhat.com>

        * gdk/gdkdisplaymanager.[ch] gdk/gdk.[ch] gdk/gdkdisplay.c
        gdk/gdkinternals.h gdk/x11/gdkdisplay-x11.c
        gdk/win32/gdkdisplay-win32.c: Add a singleton object that
        we can use to get notification when displays
        appear / disappear or the default display changes.

        gdk_set_default_display() => gdk_display_manager_set_default_display()
        gdk_list_displays() => gdk_display_manager_list_displays().
        (#85696)

        * gdk/Makefile.am gdk/gdkmarshalers.list: Add marshaler
        generation.

        * gdk/gdkintl.h: Add this.

        * gtk/gtkmain.c: Add gtk_parse_args() that initializes
        GTK+ without opening a display.

        * gtk/gtkmain.c: Set things up so if a module
        exports gtk_module_init() and gtk_module_display_init(),
        then we treat it as multihead aware, otherwise,
        we only initialize it after the default display is set.
parent 4251a51e
Thu Jun 20 16:49:00 2002 Owen Taylor <otaylor@redhat.com>
* gdk/gdkdisplaymanager.[ch] gdk/gdk.[ch] gdk/gdkdisplay.c
gdk/gdkinternals.h gdk/x11/gdkdisplay-x11.c
gdk/win32/gdkdisplay-win32.c: Add a singleton object that
we can use to get notification when displays
appear / disappear or the default display changes.
gdk_set_default_display() => gdk_display_manager_set_default_display()
gdk_list_displays() => gdk_display_manager_list_displays().
(#85696)
* gdk/Makefile.am gdk/gdkmarshalers.list: Add marshaler
generation.
* gdk/gdkintl.h: Add this.
* gtk/gtkmain.c: Add gtk_parse_args() that initializes
GTK+ without opening a display.
* gtk/gtkmain.c: Set things up so if a module
exports gtk_module_init() and gtk_module_display_init(),
then we treat it as multihead aware, otherwise,
we only initialize it after the default display is set.
Thu Jun 20 15:53:21 2002 Owen Taylor <otaylor@redhat.com> Thu Jun 20 15:53:21 2002 Owen Taylor <otaylor@redhat.com>
Patch from Erwann Chenede. Patch from Erwann Chenede.
......
Thu Jun 20 16:49:00 2002 Owen Taylor <otaylor@redhat.com>
* gdk/gdkdisplaymanager.[ch] gdk/gdk.[ch] gdk/gdkdisplay.c
gdk/gdkinternals.h gdk/x11/gdkdisplay-x11.c
gdk/win32/gdkdisplay-win32.c: Add a singleton object that
we can use to get notification when displays
appear / disappear or the default display changes.
gdk_set_default_display() => gdk_display_manager_set_default_display()
gdk_list_displays() => gdk_display_manager_list_displays().
(#85696)
* gdk/Makefile.am gdk/gdkmarshalers.list: Add marshaler
generation.
* gdk/gdkintl.h: Add this.
* gtk/gtkmain.c: Add gtk_parse_args() that initializes
GTK+ without opening a display.
* gtk/gtkmain.c: Set things up so if a module
exports gtk_module_init() and gtk_module_display_init(),
then we treat it as multihead aware, otherwise,
we only initialize it after the default display is set.
Thu Jun 20 15:53:21 2002 Owen Taylor <otaylor@redhat.com> Thu Jun 20 15:53:21 2002 Owen Taylor <otaylor@redhat.com>
Patch from Erwann Chenede. Patch from Erwann Chenede.
......
Thu Jun 20 16:49:00 2002 Owen Taylor <otaylor@redhat.com>
* gdk/gdkdisplaymanager.[ch] gdk/gdk.[ch] gdk/gdkdisplay.c
gdk/gdkinternals.h gdk/x11/gdkdisplay-x11.c
gdk/win32/gdkdisplay-win32.c: Add a singleton object that
we can use to get notification when displays
appear / disappear or the default display changes.
gdk_set_default_display() => gdk_display_manager_set_default_display()
gdk_list_displays() => gdk_display_manager_list_displays().
(#85696)
* gdk/Makefile.am gdk/gdkmarshalers.list: Add marshaler
generation.
* gdk/gdkintl.h: Add this.
* gtk/gtkmain.c: Add gtk_parse_args() that initializes
GTK+ without opening a display.
* gtk/gtkmain.c: Set things up so if a module
exports gtk_module_init() and gtk_module_display_init(),
then we treat it as multihead aware, otherwise,
we only initialize it after the default display is set.
Thu Jun 20 15:53:21 2002 Owen Taylor <otaylor@redhat.com> Thu Jun 20 15:53:21 2002 Owen Taylor <otaylor@redhat.com>
Patch from Erwann Chenede. Patch from Erwann Chenede.
......
Thu Jun 20 16:49:00 2002 Owen Taylor <otaylor@redhat.com>
* gdk/gdkdisplaymanager.[ch] gdk/gdk.[ch] gdk/gdkdisplay.c
gdk/gdkinternals.h gdk/x11/gdkdisplay-x11.c
gdk/win32/gdkdisplay-win32.c: Add a singleton object that
we can use to get notification when displays
appear / disappear or the default display changes.
gdk_set_default_display() => gdk_display_manager_set_default_display()
gdk_list_displays() => gdk_display_manager_list_displays().
(#85696)
* gdk/Makefile.am gdk/gdkmarshalers.list: Add marshaler
generation.
* gdk/gdkintl.h: Add this.
* gtk/gtkmain.c: Add gtk_parse_args() that initializes
GTK+ without opening a display.
* gtk/gtkmain.c: Set things up so if a module
exports gtk_module_init() and gtk_module_display_init(),
then we treat it as multihead aware, otherwise,
we only initialize it after the default display is set.
Thu Jun 20 15:53:21 2002 Owen Taylor <otaylor@redhat.com> Thu Jun 20 15:53:21 2002 Owen Taylor <otaylor@redhat.com>
Patch from Erwann Chenede. Patch from Erwann Chenede.
......
Thu Jun 20 16:49:00 2002 Owen Taylor <otaylor@redhat.com>
* gdk/gdkdisplaymanager.[ch] gdk/gdk.[ch] gdk/gdkdisplay.c
gdk/gdkinternals.h gdk/x11/gdkdisplay-x11.c
gdk/win32/gdkdisplay-win32.c: Add a singleton object that
we can use to get notification when displays
appear / disappear or the default display changes.
gdk_set_default_display() => gdk_display_manager_set_default_display()
gdk_list_displays() => gdk_display_manager_list_displays().
(#85696)
* gdk/Makefile.am gdk/gdkmarshalers.list: Add marshaler
generation.
* gdk/gdkintl.h: Add this.
* gtk/gtkmain.c: Add gtk_parse_args() that initializes
GTK+ without opening a display.
* gtk/gtkmain.c: Set things up so if a module
exports gtk_module_init() and gtk_module_display_init(),
then we treat it as multihead aware, otherwise,
we only initialize it after the default display is set.
Thu Jun 20 15:53:21 2002 Owen Taylor <otaylor@redhat.com> Thu Jun 20 15:53:21 2002 Owen Taylor <otaylor@redhat.com>
Patch from Erwann Chenede. Patch from Erwann Chenede.
......
Thu Jun 20 16:49:00 2002 Owen Taylor <otaylor@redhat.com>
* gdk/gdkdisplaymanager.[ch] gdk/gdk.[ch] gdk/gdkdisplay.c
gdk/gdkinternals.h gdk/x11/gdkdisplay-x11.c
gdk/win32/gdkdisplay-win32.c: Add a singleton object that
we can use to get notification when displays
appear / disappear or the default display changes.
gdk_set_default_display() => gdk_display_manager_set_default_display()
gdk_list_displays() => gdk_display_manager_list_displays().
(#85696)
* gdk/Makefile.am gdk/gdkmarshalers.list: Add marshaler
generation.
* gdk/gdkintl.h: Add this.
* gtk/gtkmain.c: Add gtk_parse_args() that initializes
GTK+ without opening a display.
* gtk/gtkmain.c: Set things up so if a module
exports gtk_module_init() and gtk_module_display_init(),
then we treat it as multihead aware, otherwise,
we only initialize it after the default display is set.
Thu Jun 20 15:53:21 2002 Owen Taylor <otaylor@redhat.com> Thu Jun 20 15:53:21 2002 Owen Taylor <otaylor@redhat.com>
Patch from Erwann Chenede. Patch from Erwann Chenede.
......
...@@ -2830,6 +2830,15 @@ Creates a border around the arrows of a #GtkSpinButton. The type of border is de ...@@ -2830,6 +2830,15 @@ Creates a border around the arrows of a #GtkSpinButton. The type of border is de
@Returns: @Returns:
<!-- ##### FUNCTION gtk_style_get_font_for_display ##### -->
<para>
</para>
@display:
@style:
@Returns:
<!-- ##### FUNCTION gtk_text_buffer_paste_primary ##### --> <!-- ##### FUNCTION gtk_text_buffer_paste_primary ##### -->
<para> <para>
......
...@@ -135,8 +135,8 @@ Creates a new file selection dialog box. By default it will contain a #GtkCList ...@@ -135,8 +135,8 @@ Creates a new file selection dialog box. By default it will contain a #GtkCList
<para> <para>
</para> </para>
@filesel: @filesel:
@filename: @filename:
<!-- ##### FUNCTION gtk_file_selection_get_filename ##### --> <!-- ##### FUNCTION gtk_file_selection_get_filename ##### -->
......
...@@ -106,27 +106,15 @@ functions such as g_signal_connect(). ...@@ -106,27 +106,15 @@ functions such as g_signal_connect().
<!-- ##### FUNCTION gtk_init ##### --> <!-- ##### FUNCTION gtk_init ##### -->
<para> <para>
Call this function before using any other GTK+ functions in your GUI
applications. It will initialize everything needed to operate the toolkit and
parses some standard command line options. <parameter>argc</parameter> and
<parameter>argv</parameter> are adjusted accordingly so your own code will
never see those standard arguments.
</para> </para>
<note> <note>
<para> <para>
This function will terminate your program if it was unable to initialize
the GUI for some reason. If you want your program to fall back to a
textual interface you want to call gtk_init_check() instead.
</para> </para>
</note> </note>
@argc: Address of the <parameter>argc</parameter> parameter of your @argc:
<function>main</function> function. Changed if any arguments were @argv:
handled.
@argv: Address of the <parameter>argv</parameter> parameter of
<function>main()</function>. Any parameters understood by gtk_init()
are stripped before return.
<!-- ##### FUNCTION gtk_init_check ##### --> <!-- ##### FUNCTION gtk_init_check ##### -->
...@@ -144,8 +132,7 @@ with the user - for example a curses or command line interface. ...@@ -144,8 +132,7 @@ with the user - for example a curses or command line interface.
<function>main()</function> function. <function>main()</function> function.
@argv: A reference to the <parameter>argv</parameter> of the @argv: A reference to the <parameter>argv</parameter> of the
<function>main()</function> function. <function>main()</function> function.
@Returns: %TRUE if the GUI has been successfully initialized, @Returns:
%FALSE otherwise.
<!-- ##### FUNCTION gtk_exit ##### --> <!-- ##### FUNCTION gtk_exit ##### -->
......
...@@ -179,16 +179,6 @@ Returns whether the style is attached to a window. ...@@ -179,16 +179,6 @@ Returns whether the style is attached to a window.
@Returns: @Returns:
<!-- ##### FUNCTION gtk_style_get_font_for_display ##### -->
<para>
</para>
@display:
@style:
@Returns:
<!-- ##### FUNCTION gtk_style_set_font ##### --> <!-- ##### FUNCTION gtk_style_set_font ##### -->
<para> <para>
......
...@@ -6,6 +6,7 @@ DIST_SUBDIRS=linux-fb win32 x11 ...@@ -6,6 +6,7 @@ DIST_SUBDIRS=linux-fb win32 x11
EXTRA_DIST = \ EXTRA_DIST = \
gdkconfig.h.win32 \ gdkconfig.h.win32 \
gdk.def \ gdk.def \
gdkmarshalers.list \
makefile.mingw \ makefile.mingw \
makefile.mingw.in \ makefile.mingw.in \
makeenums.pl \ makeenums.pl \
...@@ -86,32 +87,33 @@ LDFLAGS = @STRIP_BEGIN@ \ ...@@ -86,32 +87,33 @@ LDFLAGS = @STRIP_BEGIN@ \
# #
# Note: files added here may need to be be propagated to gdk_headers in gtk/Makefile.am # Note: files added here may need to be be propagated to gdk_headers in gtk/Makefile.am
# #
gdk_public_h_sources = @STRIP_BEGIN@ \ gdk_public_h_sources = @STRIP_BEGIN@ \
gdk.h \ gdk.h \
gdkcolor.h \ gdkcolor.h \
gdkcursor.h \ gdkcursor.h \
gdkdnd.h \ gdkdnd.h \
gdkdrawable.h \ gdkdrawable.h \
gdkevents.h \ gdkevents.h \
gdkfont.h \ gdkfont.h \
gdkgc.h \ gdkgc.h \
gdkkeysyms.h \ gdkkeysyms.h \
gdki18n.h \ gdki18n.h \
gdkimage.h \ gdkimage.h \
gdkinput.h \ gdkinput.h \
gdkkeys.h \ gdkkeys.h \
gdkpango.h \ gdkdisplaymanager.h \
gdkpixbuf.h \ gdkpango.h \
gdkpixmap.h \ gdkpixbuf.h \
gdkproperty.h \ gdkpixmap.h \
gdkregion.h \ gdkproperty.h \
gdkrgb.h \ gdkregion.h \
gdkselection.h \ gdkrgb.h \
gdktypes.h \ gdkselection.h \
gdkvisual.h \ gdktypes.h \
gdkwindow.h \ gdkvisual.h \
gdkdisplay.h \ gdkwindow.h \
gdkscreen.h \ gdkdisplay.h \
gdkscreen.h \
@STRIP_END@ @STRIP_END@
gdk_headers = @STRIP_BEGIN@ \ gdk_headers = @STRIP_BEGIN@ \
...@@ -133,6 +135,8 @@ gdk_c_sources = @STRIP_BEGIN@ \ ...@@ -133,6 +135,8 @@ gdk_c_sources = @STRIP_BEGIN@ \
gdkkeyuni.c \ gdkkeyuni.c \
gdkimage.c \ gdkimage.c \
gdkinternals.h \ gdkinternals.h \
gdkintl.h \
gdkdisplaymanager.c \
gdkpango.c \ gdkpango.c \
gdkpixbuf-drawable.c \ gdkpixbuf-drawable.c \
gdkpixbuf-render.c \ gdkpixbuf-render.c \
...@@ -157,9 +161,10 @@ gdk_c_sources = @STRIP_BEGIN@ \ ...@@ -157,9 +161,10 @@ gdk_c_sources = @STRIP_BEGIN@ \
gdkincludedir = $(includedir)/gtk-2.0/gdk gdkincludedir = $(includedir)/gtk-2.0/gdk
gdkinclude_HEADERS = $(gdk_headers) gdkinclude_HEADERS = $(gdk_headers)
libgdk_x11_2_0_la_SOURCES = $(gdk_c_sources) gdkenumtypes.c # gdkmarshalers.c is commented out becuase it is currently an empty file
libgdk_linux_fb_2_0_la_SOURCES = $(gdk_c_sources) gdkenumtypes.c libgdk_x11_2_0_la_SOURCES = $(gdk_c_sources) gdkenumtypes.c gdkmarshalers.h # gdkmarshalers.c
libgdk_win32_2_0_la_SOURCES = $(gdk_c_sources) gdkenumtypes.c libgdk_linux_fb_2_0_la_SOURCES = $(gdk_c_sources) gdkenumtypes.c gdkmarshalers.h # gdkmarshalers.c
libgdk_win32_2_0_la_SOURCES = $(gdk_c_sources) gdkenumtypes.c # gdkmarshalers.c
libgdk_x11_2_0_la_LIBADD = x11/libgdk-x11.la libgdk_x11_2_0_la_LIBADD = x11/libgdk-x11.la
libgdk_linux_fb_2_0_la_LIBADD = linux-fb/libgdk-linux-fb.la libgdk_linux_fb_2_0_la_LIBADD = linux-fb/libgdk-linux-fb.la
...@@ -191,10 +196,10 @@ if DISABLE_EXPLICIT_DEPS ...@@ -191,10 +196,10 @@ if DISABLE_EXPLICIT_DEPS
endif endif
#note: not gdkconfig.h #note: not gdkconfig.h
BUILT_SOURCES = stamp-gc-h @REBUILD@ gdkenumtypes.h BUILT_SOURCES = stamp-gc-h
# Generate built header without using automake-1.4 BUILT_SOURCES # Generate built header without using automake-1.4 BUILT_SOURCES
$(libgdk_x11_2_0_la_OBJECTS) $(libgdk_linux_fb_2_0_la_OBJECTS) $(libgdk_win32_2_0_la_OBJECTS): gdkenumtypes.h $(libgdk_x11_2_0_la_OBJECTS) $(libgdk_linux_fb_2_0_la_OBJECTS) $(libgdk_win32_2_0_la_OBJECTS): gdkenumtypes.h gdkmarshalers.h
$(srcdir)/gdkenumtypes.h: stamp-gdkenumtypes.h $(srcdir)/gdkenumtypes.h: stamp-gdkenumtypes.h
@true @true
...@@ -211,7 +216,7 @@ stamp-gdkenumtypes.h: @REBUILD@ $(gdk_public_h_sources) Makefile ...@@ -211,7 +216,7 @@ stamp-gdkenumtypes.h: @REBUILD@ $(gdk_public_h_sources) Makefile
$(srcdir)/gdkenumtypes.c: @REBUILD@ $(gdk_public_h_sources) Makefile $(srcdir)/gdkenumtypes.c: @REBUILD@ $(gdk_public_h_sources) Makefile
( cd $(srcdir) && glib-mkenums \ ( cd $(srcdir) && glib-mkenums \
--fhead "#define GDK_ENABLE_BROKEN\n#include \"gdk.h\"" \ --fhead "#define GDK_ENABLE_BROKEN\n#include \"gdk.h\"" \
--fprod "\n/* enumerations from \"@filename@\" */" \ --fprod "\n/* enumerations from \"@filename@\" */" \
--vhead "GType\n@enum_name@_get_type (void)\n{\n static GType etype = 0;\n if (etype == 0) {\n static const G@Type@Value values[] = {" \ --vhead "GType\n@enum_name@_get_type (void)\n{\n static GType etype = 0;\n if (etype == 0) {\n static const G@Type@Value values[] = {" \
--vprod " { @VALUENAME@, \"@VALUENAME@\", \"@valuenick@\" }," \ --vprod " { @VALUENAME@, \"@VALUENAME@\", \"@valuenick@\" }," \
--vtail " { 0, NULL, NULL }\n };\n etype = g_@type@_register_static (\"@EnumName@\", values);\n }\n return etype;\n}\n" \ --vtail " { 0, NULL, NULL }\n };\n etype = g_@type@_register_static (\"@EnumName@\", values);\n }\n return etype;\n}\n" \
...@@ -219,6 +224,20 @@ $(srcdir)/gdkenumtypes.c: @REBUILD@ $(gdk_public_h_sources) Makefile ...@@ -219,6 +224,20 @@ $(srcdir)/gdkenumtypes.c: @REBUILD@ $(gdk_public_h_sources) Makefile
&& cp xgen-getc $(srcdir)/gdkenumtypes.c \ && cp xgen-getc $(srcdir)/gdkenumtypes.c \
&& rm -f xgen-getc && rm -f xgen-getc
#
# Marshaller generation
#
$(srcdir)/gdkmarshalers.h: @REBUILD@ gdkmarshalers.list
cd $(srcdir) && \
( @GLIB_GENMARSHAL@ --prefix=gdk_marshal gdkmarshalers.list --header > gdkmarshalers.tmp \
&& mv gdkmarshalers.tmp gdkmarshalers.h ) \
|| ( rm -f gdkmarshalers.tmp && exit 1 )
$(srcdir)/gdkmarshalers.c: @REBUILD@ gdkmarshalers.list
cd $(srcdir) && \
$( @GLIB_GENMARSHAL@ --prefix=gdk_marshal gdkmarshalers.list --body > gdkmarshalers.tmp \
&& mv gdkmarshalers.tmp gdkmarshalers.c ) \
|| ( rm -f gdkmarshalers.tmp && exit 1 )
gdkconfig.h: stamp-gc-h gdkconfig.h: stamp-gc-h
@if test -f gdkconfig.h; then :; \ @if test -f gdkconfig.h; then :; \
else rm -f stamp-gc-h; $(MAKE) stamp-gc-h; fi else rm -f stamp-gc-h; $(MAKE) stamp-gc-h; fi
......
...@@ -287,7 +287,7 @@ gdk_parse_args (int *argc, ...@@ -287,7 +287,7 @@ gdk_parse_args (int *argc,
gint i; gint i;
if (gdk_initialized) if (gdk_initialized)
return TRUE; return;
gdk_initialized = TRUE; gdk_initialized = TRUE;
...@@ -399,7 +399,8 @@ gdk_init_check (int *argc, ...@@ -399,7 +399,8 @@ gdk_init_check (int *argc,
if (display) if (display)
{ {
gdk_set_default_display (display); gdk_display_manager_set_default_display (gdk_display_manager_get (),
display);
return TRUE; return TRUE;
} }
else else
......
...@@ -39,6 +39,7 @@ ...@@ -39,6 +39,7 @@
#include <gdk/gdkimage.h> #include <gdk/gdkimage.h>
#include <gdk/gdkinput.h> #include <gdk/gdkinput.h>
#include <gdk/gdkkeys.h> #include <gdk/gdkkeys.h>
#include <gdk/gdkdisplaymanager.h>
#include <gdk/gdkpango.h> #include <gdk/gdkpango.h>
#include <gdk/gdkpixbuf.h> #include <gdk/gdkpixbuf.h>
#include <gdk/gdkpixmap.h> #include <gdk/gdkpixmap.h>
......
...@@ -31,8 +31,6 @@ static void gdk_display_class_init (GdkDisplayClass *class); ...@@ -31,8 +31,6 @@ static void gdk_display_class_init (GdkDisplayClass *class);
static void gdk_display_init (GdkDisplay *display); static void gdk_display_init (GdkDisplay *display);
static void gdk_display_finalize (GObject *object); static void gdk_display_finalize (GObject *object);
static GdkDisplay *default_display = NULL;
static GObjectClass *parent_class; static GObjectClass *parent_class;
GType GType
...@@ -90,8 +88,9 @@ gdk_display_finalize (GObject *object) ...@@ -90,8 +88,9 @@ gdk_display_finalize (GObject *object)
_gdk_displays = g_slist_remove (_gdk_displays, display); _gdk_displays = g_slist_remove (_gdk_displays, display);
if (default_display == display) if (gdk_get_default_display() == display)
default_display = NULL; gdk_display_manager_set_default_display (gdk_display_manager_get(),
NULL);
parent_class->finalize (object); parent_class->finalize (object);
} }
...@@ -109,62 +108,6 @@ gdk_display_close (GdkDisplay *display) ...@@ -109,62 +108,6 @@ gdk_display_close (GdkDisplay *display)
g_object_unref (G_OBJECT (display)); g_object_unref (G_OBJECT (display));
} }
/**
* gdk_set_default_display:
* @display: a #GdkDisplay
*
* Sets @display as the default display.
**/
void
gdk_set_default_display (GdkDisplay *display)
{
default_display = display;
_gdk_windowing_set_default_display (display);
}
/**
* gdk_get_default_display:
*
* Gets the default #GdkDisplay.
*
* Returns: a #GdkDisplay, or %NULL if there is no default
* display.
*/
GdkDisplay *
gdk_get_default_display (void)
{
return default_display;
}
/**
* gdk_get_default_screen:
*
* Gets the default screen for the default display. (See
* gdk_get_default_display ()).
*
* Returns: a #GdkScreen.
*/
GdkScreen *
gdk_get_default_screen (void)
{
return gdk_display_get_default_screen (gdk_get_default_display ());
}
/**
* gdk_list_displays:
*
* List all currently open displays.
*
* Return value: a newly allocated #GSList of #GdkDisplay objects.
* Free this list with g_slist_free() when you are done with it.
**/
GSList *
gdk_list_displays (void)
{
return g_slist_copy (_gdk_displays);
}
/** /**
* gdk_display_get_event: * gdk_display_get_event:
* @display: a #GdkDisplay * @display: a #GdkDisplay
......
#ifndef __GDKINTL_H__
#define __GDKINTL_H__
#include "config.h"
#ifdef ENABLE_NLS
#include<libintl.h>
#define _(String) dgettext(GETTEXT_PACKAGE,String)
#ifdef gettext_noop
#define N_(String) gettext_noop(String)
#else
#define N_(String) (String)
#endif
#else /* NLS is disabled */
#define _(String) (String)
#define N_(String) (String)
#define textdomain(String) (String)
#define gettext(String) (String)
#define dgettext(Domain,String) (String)
#define dcgettext(Domain,String,Type) (String)
#define bindtextdomain(Domain,Directory) (Domain)
#endif
#endif
...@@ -51,6 +51,9 @@ gdk_open_display (const gchar *display_name) ...@@ -51,6 +51,9 @@ gdk_open_display (const gchar *display_name)
_gdk_input_init (); _gdk_input_init ();
_gdk_dnd_init (); _gdk_dnd_init ();
g_signal_emit_by_name (gdk_display_manager_get (),
"display_opened", _gdk_display);