forked from enlightenment/efl
elm gen*: Changed local variable 'no_highlight' -> 'highlight' correctly.
Signed-off-by: Daniel Juyung Seo <juyung.seo@samsung.com> SVN revision: 69050
This commit is contained in:
parent
f935b1eabd
commit
bea13e990e
|
@ -98,7 +98,7 @@ struct _Widget_Data
|
|||
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;
|
||||
|
|
|
@ -872,7 +872,7 @@ static void
|
|||
_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;
|
||||
|
@ -1946,6 +1946,7 @@ elm_gengrid_add(Evas_Object *parent)
|
|||
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);
|
||||
|
|
|
@ -688,7 +688,7 @@ _item_highlight(Elm_Gen_Item *it)
|
|||
{
|
||||
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) ||
|
||||
|
@ -3479,6 +3479,7 @@ elm_genlist_add(Evas_Object *parent)
|
|||
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);
|
||||
|
@ -5708,8 +5709,7 @@ elm_genlist_highlight_mode_set(Evas_Object *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
|
||||
|
@ -5718,7 +5718,7 @@ elm_genlist_highlight_mode_get(const Evas_Object *obj)
|
|||
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
|
||||
|
|
Loading…
Reference in New Issue