summaryrefslogtreecommitdiffstats
path: root/perl-install
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>2000-02-21 19:22:12 +0000
committerPascal Rigaux <pixel@mandriva.com>2000-02-21 19:22:12 +0000
commit8abe7a7e8c29a95d8229577b5ff0afaa74589fcc (patch)
tree36deb9889d4642b0078b687dfa4ad1a234ffc644 /perl-install
parent1a6ceb9a7e98d4f7b3aa7e398519ca6a89d852e4 (diff)
downloaddrakx-8abe7a7e8c29a95d8229577b5ff0afaa74589fcc.tar
drakx-8abe7a7e8c29a95d8229577b5ff0afaa74589fcc.tar.gz
drakx-8abe7a7e8c29a95d8229577b5ff0afaa74589fcc.tar.bz2
drakx-8abe7a7e8c29a95d8229577b5ff0afaa74589fcc.tar.xz
drakx-8abe7a7e8c29a95d8229577b5ff0afaa74589fcc.zip
no_comment
Diffstat (limited to 'perl-install')
-rw-r--r--perl-install/ChangeLog9
-rw-r--r--perl-install/common.pm4
-rw-r--r--perl-install/help.pm13
-rw-r--r--perl-install/install2.pm2
-rw-r--r--perl-install/install_steps_gtk.pm13
-rw-r--r--perl-install/mouse.pm2
-rw-r--r--perl-install/my_gtk.pm15
7 files changed, 49 insertions, 9 deletions
diff --git a/perl-install/ChangeLog b/perl-install/ChangeLog
index bceb518af..824c6ea5a 100644
--- a/perl-install/ChangeLog
+++ b/perl-install/ChangeLog
@@ -1,5 +1,14 @@
2000-02-21 Pixel <pixel@mandrakesoft.com>
+ * install_steps_gtk.pm (create_big_help): display the help in full
+ screen
+
+ * my_gtk.pm (_create_window): add big help on F1
+
+ * common.pm (add2hash): now returns the first parameter
+
+ * mouse.pm (detect): really defaults to serial mouse
+
* interactive.pm: add ask_many_from_list_with_help and
ask_many_from_list_with_help_ref
diff --git a/perl-install/common.pm b/perl-install/common.pm
index d6b9220c8..9f4716b8c 100644
--- a/perl-install/common.pm
+++ b/perl-install/common.pm
@@ -59,8 +59,8 @@ sub uniq { my %l; @l{@_} = (); keys %l }
sub to_int { $_[0] =~ /(\d*)/; $1 }
sub to_float { $_[0] =~ /(\d*(\.\d*)?)/; $1 }
sub ikeys { my %l = @_; sort { $a <=> $b } keys %l }
-sub add2hash($$) { my ($a, $b) = @_; while (my ($k, $v) = each %{$b || {}}) { $a->{$k} ||= $v } }
-sub add2hash_($$) { my ($a, $b) = @_; while (my ($k, $v) = each %{$b || {}}) { exists $a->{$k} or $a->{$k} = $v } }
+sub add2hash($$) { my ($a, $b) = @_; while (my ($k, $v) = each %{$b || {}}) { $a->{$k} ||= $v } $a }
+sub add2hash_($$) { my ($a, $b) = @_; while (my ($k, $v) = each %{$b || {}}) { exists $a->{$k} or $a->{$k} = $v } $a }
sub member { my $e = shift; foreach (@_) { $e eq $_ and return 1 } 0 }
sub dirname { @_ == 1 or die "usage: dirname <name>\n"; local $_ = shift; s|[^/]*/*\s*$||; s|(.)/*$|$1|; $_ || '.' }
sub basename { @_ == 1 or die "usage: basename <name>\n"; local $_ = shift; s|/*\s*$||; s|.*/||; $_ }
diff --git a/perl-install/help.pm b/perl-install/help.pm
index 2b0037d9e..c61567de4 100644
--- a/perl-install/help.pm
+++ b/perl-install/help.pm
@@ -84,7 +84,18 @@ computer is first turned on.
Because the effects of this process are usually irreversible, partitioning
can be intimidating and stressful to the unexperienced user. DiskDrake
simplifies the process so that it need not be. Consult the documentation
-and take your time before proceeding."),
+and take your time before proceeding.
+
+
+You can reach any option using the keyboard: navigate through the partitions
+using Tab and Up/Down arrows. When a partition is selected, you can use:
+
+- Ctrl-c to create a new partition (when an empty partition is selected)
+
+- Ctrl-d to delete a partition
+
+- Ctrl-m to set the mount point
+"),
formatPartitions =>
__("Any partitions that have been newly defined must be formatted for
diff --git a/perl-install/install2.pm b/perl-install/install2.pm
index 3c7e89b27..e22e02b9d 100644
--- a/perl-install/install2.pm
+++ b/perl-install/install2.pm
@@ -591,6 +591,8 @@ sub main {
#- needed very early for install_steps_gtk
eval { ($o->{mouse}, $o->{wacom}) = mouse::detect() } unless $o->{nomouseprobe} || $o->{mouse};
+
+ print %{$o->{mouse}}, "\n";
$::o = $o = $::auto_install ?
install_steps_auto_install->new($o) :
diff --git a/perl-install/install_steps_gtk.pm b/perl-install/install_steps_gtk.pm
index 557a9cab3..9462477fc 100644
--- a/perl-install/install_steps_gtk.pm
+++ b/perl-install/install_steps_gtk.pm
@@ -639,6 +639,19 @@ widget "*Steps*" style "steps"
}
#------------------------------------------------------------------------------
+sub create_big_help {
+ my $w = my_gtk->new('', grab => 1, force_position => [ $stepswidth, $logoheight ]);
+ $w->{rwindow}->set_usize($logowidth, $height - $logoheight);
+ gtkadd($w->{window},
+ gtkpack_(new Gtk::VBox(0,0),
+ 1, createScrolledWindow(gtktext_insert(new Gtk::Text,
+ formatAlaTeX(translate($help::steps{$::o->{step}})))),
+ 0, gtksignal_connect(new Gtk::Button(_("Ok")), "clicked" => sub { Gtk->main_quit }),
+ ));
+ $w->main;
+}
+
+#------------------------------------------------------------------------------
sub create_help_window {
my ($o) = @_;
diff --git a/perl-install/mouse.pm b/perl-install/mouse.pm
index 0750efe0d..7f0fd78f1 100644
--- a/perl-install/mouse.pm
+++ b/perl-install/mouse.pm
@@ -131,5 +131,5 @@ sub detect() {
#- defaults to generic ttyS0
add2hash(name2mouse("Generic Mouse (serial)"), { device => "ttyS0", unsafe => 1 });
- die "mouseconfig failed";
+#- die "mouseconfig failed";
}
diff --git a/perl-install/my_gtk.pm b/perl-install/my_gtk.pm
index fe940e3d7..e09d700ab 100644
--- a/perl-install/my_gtk.pm
+++ b/perl-install/my_gtk.pm
@@ -321,12 +321,17 @@ sub _create_window($$) {
$w->set_uposition(@{$my_gtk::force_position || $o->{force_position}}) if $my_gtk::force_position || $o->{force_position};
$w->signal_connect("key_press_event" => sub {
- my $d = ${{ 65481 => 'next',
+ my $d = ${{ 65470 => 'help',
+ 65481 => 'next',
65480 => 'previous' }}{$_[1]->{keyval}} or return;
- my $s = $::o->{step};
- do { $s = $::o->{steps}{$s}{$d} } until !$s || $::o->{steps}{$s}{reachable};
- $::setstep && $s and die "setstep $s\n";
- });
+ if ($d eq "help") {
+ install_steps_gtk::create_big_help();
+ } else {
+ my $s = $::o->{step};
+ do { $s = $::o->{steps}{$s}{$d} } until !$s || $::o->{steps}{$s}{reachable};
+ $::setstep && $s and die "setstep $s\n";
+ }
+ }) unless $::isStandalone;
$w->signal_connect(size_allocate => sub {
my ($wi, $he) = @{$_[1]}[2,3];