From edeb25ec8b0ddaa99b6bc799ea38fa5c156a6ced Mon Sep 17 00:00:00 2001 From: Pascal Rigaux Date: Tue, 21 Jan 2003 13:37:21 +0000 Subject: (create_okcancel): rework to prepare next move, "Next" and "Previous" on the left, and @other buttons on the right (create_hbox): do handle the layout parameter --- perl-install/ugtk2.pm | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/perl-install/ugtk2.pm b/perl-install/ugtk2.pm index 7f8ad2be0..adefba9b8 100644 --- a/perl-install/ugtk2.pm +++ b/perl-install/ugtk2.pm @@ -384,7 +384,7 @@ sub destroy_window { 0; } -sub create_hbox { gtkset_layout(gtkset_border_width(Gtk2::HButtonBox->new, 3), 'spread') } +sub create_hbox { gtkset_layout(gtkset_border_width(Gtk2::HButtonBox->new, 3), $_[0] || 'spread') } sub create_vbox { gtkset_layout(Gtk2::VButtonBox->new, $_[0] || 'spread') } sub create_factory_menu_ { @@ -444,10 +444,10 @@ sub create_okcancel { gtksignal_connect($w->{wizcancel} = Gtk2::Button->new(N("Cancel")), clicked => sub { die 'wizcancel' }) if $wizard_buttons && !$::isInstall; my @l = grep { $_ } $wizard_buttons ? (if_(!$::isInstall, $w->{wizcancel}), if_(!$::Wizard_no_previous, $b2), $b1) : ($b1, $b2); - unshift @l, map { gtksignal_connect(Gtk2::Button->new($_->[0]), clicked => $_->[1]) } @other; + my @l2 = map { gtksignal_connect(Gtk2::Button->new($_->[0]), clicked => $_->[1]) } @other; - $_->can_default($wizard_buttons) foreach @l; - gtkadd(create_hbox($spread), @l); + $_->can_default($wizard_buttons) foreach @l2, @l; + gtkadd(create_hbox($spread), @l2, @l); } sub _setup_paned { -- cgit v1.2.1