Commit Graph

85 Commits

Author SHA1 Message Date
Amitesh Singh 261d3319df spinner: don't allow dragging if widget is disabled
fixes T5569
2017-06-29 14:43:43 +09:00
Jean-Philippe Andre ed41adf791 widget: Implement mirrored from Efl.Ui.Base
Ref T5363
2017-06-14 11:02:05 +09:00
Carsten Haitzler a772c54757 elm spinner - handle more digits for format string + handle invalid fmt
handles format strings like %0.234567f even tho before it was just %2f
- single digit after . ... not that it's useful handling more...

@fix
2017-06-08 14:34:50 +09:00
Jean-Philippe Andre f767e8bea4 edje: Move part drag APIs to efl_part
This moves all part_drag APIs to legacy and implements them for
EO using efl_part(). All parts now support these APIs, even if
they are not draggable. Making this more fine grained would
probably be much extra work for little gain.

This creates a new interface Efl.Ui.Drag.
2017-05-31 15:41:20 +09:00
Woochan Lee 3cdd290f17 spinner: Add signal to notify the value of spinner has been reached at min, max.
Summary: The User requires this signal to handle spinner widget easily on their app.

Test Plan: Spinner test on elementary_test.

Reviewers: cedric, jpeg, Hermet, woohyun, Jaehyun, myoungwoon, Jaehyun_Cho

Reviewed By: myoungwoon, Jaehyun_Cho

Subscribers: myoungwoon, cedric, jpeg

Differential Revision: https://phab.enlightenment.org/D4886
2017-05-24 13:31:15 +09:00
Jean-Philippe Andre 55b529cebc evas/elm: Make group_add/group_del internal functions
This hides those two legacy functions from the EO API.
2017-05-19 14:07:00 +09:00
Amitesh Singh 9736dc6cf0 spinner: fix mem leak on focus next traversel
this patches fixes an eina list mem leak on each
focus next(tab/alt-tab) traversal.

@fix

Signed-off-by: Amitesh Singh <amitesh.sh@samsung.com>
2017-01-23 11:24:51 +05:30
Jee-Yong Um 6d0a2398ad Elm.Widget: rename "event.*" methods to solve name conflict
Summary:
Elm.Widget.event_callback_add conflicts with Efl.Object.event_callback_add.
To solve this problem, "widget_" prefix is added to methods starting with
"event".

Reviewers: cedric, jpeg

Differential Revision: https://phab.enlightenment.org/D4521
2017-01-03 10:59:49 +09:00
Carsten Haitzler 44a70ab98c Revert "spinner: call changed callback on value set."
This reverts commit 082ea96673.

As per mail from Andrii, and he's right:

From: Andrii Kroitor <an.kroitor@samsung.com>
To: Enlightenment developer list <enlightenment-devel@lists.sourceforge.net>
Subject: [E-devel] elementary callbacks hell
Date: Fri, 23 Dec 2016 18:03:58 +0200

Recently existing callbacks behavior was broken once again. This time by
https://git.enlightenment.org/core/efl.git/commit/?id=082ea9667343b7016d86143a625881a8c4aa30a4
Before that commit "changed" callback was triggered only on user
changes, after - on user changes and changes from code.
I understand that in some cases this flow is needed. But previously you
could simply trigger your callback after setting value to spinner from
code to get desired missing behavior.
On the other side - now you can't distinguish value changes made by code
from value changes made by user without dirty and painful to support
hacks. If you don't want your callback to be
triggered by elm_spinner_value_set you need to add some flag meaning
"change from code", raise it before every call of value_set, check it
inside callback, remove it after the call.
And if you want to call it from spinner "changed" callback..? Good luck
here. This is possible, but requires additional wrappers around
spinner_add and spinner_value_set and replacement with custom signals.

So this change added bigger problems than solved.
2016-12-24 09:50:23 +09:00
Jean-Philippe Andre a6b5765c3d spinner: Fix mouse wheel events
Fix invalid cast of event_info
2016-12-13 16:12:27 +09:00
Umesh Tanwar 082ea96673 spinner: call changed callback on value set.
Summary:
If user set spinner value other than it's
current value, this is change in value. So changed
callback must be called on value set.

