With ELM_POLICY_EXIT it's possible to request elementary
to delete all the windows before shutdown instead of just
quitting the main loop.
SVN revision: 77328
* should quit automatically. @see
* Elm_Policy_Quit.
*/
+ ELM_POLICY_EXIT, /**< defines elm_exit() behaviour. @see Elm_Policy_Exit.
+ * @since 1.8
+ */
ELM_POLICY_LAST
} Elm_Policy; /**< Elementary policy identifiers/groups enumeration. @see elm_policy_set() */
typedef enum
{
+ ELM_POLICY_EXIT_NONE = 0, /**< just quit the main loop on elm_exit() */
+ ELM_POLICY_EXIT_WINDOWS_DEL /**< delete all the windows after quitting
+ * the main loop */
+} Elm_Policy_Exit; /**< Possible values for the #ELM_POLICY_EXIT policy */
+
+typedef enum
+{
ELM_FOCUS_PREVIOUS,
ELM_FOCUS_NEXT
} Elm_Focus_Direction;
elm_exit(void)
{
ecore_main_loop_quit();
+
+ if (elm_policy_get(ELM_POLICY_EXIT) == ELM_POLICY_EXIT_WINDOWS_DEL)
+ {
+ Eina_List *l, *l_next;
+ Evas_Object *win;
+
+ EINA_LIST_FOREACH_SAFE(_elm_win_list, l, l_next, win)
+ evas_object_del(win);
+ }
}
//FIXME: Use Elm_Policy Parameter when 2.0 is released.