diff options
author | Norbert Preining <preining@logic.at> | 2011-06-14 05:32:38 +0000 |
---|---|---|
committer | Norbert Preining <preining@logic.at> | 2011-06-14 05:32:38 +0000 |
commit | 4943b1d2491050dd5bd25daebaf590ecee101379 (patch) | |
tree | f14e3e26c8c052238cdd621a4c6d2e6aa394658a | |
parent | d6ba1b973d6b5724295260aec7d4bce7cadf27ab (diff) |
don't allow Mojca to not install the main arch in the gui installer
git-svn-id: svn://tug.org/texlive/trunk@22967 c570f23f-e606-0410-a88d-b1316a301751
-rw-r--r-- | Master/tlpkg/installer/install-menu-perltk.pl | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/Master/tlpkg/installer/install-menu-perltk.pl b/Master/tlpkg/installer/install-menu-perltk.pl index 6a9cb99ef68..d7ef1029bbb 100644 --- a/Master/tlpkg/installer/install-menu-perltk.pl +++ b/Master/tlpkg/installer/install-menu-perltk.pl @@ -844,7 +844,9 @@ sub menu_select_binsystems { $f2 = $sw->Frame; my $f2l = $f2->Frame; foreach my $sys (sort @diskarchs) { - $f2l->Checkbutton(-variable => \$vars{"binary_$sys"}, -text => platform_desc($sys))->pack(-anchor => 'w'); + $f2l->Checkbutton(-variable => \$vars{"binary_$sys"}, + -command => sub { check_on_removal($sw, $sys); }, + -text => platform_desc($sys))->pack(-anchor => 'w'); } $f2l->pack(-side => 'left'); $f2->pack(-padx => "2m", -pady => "2m"); @@ -858,6 +860,18 @@ sub menu_select_binsystems { $sw->bind('<Escape>' => [ $cancelbutton, 'Invoke']); } +sub check_on_removal { + my $arch_frame = shift; + my $a = shift; + if (!$vars{"binary_$a"} && $a eq $vars{'this_platform'}) { + # removal not supported + $vars{"binary_$a"} = 1; + $arch_frame->Dialog(-title => __("Warning"), + -text => __("Removals of the main platform not possible!"), + -buttons => [ __("Ok") ])->Show; + } +} + sub menu_set_text { my $w = shift; |