static void makeThumbWrapper ( void *state , ThreadEntry *t ) { Images *THIS = (Images *)state; // control loop if ( ! THIS->downloadImages() ) return; // all done THIS->m_callback ( THIS->m_state ); }
static void downloadImageWrapper ( void *state ) { Images *THIS = (Images *)state; // control loop if ( ! THIS->downloadImages() ) return; // all done THIS->m_callback ( THIS->m_state ); }
static void gotImgIpWrapper ( void *state , long ip ) { Images *THIS = (Images *)state; // control loop if ( ! THIS->downloadImages() ) return; // call callback at this point, we are done with the download loop THIS->m_callback ( THIS->m_state ); }
// Use of ThreadEntry parameter is NOT thread safe static void makeThumbWrapper ( void *state, job_exit_t exit_type ) { Images *THIS = (Images *)state; // control loop if ( ! THIS->downloadImages() ) return; // all done THIS->m_callback ( THIS->m_state ); }
// we got a reply void gotTermListWrapper ( void *state ) { Images *THIS = (Images *)state; // process/store the reply THIS->gotTermList(); // try to launch more, returns false if it blocks if ( ! THIS->launchRequests() ) return; // all done THIS->m_callback ( THIS->m_state ); }