diff options
Diffstat (limited to 'src/love/love.c')
-rw-r--r-- | src/love/love.c | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/src/love/love.c b/src/love/love.c index 0e4ac40..1f885bc 100644 --- a/src/love/love.c +++ b/src/love/love.c | |||
@@ -55,7 +55,7 @@ typedef struct _script | |||
55 | } script; | 55 | } script; |
56 | 56 | ||
57 | 57 | ||
58 | int logDom; // Our logging domain. | 58 | int logDom = -1; // Our logging domain. |
59 | //static int CPUs = 4; | 59 | //static int CPUs = 4; |
60 | static Eina_Strbuf *LuaSLStream; | 60 | static Eina_Strbuf *LuaSLStream; |
61 | static Eina_Strbuf *clientStream; | 61 | static Eina_Strbuf *clientStream; |
@@ -166,7 +166,7 @@ static Eina_Bool _addLuaSL(void *data, int type, Ecore_Con_Event_Server_Add *ev) | |||
166 | 166 | ||
167 | // Compile and run scripts. | 167 | // Compile and run scripts. |
168 | gettimeofday(&startTime, NULL); | 168 | gettimeofday(&startTime, NULL); |
169 | snprintf(buf, sizeof(buf), "%s/Test sim/objects", PACKAGE_DATA_DIR); | 169 | snprintf(buf, sizeof(buf), "%s/Test sim/objects", prefix_data_get()); |
170 | eina_file_dir_list(buf, EINA_TRUE, dirList_compile, data); | 170 | eina_file_dir_list(buf, EINA_TRUE, dirList_compile, data); |
171 | 171 | ||
172 | return ECORE_CALLBACK_RENEW; | 172 | return ECORE_CALLBACK_RENEW; |
@@ -413,7 +413,7 @@ static Eina_Bool _dataLuaSL(void *data, int type, Ecore_Con_Event_Server_Data *e | |||
413 | temp++; | 413 | temp++; |
414 | temp[0] = '\0'; | 414 | temp[0] = '\0'; |
415 | lineNo = atoi(line); | 415 | lineNo = atoi(line); |
416 | snprintf(key, sizeof(key), "%s/Test sim/objects/onefang%%27s%%20test%%20bed.5cb927d5-1304-4f1a-9947-308251ef2df0/%s", PACKAGE_DATA_DIR, notecard); | 416 | snprintf(key, sizeof(key), "%s/Test sim/objects/onefang%%27s%%20test%%20bed.5cb927d5-1304-4f1a-9947-308251ef2df0/%s", prefix_data_get(), notecard); |
417 | 417 | ||
418 | fd = open(key, O_RDONLY); | 418 | fd = open(key, O_RDONLY); |
419 | if (-1 != fd) | 419 | if (-1 != fd) |
@@ -493,7 +493,7 @@ static Eina_Bool _delLuaSL(void *data, int type, Ecore_Con_Event_Server_Del *ev) | |||
493 | char buf[PATH_MAX]; | 493 | char buf[PATH_MAX]; |
494 | 494 | ||
495 | PW("Failed to connect to a script server, starting our own."); | 495 | PW("Failed to connect to a script server, starting our own."); |
496 | sprintf(buf, "%s/LuaSL &", PACKAGE_BIN_DIR); | 496 | sprintf(buf, "%s/LuaSL &", prefix_bin_get()); |
497 | system(buf); | 497 | system(buf); |
498 | count = 0; | 498 | count = 0; |
499 | } | 499 | } |
@@ -618,7 +618,7 @@ int main(int argc, char **argv) | |||
618 | 618 | ||
619 | if (eina_init()) | 619 | if (eina_init()) |
620 | { | 620 | { |
621 | logDom = loggingStartup("love", logDom); | 621 | logDom = HamrTime(argv[0], main, logDom); |
622 | ourGlobals.scripts = eina_hash_string_superfast_new(NULL); | 622 | ourGlobals.scripts = eina_hash_string_superfast_new(NULL); |
623 | 623 | ||
624 | if (ecore_con_init()) | 624 | if (ecore_con_init()) |
@@ -703,7 +703,7 @@ int main(int argc, char **argv) | |||
703 | evas_object_focus_set(ourGlobals.bg, EINA_TRUE); | 703 | evas_object_focus_set(ourGlobals.bg, EINA_TRUE); |
704 | 704 | ||
705 | ourGlobals.edje = edje_object_add(ourGlobals.canvas); | 705 | ourGlobals.edje = edje_object_add(ourGlobals.canvas); |
706 | snprintf(buf, sizeof(buf), "%s/%s.edj", PACKAGE_DATA_DIR, "love"); | 706 | snprintf(buf, sizeof(buf), "%s/%s.edj", prefix_data_get(), "love"); |
707 | if (!edje_object_file_set(ourGlobals.edje, buf, group)) | 707 | if (!edje_object_file_set(ourGlobals.edje, buf, group)) |
708 | { | 708 | { |
709 | int err = edje_object_load_error_get(ourGlobals.edje); | 709 | int err = edje_object_load_error_get(ourGlobals.edje); |
@@ -720,7 +720,7 @@ int main(int argc, char **argv) | |||
720 | evas_object_resize(ourGlobals.edje, WIDTH, HEIGHT); | 720 | evas_object_resize(ourGlobals.edje, WIDTH, HEIGHT); |
721 | evas_object_show(ourGlobals.edje); | 721 | evas_object_show(ourGlobals.edje); |
722 | 722 | ||
723 | snprintf(buf, sizeof(buf), "%s/bubble_sh.png", PACKAGE_DATA_DIR); | 723 | snprintf(buf, sizeof(buf), "%s/bubble_sh.png", prefix_data_get()); |
724 | for (i = 0; i < (sizeof(names) / sizeof(char *) / 2); i++) | 724 | for (i = 0; i < (sizeof(names) / sizeof(char *) / 2); i++) |
725 | { | 725 | { |
726 | sh = evas_object_image_filled_add(ourGlobals.canvas); | 726 | sh = evas_object_image_filled_add(ourGlobals.canvas); |
@@ -730,7 +730,7 @@ int main(int argc, char **argv) | |||
730 | evas_object_data_set(ourGlobals.bg, names[(i * 2) + 1], sh); | 730 | evas_object_data_set(ourGlobals.bg, names[(i * 2) + 1], sh); |
731 | } | 731 | } |
732 | 732 | ||
733 | snprintf(buf, sizeof(buf), "%s/bubble.png", PACKAGE_DATA_DIR); | 733 | snprintf(buf, sizeof(buf), "%s/bubble.png", prefix_data_get()); |
734 | for (i = 0; i < (sizeof(names) / sizeof(char *) / 2); i++) | 734 | for (i = 0; i < (sizeof(names) / sizeof(char *) / 2); i++) |
735 | { | 735 | { |
736 | bub = evas_object_image_filled_add(ourGlobals.canvas); | 736 | bub = evas_object_image_filled_add(ourGlobals.canvas); |
@@ -779,6 +779,7 @@ int main(int argc, char **argv) | |||
779 | PC("Failed to init ecore_con!"); | 779 | PC("Failed to init ecore_con!"); |
780 | 780 | ||
781 | eina_hash_free(ourGlobals.scripts); | 781 | eina_hash_free(ourGlobals.scripts); |
782 | pantsOff(logDom); | ||
782 | } | 783 | } |
783 | else | 784 | else |
784 | fprintf(stderr, "Failed to init eina!"); | 785 | fprintf(stderr, "Failed to init eina!"); |