summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThierry Vignaud <tvignaud@mandriva.org>2003-12-19 20:34:34 +0000
committerThierry Vignaud <tvignaud@mandriva.org>2003-12-19 20:34:34 +0000
commit4c20967e2a50d1f85950732231b91678053d9255 (patch)
tree180fa0d564c3057623904014bca481f1c04af122
parent41d66885e06f3d38e16d2e2c88cfd41fd2e01835 (diff)
downloadcontrol-center-4c20967e2a50d1f85950732231b91678053d9255.tar
control-center-4c20967e2a50d1f85950732231b91678053d9255.tar.gz
control-center-4c20967e2a50d1f85950732231b91678053d9255.tar.bz2
control-center-4c20967e2a50d1f85950732231b91678053d9255.tar.xz
control-center-4c20967e2a50d1f85950732231b91678053d9255.zip
- rename $still_in_splash_screen variable as $still_not_in_a_section
in order to better reflect its current purpose - remove $done variable - logs menu entry: only do anything visually if not anymore in summary (and use $still_not_in_a_section rather than $done for this by the way) - replace the only remaining use of $done by checking whether main window is realized or not
-rwxr-xr-xcontrol-center14
1 files changed, 7 insertions, 7 deletions
diff --git a/control-center b/control-center
index 109c75db..cee1a58e 100755
--- a/control-center
+++ b/control-center
@@ -88,7 +88,7 @@ gtkflush();
#-------------------------------------------------------------
-my $still_in_splash_screen = 1;
+my $still_not_in_a_section = 1;
#-------------------------------------------------------------
@@ -315,7 +315,6 @@ my ($netcnx, $netc, $intf) = ({}, {}, {});
my @profiles;
my $mdk_rel = common::mandrake_release();
-my $done;
my @menu_items = (
@@ -325,7 +324,8 @@ my @menu_items = (
[ join('', @{$options{show_log}}), undef,
sub {
$option_values{show_log} = $check_boxes{show_log}->get_active;
- start_logdrake() if $done;
+ return if $still_not_in_a_section;
+ start_logdrake();
update_exp();
},
undef, '<CheckItem>'
@@ -394,7 +394,7 @@ my @menu_items = (
}, undef, '<Item>' ],
[ $shared_translations{profiles} . $shared_translations{delete}, undef, sub {
- return if !$done && $netcnx->{PROFILE} ne "default";
+ return if !$window_global->realized && $netcnx->{PROFILE} ne "default";
my $dialog = _create_dialog(N("Delete profile"), { stock => 'gtk-dialog-warning' });
gtkpack($dialog->vbox,
Gtk2::Label->new(N("Profile to delete:")),
@@ -704,7 +704,7 @@ foreach (@tree) {
$curr_state[$index_sav] = 0;
$hand_cursor->($darea_left_list[$index_sav]);
$darea_left_list[$index_sav]->queue_draw;
- } else { $still_in_splash_screen = 0 }
+ }
$index_sav = $my_index;
$curr_state[$my_index] = 2;
$darea_left->window->set_cursor($cursor_normal);
@@ -807,7 +807,6 @@ $SIG{CHLD} = \&sig_child;
$window_splash->destroy;
undef $window_splash;
-$done = 1;
Gtk2->main;
@@ -853,7 +852,7 @@ sub create_hidden_socket() {
}
sub update_exp() {
- return if $still_in_splash_screen;
+ return if $still_not_in_a_section;
if ($option_values{show_log}) {
$w_exp->show_all;
} else {
@@ -1116,6 +1115,7 @@ sub set_page {
start_logdrake();
update_exp();
$notebook_global->set_current_page($index);
+ $still_not_in_a_section = 0;
$help_on_context = $ctx[$index];
}