summaryrefslogtreecommitdiffstats
path: root/perl-install/install_steps_auto_install.pm
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>2000-06-24 10:46:30 +0000
committerPascal Rigaux <pixel@mandriva.com>2000-06-24 10:46:30 +0000
commit1dfc06422978cbae04f06f13165d2aea37fac8e1 (patch)
tree6272b1add0068da59fe9f58ba818e617dd7a0a29 /perl-install/install_steps_auto_install.pm
parent2a0bbee296669686a3332e6595bc1021757249b0 (diff)
downloaddrakx-1dfc06422978cbae04f06f13165d2aea37fac8e1.tar
drakx-1dfc06422978cbae04f06f13165d2aea37fac8e1.tar.gz
drakx-1dfc06422978cbae04f06f13165d2aea37fac8e1.tar.bz2
drakx-1dfc06422978cbae04f06f13165d2aea37fac8e1.tar.xz
drakx-1dfc06422978cbae04f06f13165d2aea37fac8e1.zip
no_comment
Diffstat (limited to 'perl-install/install_steps_auto_install.pm')
-rw-r--r--perl-install/install_steps_auto_install.pm30
1 files changed, 25 insertions, 5 deletions
diff --git a/perl-install/install_steps_auto_install.pm b/perl-install/install_steps_auto_install.pm
index 333215dab..83c19c007 100644
--- a/perl-install/install_steps_auto_install.pm
+++ b/perl-install/install_steps_auto_install.pm
@@ -13,6 +13,21 @@ use common qw(:common);
use install_steps;
use log;
+my $graphical = 1;
+
+sub new {
+ my ($type, $o) = @_;
+
+ if ($graphical) {
+ require install_steps_gtk;
+ undef *enteringStep; *enteringStep = *install_steps_gtk::enteringStep;
+ undef *installPackages; *installPackages = *install_steps_gtk::installPackages;
+ goto &install_steps_gtk::new;
+ } else {
+ (bless {}, ref $type || $type)->SUPER::new($o);
+ }
+}
+
sub enteringStep($$$) {
my ($o, $step) = @_;
print _("Entering step `%s'\n", translate($o->{steps}{$step}{text}));
@@ -33,13 +48,18 @@ sub errorInStep {
}
sub exitInstall {
- my ($o) = @_;
+ my ($o, $alldone) = @_;
return if $o->{autoExitInstall};
- print "\a";
- print "Auto installation complete\n";
- print "Press <Enter> to reboot\n";
- <STDIN>;
+ if ($graphical) {
+ my $O = bless $o, "install_steps_gtk";
+ $O->exitInstall($alldone);
+ } else {
+ print "\a";
+ print "Auto installation complete\n";
+ print "Press <Enter> to reboot\n";
+ <STDIN>;
+ }
}
1;