static void document_delete(void *d) { Engine_Remote_Document *rdoc = d; ecore_ipc_shutdown(); ecore_shutdown(); }
/* externally accessible functions */ int main(int argc, char **argv) { int i; for (i = 1; i < argc; i++) { if ((!strcmp(argv[i], "-h")) || (!strcmp(argv[i], "-help")) || (!strcmp(argv[i], "--help"))) { printf( "This is an internal tool for Enlightenment.\n" "do not use it.\n" ); exit(0); } else if (!strncmp(argv[i], "--nice=", 7)) { const char *val; int ret = 0; val = argv[i] + 7; if (*val) ret = nice(atoi(val)); } } ecore_init(); ecore_app_args_set(argc, (const char **)argv); eet_init(); evas_init(); ecore_evas_init(); edje_init(); ecore_file_init(); ecore_ipc_init(); e_user_dir_concat_static(_thumbdir, "fileman/thumbnails"); ecore_file_mkpath(_thumbdir); if (_e_ipc_init()) ecore_main_loop_begin(); if (_e_ipc_server) { ecore_ipc_server_del(_e_ipc_server); _e_ipc_server = NULL; } ecore_ipc_shutdown(); ecore_file_shutdown(); ecore_evas_shutdown(); edje_shutdown(); evas_shutdown(); eet_shutdown(); ecore_shutdown(); return 0; }
int ecore_config_ipc_exit(Ecore_Config_Ipc_Server_List ** srv_list) { Ecore_Config_Ipc_Server_List *tmp = *srv_list; if (!srv_list) return ECORE_CONFIG_ERR_FAIL; if (*srv_list) while (tmp) { ecore_ipc_server_del(tmp->srv); tmp = tmp->next; } *srv_list = NULL; ecore_ipc_shutdown(); return ECORE_CONFIG_ERR_SUCC; }
/* externally accessible functions */ int main(int argc, char **argv) { if (argc > 1) { printf( "This is an internal tool for Enlightenment.\n" "do not use it.\n" ); exit(0); } eina_init(); eet_init(); ecore_init(); ecore_app_args_set(argc, (const char **)argv); ecore_file_init(); ecore_ipc_init(); _e_storage_volume_edd_init(); if (!_e_fm_ipc_init()) return -1; efm_log_dom = eina_log_domain_register("efm", EINA_COLOR_GREEN); _e_fm_init(); ecore_event_handler_add(ECORE_EXE_EVENT_DATA, _e_fm_ipc_slave_data_cb, NULL); ecore_event_handler_add(ECORE_EXE_EVENT_ERROR, _e_fm_ipc_slave_error_cb, NULL); ecore_event_handler_add(ECORE_EXE_EVENT_DEL, _e_fm_ipc_slave_del_cb, NULL); ecore_main_loop_begin(); if (_e_fm_ipc_server) { ecore_ipc_server_del(_e_fm_ipc_server); _e_fm_ipc_server = NULL; } _e_fm_shutdown(); _e_storage_volume_edd_shutdown(); ecore_ipc_shutdown(); ecore_file_shutdown(); ecore_shutdown(); eina_shutdown(); return 0; }
/** * @param argc: Number of command line arguments supplied. * @param argv: Char* array containing the command line arguments supplied. * @return: To the system, normally 0. * @brief: The first function once enotes is called. */ int main(int argc, char *argv[]) { int note_count; /* IPC Check */ ecore_ipc_init(); dml("IPC Initiated Successfully", 1); /* loading will increment this if there are notes if not we may need to * create a blank one */ note_count = 0; if ((ecore_config_init("enotes")) == ECORE_CONFIG_ERR_FAIL) { ecore_ipc_shutdown(); return (-1); } ecore_app_args_set(argc, (const char **) argv); ecore_config_app_describe("E-Notes - Sticky Notes for Enlightenment\n\ Copyright (c) Thomas Fletcher\n\ Usage: enotes [options]"); /* Read the Usage and Configurations */ main_config = mainconfig_new(); if (read_configuration(main_config) != ECORE_CONFIG_PARSE_CONTINUE) { ecore_config_shutdown(); ecore_ipc_shutdown(); ecore_shutdown(); mainconfig_free(main_config); return (-1); } dml("Successfully Read Configurations and Usage", 1); process_note_storage_locations(); if (find_server() != 0) { if (remotecmd != NULL) send_to_server(remotecmd); else send_to_server("DEFNOTE"); } else { dml("Server wasn't found.. Creating one", 1); /* Setup Server */ setup_server(); /* Initialise the E-Libs */ ecore_init(); ecore_x_init(NULL); ecore_app_args_set(argc, (const char **) argv); if (!ecore_evas_init()) { mainconfig_free(main_config); return -1; } ewl_init(&argc, argv); edje_init(); dml("Efl Successfully Initiated", 1); autoload(); /* create autosave timer */ update_autosave(); if (remotecmd != NULL) handle_ipc_message(remotecmd); /* Begin the Control Centre */ if (main_config->controlcentre == 1) { setup_cc(); dml("Control Centre Setup", 1); } else { dml("No Control Centre - Displaying Notice", 1); if (get_note_count() == 0) new_note(); } if (main_config->welcome == 1) { open_welcome(); } /* Begin the main loop */ dml("Starting Main Loop", 1); ecore_main_loop_begin(); dml("Main Loop Ended", 1); /* Save Controlcentre Settings */ set_cc_pos(); autosave(); if (autosave_timer) ecore_timer_del(autosave_timer); /* Save and Free the Configuration */ ecore_config_save(); dml("Configuration Saved", 1); mainconfig_free(main_config); dml("Configuration Structure Free'd", 1); /* Shutdown the E-Libs */ edje_shutdown(); ecore_evas_shutdown(); ecore_x_shutdown(); ecore_shutdown(); dml("Efl Shutdown", 1); } /* End IPC */ ecore_ipc_shutdown(); dml("IPC Shutdown", 1); dml("Leaving.", 1); return (0); }