Commit Graph

984 Commits

Author SHA1 Message Date
Daniel Juyung Seo f14fa87c84 genlist: Fix internal comments. 2014-12-30 01:31:43 +09:00
ChunEon Park f9cc9863a3 genlist: return as possible as soon. 2014-12-29 22:58:38 +09:00
ChunEon Park f2b7e575f0 genlist: clean up code.
repositioned function and remove unnecessary prototype declaration.
2014-12-29 22:51:39 +09:00
ChunEon Park fb8af1004c genlist: remove duplicated signal registration. 2014-12-29 22:34:45 +09:00
ChunEon Park 1f73409844 genlist: send an additional signal
send flip disabled signal when it's state is switched.
2014-12-29 22:27:28 +09:00
ChunEon Park cce9511130 genlist: send a signal internally.
send a signal so that item set it's style according to it's depth
2014-12-29 22:16:34 +09:00
ChunEon Park 5b2493b7af genlist: send a disabled signal when the decorated item is unrealized. 2014-12-29 21:44:50 +09:00
ChunEon Park b4fe364f1b genlist: code refactoring
declare/use const strings for internal signals
2014-12-29 19:50:39 +09:00
Davide Andreoli 9988b752c7 Genlist: do not fire clicked,right while dragging in progress 2014-12-29 11:19:21 +01:00
ChunEon Park eb229ae0e2 genlist: add "scroll" smart call
@feature
2014-12-29 19:02:08 +09:00
Davide Andreoli 69b6310954 Improve -clicked- detection code by accept only if the mouse do not move too much
Too much in this case is a fixed 4px. As fingers do not have a right button I think
that taking into account finger size is not needed here.

Also someone argued about the signal name is not really correct...
should I change it to somethig like: clicked,secondary ?
2014-12-26 18:46:28 +01:00
Davide Andreoli 536c5de134 Genlist: added the clicked,right event on items
@feature
2014-12-26 17:29:51 +01:00
Amitesh Singh fc1579020c list/genlist/gengrid: Fix memory leak.
Summary: @Fix

Reviewers: kimcinoo, SanghyeonLee, raster, seoz

Reviewed By: seoz

Subscribers: seoz

Differential Revision: https://phab.enlightenment.org/D1825
2014-12-26 20:22:57 +09:00
Daniel Juyung Seo d47a4adae4 gengrid, genlist, list, toolbar: Fix memory leak and enhance performance.
1. Fix memory leak by freeing eina_list.
2. Enhance performance by getting the item list when it is really
needed.

@fix
2014-12-26 18:41:48 +09:00
Daniel Juyung Seo 9b038471bf genlist: Return the correct pointer for object item.
No backport needed.
2014-12-26 14:36:36 +09:00
Andrii Kroitor 8148de6e17 elm_genlist: add missing callback call
Summary:
Added missing "moved" callback call when reordering items with keyboard
"up" and "down" arrows

@fix

Reviewers: cedric, raster, seoz

Reviewed By: seoz

Subscribers: reutskiy.v.v

Differential Revision: https://phab.enlightenment.org/D1818
2014-12-26 14:23:42 +09:00
Mike Blumenkrantz c201ec6c87 genlist should ignore no-select items when moving with the keyboard
@fix
2014-12-25 20:39:17 -05:00
Daniel Juyung Seo 4a61d3955e genlist: Fix dereference before null check.
This fixes coverity CID 1258636.
No backport needed.
2014-12-16 23:54:13 +09:00
Carsten Haitzler 17f411f6be elm - fix warnings added in f99be3a1d6bdc63153598b592b5437c33da44bf0 2014-12-16 19:36:35 +09:00
Jyotiprakash Sahoo 17419ec81c genlist: added reorder feature on key events
Summary: This feature allows user to reorder items using up/down keys.

Test Plan: elementary_test -to "Genlist Reorder Mode"

Reviewers: singh.amitesh, raster, seoz, SanghyeonLee

Differential Revision: https://phab.enlightenment.org/D1262

Conflicts:
	src/bin/test_genlist.c
	src/lib/elm_genlist_legacy.h
2014-12-16 18:20:32 +09:00
Daniel Juyung Seo 14e79451c2 genlist: Fix genlist crash issue when clearing genlist on item focus callback.
This fixes "genlist focus" test sample's crash issue.

@fix
2014-12-14 04:19:42 +09:00
Daniel Juyung Seo e31df3372c gengrid, genlist: Optimize eo item usage.
Remove unnecessary pointer reference.
2014-11-25 21:55:14 +09:00
Daniel Zaoui dfc3f7ac30 Genlist: Fix previous commit.
The items of an item is a list of Elm_Object_Item and not of Elm_Gen_Item.
Sorry @zmike ;-)

Fixes T1859

Another fix has been added in this commit, related to relative items.
2014-11-23 09:18:42 +02:00
Daniel Zaoui 0f28743080 Genlist: Fix API return value.
elm_genlist_item_subitems_get has to return a list of Elm_Object_Item.
Because of the porting of the genlist item to Eo, this function returns
a list of Elm_Gen_Item.

Thanks to zmike and seoz for catching this.

Fixes T1859
2014-11-22 09:40:37 +02:00
Daniel Juyung Seo 7fc83c54b5 genlist: Fix build warning for uninitialized variable.
elm_genlist.c:1916:15: warning: 'eo_it' may be used uninitialized in
this function [-Wuninitialized]
2014-11-19 19:53:40 +09:00
Daniel Zaoui 05225b162e Object Items: remove data variable from widget item.
Now, data is stored in Eo layer via eo_key_data_set/get.

Two macros have been added to facilitate access.
2014-11-12 12:03:58 +02:00
Daniel Zaoui ef03bc098e Object Items: remove legacy APIs.
They are now generated by Eolian.
2014-11-12 12:03:58 +02:00
Daniel Zaoui b01d01528a Object Items: remove casts that are no more needed.
It includes casts to Eo, Elm_Object_Item and to specific items data.
This belongs to the cleaning phase of the object items porting to Eo.
2014-11-12 12:03:57 +02:00
Daniel Zaoui ca286ea1cb Elm Genlist Item: Migrate to Eo 2014-11-12 12:03:56 +02:00
Daniel Zaoui a9b13f7633 Elm Widget Item: Migrate to Eo
Since we want to support legacy inheritance mechanism, code is not
finished and will have to be cleaned when all the items are ported.
2014-11-12 11:52:10 +02:00
Daniel Juyung Seo f9ec18f586 genlist: Remove unnecessary callbacks when item loop is disabled.
@fix
2014-11-07 02:20:21 +09:00
Lukasz Stanislawski 2ca1f8a75a atspi: properly include at-spi headers.
Summary:
Change requested by TAsn. Previuosly AT-SPI headers were kept private
and included directly into elementary source code. From now on,
AT-SPI headers can be included from Elementary.h public header, however
will be marked as beta APIs.

Commit includes following changes:
* include all atspi headers into new elm_interfaces.h header.
* marking all at-spi interfaces methods/properties as @protected.
* wrap all common headers with EFL_BETA_API_SUPPORT.
* make some common APIs visible in lib, by adding EAPI attribute
  (if someone decides to use beta APIs).

Test Plan: out-off tree build with gcc, g++

Reviewers: tasn

Reviewed By: tasn

Subscribers: seoz, q66, kuuko

Maniphest Tasks: T1721

