#ifndef __MF_UG_LIST_PLAY_H #define __MF_UG_LIST_PLAY_H #include typedef enum { MF_PLAYER_CB_TYPE_STARTED, MF_PLAYER_CB_TYPE_PAUSED, MF_PLAYER_CB_TYPE_COMPLETED, MF_PLAYER_CB_TYPE_INTURRUPTED, MF_PLAYER_CB_TYPE_ERROR, MF_PLAYER_CB_TYPE_BUFFERING, MF_PLAYER_CB_TYPE_PREPARE, MF_PLAYER_CB_TYPE_NUM, } mf_player_cb_type; typedef struct __mf_player_cbs mf_player_cbs; struct __mf_player_cbs{ /* player callbacks */ player_started_cb started_cb; player_paused_cb paused_cb; player_completed_cb completed_cb; player_interrupted_cb interrupted_cb; player_error_cb error_cb; player_buffering_cb buffering_cb; player_prepared_cb prepare_cb; /* callback user data */ void *user_data[MF_PLAYER_CB_TYPE_NUM]; }; typedef struct { mf_player_cb_type cb_type; union { player_interrupted_code_e interrupted_code; int error_code; int percent; } param; } mf_player_cb_extra_data; #endif