Ephoto: Fix some incorrect thumb selection issues.

v-1.6.0
Stephen Houston 7 years ago
parent 6c38b82f95
commit bcfd488e0f
  1. 1
      src/bin/ephoto.h
  2. 8
      src/bin/ephoto_main.c
  3. 1
      src/bin/ephoto_thumb_browser.c

@ -191,6 +191,7 @@ struct _Ephoto
Ephoto_State state, prev_state;
Ephoto_Config *config;
Ephoto_Entry *thumb_entry;
};
struct _Ephoto_Entry

@ -38,11 +38,10 @@ _ephoto_thumb_browser_show(Ephoto *ephoto, Ephoto_Entry *entry)
_ephoto_state_set(ephoto, EPHOTO_STATE_THUMB);
ephoto_title_set(ephoto, ephoto->config->directory);
if (ephoto->thumb_entry)
elm_gengrid_item_selected_set(ephoto->thumb_entry->item, EINA_TRUE);
if ((entry) && (entry->item))
{
elm_gengrid_item_selected_set(entry->item, EINA_TRUE);
elm_gengrid_item_bring_in(entry->item, ELM_GENGRID_ITEM_SCROLLTO_IN);
}
elm_gengrid_item_bring_in(entry->item, ELM_GENGRID_ITEM_SCROLLTO_IN);
}
static void
@ -58,6 +57,7 @@ _ephoto_single_browser_show(Ephoto *ephoto, Ephoto_Entry *entry)
ephoto_single_browser_entries_set(ephoto->single_browser,
ephoto->entries);
ephoto->thumb_entry = entry;
ephoto_single_browser_entry_set(ephoto->single_browser, entry);
elm_naviframe_item_simple_promote(ephoto->pager, ephoto->single_browser);
elm_object_focus_set(ephoto->single_browser, EINA_TRUE);

@ -1064,6 +1064,7 @@ _ephoto_thumb_activated(void *data, Evas_Object *obj EINA_UNUSED,
{
EINA_LIST_FOREACH(selected, s, item)
{
elm_gengrid_item_selected_set(item, EINA_TRUE);
tb->ephoto->selentries = eina_list_append(tb->ephoto->selentries,
elm_object_item_data_get(item));
}

Loading…
Cancel
Save