2019-01-21 07:22:32 -08:00
|
|
|
class Elm.Flipselector extends Efl.Ui.Layout implements Efl.Ui.Range_Interactive,
|
2017-11-15 18:31:26 -08:00
|
|
|
Efl.Access.Widget.Action,
|
2019-01-18 05:22:23 -08:00
|
|
|
Efl.Ui.Selectable, Efl.Ui.Legacy
|
2014-03-30 00:34:05 -07:00
|
|
|
{
|
2016-11-21 04:56:47 -08:00
|
|
|
[[Elementary flipselector class]]
|
2016-05-12 09:06:04 -07:00
|
|
|
legacy_prefix: elm_flipselector;
|
2014-03-30 00:34:05 -07:00
|
|
|
eo_prefix: elm_obj_flipselector;
|
2016-05-17 09:14:47 -07:00
|
|
|
event_prefix: elm_flipselector;
|
2015-05-07 09:32:53 -07:00
|
|
|
methods {
|
|
|
|
@property items {
|
2014-03-30 00:34:05 -07:00
|
|
|
get {
|
2015-07-29 06:44:07 -07:00
|
|
|
[[Get the internal list of items in a given flip selector widget.
|
|
|
|
|
|
|
|
This list is not to be modified in any way and must not be
|
|
|
|
freed. Use the list members with functions like
|
|
|
|
\@ref elm_object_item_text_set,
|
|
|
|
\@ref elm_object_item_text_get,
|
|
|
|
\@ref elm_object_item_del,
|
|
|
|
\@ref elm_flipselector_item_selected_get,
|
|
|
|
\@ref elm_flipselector_item_selected_set.
|
|
|
|
|
|
|
|
Warning: This list is only valid until $obj object's internal
|
|
|
|
items list is changed. It should be fetched again with another
|
|
|
|
call to this function when changes happen.
|
|
|
|
]]
|
2016-11-21 04:56:47 -08:00
|
|
|
return: const(list<Elm.Widget.Item>); [[List of items]]
|
2014-03-30 00:34:05 -07:00
|
|
|
}
|
|
|
|
}
|
2015-05-07 09:32:53 -07:00
|
|
|
@property first_item {
|
2014-03-30 00:34:05 -07:00
|
|
|
get {
|
2015-07-29 06:44:07 -07:00
|
|
|
[[Get the first item in the given flip selector widget's list of
|
|
|
|
items.
|
2014-03-30 00:34:05 -07:00
|
|
|
|
2015-07-29 06:44:07 -07:00
|
|
|
See also @.item_append,
|
|
|
|
@.last_item.get.
|
|
|
|
]]
|
2016-05-23 07:41:28 -07:00
|
|
|
return: Elm.Widget.Item; [[The first item or $null, if it has no items (and on
|
2015-07-29 06:44:07 -07:00
|
|
|
errors).]]
|
2014-03-30 00:34:05 -07:00
|
|
|
|
|
|
|
}
|
|
|
|
}
|
2015-05-07 09:32:53 -07:00
|
|
|
@property last_item {
|
2014-03-30 00:34:05 -07:00
|
|
|
get {
|
2015-07-29 06:44:07 -07:00
|
|
|
[[Get the last item in the given flip selector widget's list of
|
|
|
|
items.
|
2014-03-30 00:34:05 -07:00
|
|
|
|
2015-07-29 06:44:07 -07:00
|
|
|
See also @.item_prepend,
|
|
|
|
@.first_item.get.
|
|
|
|
]]
|
2016-05-23 07:41:28 -07:00
|
|
|
return: Elm.Widget.Item; [[The last item or $null, if it has no items (and on
|
2015-07-29 06:44:07 -07:00
|
|
|
errors).]]
|
2014-03-30 00:34:05 -07:00
|
|
|
|
|
|
|
}
|
|
|
|
}
|
2015-05-07 09:32:53 -07:00
|
|
|
@property selected_item {
|
2014-03-30 00:34:05 -07:00
|
|
|
get {
|
2015-07-29 06:44:07 -07:00
|
|
|
[[Get the currently selected item in a flip selector widget.]]
|
2016-05-23 07:41:28 -07:00
|
|
|
return: Elm.Widget.Item; [[The selected item or $null, if the widget has no items
|
2015-07-29 06:44:07 -07:00
|
|
|
(and on errors).]]
|
2014-03-30 00:34:05 -07:00
|
|
|
|
|
|
|
}
|
|
|
|
}
|
2017-11-20 02:12:49 -08:00
|
|
|
@property first_interval {
|
|
|
|
set {
|
|
|
|
[[Set the interval on time updates for a user mouse button hold
|
|
|
|
on a flip selector widget.
|
|
|
|
|
|
|
|
This interval value is decreased while the user holds the
|
|
|
|
mouse pointer either flipping up or flipping down a given flip
|
|
|
|
selector.
|
|
|
|
|
|
|
|
This helps the user to get to a given item distant from the
|
|
|
|
current one easier/faster, as it will start to flip quicker and
|
|
|
|
quicker on mouse button holds.
|
|
|
|
|
|
|
|
The calculation for the next flip interval value, starting from
|
|
|
|
the one set with this call, is the previous interval divided by
|
|
|
|
1.05, so it decreases a little bit.
|
|
|
|
|
|
|
|
The default starting interval value for automatic flips is
|
|
|
|
0.85 seconds.
|
|
|
|
|
|
|
|
See also @.first_interval.get.
|
|
|
|
]]
|
|
|
|
}
|
|
|
|
get {
|
|
|
|
[[Get the interval on time updates for an user mouse button hold
|
|
|
|
on a flip selector widget.
|
|
|
|
|
|
|
|
See also @.first_interval.set for more details.
|
|
|
|
]]
|
|
|
|
}
|
|
|
|
values {
|
|
|
|
interval: double; [[The (first) interval value in seconds.]]
|
|
|
|
}
|
|
|
|
}
|
2014-03-30 00:34:05 -07:00
|
|
|
item_prepend {
|
2015-07-29 06:44:07 -07:00
|
|
|
[[Prepend a (text) item to a flip selector widget
|
2014-03-30 00:34:05 -07:00
|
|
|
|
2015-07-29 06:44:07 -07:00
|
|
|
The widget's list of labels to show will be prepended with the
|
|
|
|
given value. If the user wishes so, a callback function pointer
|
|
|
|
can be passed, which will get called when this same item is
|
|
|
|
selected.
|
2014-03-30 00:34:05 -07:00
|
|
|
|
2015-07-29 06:44:07 -07:00
|
|
|
Note: The current selection won't be modified by prepending
|
|
|
|
an element to the list.
|
2014-03-30 00:34:05 -07:00
|
|
|
|
2015-07-29 06:44:07 -07:00
|
|
|
Note: The maximum length of the text label is going to be
|
|
|
|
determined by the widget's theme. Strings larger than
|
|
|
|
that value are going to be truncated.
|
|
|
|
]]
|
2016-11-21 04:56:47 -08:00
|
|
|
return: Elm.Widget.Item; [[New widget item]]
|
2014-03-30 00:34:05 -07:00
|
|
|
params {
|
2016-05-31 08:02:26 -07:00
|
|
|
@in label: string; [[The (text) label of the new item.]]
|
2015-07-29 06:44:07 -07:00
|
|
|
@in func: Evas_Smart_Cb @optional; [[Convenience callback function to take place when
|
|
|
|
item is selected.]]
|
2016-06-02 04:54:59 -07:00
|
|
|
@in data: void_ptr @optional; [[Data passed to $func, above.]]
|
2014-03-30 00:34:05 -07:00
|
|
|
}
|
|
|
|
}
|
|
|
|
flip_next {
|
2015-07-29 06:44:07 -07:00
|
|
|
[[Programmatically select the next item of a flip selector widget
|
2014-03-30 00:34:05 -07:00
|
|
|
|
2015-07-29 06:44:07 -07:00
|
|
|
Note: The selection will be animated. Also, if it reaches the
|
|
|
|
end of its list of member items, it will continue with the first
|
|
|
|
one onwards.
|
|
|
|
]]
|
2014-03-30 00:34:05 -07:00
|
|
|
}
|
|
|
|
item_append {
|
2015-07-29 06:44:07 -07:00
|
|
|
[[Append a (text) item to a flip selector widget
|
2014-03-30 00:34:05 -07:00
|
|
|
|
2015-07-29 06:44:07 -07:00
|
|
|
The widget's list of labels to show will be appended with the
|
|
|
|
given value. If the user wishes so, a callback function pointer
|
|
|
|
can be passed, which will get called when this same item is
|
|
|
|
selected.
|
2014-03-30 00:34:05 -07:00
|
|
|
|
2015-07-29 06:44:07 -07:00
|
|
|
Note: The current selection won't be modified by appending an
|
|
|
|
element to the list.
|
2014-03-30 00:34:05 -07:00
|
|
|
|
2015-07-29 06:44:07 -07:00
|
|
|
Note: The maximum length of the text label is going to be
|
|
|
|
determined by the widget's theme. Strings larger than
|
|
|
|
that value are going to be truncated.
|
|
|
|
]]
|
2016-11-21 04:56:47 -08:00
|
|
|
return: Elm.Widget.Item; [[New widget item]]
|
2014-03-30 00:34:05 -07:00
|
|
|
params {
|
2016-05-31 08:02:26 -07:00
|
|
|
@in label: string; [[The (text) label of the new item.]]
|
2015-07-29 06:44:07 -07:00
|
|
|
@in func: Evas_Smart_Cb @optional; [[Convenience callback function to take place when
|
|
|
|
item is selected.]]
|
2016-06-02 04:54:59 -07:00
|
|
|
@in data: const(void_ptr) @optional; [[Data passed to $func, above.]]
|
2014-03-30 00:34:05 -07:00
|
|
|
}
|
|
|
|
}
|
|
|
|
flip_prev {
|
2015-07-29 06:44:07 -07:00
|
|
|
[[Programmatically select the previous item of a flip selector
|
|
|
|
widget
|
2014-03-30 00:34:05 -07:00
|
|
|
|
2015-07-29 06:44:07 -07:00
|
|
|
Note: The selection will be animated. Also, if it reaches the
|
|
|
|
beginning of its list of member items, it will continue with the
|
|
|
|
last one backwards.
|
|
|
|
]]
|
2014-03-30 00:34:05 -07:00
|
|
|
}
|
|
|
|
}
|
|
|
|
implements {
|
2014-06-20 02:47:39 -07:00
|
|
|
class.constructor;
|
2016-08-10 07:23:04 -07:00
|
|
|
Efl.Object.constructor;
|
2018-01-07 20:55:35 -08:00
|
|
|
Efl.Ui.Widget.theme_apply;
|
|
|
|
Efl.Ui.Widget.widget_event;
|
2019-01-21 07:22:32 -08:00
|
|
|
Efl.Ui.Range_Display.range_min_max { get; set; }
|
|
|
|
Efl.Ui.Range_Interactive.range_step { get; set; }
|
|
|
|
Efl.Ui.Range_Display.range_value { get; set; }
|
2017-11-15 18:31:26 -08:00
|
|
|
Efl.Access.Widget.Action.elm_actions { get; }
|
2014-03-30 00:34:05 -07:00
|
|
|
}
|
|
|
|
events {
|
efl: Add missing event types
Summary:
All events must have a type now, otherwise bindings don't know how to handle
the event_info field.
Most of the missing event types were actually "void" (no event_info present).
Some struct definitions had to be moved to eo instead of h files, so they
are available to bindings. Some have not, and are marked with FIXME.
Some namespaces have been fixed (like Efl_Event_Cb -> Efl.Event_Cb).
In general, there are hundreds of changed files, but mostly to add a type which
was not present before, so there's no harm done.
Also, A lot of FIXMEs have been added which should be, like, fixed.
For example, some events can send different types of event_info, which is
very inconvenient (and error prone).
Test Plan: make with c# bindings works, make check and make examples work too.
Reviewers: cedric, q66, lauromoura
Subscribers: zmike
Tags: #efl
Differential Revision: https://phab.enlightenment.org/D6169
2018-05-11 08:20:40 -07:00
|
|
|
underflowed: void; [[Called when flipselector is underflowed]]
|
|
|
|
overflowed: void; [[Called when flipselector is overflowed]]
|
2014-03-30 00:34:05 -07:00
|
|
|
}
|
|
|
|
}
|