diff --git a/src/api/system.c b/src/api/system.c index dc6827ad..3eeb947d 100644 --- a/src/api/system.c +++ b/src/api/system.c @@ -14,6 +14,8 @@ #include #elif __linux__ #include +#elif __amigaos4__ + #include "platform/amigaos4.h" #endif extern SDL_Window *window; @@ -798,7 +800,6 @@ static int f_watch_dir(lua_State *L) { const char *path = luaL_checkstring(L, 1); const int recursive = lua_toboolean(L, 2); // uint32_t dmon_flags = (recursive ? DMON_WATCHFLAGS_RECURSIVE : 0); - uint32_t dmon_flags = 0; // dmon_watch_id watch_id = dmon_watch(path, dirmonitor_watch_callback, dmon_flags, NULL); // if (watch_id.id == 0) { luaL_error(L, "directory monitoring watch failed"); } // lua_pushnumber(L, watch_id.id); diff --git a/src/dirmonitor.c b/src/dirmonitor.c index 0063e400..fe3cc41c 100644 --- a/src/dirmonitor.c +++ b/src/dirmonitor.c @@ -3,9 +3,11 @@ #include +#ifndef __amigaos4__ #define DMON_IMPL #include "dmon.h" #include "dmon_extra.h" +#endif #include "dirmonitor.h" @@ -32,14 +34,14 @@ static void send_sdl_event(dmon_watch_id watch_id, dmon_action action, const cha } void dirmonitor_init() { - dmon_init(); + //dmon_init(); /* In theory we should register our user event but since we have just one type of user event this is not really needed. */ /* sdl_dmon_event_type = SDL_RegisterEvents(1); */ } void dirmonitor_deinit() { - dmon_deinit(); + //dmon_deinit(); } void dirmonitor_watch_callback(dmon_watch_id watch_id, dmon_action action, const char *rootdir, @@ -49,11 +51,11 @@ void dirmonitor_watch_callback(dmon_watch_id watch_id, dmon_action action, const (void) user; switch (action) { case DMON_ACTION_MOVE: - send_sdl_event(watch_id, DMON_ACTION_DELETE, oldfilepath); - send_sdl_event(watch_id, DMON_ACTION_CREATE, filepath); + //send_sdl_event(watch_id, DMON_ACTION_DELETE, oldfilepath); + //send_sdl_event(watch_id, DMON_ACTION_CREATE, filepath); break; - default: - send_sdl_event(watch_id, action, filepath); + //default: + //send_sdl_event(watch_id, action, filepath); } }