summaryrefslogtreecommitdiffstats
path: root/perl-install/standalone
diff options
context:
space:
mode:
Diffstat (limited to 'perl-install/standalone')
-rwxr-xr-xperl-install/standalone/drakconnect4
-rwxr-xr-xperl-install/standalone/drakfont24
-rwxr-xr-xperl-install/standalone/drakperm3
-rwxr-xr-xperl-install/standalone/net_monitor6
-rwxr-xr-xperl-install/standalone/service_harddrake7
5 files changed, 29 insertions, 15 deletions
diff --git a/perl-install/standalone/drakconnect b/perl-install/standalone/drakconnect
index 1d34360dd..dc7811200 100755
--- a/perl-install/standalone/drakconnect
+++ b/perl-install/standalone/drakconnect
@@ -186,7 +186,7 @@ $window1->{window}->add(
0, $profile_combo,
0, $button_del,
0, gtksignal_connect(Gtk2::Button->new(N("New profile...")), clicked => sub {
- my $dialog = _create_dialog("New profile...", { small => 1 });
+ my $dialog = _create_dialog(N("New profile..."), { small => 1 });
my $entry_dialog = Gtk2::Entry->new;
gtkpack($dialog->vbox,
Gtk2::Label->new(N("Name of the profile to create (the new profile is created as a copy of the current one) :")),
@@ -263,7 +263,7 @@ $window1->{window}->add(
!$wizard_pid and do { exec("drakconnect") or POSIX::_exit(1) };
sensitive_buttons(0);
} else {
- err_dialog(N("Unable to fork: %s", "$!"));
+ err_dialog(N("Error"), N("Unable to fork: %s", "$!"));
}
}),
),
diff --git a/perl-install/standalone/drakfont b/perl-install/standalone/drakfont
index ca7fe9a9e..3dd3010c6 100755
--- a/perl-install/standalone/drakfont
+++ b/perl-install/standalone/drakfont
@@ -319,10 +319,15 @@ sub convert_fonts {
sub convert_ttf_fonts {
my ($fonts, $o_generate_pfb) = @_;
- convert_fonts($fonts, $o_generate_pfb, "TTF", $ttf2pt1);
+ convert_fonts($fonts, $ttf2pt1, "TTF", $o_generate_pfb);
}
+sub move_fonts {
+ my ($src_dir, $dest_dir, @extensions) = @_;
+ my @fonts = map { s!.*/!!; $_ } map { glob("$src_dir/*.$_") } @extensions;
+ system("cd $src_dir && mv @fonts $dest_dir") if @fonts;
+}
sub put_font_dir() {
-e "/usr/share/ghostscript" or do { $gs = 0; print "ghostscript is not installed on your system...\n" };
@@ -334,8 +339,11 @@ sub put_font_dir() {
}
interactive_progress($pbar1, 0.01, N("done"));
interactive_progress($pbar2, 0.10, N("True Type fonts installation"));
- glob("$drakfont_dir/tmp/tmp/*.TTF")
- and system('cd ' . $drakfont_dir . '/tmp/tmp ; for foo in *.TTF; do mv $foo `basename $foo .TTF`.ttf; done');
+ foreach my $font (glob("$drakfont_dir/tmp/tmp/*.TTF")) {
+ my $newfont = $font;
+ $newfont =~ s/\.TTF$/.ttf/;
+ rename($font, $newfont);
+ }
system('cd ' . $drakfont_dir . '/tmp/tmp && cp *.ttf ../../ttf; chmod 644 ../../ttf/*ttf');
interactive_progress($pbar2, 0.20, N("please wait during ttmkfdir..."));
@@ -346,16 +354,16 @@ sub put_font_dir() {
if ($gs) {
convert_ttf_fonts([ glob("$drakfont_dir/tmp/tmp/*.ttf") ], 1);
- system(join('', "cd $drakfont_dir/tmp/tmp && mv *.gsf *.pfb *.pfm", if_($so, "*.afm"), " ../Type1"));
+ move_fonts("$drakfont_dir/tmp/tmp", "../Type1", qw(afm gsf pfb pfm));
system("cd $drakfont_dir/tmp/Type1 && $type1inst");
interactive_progress($pbar2, 0.1, N("type1inst building"));
if ($so) {
-e "$drakfont_dir/tmp/Type1/Fontmap"
and system("cd $drakfont_dir/tmp/Type1 && cat Fontmap >> `rpm -ql ghostscript | grep Fontmap.GS` ");
- system("cd $drakfont_dir/tmp/Type1 && mv *.pfm *.gsf *.afm *.pfb ../../Type1 ");
+ move_fonts("$drakfont_dir/tmp/Type1", "../../Type1", qw(afm gsf pfb pfm));
} else {
system("cd $drakfont_dir/tmp/Type1 && cat Fontmap >> `rpm -ql ghostscript | grep Fontmap.GS` ");
- system("cd $drakfont_dir/tmp/Type1 && mv *.pfm *.afm *.gsf *.pfb ../../Type1 ");
+ move_fonts("$drakfont_dir/tmp/Type1", "../../Type1", qw(afm gsf pfb pfm));
}
my $type1dir = $drakfont_dir . "/Type1";
system("cd $type1dir && $fccache && $type1inst");
@@ -364,8 +372,8 @@ sub put_font_dir() {
} elsif ($so) {
convert_ttf_fonts([ glob("$drakfont_dir/tmp/tmp/*.ttf") ]);
convert_fonts([ glob("$drakfont_dir/tmp/tmp/*.pfm") ], $pfm2afm, "PFM");
- system("cd $drakfont_dir/tmp/tmp && mv *.afm ../Type1");
- system("cd $drakfont_dir/tmp/Type1 && mv *.afm ../../Type1 ");
+ move_fonts("$drakfont_dir/tmp/tmp", "../Type1", qw(afm));
+ move_fonts("$drakfont_dir/tmp/Type1", "../../Type1", qw(afm));
my $type1dir = $drakfont_dir . "/Type1";
system("cd $type1dir && $fccache && $type1inst");
interactive_progress($pbar2, 0.14, N("type1inst building"));
diff --git a/perl-install/standalone/drakperm b/perl-install/standalone/drakperm
index 7a19992d3..559462c99 100755
--- a/perl-install/standalone/drakperm
+++ b/perl-install/standalone/drakperm
@@ -283,6 +283,7 @@ sub row_setting_dialog {
$suid->set_active($s_right{read});
$file->set_text($model->get($iter, 1)) if $iter;
+ $ok->set_sensitive(!$model->get($iter, 0)) if $iter;
my $users = Gtk2::OptionMenu->new;
$users->set_popdown_strings(&get_user_or_group('users'));
@@ -382,7 +383,7 @@ sub row_setting_dialog {
);
$vbox;
- } keys %rights),
+ } qw(user group other)),
gtkpack(Gtk2::VBox->new(0,5),
Gtk2::Label->new(' '),
$suid,
diff --git a/perl-install/standalone/net_monitor b/perl-install/standalone/net_monitor
index 68ca5a9a2..40310fa1a 100755
--- a/perl-install/standalone/net_monitor
+++ b/perl-install/standalone/net_monitor
@@ -132,7 +132,8 @@ gtkadd($window1->{window},
$window1->{rwindow}->show_all;
$window1->{rwindow}->realize;
$combo1->entry->signal_connect(changed => sub {
- network::netconnect::set_profile($netcnx, $combo1->entry->get_text);
+ $netcnx->{PROFILE} = $combo1->entry->get_text;
+ network::netconnect::set_profile($netcnx);
network::netconnect::load_conf($netcnx, $netc, $intf);
network::netconnect::read_net_conf('', $netcnx, $netc);
});
@@ -561,5 +562,6 @@ sub draw_monitor {
sub test_connected {
- $::testing || network::tools::test_connected;
+ my ($arg) = @_;
+ $::testing || network::tools::test_connected($arg);
}
diff --git a/perl-install/standalone/service_harddrake b/perl-install/standalone/service_harddrake
index f59c3c668..f8028b762 100755
--- a/perl-install/standalone/service_harddrake
+++ b/perl-install/standalone/service_harddrake
@@ -66,6 +66,11 @@ foreach (@harddrake::data::tree) {
} else {
@configurator_pool = $configurator;
}
+ # automatic sound slots configuration
+ if ($Ident eq "AUDIO") {
+ harddrake::sound::configure_sound_slots();
+ }
+
next unless -x first(split /\s+/, $configurator_pool[0]);
foreach my $configurator (@configurator_pool) {
my ($pid, $no);
@@ -94,7 +99,5 @@ foreach (@harddrake::data::tree) {
log::explanations("created file $last_boot_config");
Storable::store(\%config, $last_boot_config);
-# automatic sound slots configuration
-harddrake::sound::configure_sound_slots();
$in->exit(0) if $in;