summaryrefslogtreecommitdiffstats
path: root/tools/XFdrake
diff options
context:
space:
mode:
Diffstat (limited to 'tools/XFdrake')
-rwxr-xr-xtools/XFdrake28
1 files changed, 6 insertions, 22 deletions
diff --git a/tools/XFdrake b/tools/XFdrake
index a1932db..19988f3 100755
--- a/tools/XFdrake
+++ b/tools/XFdrake
@@ -1,7 +1,7 @@
#!/usr/bin/perl
# XFdrake
-# Copyright (C) 1999-2005 Mandriva (pixel@mandrakesoft.com)
+# Copyright (C) 1999-2006 Mandriva (pixel@mandrakesoft.com)
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -19,6 +19,9 @@
use lib qw(/usr/lib/libDrakX);
+# i18n: IMPORTANT: to get correct namespace (drakx-kbd-mouse-x11 instead of libDrakX)
+BEGIN { unshift @::textdomains, 'drakx-kbd-mouse-x11' }
+
use standalone; #- warning, standalone must be loaded very first, for 'explanations'
use Xconfig::main;
@@ -54,7 +57,7 @@ $configure_this ||= $::auto ? 'auto_install' : 'everything';
};
if (!$::auto) {
if ($rc eq 'need_restart') {
- ask_for_X_restart($in);
+ any::ask_for_X_restart($in);
} elsif ($rc eq 'need_reboot') {
$in->ask_warn('', N("You need to reboot for changes to take effect"));
}
@@ -72,26 +75,7 @@ sub check_XFree {
symlinkf("$_.standard", $f) if -l $f && -e "$f.standard";
}
- my $f = "/usr/X11R6/lib/X11/rgb.txt"; #- this one is on all platform
- -e $f or $in->do_pkgs->install('xorg-x11', 'xorg-x11-75dpi-fonts');
- -e $f or die "install Xorg first!\n";
+ $in->do_pkgs->ensure_are_installed(['task-x11']) or $in->exit;
system("mount /proc 2>/dev/null"); # ensure /proc is mounted for pci probing
}
-
-sub ask_for_X_restart {
- my ($in) = @_;
-
- $::isStandalone && $in->isa('interactive::gtk') or return;
-
- my ($wm, $pid) = any::running_window_manager();
-
- if (!$wm) {
- $in->ask_warn('', N("Please log out and then use Ctrl-Alt-BackSpace"));
- return;
- }
-
- $in->ask_okcancel('', N("You need to log out and back in again for changes to take effect"), 1) or return;
-
- any::ask_window_manager_to_logout_then_do($wm, $pid, 'killall X');
-}