DEMOPAGE_API HWND __stdcall Init(HWND hWndParent, unsigned __int64 gid, LPCTSTR pszUserPath)
{
if(g_pDllMainWnd == NULL)
{
g_pDllMainWnd = new CDllMainWnd;
g_pDllMainWnd->m_strText = pszUserPath;
g_pDllMainWnd->Create(NULL, _T("DllMainPage"), WS_CHILD|WS_VISIBLE, CRect(0,0,0,0),
CWnd::FromHandle(hWndParent), 2344);
}
return g_pDllMainWnd->m_hWnd;
}如题,请帮忙用delphi写一下。
{
if(g_pDllMainWnd == NULL)
{
g_pDllMainWnd = new CDllMainWnd;
g_pDllMainWnd->m_strText = pszUserPath;
g_pDllMainWnd->Create(NULL, _T("DllMainPage"), WS_CHILD|WS_VISIBLE, CRect(0,0,0,0),
CWnd::FromHandle(hWndParent), 2344);
}
return g_pDllMainWnd->m_hWnd;
}如题,请帮忙用delphi写一下。
begin
if(g_pDllMainWnd = 0) then
begin
g_pDllMainWnd.m_strText := pszUserPath;
g_pDllMainWnd.Create( 0 , _T('DllMainPage'), WS_CHILD + WS_VISIBLE, CRect(0,0,0,0), hWndParent.handle , 2344);
end;
result := g_pDllMainWnd.m_hWnd;
end;