Differential Revision: https://phab.enlightenment.org/D1528
2014-10-17 16:57:26 +01:00
zmike 2bcbe743d1 genlist item block recalc checks now more readable 2014-10-07 14:07:13 -04:00
zmike dbc3b87b18 genlist item block recalc checks make more sense 2014-10-07 14:07:13 -04:00
Tom Hacohen 236bab8d53 Change according to recent Eo changes, and fix related wrong unrefs.
eo_add()'s counterpart is eo_del, not eo_unref. Regardless of that, some
objects were being double-deleted which spew out some eo errors. These
things should now be fixed.

bc6b6aa457 is the relevant EFL commit.
2014-09-30 14:54:52 +01:00
Tom Hacohen 7629c147eb Eo related: Change according to recent changes in eo_add().
For more info check out a7560dbc61 in
the EFL tree.
2014-09-25 17:39:34 +01:00
Amitesh Singh b9744e58f5 genlist: Removed unnecessary casting of genlist item.
Reviewers: seoz

Subscribers: seoz

Differential Revision: https://phab.enlightenment.org/D1471
2014-09-25 01:36:03 +09:00
Jae Yong Hwang fbee0944db genlist: Fixed a crash bug in case of calling a genlist_clear in a select callback function.
Summary:
If item select callback is elm_genlist_clear and genlist object have many item, elm_genlist_clear was broken.
This reason is due to incorrect code. In Old code, check the item focus  after an item was deleted. So, I changed the order of the code.
Before item was deleted, Check the item focus.
@fix

Test Plan: I revised the elementary_test code and tested with that.

Reviewers: raster, SanghyeonLee, seoz

Reviewed By: seoz

Subscribers: bluezery, SanghyeonLee

Differential Revision: https://phab.enlightenment.org/D1418
2014-09-06 01:47:55 +09:00
Daniel Juyung Seo e68db15448 genlist: added internal function _view_clear() for common codes.
Use this function for normal items, decorate items, and decorate all
items.
2014-08-22 03:44:26 +09:00
Daniel Juyung Seo 08fe37c254 genlist: merged _item_content_realize() and _item_mode_content_realize(). 2014-08-22 03:44:26 +09:00
Daniel Juyung Seo 460609ce80 genlist: moved internals functions before refactoring it.
_item_text_realize(), _item_content_realize(), and
_item_state_realize().
2014-08-22 03:44:26 +09:00
Daniel Juyung Seo 122dda0b48 genlist: Added internal functions _view_create and _view_style_update
for the commonly used codes.
2014-08-22 03:44:26 +09:00
Daniel Juyung Seo 9c81e0e02a genlist: Unbreak double click smart callback.
Fixed a typo in my commit adb976e.
2014-08-22 03:42:11 +09:00
Daniel Juyung Seo 4a398c6ee9 genlist: Fixed ELM_OBJECT_SELECT_MODE_NONE codes and added more DISPLAY_ONLY check.
Also made an internal function to check it easily.

@fix
2014-08-22 02:47:24 +09:00
Daniel Juyung Seo 509112325d gengrid, genlist, list, toolbar: Fixed DISPLAY_ONLY select mode for an object.
DISPLAY_ONLY select mode for elm_xxx_item_select_mode_set works fine but
elm_xxx_select_mode_set was broken.

@fix
2014-08-22 01:12:38 +09:00
Jae Yong Hwang 9a13ed55fc genlist: Fixed item select logic when item select mode is ALWAYS.
Summary:
ELM_OBJECT_SELECT_MODE_ALWAYS mode for elm_genlist_item_select_mode
was broken. In the item select routine, item mode(it->mode) was not
checked. So, I added the check routine there.

@fix

Test Plan: I revised the elementary_test code and tested with that.

Reviewers: raster, seoz

Reviewed By: seoz

Subscribers: SanghyeonLee, bluezery

Differential Revision: https://phab.enlightenment.org/D1347
2014-08-21 22:54:22 +09:00
Davide Andreoli 4052f7521e Genlist: do not segv if the user clear the list on item double-click
@fix
moved the user callbacks call at the end of the function, so the user
is able to modify the list without making the code below the call to
fail miserably.

Also improved the Genlist Del test to also include this case.
2014-08-09 17:53:46 +02:00
Chinmaya 7dbc9f48b6 Genlist: Fixed indentation.
Summary: Fixed indentation.

Test Plan: -NA-

Reviewers: seoz, raster

Subscribers: seoz

Differential Revision: https://phab.enlightenment.org/D1269
2014-08-06 13:58:52 +09:00
Anand c464abf99b genlist: removed unnecessary EINA_UNUSED macro
Reviewers: singh.amitesh, nirajkr, seoz

Reviewed By: seoz

Subscribers: sachin.dev

Differential Revision: https://phab.enlightenment.org/D1270
2014-08-06 13:56:07 +09:00
Davide Andreoli 139a1ddb08 Genlist: fix search_by_text_item_get() text_get call
The text_get function was called with the wrong params, now its usage is consistent with the rest of the code.
2014-08-01 16:29:16 +02:00
Lukasz Stanislawski 09b9ef0bc0 atspi: expose more actions through atspi bus.
Summary:
Main purpose of exposing widget actions and keyboard shortcuts
is to allow accessibility clients to implement alternative methods
of GUI navigation.

Reviewers: z.kosinski

Reviewed By: z.kosinski

Subscribers: seoz

Differential Revision: https://phab.enlightenment.org/D1227
2014-07-25 11:58:16 +02:00
Carsten Haitzler e741a19b21 fix genlist/grid search item patch to be simpler and just better
better - why?

1. no reliance on fnmatrch headers - have special enums for this so
fnmatch is an internal detail (casefole may not exist)
2. don't leak strduped strings - free them when done
3. have the same code for genlist and grid (dup for now until an
interface makes it the same search interface)
4. improve docs
5. get right @since version
6. use label get func in item class - providing a func won't work when
multiple items of multiple classes exist in the list
2014-07-24 12:41:33 +09:00
Anand 8b6ac56dc3 genlist: Focus highlight when loop is enable
Summary:
This patch is dependent on D1193 and D1136.
It will be pushed after D1193 and D1136 patch.

Reviewers: singh.amitesh

Differential Revision: https://phab.enlightenment.org/D1168

Conflicts:
	src/lib/elm_genlist.c
2014-07-22 15:57:32 +09:00
Hosang Kim 105ee3660d genlist : Add item looping on flag.
Summary: When item looping feature is on and press up or down key, screen seems to be frozen.

Test Plan: elementary_test -to "genlist focus" -> click item looing enable -> move list up and down

Reviewers: anand.km, seoz, woohyun

Subscribers: singh.amitesh

Differential Revision: https://phab.enlightenment.org/D1193
2014-07-22 15:11:18 +09:00
Anil Kumar Nahak 76e3372531 Focus: first item should be focused when there is no focused/selected item
Summary: First item of widget should be focused when focus comes to the widget for first time.

Test Plan:
elementary_test -to "Genlist Focus"
elementary_test -to "Gengrid Focus"
elementary_test -to "List Focus"
elementary_test -to "toolbar Focus"

Reviewers: seoz

Differential Revision: https://phab.enlightenment.org/D1135
2014-07-21 18:55:55 +09:00
ChunEon Park 0f6bb7fac2 genlist - fix a crash.
It allows NULL focused item.
let it null check.
2014-07-15 12:31:07 +09:00
Shobhit f4fea0abca genlist: Removed unnecessary calculation.
Summary: Removed unnecessary calculation from _elm_genlist_elm_widget_focus_highlight_geometry_get()

