// CSharpMainDialogGenerator.h
//

#if !defined(_CCSHARPMAINDIALOGGENERATOR_H_)
#define _CCSHARPMAINDIALOGGENERATOR_H_

#include "CSharpBaseGenerator.h"
#include "cmString.h"
#include <vector>

using namespace std;

class CXmlClassInfo;

class CCSharpMainDialogGenerator: public CCSharpBaseGenerator
{
public:
	CCSharpMainDialogGenerator();
	~CCSharpMainDialogGenerator();

	void Generate();

protected:
/***
	virtual void GenerateHeader();
	virtual void GenerateImplementation();

	// header file generators
	//
	void Head_generateHeader();
	void Head_generateIfDefBegin();
	void Head_generateIncludeSection();
	void Head_generateForwardDeclarations();
	void Head_generateForwardDeclarations(CXmlClassInfo* classInfo);
	void Head_generateDlgInclude(CXmlClassInfo* classInfo);
	void Head_generateDlgDeclare(CXmlClassInfo* classInfo);
	void Head_generateViewIndexDeclare(CXmlClassInfo* classInfo);
	void Head_generateDeclareChildDlg(CXmlClassInfo* classInfo);
	void Head_generateClassBegin();
	void Head_generateConstructor();
	void Head_generateDestructor();
	void Head_generateDialogData();
	void Head_generateGetSetData();
	void Head_generateOverrides();
	void Head_generateMessageMap();
	void Head_generateDataMembers();
	void Head_generateInitializeTree();
	void Head_generateStoreNodeData();
	void Head_generateBuildNode(CXmlClassInfo* classInfo, cmString parentPath);
	void Head_generateGetItem(CXmlClassInfo* classInfo, vector<CXmlClassInfo*> parentStack);
	void Head_generateInsertChildNode(CXmlClassInfo* classInfo, vector<CXmlClassInfo*> parentStack);
	void Head_generateOnOK();
	void Head_generateGetChildDialog();
	void Head_generateClassEnd();
	void Head_generateIfDefEnd();
	void Head_generateGetNodeInfo();
	void Head_generateDeleteNode();
	void Head_generateUpdateWindowSize();
	void Head_generateDisplayPopupMenu();
	void Head_generateUpdateNodeImages();
	void Head_generateInterfaceImplementation();
	void Head_generateDeleteArrayItemNode();
	void Head_generateSelectArrayItemNode();
	
	void Head_generateDeleteMapItemNode();
	void Head_generateSelectMapItemNode();
	void Head_generateReplaceMapKey(CXmlClassInfo* classInfo, vector<CXmlClassInfo*> parentStack);

	// implementation file generators
	//
	void Impl_generateHeader();
	void Impl_generateIncludeSection();
	void Impl_generateDebugSymbols();
	void Impl_generateMainTitle();
	void Impl_generateConstructor();
	void Impl_generateDestructor();
	void Impl_generateMessageMap();
	void Impl_generateOnInitDialog();
	void Impl_generateDlgCreate(CXmlClassInfo* classInfo);
	void Impl_generateDlgAddView(CXmlClassInfo* classInfo);
	void Impl_generateDeleteView(CXmlClassInfo* classInfo);
	void Impl_generateInsertChildNode(CXmlClassInfo* classInfo, int& count, vector<CXmlClassInfo*> parentStack);
	void Impl_generateInitializeTree();
	void Impl_generateStoreNodeData();
	void Impl_generateOnOK();
	void Impl_generateNodeInsertion(CXmlClassInfo* classInfo, CXmlClassInfo* parentClassInfo = NULL);
	void Impl_generateGetChildDialog();
	void Impl_generateOnNodeSelection();
	void Impl_generateGetSetData();
	void Impl_generateDialogSwitch(CXmlClassInfo* classInfo, int& count);
	void Impl_generateDialogSetDataSwitch(CXmlClassInfo* classInfo, vector<CXmlClassInfo*>parentStack, int& count);
	void Impl_generateDialogStoreDataSwitch(CXmlClassInfo* classInfo, int& count);
	void Impl_generateClassInclude(CXmlClassInfo* classInfo);
	void Impl_generateBuildNode(CXmlClassInfo* classInfo, int& count, cmString parentPath);
	void Impl_generateGetItem(CXmlClassInfo* classInfo, vector<CXmlClassInfo*> parentStack);
	void Impl_generateGetNodeInfo();
	void Impl_generateOnSize();
	void Impl_generateUpdateWindowSize();
	void Impl_generateDisplayPopupMenu();
	void Impl_generatePopupMenuDataSwitch(CXmlClassInfo* classInfo, int& count);
	void Impl_generateOnMnuAppendItem_Array();     
	void Impl_generateOnMnuAppendItem_OnMnuInsertItem_ArrayItem(); 
	void Impl_generateOnMnuAppendItem_OnMnuAppendItem_ArrayItem(); 
	void Impl_generateOnMnuAppendItem_OnMnuRemoveItem_ArrayItem(); 
	void Impl_generateOnMnuAppendItem_OnMnuCreateItem_Map();       
	void Impl_generateOnMnuAppendItem_OnMnuRemoveItem_MapItem();   
	void Impl_generateOnMnuAppendItem_OnMnuCreateItem_MapItem();   
	void Impl_generateMapCreateItem(CXmlClassInfo* classInfo, vector<CXmlClassInfo*> parentStack, int& count, cmString parentPath);
	void Impl_generateMapItemCreateItem(CXmlClassInfo* classInfo, vector<CXmlClassInfo*> parentStack, int& count, cmString parentPath);
	void Impl_generateMapItemRemoveItem(CXmlClassInfo* classInfo, vector<CXmlClassInfo*> parentStack, int& count, cmString parentPath);
	void Impl_generateDeleteNode();
	void Impl_generateUpdateNodeImages();
	void Impl_generateInterfaceImplementation();
	void Impl_generateDeleteArrayItemNode();
	void Impl_generateSelectArrayItemNode();
	void Impl_generateDeleteMapItemNode();
	void Impl_generateSelectMapItemNode();
	void Impl_generateReplaceMapKey(CXmlClassInfo* classInfo, vector<CXmlClassInfo*> parentStack);

	cmString Impl_generateVarPath(CXmlClassInfo* classInfo, vector<CXmlClassInfo*>& parentStack, bool containerVarOnly = false);
	void Impl_generateChildDlgInit(CXmlClassInfo* classInfo);
	void Impl_generateChildDlgDelete(CXmlClassInfo* classInfo);
	void Impl_generateChildDlgInclude(CXmlClassInfo* classInfo);

	cmString implCode_;
	cmString headCode_;

  ***/
};

#endif
