lib/efl/interfaces/efl_observable.eo \
lib/efl/interfaces/efl_ui_item.eo \
lib/efl/interfaces/efl_ui_menu.eo \
+ lib/efl/interfaces/efl_ui_autorepeat.eo \
$(efl_eolian_legacy_files) \
$(NULL)
interfaces/efl_ui_menu.eo
interfaces/efl_ui_progress.eo
interfaces/efl_ui_spin.eo
+ interfaces/efl_ui_autorepeat.eo
interfaces/efl_vpath.eo
interfaces/efl_vpath_core.eo
interfaces/efl_vpath_file.eo
#include "interfaces/efl_ui_progress.eo.h"
#include "interfaces/efl_ui_item.eo.h"
#include "interfaces/efl_ui_menu.eo.h"
+#include "interfaces/efl_ui_autorepeat.eo.h"
#include "interfaces/efl_screen.eo.h"
--- /dev/null
+interface Efl.Ui.Autorepeat {
+ [[Efl UI autorepeat interface]]
+ methods {
+ @property initial_timeout {
+ [[The initial timeout before the autorepeat event is generated
+
+ Sets the timeout, in seconds, since the button is pressed until the
+ first $repeated signal is emitted. If $t is 0.0 or less, there
+ won't be any delay and the event will be fired the moment the button is
+ pressed.
+
+ See also @.enabled.set, @.gap_timeout.set.
+ ]]
+ values {
+ t: double; [[Timeout in seconds]]
+ }
+ }
+ @property gap_timeout {
+ [[The interval between each generated autorepeat event
+
+ After the first $repeated event is fired, all subsequent ones will
+ follow after a delay of $t seconds for each.
+
+ See also @.initial_timeout.set.
+ ]]
+ values {
+ t: double; [[Interval in seconds]]
+ }
+ }
+ @property enabled {
+ [[Turn on/off the autorepeat event generated when the button is kept pressed
+
+ When off, no autorepeat is performed and buttons emit a normal $clicked
+ signal when they are clicked.
+
+ When on, keeping a button pressed will continuously emit a $repeated
+ signal until the button is released. The time it takes until it starts
+ emitting the signal is given by @.initial_timeout.set, and the
+ time between each new emission by @.gap_timeout.set.
+ ]]
+ values {
+ on: bool; [[A bool to turn on/off the event]]
+ }
+ }
+ @property supported {
+ [[Whether the button supports autorepeat.]]
+ get {
+ }
+ values {
+ ret: bool; [[$true if autorepeat is supported, $false otherwise]]
+ }
+ }
+ }
+}
}
EOLIAN static Eina_Bool
-_elm_combobox_elm_button_admits_autorepeat_get(Eo *obj EINA_UNUSED,
- Elm_Combobox_Data *sd EINA_UNUSED)
+_elm_combobox_efl_ui_autorepeat_supported_get(Eo *obj EINA_UNUSED,
+ Elm_Combobox_Data *sd EINA_UNUSED)
{
return EINA_FALSE;
}
}
EOLIAN static Eina_Bool
-_elm_fileselector_button_elm_button_admits_autorepeat_get(Eo *obj EINA_UNUSED, Elm_Fileselector_Button_Data *sd EINA_UNUSED)
+_elm_fileselector_button_efl_ui_autorepeat_supported_get(Eo *obj EINA_UNUSED, Elm_Fileselector_Button_Data *sd EINA_UNUSED)
{
return EINA_FALSE;
}
}
EOLIAN static Eina_Bool
-_elm_hoversel_elm_button_admits_autorepeat_get(Eo *obj EINA_UNUSED, Elm_Hoversel_Data *sd EINA_UNUSED)
+_elm_hoversel_efl_ui_autorepeat_supported_get(Eo *obj EINA_UNUSED, Elm_Hoversel_Data *sd EINA_UNUSED)
{
return EINA_FALSE;
}
}
EOLIAN static void
-_elm_button_autorepeat_set(Eo *obj EINA_UNUSED, Elm_Button_Data *sd, Eina_Bool on)
+_elm_button_efl_ui_autorepeat_enabled_set(Eo *obj EINA_UNUSED, Elm_Button_Data *sd, Eina_Bool on)
{
ELM_SAFE_FREE(sd->timer, ecore_timer_del);
sd->autorepeat = on;
}
#define _AR_CAPABLE(obj) \
- (_internal_elm_button_admits_autorepeat_get(obj))
+ (_internal_elm_button_autorepeat_supported_get(obj))
static Eina_Bool
-_internal_elm_button_admits_autorepeat_get(const Evas_Object *obj)
+_internal_elm_button_autorepeat_supported_get(const Evas_Object *obj)
{
Eina_Bool ret = EINA_FALSE;
- ret = elm_obj_button_admits_autorepeat_get((Eo *) obj);
+ ret = efl_ui_autorepeat_supported_get(obj);
return ret;
}
EOLIAN static Eina_Bool
-_elm_button_admits_autorepeat_get(Eo *obj EINA_UNUSED, Elm_Button_Data *_pd EINA_UNUSED)
+_elm_button_efl_ui_autorepeat_supported_get(Eo *obj EINA_UNUSED, Elm_Button_Data *_pd EINA_UNUSED)
{
return EINA_TRUE;
}
EOLIAN static Eina_Bool
-_elm_button_autorepeat_get(Eo *obj, Elm_Button_Data *sd)
+_elm_button_efl_ui_autorepeat_enabled_get(Eo *obj, Elm_Button_Data *sd)
{
return (_AR_CAPABLE(obj) & sd->autorepeat);
}
EOLIAN static void
-_elm_button_autorepeat_initial_timeout_set(Eo *obj, Elm_Button_Data *sd, double t)
+_elm_button_efl_ui_autorepeat_initial_timeout_set(Eo *obj, Elm_Button_Data *sd, double t)
{
if (!_AR_CAPABLE(obj))
{
}
EOLIAN static double
-_elm_button_autorepeat_initial_timeout_get(Eo *obj, Elm_Button_Data *sd)
+_elm_button_efl_ui_autorepeat_initial_timeout_get(Eo *obj, Elm_Button_Data *sd)
{
if (!_AR_CAPABLE(obj))
return 0.0;
}
EOLIAN static void
-_elm_button_autorepeat_gap_timeout_set(Eo *obj, Elm_Button_Data *sd, double t)
+_elm_button_efl_ui_autorepeat_gap_timeout_set(Eo *obj, Elm_Button_Data *sd, double t)
{
if (!_AR_CAPABLE(obj))
{
}
EOLIAN static double
-_elm_button_autorepeat_gap_timeout_get(Eo *obj EINA_UNUSED, Elm_Button_Data *sd)
+_elm_button_efl_ui_autorepeat_gap_timeout_get(Eo *obj EINA_UNUSED, Elm_Button_Data *sd)
{
return sd->ar_gap_timeout;
}
/* Efl.Part end */
+EAPI void
+elm_button_autorepeat_initial_timeout_set(Evas_Object *obj, double t)
+{
+ efl_ui_autorepeat_initial_timeout_set(obj, t);
+}
+
+EAPI double
+elm_button_autorepeat_initial_timeout_get(const Evas_Object *obj)
+{
+ return efl_ui_autorepeat_initial_timeout_get(obj);
+}
+
+EAPI void
+elm_button_autorepeat_gap_timeout_set(Evas_Object *obj, double t)
+{
+ efl_ui_autorepeat_gap_timeout_set(obj, t);
+}
+
+EAPI double
+elm_button_autorepeat_gap_timeout_get(const Evas_Object *obj)
+{
+ return efl_ui_autorepeat_gap_timeout_get(obj);
+}
+
+EAPI void
+elm_button_autorepeat_set(Evas_Object *obj, Eina_Bool on)
+{
+ efl_ui_autorepeat_enabled_set(obj, on);
+}
+
+EAPI Eina_Bool
+elm_button_autorepeat_get(const Evas_Object *obj)
+{
+ return efl_ui_autorepeat_enabled_get(obj);
+}
+
#include "elm_button.eo.c"
-class Elm.Button (Elm.Layout, Efl.Ui.Clickable, Efl.Text,
+class Elm.Button (Elm.Layout, Efl.Ui.Clickable, Efl.Ui.Autorepeat, Efl.Text,
Elm.Interface.Atspi_Widget_Action)
{
[[Push-button widget
legacy_prefix: elm_button;
eo_prefix: elm_obj_button;
methods {
- @property autorepeat_initial_timeout {
- [[The initial timeout before the autorepeat event is generated
-
- Sets the timeout, in seconds, since the button is pressed until the
- first $repeated signal is emitted. If $t is 0.0 or less, there
- won't be any delay and the event will be fired the moment the button is
- pressed.
-
- See also @.autorepeat.set, @.autorepeat_gap_timeout.set.
- ]]
- set {
- }
- get {
- }
- values {
- t: double; [[Timeout in seconds]]
- }
- }
- @property autorepeat_gap_timeout {
- [[The interval between each generated autorepeat event
-
- After the first $repeated event is fired, all subsequent ones will
- follow after a delay of $t seconds for each.
-
- See also @.autorepeat_initial_timeout.set.
- ]]
- set {
- }
- get {
- }
- values {
- t: double; [[Interval in seconds]]
- }
- }
- @property autorepeat {
- [[Turn on/off the autorepeat event generated when the button is kept pressed
-
- When off, no autorepeat is performed and buttons emit a normal $clicked
- signal when they are clicked.
-
- When on, keeping a button pressed will continuously emit a $repeated
- signal until the button is released. The time it takes until it starts
- emitting the signal is given by @.autorepeat_initial_timeout.set, and the
- time between each new emission by @.autorepeat_gap_timeout.set.
- ]]
- set {
- }
- get {
- }
- values {
- on: bool; [[A bool to turn on/off the event]]
- }
- }
- @property admits_autorepeat {
- [[Whether the button supports autorepeat.]]
- get {
- legacy: null;
- }
- values {
- ret: bool; [[$true if autorepeat is supported, $false otherwise]]
- }
- }
}
implements {
class.constructor;
Efl.Object.constructor;
Efl.Canvas.Group.group_add;
+ Efl.Ui.Autorepeat.initial_timeout { set; get; }
+ Efl.Ui.Autorepeat.gap_timeout { set; get; }
+ Efl.Ui.Autorepeat.enabled { set; get; }
+ Efl.Ui.Autorepeat.supported { get;}
Elm.Widget.activate;
Elm.Widget.focus_next_manager_is;
Elm.Widget.focus_direction_manager_is;
*/
EAPI Evas_Object *elm_button_add(Evas_Object *parent);
+/**
+ * @brief The initial timeout before the autorepeat event is generated
+ *
+ * Sets the timeout, in seconds, since the button is pressed until the first
+ * @c repeated signal is emitted. If @c t is 0.0 or less, there won't be any
+ * delay and the event will be fired the moment the button is pressed.
+ *
+ * See also @ref elm_button_autorepeat_set,
+ * @ref elm_button_autorepeat_gap_timeout_set.
+ *
+ * @param[in] t Timeout in seconds
+ *
+ * @ingroup Elm_Button
+ */
+
+EAPI void elm_button_autorepeat_initial_timeout_set(Evas_Object *obj, double t);
+
+/**
+ * @brief The initial timeout before the autorepeat event is generated
+ *
+ * Sets the timeout, in seconds, since the button is pressed until the first
+ * @c repeated signal is emitted. If @c t is 0.0 or less, there won't be any
+ * delay and the event will be fired the moment the button is pressed.
+ *
+ * See also @ref elm_button_autorepeat_set,
+ * @ref elm_button_autorepeat_gap_timeout_set.
+ *
+ * @return Timeout in seconds
+ *
+ * @ingroup Elm_Button
+ */
+
+EAPI double elm_button_autorepeat_initial_timeout_get(const Evas_Object *obj);
+
+/**
+ * @brief The interval between each generated autorepeat event
+ *
+ * After the first @c repeated event is fired, all subsequent ones will follow
+ * after a delay of @c t seconds for each.
+ *
+ * See also @ref elm_button_autorepeat_initial_timeout_set.
+ *
+ * @param[in] t Interval in seconds
+ *
+ * @ingroup Elm_Button
+ */
+EAPI void elm_button_autorepeat_gap_timeout_set(Evas_Object *obj, double t);
+
+/**
+ * @brief The interval between each generated autorepeat event
+ *
+ * After the first @c repeated event is fired, all subsequent ones will follow
+ * after a delay of @c t seconds for each.
+ *
+ * See also @ref elm_button_autorepeat_initial_timeout_set.
+ *
+ * @return Interval in seconds
+ *
+ * @ingroup Elm_Button
+ */
+EAPI double elm_button_autorepeat_gap_timeout_get(const Evas_Object *obj);
+
+/**
+ * @brief Turn on/off the autorepeat event generated when the button is kept
+ * pressed
+ *
+ * When off, no autorepeat is performed and buttons emit a normal @c clicked
+ * signal when they are clicked.
+ *
+ * When on, keeping a button pressed will continuously emit a @c repeated
+ * signal until the button is released. The time it takes until it starts
+ * emitting the signal is given by @ref elm_button_autorepeat_initial_timeout_set,
+ * and the time between each new emission by
+ * @ref elm_button_autorepeat_gap_timeout_set.
+ *
+ * @param[in] on A bool to turn on/off the event
+ *
+ * @ingroup Elm_Button
+ */
+EAPI void elm_button_autorepeat_set(Evas_Object *obj, Eina_Bool on);
+
+/**
+ * @brief Turn on/off the autorepeat event generated when the button is kept
+ * pressed
+ *
+ * When off, no autorepeat is performed and buttons emit a normal @c clicked
+ * signal when they are clicked.
+ *
+ * When on, keeping a button pressed will continuously emit a @c repeated
+ * signal until the button is released. The time it takes until it starts
+ * emitting the signal is given by @ref elm_button_autorepeat_initial_timeout_set,
+ * and the time between each new emission by
+ * @ref elm_button_autorepeat_gap_timeout_set.
+ *
+ * @return A bool to turn on/off the event
+ *
+ * @ingroup Elm_Button
+ */
+EAPI Eina_Bool elm_button_autorepeat_get(const Evas_Object *obj);
+
#include "elm_button.eo.legacy.h"
Elm.Widget.theme_apply;
Elm.Widget.translate;
Elm.Widget.widget_event;
- Elm.Button.admits_autorepeat { get; }
+ Efl.Ui.Autorepeat.supported { get; }
Elm.Genlist.filter { set; }
Elm.Interface.Atspi_Widget_Action.elm_actions { get; }
}
Efl.Canvas.Group.group_add;
Efl.Canvas.Group.group_del;
Elm.Widget.theme_apply;
- Elm.Button.admits_autorepeat { get; }
+ Efl.Ui.Autorepeat.supported { get; }
Elm.Interface.Fileselector.selected_models { get; }
Elm.Interface.Fileselector.expandable { get; set; }
Elm.Interface.Fileselector.thumbnail_size { get; set; }
Elm.Widget.theme_apply;
Elm.Widget.translate;
Elm.Widget.widget_event;
- Elm.Button.admits_autorepeat { get; }
+ Efl.Ui.Autorepeat.supported { get; }
Elm.Interface.Atspi_Widget_Action.elm_actions { get; }
}
events {