Test Plan: elementary_test -to "genlist focus"

Reviewers: seoz, Hermet

Reviewed By: Hermet

Subscribers: sachin.dev

Differential Revision: https://phab.enlightenment.org/D1145
2014-07-15 12:15:53 +09:00
wonguk.jeong de7dc33904 genlist: remove annoying error message
Summary:
content couldn't be always a elm widget.
After checking whether it's elm widget or not, use widget API

Test Plan:
terminology -> options -> font -> select font and check below error message

ERR<25935>:eo lib/eo/eo.c:603 _eo_call_resolve() in elm_widget.eo.c:8: you called func 'elm_obj_widget_focus_get' (213) which is unknown in class 'Edje_Object'.

Reviewers: raster, cedric, seoz, Hermet

Reviewed By: Hermet

Subscribers: seoz

Differential Revision: https://phab.enlightenment.org/D1186
2014-07-15 12:07:10 +09:00
Shobhit 32c3bf41b5 genlist: Removed unnecessary condition check.
Summary:
Removed condition check from _elm_genlist_elm_widget_item_loop_enabled_set()

Reviewers: seoz

CC: sachin.dev

Differential Revision: https://phab.enlightenment.org/D1144
2014-07-10 00:39:52 +09:00
Amitesh Singh 24ce4835c1 list/genlist/gengrid/toolbar: removed unused smart data member prev_focused_item.
Reviewers: raster, seoz

CC: seoz

Differential Revision: https://phab.enlightenment.org/D1119
2014-07-07 12:20:54 +09:00
Anil Kumar Nahak 2b8e6862ac genlist: focus of genlist item should adjust according to genlist's viewport
Summary: The focus of genlist should adjust its position on resizing(shrinking).

Reviewers: seoz

Differential Revision: https://phab.enlightenment.org/D1072
2014-07-03 16:39:42 +09:00
Zbigniew Kosinski 9ce23f0004 atspi:Set roles for widgets
Reviewers: stanluk, m.jagiello, raster

Differential Revision: https://phab.enlightenment.org/D930
2014-06-11 11:07:16 +09:00
Anil Kumar Nahak bdb51ddd45 genlist: Focus out of genlist viewport area on resize fixed
Summary:
The focus of genlist was coming out of genlist's viewport area on resizing(shrinking).
This is fixed in this patch.

Test Plan: elementary_test -to genlist5, elementary_test -to fileselector

Reviewers: seoz, singh.amitesh, nirajkr

Differential Revision: https://phab.enlightenment.org/D949
2014-06-10 19:29:47 +09:00
Tom Hacohen efa41c7d75 Elm: Update code to use the new class names generated by eolian. 2014-06-03 11:54:44 +01:00
Kateryna Fesyna 28e73198f7 Genlist: Add function to search item by string.
Summary:
This function allows user to search for item in Genlist.
It takes four search parameters:
1. pointer to function to get text of the item. It could be the same with item's
   get_text function. This parameter is added to let user use the specific search key
   and to avoid problems with setting item's text, that is not constant.
2. pointer to the item from which search should start.
3. search pattern.
4. fnmatch() flags.
To check it's usage the new test is added to the elementary_test (Genlist Item Search By Text)

Reviewers: cedric, seoz, raster

CC: reutskiy.v.v

Differential Revision: https://phab.enlightenment.org/D566
2014-05-27 15:55:05 +09:00
Daniel Juyung Seo 7357290056 genlist: fixed wrong item focus set on item_focus_set API call.
Reset the last_focused_item on _item_focus_set_hook.
This fixes the issue which sets the focus to the wrong item when the
focus is set by an API.

Reproduction step:
elementary_test -> genlist focus -> click an item (not the 2nd item) -> click "Focus 2nd
Item after 1.5 seconds" button.
Focus is not moved to the 2nd item.

@fix
2014-05-26 22:08:13 +09:00
chinmaya 184c394259 Genlist: On focus_on_selection mode, the focus should set on item content objects of item type ELM_GENLIST_ITEM_TREE.
Summary:
On focus_on_selection set, the focus set on genlist item of type ELM_GENLIST_ITEM_TREE rather than
         on item content objects.

Test Plan: elementary_test -to "genlist focus"

Reviewers: seoz, eagleeye, SanghyeonLee, raster

Reviewed By: raster

CC: seoz

Differential Revision: https://phab.enlightenment.org/D899
2014-05-26 15:52:07 +09:00
chinmaya cd603fa02b Genlist: Focus does not move, if it is set on item content objects.
Summary:
If focus is set on item content object, it's treated as a
         different object which results the focus deadlock. So, every
         time whenever focus sets on item content object, we need to
         unset and set the focus on genlist object. Thanks to Seoz for
         the idea.

Test Plan: elementary_test -to "genlist focus"

Reviewers: seoz, SanghyeonLee, eagleeye

CC: seoz

Differential Revision: https://phab.enlightenment.org/D891
2014-05-26 15:45:54 +09:00
Daniel Juyung Seo a64e8eed91 focus: update the focus in_theme status on each item's focus set.
As widget and widget item can have different in_theme value (since
 30cada369), we need to update in_theme value whenever the widget or
widget item get the focus.

Applied this logic to genlist, gengrid, toolbar first.
List focus is not working well at the moment.

This fixes small focus highlight on the left top corner of genlist
when the genlist scroller is clicked before the genlist is focused.

Special thanks to zmike for the report.
2014-05-12 01:25:43 +09:00
Daniel Juyung Seo 45e8b4c82e focus: Change new API names related to focus auto scrolling.
elm_config_focus_auto_scroll_bring_in_enabled_get/set()
 ->
elm_config_focus_autoscroll_mode_get/set()

The main reason is that bring_in_enabled_get/set() APIs are too restricted
and thus not flexible. I got more requirements for the focus autoscrolling
such as none, wholely visible not just bring_in and show. So it is correct
to add mode_set/get() APIs for the focus auto scrolling.

Thanks god, we've found this before the release :)

@feature
2014-05-11 22:46:16 +09:00
Daniel Juyung Seo 4f8614e866 Revert "remove all scrolling changes for focused items."
This reverts commit 377179bdaf84aa1a86621cdfa64ed43613ab9d45.

The main claim of https://phab.enlightenment.org/T1205 was fixed in
the previous commit 30cada369. This code will be modifed again in the
next commit due to the api change during development life cycle.

Note: do not blindly revert this commit if you have any problem with
widget item focus. This commit is not related to any fundamental cause
of the issues. If you have a problem, please contact me first.

seojuyung2@gmail.com or SeoZ on IRC.

Thanks.
2014-05-11 22:42:15 +09:00
Daniel Juyung Seo dfead75366 gengrid/genlist/list/toolbar: Do not set the focus to the item on widget's first focus.
This was introduced during 1.10 development phase but this changed the
default focus behavior and got a lot of complaints. (especially from
discomfitor)

