Lines Matching refs:prop
39 struct property *prop = prop_alloc(P_DEFAULT, sym); in sym_add_default() local
41 prop->expr = expr_alloc_symbol(sym_lookup(def, 1)); in sym_add_default()
113 struct property *prop; in sym_get_choice_prop() local
115 for_all_choices(sym, prop) in sym_get_choice_prop()
116 return prop; in sym_get_choice_prop()
122 struct property *prop; in sym_get_default_prop() local
124 for_all_defaults(sym, prop) { in sym_get_default_prop()
125 prop->visible.tri = expr_calc_value(prop->visible.expr); in sym_get_default_prop()
126 if (prop->visible.tri != no) in sym_get_default_prop()
127 return prop; in sym_get_default_prop()
134 struct property *prop; in sym_get_range_prop() local
136 for_all_properties(sym, prop, P_RANGE) { in sym_get_range_prop()
137 prop->visible.tri = expr_calc_value(prop->visible.expr); in sym_get_range_prop()
138 if (prop->visible.tri != no) in sym_get_range_prop()
139 return prop; in sym_get_range_prop()
162 struct property *prop; in sym_validate_range() local
176 prop = sym_get_range_prop(sym); in sym_validate_range()
177 if (!prop) in sym_validate_range()
180 val2 = sym_get_range_val(prop->expr->left.sym, base); in sym_validate_range()
182 val2 = sym_get_range_val(prop->expr->right.sym, base); in sym_validate_range()
195 struct property *prop; in sym_calc_visibility() local
200 for_all_prompts(sym, prop) { in sym_calc_visibility()
201 prop->visible.tri = expr_calc_value(prop->visible.expr); in sym_calc_visibility()
202 tri = E_OR(tri, prop->visible.tri); in sym_calc_visibility()
226 struct property *prop; in sym_calc_choice() local
238 for_all_defaults(sym, prop) { in sym_calc_choice()
239 prop->visible.tri = expr_calc_value(prop->visible.expr); in sym_calc_choice()
240 if (prop->visible.tri == no) in sym_calc_choice()
242 def_sym = prop_get_symbol(prop); in sym_calc_choice()
249 prop = sym_get_choice_prop(sym); in sym_calc_choice()
250 for (e = prop->expr; e; e = e->left.expr) { in sym_calc_choice()
265 struct property *prop; in sym_calc_value() local
304 prop = sym_get_choice_prop(sym); in sym_calc_value()
305 newval.tri = (prop_get_symbol(prop)->curr.val == sym) ? yes : no; in sym_calc_value()
311 prop = sym_get_default_prop(sym); in sym_calc_value()
312 if (prop) in sym_calc_value()
313 newval.tri = expr_calc_value(prop->expr); in sym_calc_value()
317 prop = sym_get_default_prop(sym); in sym_calc_value()
318 if (prop) { in sym_calc_value()
320 newval.tri = expr_calc_value(prop->expr); in sym_calc_value()
336 prop = sym_get_default_prop(sym); in sym_calc_value()
337 if (prop) { in sym_calc_value()
338 struct symbol *ds = prop_get_symbol(prop); in sym_calc_value()
362 prop = sym_get_choice_prop(sym); in sym_calc_value()
363 for (e = prop->expr; e; e = e->left.expr) { in sym_calc_value()
385 struct property *prop; in sym_set_changed() local
388 for (prop = sym->prop; prop; prop = prop->next) { in sym_set_changed()
389 if (prop->menu) in sym_set_changed()
390 prop->menu->flags |= MENU_CHANGED; in sym_set_changed()
439 struct property *prop; in sym_set_tristate_value() local
444 prop = sym_get_choice_prop(cs); in sym_set_tristate_value()
445 for (e = prop->expr; e; e = e->left.expr) { in sym_set_tristate_value()
529 struct property *prop; in sym_string_within_range() local
538 prop = sym_get_range_prop(sym); in sym_string_within_range()
539 if (!prop) in sym_string_within_range()
542 return val >= sym_get_range_val(prop->expr->left.sym, 10) && in sym_string_within_range()
543 val <= sym_get_range_val(prop->expr->right.sym, 10); in sym_string_within_range()
547 prop = sym_get_range_prop(sym); in sym_string_within_range()
548 if (!prop) in sym_string_within_range()
551 return val >= sym_get_range_val(prop->expr->left.sym, 16) && in sym_string_within_range()
552 val <= sym_get_range_val(prop->expr->right.sym, 16); in sym_string_within_range()
793 struct property *prop; in sym_check_deps() local
807 for (prop = sym->prop; prop; prop = prop->next) { in sym_check_deps()
808 if (prop->type == P_CHOICE || prop->type == P_SELECT) in sym_check_deps()
810 sym2 = sym_check_expr_deps(prop->visible.expr); in sym_check_deps()
813 if (prop->type != P_DEFAULT || sym_is_choice(sym)) in sym_check_deps()
815 sym2 = sym_check_expr_deps(prop->expr); in sym_check_deps()
833 struct property *prop; in prop_alloc() local
836 prop = malloc(sizeof(*prop)); in prop_alloc()
837 memset(prop, 0, sizeof(*prop)); in prop_alloc()
838 prop->type = type; in prop_alloc()
839 prop->sym = sym; in prop_alloc()
840 prop->file = current_file; in prop_alloc()
841 prop->lineno = zconf_lineno(); in prop_alloc()
845 for (propp = &sym->prop; *propp; propp = &(*propp)->next) in prop_alloc()
847 *propp = prop; in prop_alloc()
850 return prop; in prop_alloc()
853 struct symbol *prop_get_symbol(struct property *prop) in prop_get_symbol() argument
855 if (prop->expr && (prop->expr->type == E_SYMBOL || in prop_get_symbol()
856 prop->expr->type == E_CHOICE)) in prop_get_symbol()
857 return prop->expr->left.sym; in prop_get_symbol()