evas_object_show(bt);
notify = elm_notify_add(win);
- elm_notify_repeat_events_set(notify, EINA_FALSE);
+ elm_notify_allow_events_set(notify, EINA_FALSE);
evas_object_size_hint_weight_set(notify, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
elm_notify_orient_set(notify, ELM_NOTIFY_ORIENT_BOTTOM);
elm_notify_timeout_set(notify, 5.0);
elm_notify_orient_set(popup, ELM_NOTIFY_ORIENT_CENTER);
// Using the timeout doesn't seem to go well with the second main loop
//elm_notify_timeout_set(popup, 2.0);
- elm_notify_repeat_events_set(popup, EINA_FALSE);
+ elm_notify_allow_events_set(popup, EINA_FALSE);
evas_object_show(popup);
evas_object_smart_callback_add(popup, "block,clicked", _alert_del, NULL);
popup = elm_notify_add(obj);
elm_notify_orient_set(popup, ELM_NOTIFY_ORIENT_CENTER);
- elm_notify_repeat_events_set(popup, EINA_FALSE);
+ elm_notify_allow_events_set(popup, EINA_FALSE);
evas_object_show(popup);
box = elm_box_add(obj);
EINA_DEPRECATED EAPI Elm_Object_Item *elm_menu_item_add_object(Evas_Object *obj, Elm_Object_Item *parent, Evas_Object *subobj, Evas_Smart_Cb func, const void *data);
/**
+ * @brief Sets whether events should be passed to by a click outside
+ * its area.
+ *
+ * @param obj The notify object
+ * @param repeat EINA_TRUE Events are repeats, else no
+ *
+ * When true if the user clicks outside the window the events will be caught
+ * by the others widgets, else the events are blocked.
+ *
+ * @note The default value is EINA_TRUE.
+ * @deprecated Please use elm_notify_allow_events_set() instead
+ */
+EINA_DEPRECATED EAPI void elm_notify_repeat_events_set(Evas_Object *obj, Eina_Bool repeat);
+
+/**
+ * @brief Return true if events are repeat below the notify object
+ * @param obj the notify object
+ *
+ * @see elm_notify_repeat_events_set()
+ * @deprecated Please use elm_notify_allow_events_get() instead
+ */
+EINA_DEPRECATED EAPI Eina_Bool elm_notify_repeat_events_get(const Evas_Object *obj);
+
+/**
* Set if the cursor set should be searched on the theme or should use
* the provided by the engine, only.
*
Evas_Object *notify, *content, *parent;
Elm_Notify_Orient orient;
- Eina_Bool repeat_events;
+ Eina_Bool allow_events;
Evas_Object *block_events;
double timeout;
Widget_Data *wd = elm_widget_data_get(obj);
if (!wd) return;
elm_notify_parent_set(obj, NULL);
- elm_notify_repeat_events_set(obj, EINA_TRUE);
+ elm_notify_allow_events_set(obj, EINA_TRUE);
if (wd->timer)
{
ecore_timer_del(wd->timer);
Widget_Data *wd = elm_widget_data_get(obj);
if (!wd) return;
evas_object_show(wd->notify);
- if (!wd->repeat_events)
- evas_object_show(wd->block_events);
+ if (!wd->allow_events) evas_object_show(wd->block_events);
_timer_init(obj, wd);
elm_object_focus_set(obj, EINA_TRUE);
}
Widget_Data *wd = elm_widget_data_get(obj);
if (!wd) return;
evas_object_hide(wd->notify);
- if (!wd->repeat_events)
- evas_object_hide(wd->block_events);
+ if (!wd->allow_events) evas_object_hide(wd->block_events);
if (wd->timer)
{
ecore_timer_del(wd->timer);
elm_widget_content_get_hook_set(obj, _content_get_hook);
elm_widget_content_unset_hook_set(obj, _content_unset_hook);
- wd->repeat_events = EINA_TRUE;
+ wd->allow_events = EINA_TRUE;
wd->notify = edje_object_add(e);
wd->orient = -1;
return wd->timeout;
}
+EINA_DEPRECATED EAPI void
+elm_repeat_repeat_events_set(Evas_Object *obj, Eina_Bool repeat)
+{
+ elm_notify_allow_events_set(obj, repeat);
+}
+
+EINA_DEPRECATED EAPI Eina_Bool
+elm_repeat_allow_events_get(const Evas_Object *obj)
+{
+ return elm_notify_allow_events_get(obj);
+}
+
EAPI void
-elm_notify_repeat_events_set(Evas_Object *obj, Eina_Bool repeat)
+elm_notify_allow_events_set(Evas_Object *obj, Eina_Bool allow)
{
ELM_CHECK_WIDTYPE(obj, widtype);
Widget_Data *wd = elm_widget_data_get(obj);
if (!wd) return;
- if (repeat == wd->repeat_events) return;
- wd->repeat_events = repeat;
- if (!repeat)
+ if (allow == wd->allow_events) return;
+ wd->allow_events = allow;
+ if (!allow)
{
wd->block_events = edje_object_add(evas_object_evas_get(obj));
_block_events_theme_apply(obj);
}
EAPI Eina_Bool
-elm_notify_repeat_events_get(const Evas_Object *obj)
+elm_notify_allow_events_get(const Evas_Object *obj)
{
ELM_CHECK_WIDTYPE(obj, widtype) EINA_FALSE;
Widget_Data *wd = elm_widget_data_get(obj);
if (!wd) return EINA_FALSE;
- return wd->repeat_events;
+ return wd->allow_events;
}
* its area.
*
* @param obj The notify object
- * @param repeat EINA_TRUE Events are repeats, else no
+ * @param allow EINA_TRUE If events are allowed, otherwise not
*
* When true if the user clicks outside the window the events will be caught
* by the others widgets, else the events are blocked.
*
* @note The default value is EINA_TRUE.
*/
-EAPI void elm_notify_repeat_events_set(Evas_Object *obj, Eina_Bool repeat);
+EAPI void elm_notify_allow_events_set(Evas_Object *obj, Eina_Bool allow);
/**
- * @brief Return true if events are repeat below the notify object
+ * @brief Return true if events are allowed below the notify object
* @param obj the notify object
*
- * @see elm_notify_repeat_events_set()
+ * @see elm_notify_allow_events_set()
*/
-EAPI Eina_Bool elm_notify_repeat_events_get(const Evas_Object *obj);
+EAPI Eina_Bool elm_notify_allow_events_get(const Evas_Object *obj);
/**
* @}