So I would like to comment this out now and make it optional on 1.11
by keeping the default behavior.
2014-05-11 21:21:51 +09:00
Daniel Juyung Seo 8ffbf246f4 elm: fixed trivial formattings.
Just found them while reading codes.
2014-05-10 23:44:27 +09:00
Daniel Juyung Seo af92b3e6f9 elm: call elm_widget_item_del instead of elm_object_item_del inside elementary.
This reduces only one more function call but this makes the elm code
more consistent between widgets.
2014-05-10 23:44:27 +09:00
Anil Kumar Nahak 9d1813f7ee genlist/gengrid: Use pan object geometry for focus highlight calculation
Summary: Genlist/gengrid object geometry was used before this patch but using the pan object geometry is more correct. This can be reproduced when the size of "elm.swallow.content" part is smaller then the size of scroller object, focus animtaion on items is jerky.

Reviewers: raster, seoz, singh.amitesh

CC: nirajkr

Differential Revision: https://phab.enlightenment.org/D818
2014-05-10 01:07:58 +09:00
zmike fe4fae4954 Revert "Revert "focus: Removed unused parameter from an internal focus function.""
This reverts commit b8549f3e83a8592145a50085182583adead2c74e.

this build system is bad and whoever did the eo integration should not feel pleased with themselves.
2014-05-07 01:13:19 -04:00
zmike 54eabd94e2 Revert "focus: Removed unused parameter from an internal focus function."
This reverts commit 5832b692aa5f68a2924bd7886390d489eb13aefb.

broke build
2014-05-07 01:08:04 -04:00
zmike be636e58be remove all scrolling changes for focused items.
this.is.BROOOOOOOOOOOOOOOKEEEEEEEEEEEEEEEEEEENNNNNNNNNNNNNNNNNNNNNNNNNNNNN.

SERIOUSLY.

you cannot go scrolling all over the place in every widget that has a scroller just because the widget gets focus. what user wants that? no user anywhere, under any circumstances, ever, in all of history.

if you dare to put this back in, I will continue to remove it for the rest of eternity until it never, ever scrolls in any unwanted case. the focused item doesn't have to always be in the viewport, and should never be moved into the viewport [[[[[[[ except to maintain an already-existing position inside the viewport ]]]]]]]

too much of my time wasted on this stupid "feature" which should have been MUCH more thoroughly tested and reviewed before it was merged.

T1205 STILL NOT FIXED
2014-05-07 01:06:30 -04:00
Daniel Juyung Seo d0380e3342 focus: Removed unused parameter from an internal focus function.
is_next parameter is not used for
elm_widget_focus_highlight_geometry_get() function.
But this parameter was not cleaned up in the commit 5320cca.
2014-05-07 00:05:07 +09:00
Daniel Juyung Seo d4aa2ccc08 genlist: refactor the internal code to make it more readable. 2014-04-27 12:55:58 +09:00
Amitesh Singh 8405b15b2b genlist: Implemented item_select_on_focus feature.
Summary: @feature

Test Plan: elementary_test->Genlist Focus

Reviewers: seoz, raster

CC: seoz

Differential Revision: https://phab.enlightenment.org/D705
2014-04-27 12:40:17 +09:00
Daniel Juyung Seo 9652839c96 genlist: renamed internal function according to the key binding adoption. 2014-04-27 11:26:53 +09:00
Amitesh Singh 8e0ffb8332 config: Added two APIs to enable/disable focus auto scroll bring in feature.
Summary:
 Summary:
    - APIs
      - elm_config_focus_auto_scroll_bring_in_enabled_set
      - elm_config_focus_auto_scroll_bring_in_enabled_get
    - list/genlist/toolbar/gengrid: Using this feature for scrolling for focus movement.
    - Added test case in "List Focus", "Genlist Focus", "Toolbar Focus" and "Gengrid Focus"

    @feature

Test Plan: elementary_test->"List Focus", "Genlist Focus", "Toolbar Focus" & "Gengrid Focus".

Reviewers: raster, seoz

CC: seoz

Differential Revision: https://phab.enlightenment.org/D799
2014-04-27 04:15:26 +09:00
Daniel Juyung Seo 571b60e298 genlist: Removed unnecessary item show call on multi select.
item select will automatically trigger item show.
@fix
2014-04-27 03:02:58 +09:00
Hosang Kim 0f636e890a genlist: Add item loop feature
Summary:
If item loop feature is enabled, item is moved infinitely.

    1. Refactor direction key event handling routine
      - added internal function _elm_genlist_elm_widget_event_direction.
    2. Add looping feature for genlist
      - added Eolian function _elm_genlist_elm_widget_item_loop_enabled_set/get.
    3. Add demo - test_genlist.c / genlist focus

Reviewers: seoz, woohyun, jaehwan, Hermet, raster

Reviewed By: Hermet

Differential Revision: https://phab.enlightenment.org/D778

Conflicts:

	src/lib/elm_widget_genlist.h
2014-04-24 14:17:35 +09:00
Daniel Zaoui d2484d08d5 Genlist: fix EO errors.
Elm-Widget function was called on non elm-widget objects.
2014-04-23 11:00:50 +03:00
Daniel Juyung Seo b173ed7c85 genlist/gengrid/list: Fix first on_focus call correctly by checking focus highlight.
First on_focus call should consider focus highlight enable status and
do the different job according to that.

This can be tested in "genlist 7" and "genlist focus" examples in
elementary_test.
2014-04-22 23:18:04 +09:00
Carsten Haitzler 9d55fab418 entry: wrong viewport value calculation issue fix
Summary:
Issue: As entire scroller edje co-ordinates was being taken instead of the actual viewport value,
if in scroller edje more parts are added apart from just "elm.swallow.content", then the viewport value
set will be wrong. hence the selection handlers will not hide when they have to hide.

solution: Instead of taking scroller edje's geometry, get the actual viewport values.
To get viewport x,y a new scrollable interface is also added.

signed-off by: Shilpa Singh <shilpa.singh@samsung.com>

@fix

Test Plan: Selection handlers have to hide correctly when the text is scrolled in a scrolled entry, if the scroller edc of entry has more parts added other than elm.swallow.content, then when we scroll the selection handlers are not hidden correctly.

Reviewers: jaehwan, woohyun, seoz, Hermet, raster

CC: govi, rajeshps, thiepha

Differential Revision: https://phab.enlightenment.org/D674
2014-04-21 12:31:49 +09:00
Jaeun Choi fc491c7c6c genlist: apply key binding
Summary: This patch applies key binding to elm_genlist.

Test Plan: None

Reviewers: Hermet, raster

Reviewed By: raster

Differential Revision: https://phab.enlightenment.org/D743
2014-04-16 17:29:16 +09:00
ChunEon Park 5ab6a7739f widgets - don't handle the events(key,mouse) if the object is disabled.
we can prevent to handle the widget events from the widget infra,
if the object is disabled.

conceptually, disabled object should not be interacted to user input(key, mouse)
2014-04-16 10:59:43 +09:00
Tom Hacohen e15f80074e genlist: Adjusted to Eo2. 2014-04-10 09:35:00 +01:00
Mike Blumenkrantz 8fba6f77e9 genlist event_block_rect needs a smart parent to reduce BITCH 2014-04-08 16:23:07 -04:00
Amitesh Singh 1479664ec0 list/genlist/gengrid/toolbar: Fix - _nearest_visible_item_get() should always return an item.
Test Plan:
Bug:
- elementary_test->genlist/list/toolbar/gengrid Focus
- Resize the window to a state when no item is fully visible. only partially visible.
- Move Focus from outer widgets (Up/Down/Left/right buttons) to list/genlist/gengrid/toolbar.
- Focus goes away (size - 0). Reason: _nearest_visible_item_get returns NULL.