@fix

Signed-off-by: Umesh Tanwar <umesh.tanwar@samsung.com>

Reviewers: raster, singh.amitesh, cedric, jpeg

Subscribers: atulfokk, cedric, jpeg

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

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2016-12-12 16:34:24 -08:00
Woochan Lee 1e4c44f025 elm_spinner: Spinner internal focus logic fixed to following new focused UI concept.
Summary:
The spinner entry will be activated when user gives a focus to text button in new focused ui concept.

To support this, we have to change internal logic about change text button to entry, entry to text button.

@fix

Test Plan:
elementary_test
spinner sample.

Reviewers: woohyun, Hermet

Subscribers: cedric, jpeg

Differential Revision: https://phab.enlightenment.org/D4475
2016-12-12 16:51:27 +09:00
WooHyun Jung bf21eceb48 elm_spinner: fix wrong focus logic when spinner is unfocused
When unfocusing spinner, entry's UNFOCUSED callback is called.
In the callback function, entry is hidden and spinner gets focus
from focus_revert logic.
This gave lots of meaningless focused/unfocused state changes.

@fix
2016-11-29 21:06:25 +09:00
Andrii Kroitor ef55640d2a elm_spinner: apply value after pressing enter key
This was broken previously by a659fe3484

@fix
2016-11-17 15:56:14 +02:00
Shinwoo Kim e648f1e85e [elementary][atspi] change accessible description to char* from const char*
Summary:
The accessible name is char*, this could confuse API user.
If we provide user callback to get description, an user would return allocated string.
The usage of elm_interface_atspi_description_get/set should be same with elm_interface_atspi_name_get/set

Reviewers: lukasz.stanislawski, cedric, raster

Reviewed By: raster

Subscribers: stanluk, jpeg

Differential Revision: https://phab.enlightenment.org/D4378
2016-11-10 11:11:48 +09:00
WooHyun Jung a659fe3484 elm_spinner: change the key event operation on spinner
Left/Right(or Up/Down with vertical one) changed the value of
spinner previously. However, it gave uneasy because focus could not be
moved to another winset until the value met the min or max.
Now, inc/dec button can get focus, and enter input on them change
the value.
Additionally, central text button changes to the entry automatically
when it gets focus. i.e. toggle on the text button is removed.

@fix
2016-10-22 12:03:54 +09:00
Tom Hacohen d5e321466e Efl object: Rename Eo_Event -> Efl_Event.
This is the last step of the Eo renaming efforts.
2016-08-30 13:34:10 +01:00
Vitor Sousa 8356b16a49 Efl Object: remove legacy callback calls from event_callback_call
Efl.Object.event_callback_call no longer calls legacy smart callbacks;
calling only event callbacks registered with the given event description
pointer.

Create the method Efl.Object.event_callback_legacy_call to inherit the old
behavior from Efl.Object.event_callback_call, calling both Efl.Object events
and legacy smart callbacks.

Update all other files accordingly in order to still supply legacy
callbacks while they are necessary.
2016-08-26 15:45:07 -03:00
Jean-Philippe Andre d504284dd2 efl: Rename Efl.Event.XX to Efl.Input.XX
This removes:
 Efl.Event interface

And renames:
 Efl.Event.Input -> Efl.Input.Event
 Efl.Event -> Efl.Input.Event (merged)
 Efl.Event.Pointer -> Efl.Input.Pointer
 Efl.Event.Key -> Efl.Input.Key
 Efl.Event.Hold -> Efl.Input.Hold

This also moves some interfaces from efl/ to evas/ where they
belong better.

This allows renaming Eo_Event to Efl_Event.
2016-08-26 10:18:01 +09:00
Tom Hacohen e65aae994e Eo: Finish the renaming of Eo to the EFL.
This renames all the rest of the API to the EFL namespace except for
Eo_Event that will follow soon.

