summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Odin <odin@mandriva.org>2001-06-12 12:45:57 +0000
committerDavid Odin <odin@mandriva.org>2001-06-12 12:45:57 +0000
commit2c9c6a8f7e6e36f42671d047e27c7f1de1be061b (patch)
treea452417462590e26f4ebe571e0ed4500c1935159
parent0405309dde44eb8c66d4f4612860a93e267e6c84 (diff)
downloaddrakx-backup-do-not-use-2c9c6a8f7e6e36f42671d047e27c7f1de1be061b.tar
drakx-backup-do-not-use-2c9c6a8f7e6e36f42671d047e27c7f1de1be061b.tar.gz
drakx-backup-do-not-use-2c9c6a8f7e6e36f42671d047e27c7f1de1be061b.tar.bz2
drakx-backup-do-not-use-2c9c6a8f7e6e36f42671d047e27c7f1de1be061b.tar.xz
drakx-backup-do-not-use-2c9c6a8f7e6e36f42671d047e27c7f1de1be061b.zip
ui for drakproxy almost done
-rw-r--r--perl-install/proxy.pm39
-rwxr-xr-xperl-install/standalone/drakproxy7
2 files changed, 41 insertions, 5 deletions
diff --git a/perl-install/proxy.pm b/perl-install/proxy.pm
index f19ed4d82..8779d48c8 100644
--- a/perl-install/proxy.pm
+++ b/perl-install/proxy.pm
@@ -10,12 +10,45 @@ use c;
sub main {
my ($prefix, $in, $install) = @_;
begin:
+ $::isWizard = 1;
$::Wizard_no_previous = 1;
$in->ask_okcancel(_("Proxy configuration"), _("blabla proxy"), 1) or quit_global($in, 0);
- my $url;
- my $e = $in->ask_from_entry($url, _("foo"), _("url"));
- print "$url / $e \n";
+
+ # http proxy
+ my $http_proxy = {};
+ $http_proxy->{url} = "http://bla.foo.fr/";
+ $in->ask_from_entries_refH(_("Proxy configuration"),
+ _("Please fill in the http proxy informations"),
+ [
+ { label => _("URL"), val => \$http_proxy->{url} },
+ { label => _("port"), val => \$http_proxy->{port} }
+ ]
+ );
undef $::Wizard_no_previous;
+ # ftp proxy
+ my $ftp_proxy = {};
+ $ftp_proxy->{url} = "http://bla.foo.fr/";
+ $in->ask_from_entries_refH(_("Proxy configuration"),
+ _("Please fill in the ftp proxy informations"),
+ [
+ { label => _("URL"), val => \$ftp_proxy->{url} },
+ { label => _("port"), val => \$ftp_proxy->{port} }
+ ]
+ );
+ # proxy login/passwd
+ my $proxy_login = {};
+ $in->ask_from_entries_refH(_("Proxy configuration"),
+ _("Please enter proxy login and password, if any"),
+ [
+ { label => _("login"), val => \$proxy_login->{login} },
+ { label => _("password"), val => \$proxy_login->{passwd} }
+ ]
+ );
+
+ print "http: $http_proxy->{url}:$http_proxy->{port}\n";
+ print "ftp: $ftp_proxy->{url}:$ftp_proxy->{port}\n";
+ print "login: $proxy_login->{login}, $proxy_login->{passwd}\n";
+
log::l("[drakproxy] Installation complete, exiting\n");
}
diff --git a/perl-install/standalone/drakproxy b/perl-install/standalone/drakproxy
index de0c51710..6a10e9a41 100755
--- a/perl-install/standalone/drakproxy
+++ b/perl-install/standalone/drakproxy
@@ -34,7 +34,7 @@ $::Wizard_title = _("Proxy handling");
my $in = interactive::vnew('su', 'default');
-if ($::isEmbedded && ref($in) =~ /gtk/) {
+if ($::isWizard || ($::isEmbedded && ref($in) =~ /gtk/)) {
proxy::main('', $in, sub { $in->standalone::pkgs_install(@_) });
$in->exit(0);
}
@@ -54,7 +54,7 @@ Click on Configure to launch the setup wizard."),
),
1, gtkpack(my $hbox2 = new Gtk::HBox(0,0),),
0, gtkadd(gtkset_layout(new Gtk::HButtonBox, -end),
- gtksignal_connect(new Gtk::Button(_("Configure")), clicked => sub { system ("/usr/sbin/drakgw --wizard") }),
+ gtksignal_connect(new Gtk::Button(_("Configure")), clicked => sub { system ("/usr/sbin/drakproxy --wizard") }),
gtksignal_connect(new Gtk::Button(_("Cancel")), clicked => sub { kill(USR1, $::CCPID) }),
)
)
@@ -67,6 +67,9 @@ Gtk->exit(0);
#-------------------------------------------------
#- $Log$
+#- Revision 1.5 2001/06/12 12:45:57 odin
+#- ui for drakproxy almost done
+#-
#- Revision 1.4 2001/06/11 16:34:49 damien
#- corrected CVS: ----------------------------------------------------------------------
#-