@fix

Reviewers: seoz, raster, woohyun

Reviewed By: raster

CC: seoz, nirajkr, anand.km

Differential Revision: https://phab.enlightenment.org/D696
2014-04-04 12:04:04 +09:00
Amitesh Singh daee26de35 genlist: Added focus movement on widget items by mouse in.
Summary: @feature

Test Plan: elementary_test->Genlist Focus

Reviewers: raster, cedric, woohyun

Reviewed By: raster

CC: seoz

Differential Revision: https://phab.enlightenment.org/D663
2014-04-01 20:25:03 +09:00
Daniel Zaoui 2bc08afc83 Eolian: Integration of Genlist and Genlist Pan 2014-04-01 13:55:42 +03:00
zmike de67ce137d genlist no longer randomly selects items (or scrolls to them after selecting)
this item focus thing is a giant bug nightmare and needed to be developed/tested much more thoroughly in a branch before being committed to master.
2014-03-30 23:20:04 -04:00
Daniel Juyung Seo dcdd697c70 genlist: Check disabled status of an item in nearest visible item.
Also added a test for it.
2014-03-24 02:07:41 +09:00
Amitesh Singh d37c8dccb1 genlist: removed printf from commit. b72db5c19
Reviewers: seoz

Reviewed By: seoz

CC: seoz

Differential Revision: https://phab.enlightenment.org/D652
2014-03-24 01:20:46 +09:00
Daniel Juyung Seo 1f319f3e2d genlist: Fixed item multi/single selection routine to skip disabled item
correctly.

@fix
2014-03-24 00:49:06 +09:00
zmike ea088ab21f genlist no longer crashes if a selected item is deleted during deselect_all 2014-03-23 10:39:47 -04:00
Daniel Juyung Seo 7f0f50fbc6 list/genlist/gengrid: Internal refactoring of item_focused/unfocused
codes.

- Added a check for focus highlight enable status before calling focus
signal to edje.
- Used obj instead of WIDGET(it) because that is used many times.
2014-03-23 23:29:16 +09:00
Daniel Juyung Seo 32cd38f89d genlist: Fixed focus object hidden bug on re-focus.
On smart_on_focus, genlist calls elm_object_item_focus_set. That API
internally calls _elm_widget_focus_highlight_start() but we need to call
this function once again because of the weird focus behavior.

Condition: enable focus highlight and focus highlight animation.
The first _elm_widget_focus_highlight_start() triggers
_elm_win_focus_highlight_simple_setup, and second call triggers
_elm_win_focus_highlight_anim_setup. But the first call does not show
the focus highlight object properly.

Reproduction scenario:
1. elementary_test -> genlist focus
2. click an item
3. scroll the genlist and move the focused item away from the viewport.
4. move the mouse pointer to another window
5. move the mouse pointer to the genlist window back again.
6. focus highlight object is now shown correctly.

By the way, this bug will be hidden when the focus highlight never
scrolls away. I will add this feature soon.
2014-03-23 21:37:55 +09:00
Daniel Juyung Seo 1343551e2a genlist: Fixed typo for _elm_genlist_nearest_visible_item_get comments. 2014-03-23 19:14:18 +09:00
Daniel Juyung Seo fad3a2dfc4 list/genlist/gengrid: Handle on_focus event on focus set only for key
event.

When you use mouse(touch) that triggers mouse up event, the
focus/selection movement is done by mouse up callback, so don't need to
handle on_focus event when mouse(touch) is used.

You can reproduce the bug by the following step.
1. launch elementary_test -> list focus, genlist focus, gengrid focus
2. focus an item (by touch, by key)
3. move focus to left button (by touch, by key)
4. click an another item (by touch)
5. previously focused item will be unfocused again even it was unfocused
at step #3/

Special thanks to Amitesh for the report.
2014-03-23 16:48:10 +09:00
zmike 5b07498ba1 genlist needs to iterate exactly once over a fixed list when deselcting all items
the selected items list can be modified during deselect from the smart callback, which can cause an infinite loop here

@fix
2014-03-23 03:11:14 -04:00
Daniel Juyung Seo 8129ae20ec genlist: Fixed broken genlist item focus support.
Now it works so much better than before.
- Fixed the separate behavior between selected item and focused item.
- Fixed wrong focus set when genlist is focused first time by mouse.
- Fixed wrong scroll movement when the focus highlight is disabled.
- Item selection sets that item focused. So when an item is selected, do
not need to set the focus again.
- Fixed wrong call for _elm_genlist_item_content_focus_set on deleted
item.
2014-03-22 23:51:44 +09:00
Daniel Juyung Seo 27f98b1e01 genlist/gengrid: Used item callback infrastructure. 2014-03-22 19:10:27 +09:00
Daniel Juyung Seo 65c948ca93 list/genlist/gengrid: Call item_show not bring_in on focus.
Elm 1.9 does item_show not bring_in so let's keep the consistency. I
will make this optional later.
2014-03-22 18:38:00 +09:00
Daniel Juyung Seo 9dd3112f15 genlist: Fixed annoying autoscrolling bug in genlist item focus.
Now, genlist does not autoscroll to last focused/selected item when the genlist
is focused. It tries to find the nearest visible item instead of the
last focused/selected item.
2014-03-19 00:48:07 +09:00
Daniel Juyung Seo 1c5f5ade61 list/genlist: Fixed Home and End key event handling routine.
Move focus and selection when Home or End key is pressed.

@fix
This needs a partial backport to elementary-1.9
2014-03-18 19:14:39 +09:00
Daniel Juyung Seo c08c20aac3 Revert "genlist no longer scrolls crazily"
This reverts commit 7a653914ad048c00871d2ef71a56185e5a7fb1ca.

I will fix this in another way.
2014-03-18 19:05:24 +09:00
Daniel Juyung Seo 699b01bcb2 Revert "genlist now uses uniform item showing behavior when selecting items with keyboard"
This reverts commit 85332555e8d3e5b981cde10ba9a1675ef6a4936e.

I will fix this in another way.
2014-03-18 19:05:24 +09:00
Daniel Zaoui 7460467419 Eolian: Integration of Scrollable Interface 2014-03-18 08:14:44 +02:00
Daniel Zaoui 8c29f2a77b Focus: fix segfault due to bad call to Eo function.
Due to Eolian auto-generation, legacy parameters are directly
transferred to Eo functions without conversion.

In this case, is_next was Eina_Bool in legacy and Eina_Bool * in Eo.
The logic code was expecting a pointer but was receiving a Eina_Bool.

The fix consists in giving the logic code the Eina_Bool instead of the
pointer.

@fix
2014-03-18 08:14:44 +02:00
Mike Blumenkrantz 05a1bd01d9 genlist now uses uniform item showing behavior when selecting items with keyboard 2014-03-17 14:57:07 -04:00
Mike Blumenkrantz f04c347985 genlist no longer scrolls crazily
fix T1090
2014-03-17 13:25:06 -04:00
Daniel Zaoui e2206a1a22 Eolian: Integration of Elm Widget 2014-03-17 09:03:56 +02:00
nirajkr be6f406e54 elm_genlist: Handle prev_focused_item if it get deleted
Summary:
Assign the prev_focused_item to NULL it get deleted

Reviewers: seoz, raster

