summaryrefslogtreecommitdiffstats
path: root/perl-install/standalone/keyboarddrake
diff options
context:
space:
mode:
authordamien <damien@mandriva.com>2001-02-08 10:11:37 +0000
committerdamien <damien@mandriva.com>2001-02-08 10:11:37 +0000
commitaca4c306be5e8d757fbac86c9de3f6f3862cc471 (patch)
tree3f63882e84775916b5aea7a54a2ad142dfc567d8 /perl-install/standalone/keyboarddrake
parent842c74ed3d9e2396cf1fb85f14e34258bbd13cd6 (diff)
downloaddrakx-aca4c306be5e8d757fbac86c9de3f6f3862cc471.tar
drakx-aca4c306be5e8d757fbac86c9de3f6f3862cc471.tar.gz
drakx-aca4c306be5e8d757fbac86c9de3f6f3862cc471.tar.bz2
drakx-aca4c306be5e8d757fbac86c9de3f6f3862cc471.tar.xz
drakx-aca4c306be5e8d757fbac86c9de3f6f3862cc471.zip
implemented or updated embedded mode
Diffstat (limited to 'perl-install/standalone/keyboarddrake')
-rwxr-xr-xperl-install/standalone/keyboarddrake12
1 files changed, 9 insertions, 3 deletions
diff --git a/perl-install/standalone/keyboarddrake b/perl-install/standalone/keyboarddrake
index 01f99809d..da23cdc28 100755
--- a/perl-install/standalone/keyboarddrake
+++ b/perl-install/standalone/keyboarddrake
@@ -10,16 +10,20 @@ use Xconfigurator_consts;
use common qw(:system);
use c;
+$::isEmbedded = ($::XID, $::CCPID) = "@ARGV" =~ /--embedded (\w+) (\w+)/;
local $_ = join '', @ARGV;
/-h/ and die _("usage: keyboarddrake [--expert] [keyboard]\n");
$::expert = /-expert/;
-my ($keyboard) = grep { !/^-/ } @ARGV;
-
+print "[$::expert]\n";
+my $keyboard='';
+if ($::expert) { ($keyboard) = grep { !/^-/ } @ARGV;}
+print "[$keyboard]\n";
my $in = interactive->vnew('su');
+begin:
$keyboard ||= $in->ask_from_listf_(_("Keyboard"),
_("Please, choose your keyboard layout."),
\&keyboard::keyboard2text,
@@ -57,4 +61,6 @@ substInFile {
keyboard::write('', $keyboard, $isNotDelete);
-$in->exit(0);
+$::isEmbedded ? kill(USR1, $::CCPID) : $in->exit(0);
+$keyboard='';
+goto begin;