Eina_Bool on_hold : 1;
Eina_Bool multi : 1; /**< a flag for item multi selection */
Eina_Bool wasselected : 1;
- Eina_Bool no_highlight : 1;
+ Eina_Bool highlight : 1; /**< a flag for items can be highlighted or not. by default this flag is true. */
Eina_Bool clear_me : 1; /**< a flag whether genlist is marked as to be cleared or not. if this flag is true, genlist clear was already deferred. */
Eina_Bool h_bounce : 1;
Eina_Bool v_bounce : 1;
_item_highlight(Elm_Gen_Item *it)
{
if ((it->wd->select_mode == ELM_OBJECT_SELECT_MODE_NONE) ||
- (it->wd->no_highlight) || (it->highlighted) ||
+ (!it->wd->highlight) || (it->highlighted) ||
(it->generation < it->wd->generation)) return;
edje_object_signal_emit(VIEW(it), "elm,state,selected", "elm");
it->highlighted = EINA_TRUE;
wd->align_y = 0.5;
wd->h_bounce = bounce;
wd->v_bounce = bounce;
+ wd->highlight = EINA_TRUE;
evas_object_smart_callback_add(obj, "scroll-hold-on", _hold_on, obj);
evas_object_smart_callback_add(obj, "scroll-hold-off", _hold_off, obj);
{
const char *selectraise;
if ((it->wd->select_mode == ELM_OBJECT_SELECT_MODE_NONE) ||
- (it->wd->no_highlight) ||
+ (!it->wd->highlight) ||
(it->generation < it->wd->generation) ||
(it->highlighted) || elm_widget_item_disabled_get(it) ||
(it->select_mode == ELM_OBJECT_SELECT_MODE_NONE) || (it->item->mode_view) ||
wd->max_items_per_block = MAX_ITEMS_PER_BLOCK;
wd->item_cache_max = wd->max_items_per_block * 2;
wd->longpress_timeout = _elm_config->longpress_timeout;
+ wd->highlight = EINA_TRUE;
evas_object_smart_callback_add(obj, "scroll-hold-on", _hold_on, obj);
evas_object_smart_callback_add(obj, "scroll-hold-off", _hold_off, obj);
ELM_CHECK_WIDTYPE(obj, widtype);
Widget_Data *wd = elm_widget_data_get(obj);
if (!wd) return;
- highlight = !!highlight;
- wd->no_highlight = !highlight;
+ wd->highlight = !!highlight;
}
EAPI Eina_Bool
ELM_CHECK_WIDTYPE(obj, widtype) EINA_FALSE;
Widget_Data *wd = elm_widget_data_get(obj);
if (!wd) return EINA_FALSE;
- return !wd->no_highlight;
+ return wd->highlight;
}
EAPI void