Differential Revision: https://phab.enlightenment.org/D635
2014-03-16 02:35:13 +09:00
zmike 91a9805bc4 genlist shouldn't try to focus an item when it has no items 2014-03-14 13:55:11 -04:00
Daniel Juyung Seo cdb21fd556 genlist: Initialized local variables and removed unnecessary local
variable.

This fixes coverity CID 1191580 ~ 1191583
2014-03-09 19:36:17 +09:00
Daniel Juyung Seo 0a31f91b20 genlist: Refactor event_block_rect handling routine.
- Changed wrong name alpha_bg to event_block_rect.
- Added more comments to the smart data variable.
- Changed wrong function name _tray_alpha_bg_create to
_event_block_rect_update.
2014-03-09 04:48:21 +09:00
Daniel Juyung Seo e25fbe9768 genlist: Internal refactoring for the code readability.
Added one more internal variable to reduce unnecessary pointer
redirection too much.
Elm_Genlist_Smart_Data *sd is used many times in those functions but it
was always redirected from psd->wsd. I just cut down the step and made
the code more readable and consistent with other lines of code.

psd->wsd --> sd
2014-03-09 04:48:12 +09:00
Daniel Juyung Seo e60e43f8f5 list/genlist/gengrid: Clear some internal variables when an item is deleted.
Set last_selected_item, last_focused_item, focused_item to NULL when the
item is deleted.
For genlist and gengrid, clear them in del_not_serious.
2014-03-09 02:57:09 +09:00
Daniel Juyung Seo 80a3eea785 genlist: Removed trailing whitespaces from the previous Niraj's commit.
I aimed to merge this commit to the previous commit but I made git
amend mistake... :(
2014-03-09 02:48:34 +09:00
nirajkr e014fe92f4 genlist: Implemented the item focus support in genlist
Summary:
Implemented the following function
          1. _item_unfocused
          2. _item_focused
          3. _item_focus_up
          4. _item_focus_down
          5. _item_focus_left : Currently this function return EINA_FALSE. It means focus will move out of genlist to the another left widget
          6. _item_focus_right : Currently this function return EINA_FALSE. It means focus will move out of genlist to the right widget
          7. _item_focus_set_hook
          8. _item_focus_get_hook
          9. _elm_genlist_focus_highlight_geometry_get
          10. _elm_genlist_focused_item_get
          11. Changes in the smart_event, smart_on_focus, pan_smart_calculate, mouse up callback.
              Currently selected/focus logic are both present in the smart_event function and its
              will be separate out.

Reviewers: seoz, woohyun

CC: singh.amitesh

Differential Revision: https://phab.enlightenment.org/D558

Conflicts:

	src/lib/elm_genlist.c
2014-03-09 01:55:40 +09:00
Daniel Juyung Seo d626f9278f genlist/list: Fixed wrong internal function name.
_list/genlist_item_focus_set --> _list/genlist_item_content_focus_set.
These internal functions set the focus to the item's content objects,
 not the item itself. So the name was wrong and very confusing.
2014-03-08 03:27:09 +09:00
zmike f3f83a64fd @fix homogeneous genlist recalc on theme change
fix T1023
2014-03-02 15:04:07 -05:00
Daniel Juyung Seo 1a29ad5679 elm: removing trailing white space ceremony for 1.9 release. 2014-03-02 00:52:26 +09:00
Andy Williams 6e71ec05f7 Revert "oops, a mistake in T966 fix that could cause a segv"
This reverts commit b7d1cb531d1e196dee5f93dd4457e68df2692ed3.
2014-02-22 12:40:20 +00:00
Andy Williams a5f38fe810 oops, a mistake in T966 fix that could cause a segv 2014-02-19 18:32:58 +00:00
Andy Williams 72191ab692 Fix T966, sort order of child folders.
Comparison was being incorrectly applied for child elements - they need to be treated differently if there are no siblings
2014-02-19 10:30:50 +00:00
Andy Williams d1534e4aa9 Fix issue where items added into tree with more than 2 levels could be rendered at the wrong location in the list.
Fix this by ensuring items are attached after all items below the current node rather than only below those at the current level of children
2014-02-15 20:23:18 +00:00
zmike 7899534662 +elm_genlist_item_subitems_get() 2014-02-08 16:03:25 -05:00
zmike a3ff700982 +genlist_item_subitems_count()
group apis are currently pretty lacking. there should probably be functions for iterating over subitems in addition to this one
2014-02-08 01:16:06 -05:00
Jaehwan Kim db23689614 access: Add smart signal "access,changed"
It occurs that access mode is changed.
Application can add this callback for each widget.
2014-02-08 14:05:14 +09:00
WooHyun Jung 0a1179dde4 elm_layout now supports focused/unfocused smart callback
by itself for widgets that inherit layout class.
If it uses elm_widget's, smart callback will be called at the
beginning or smart_on_focus function.
2014-02-06 16:18:57 +09:00
ChunEon Park dbacb2fef9 elementary - send signal "language,changed" with one way in the widget.
Call the smart callback in the widget infra so that each widget don't need to hook the smart_translate only for the smart call.

This makes reducing duplicated code and supporting language,chagned from all widgets.
2014-01-23 19:30:34 +09:00
ChunEon Park aebdcff513 elementary - use the focused/unfocused string in widget defined.
Now, it will share the strings so that reduce the binary size also user uses it in one way.
2014-01-23 17:27:17 +09:00
Daniel Juyung Seo 0d1ac0fa05 elm: Removed unnecessary null check for eina_list_free. 2014-01-22 10:55:01 +09:00
Daniel Juyung Seo db5fe2581d elm: Removed unnecessary null check for evas_object_del. 2014-01-22 10:54:52 +09:00
Daniel Juyung Seo 43533a2fb9 elm: Removed unnecessary null check for eina_stringshare_del. 2014-01-22 10:54:45 +09:00
Daniel Juyung Seo c066009c49 elm: Removed unnecessary null check for ecore_idler_del, ecore_idle_enterer_del. 2014-01-22 10:54:28 +09:00
Daniel Juyung Seo a4f3074f9c elm: Removed unnecessary null check for ecore_timer_del,
ecore_animator_del, and ecore_job_del.

As all efl public free apis get null as valid parameter, we do not need
to check null. I also removed some null check for other free apis which
were right next to timer/animator/job del. After this job code got
cleaner.
2014-01-21 23:18:16 +09:00
Yakov Goldberg 3379c124df all widgets: change Eo API for "elm_widget_theme()" to "theme_apply"
There are elm_widget_theme/theme_set/theme_get functions.
    In Eolian these functions will be described as "theme" method and
    "theme" property. There is clash here.
    So add suffix "_apply" to Eo API for "elm_widget_theme".
2014-01-21 11:08:29 +02:00
Ryuan Choi 23bebb1c47 genlist: Check return value out of the loop in _realized_items_get 2014-01-13 17:34:36 +09:00
Daniel Juyung Seo a7a8b257c2 gengrid, genlist: Fallback into default item style if the required item
style does not exist.
2014-01-08 19:07:56 +09:00
Daniel Juyung Seo fd5c046dfe elm: Changed __UNUSED__ to EINA_UNUSED. 2014-01-06 23:33:57 +09:00
Daniel Juyung Seo 16f687b87a multibuttonentry, genlist, layout, toolbar: Fixed dereference of null
pointers which were reported by clang builg.

https://build.enlightenment.org/job/nightly_elm_clang_x86_64/lastSuccessfulBuild/artifact/scan-build/build/2014-01-05-1/report-XZo1hW.html#EndPath
https://build.enlightenment.org/job/nightly_elm_clang_x86_64/lastSuccessfulBuild/artifact/scan-build/build/2014-01-05-1/report-isAlRt.html#EndPath
https://build.enlightenment.org/job/nightly_elm_clang_x86_64/lastSuccessfulBuild/artifact/scan-build/build/2014-01-05-1/report-8Ascv8.html#EndPath
https://build.enlightenment.org/job/nightly_elm_clang_x86_64/lastSuccessfulBuild/artifact/scan-build/build/2014-01-05-1/report-gBkVuE.html#EndPath
2014-01-06 23:26:46 +09:00
Chinmaya Panigrahi e4cbf1bcfb [Genlist]: Added NULL check
Summary: Added NULL check

Test Plan: elementary_test -to genlist

Reviewers: seoz, singh.amitesh, raster

Reviewed By: raster

Differential Revision: https://phab.enlightenment.org/D432
2014-01-01 14:11:50 +09:00
Daniel Juyung Seo e63dd3110a elm: Unified eina critical manro to CRI.
Being annoyed by different types of eina critical macros - CRI, CRIT,
 CRITICAL -, I concluded to unify them to one. Discussed on IRC and
 finally, CRI was chosen to meet the consistency with other macros -
 ERR, WRN, INF, DBG - in terms of the number of characters.
If there is any missing bits, please let me know.
2013-12-26 13:03:55 +09:00
discomfitor ba5823f188 bugfix: unset genlist mincalcd flag when changing to/from having no item contents
not backporting because not sure if correct, but definitely a bug

also there's a similar issue where objects (I'm looking at you, elm_list) don't size until the first render, which causes the initial genlist calc sizes to be 100% wrong every time
2013-12-16 14:15:29 -05:00
Daniel Juyung Seo 6d71a23c3a elm lib: removed all the unnecessary empty lines.
being pedantic.
2013-12-15 06:18:35 +09:00
Viacheslav Lvov 332cdd1e7c genlist - don't do heavy queue work for 0 width genlists and defer fill
Scenario:
1. Create elm_genlist.
2. Add some items to it.
3. Do not resize the genlist and leave it with width == 0.

