From 0f1a363af19d12e8bc38ec02f5a99ecbae1eadc1 Mon Sep 17 00:00:00 2001 From: Thierry Vignaud Date: Tue, 28 Jan 2003 15:39:51 +0000 Subject: cleaning the utf8 support stuff: - consolidate check_for_xserver() to check for x11 access - introduce prepare_gtk2() to do what gtk+2 needs, so that tools that're not part of drakxtools (aka: rpmdrake, mcc, ...) can just do : unshift @::textdomains, 'drakconf'; prepare_gtk2(); --- perl-install/ugtk.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'perl-install/ugtk.pm') diff --git a/perl-install/ugtk.pm b/perl-install/ugtk.pm index 28c2848ec..d69dcfd1f 100644 --- a/perl-install/ugtk.pm +++ b/perl-install/ugtk.pm @@ -16,7 +16,7 @@ $EXPORT_TAGS{all} = [ map { @$_ } values %EXPORT_TAGS ]; use Gtk; if (!$::no_ugtk_init) { - !$ENV{DISPLAY} || system('/usr/X11R6/bin/xtest') and die "Cannot be run in console mode.\n"; + !check_for_xserver() and die "Cannot be run in console mode.\n"; Gtk->init; eval { require Gtk::Gdk::Pixbuf; Gtk::Gdk::Pixbuf->init }; $use_pixbuf = $@ ? 0 : 1; -- cgit v1.2.1