summaryrefslogtreecommitdiffstats
path: root/gurpm/RPMProgressDialog.pm
diff options
context:
space:
mode:
Diffstat (limited to 'gurpm/RPMProgressDialog.pm')
-rw-r--r--gurpm/RPMProgressDialog.pm4
1 files changed, 3 insertions, 1 deletions
diff --git a/gurpm/RPMProgressDialog.pm b/gurpm/RPMProgressDialog.pm
index 7dd04038..2b23fdb7 100644
--- a/gurpm/RPMProgressDialog.pm
+++ b/gurpm/RPMProgressDialog.pm
@@ -48,7 +48,7 @@ sub title {
}
# package variable needed in order to simplify callbacks
-my ($mainw, $urpm);
+my ($mainw, $urpm, $old_main_window);
my $progressbar_size = 450;
my ($progress_nb, $download_nb);
@@ -72,6 +72,7 @@ sub new {
# my $w = ugtk2->new($title, %options, default_width => 600, width => 600);
my $w = $mainw = bless(Gtk2::Window->new('toplevel'), $self);
+ $old_main_window = $::main_window;
$::main_window = $w;
$w->set_border_width(12);
$w->set_title($w->title);
@@ -292,6 +293,7 @@ sub DESTROY {
my ($self) = @_;
undef $mainw;
undef $urpm;
+ $::main_window = $old_main_window;
$self and $self->destroy;
$self = undef;