PROPOSAL:
1. When the element is queued for recalculation check current width of
widget. If it is equal to 0 do not add idle enterer.
2. In smart callback on resize check if queue of items that need
recalculation is not empty and new width is not 0. In this situation
add idle enterer.
2013-12-06 16:08:09 +09:00
Daniel Juyung Seo 8a0159df4f elm: long waited seasonal trailing whitespaces removal!
This is a ceremony of elementary 1.8 release!
2013-12-02 19:43:46 +09:00
Daniel Juyung Seo 9efa212975 elm_genlist.c: return "elm.swallow.icon" part's object when the part parameter is null on _item_content_get_hook().
Now elm_object_item_content_get() works fine.
+ avoid ambiguous if-else statement by using braces.
2013-11-30 18:28:47 +09:00
Daniel Juyung Seo 00bd27a883 elm_genlist.c: return "elm.text" part's text when the part parameter is null on _item_text_get_hook().
Now elm_object_item_text_get() works fine.
2013-11-30 17:02:24 +09:00
nirajkr 98b0383451 elm_genlist.c: Fix to decorate the item if it is set
Summary: Changes in the _item_realize to decorate the item T576 test_genlist10

Reviewers: seoz, singh.amitesh

Differential Revision: https://phab.enlightenment.org/D358
2013-11-29 19:18:00 +09:00
Gustavo Sverzut Barbieri 085e644c49 genlist: clear 'rel' pointer when it becomes unused during del_pre_hook.
If we're walking an item and it's deleted, the memory won't go away
immediately in _item_del_pre_hook() as would in _item_del(), then it's
not enough to remove ourselves from the reverse-relative list of the
item we were relative to, we also need to clean our own relative
pointer so we won't touch it later when the item is not being walked
anymore and _item_del() is called.

I was getting this annoying error with espionage application, opening
an interface of an object and then closing the window or selecting
another bus name (whatever would call elm_genlist_clear()).

During the clear process genlist will flag the next item as "walking"
so it's not gone when the current item dies (would happen if next item
is a subitem). The item would run _item_del_pre_hook() but not
_item_del(), but on the next loop iteration the next item would be the
current, then not walking anymore and during _item_del() it would
access it->item->rel which would point to the now-dead item.
2013-11-28 20:42:16 -02:00
Carsten Haitzler f6b66cc1d3 genlist - fix show item if list manipulation changes shown item position
this fixes T38 - it's a bit brute force but the only way i can think
of that is not too invasive before release.
2013-11-28 16:36:55 +09:00
Jihoon Kim 9e99a7f579 fix typos in doxygen and comments 2013-11-22 11:06:37 +09:00
Carsten Haitzler 872d21341e genlist - fix queue processor to not account for entire loop run in time 2013-11-19 15:10:03 +09:00
Tom Hacohen 4c8d03894c Changed Eo class names to be consistent. #2
All the class names are now of the format: Elm_Type_Subtype_Extra

Thanks to Yakov for pointing out I forgot a few and for giving me a nice
list.
2013-11-07 14:30:22 +00:00
Tom Hacohen 2f1e1554e5 Changed Eo class names to be consistent.
All the class names are now of the format: Elm_Type_Subtype_Extra
2013-11-07 11:44:22 +00:00
Daniel Juyung Seo 9509986a05 gengrid/genlist: added Eo compatibles for elm_genlist/gengrid_multi_select_mode_set/get() APIs. 2013-11-04 01:15:58 +09:00
Daniel Juyung Seo 6a0f47d120 Genlist/Gengrid: Added multi select mode for genlist/gengrid.
elm_genlist_multi_select_mode_set/get()
elm_gengrid_multi_select_mode_set/get()
2013-11-03 23:58:57 +09:00
Ryuan Choi 5836a25bc8 genlist, gengrid: Add ELM_OBJECT_MULTIPLE_SELECT_MODE_WITH_CONTROL
Summary:
Some applications like file viewer allow multiple selection only with
Control key was pressed.

Reviewers: seoz, raster

Reviewed By: raster

Differential Revision: https://phab.enlightenment.org/D251

Conflicts:
	ChangeLog
	NEWS
