aboutsummaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2007-03-29 11:19:50 +0000
committerFelix Fietkau <nbd@openwrt.org>2007-03-29 11:19:50 +0000
commit4d8d4267144a74663eece82ef5b018ade4a607df (patch)
tree0f39427abbd81945876ec474d2b6e1c1fe5b4a65 /scripts
parent55e4f0f8bc68ebb687405afd8a8d37beb70094e2 (diff)
downloadupstream-4d8d4267144a74663eece82ef5b018ade4a607df.tar.gz
upstream-4d8d4267144a74663eece82ef5b018ade4a607df.tar.bz2
upstream-4d8d4267144a74663eece82ef5b018ade4a607df.zip
fix menuconfig 'deselect' statement
SVN-Revision: 6753
Diffstat (limited to 'scripts')
-rw-r--r--scripts/config/symbol.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/scripts/config/symbol.c b/scripts/config/symbol.c
index 23246ca3d4..2c1392ad43 100644
--- a/scripts/config/symbol.c
+++ b/scripts/config/symbol.c
@@ -197,6 +197,7 @@ static void sym_calc_visibility(struct symbol *sym)
{
struct property *prop;
tristate tri;
+ int deselected = 0;
/* any prompt visible? */
tri = no;
@@ -206,15 +207,15 @@ static void sym_calc_visibility(struct symbol *sym)
}
if (tri == mod && (sym->type != S_TRISTATE))
tri = yes;
- if (sym->rev_dep_inv.expr) {
- if (expr_calc_value(sym->rev_dep_inv.expr) == yes)
- tri = no;
+ if (sym->rev_dep_inv.expr && (expr_calc_value(sym->rev_dep_inv.expr) == yes)) {
+ tri = no;
+ deselected = 1;
}
if (sym->visible != tri) {
sym->visible = tri;
sym_set_changed(sym);
}
- if (sym_is_choice_value(sym))
+ if (sym_is_choice_value(sym) || deselected)
return;
tri = no;
if (sym->rev_dep.expr)
@@ -310,6 +311,8 @@ void sym_calc_value(struct symbol *sym)
if (sym_is_choice_value(sym) && sym->visible == yes) {
prop = sym_get_choice_prop(sym);
newval.tri = (prop_get_symbol(prop)->curr.val == sym) ? yes : no;
+ } else if (sym->rev_dep_inv.expr && (expr_calc_value(sym->rev_dep_inv.expr) == yes)) {
+ newval.tri = no;
} else if (E_OR(sym->visible, sym->rev_dep.tri) != no) {
sym->flags |= SYMBOL_WRITE;
if (sym_has_value(sym))