On Tue, Sep 22, 2009 at 6:14 AM, Nicolas Aguirre
<[email protected]> wrote:
> Hi guys,
>
> in Enna, I use elementary since a while now, and I have a little
> problem that I would like to fix. I explain :
> In enna's file browser, I use genlist to display files. The item
> selection can be done either with mouse or with keyboard/remote
> control.
> To select items with keyboard I select them programatically with
> elm_genlist_item_selected_set(it, 1). When I do that, the selected
> callback passed in argument in elm_genlist_item_add is called, same
> behavior than if user click with mouse. This behavior is completely
> normal.
>
> When I browse with keyboard I want that the next/prev items are only
> highlight when user press key_up/key_down and select it when he press
> key_enter. So I pass NULL to the callback function parameter and catch
> the "clicked" callback which is send when the user double click on an
> item (and not the "selected" one). This is this behavior that I would
> like to change in Enna. Have a one click selection with mouse, and
> continued to be able to browse with keyboard.
>
> What do you think if I add these 3 new functions in elm_genlist ?
>
> EAPI Elm_Genlist_Item *elm_genlist_hilighted_item_get(const Evas_Object *obj);
> EAPI void
> elm_genlist_item_hilighted_set(Elm_Genlist_Item *item, Eina_Bool
> hilighted);
> EAPI Eina_Bool         elm_genlist_item_hilighted_get(const
> Elm_Genlist_Item *item);
>
> "hilighted" state of the item will change in line with  the "selected"
> state, AND when elm_genlist_item_hilighted_set is called.
> elm_genlist_hilighted_item_get retrieve item that is actually in
> "hilighted" state.
>
> You maybe don't want such behaviour in elm ? And there ise maybe other
> way to do that, so any comments will be appreciated :)

why not?! I guess this is a valid use case, just did not come as
requirement so far, then nobody implemented it... just do and commit,
be happy, avoid nasty hacks :-)

-- 
Gustavo Sverzut Barbieri
http://profusion.mobi embedded systems
--------------------------------------
MSN: [email protected]
Skype: gsbarbieri
Mobile: +55 (19) 9225-2202

------------------------------------------------------------------------------
Come build with us! The BlackBerry&reg; Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay 
ahead of the curve. Join us from November 9&#45;12, 2009. Register now&#33;
http://p.sf.net/sfu/devconf
_______________________________________________
enlightenment-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel

Reply via email to