2013-11-02 20:53:43 +09:00
Daniel Juyung Seo d22076681b elm: Fixed formatting about smart_event check for code consistency.
- Made it look clearer.
- Removed unnecessary local variables.
- Keep the code sequence consistent.
2013-10-28 23:30:12 +09:00
Carsten Haitzler 95fdc9cc88 fix up namespace for many signal while keeping old versions for compat 2013-10-05 21:35:27 +09:00
Daniel Juyung Seo a2c704d613 elm_genlist.c: adopted ELM_WIDGET_DATA_GET_OR_RETURN macro. 2013-10-05 17:14:25 +09:00
Carsten Haitzler 0aed5eb970 genlist - fix homogenouse mode after previous fix to stop realizing all 2013-10-04 15:00:26 +09:00
Carsten Haitzler 6641cc792e genlist - fix homogenous to NOT go (un)realizing every item on queue 2013-10-01 12:54:28 +09:00
Daniel Juyung Seo e756f97dae elm: Longwaited trailing white space removal. Clean elm up! 2013-09-30 22:15:01 +09:00
Cedric Bail 29af5e1e43 elementary: update to new eo_parent_get/set API. 2013-09-25 13:34:27 +09:00
ChunEon Park a7b11a4c56 elementary/genlist,gengrid - should be cancel the track object before item view is removed. 2013-09-13 16:20:40 +09:00
ChunEon Park f426e08982 elementary/elm_object_item - delete the track objects when genlist/gengrid items are unrealized. 2013-09-13 14:19:41 +09:00
Daniel Zaoui 9cb42442f8 Genlist: fix memory not freed when item is expanded.
Thanks to TaeHwan Kim for the fix.
2013-09-09 10:14:14 +03:00
Daniel Juyung Seo 745488fff3 genlist/gengrid: use spacer when item edc supports elm.swallow.pad part. 2013-09-06 13:08:21 +09:00
Daniel Juyung Seo ce2df375b2 elm_genlist.c: use more ELM_SAFE_FREE. 2013-09-06 13:00:42 +09:00
ChunEon Park fe0f0a445e elementary/widgets - set parents before widget constructs their body.
This avoids unnecessary setups again when obj <-> sub has connected.
2013-08-27 00:29:45 +09:00
Gustavo Sverzut Barbieri 19b55ddc65 genlist: implement list position signals.
Genlist will now emit the following signals to item view related to
their position in the whole list:
      - elm,state,list,first: first item of the whole list
      - elm,state,list,last: last item of the whole list
      - elm,state,list,middle: any item that is not first or last.
      - elm,state,list,single: when the item is the only element of list.
And the following related to a group (considering its given 'parent'):
      - elm,state,group,first: first item of the group
      - elm,state,group,last: last item of the group
      - elm,state,group,middle: any item that is not first or last.
      - elm,state,group,single: when the item is the only element of group.

Unlike odd/even the signals have an extra namespace "list" or "group"
to avoid conflicts with applications that may have declared these
signals themselves for other purposes.

With this patch one can implement easily something like this:

         https://developer.apple.com/library/ios/documentation/userexperience/conceptual/tableview_iphone/Art/tv_grouped_style.jpg
2013-08-22 17:02:49 -03:00
Gustavo Sverzut Barbieri 1bba4c94d3 genlist: rename even_odd_update to more generic name.
The next patch will also send signals to say if it's the first, middle
or last item and also for group, thus using a more generic name will
help.
2013-08-22 17:02:49 -03:00
Daniel Juyung Seo c5b0d63838 fixed documentation for consistency. Gets -> Get.
Occurance of Get is super much higher than Gets.
So change Gets to Get for consistency.
2013-08-22 05:24:46 +09:00
Carsten Haitzler 59e8bc5a35 Fix elm to use key not keyname (so xmodmap works) 2013-07-31 15:16:41 +09:00
Shinwoo Kim c47ef1b7fe [access] use proper name _elm_access_info_get(); not _elm_access_object_get(); to get access information 2013-07-31 12:57:49 +09:00
Ryuan Choi 477c38cdd8 elm, genlist: Introduce ELM_PRIV_STATIC_VARIABLE_DECLARE and ELM_PRIV_SMART_CALLBACKS_DESC
This can reduce human mistakes when adding new signals (and typing).

This is not all, I will work on adopting these macros for oter widgets.
2013-07-15 11:28:18 +09:00
Daniel Juyung Seo 23d6d17695 elm_genlist.c: refactoring. use correct parameters. 2013-07-06 13:00:39 +09:00
Daniel Juyung Seo d66e2ed136 elm_genlist.c: do not check null. it should not be a null and it was already dereferenced.
This fixes 'dereference before null check' issue which was spotted by coverity. CID 1040000.
2013-07-06 12:56:58 +09:00
Daniel Juyung Seo 14c7bf8039 elm_gengrid/genlist.c: removed logically dead code. NULL is already checked.
This fixes 'Logically dead code' warning which was spotted by coverity.
CID 1040038, 1040040, 1040036, 1040037.
2013-07-06 12:49:54 +09:00
Carsten Haitzler 651214b722 put a lot more hysterisis on drag detects in genlist... 2013-07-02 19:33:00 +09:00
Carsten Haitzler 153f5d9de2 genlist - fix some stacking issues when selecting items with group headers
stacking become a lot more complex when re-order mode was added, group
headers and more, so simple raise/lower wasn't enough, so this adds 2
stacking markers (rectangles) and objects are stacked above or below
these 2 markers. that basically provides 4 possible stacking slots
that are easy to address, and if you also still raise/lower you get 6
slots. use these markers for stacking so items go into a fixed
stacking layer when they stack around.
2013-06-23 15:17:39 +09:00
Daniel Juyung Seo 6cf684f02a elm: added more "focused" and "unfocused" documentations.
genlist, hover, index, list, map, photocam, progressbar, radio, scroller, slider, slideshow, spinner, toolbar, win.
2013-06-10 14:13:55 +09:00
Daniel Juyung Seo e533e0e9c8 elm_genlist.c: ELM_SAFE_FREE adoption.
I splited ELM_SAFE_FREE refactoring patches. One commit per each file as recommended.
For the detail, please refer 3072dab12f12fe83fb5a628d15efd5cded11787f.
2013-05-29 20:54:11 +09:00
Daniel Juyung Seo ef8701a173 elm: more ELM_FREE_FUNC cleanups. 2013-05-24 00:58:38 +09:00
Daniel Juyung Seo ac25946a19 elm: introduce ELM_FREE_FUNC for code quality enhancement.
There are pros and cons but this
1. reduces human mistakes.
2. enhances readability.
3. enhances code quality.
4. removes future bug.
5. was adopted from enlightenment.

This is not all. I will work on enhancing elementary more and more.
2013-05-22 02:24:02 +09:00
Ivan Briano 86b4ab8276 Process messages after using the state_get of genlist items
This allows to make these states change the minimum size of the item
without the list calculating everything wrong.
2013-05-16 19:28:17 -03:00
Yossi Kantor 2e1eacd0ba elementary: Focus improvement for elm_genlist and elm_list
Summary:
This patch applies automatic focus feature to elm_genlist and elm_list
containers.
Currently (prior to this patch), focusable widgets inside list items of both
containers receive focus by an explicit mouse click over them, and lose focus
when focus goes to someone else in the window.
This change also adds the ability to:
- focus by default on the first-from-right focusable widget upon items selection
- lose the focus when another item is selected (focused or not)
- move focus between focusable widgets inside the same item by left and right
arrow keys accordingly (up and down keys when elm_list is in horizontal mode)

Focus is supported for horizontal and vertical lists.

Tests have been added for genlists and lists to check focus feature.
2013-05-12 15:32:33 +03:00
Tae-Hwan Kim e6afe0c33d [Genlist] Fix bug when error abort is enabled. 2013-05-07 19:41:15 +09:00
Shinwoo Kim 4a568d2bff [access][genlist] do not append NULL to genlist focus list 2013-05-03 20:01:58 +09:00
Cedric Bail c929b33052 elementary: properly sanitize headers order. 2013-05-03 16:07:06 +09:00
Daniel Juyung Seo 2edf9256fc elm_genlist: refactoring. code clean up.
introduced ELM_GENLIST_DATA_GET_FROM_ITEM and made sources so much cleaner.
2013-05-03 03:14:37 +09:00