Obviously breaks both API and ABI.
2016-08-15 15:07:42 +01:00
Tom Hacohen c662934be8 Change the EFL to follow the new Eo rename. 2016-08-11 17:04:43 +01:00
Woochan Lee 186d9938cd spinner: spinner entry reactivate when focus come again.
Summary:
When user edit spinner value on entry.
The user want to back on entry to edit spinner value even swiching view(focus out and focus in).

I considered a couple of exception case ( case that entry should not reactivate.)
1. User click spinner button to give focus.
2. User give focus to spinner's object using key action.

Test Plan:
Add sample in elementary_test.
Edit spinner value.
Gives focus to other window.
Back to spinner view.
See the action.

Reviewers: Hermet, woohyun, cedric, jpeg

Subscribers: cedric, jpeg

Differential Revision: https://phab.enlightenment.org/D4120
2016-07-04 19:55:53 +09:00
Jinyong Park 3271ec8d18 theme: return enum from elm_widget_style_set instead of bool
Summary:
if trying to apply incorrect theme, widget apply default theme and return TRUE.
so there is no way to check it really apply correct theme.
To resolve this problem, _elm_theme_set return three type enum

* related history : 4ca3ef4514
* elm_object_style_set is public api, so I didn't change it.
* typedef name [ Theme_Apply ] is temporarily, please suggest better one.

@fix

Reviewers: singh.amitesh, herb, Hermet, cedric, jpeg, raster

Subscribers: cedric, jpeg

Differential Revision: https://phab.enlightenment.org/D4073
2016-07-01 15:09:43 +09:00
Jean-Philippe Andre 7bf8da2baa evas: Rename Evas.Object to Efl.Canvas.Object
One step closer to make the EO inheritance tree look like
it's all Efl.
2016-06-21 14:35:19 +09:00
Tom Hacohen 6202cc7485 Adjust the code according to the eo event stop changes.
This was changed in the previous commit.
2016-06-20 18:02:00 +01:00
Jean-Philippe Andre 52f9220b3f Evas: Rename smart object into Efl.Canvas.Group 2016-06-17 19:32:43 +09:00
Jean-Philippe Andre 42b63f5507 Evas: Add smart_ prefix to all smart functions (eo)
This is a first step at separating legacy smart
object features away from standard efl interfaces.
2016-06-17 19:25:48 +09:00
Jean-Philippe Andre 9a052a740d Evas: Move smart_callbacks_descriptions to legacy 2016-06-17 19:25:47 +09:00
Jean-Philippe Andre 1e82603013 spinner: Remove usage of eo evas object event 2016-06-14 16:27:42 +09:00
Jean-Philippe Andre e691de04be Evas: Rename Clickable_Interface to Efl.Ui.Clickable
Event prefix is efl_ui:
 EFL_UI_EVENT_CLICKED
 EFL_UI_EVENT_CLICKED_DOUBLE
 ...

The event prefix could be reduced to efl but I personally
prefer with UI.
2016-06-10 17:33:53 +09:00
Cedric Bail 75a53ece10 eo: for consistency use object like all our API. 2016-05-18 08:18:04 -07:00
Yeshwanth Reddivari f7e1be2062 spin interface: common interface for flipselector and spinner
Summary:
Added common interface for flipselector and spinner.
Implemented APIs of spinner like min_max_set, step_set, value_set etc in flipselector.

Test Plan: elementary_test

Reviewers: raster, jpeg, singh.amitesh, woohyun, SanghyeonLee, cedric

Reviewed By: cedric

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

Signed-off-by: Cedric Bail <cedric@osg.samsung.com>
2016-04-29 18:56:51 -07:00
Stefan Schmidt 39eb3004f8 elm_spinner: free string in all cases before returning
If len < max_len was true here we leaked new_str. Make sure we also free it
in this case.

CID: 1353605
2016-04-18 16:01:21 +02:00
Tom Hacohen f14305024e Eo event: rename Eo_Event->event_info to Eo_Event->info.
The previous naming was redundant and too long.
2016-04-12 15:23:55 +01:00
Cedric BAIL c2a1c49ab2 elementary: move all legacy files to their expected new location. 2016-03-23 13:24:41 -07:00