From c18b5aff0fcb2adca6022214406e685b3af157a2 Mon Sep 17 00:00:00 2001 From: damien Date: Mon, 18 Dec 2000 18:10:52 +0000 Subject: new control center and related --- perl-install/ChangeLog | 4 ++++ perl-install/interactive_gtk.pm | 45 +++++++++++++++++++++++++++++++++++ perl-install/standalone/XFdrake | 4 ++++ perl-install/standalone/adduserdrake | 3 +++ perl-install/standalone/drakboot | 4 ++++ perl-install/standalone/drakxservices | 4 ++++ 6 files changed, 64 insertions(+) diff --git a/perl-install/ChangeLog b/perl-install/ChangeLog index dd3f9ec2c..541d090cc 100644 --- a/perl-install/ChangeLog +++ b/perl-install/ChangeLog @@ -1,3 +1,7 @@ +2000-12-12 DrakX + + * dams : firewall snapshot uploaded + 2000-12-07 DrakX * dams : firewall snapshot uploaded diff --git a/perl-install/interactive_gtk.pm b/perl-install/interactive_gtk.pm index f4209c073..3d1157a51 100644 --- a/perl-install/interactive_gtk.pm +++ b/perl-install/interactive_gtk.pm @@ -38,6 +38,15 @@ sub ask_from_list_with_helpW { my $r; my $w = my_gtk->new(first(deref($title)), %$o); + if ($::isEmbedded) { + $w->{window} = new Gtk::VBox(0,0); + $w->{rwindow} = $w->{window}; + defined($::Plug) ? $::Plug->child->destroy() : ($::Plug = new Gtk::Plug ($::XID)); + $::Plug->show; + my_gtk::flush(); + $::Plug->add($w->{window}); + $w->{window}->add($w->{rwindow}); + } #gtkset_usize(createScrolledWindow($tree), 300, min(350, $::windowheight - 60)), $w->{retval} = $def || $l->[0]; #- nearly especially for the X test case (see timeout in Xconfigurator.pm) $w->{rwindow}->set_policy(0, 0, 1) if $::isWizard; @@ -88,6 +97,15 @@ sub ask_from_treelistW { my ($o, $title, $messages, $separator, $l, $def) = @_; my $sep = quotemeta $separator; my $w = my_gtk->new($title); + if ($::isEmbedded) { + $w->{window} = new Gtk::VBox(0,0); + $w->{rwindow} = $w->{window}; + defined($::Plug) ? $::Plug->child->destroy() : ($::Plug = new Gtk::Plug ($::XID)); + $::Plug->show; + my_gtk::flush(); + $::Plug->add($w->{window}); + $w->{window}->add($w->{rwindow}); + } my $tree = Gtk::CTree->new(1, 0); my %wtree; @@ -166,6 +184,15 @@ sub ask_from_treelistW { sub ask_many_from_listW { my ($o, $title, $messages, @l) = @_; my $w = my_gtk->new('', %$o); + if ($::isEmbedded) { + $w->{window} = new Gtk::VBox(0,0); + $w->{rwindow} = $w->{window}; + defined($::Plug) ? $::Plug->child->destroy() : ($::Plug = new Gtk::Plug ($::XID)); + $::Plug->show; + my_gtk::flush(); + $::Plug->add($w->{window}); + $w->{window}->add($w->{rwindow}); + } $w->sync; # for XPM's creation my $tips = new Gtk::Tooltips; @@ -204,6 +231,15 @@ sub ask_from_entries_refW { my $ignore = 0; #-to handle recursivity my $w = my_gtk->new($title_, %$o); + if ($::isEmbedded) { + $w->{window} = new Gtk::VBox(0,0); + $w->{rwindow} = $w->{window}; + defined($::Plug) ? $::Plug->child->destroy() : ($::Plug = new Gtk::Plug ($::XID)); + $::Plug->show; + my_gtk::flush(); + $::Plug->add($w->{window}); + $w->{window}->add($w->{rwindow}); + } $w->sync; # for XPM's creation my $set_icon = sub { @@ -361,6 +397,15 @@ sub wait_messageW($$$) { my ($o, $title, $messages) = @_; my $w = my_gtk->new($title, %$o, grab => 1); + if ($::isEmbedded) { + $w->{window} = new Gtk::VBox(0,0); + $w->{rwindow} = $w->{window}; + defined($::Plug) ? $::Plug->child->destroy() : ($::Plug = new Gtk::Plug ($::XID)); + $::Plug->show; + my_gtk::flush(); + $::Plug->add($w->{window}); + $w->{window}->add($w->{rwindow}); + } gtkadd($w->{window}, my $hbox = new Gtk::HBox(0,0)); $hbox->pack_start(my $box = new Gtk::VBox(0,0), 1, 1, 10); $box->pack_start($_, 1, 1, 4) foreach my @l = map { new Gtk::Label($_) } @$messages; diff --git a/perl-install/standalone/XFdrake b/perl-install/standalone/XFdrake index 88db4c23d..11a3f77ae 100755 --- a/perl-install/standalone/XFdrake +++ b/perl-install/standalone/XFdrake @@ -24,6 +24,10 @@ use Xconfigurator; use Xconfig; use c; +for (my $i=0; $i<=$#ARGV; $i++) { + $ARGV[$i] eq '--embedded' and $::XID=$ARGV[$i+1] and $::isEmbedded = 1; +} + local $_ = join '', @ARGV; /-h/ and die "usage: XFdrake [--xf3] [--beginner] [--expert] [--auto] [--noauto] [--skiptest] [--testing]\n"; diff --git a/perl-install/standalone/adduserdrake b/perl-install/standalone/adduserdrake index 1ce283f8c..3b620d020 100755 --- a/perl-install/standalone/adduserdrake +++ b/perl-install/standalone/adduserdrake @@ -6,6 +6,9 @@ use common qw(:common :functional :system :file); use interactive; use any; +for (my $i=0; $i<=$#ARGV; $i++) { + $ARGV[$i] eq '--embedded' and $::XID=$ARGV[$i+1] and $::isEmbedded = 1; +} local $_ = join '', @ARGV; /-h/ and die "usage: adduserdrake [--beginner] [--expert] []\n"; diff --git a/perl-install/standalone/drakboot b/perl-install/standalone/drakboot index b5656dc4a..6d31f4c9f 100755 --- a/perl-install/standalone/drakboot +++ b/perl-install/standalone/drakboot @@ -11,6 +11,10 @@ use fsedit; use fs; use c; +for (my $i=0; $i<=$#ARGV; $i++) { + $ARGV[$i] eq '--embedded' and $::XID=$ARGV[$i+1] and $::isEmbedded = 1; +} + local $_ = join '', @ARGV; /-h/ and die "usage: drakboot [--expert]\n"; diff --git a/perl-install/standalone/drakxservices b/perl-install/standalone/drakxservices index 63318a031..065d5a7cf 100755 --- a/perl-install/standalone/drakxservices +++ b/perl-install/standalone/drakxservices @@ -7,6 +7,10 @@ use interactive; use services; use log; +for (my $i=0; $i<=$#ARGV; $i++) { + $ARGV[$i] eq '--embedded' and $::XID=$ARGV[$i+1] and $::isEmbedded = 1; +} + local $_ = join '', @ARGV; /-h/ and die "usage: drakxservices\n"; -- cgit v1.2.1