/src/backend/android/ftk_source_android.c
http://ftk.googlecode.com/ · C · 46 lines · 35 code · 11 blank · 0 comment · 4 complexity · ada939f437b55baca29343b076390fd0 MD5 · raw file
- #include "ftk_source_android.h"
- static int ftk_source_android_get_fd(FtkSource* thiz)
- {
- return -1;
- }
- static int ftk_source_android_check(FtkSource* thiz)
- {
- return 0;
- }
- static Ret ftk_source_android_dispatch(FtkSource* thiz)
- {
- usleep(20000);
- return RET_OK;
- }
- static void ftk_source_android_destroy(FtkSource* thiz)
- {
- if(thiz != NULL)
- {
- FTK_ZFREE(thiz, sizeof(thiz));
- }
- }
- FtkSource* ftk_source_android_create(void)
- {
- FtkSource* thiz = NULL;
- thiz = (FtkSource*)FTK_ZALLOC(sizeof(FtkSource));
- if(thiz != NULL)
- {
- thiz->get_fd = ftk_source_android_get_fd;
- thiz->check = ftk_source_android_check;
- thiz->dispatch = ftk_source_android_dispatch;
- thiz->destroy = ftk_source_android_destroy;
- thiz->ref = 1;
- }
- return thiz;
- }