1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
   | // CodeCpp.cpp
 
#include "MaDll.h"
 
class UneClasse
{
private:
	int FonctionCallback(int, int);
	static int SFonctionCallback(intptr_t, int, int);
public:
	void AppelFonctionDll(void);
};
 
int UneClasse::SFonctionCallback(intptr_t user, int a, int b)
{
	UneClasse *this = reinterpret_cast< UneClasse * >(user);
	return this->FonctionCallback(a, b);
}
 
void UneClasse::AppelFonctionDll(void)
{
	FonctionQuiPrendUnCallback(SFonctionCallback, reinterpret_cast<intptr_t>(this));
} | 
Partager