summaryrefslogtreecommitdiff
path: root/src/bin/main.c
diff options
context:
space:
mode:
authorFlavio Ceolin <flavio.ceolin@gmail.com>2013-09-01 19:41:13 -0300
committerFlavio Ceolin <flavio.ceolin@gmail.com>2014-04-03 16:23:04 -0300
commit196cdb70b84958dd827797f86e78abd798e48cf7 (patch)
treefa94c67c0794b8dd8d64b8e216daccc20801c584 /src/bin/main.c
parentc984cf740b8625571a5d1617e0c3911fc27c11f9 (diff)
Adding common code
Init/shutdown used libraries and including common headers.
Diffstat (limited to 'src/bin/main.c')
-rw-r--r--src/bin/main.c31
1 files changed, 31 insertions, 0 deletions
diff --git a/src/bin/main.c b/src/bin/main.c
new file mode 100644
index 0000000..66cd35a
--- /dev/null
+++ b/src/bin/main.c
@@ -0,0 +1,31 @@
1#include <common.h>
2#include <epulse.h>
3#include "main_window.h"
4
5#define DEFAULT_HEIGHT 600
6#define DEFAULT_WIDTH 800
7
8EAPI int
9elm_main(int argc EINA_UNUSED, char *argv[] EINA_UNUSED)
10{
11 Evas_Object *win;
12
13 EINA_SAFETY_ON_FALSE_RETURN_VAL(epulse_common_init("epulse"), EXIT_FAILURE);
14 EINA_SAFETY_ON_FALSE_RETURN_VAL(epulse_init() > 0, EXIT_FAILURE);
15
16 win = main_window_add();
17 evas_object_resize(win, DEFAULT_WIDTH, DEFAULT_HEIGHT);
18 evas_object_show(win);
19
20 elm_run();
21
22 epulse_common_shutdown();
23 epulse_shutdown();
24 return 0;
25}
26
27/*
28 * Create the default main() that will work with both quicklaunch or
29 * regular applications.
30 */
31ELM_MAIN()