summaryrefslogtreecommitdiffstats
path: root/move/move.pm
diff options
context:
space:
mode:
authorGuillaume Cottenceau <gc@mandriva.com>2003-11-21 11:22:44 +0000
committerGuillaume Cottenceau <gc@mandriva.com>2003-11-21 11:22:44 +0000
commitf63d102c82f4efe65c38d25b618816dd9813cbbb (patch)
tree4e9e844bd062029d88e48c2a5bd25a894c2611af /move/move.pm
parentdad6e4aade1c73e302b559458c021c29fd08f208 (diff)
downloaddrakx-f63d102c82f4efe65c38d25b618816dd9813cbbb.tar
drakx-f63d102c82f4efe65c38d25b618816dd9813cbbb.tar.gz
drakx-f63d102c82f4efe65c38d25b618816dd9813cbbb.tar.bz2
drakx-f63d102c82f4efe65c38d25b618816dd9813cbbb.tar.xz
drakx-f63d102c82f4efe65c38d25b618816dd9813cbbb.zip
display background image as soon as possible
keep a gdkwindow with the background image so that it stays when wizardwindow is destroyed
Diffstat (limited to 'move/move.pm')
-rw-r--r--move/move.pm26
1 files changed, 16 insertions, 10 deletions
diff --git a/move/move.pm b/move/move.pm
index f21addfb2..f3bc7f747 100644
--- a/move/move.pm
+++ b/move/move.pm
@@ -17,6 +17,7 @@ my ($using_existing_user_config, $using_existing_host_config);
my $key_sysconf = '/home/.sysconf';
my $virtual_key_part;
my $key_mountopts = 'umask=077,uid=501,gid=501,shortname=mixed';
+my $rootwindow; #- holds background image
sub symlinkf_short {
my ($dest, $file) = @_;
@@ -142,13 +143,14 @@ sub init {
}
drakx_stuff:
- $o->{steps}{$_} = { reachable => 1, text => $_ } foreach qw(autoSelectLanguage handleI18NClp verifyKey configMove startMove);
+ $o->{steps}{$_} = { reachable => 1, text => $_ }
+ foreach qw(displayBackground autoSelectLanguage handleI18NClp verifyKey configMove startMove);
$o->{orderedSteps_orig} = $o->{orderedSteps};
$o->{orderedSteps} = [ $using_existing_host_config ?
- qw(handleI18NClp verifyKey startMove)
+ qw(displayBackground handleI18NClp verifyKey startMove)
: $using_existing_user_config ?
- qw(autoSelectLanguage handleI18NClp verifyKey selectMouse selectKeyboard configMove startMove)
- : qw(selectLanguage handleI18NClp acceptLicense verifyKey selectMouse selectKeyboard configMove startMove) ];
+ qw(displayBackground autoSelectLanguage handleI18NClp verifyKey selectMouse selectKeyboard configMove startMove)
+ : qw(displayBackground selectLanguage handleI18NClp acceptLicense verifyKey selectMouse selectKeyboard configMove startMove) ];
$o->{steps}{first} = $o->{orderedSteps}[0];
#- don't use shadow passwords since pwconv overwrites /etc/shadow hence contents will be lost for usb key
@@ -442,17 +444,20 @@ sub install_TrueFS_in_home {
}
}
-sub install2::startMove {
- my $o = $::o;
-
- $::WizardWindow->destroy if $::WizardWindow;
+sub install2::displayBackground {
require ugtk2;
- my $root = ugtk2::gtkroot();
+ $rootwindow = ugtk2::gtkroot();
my $pixbuf = eval { Gtk2::Gdk::Pixbuf->new_from_file("/image/move/BOOT-$::rootwidth-MOVE.jpg") };
$pixbuf ||= Gtk2::Gdk::Pixbuf->new_from_file('/usr/share/mdk/screensaver/3.png');
my ($w, $h) = ($pixbuf->get_width, $pixbuf->get_height);
- $root->draw_pixbuf(Gtk2::Gdk::GC->new($root), $pixbuf, 0, 0, ($::rootwidth - $w) / 2, ($::rootheight - $h)/2, $w, $h, 'none', 0, 0);
+ $rootwindow->draw_pixbuf(Gtk2::Gdk::GC->new($rootwindow), $pixbuf, 0, 0, ($::rootwidth - $w) / 2, ($::rootheight - $h)/2, $w, $h, 'none', 0, 0);
ugtk2::gtkflush();
+}
+
+sub install2::startMove {
+ my $o = $::o;
+
+ $::WizardWindow->destroy if $::WizardWindow;
#- get info from existing fstab. This won't do anything if we already wrote fstab in configMove
fs::get_info_from_fstab($o->{all_hds}, '');
@@ -484,6 +489,7 @@ sub install2::startMove {
if (fork()) {
sleep 1;
+ undef $rootwindow;
log::l("DrakX waves bye-bye");
my (undef, undef, $uid, $gid, undef, undef, undef, $home, $shell) = getpwnam($username);