#if !defined _FULLSCREEN_H_
#define _FULLSCREEN_H_

#pragma message ("compile FullScreenData")
//check this defines with cuik...
#define CUIK_WM_BASE								WM_USER+100
#define CUIK_WM_REQUIRE_WINDOW_IDENTIFICATION		CUIK_WM_BASE+12	
#define CUIKWND_EXTERNAL							0x00000002


struct FullScreenData
{
	enum FullScreenFlags
	{
		e_FS_Fullscreen			= 0x01,	//is target in fullscreen
		e_FS_parentIsZoomed		= 0x02,	//is target top parent (parent while fullscreen) maximized before FS
		e_FS_parentIsExternal	= 0x04,	//is target top parent (parent while fullscreen) external wnd
	};

	CWnd*	m_Target;					//the richedit
	CWnd*	m_OldParent;				//parent before fullscreen
	CWnd*	m_FullscreenParent;			//parent while fullscreen, ie Application wnd or external wnd
	HMENU	m_FullscreenParentMenu;		//menu Application wnd
	DWORD	m_Flags;					//FullScreenFlags
	RECT	m_TargetOldRect;			//old rect
	XArray<HWND> m_FSParentVisibleChildren;	//visible children depth = 1

	void ToggleFullscreen();

	FullScreenData() {Clear();}
	void Clear() {m_FSParentVisibleChildren.Clear();memset(this,0,sizeof(FullScreenData));}
	BOOL IsFullScreen() {return (m_Flags & e_FS_Fullscreen)?TRUE:FALSE;}
	BOOL IsFSParentZoomed() {return (m_Flags & e_FS_parentIsZoomed)?TRUE:FALSE;}
	BOOL IsFSParentExternal() {return (m_Flags & e_FS_parentIsExternal)?TRUE:FALSE;}
	void SetFullscreen(BOOL b) {if (b) m_Flags |=e_FS_Fullscreen;else m_Flags &=~e_FS_Fullscreen;}
	void SetFSParentZoomed(BOOL b) {if (b) m_Flags |=e_FS_parentIsZoomed;else m_Flags &=~e_FS_parentIsZoomed;}
	void SetFSParentExternal(BOOL b) {if (b) m_Flags |=e_FS_parentIsExternal;else m_Flags &=~e_FS_parentIsExternal;}
	void ShowFullScreenParentChildren(BOOL show);
};

#endif