forked from enlightenment/efl
Merge branch 'master' into devs/hermet/lottie
This commit is contained in:
commit
2d704c935b
|
@ -189,7 +189,7 @@ compress_target = custom_target('package_doc_tar',
|
|||
)
|
||||
|
||||
run_target('doc',
|
||||
command: ['echo', 'Documentation sucessfully build!'],
|
||||
command: ['echo', 'Documentation built successfully'],
|
||||
depends: compress_target,
|
||||
)
|
||||
|
||||
|
|
|
@ -609,8 +609,8 @@ EAPI Eina_List *ecore_file_app_list(void);
|
|||
* @return @c EINA_TRUE if the download start or @c EINA_FALSE on failure.
|
||||
*
|
||||
* This function starts the download of the URL @p url and saves it to
|
||||
* @p dst. @p url must provide the protocol, including 'http://',
|
||||
* 'ftp://' or 'file://'. Ecore_File must be compiled with CURL to
|
||||
* @p dst. @p url must provide the protocol, including '%http://',
|
||||
* '%ftp://' or '%file://'. Ecore_File must be compiled with CURL to
|
||||
* download using http and ftp protocols. If @p dst is ill-formed, or
|
||||
* if it already exists, the function returns @c EINA_FALSE. When the
|
||||
* download is complete, the callback @p completion_cb is called and
|
||||
|
@ -684,8 +684,8 @@ EAPI void ecore_file_download_abort(Ecore_File_Download_Job *job);
|
|||
* @return @c EINA_TRUE if protocol is handled, @c EINA_FALSE otherwise.
|
||||
*
|
||||
* This function returns @c EINA_TRUE if @p protocol is supported,
|
||||
* @c EINA_FALSE otherwise. @p protocol can be 'http://', 'ftp://' or
|
||||
* 'file://'. Ecore_FILE must be compiled with CURL to handle http and
|
||||
* @c EINA_FALSE otherwise. @p protocol can be '%http://', '%ftp://' or
|
||||
* '%file://'. Ecore_FILE must be compiled with CURL to handle http and
|
||||
* ftp protocols.
|
||||
*/
|
||||
EAPI Eina_Bool ecore_file_download_protocol_available(const char *protocol);
|
||||
|
|
|
@ -39,8 +39,6 @@ struct _Eldbus_Property_Promise
|
|||
Eina_Stringshare *property;
|
||||
};
|
||||
|
||||
static void _eldbus_model_proxy_property_set_data_free(Eldbus_Model_Proxy_Property_Set_Data *);
|
||||
|
||||
static Eina_Bool
|
||||
_eldbus_model_proxy_load(Eldbus_Model_Proxy_Data *pd)
|
||||
{
|
||||
|
@ -236,6 +234,9 @@ _eldbus_model_proxy_cancel_cb(Efl_Loop_Consumer *consumer EINA_UNUSED,
|
|||
Eldbus_Model_Proxy_Property_Set_Data *sd = data;
|
||||
|
||||
sd->promise = NULL;
|
||||
eina_stringshare_del(sd->property);
|
||||
eina_value_free(sd->value);
|
||||
free(sd);
|
||||
}
|
||||
|
||||
static Eldbus_Pending *
|
||||
|
@ -655,7 +656,6 @@ _eldbus_model_proxy_property_set_load_cb(void *data,
|
|||
if (!signature || !properties)
|
||||
{
|
||||
eina_promise_reject(set_data->promise, EFL_MODEL_ERROR_UNKNOWN);
|
||||
_eldbus_model_proxy_property_set_data_free(set_data);
|
||||
goto end;
|
||||
}
|
||||
|
||||
|
@ -688,7 +688,7 @@ _eldbus_model_proxy_property_set_cb(void *data,
|
|||
{
|
||||
ERR("%s: %s", error_name, error_text);
|
||||
eina_promise_reject(sd->promise, EFL_MODEL_ERROR_UNKNOWN);
|
||||
goto end;
|
||||
return;
|
||||
}
|
||||
|
||||
value = eina_hash_find(pd->properties, sd->property);
|
||||
|
@ -705,9 +705,6 @@ _eldbus_model_proxy_property_set_cb(void *data,
|
|||
eina_promise_reject(sd->promise,
|
||||
EFL_MODEL_ERROR_NOT_FOUND);
|
||||
}
|
||||
|
||||
end:
|
||||
_eldbus_model_proxy_property_set_data_free(sd);
|
||||
}
|
||||
|
||||
static const char *
|
||||
|
@ -726,13 +723,4 @@ _eldbus_model_proxy_property_type_get(Eldbus_Model_Proxy_Data *pd,
|
|||
return property_introspection->type;
|
||||
}
|
||||
|
||||
static void
|
||||
_eldbus_model_proxy_property_set_data_free(Eldbus_Model_Proxy_Property_Set_Data *data)
|
||||
{
|
||||
EINA_SAFETY_ON_NULL_RETURN(data);
|
||||
eina_stringshare_del(data->property);
|
||||
eina_value_free(data->value);
|
||||
free(data);
|
||||
}
|
||||
|
||||
#include "eldbus_model_proxy.eo.c"
|
||||
|
|
|
@ -77,6 +77,21 @@ _user_value_update(Evas_Object *obj, double value)
|
|||
evas_object_smart_changed(obj);
|
||||
}
|
||||
|
||||
static void
|
||||
_step_value_update(Evas_Object *obj, double step)
|
||||
{
|
||||
double value;
|
||||
|
||||
EFL_UI_SLIDER_DATA_GET(obj, sd);
|
||||
|
||||
if (efl_ui_mirrored_get(obj) ^ efl_ui_layout_orientation_is_inverted(sd->dir))
|
||||
step *= -1.0;
|
||||
|
||||
value = CLAMP(sd->val + step, sd->val_min, sd->val_max);
|
||||
_user_value_update(obj, value);
|
||||
|
||||
}
|
||||
|
||||
static void
|
||||
_drag_value_fetch(Evas_Object *obj)
|
||||
{
|
||||
|
@ -194,7 +209,8 @@ _drag_up(Evas_Object *obj)
|
|||
|
||||
efl_ui_drag_step_move(efl_part(wd->resize_obj, "efl.draggable.slider"),
|
||||
relative_step, relative_step);
|
||||
_drag_value_fetch(obj);
|
||||
|
||||
_step_value_update(obj, step);
|
||||
}
|
||||
|
||||
static void
|
||||
|
@ -214,7 +230,8 @@ _drag_down(Evas_Object *obj)
|
|||
|
||||
efl_ui_drag_step_move(efl_part(wd->resize_obj, "efl.draggable.slider"),
|
||||
relative_step, relative_step);
|
||||
_drag_value_fetch(obj);
|
||||
|
||||
_step_value_update(obj, step);
|
||||
}
|
||||
|
||||
static Eina_Bool
|
||||
|
|
|
@ -329,6 +329,9 @@ extern const char *_elm_engines[];
|
|||
# define ELM_PRIV_SMART_CALLBACKS_DESC(name, signal, type) \
|
||||
{name, type},
|
||||
|
||||
# define CLAMP(x, min, max) \
|
||||
(((x) > (max)) ? (max) : (((x) < (min)) ? (min) : (x)))
|
||||
|
||||
struct _Elm_Config_Flags
|
||||
{
|
||||
Eina_Bool engine : 1;
|
||||
|
|
|
@ -144,7 +144,6 @@ _indicator_set(Evas_Object *obj)
|
|||
elm_layout_text_set(obj, "elm.dragable.slider:elm.indicator", str);
|
||||
if (sd->popup)
|
||||
edje_object_part_text_set(sd->popup, "elm.indicator", str);
|
||||
|
||||
if (sd->popup2)
|
||||
{
|
||||
eina_strbuf_reset(sd->indi_format_strbuf);
|
||||
|
@ -335,6 +334,40 @@ _val_set(Evas_Object *obj)
|
|||
evas_object_smart_changed(obj);
|
||||
}
|
||||
|
||||
static void
|
||||
_user_value_update(Evas_Object *obj, double value)
|
||||
{
|
||||
double val = value;
|
||||
|
||||
ELM_SLIDER_DATA_GET_OR_RETURN(obj, sd);
|
||||
|
||||
if (fabs(val - sd->val) > DBL_EPSILON)
|
||||
{
|
||||
sd->val = val;
|
||||
sd->intvl_from = val;
|
||||
_val_set(obj);
|
||||
|
||||
evas_object_smart_callback_call(obj, SIG_CHANGED, NULL);
|
||||
ecore_timer_del(sd->delay);
|
||||
sd->delay = ecore_timer_add(SLIDER_DELAY_CHANGED_INTERVAL, _delay_change, obj);
|
||||
}
|
||||
}
|
||||
|
||||
static void
|
||||
_step_value_update(Evas_Object *obj, double step)
|
||||
{
|
||||
double value, absolute_step;
|
||||
|
||||
ELM_SLIDER_DATA_GET(obj, sd);
|
||||
|
||||
if (efl_ui_mirrored_get(obj) ^ efl_ui_layout_orientation_is_inverted(sd->dir))
|
||||
step *= -1.0;
|
||||
|
||||
absolute_step = step * (sd->val_max - sd->val_min);
|
||||
value = CLAMP(sd->val + absolute_step, sd->val_min, sd->val_max);
|
||||
_user_value_update(obj, value);
|
||||
}
|
||||
|
||||
static void
|
||||
_val_fetch(Evas_Object *obj, Eina_Bool user_event)
|
||||
{
|
||||
|
@ -489,6 +522,8 @@ _drag_up(void *data,
|
|||
ELM_WIDGET_DATA_GET_OR_RETURN(data, wd);
|
||||
efl_ui_drag_step_move(efl_part(wd->resize_obj, "elm.dragable.slider"),
|
||||
step, step);
|
||||
|
||||
_step_value_update(data, step);
|
||||
}
|
||||
|
||||
static void
|
||||
|
@ -507,6 +542,8 @@ _drag_down(void *data,
|
|||
ELM_WIDGET_DATA_GET_OR_RETURN(data, wd);
|
||||
efl_ui_drag_step_move(efl_part(wd->resize_obj, "elm.dragable.slider"),
|
||||
step, step);
|
||||
|
||||
_step_value_update(data, step);
|
||||
}
|
||||
|
||||
static Eina_Bool
|
||||
|
|
Loading…
Reference in New Issue