#include <windows.h>
#include <stdio.h>
#include <rkcontroles.h>

/* rkcontroles.lib ole32.lib olepro32.lib pic.lib r:\programmation\projets_lcc_2004\calcul_lib\lcc\calcul_lib.lib shell32.lib uuid.lib shell32.lib*/

//#pragma lib <rkcontroles.lib>
//#pragma lib <ole32.lib>

int appelDlgMain(HWND hwndParent);

static BOOL enregClassedialog(HINSTANCE hInst);

HINSTANCE hInst = NULL;

int WINAPI WinMain(HINSTANCE hInstance,HINSTANCE hPrevInstance,LPSTR lpCmdLine,INT iCmdShow)
{
	/* Déclarations */

	/* Code */

	hInst = hInstance;


	enregClassedialog(hInst);

	InitialiserRKPicto(hInst);

	InitialiserRKRichEdit(hInst);
	/* Initialisation de l'utilisation du RGGraphe et RKGrapheBarre */

	//InitialiserRKGrBarres(hInst);

	/* Séparateur ajustable de fenêtres */
	//InitialiserRKSepar(hInst);


	appelDlgMain(NULL);

	//appelDlgImporterPhidusFiles(NULL);

	return 0;
}

/*------------------------------------------------------------------------
Procedure:     enregClassedialog ID:1
Purpose:
Input:
Output:
Errors:
------------------------------------------------------------------------*/
static BOOL enregClassedialog(HINSTANCE hInst)
{
	/*
	* declaration des variables locales
	* =================================
	*/
	WNDCLASSEX wcx;
/*
a1 = nomClasse
a2 = nomMenu
a3 = nomIcone
*/
	/*
	* code executable
	* ===============
	*/
	memset(&wcx,0,sizeof(WNDCLASSEX));

	wcx.cbSize = sizeof(WNDCLASSEX);
	wcx.lpfnWndProc = DefDlgProc;
	wcx.cbWndExtra = DLGWINDOWEXTRA;
	wcx.hInstance = hInst;
	wcx.hCursor = LoadCursor(NULL, IDC_ARROW);
	wcx.hbrBackground = (HBRUSH) (COLOR_WINDOW + 1);
	wcx.lpszClassName = "dialogNormal";
	wcx.lpszMenuName = NULL;
	wcx.hIcon = LoadIcon(hInst, NULL);
	wcx.hIconSm = NULL;


	if(RegisterClassEx(&wcx))
   		return TRUE;
	else
    	return FALSE;
}

