From 2aa86cb598d7fd827b4bcb23ef059b97d6d22501 Mon Sep 17 00:00:00 2001 From: damien Date: Fri, 22 Sep 2000 11:49:09 +0000 Subject: stc --- perl-install/ChangeLog | 8 ++++++++ perl-install/network.pm | 22 ++++++++++++++++------ 2 files changed, 24 insertions(+), 6 deletions(-) (limited to 'perl-install') diff --git a/perl-install/ChangeLog b/perl-install/ChangeLog index 9f26dbe8f..1635d5472 100644 --- a/perl-install/ChangeLog +++ b/perl-install/ChangeLog @@ -1,3 +1,11 @@ +2000-09-22 dam's + + * netconnect.pm (get_net_device): added get_net_device to know + which interface has been used to configure the internet connection. + + * network.pm (configureNetworkIntf): changed label to warn people + about already configured eth cards. + 2000-09-22 François Pons * install_gtk.pm: added Desktop themes. diff --git a/perl-install/network.pm b/perl-install/network.pm index c7b88e420..b28482edc 100644 --- a/perl-install/network.pm +++ b/perl-install/network.pm @@ -253,7 +253,7 @@ sub configureNetwork { my $intf2 = findIntf($intf ||= {}, $_); add2hash($intf2, $last); add2hash($intf2, { NETMASK => '255.255.255.0' }); - configureNetworkIntf($in, $intf2) or last; + configureNetworkIntf($in, $intf2, $netc->{net_device}, 0) or last; $netc ||= {}; $last = $intf2; @@ -279,17 +279,27 @@ such as ``mybox.mylab.myco.com''."), sub configureNetworkIntf { - my ($in, $intf) = @_; + my ($in, $intf, $net_device, $skip) = @_; + my $text; + if ($net_device eq $intf->{DEVICE}) { + $skip and return 1; + $text = _("WARNING : This device has been previously configured to connect to the Internet. +Simply press Cancel to keep this device configured. +Modifying the fields below and clicking on OK will override this configuration."); + } + else { + $text = _("Please enter the IP configuration for this machine. +Each item should be entered as an IP address in dotted-decimal +notation (for example, 1.2.3.4)."); + } my $pump = $intf->{BOOTPROTO} =~ /^(dhcp|bootp)$/; delete $intf->{NETWORK}; delete $intf->{BROADCAST}; my @fields = qw(IPADDR NETMASK); $::isStandalone or $in->set_help('configureNetworkIP'); $in->ask_from_entries_ref(_("Configuring network device %s", $intf->{DEVICE}), -($::isStandalone ? '' : _("Configuring network device %s", $intf->{DEVICE}) . "\n\n") . -_("Please enter the IP configuration for this machine. -Each item should be entered as an IP address in dotted-decimal -notation (for example, 1.2.3.4)."), + ($::isStandalone ? '' : _("Configuring network device %s", $intf->{DEVICE}) . "\n\n") . + $text, [ _("IP address"), _("Netmask"), _("Automatic IP") ], [ \$intf->{IPADDR}, \$intf->{NETMASK}, { val => \$pump, type => "bool", text => _("(bootp/dhcp)") } ], complete => sub { -- cgit v1.2.1