Add rayman2 source files

This commit is contained in:
2024-09-18 02:33:44 +08:00
parent bcc093f8ed
commit fb036c54fd
14339 changed files with 2596224 additions and 0 deletions

View File

@@ -0,0 +1,492 @@
//Microsoft Developer Studio generated resource script.
//
#include "..\inc\_zRes.h"
#define APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 2 resource.
//
#include "afxres.h"
/////////////////////////////////////////////////////////////////////////////
#undef APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
// English (U.S.) resources
#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)
#ifdef _WIN32
LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US
#pragma code_page(1252)
#endif //_WIN32
/////////////////////////////////////////////////////////////////////////////
//
// Dialog
//
IDD_CHECK_ZONES_AGAINST_BV DIALOG DISCARDABLE 0, 0, 237, 170
STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
CAPTION "WARNING!"
FONT 8, "MS Sans Serif"
BEGIN
DEFPUSHBUTTON "OK",IDOK,52,149,50,14
PUSHBUTTON "Cancel",IDCANCEL,135,149,50,14
LTEXT "WARNING! These zones exceed the bounding volume limits. ",
IDC_STATIC,20,7,197,8
CONTROL "Check zones against the bounding volume",
IDC_CHECK_ZONES,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,18,
131,150,10
LTEXT "Do you want to update the bounding volume now?",
IDC_STATIC,18,118,160,8
CONTROL "Yes",IDC_CHECK_YES,"Button",BS_AUTOCHECKBOX |
WS_TABSTOP,192,118,28,10
LISTBOX IDC_LIST_ZONES,28,22,181,86,LBS_SORT |
LBS_NOINTEGRALHEIGHT | WS_VSCROLL | WS_TABSTOP
END
/////////////////////////////////////////////////////////////////////////////
//
// DESIGNINFO
//
#ifdef APSTUDIO_INVOKED
GUIDELINES DESIGNINFO DISCARDABLE
BEGIN
IDD_CHECK_ZONES_AGAINST_BV, DIALOG
BEGIN
LEFTMARGIN, 7
RIGHTMARGIN, 230
TOPMARGIN, 7
BOTTOMMARGIN, 163
END
END
#endif // APSTUDIO_INVOKED
#endif // English (U.S.) resources
/////////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////
// French (France) resources
#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_FRA)
#ifdef _WIN32
LANGUAGE LANG_FRENCH, SUBLANG_FRENCH
#pragma code_page(1252)
#endif //_WIN32
/////////////////////////////////////////////////////////////////////////////
//
// Dialog
//
IDD_ZDD_Info_Window DIALOG DISCARDABLE 0, 0, 106, 99
STYLE WS_CHILD
FONT 8, "Arial"
BEGIN
RTEXT "&Name :",IDC_Static_Text_Name,2,3,26,10
EDITTEXT IDC_Edition_Zone_Name,31,3,57,12,ES_AUTOHSCROLL |
WS_DISABLED
RTEXT "Type :",IDC_Static_Text_Type,2,17,26,10
PUSHBUTTON "Apply",IDC_Apply_Button,2,32,41,15,WS_DISABLED
PUSHBUTTON "Cancel",IDC_Cancel_Button,48,32,41,15,WS_DISABLED
LTEXT "",IDC_Pos_Shape_Info_Window,2,50,78,35,NOT WS_GROUP
EDITTEXT IDC_Edition_Zone_Type,31,17,57,12,ES_AUTOHSCROLL |
WS_DISABLED
END
IDD_ZDD_Sphere_Info_Window DIALOGEX 0, 0, 85, 80
STYLE WS_CHILD
EXSTYLE WS_EX_CLIENTEDGE
FONT 8, "Arial", 0, 0, 0x1
BEGIN
GROUPBOX "Center",IDC_Frame,5,0,60,45
RTEXT "&X :",IDC_Static_Text_Center_X,10,10,10,8
RTEXT "&Y :",IDC_Static_Text_Center_Y,10,20,10,8
RTEXT "&Z :",IDC_Static_Text_Center_Z,10,30,10,8
LTEXT "&Radius :",IDC_Static_Text_Radius,5,49,28,10
EDITTEXT IDC_Edition_Zone_Center_X,25,10,35,12,ES_AUTOHSCROLL
EDITTEXT IDC_Edition_Zone_Center_Y,25,20,35,12,ES_AUTOHSCROLL
EDITTEXT IDC_Edition_Zone_Center_Z,25,30,35,12,ES_AUTOHSCROLL
EDITTEXT IDC_Edition_Zone_Radius,34,47,30,12,ES_AUTOHSCROLL
CONTROL "Slider1",IDC_Slider_Radius,"msctls_trackbar32",
TBS_AUTOTICKS | WS_TABSTOP,1,59,65,13
CTEXT "0",IDC_Static_Text_0,5,72,8,8
CTEXT "1",IDC_Static_Text_1,39,72,8,8
CTEXT "1.5",IDC_Static_Text_1_5,54,72,11,8
PUSHBUTTON "&Ini",IDC_Button_Init,67,61,16,12
END
IDD_ZDD_Box_Info_Window_1 DIALOG DISCARDABLE 0, 0, 129, 85
STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_VISIBLE | WS_CAPTION |
WS_SYSMENU
CAPTION "ZDD Box"
FONT 8, "Arial"
BEGIN
CONTROL "Ce&nter",IDC_Radio_Button_Center,"Button",
BS_AUTORADIOBUTTON,5,5,37,10
CONTROL "&Extrema",IDC_Radio_Button_Extrema,"Button",
BS_AUTORADIOBUTTON,40,5,43,10
GROUPBOX "Center",IDC_Frame,5,15,55,45
RTEXT "&X :",IDC_Static_Text_Center_X,10,25,10,8
EDITTEXT IDC_Edition_Zone_Center_X,25,25,30,10,ES_AUTOHSCROLL
RTEXT "&Y :",IDC_Static_Text_Center_Y,10,35,10,8
EDITTEXT IDC_Edition_Zone_Center_Y,25,35,30,10,ES_AUTOHSCROLL
RTEXT "&Z :",IDC_Static_Text_Center_Z,10,45,10,8
EDITTEXT IDC_Edition_Zone_Center_Z,25,45,30,10,ES_AUTOHSCROLL
RTEXT "&Length :",IDC_Static_Text_Length,60,25,30,10
EDITTEXT IDC_Edition_Zone_Length,95,25,30,10,ES_AUTOHSCROLL
RTEXT "&Width:",IDC_Static_Text_Width,60,35,30,10
EDITTEXT IDC_Edition_Zone_Width,95,35,30,10,ES_AUTOHSCROLL
RTEXT "&Height :",IDC_Static_Text_Height,60,45,30,10
EDITTEXT IDC_Edition_Zone_Height,95,45,30,10,ES_AUTOHSCROLL
CONTROL "Cu&be",IDC_Check_Box_Cube,"Button",BS_AUTOCHECKBOX |
WS_TABSTOP,5,65,45,10
PUSHBUTTON "&OK",IDC_OK_Button,65,65,25,15
PUSHBUTTON "&Cancel",IDC_Cancel_Button,95,65,30,15
END
IDD_ZDD_Box_Info_Window_2 DIALOG DISCARDABLE 0, 0, 129, 85
STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_VISIBLE | WS_CAPTION |
WS_SYSMENU
CAPTION "ZDD Box"
FONT 8, "Arial"
BEGIN
RTEXT "X :",IDC_Static_Text_X_Mini,10,25,10,8
GROUPBOX "&Mini",IDC_Frame_Mini,5,15,55,45
RTEXT "Y :",IDC_Static_Text_Y_Mini,10,35,10,8
RTEXT "Z :",IDC_Static_Text_Z_Mini,10,45,10,8
EDITTEXT IDC_Edition_Zone_X_Mini,25,25,30,10,ES_AUTOHSCROLL
EDITTEXT IDC_Edition_Zone_Y_Mini,25,35,30,10,ES_AUTOHSCROLL
EDITTEXT IDC_Edition_Zone_Z_Mini,25,45,30,10,ES_AUTOHSCROLL
PUSHBUTTON "&OK",IDC_OK_Button,65,65,25,15
PUSHBUTTON "&Cancel",IDC_Cancel_Button,95,65,30,15
CONTROL "Cu&be",IDC_Check_Box_Cube,"Button",BS_AUTOCHECKBOX |
WS_TABSTOP,5,65,45,10
CONTROL "Ce&nter",IDC_Radio_Button_Center,"Button",
BS_AUTORADIOBUTTON,5,5,35,10
CONTROL "&Extrema",IDC_Radio_Button_Extrema,"Button",
BS_AUTORADIOBUTTON,40,5,43,10
RTEXT "X :",IDC_Static_Text_X_Maxi,75,25,10,8
GROUPBOX "Ma&xi",IDC_Frame_Maxi,70,15,55,45
RTEXT "Y :",IDC_Static_Text_Y_Maxi,75,35,10,8
RTEXT "Z :",IDC_Static_Text_Z_Maxi,75,45,10,8
EDITTEXT IDC_Edition_Zone_X_Maxi,90,25,30,10,ES_AUTOHSCROLL
EDITTEXT IDC_Edition_Zone_Y_Maxi,90,35,30,10,ES_AUTOHSCROLL
EDITTEXT IDC_Edition_Zone_Z_Maxi,90,45,30,10,ES_AUTOHSCROLL
END
IDD_ZDD_Box_Info_Window DIALOGEX 0, 0, 129, 83
STYLE WS_CHILD
EXSTYLE WS_EX_CLIENTEDGE
FONT 8, "Arial", 0, 0, 0x1
BEGIN
CONTROL "Ce&nter",IDC_Radio_Button_Center,"Button",
BS_AUTORADIOBUTTON | WS_GROUP,5,5,35,10
CONTROL "&Extrema",IDC_Radio_Button_Extrema,"Button",
BS_AUTORADIOBUTTON,45,5,43,10
GROUPBOX "Center",IDC_Frame_Center,5,15,55,45
RTEXT "&X :",IDC_Static_Text_Center_X,10,25,10,8
EDITTEXT IDC_Edition_Zone_Center_X,25,25,30,12,ES_AUTOHSCROLL
RTEXT "&Y :",IDC_Static_Text_Center_Y,10,35,10,8
EDITTEXT IDC_Edition_Zone_Center_Y,25,35,30,12,ES_AUTOHSCROLL
RTEXT "&Z :",IDC_Static_Text_Center_Z,10,45,10,8
EDITTEXT IDC_Edition_Zone_Center_Z,25,45,30,12,ES_AUTOHSCROLL
GROUPBOX "Ma&xi",IDC_Frame_Maxi,70,15,55,45
RTEXT "&Length :",IDC_Static_Text_Length,61,25,29,10
RTEXT "X :",IDC_Static_Text_X_Maxi,75,25,10,8
RTEXT "&Width:",IDC_Static_Text_Width,65,35,25,10
RTEXT "Y :",IDC_Static_Text_Y_Maxi,75,35,10,8
RTEXT "&Height :",IDC_Static_Text_Height,65,45,25,10
RTEXT "Z :",IDC_Static_Text_Z_Maxi,75,45,10,8
EDITTEXT IDC_Edition_Zone_X_Maxi,90,25,30,12,ES_AUTOHSCROLL
EDITTEXT IDC_Edition_Zone_Length,95,25,30,12,ES_AUTOHSCROLL
EDITTEXT IDC_Edition_Zone_Y_Maxi,90,35,30,12,ES_AUTOHSCROLL
EDITTEXT IDC_Edition_Zone_Width,95,35,30,12,ES_AUTOHSCROLL
EDITTEXT IDC_Edition_Zone_Z_Maxi,90,45,30,12,ES_AUTOHSCROLL
EDITTEXT IDC_Edition_Zone_Height,95,45,30,12,ES_AUTOHSCROLL
CONTROL "Cu&be",IDC_Check_Box_Cube,"Button",BS_AUTOCHECKBOX |
WS_TABSTOP,5,62,31,10
RTEXT "X :",IDC_Static_Text_X_Mini,10,25,10,8
GROUPBOX "&Mini",IDC_Frame_Mini,5,15,55,45
RTEXT "Y :",IDC_Static_Text_Y_Mini,10,35,10,8
RTEXT "Z :",IDC_Static_Text_Z_Mini,10,45,10,8
EDITTEXT IDC_Edition_Zone_X_Mini,25,25,30,12,ES_AUTOHSCROLL
EDITTEXT IDC_Edition_Zone_Y_Mini,25,35,30,12,ES_AUTOHSCROLL
EDITTEXT IDC_Edition_Zone_Z_Mini,25,45,30,12,ES_AUTOHSCROLL
CONTROL "Slider1",IDC_Slider_Size,"msctls_trackbar32",
TBS_AUTOTICKS | WS_TABSTOP,41,60,65,13
CTEXT "0",IDC_Static_Text_0,45,73,8,8
CTEXT "1",IDC_Static_Text_1,79,73,8,8
CTEXT "1.5",IDC_Static_Text_1_5,94,73,11,8
PUSHBUTTON "&Ini",IDC_Button_Init,107,62,16,12
END
IDD_ZDD_Point_Info_Window DIALOGEX 0, 0, 63, 43
STYLE WS_CHILD
EXSTYLE WS_EX_CLIENTEDGE
FONT 8, "Arial", 0, 0, 0x1
BEGIN
RTEXT "&X :",IDC_Static_Text_X,5,5,10,8
EDITTEXT IDC_Edition_Zone_X,20,5,40,10,ES_AUTOHSCROLL
RTEXT "&Y :",IDC_Static_Text_Y,5,15,10,8
EDITTEXT IDC_Edition_Zone_Y,20,15,40,10,ES_AUTOHSCROLL
RTEXT "&Z :",IDC_Static_Text_Z,5,25,10,8
EDITTEXT IDC_Edition_Zone_Z,20,25,40,10,ES_AUTOHSCROLL
END
IDD_ZDD_List1_Window DIALOG DISCARDABLE 0, 0, 147, 66
STYLE WS_CHILD | WS_BORDER
FONT 8, "MS Sans Serif"
BEGIN
PUSHBUTTON "",IDC_Button_Return,2,17,19,13,BS_BITMAP
CONTROL "Tree1",IDC_Tree_Ctrl_1,"SysTreeView32",TVS_HASBUTTONS |
TVS_HASLINES | TVS_LINESATROOT | TVS_EDITLABELS |
TVS_SHOWSELALWAYS | WS_BORDER | WS_TABSTOP,2,34,145,30
COMBOBOX IDC_Combo_Box_List_1,2,0,145,105,CBS_DROPDOWNLIST |
CBS_OWNERDRAWFIXED | CBS_HASSTRINGS | WS_VSCROLL |
WS_TABSTOP
CONTROL "",IDC_Check_Button_Show_Actor,"Button",BS_AUTOCHECKBOX |
BS_BITMAP | BS_PUSHLIKE | WS_TABSTOP,26,17,19,13
CONTROL "",IDC_Check_Button_Show_Module,"Button",BS_AUTOCHECKBOX |
BS_BITMAP | BS_PUSHLIKE | WS_TABSTOP,50,17,19,13
CONTROL "",IDC_Check_Button_Show_Module_ZDx,"Button",
BS_AUTOCHECKBOX | BS_BITMAP | BS_PUSHLIKE | WS_TABSTOP,
74,17,19,13
CONTROL "",IDC_Check_Button_Bounding_Volume,"Button",
BS_AUTOCHECKBOX | BS_BITMAP | BS_PUSHLIKE | WS_TABSTOP,
98,17,19,13
CONTROL "",IDC_Check_Button_Test_Point,"Button",BS_AUTOCHECKBOX |
BS_BITMAP | BS_PUSHLIKE | WS_DISABLED | WS_TABSTOP,122,
17,19,13
END
IDD_ZDD_List2_Window DIALOG DISCARDABLE 0, 0, 96, 64
STYLE WS_CHILD
FONT 8, "MS Sans Serif"
BEGIN
CONTROL "ZD&D",IDC_Check_Box_ZDD,"Button",BS_AUTOCHECKBOX |
WS_TABSTOP,5,2,30,13
CONTROL "ZD&E",IDC_Check_Box_ZDE,"Button",BS_AUTOCHECKBOX |
WS_TABSTOP,39,2,30,13
CONTROL "ZD&M",IDC_Check_Box_ZDM,"Button",BS_AUTOCHECKBOX |
WS_TABSTOP,5,15,30,13
CONTROL "ZD&R",IDC_Check_Box_ZDR,"Button",BS_AUTOCHECKBOX |
WS_TABSTOP,39,15,30,13
PUSHBUTTON "&All",IDC_Button_All_ZDx,70,5,25,10
COMBOBOX IDC_Combo_Box_List,1,31,69,95,CBS_DROPDOWNLIST |
WS_VSCROLL | WS_TABSTOP
LISTBOX IDC_List_Ctrl_2,0,46,95,18,LBS_OWNERDRAWFIXED |
LBS_HASSTRINGS | LBS_NOINTEGRALHEIGHT |
LBS_WANTKEYBOARDINPUT | WS_VSCROLL | WS_TABSTOP
PUSHBUTTON "&New",IDC_Button_New_List,73,31,22,12,NOT WS_VISIBLE
PUSHBUTTON "N&one",IDC_Button_No_ZDx,70,15,25,10
END
IDD_ZDD_Cone_Info_Window DIALOGEX 0, 0, 123, 74
STYLE WS_CHILD
EXSTYLE WS_EX_CLIENTEDGE
FONT 8, "MS Sans Serif", 0, 0, 0x1
BEGIN
RTEXT "X :",IDC_Static_Text_X_Top,11,11,10,9
GROUPBOX "&Top",IDC_Frame_Top,5,0,55,49
RTEXT "Y :",IDC_Static_Text_Y_Top,11,22,10,9
RTEXT "Z :",IDC_Static_Text_Z_Top,11,33,10,9
EDITTEXT IDC_Edition_Zone_X_Top,25,11,30,11,ES_AUTOHSCROLL
EDITTEXT IDC_Edition_Zone_Y_Top,25,22,30,11,ES_AUTOHSCROLL
EDITTEXT IDC_Edition_Zone_Z_Top,25,33,30,11,ES_AUTOHSCROLL
RTEXT "X :",IDC_Static_Text_X_Base,71,10,10,9
GROUPBOX "&Base",IDC_Frame_Base,65,0,55,49
RTEXT "Y :",IDC_Static_Text_Y_Base,71,21,10,9
RTEXT "Z :",IDC_Static_Text_Z_Base,71,32,10,9
EDITTEXT IDC_Edition_Zone_X_Base,84,10,30,11,ES_AUTOHSCROLL
EDITTEXT IDC_Edition_Zone_Y_Base,84,21,30,11,ES_AUTOHSCROLL
EDITTEXT IDC_Edition_Zone_Z_Base,84,32,30,11,ES_AUTOHSCROLL
LTEXT "&Radius :",IDC_Static_Text_Radius,10,50,30,11
EDITTEXT IDC_Edition_Zone_Radius,40,50,35,11,ES_AUTOHSCROLL
LTEXT "&Angle :",IDC_Static_Text_Angle,10,60,30,11
EDITTEXT IDC_Edition_Zone_Angle,40,60,35,11,ES_AUTOHSCROLL
END
IDD_ZDD_Display_Control_Window DIALOG DISCARDABLE 0, 0, 121, 51
STYLE WS_CHILD
FONT 8, "MS Sans Serif"
BEGIN
GROUPBOX "&All actors",IDC_Frame_All_Actors,2,2,117,24
CONTROL "On",IDC_Radio_Button_All_Actors_On,"Button",
BS_AUTORADIOBUTTON | BS_PUSHLIKE | WS_GROUP | WS_TABSTOP,
8,11,25,11
CONTROL "Off",IDC_Radio_Button_All_Actors_Off,"Button",
BS_AUTORADIOBUTTON | BS_PUSHLIKE,40,11,25,11
CONTROL "Selected",IDC_Radio_Button_All_Actors_Selected,"Button",
BS_AUTORADIOBUTTON | BS_PUSHLIKE,70,11,44,11
GROUPBOX "&Current actor",IDC_Frame_Current_Actor,2,26,117,24
CONTROL "On",IDC_Radio_Button_Current_Actor_On,"Button",
BS_AUTORADIOBUTTON | BS_PUSHLIKE | WS_GROUP | WS_TABSTOP,
8,35,25,11
CONTROL "Off",IDC_Radio_Button_Current_Actor_Off,"Button",
BS_AUTORADIOBUTTON | BS_PUSHLIKE,40,35,25,11
CONTROL "Selected",IDC_Radio_Button_Current_Actor_Selected,
"Button",BS_AUTORADIOBUTTON | BS_PUSHLIKE,70,35,44,11
END
/////////////////////////////////////////////////////////////////////////////
//
// DESIGNINFO
//
#ifdef APSTUDIO_INVOKED
GUIDELINES DESIGNINFO DISCARDABLE
BEGIN
IDD_ZDD_Info_Window, DIALOG
BEGIN
LEFTMARGIN, 2
RIGHTMARGIN, 104
TOPMARGIN, 3
BOTTOMMARGIN, 97
END
IDD_ZDD_Sphere_Info_Window, DIALOG
BEGIN
RIGHTMARGIN, 83
END
IDD_ZDD_Box_Info_Window_1, DIALOG
BEGIN
LEFTMARGIN, 7
RIGHTMARGIN, 122
TOPMARGIN, 7
BOTTOMMARGIN, 78
END
IDD_ZDD_Box_Info_Window_2, DIALOG
BEGIN
LEFTMARGIN, 7
RIGHTMARGIN, 122
TOPMARGIN, 7
BOTTOMMARGIN, 78
END
IDD_ZDD_Point_Info_Window, DIALOG
BEGIN
LEFTMARGIN, 7
RIGHTMARGIN, 56
TOPMARGIN, 7
BOTTOMMARGIN, 36
END
IDD_ZDD_List1_Window, DIALOG
BEGIN
LEFTMARGIN, 2
RIGHTMARGIN, 121
BOTTOMMARGIN, 59
END
IDD_ZDD_List2_Window, DIALOG
BEGIN
TOPMARGIN, 7
END
IDD_ZDD_Cone_Info_Window, DIALOG
BEGIN
LEFTMARGIN, 7
RIGHTMARGIN, 116
TOPMARGIN, 7
BOTTOMMARGIN, 67
END
IDD_ZDD_Display_Control_Window, DIALOG
BEGIN
LEFTMARGIN, 2
RIGHTMARGIN, 119
TOPMARGIN, 2
END
END
#endif // APSTUDIO_INVOKED
#ifdef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// TEXTINCLUDE
//
1 TEXTINCLUDE DISCARDABLE
BEGIN
"..\\inc\\_zRes.h\0"
END
2 TEXTINCLUDE DISCARDABLE
BEGIN
"#include ""afxres.h""\r\n"
"\0"
END
3 TEXTINCLUDE DISCARDABLE
BEGIN
"\r\n"
"\0"
END
#endif // APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// Bitmap
//
IDB_Bitmap_Return BITMAP DISCARDABLE "..\\res\\zReturn.bmp"
IDB_Bitmap_Show_Actor BITMAP DISCARDABLE "..\\res\\zShowAct.bmp"
IDB_Bitmap_Show_Module BITMAP DISCARDABLE "..\\res\\zShowMod.bmp"
IDB_Bitmap_Show_Module_ZDx BITMAP DISCARDABLE "..\\res\\zShowZDx.bmp"
IDB_Bitmap_Bounding_Volume BITMAP DISCARDABLE "..\\res\\zBoundin.bmp"
IDB_Bitmap_Test_Point BITMAP DISCARDABLE "..\\res\\zTestPnt.bmp"
/////////////////////////////////////////////////////////////////////////////
//
// Icon
//
// Icon with lowest ID value placed first to ensure application icon
// remains consistent on all systems.
IDI_Icon_Family ICON DISCARDABLE "..\\res\\zFamily.ico"
IDI_Icon_Model ICON DISCARDABLE "..\\res\\zModel.ico"
IDI_Icon_Instance ICON DISCARDABLE "..\\res\\zInstanc.ico"
IDI_Icon_Module ICON DISCARDABLE "..\\res\\zModule.ico"
IDI_Icon_ZDx ICON DISCARDABLE "..\\res\\zZone.ico"
IDI_Icon_Big_Global_Zone ICON DISCARDABLE "..\\res\\zBigZone.ico"
IDI_Icon_Common_Mode ICON DISCARDABLE "..\\res\\zCommon.ico"
IDI_Icon_Shared_Mode ICON DISCARDABLE "..\\res\\zShared.ico"
IDI_Icon_Virge_Mode ICON DISCARDABLE "..\\res\\zVirge.ico"
IDI_Icon_Motor_Display_On ICON DISCARDABLE "..\\res\\zShowOn.ico"
IDI_Icon_Motor_Display_Off ICON DISCARDABLE "..\\res\\zShowOff.ico"
IDI_Icon_Used_Module ICON DISCARDABLE "..\\res\\zUsedMod.ico"
IDI_ZDX_DLGBAR_ICON ICON DISCARDABLE "..\\res\\zdx_dlgb.ico"
/////////////////////////////////////////////////////////////////////////////
//
// Cursor
//
IDC_Cursor_Drag_And_Drop CURSOR DISCARDABLE "..\\res\\zDragCur.cur"
IDC_Cursor_No_Drag_And_Drop CURSOR DISCARDABLE "..\\res\\zNoDrag.cur"
#endif // French (France) resources
/////////////////////////////////////////////////////////////////////////////
#ifndef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 3 resource.
//
/////////////////////////////////////////////////////////////////////////////
#endif // not APSTUDIO_INVOKED

View File

@@ -0,0 +1,20 @@
// stdafx.h : include file for standard system include files,
// or project specific include files that are used frequently, but
// are changed infrequently
//
#ifndef __STDAAFX_H__
#define __STDAAFX_H__
#pragma once
#define VC_EXTRALEAN // Exclude rarely-used stuff from Windows headers
#include <afxwin.h> // MFC core and standard components
#include <afxext.h> // MFC extensions
#ifndef _AFX_NO_AFXCMN_SUPPORT
#include <afxcmn.h> // MFC support for Windows 95 Common Controls
#endif // _AFX_NO_AFXCMN_SUPPORT
#endif //__STDAAFX_H__

View File

@@ -0,0 +1,621 @@
//*****************************************************************************
//* _zInterf.hpp *
//*****************************************************************************
//* *
//* This file contains the definition of the ZDx_Interface class. *
//* *
//*****************************************************************************
//* Author : Alexis Vaisse *
//*****************************************************************************
#ifndef __ZINTERF_HPP__
#define __ZINTERF_HPP__
#pragma once
// if you want only one instance of your DLL, activate the next line
#define DLL_ONLY_ONE_INSTANCE
#include "IncITF.h"
// Actors dll "include"
class CPA_Actor;
class EdtList;
class CPA_tdoNameList;
// Physical Object dll "include"
class EditorPO;
// Family dll "include"
// ANNECY AV CLEAN_MEC {
//class CPA_TestPointsList;
// END ANNECY AV }
typedef enum eZDxConstraintType_ { eZDxNormal , eZDxModifyAllActors , eZDxModifyOneActor } tdeZDxConstraintType;
// personal "include"
#include "_zObject.hpp"
class ZDx_Object;
class ZDx_Modif;
class CDisplayControlWindow;
class CList1Window;
class CList2Window;
class CZDxInfoWindow;
class EdtList;
// Flags for the function : ShowZDxOfInstance
#define C_ucHideAllZDx 0
#define C_ucShowZDD 1
#define C_ucShowZDE 2
#define C_ucShowZDM 4
#define C_ucShowZDR 8
#define C_ucShowAllZDx (C_ucShowZDD + C_ucShowZDE + C_ucShowZDM + C_ucShowZDR)
// ANNECY AV CLEAN_MEC {
//#define C_ucShowTestPoint 16
// END ANNECY AV }
// Constant for the RefreshDisplay function
#define C_lOnInsertActor 1
#define C_lOnDeleteActor 2
#define C_lOnInsertZDxOfActor 3
#define C_lOnDeleteZDxOfActor 4
#define C_lOnInsertZDxOfModule 5
#define C_lOnDeleteZDxOfModule 6
#define C_lOnInsertBV 7
#define C_lOnDeleteBV 8
// ANNECY AV CLEAN_MEC {
//#define C_lOnInsertTestPoint 9
//#define C_lOnDeleteTestPoint 10
// END ANNECY AV }
#define C_lOnSelectActor 11
#define C_lOnSelectZDxOfActor 12
#define C_lOnMouseMove 13
#define C_lOnSelChangeTreeCtrl1 14
#define C_lOnSelChangeTreeCtrl2 15
#define C_lOnSelChangeCombo2 16
#define C_lOnCheckBoxShowActor 17
#define C_lOnCheckBoxShowModule 18
#define C_lOnCheckBoxesZDx 19
#define C_lOnButtonAllZDx 20
#define C_ucSetCamera 21
#define C_lRedrawZDxObject 22
#define C_lModifZDx 23
#define C_lModifDeleteDo 24
#define C_lModifDeleteUndo 25
#define C_lShowZDxOfAllActors 26
#define C_lOnButtonAllActors 27
#define C_lShowZDxSelectedActor 28
#define C_lHideZDxSelectedActor 29
#define C_lShowModuleZDxActor 30
#define C_lHideModuleZDxActor 31
#define C_lPopupMenuShowZone 32
#define C_lShowZDxOfOneModule 33
#define C_lShowZDxOfAllModule 34
#define C_lEnterBoundingVolume 35
#define C_lLeaveBoundingVolume 36
// ANNECY AV CLEAN_MEC {
//#define C_lEnterTestPoint 37
//#define C_lLeaveTestPoint 38
// END ANNECY AV }
#define C_lLButtonDown 39
// Name of the list of ZDx models
#define C_szZDxListName "Zone"
//-----------------------------------------------------------------------------
// stSizeChangingMode structure
// used when the user changes the size of the ZDx object with the mouse
//-----------------------------------------------------------------------------
typedef struct stSizeChangingMode_
{
BOOL bActiveMode; // Are we in "size changing" mode ?
CPA_SuperObject * pSelectedZDxSuperObject; // The ZDx object whose size is changing
MTH3D_tdstVector GlobalSelectedPoint; // The 3D coordinates of the point of the ZDx object pointed by the mouse in the global repere
MTH3D_tdstVector LocalSelectedPoint; // The 3D coordinates of the same point in the local repere
MTH3D_tdstVector CenterInMousePlane; // The 3D coordinates of the center of the sphere, projected into the plane where the mouse moves into
ZDx_Modif * pZDxModif;
BOOL bChangeTopPointOfCone; // When changing the size of a cone : if TRUE, change the top point, else change the radius
} tdstSizeChangingMode;
//-----------------------------------------------------------------------------
// Object DLL interface class
//-----------------------------------------------------------------------------
class ZDx_Interface : public CPA_ObjectDLLBase
{
public:
ZDx_Interface (void); // Constructor
//-------------------------------------------
//--- Virtual functions of the base class --- (file : _zInterf.cpp)
//-------------------------------------------
// --- General functions for editor ---
public:
void fn_vJustAfterRegistered(void); // Called for the first initializations
void fn_vConstruct (void); // Called once the 3D window is constructed
void fn_vBeforeEditor (void); // Called just before entering editor mode
void fn_vBeforeEngine (void); // Called just before leaving editor mode
void fn_vOnActivateEditor (CPA_List<CPA_BaseObject> * pParams , BOOL bBackActivated = FALSE);
// Called when somebody wants to open the ZDx editor
void fn_vOnCloseEditor (void); // Called when somebody wants to close the ZDx editor
BOOL fn_bHasGainedFocus (void); // Called when the dll becomes the current dll
void fn_vHasLostFocus (void); // Called when the dll is no longer the current dll
long OnQueryAction (CPA_EditorBase * pCallingDll , WPARAM , LPARAM);
// To communicate with the dll
long OnQueryInfos (CPA_EditorBase * pCallingDll , WPARAM , LPARAM);
// To communicate with the dll
/*===========================================================================
Dialog Bar - Mircea Dunka 31 Aug. 1998
=========================================================================*/
public:
void fn_vDefineDlgBarBtnIcon (tde_DlgBarCategory wCategory, tds_DlgBarBtn *_pDlgBarBtn);
// --- Menu ---
public:
BOOL fn_bDefineSubMenu (EDT_SubMenu * _p_oEDTSubMenu); // This function lets the dll add an entry in a sub menu
void _OnSubMenuCommand (EDT_SubMenu * _p_oEDTSubMenu,UINT uiMsgID); // Called when the user clics on an entry in a sub menu
BOOL fn_bDefinePopupMenu (EDT_PopUpMenu * pPopup , CPA_List<CPA_SuperObject> * pSelection , BOOL bAsCurrentEditor);
// This function lets the dll add an entry in the popup menu
void _OnPopUpMenuCommand (UINT m_IDCmdMsg); // Called when the user clics on an entry in the popup menu
// --- Questions to manage ZDx objects ---
public:
BOOL fn_bCanActivateEditor (CPA_List<CPA_BaseObject> * _pParams); // Return if the editor can be activated
BOOL fn_bCanHandleThisType (long lEngineType); // The type of the objects we can handle
tdePermission fn_eAcceptNewEditor (CPA_EditorBase * pNewDLL) // When another editor is activated, we want to close the window
{ return C_CloseBefore; }
BOOL fn_bAcceptModifRotate (CPA_List<CPA_SuperObject> * pListObjects , tdeStatus eStatus)
// We don't want the rotation matrix of a ZDx object to be modified
{ return eStatus != C_AsConcernedDLL; }
BOOL fn_bAcceptModifScale (CPA_SuperObject * pEdObj , tdeStatus eStatus) // We don't want the scale of a ZDx object to be modified
{ return eStatus != C_AsConcernedDLL; }
BOOL fn_bAcceptModifParent (CPA_List<CPA_SuperObject> * pListObjects , tdeStatus eStatus);
// One cannot change the parent of a zone
BOOL fn_bAcceptModifCopy (CPA_List<CPA_SuperObject> * pListObjects , tdeStatus eStatus);
// A ZDx object can be copied
BOOL fn_bAcceptAsChild (CPA_BaseObject * pParent, CPA_BaseObject * pChild)
{ return FALSE; } // We don't want any child for a ZDx object
BOOL fn_bAcceptAsParent (CPA_BaseObject * pChild , CPA_BaseObject * pParent);
// Only actors or modules can be parent for a ZDx object
BOOL fn_bAcceptModifInsert (CPA_SuperObject * pSuperObjectToInsert, CPA_SuperObject *pParent, tdeStatus eStatus);
// Called before a object is inserted into the hierarchy
// --- Functions to manage ZDx objects ---
public:
void fn_vInitListByType (CPA_World * pWorld); // To register the different types of objects
void fn_vInitListsOfModels (); // To register the different types of models
tdeTypeSO GetTypeInstance (CString csTypeName , CString csModelName)
{ return C_Protected; } // Return the type of the super object of a ZDx object
//ANNECY Shaitan EmptySectors 25/02/98
tdeSaveStatus GetStatusInstance (CString csTypeName, CString csModelName)
{ return E_ss_NoSave; }
//ENDANNECY Shaitan EmptySectors
CPA_SuperObject * GetNewInstance (CString csTypeName , CString csModelName , CPA_SuperObject * pParent);
// To insert a new ZDx object into the world
BOOL fn_bChooseInsertPosition (CPA_SuperObject * pNewInstance , CPA_SuperObject * pParent ,
tdstPosition * pPosition); // To choose the position where to insert the ZDx object
CPA_SuperObject * GetParentForInsertion (CString csTypeName , CString csModelName , tdstPosition * pPosition);
// To choose the parent when inserting a ZDx object
CPA_BaseObject * Duplicate (CPA_BaseObject * pObject, CPA_SuperObject * pSuperObject);
// To copy a ZDx object
CPA_SuperObject * GetCopyOfProtectedChild (CPA_SuperObject * pChild, CPA_SuperObject * pNewOwner);
// To copy a protected child of a ZDx object
void fn_vComputeBoundingVolume (CPA_BaseObject * _pObject); // Compute bounding volume of a ZDx object
ACP_tdxHandleOfObject fn_hGetBoundingVolume (CPA_BaseObject * _pObject); // Return bounding volume of a ZDx object
// --- Modifications ---
public:
void fn_vOnModifInsert (CPA_SuperObject * pEdObj , CPA_SuperObject * pParent,
tdstPosition * p_stPosition , tdeTypeModif , tdeStatus eStatus);
// Called when an object is inserted
void fn_vOnModifDelete (CPA_List<EDT_SaveParents> * , tdeTypeModif , tdeStatus eStatus);
// Called when an object is deleted
void fn_vOnCancelInsertion (CPA_SuperObject * _pSuperObject);
// This function is called when an insertion is canceled
void fn_vOnModifCopy (CPA_List<EDT_SaveParents> * , tdeTypeModif , tdeStatus eStatus);
// Called when an object has been copied
void fn_vOnBeginMove (CPA_List<CPA_SuperObject> * pListObjects ,
CPA_List<CPA_SuperObject> * pListConcerned , tdeStatus eStatus);
// This funtion is called just before a move
//CPA2 (Corneliu Babiuc) 15-04-1998
void fn_vOnMoving (CPA_List<CPA_SuperObject> * pListObjects ,
CPA_List<CPA_SuperObject> * pListConcerned, tdeStatus eStatus);
// This function is called when a ZDx object is moved
//END CPA2 (Corneliu Babiuc) 15-04-1998
void fn_vOnModifMove (CPA_List<EDT_SavePos> * pListObjects , CPA_List<EDT_SaveGlobalPos> * pListConcerned ,
tdeTypeModif eType, tdeStatus eStatus); // This function is called after a ZDx object has been moved
void fn_vOnSelect (CPA_SuperObject *pSuperObject, tdeTypeModif eType, tdeStatus eStatus);
// This function is called when a ZDx Object is selected
// --- Windows messages ---
public:
BOOL _OnKeyDown (UINT nChar , UINT nRepCnt , UINT nFlags); // Called when a key is pressed
BOOL _OnKeyUp (UINT nChar , UINT nRepCnt , UINT nFlags); // Called when a key is released
BOOL _OnMouseMove (UINT nFlags, tdstMousePos * p_stPos, MTH3D_tdstVector * p_stObject);
// Called when the mouse moves
BOOL _OnLButtonDown (UINT nFlags, tdstMousePos * p_stPos, ACP_tdxIndex xIndex, HIE_tdstPickInfo * p_stObject);
// Called when the left button is pressed
BOOL _OnLButtonUp (UINT nFlags, tdstMousePos * p_stPos); // Called when the left button is released
//ROMTEAM WorldEditor
BOOL _OnLButtonDblClk (UINT nFlags, tdstMousePos *p_stPos, ACP_tdxIndex xIndex, HIE_tdstPickInfo *p_stPickInfo); // Called when the left button is double clicked
//ENDROMTEAM WorldEditor
//--------------------------
//--- Internal functions ---
//--------------------------
// --- Internal functions for questions ---
private:
BOOL AcceptModifInsertZDxOfActor (CPA_SuperObject * pSuperObjectToInsert , CPA_SuperObject * pParent);
// Called before a ZDx of actor is inserted into the hierarchy
BOOL AcceptModifInsertZDxOfModule (CPA_SuperObject * pSuperObjectToInsert , CPA_SuperObject * pParent);
// Called before a ZDx of module is inserted into the hierarchy
BOOL AcceptModifInsertBoundingVolume (CPA_SuperObject * pSuperObjectToInsert , CPA_SuperObject * pParent);
// Called before a ZDx which is a bounding volume is inserted into the hierarchy
// ANNECY AV CLEAN_MEC {
// BOOL AcceptModifInsertTestPoint (CPA_SuperObject * pSuperObjectToInsert , CPA_SuperObject * pParent);
// Called before a ZDx which is a test point is inserted into the hierarchy
// END ANNECY AV }
// --- Internal functions for modifications ---
private:
void OnInsertActor (CPA_SuperObject * _pActorSuperObject);
// Called when an actor is inserted into the hierarchy
void OnDeleteActor (CPA_SuperObject * _pActorSuperObject);
// Called when an actor is deleted from the hierarchy
void OnInsertZDxOfActor (CPA_SuperObject * _pZDxSuperObject , CPA_SuperObject * _pActorSuperObject );
// Called when a ZDx of actor is inserted into the hierarchy
void OnDeleteZDxOfActor (CPA_SuperObject * _pZDxSuperObject , CPA_SuperObject * _pActorSuperObject );
// Called when a ZDx of actor is deleted from the hierarchy
void OnInsertZDxOfModule (CPA_SuperObject * _pZDxSuperObject , CPA_SuperObject * _pModuleSuperObject);
// Called when a ZDx of module is inserted into the hierarchy
void OnDeleteZDxOfModule (CPA_SuperObject * _pZDxSuperObject , CPA_SuperObject * _pModuleSuperObject);
// Called when a ZDx of module is deleted from the hierarchy
void OnInsertBoundingVolume (CPA_SuperObject * _pZDxSuperObject , CPA_SuperObject * _pActorSuperObject , BOOL bCreateBdV = TRUE);
// Called when a ZDx that is a bounding volume is inserted into the hierarchy
void OnDeleteBoundingVolume (CPA_SuperObject * _pZDxSuperObject , CPA_SuperObject * _pActorSuperObject );
// Called when a ZDx that is a bounding volume is deleted from the hierarchy
// ANNECY AV CLEAN_MEC {
// void OnInsertTestPoint (CPA_SuperObject * _pZDxSuperObject , CPA_SuperObject * _pActorSuperObject );
// Called when a ZDx that is a test point is inserted into the hierarchy
// void OnDeleteTestPoint (CPA_SuperObject * _pZDxSuperObject , CPA_SuperObject * _pActorSuperObject );
// Called when a ZDx that is a test point is deleted from the hierarchy
// END ANNECY AV }
void OnSelectActor (CPA_SuperObject * _pActorSuperObject , tdeTypeModif eType);
// Called when an actor is selected or unselected
void OnSelectZDxOfActor (CPA_SuperObject * _pZDxSuperObject , CPA_SuperObject * _pActorSuperObject , tdeTypeModif eType);
// Called when a ZDx of actor is selected or unselected
void OnSelectModule (CPA_SuperObject * _pModuleSuperObject , tdeTypeModif eType);
// Called when a module is selected or unselected
void OnSelectZDxOfModule (CPA_SuperObject * _pZDxSuperObject , CPA_SuperObject * _pModuleSuperObject , tdeTypeModif eType);
// Called when a ZDx of a module is selected or unselected
void OnSelectBoundingVolume (CPA_SuperObject * _pZDxSuperObject , CPA_SuperObject * _pModuleSuperObject , tdeTypeModif eType);
// Called when a ZDx objct that is a bounding volume is selected or unselected
// ANNECY AV CLEAN_MEC {
// void OnSelectTestPoint (CPA_SuperObject * _pZDxSuperObject , CPA_SuperObject * _pModuleSuperObject , tdeTypeModif eType);
// Called when a ZDx objct that is a test point is selected or unselected
// END ANNECY AV }
//---------------------
//--- Personal data ---
//---------------------
private:
CPA_KeyActionConfiguration
* m_pZDxKeyActionConfiguration; // To use the keyboard
BOOL m_bSizeKeyPressed; // To store the key state
//CPA2 (Corneliu Babiuc) 13-04-1997
BOOL m_bMoveOnlyActorKeyPressed; // Is TRUE when the key for "moving actor only" is pressed
BOOL m_bMoveOnlyActor; // Is TRUE when the "moving actor only" mode is activated
//END CPA2 (Corneliu Babiuc) 13-04-1997
BOOL m_bMoveHasBegun; // Is TRUE when a object move has begun (to differentiate move and move-to)
BOOL m_bIsSelectingObject; // Is TRUE when selecting an object
BOOL m_bIsAskingToSelectObject; // Is TRUE when asking the hierarchy editor to select an object
BOOL m_bIsShowingOrHidingZDx; // Is TRUE when showing or hiding ZDx
BOOL m_bIsInsertingZDxObject; // Is TRUE when inserting a ZDx into the hierarchy
BOOL m_bIsDeletingZDxObject; // Is TRUE when deleting a ZDx from the hierarchy
BOOL m_bIsInsideOnModifInsertDelete;// Is TRUE inside the OnModifInsert or OnModifDelete function
BOOL m_bAskToEditModuleZone; // Is TRUE when one wants to edit the module zones when one opens the editor
long m_lRefreshDisplayCallerID; // The ID of the function that will refresh the display
CPA_SuperObject * m_pActorSuperObjectToUnselect; // Actor whose ZDx must be hidden
CPA_SuperObject * m_pModuleSuperObjectToUnselect;// Module whose ZDx must be hidden
ACP_tdxHandleOfObject m_GlobalBoundingVolume; // Used to give the bounding volume of a ZDx
CSplitFrame * m_pSplitFrame; // Frame where all the windows are
CDisplayControlWindow * m_pDisplayControlWindow; // Window associated to the frame for the display control
CList1Window * m_pList1Window; // Window associated to the frame for the first list
CList2Window * m_pList2Window; // Window associated to the frame for the second list
CZDxInfoWindow * m_pEditWindow; // Window associated to the frame where one can edit a ZDx
tdstSizeChangingMode m_stSizeChangingMode; // Used when the user changes the size of a ZDx object with the mouse
//--------------------------
//--- Personal functions --- (file : _zInterf.inc)
//--------------------------
// --- Get functions for windows ---
public:
CList1Window * GetList1Window () { return m_pList1Window; }
CList2Window * GetList2Window () { return m_pList2Window; }
CZDxInfoWindow * GetEditWindow () { return m_pEditWindow; }
CDisplayControlWindow * GetDisplayControlWindow () { return m_pDisplayControlWindow; }
// --- Personal low-level functions
private:
void ConvertVectorGlobalToLocal (MTH3D_tdstVector * pDest , POS_tdstCompletePosition * pAbsoluteMatrix , MTH3D_tdstVector * pSource);
// Function to convert a vector from the global repere to a local repere
void ConvertVectorLocalToGlobal (MTH3D_tdstVector * pDest , POS_tdstCompletePosition * pAbsoluteMatrix , MTH3D_tdstVector * pSource);
// Function to convert a vector from a local repere to the global repere
void ConvertPointGlobalToLocal (MTH3D_tdstVector * pDest , POS_tdstCompletePosition * pAbsoluteMatrix , MTH3D_tdstVector * pSource);
// Function to convert a point from the global repere to a local repere
void ConvertPointLocalToGlobal (MTH3D_tdstVector * pDest , POS_tdstCompletePosition * pAbsoluteMatrix , MTH3D_tdstVector * pSource);
// Function to convert a point from a local repere to the global
//CPA2 (Corneliu Babiuc) 15-04-1998
//this function is intended to set the local translation vector of a zone to keep unchanged its global position
void MoveBackZone (CPA_SuperObject * _pZDxSuperObject, MTH3D_tdstVector * p_stVector = NULL);
//END CPA2 (Corneliu Babiuc) 15-04-1998
// --- Various functions ---
private:
char * GetZDxTypeName (tdeZDxType _eZDxType); // return the name ("Zdd"...) of the ZDx type
CPA_SuperObject * GetSelectedActorSuperObject (); // Return the selected actor. NULL if none
public:
unsigned char ConvertZDxTypeToEngineType (tdeZDxType _eZDxType); // Convert a ZDx type to a type used by the engine
CPA_SuperObject * GetZDxSuperObject (ZDx_Object * , CPA_SuperObject * _pParentSuperObject);
// Look at all childs of _pParentSuperObject to find the super object
// associated with the given ZDx object
BOOL IsInsideOnModifInsertDelete () { return m_bIsInsideOnModifInsertDelete; }// Is TRUE inside the OnModifInsert or OnModifDelete function
// --- Personal functions for models ---
private:
void AddModelOfZDx (); // Add all the models of ZDx into the model window
void RemoveModelOfZDx (); // Remove all the models of ZDx from the model window
// --- Personal functions for ZDx creation ---
private:
CPA_SuperObject * CreateSuperObject (); // Create a super object
public:
//ROMTEAM WorldEditor
Shape3D * CreateGraphicObject (tdeZDxGeometricType /*, ACP_tdxHandleOfElement * */,
char * _szDataPath , const CString _csReferenceSectionName);
// Create graphic object (sphere, box...)
private:
CPA_SuperObject * CreateGraphicSuperObject (tdeZDxGeometricType /*, ACP_tdxHandleOfElement * */,
char * _szDataPath , const CString _csReferenceSectionName);
// Create a graphic super object (sphere, box...)
// ENDROMTEAM WorldEditor
CPA_BaseObject * GetFamilyForNewInstance (CPA_BaseObject * _pParent); // Give the family of a new created ZDx object
void ComputeSectionNameForNewInstance (char * * _p_szDataPath , CString * _p_csReferenceSectionName ,
CPA_BaseObject * _pParent); // Compute the data path and the reference section name to give to a created ZDx object
CPA_SuperObject * GetNewInstanceWithSameZDxObject (ZDx_Object * pZDxObject , char * szZDxGeometricTypeName);
// Same function as GetNewInstance, but use an existing ZDx object
ZDx_Object * CreateZdxObject (LPARAM lParam); // Create a new Zdx with an existing engine zone
// ANNECY AV CLEAN_MEC {
// void CreateZdxTestPoints (CPA_TestPointsList *); // For each test point in the given list, create an associated ZDx object
// END ANNECY AV }
// --- Communication with hierarchy editor ---
public:
void AskHierarchyEditorToSelectObject (CPA_SuperObject * _pSuperObject); // Ask the hierarchy editor to select an actor
void InsertZDxObjectIntoHierarchy (CPA_SuperObject * _pZDxSuperObject , CPA_SuperObject * _pParentSuperObject);
// Ask the hierarchy editor to insert a ZDx object into the hierarchy
void DeleteZDxObjectFromHierarchy (CPA_SuperObject * _pZDxSuperObject);
// Ask the hierarchy editor to delete a ZDx object from the hierarchy
// --- Show / Hide ZDx objects ---
private:
void SetDisplayFlag (EdtList * , tdeZDxDisplayType); // Set the display zone flag of all ZDx of the list
// ANNECY AV CLEAN_MEC {
// void SetDisplayFlag (CPA_TestPointsList * , tdeZDxDisplayType);// Set the display zone flag of all test points of the list
// END ANNECY AV }
void SetDisplayFlagOfAllActors (BOOL _bNewFlag); // Set the display zone flag of all actors
void SetAspectOfZDx (CPA_SuperObject * , BOOL _bSelected); // Set the graphical aspect of a ZDx : selected or not selected
public:
void PutZDxIntoHierarchy (CPA_SuperObject * _pFatherSuperObject , // Put a ZDx as child of a super object into the hierarchy
ZDx_Object * _pZDxObject ,
BOOL _bSelectZDx ,
BOOL _bSetEditProtected = FALSE);
private:
void CheckAndPutZDxIntoHierarchy (CPA_SuperObject * _pFatherSuperObject , // Check if the ZDx must be put into the hierarchy
ZDx_Object * _pZDxObject ,
BOOL _bSelectZDx ,
BOOL _bSetEditProtected = FALSE);
void PutListOfZDxIntoHierarchy (EdtList * _pListOfZDx , // Put a list of ZDx as childs of a super object into the hierarchy
CPA_SuperObject * _pFapherSuperObject ,
ZDx_Object * _pZDxObjectToSelect ,
BOOL _bUseDisplayFlag ,
BOOL _bSetEditProtected = FALSE);
// ANNECY AV CLEAN_MEC {
/*
void PutListOfTestPointIntoHierarchy // Put a list of test points as childs of a super object into the hierarchy
(CPA_TestPointsList * _pTestPointList ,
CPA_SuperObject * _pFapherSuperObject ,
ZDx_Object * _pZDxObjectToSelect ,
BOOL _bUseDisplayFlag ,
BOOL _bSetEditProtected = FALSE);
*/
// END ANNECY AV }
public:
void ShowZDxOfActor (CPA_SuperObject * _pActorSuperObject , unsigned char _ZDxToShow ,
ZDx_Object * _pZDxToSelect = NULL , // Show the ZDx of an actor which have the correct type, select one ZDx if necessaray
BOOL _bUseDisplayFlag = TRUE ,
BOOL _bSetEditProtected = FALSE);
void ShowAllZDxOfAllActors (unsigned char _ucZDxToShow , BOOL _bShowOnlySelected);
// Show all ZDx of all actors. If _bShowOnlySelected = TRUE,
// show only the zones of actors that have the bDisplayZone flag set
void ShowZDxOfModule (CPA_SuperObject * _pModuleSuperObject , unsigned char _ucZDxToShow ,
ZDx_Object * _pZDxToSelect = NULL , BOOL _bSetEditProtected = FALSE);
// Show the ZDx of a module (insert ZDx objects in the hierarchy)
void ShowBoundingVolume (CPA_SuperObject * _pActorSuperObject , ZDx_Object * _pBoundingVolume , BOOL _bSelectZDx);
// Show the bounding volume of an actor
private:
void ShowModuleZDxRecursiv (CPA_SuperObject * _pModuleSuperObject); // Show all zdx of a module and of all of its module childs
public:
void ShowModuleZDxOfActor (CPA_SuperObject * _pActorSuperObject); // Show all ZDx of all modules of an actor
private:
void HideModuleZDxRecursiv (CPA_SuperObject * _pModuleSuperObject); // Hide all zdx of a module and of all of its module childs
public:
void HideModuleZDxOfActor (CPA_SuperObject * _pActorSuperObject); // Hide all ZDx of all modules of an actor
private:
void ShowZDxOfAllModule (unsigned char _ucZDxToShow); // Show or hide the ZDx of all modules in the world
void ShowZDxOfSelectedActor (); // Show all ZDx of selected actor
void HideZDxOfSelectedActor (); // Hide all ZDx of selected actor
// --- Refresh display ---
public:
BOOL IWillRefreshDisplay (long _lCallerID); // Someone say he will refresh the display later (to prevent multiple refreshes)
// Return TRUE if nobody else has asked it before
BOOL RefreshDisplay (long _lCallerID , BOOL _bRefreshDisplay = TRUE);
// Refresh the display if the caller has asked it before (to prevent from multiple refreshes)
// --- Check if ZDx are displayed ---
private:
BOOL AreZDxOfActorDisplayed (CPA_SuperObject * _pActorSuperObject); // Return if the ZDx of the actor are displayed or not
BOOL AreZDxOfModuleDisplayed (CPA_SuperObject * _pModuleSuperObject);// Return if the ZDx of the module are displayed or not
BOOL AreZDxOfAllModuleDisplayed (); // Return TRUE if at least one ZDx of one module in the world is displayed
BOOL AreZDxOfModuleDisplayedRecursiv (CPA_SuperObject * _pModuleSuperObject);// Return if the ZDx of the given module and of all its module childs are displayed or not
BOOL AreModuleZDxOfActorDisplayed (CPA_SuperObject * _pActorSuperObject); // Return if the module ZDx of the actor are displayed or not
// --- Check if an actor has ZDx ---
public:
BOOL DoesActorHaveZDx (CPA_BaseObject * _pActor); // Return if an actor has some ZDx or not
BOOL DoesActorHaveModuleZDx (CPA_SuperObject * _pActorSuperObject); // Return if an actor has some ZDx of module or not
// --- List of zones ---
private:
long GetNumberOfZDxInList (EdtList * _pEdtList); // Get the number of existing ZDx in a list
public:
CString ConvertZDxTypeToListType (tdeZDxType); // Convert a ZDx type to a list type
tdeZDxType ConvertListTypeToZDxType (CString); // Convert a list type to a ZDx type
CPA_tdoNameList
* GetNameList (CPA_BaseObject * _pActor , tdeZDxType _eZDxType);
// Call the Actors dll to get the list of names of an actor for a specific type
EdtList * CreateANewZDxList (CPA_BaseObject * _pActor , tdeZDxType _eZDxType);
// Call the Actors dll to create a new list of ZDx
EdtList * GetZDxList (CPA_BaseObject * _pActor , tdeZDxType _eZDxType);
// Call the Actors dll to get the list of ZDx of an actor
void SetZDxList (CPA_BaseObject * _pActor , tdeZDxType _eZDxType , EdtList * _pZDxList);
// Call the Actors dll to set the list of ZDx of an actor
BOOL DeleteZDxList (CPA_BaseObject * _pActor , tdeZDxType _eZDxType);
// Call the Actors dll to delete a list of ZDx of an actor ; return FALSE if failure
void SetZDxObjectInList (CPA_BaseObject * _pActor , tdeZDxType _eZDxType ,
long _lIndexInList , ZDx_Object * pZDxObject ,
tdeZDxConstraintType _eZDxConstraintType = eZDxNormal);
// Call the Actors dll to set a ZDx in a list of ZDx of an actor
BOOL InsertZDxIntoList (EdtList * , ZDx_Object * , long * plPosition ,
CPA_BaseObject * _pActor , tdeZDxConstraintType _eZDxConstraintType = eZDxNormal);
// Insert a ZDx object into a list at a specific position.
// If Position = -1, insert it at the first unused position.
// Failure -> return FALSE (no more unused position)
void RemoveZDxFromList (EdtList * , ZDx_Object * , CPA_BaseObject * _pActor ,
BOOL _bEnableListCreation = FALSE); // Remove a ZDx object from a list
private:
void AZDxHasBeenChangedInList (void * _pEdtListMess); // Called when a ZDx has been changed in a list of ZDx
BOOL IsObjectInList (CPA_BaseObject * _pObject, CPA_BaseObject * _pActor , tdeZDxType _eZDxType);
// Return TRUE if the given object is in a list of ZDx
// --- Physical objects ---
public:
ZDx_Object * GetZDxOfPhysicalObject (EditorPO * , tdeZDxType); // return the ZDx object of a given type of a physical object
void SetZDxOfPhysicalObject (EditorPO * , ZDx_Object * , tdeZDxType); // set the ZDx object (can be NULL) of a given type for a physical object
private:
BOOL DoesModuleHaveZDx (EditorPO *); // Return if a module has some ZDx of not
BOOL DoesModuleHaveZDxRecursiv (CPA_SuperObject * _pModuleSuperObject); // Return if a module or one of its module childs has some ZDx or not
BOOL DoesAtLeastOneModuleHaveZDx (); // Return TRUE if at least one module in the world has some ZDx
// --- Personal functions for size changing ---
private:
//ROMTEAM WorldEditor
/*
void ChangeSizeZDxSphereObject (MTH3D_tdstVector * p_stDeplacement); // Called by the OnMouseMove function when changing the size of a sphere
void ChangeSizeZDxBoxObject (MTH3D_tdstVector * p_stDeplacement); // Called by the OnMouseMovefunction when changing the size of a box
void ChangeSizeZDxConeObject (MTH3D_tdstVector * p_stDeplacement); // Called by the OnMouseMove function when changing the size of a cone
void OnBeginChangingSize (ACP_tdxIndex xIndex , HIE_tdstPickInfo * p_stObject);
// Called when the user begins to change the size of a ZDx object
void OnEndChangingSize (); // Called when the user has finished to change the size of a ZDx object
*/
//ENDROMTEAM WorldEditor
// --- Compute dimension of objects ---
private:
//ANNECY TQ 19/03/98{
void ComputeBoundingBoxOfObject (CPA_BaseObject * _pObject , POS_tdstCompletePosition * _pGlobalMatrix ,POS_tdstCompletePosition * _pLocalMatrix ,
MTH3D_tdstVector * _pMinPoint , MTH3D_tdstVector * _pMaxPoint);
//ENDANNECY TQ}
// Compute the bounding box of a geometric object, and return its limits in _pMinPoint and _pMaxPoint
void ComputeBoundingBoxOfObjectAndChilds (CPA_SuperObject * _pSuperObject ,
MTH3D_tdstVector * _pMinPoint, MTH3D_tdstVector *_pMaxPoint);
// Compute the bounding box of an object and all of its childs, and return the limits in _pMinPoint and _pMaxPoint
public:
void ComputeInitialSizeOfBox (CPA_SuperObject * _pSuperObject ,
MTH3D_tdstVector * MinPoint , MTH3D_tdstVector * MaxPoint);
// Compute the bounding box dimension of an object and all of its childs
MTH_tdxReal ComputeInitialSizeOfSphere (CPA_SuperObject * _pSuperObject , MTH3D_tdstVector * Center);
//ROMTEAM WorldEditor (Cristi Petrescu 12/12/97)
long m_lGetTypeOfZoneByGeometricObject (Geometry3D *pGeometry3D);
//ENDROMTEAM WorldEditor (Cristi Petrescu)
//CPA2 Stegaru Cristian 98-04
BOOL mfn_bObjectIsOutsideTheBV (ZDx_Object *pBVolume, ZDx_Object *pZDxObject);
BOOL mfn_bIs1SphereOutsideThe2Sphere (MTH3D_tdstVector *ptdstMasterCenter, GLI_tdxValue tdxMasterRadius, MTH3D_tdstVector *ptdstSlaveCenter, GLI_tdxValue tdxSlaveRadius);
void mfn_vCheckActorsZonesAndBV (CPA_SuperObject * pActorSuperObject);
//End CPA2 Stegaru Cristian 98-04
};
//-----------------------------------------------------------------------------
// Global variables
//-----------------------------------------------------------------------------
// the DLL global definition
extern tdstDLLIdentity g_stZDxDllIdentity;
#endif // __ZINTERF_HPP__

View File

@@ -0,0 +1,169 @@
//*****************************************************************************
//* _zModif.hpp *
//*****************************************************************************
//* *
//* This file contains the definitions of the modif classes *
//* *
//*****************************************************************************
//* Author : Alexis Vaisse *
//*****************************************************************************
#ifndef __ZMODIF_H
#define __ZMODIF_H
#pragma once
// Actor dll "include"
class EdtList;
// Physical Object dll "include"
class EditorPO;
// personal "include"
class ZDx_Interface;
class ZDx_Object;
#include "_zObject.hpp"
typedef struct stBackupDataForSphere_
{
MTH3D_tdstVector stCenter;
GLI_tdxValue Radius;
} tdstBackupDataForSphere;
typedef struct stBackupDataForBox_
{
MTH3D_tdstVector stMinPoint;
MTH3D_tdstVector stMaxPoint;
} tdstBackupDataForBox;
typedef struct stBackupDataForPoint_
{
MTH3D_tdstVector stPoint;
} tdstBackupDataForPoint;
typedef struct stBackupDataForCone_
{
MTH3D_tdstVector stTopPoint;
MTH3D_tdstVector stBasePoint;
GLI_tdxValue Radius;
} tdstBackupDataForCone;
//-----------------------------------------------------------------------------
// class ZDx_Modif
//
// This class deals with all the modifications of a ZDx Object
//-----------------------------------------------------------------------------
class ZDx_Modif : public CPA_Modif
{
private:
ZDx_Object * m_pZDxObject; // the ZDx object to modify
BOOL m_bFirstTime;
// backup data
char * m_BackupName;
void * m_pBackupData; // Point to a tdstBackupDataFor... structure, depends on the ZDx type
BOOL m_bIsDoingUndo; // Is TRUE when doing an Undo
void BackupSphereData ();
void BackupBoxData ();
void BackupPointData ();
void BackupConeData ();
void ExchangeBackupSphereData ();
void ExchangeBackupBoxData ();
void ExchangeBackupPointData ();
void ExchangeBackupConeData ();
public:
ZDx_Modif (ZDx_Object * , char * ); // constructor with the ZDx object which will be modified
// and the name of the modif ("Modification ZDx" for instance)
~ZDx_Modif (); // destructor
void SetZDxObject (ZDx_Object *); // set the ZDx object which will be modified
BOOL Do ();
BOOL Undo (); // Standard Undo : it refreshes the window by default
BOOL Undo (BOOL _bRefreshWindow); // personal Undo : if we don't want the window to be refreshed
};
//-----------------------------------------------------------------------------
// class ZDx_Modif_Exchange
//
// This class deals with the exchange of two ZDx object within two objects lists
//-----------------------------------------------------------------------------
class ZDx_Modif_Exchange : public CPA_Modif
{
private:
ZDx_Interface * m_pZDxInterface;
ZDx_Object * m_pZDxObject1 , * m_pZDxObject2;
long m_lIndexInList1 , m_lIndexInList2;
EdtList * m_pZDxList1 , * m_pZDxList2;
tdeZDxType m_eTypeOfList1 , m_eTypeOfList2;
CPA_BaseObject * m_pActor1 , * m_pActor2;
CPA_SuperObject * m_pActorSuperObject1 , * m_pActorSuperObject2;
public:
// Constructor
ZDx_Modif_Exchange (ZDx_Object * , long lIndexInList1 , EdtList * , CPA_SuperObject * _pActorSuperObject1 ,
ZDx_Object * , long lIndexInList2 , EdtList * , CPA_SuperObject * _pActorSuperObject2 ,
ZDx_Interface *);
BOOL Do ();
BOOL Undo ();
};
//-----------------------------------------------------------------------------
// class ZDx_Modif_Delete
//
// This class deals with the deletion of a ZDx object from a list
//-----------------------------------------------------------------------------
class ZDx_Modif_Delete : public CPA_Modif
{
private:
ZDx_Interface * m_pZDxInterface;
CPA_SuperObject * m_pZDxSuperObject;
ZDx_Object * m_pZDxObject;
long m_lIndexInList;
EdtList * m_pZDxList;
CPA_SuperObject * m_pModuleSuperObject;
EditorPO * m_pModule;
CPA_SuperObject * m_pActorSuperObject;
CPA_BaseObject * m_pActor;
public:
// Constructor
ZDx_Modif_Delete (CPA_SuperObject * _pZDxSuperObject , long lIndexInList , EdtList * ,
CPA_SuperObject * _pModuleSuperObject , CPA_SuperObject * _pActorSuperObject ,
ZDx_Interface *);
~ZDx_Modif_Delete (); // Destructor
BOOL Do ();
BOOL Undo ();
};
//-----------------------------------------------------------------------------
// class ZDx_Modif_Change_ZDx_List
//
// This class deals with the change of a list of ZDx for an actor
//-----------------------------------------------------------------------------
class ZDx_Modif_Change_ZDx_List : public CPA_Modif
{
private:
ZDx_Interface * m_pZDxInterface;
CPA_SuperObject * m_pActorSuperObject;
CPA_BaseObject * m_pActor;
tdeZDxType m_eTypeOfList;
EdtList * m_pZDxList;
public:
// Constructor
ZDx_Modif_Change_ZDx_List (ZDx_Interface * , CPA_SuperObject * _pActorSuperObject , tdeZDxType , EdtList *);
BOOL Do ();
BOOL Undo ();
};
#endif // __ZMODIF_H

View File

@@ -0,0 +1,364 @@
//*****************************************************************************
//* _zObject.hpp *
//*****************************************************************************
//* *
//* This file contains the definition of the ZDx_Object class *
//* and its inherited classes *
//* *
//*****************************************************************************
//* Author : Alexis Vaisse *
//*****************************************************************************
#ifndef __ZOBJECT_HPP__
#define __ZOBJECT_HPP__
#pragma once
//-----------------------------------------------------------------------------
// Include
//-----------------------------------------------------------------------------
// general include
#include "IncITF.h"
#include "OGD.h"
// personal "include"
//class Geometry3D; // the 3D geometric object (editor object)
//class Shape3D; // the polimorfic 3d geometric object
// ANNECY AV CLEAN_MEC {
//class CPA_TestPointNode; // class of the Family tool dll
// END ANNECY AV }
class ZDx_Interface;
class ZDx_Shape;
//-----------------------------------------------------------------------------
// Define
//-----------------------------------------------------------------------------
// type of ZDx
// ANNECY AV CLEAN_MEC {
typedef enum eZDxType_ { eZdd , eZde , eZdm , eZdr , eBoundingVolume /* , eTestPoint */ } tdeZDxType;
// END ANNECY AV }
// type of geometric object for ZDx (eItself means that the Zdx of the module is the module itself)
typedef enum eZDxGeometricType_ { eBox , eSphere , ePoint , eCone } tdeZDxGeometricType;
// type of display for ZDx
typedef enum eZDxDisplayType_ { eNotDisplayed , eDisplayed} tdeZDxDisplayType;
// name of ZDx
#define C_szZddName "ZDD"
#define C_szZdeName "ZDE"
#define C_szZdmName "ZDM"
#define C_szZdrName "ZDR"
#define C_szBoundingVolumeName "BV"
// ANNECY AV CLEAN_MEC {
//#define C_szTestPointName "TestPoint"
// END ANNECY AV}
#define C_szZDxSphereName "Sphere"
#define C_szZDxBoxName "Box"
#define C_szZDxPointName "Point"
#define C_szZDxConeName "Cone"
//ROMTEAM WorldEditor (Cristi Petrescu 11/12/97)
/*
* Moved to OZO.h in the public directories. Needed for material checks
*
// public ID for the ZDx objects
#define C_lZDD 18300
#define C_lZDE 18301
#define C_lZDM 18302
#define C_lZDR 18303
#define C_lBoundingVolume 18304
#define C_lTestPoint 18305
*/
//ENDROMTEAM WorldEditor (Cristi Petrescu)
//-----------------------------------------------------------------------------
// Macros
//-----------------------------------------------------------------------------
#define M_bIsThisObjectAZDx(pObject) \
((pObject) -> fn_bIsOfType (C_szZddName) \
|| (pObject) -> fn_bIsOfType (C_szZdeName) \
|| (pObject) -> fn_bIsOfType (C_szZdmName) \
|| (pObject) -> fn_bIsOfType (C_szZdrName) \
|| (pObject) -> fn_bIsOfType (C_szBoundingVolumeName))
// ANNECY AV CLEAN_MEC {
// || (pObject) -> fn_bIsOfType (C_szTestPointName))
// END ANNECY AV }
//-----------------------------------------------------------------------------
// class ZDx_Object
//
// Definition of the ZDx object class
//-----------------------------------------------------------------------------
class ZDx_Object : public CPA_SaveObject , public CPA_EdMot<ACP_tdxHandleOfObject>
{
private:
tdeZDxType m_eZDxType; // The type of the ZDx (zdd, zde, zdm or zdr)
tdeZDxGeometricType m_eZDxGeometricType; // The geometric type of the ZDx (sphere, box...)
tdeZDxDisplayType m_eDisplayType; // The display type of the ZDx
BOOL m_bMotorDisplay; // TRUE if the ZDx must be showed when motor is running
long m_lIndexInList; // The index (zero-based) of the zone inside the list of zones
// ANNECY AV CLEAN_MEC {
// CPA_TestPointNode * m_pTestPoint; // When the ZDx object is a test point, a pointor to the associated test point
// END ANNECY AV }
ZDx_Shape * m_pZDxShape; // A pointer to an instance of the shape class
long GiveZDxID (tdeZDxType); // Give the ID of a ZDx object, depending on its type
public:
// --- Constructor ---
//ROMTEAM WorldEditor (Cristi Petrescu 11/12/97)
ZDx_Object (ZDx_Interface * , const CString _csZDxTypeName , tdeZDxType , tdeZDxGeometricType , const CString _csZDxName ,
CPA_BaseObject * _pOwner , Shape3D * /*, ACP_tdxHandleOfElement*/);
//ENDROMTEAM WorldEditor (Cristi Petrescu)
ZDx_Object (ZDx_Object & _pZDxObjectToCopy); // Copy constructor
// --- Destructor ---
~ZDx_Object ();
// Functions used by the CPA_EdMot class
static void InitZDxObject ();
static ACP_tdxHandleOfObject CreateZDxEngineStruct ();
static void CopyZDxEngineStruct (ACP_tdxHandleOfObject , ACP_tdxHandleOfObject);
static void DeleteZDxEngineStruct (ACP_tdxHandleOfObject);
// Virtual functions of the base class
long GetDataType ();
void * GetData ();
tdeMissingCriteria fn_eCheckUnicity (const CString csNewName);
void fn_vNotifyRename (); // Called when one renames the ZDx :
// we also rename the geometric object
// --- Engine structure ---
void * GetEngineStruct () { return GetStruct (); }
void SetEngineStruct (void * pStruct)
{ SetStruct ((ACP_tdxHandleOfObject) pStruct); }
// --- ZDx type ---
tdeZDxType GetZDxType () { return m_eZDxType; }
void SetZDxType (tdeZDxType _eType)
{ m_eZDxType = _eType; }
char * GetZDxTypeName ();
// --- ZDx geometric type ---
tdeZDxGeometricType GetZDxGeometricType () { return m_eZDxGeometricType; }
void SetZDxGeometricType (tdeZDxGeometricType _eZDxGeometricType)
{ m_eZDxGeometricType = _eZDxGeometricType; }
//--- ZDx Name ---
char * GetZDxName (); // return the name of the ZDx object
BOOL SetZDxName (char *); // set the name of the ZDx object. Return FALSE if the name already exists
//--- Display ---
tdeZDxDisplayType GetDisplay () { return m_eDisplayType; }
void SetDisplay (tdeZDxDisplayType _eDisplayType)
{ m_eDisplayType = _eDisplayType; }
BOOL GetMotorDisplay () { return m_bMotorDisplay; }
void SetMotorDisplay (BOOL _bMotorDisplay)
{ m_bMotorDisplay = _bMotorDisplay; }
// Function to access the instance of the ZDxShape class
ZDx_Shape * GetZDxShape () { return m_pZDxShape; }
void SetZDxShape (ZDx_Shape * _pZDxShape)
{ m_pZDxShape = _pZDxShape; }
// Index of the zone inside the list of zones
long GetIndexInList () { return m_lIndexInList; }
void SetIndexInList (long _lIndexInList)
{ m_lIndexInList = _lIndexInList; }
// When the ZDx object is a test point : functions to access the test point
// ANNECY AV CLEAN_MEC {
/*
CPA_TestPointNode * GetTestPoint () { return m_pTestPoint; }
void SetTestPoint (CPA_TestPointNode * _pTestPoint)
{ m_pTestPoint = _pTestPoint; }
*/
// END ANNECY AV}
// Object Save
void fn_vNotifySave ();
void fn_vNotifyUnSave ();
void fn_vNotifyRestore ();
CString fn_csComputeReferencedSectionName (const CString _csNewName);
void static CallbackToCreateZDxFile (SCR_tdst_File_Description * _pFile ,
char * _szSectionName ,
void * _pData ,
SCR_tde_Ntfy_Action _eAction);
long GetNumberOfModuleUsingThis (); // Get the number of modules using this ZDx object
void RedrawZDxObject (); // redraw the object (in fact, redraw the whole world)
};
//-----------------------------------------------------------------------------
// class ZDx_Shape
//
// Definition of the base class for the diferent shape of ZDx
// The inherited classes will contains methods to modify the geometric definition of the ZDx
//-----------------------------------------------------------------------------
class ZDx_Shape
{
protected:
ZDx_Object * m_pZDxObject;
//ROMTEAM WorldEditor (Cristi Petrescu 11/12/97)
Shape3D *m_pGeometric3dObject;
//ACP_tdxHandleOfElement m_hHandleOfElement;
public:
ZDx_Shape (ZDx_Object * , Shape3D * /*, ACP_tdxHandleOfElement*/); // Constructor
Shape3D * GetGeometric3dObject () { return m_pGeometric3dObject; }
//ACP_tdxHandleOfElement GetHandleOfElement () { return m_hHandleOfElement; }
//ENDROMTEAM WorldEditor (Cristi Petrescu)
void RefreshData (CPA_SuperObject *); // Recompute data (center, min point...)
// from the position of the super object
void RedrawZDxObject () { m_pZDxObject -> RedrawZDxObject (); } // redraw the object
//ROMTEAM WorldEditor (Cristi Petrescu 11/12/97)
MTH3D_tdstVector GetCenter () {return GetGeometric3dObject () -> GetCenter ();}; // Get the center of the object
void SetCenter (MTH3D_tdstVector *_pCenter) {GetGeometric3dObject () -> SetCenter (_pCenter);}; // Set the center of the object
//ENDROMTEAM WorldEditor (Cristi Petrescu)
ZDx_Object * GetZDxObject () { return m_pZDxObject; }
};
//ROMTEAM WorldEditor (Cristi Petrescu 11/12/97)
/*
//-----------------------------------------------------------------------------
// class ZDx_Sphere
//
// Definition of the class to modify the geometric aspect of a ZDx of type sphere
//-----------------------------------------------------------------------------
class ZDx_Sphere : public ZDx_Shape
{
public:
ZDx_Sphere (ZDx_Object * , Shape3D * , ACP_tdxHandleOfElement , ZDx_Sphere * _pZDxSphereToCopy = NULL); // Constructor
MTH3D_tdstVector GetCenter (); // return the 3D coordinates of the center of the sphere
void SetCenter (MTH3D_tdstVector *); // set the 3D coordinates of the center of the sphere
void SetCenterX (GLI_tdxValue);
void SetCenterY (GLI_tdxValue);
void SetCenterZ (GLI_tdxValue);
GLI_tdxValue GetRadius (); // return the radius of the sphere
BOOL SetRadius (GLI_tdxValue * _Radius); // set the radius of the sphere
// Return FALSE if the given value if not correct
// (that is, negative. Radius is then set to 0).
// The new radius is returned in * _Radius.
};
//-----------------------------------------------------------------------------
// class ZDx_Box
//
// Definition of the class to modify the geometric aspect of a ZDx of type box
//-----------------------------------------------------------------------------
class ZDx_Box : public ZDx_Shape
{
public:
ZDx_Box (ZDx_Object * _pZDxObject , Shape3D * , ACP_tdxHandleOfElement , ZDx_Box * _pZDxBoxToCopy = NULL); // Constructor
// All the Set functions return TRUE if the given value is correct, FALSE if not (for example, the given
// MinPointX is greater than the actual MaxPointX. The MinPointX is then set to the MaxPointX)
// In both case, the new value is returned
MTH3D_tdstVector GetMinPoint (); // return the 3D coordinates of the point with the min coordinates
BOOL SetMinPoint (MTH3D_tdstVector *);
BOOL SetMinPointX (GLI_tdxValue *);
BOOL SetMinPointY (GLI_tdxValue *);
BOOL SetMinPointZ (GLI_tdxValue *);
BOOL IncMinPointX (GLI_tdxValue *);
BOOL IncMinPointY (GLI_tdxValue *);
BOOL IncMinPointZ (GLI_tdxValue *);
MTH3D_tdstVector GetMaxPoint (); // return the 3D coordinates of the point with the max coordinates
BOOL SetMaxPoint (MTH3D_tdstVector *);
BOOL SetMaxPointX (GLI_tdxValue *);
BOOL SetMaxPointY (GLI_tdxValue *);
BOOL SetMaxPointZ (GLI_tdxValue *);
BOOL IncMaxPointX (GLI_tdxValue *);
BOOL IncMaxPointY (GLI_tdxValue *);
BOOL IncMaxPointZ (GLI_tdxValue *);
MTH3D_tdstVector GetCenter (); // return the 3D coordinates of the center of the box
// (in fact, it is the middle of the min point and the max point)
GLI_tdxValue GetLength (); // return the length of the box
GLI_tdxValue GetWidth (); // return the width of the box
GLI_tdxValue GetHeight (); // return the height of the box
void SetCenter (MTH3D_tdstVector *); // set the center of the box, dimensions are unchanged
void SetCenterX (GLI_tdxValue);
void SetCenterY (GLI_tdxValue);
void SetCenterZ (GLI_tdxValue);
BOOL SetLength (GLI_tdxValue *);
BOOL SetWidth (GLI_tdxValue *);
BOOL SetHeight (GLI_tdxValue *);
};
//-----------------------------------------------------------------------------
// class ZDx_Cone
//
// Definition of the class to modify the geometric aspect of a ZDx of type cone
//-----------------------------------------------------------------------------
class ZDx_Cone : public ZDx_Shape
{
public:
ZDx_Cone (ZDx_Object * _pZDxObject , Shape3D * , ACP_tdxHandleOfElement , ZDx_Cone * _pZDxConeToCopy = NULL); // Constructor
MTH3D_tdstVector GetBasePoint (); // Return the 3D coordinates of the base point
MTH3D_tdstVector GetTopPoint (); // Return the 3D coordinates of the top point
void SetBasePoint (MTH3D_tdstVector *); // Set the 3D coordinates of the base point
void SetTopPoint (MTH3D_tdstVector *); // Set the 3D coordinates of the top point
void SetBasePointX (GLI_tdxValue);
void SetBasePointY (GLI_tdxValue);
void SetBasePointZ (GLI_tdxValue);
void SetTopPointX (GLI_tdxValue);
void SetTopPointY (GLI_tdxValue);
void SetTopPointZ (GLI_tdxValue);
MTH3D_tdstVector GetCenter ();
void SetCenter (MTH3D_tdstVector *);
GLI_tdxValue GetRadius (); // Get the radius of the cone
BOOL SetRadius (GLI_tdxValue *); // Set the radius of the cone. Return FALSE if value is not correct
GLI_tdxValue GetAngle (); // Return the angle (in degrees) of the cone
BOOL SetAngle (GLI_tdxValue *); // Set the angle (in degrees) of the cone. Return FALSE if value is not correct
};
*/
//-----------------------------------------------------------------------------
// class ZDx_Point
//
// Definition of the class to modify the geometric aspect of a ZDx of type point
//-----------------------------------------------------------------------------
class ZDx_Point : public ZDx_Shape
{
public:
ZDx_Point (ZDx_Object * _pZDxObject , Shape3D * /* ACP_tdxHandleOfElement */, ZDx_Point * _pZDxPointToCopy = NULL); // Constructor
/*
MTH3D_tdstVector GetPoint (); // return the 3D coordinates of the point
void SetPoint (MTH3D_tdstVector *); // set the 3D coordinates of the point
void SetPointX (GLI_tdxValue);
void SetPointY (GLI_tdxValue);
void SetPointZ (GLI_tdxValue);
MTH3D_tdstVector GetCenter () { return ((Point3D *) GetGeometric3dObject ()) -> GetPoint (); }
void SetCenter (MTH3D_tdstVector * _pCenter) { ((Point3D *) GetGeometric3dObject ()) -> SetPoint (_pCenter); }
void SetColorOfPoint (BOOL _bSelected); // Set the color of the point : selected or not selected
private:
*/
// ANNECY AV CLEAN_MEC {
// void UpdateTestPointPosition (); // Set the position of the test point with the position of the point
// END ANNECY AV }
};
//ENDROMTEAM WorldEditor (Cristi Petrescu)
#endif //__ZOBJECT_HPP__

View File

@@ -0,0 +1,145 @@
//{{NO_DEPENDENCIES}}
// Microsoft Developer Studio generated include file.
// Used by D:\cpa\tempgrp\ozo\Inc\Resource.rc
//
#define IDD_ZDD_Info_Window 170
#define IDD_ZDD_Box_Info_Window_1 171
#define IDD_ZDD_Box_Info_Window_2 172
#define IDD_ZDD_Box_Info_Window 173
#define IDD_ZDD_Point_Info_Window 174
#define IDD_ZDD_Sphere_Info_Window 175
#define IDD_ZDD_List1_Window 176
#define IDD_ZDD_List2_Window 177
#define IDB_Bitmap_Return 180
#define IDI_Icon_Family 190
#define IDI_Icon_Model 191
#define IDI_Icon_Instance 192
#define IDI_Icon_Module 194
#define IDI_Icon_ZDx 195
#define IDI_Icon_Big_Global_Zone 196
#define IDC_Cursor_Drag_And_Drop 197
#define IDI_Icon_Common_Mode 198
#define IDI_Icon_Shared_Mode 199
#define IDI_Icon_Virge_Mode 200
#define IDB_Bitmap_Show_Actor 201
#define IDC_Cursor_No_Drag_And_Drop 202
#define IDD_ZDD_Cone_Info_Window 203
#define IDB_Bitmap_Show_Module 205
#define IDD_ZDD_Display_Control_Window 206
#define IDB_Bitmap_Show_Module_ZDx 208
#define IDI_Icon_Motor_Display_On 210
#define IDI_Icon_Motor_Display_Off 211
#define IDB_Bitmap_Bounding_Volume 212
#define IDB_Bitmap_Test_Point 214
#define IDI_Icon_Used_Module 215
#define IDD_CHECK_ZONES_AGAINST_BV 216
#define IDI_ZDX_DLGBAR_ICON 217
#define IDC_OK_Button 1002
#define IDC_Static_Text_Name 1018
#define IDC_Edition_Zone_Name 1019
#define IDC_Edition_Zone_Type 1020
#define IDC_Static_Text_Center_X 1021
#define IDC_Static_Text_Center_Y 1022
#define IDC_Frame 1023
#define IDC_Static_Text_Center_Z 1024
#define IDC_Static_Text_Radius 1025
#define IDC_Edition_Zone_Center_X 1026
#define IDC_Static_Text_Angle 1026
#define IDC_Edition_Zone_Center_Y 1027
#define IDC_Edition_Zone_Center_Z 1028
#define IDC_Edition_Zone_Length 1029
#define IDC_Cancel_Button 1031
#define IDC_Static_Text_Length 1032
#define IDC_Static_Text_Width 1033
#define IDC_Edition_Zone_Width 1035
#define IDC_Check_Box_Cube 1037
#define IDC_Radio_Button_Center 1038
#define IDC_Radio_Button_Extrema 1039
#define IDC_Static_Text_X_Mini 1040
#define IDC_Static_Text_Y_Mini 1041
#define IDC_Static_Text_Z_Mini 1042
#define IDC_Edition_Zone_X_Mini 1043
#define IDC_Edition_Zone_Y_Mini 1044
#define IDC_Edition_Zone_Z_Mini 1045
#define IDC_Static_Text_X_Maxi 1046
#define IDC_Static_Text_Y_Maxi 1047
#define IDC_Static_Text_Z_Maxi 1048
#define IDC_Edition_Zone_X_Maxi 1049
#define IDC_Edition_Zone_Y_Maxi 1050
#define IDC_Edition_Zone_Z_Maxi 1051
#define IDC_Frame_Mini 1052
#define IDC_Frame_Center 1053
#define IDC_Frame_Maxi 1054
#define IDC_Static_Text_Height 1055
#define IDC_Edition_Zone_Height 1056
#define IDC_Static_Text_X 1057
#define IDC_Static_Text_Y 1058
#define IDC_Static_Text_Z 1059
#define IDC_Edition_Zone_X 1060
#define IDC_Edition_Zone_Y 1061
#define IDC_Edition_Zone_Z 1062
#define IDC_Pos_Shape_Info_Window 1066
#define IDC_Apply_Button 1068
#define IDC_Edition_Zone_Radius 1073
#define IDC_Check_Box_ZDD 1074
#define IDC_Edition_Zone_Angle 1074
#define IDC_Check_Box_ZDE 1075
#define IDC_Check_Box_ZDM 1076
#define IDC_Check_Box_ZDR 1077
#define IDC_Button_All_ZDx 1078
#define IDC_Button_Return 1085
#define IDC_Tree_Ctrl_1 1086
#define IDC_Combo_Box_List_1 1087
#define IDC_Tree_Ctrl_2 1088
#define IDC_Check_Button_Show_Actor 1100
#define IDC_Frame_Top 1101
#define IDC_Check_Button_Show_Module 1101
#define IDC_Frame_Base 1102
#define IDC_Check_Button_Show_Module_ZDx 1102
#define IDC_Static_Text_X_Top 1103
#define IDC_Check_Button_Bounding_Volume 1103
#define IDC_Static_Text_Y_Top 1104
#define IDC_Check_Button_Test_Point 1104
#define IDC_Static_Text_Z_Top 1105
#define IDC_Static_Text_X_Base 1106
#define IDC_Static_Text_Y_Base 1107
#define IDC_Static_Text_Z_Base 1108
#define IDC_Edition_Zone_X_Top 1109
#define IDC_Edition_Zone_Y_Top 1110
#define IDC_Edition_Zone_Z_Top 1111
#define IDC_Edition_Zone_X_Base 1112
#define IDC_Edition_Zone_Y_Base 1113
#define IDC_Edition_Zone_Z_Base 1114
#define IDC_Combo_Box_List 1115
#define IDC_Frame_All_Actors 1116
#define IDC_Frame_Current_Actor 1117
#define IDC_Radio_Button_All_Actors_On 1118
#define IDC_Radio_Button_All_Actors_Off 1119
#define IDC_List_Ctrl_2 1119
#define IDC_Radio_Button_Current_Actor_On 1120
#define IDC_Slider_Radius 1120
#define IDC_Radio_Button_Current_Actor_Off 1121
#define IDC_Static_Text_0 1121
#define IDC_Radio_Button_All_Actors_Selected 1122
#define IDC_Static_Text_1 1122
#define IDC_Radio_Button_Current_Actor_Selected 1123
#define IDC_Static_Text_1_5 1123
#define IDC_Button_Init 1124
#define IDC_Slider_Size 1125
#define IDC_Button_New_List 1126
#define IDC_Button_No_ZDx 1127
#define IDC_CHECK_ZONES 1129
#define IDC_CHECK_YES 1130
#define IDC_LIST_ZONES 1131
#define IDC_Static_Text_Type -1
// Next default values for new objects
//
#ifdef APSTUDIO_INVOKED
#ifndef APSTUDIO_READONLY_SYMBOLS
#define _APS_NEXT_RESOURCE_VALUE 218
#define _APS_NEXT_COMMAND_VALUE 40001
#define _APS_NEXT_CONTROL_VALUE 1132
#define _APS_NEXT_SYMED_VALUE 170
#endif
#endif

View File

@@ -0,0 +1,451 @@
//*****************************************************************************
//* _zWEdit.hpp *
//*****************************************************************************
//* *
//* This file contains the definitions of the edit windows *
//* *
//*****************************************************************************
//* Author : Alexis Vaisse *
//*****************************************************************************
#ifndef __ZWEDIT_HPP
#define __ZWEDIT_HPP
#pragma once
// personal include
#include "_zRes.h" // File created by Microsoft Developer Studio
#include "_zObject.hpp"
// class of "_modif.hpp"
class ZDx_Modif;
// class defined latter
class CZDxShapeInfoWindow;
typedef enum eDisplayType_ { eNoZone , eOn , eOff , eSelected } tdeDisplayType;
//-----------------------------------------------------------------------------
// class CDisplayControlWindow
//
// Window that controls the display of the zones
//-----------------------------------------------------------------------------
class CDisplayControlWindow : public CFormView
{
// Construction
public:
CDisplayControlWindow(CWnd* pParent = NULL); // standard constructor
DECLARE_DYNCREATE (CDisplayControlWindow)
// Dialog Data
//{{AFX_DATA(CDisplayControlWindow)
enum { IDD = IDD_ZDD_Display_Control_Window };
int m_Radio_Button_All_Actors;
int m_Radio_Button_Current_Actor;
//}}AFX_DATA
// Overrides
// ClassWizard generated virtual function overrides
//{{AFX_VIRTUAL(CDisplayControlWindow)
public:
virtual BOOL Create(LPCTSTR lpszClassName, LPCTSTR lpszWindowName, DWORD dwStyle, const RECT& rect, CWnd* pParentWnd, UINT nID, CCreateContext* pContext = NULL);
virtual BOOL PreTranslateMessage(MSG* pMsg);
protected:
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
//}}AFX_VIRTUAL
// Implementation
protected:
// Generated message map functions
//{{AFX_MSG(CDisplayControlWindow)
afx_msg void On_Radio_Buttons_All_Actors();
afx_msg void On_Radio_Buttons_Current_Actor();
//}}AFX_MSG
afx_msg BOOL SetToolTipText(UINT uiControlId , NMHDR *pNMHDR, LRESULT *pResult);
DECLARE_MESSAGE_MAP()
// Private data
private:
CToolTipCtrl m_ToolTipCtrl;
ZDx_Interface * m_pZDxInterface;
public:
void SetZDxInterface (ZDx_Interface * _pZDxInterface) { m_pZDxInterface = _pZDxInterface; }
tdeDisplayType GetDisplayForAllActors (); // Get the state of the "All actors" radio button
tdeDisplayType GetDisplayForCurrentActor (); // Get the state of the "Current actor" radio button
void SetDisplayForAllActors (tdeDisplayType); // Set the state of the "All actors" radio button
void SetDisplayForCurrentActor (tdeDisplayType); // Set the state of the "Current actor" radio button
void SetNameOfCurrentActor (CString); // Set the name of the current actor (it is showed in the window)
void DisplayAllActors (); // Display all actors with the correct zones
};
//-----------------------------------------------------------------------------
// class CZDxInfoWindow
//
// Window that shows informations about a ZDx object
//-----------------------------------------------------------------------------
class CZDxInfoWindow : public CFormView
{
// Construction
public:
CZDxInfoWindow(CWnd* pParent = NULL); // standard constructor
DECLARE_DYNCREATE (CZDxInfoWindow)
// Dialog Data
//{{AFX_DATA(CZDxInfoWindow)
enum { IDD = IDD_ZDD_Info_Window };
CString m_Edition_Zone_Name;
CString m_Edition_Zone_Type;
//}}AFX_DATA
// Overrides
// ClassWizard generated virtual function overrides
//{{AFX_VIRTUAL(CZDxInfoWindow)
public:
virtual BOOL Create(LPCTSTR lpszClassName, LPCTSTR lpszWindowName, DWORD dwStyle, const RECT& rect, CWnd* pParentWnd, UINT nID, CCreateContext* pContext = NULL);
virtual BOOL PreTranslateMessage(MSG* pMsg);
protected:
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
//}}AFX_VIRTUAL
// Implementation
protected:
// Generated message map functions
//{{AFX_MSG(CZDxInfoWindow)
afx_msg void On_Change_Edition_Zone_Name();
afx_msg void OnCancel();
afx_msg void OnOK();
afx_msg void On_Apply_Button();
afx_msg void On_Cancel_Button();
//}}AFX_MSG
DECLARE_MESSAGE_MAP()
// Personal data
private:
CPA_SuperObject * m_pZDxSuperObject; // Pointer to the ZDx super object
ZDx_Object * m_pZDxObject; // Pointer to the ZDx object
ZDx_Modif * m_pZDxModif; // Pointer to the ZDx modif
BOOL m_bIsApplying; // Is TRUE when cliquing on the Apply button
CZDxShapeInfoWindow * m_pCZDxShapeInfoWindow; // Pointer to the child window
tdeZDxGeometricType m_eTypeShapeInfoWindow; // Type of the shape info window (sphere, box...)
BOOL m_ZDxHasBeenChanged; // Indicate if the ZDx has been changed or not
void OpenShapeInfoWindow ();
void CloseShapeInfoWindow ();
CWnd * GetFirstControlOfWindow (); // Get the first control of the window
CWnd * GetLastControlOfWindow (); // Get the last control of the window
BOOL OnTabKeyPressed (); // Called when the Tab key is pressed
BOOL OnShiftTabKeyPressed (); // Called when the Tab key is pressed with shift
public:
void SetZDxHasBeenChanged (BOOL b);
ZDx_Object * GetZDxObjectEdited () { return m_pZDxObject; }
void SetZDxObjectToEdit (CPA_SuperObject *); // Give a ZDx object to edit
void Apply (); // To simulate a clic on the Apply button
void Cancel (); // To simulate a clic on the Cancel button
void RefreshData (BOOL RedrawNeeded); // Called when the data need to be refreshed
// The ZDx object can be redrawed or not
void RefreshModif (); // Create a modif for the edited ZDx object
};
//-----------------------------------------------------------------------------
// class CZDxShapeInfoWindow
// Abstract class
//-----------------------------------------------------------------------------
class CZDxShapeInfoWindow : public CDialog
{
public:
virtual void SetZDxShapeToEdit (ZDx_Shape *) = 0; // Set the ZDx shape to edit
virtual void RefreshData () = 0; // Called when the data need to be refreshed
virtual CWnd * GetFirstControlOfWindow () = 0; // Get the first control of the window
virtual CWnd * GetLastControlOfWindow () = 0; // Get the last control of the window
virtual BOOL PreTranslateMessage (MSG * pMsg);
protected:
void SetZDxHasBeenChanged (BOOL); // indicate to the parent window that the ZDx object has been changed
void OnOK ();
void OnCancel ();
};
//-----------------------------------------------------------------------------
// class CZDxSphereInfoWindow
//
// Window that shows informations about a ZDx sphere object
//-----------------------------------------------------------------------------
class CZDxSphereInfoWindow : public CZDxShapeInfoWindow
{
// Construction
public:
//ROMTEAM WorldEditor (Cristi Petrescu 12/97)
CZDxSphereInfoWindow (CWnd * pParent , ZDx_Shape * pZDxObject , CPA_SuperObject * _pFatherSuperObject , ZDx_Interface *);
//ENDROMTEAM WorldEditor (Cristi Petrescu)
// Dialog Data
//{{AFX_DATA(CZDxSphereInfoWindow)
enum { IDD = IDD_ZDD_Sphere_Info_Window };
CString m_Edition_Zone_Center_X;
CString m_Edition_Zone_Center_Y;
CString m_Edition_Zone_Center_Z;
CString m_Edition_Zone_Radius;
CSliderCtrl m_Slider_Radius;
//}}AFX_DATA
// Overrides
// ClassWizard generated virtual function overrides
//{{AFX_VIRTUAL(CZDxSphereInfoWindow)
protected:
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
//}}AFX_VIRTUAL
// Implementation
protected:
// Generated message map functions
//{{AFX_MSG(CZDxSphereInfoWindow)
virtual BOOL OnInitDialog();
afx_msg void On_Change_Edition_Zone_Center_X();
afx_msg void On_Change_Edition_Zone_Center_Y();
afx_msg void On_Change_Edition_Zone_Center_Z();
afx_msg void On_Change_Edition_Zone_Radius();
afx_msg void OnHScroll(UINT nSBCode, UINT nPos, CScrollBar* pScrollBar);
afx_msg void On_Button_Init();
afx_msg void OnDestroy();
//}}AFX_MSG
DECLARE_MESSAGE_MAP()
// Personal data
private:
//ROMTEAM WorldEditor (Cristi Petrescu 12/97)
ZDx_Shape * m_pZDxSphere;
Sphere3D * m_pSphere3D; // Pointer to the ZDx sphere
//ENDROMTEAM WorldEditor (Cristi Petrescu)
MTH_tdxReal m_FatherRadius; // Radius of the father of the ZDx object
MTH3D_tdstVector m_FatherCenter; // Center of the father of the ZDx object
void RefreshSlider ();
void RefreshRadiusFromSlider ();
public:
void SetZDxShapeToEdit (ZDx_Shape *); // Set the ZDx shape to edit
void RefreshData (); // Called when the data need to be refreshed
CWnd * GetFirstControlOfWindow (); // Get the first control of the window
CWnd * GetLastControlOfWindow (); // Get the last control of the window
};
//-----------------------------------------------------------------------------
// class CZDxBoxInfoWindow
//
// Window that shows informations about a ZDx box object
//-----------------------------------------------------------------------------
class CZDxBoxInfoWindow : public CZDxShapeInfoWindow
{
// Construction
public:
//ROMTEAM WorldEditor (Cristi Petrescu 12/97)
CZDxBoxInfoWindow(CWnd* pParent , ZDx_Shape * pZDxObject , CPA_SuperObject * _pFatherSuperObject , ZDx_Interface *);
//ENDROMTEAM WorldEditor (Cristi Petrescu)
// Dialog Data
//{{AFX_DATA(CZDxBoxInfoWindow)
enum { IDD = IDD_ZDD_Box_Info_Window };
int m_Radio_Button;
BOOL m_Check_Box_Cube;
CString m_Edition_Zone_Center_X;
CString m_Edition_Zone_Center_Y;
CString m_Edition_Zone_Center_Z;
CString m_Edition_Zone_Height;
CString m_Edition_Zone_Length;
CString m_Edition_Zone_Width;
CString m_Edition_Zone_X_Maxi;
CString m_Edition_Zone_X_Mini;
CString m_Edition_Zone_Y_Maxi;
CString m_Edition_Zone_Y_Mini;
CString m_Edition_Zone_Z_Maxi;
CString m_Edition_Zone_Z_Mini;
CSliderCtrl m_Slider_Size;
//}}AFX_DATA
// Overrides
// ClassWizard generated virtual function overrides
//{{AFX_VIRTUAL(CZDxBoxInfoWindow)
protected:
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
//}}AFX_VIRTUAL
// Implementation
protected:
// Generated message map functions
//{{AFX_MSG(CZDxBoxInfoWindow)
virtual BOOL OnInitDialog();
afx_msg void On_Radio_Button_Center();
afx_msg void On_Radio_Button_Extrema();
afx_msg void On_Change_Edition_Zone_X_Mini();
afx_msg void On_Change_Edition_Zone_Y_Mini();
afx_msg void On_Change_Edition_Zone_Z_Mini();
afx_msg void On_Change_Edition_Zone_X_Maxi();
afx_msg void On_Change_Edition_Zone_Y_Maxi();
afx_msg void On_Change_Edition_Zone_Z_Maxi();
afx_msg void On_Change_Edition_Zone_Center_X();
afx_msg void On_Change_Edition_Zone_Center_Y();
afx_msg void On_Change_Edition_Zone_Center_Z();
afx_msg void On_Change_Edition_Zone_Length();
afx_msg void On_Change_Edition_Zone_Width();
afx_msg void On_Change_Edition_Zone_Height();
afx_msg void On_Check_Box_Cube();
afx_msg void OnHScroll(UINT nSBCode, UINT nPos, CScrollBar* pScrollBar);
afx_msg void On_Button_Init();
afx_msg void OnDestroy();
//}}AFX_MSG
DECLARE_MESSAGE_MAP()
// Personal data
private:
//ROMTEAM WorldEditor (Cristi Petrescu 12/97)
ZDx_Shape * m_pZDxBox; // pointer to the ZDx box
Box3D * m_pBox3D;
//ENDROMTEAM WorldEditor (Cristi Petrescu)
BOOL m_ZDxIsACube; // Indicate if the ZDx box is a cube or not
double m_FatherAverageSize;
MTH3D_tdstVector m_FatherMinPoint;
MTH3D_tdstVector m_FatherMaxPoint;
void RefreshSlider ();
void RefreshSizeFromSlider ();
public:
void SetZDxShapeToEdit (ZDx_Shape *); // Set the ZDx shape to edit
void RefreshData (); // Called when the data need to be refreshed
void RefreshData (BOOL _bKeepCube); // Idem
CWnd * GetFirstControlOfWindow (); // Get the first control of the window
CWnd * GetLastControlOfWindow (); // Get the last control of the window
};
//-----------------------------------------------------------------------------
// class CZDxPointInfoWindow
//
// Window that shows informations about a ZDx point object
//-----------------------------------------------------------------------------
class CZDxPointInfoWindow : public CZDxShapeInfoWindow
{
// Construction
public:
CZDxPointInfoWindow (CWnd * pParent , ZDx_Point * pZDxObject);
// Dialog Data
//{{AFX_DATA(CZDxPointInfoWindow)
enum { IDD = IDD_ZDD_Point_Info_Window };
CString m_Edition_Zone_X;
CString m_Edition_Zone_Y;
CString m_Edition_Zone_Z;
//}}AFX_DATA
// Overrides
// ClassWizard generated virtual function overrides
//{{AFX_VIRTUAL(CZDxPointInfoWindow)
protected:
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
//}}AFX_VIRTUAL
// Implementation
protected:
// Generated message map functions
//{{AFX_MSG(CZDxPointInfoWindow)
afx_msg void On_Change_Edition_Zone_X();
afx_msg void On_Change_Edition_Zone_Y();
afx_msg void On_Change_Edition_Zone_Z();
virtual BOOL OnInitDialog();
afx_msg void OnDestroy();
//}}AFX_MSG
DECLARE_MESSAGE_MAP()
// Personal data
private:
ZDx_Point * m_pZDxPoint; // pointer to the ZDx point
//ROMTEAM WorldEditor (Cristi Petrescu 12/97)
Point3D * m_pPoint3D;
//ENDROMTEAM WorldEditor (Cristi Petrescu)
public:
void SetZDxShapeToEdit (ZDx_Shape *); // Set the ZDx shape to edit
void RefreshData (); // Called when the data need to be refreshed
CWnd * GetFirstControlOfWindow (); // Get the first control of the window
CWnd * GetLastControlOfWindow (); // Get the last control of the window
};
//-----------------------------------------------------------------------------
// class CZDxConeInfoWindow
//
// Window that shows informations about a ZDx cone object
//-----------------------------------------------------------------------------
class CZDxConeInfoWindow : public CZDxShapeInfoWindow
{
// Construction
public:
//ROMTEAM WorldEditor (Cristi Petrescu 12/97)
CZDxConeInfoWindow (CWnd * pParent , ZDx_Shape * pZDxObject);
//ENDROMTEAM WorldEditor (Cristi Petrescu)
// Dialog Data
//{{AFX_DATA(CZDxConeInfoWindow)
enum { IDD = IDD_ZDD_Cone_Info_Window };
CString m_Edition_Zone_Angle;
CString m_Edition_Zone_Radius;
CString m_Edition_Zone_X_Base;
CString m_Edition_Zone_X_Top;
CString m_Edition_Zone_Y_Base;
CString m_Edition_Zone_Y_Top;
CString m_Edition_Zone_Z_Base;
CString m_Edition_Zone_Z_Top;
//}}AFX_DATA
// Overrides
// ClassWizard generated virtual function overrides
//{{AFX_VIRTUAL(CZDxConeInfoWindow)
protected:
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
//}}AFX_VIRTUAL
// Implementation
protected:
// Generated message map functions
//{{AFX_MSG(CZDxConeInfoWindow)
virtual BOOL OnInitDialog();
afx_msg void On_Change_Edition_Zone_Angle();
afx_msg void On_Change_Edition_Zone_Radius();
afx_msg void On_Change_Edition_Zone_X_Base();
afx_msg void On_Change_Edition_Zone_X_Top();
afx_msg void On_Change_Edition_Zone_Y_Base();
afx_msg void On_Change_Edition_Zone_Y_Top();
afx_msg void On_Change_Edition_Zone_Z_Base();
afx_msg void On_Change_Edition_Zone_Z_Top();
afx_msg void OnDestroy();
//}}AFX_MSG
DECLARE_MESSAGE_MAP()
// Personal data
private:
//ROMTEAM WorldEditor (Cristi Petrescu 12/97)
ZDx_Shape * m_pZDxCone; // pointer to the ZDx cone
Cone3D * m_pCone3D;
//ENDROMTEAM WorldEditor (Cristi Petrescu)
public:
void SetZDxShapeToEdit (ZDx_Shape *); // Set the ZDx shape to edit
void RefreshData (); // Called when the data need to be refreshed
CWnd * GetFirstControlOfWindow (); // Get the first control of the window
CWnd * GetLastControlOfWindow (); // Get the last control of the window
};
#endif // __ZWEDIT_HPP

View File

@@ -0,0 +1,240 @@
//*****************************************************************************
//* _zWList1.hpp *
//*****************************************************************************
//* *
//* This file contains the definitions of the first list window *
//* *
//*****************************************************************************
//* Author : Alexis Vaisse *
//*****************************************************************************
#ifndef __ZWLIST1_HPP
#define __ZWLIST1_HPP
#pragma once
// Actors dll "include"
class EdtList;
class CPA_tdoNameList;
// Physical Object dll "include"
class EditorPO;
// personal "include"
#include "_zRes.h" // File created by Microsoft Developer Studio
#include "_zObject.hpp"
class ZDx_Interface;
//-----------------------------------------------------------------------------
// Definition for the first list
//-----------------------------------------------------------------------------
typedef enum eList1Type_ {eListOfFamily , eListOfModel , eListOfModelOfFamily , eListOfInstance , eListOfModule} tdeList1Type;
#define C_szListOfFamily "List of all families"
#define C_szListOfModel "List of all models"
#define C_szListOfModelOfFamily "List of models of same family"
#define C_szListOfInstance "List of instances"
#define C_szListOfModule "List of modules"
#define C_szListOfModelOfGivenFamily "List of models of family: "
#define C_szListOfInstanceOfGivenModel "List of instances of model: "
#define C_szListOfModuleOfGivenTable "List of modules of table: "
#define C_ucIconFamily 0
#define C_ucIconModel 1
#define C_ucIconInstance 2
#define C_ucIconModule 3
#define C_ucIconUsedModule 4
#define C_ucIconZDx 5
#define C_ucIconBigGlobalZone 6
//-----------------------------------------------------------------------------
// class TreeControl
//-----------------------------------------------------------------------------
//----------------------------
// ANNECY AV CLEAN_MEC {
typedef enum eTreeElementType_ { eFamilyElement , eModelElement , eInstanceElement ,
eModuleElement , eBigGlobalZoneElement ,
eZddElement , eZdeElement , eZdmElement , eZdrElement ,
eBoundingVolumeElement /* , eTestPointElement */
} tdeTreeElementType;
// END ANNECY AV }
//-------------------------------
typedef struct stTreeElementData_
{
tdeTreeElementType eType;
CPA_BaseObject * pObject;
CPA_SuperObject * pSuperObject;
} tdstTreeElementData;
//----------------------------------
class TreeControl : public CTreeCtrl
{
private:
void DeleteItemRecursive (HTREEITEM hHandle);
public:
HTREEITEM InsertItem (LPCTSTR Name , tdeTreeElementType _eType , CPA_BaseObject * _pObject , CPA_SuperObject * _pSuperObject ,
HTREEITEM hParent = TVI_ROOT , HTREEITEM hInsertAfter = TVI_LAST);
BOOL DeleteAllItems ();
BOOL DestroyWindow ();
};
//-----------------------------------------------------------------------------
// class CList1Window
//
// Window that shows different lists
//-----------------------------------------------------------------------------
class CList1Window : public CFormView
{
// Construction
public:
CList1Window(CWnd* pParent = NULL); // standard constructor
DECLARE_DYNCREATE (CList1Window)
// Dialog Data
//{{AFX_DATA(CList1Window)
enum { IDD = IDD_ZDD_List1_Window };
CButton m_Check_Button_Show_Actor;
CButton m_Check_Button_Show_Module;
CButton m_Check_Button_Show_Module_ZDx;
CButton m_Check_Button_Bounding_Volume;
CButton m_Check_Button_Test_Point;
CButton m_Button_Return;
CComboBox m_Combo_Box_List_1;
TreeControl m_Tree_Ctrl_1;
CString m_Combo_Box_String_List_1;
//}}AFX_DATA
// Overrides
// ClassWizard generated virtual function overrides
//{{AFX_VIRTUAL(CList1Window)
public:
virtual BOOL Create(LPCTSTR lpszClassName, LPCTSTR lpszWindowName, DWORD dwStyle, const RECT& rect, CWnd* pParentWnd, UINT nID, CCreateContext* pContext = NULL);
virtual BOOL PreTranslateMessage(MSG* pMsg);
protected:
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
virtual BOOL OnCommand(WPARAM wParam, LPARAM lParam);
//}}AFX_VIRTUAL
// Implementation
protected:
// Generated message map functions
//{{AFX_MSG(CList1Window)
afx_msg void OnSize(UINT nType, int cx, int cy);
afx_msg void On_Selection_Has_Changed_Combo_Box_List_1();
afx_msg void On_Return_Button();
afx_msg void On_Double_Click_Tree_Ctrl_1(NMHDR* pNMHDR, LRESULT* pResult);
afx_msg void On_Selection_Has_Changed_Tree_Ctrl_1(NMHDR* pNMHDR, LRESULT* pResult);
afx_msg void OnDrawItem(int nIDCtl, LPDRAWITEMSTRUCT lpDrawItemStruct);
afx_msg void On_Right_Click_Tree_Ctrl_1(NMHDR* pNMHDR, LRESULT* pResult);
afx_msg void On_Check_Button_Show_Actor();
afx_msg void On_Check_Button_Show_Module();
afx_msg void On_Check_Button_Show_Module_ZDx();
afx_msg void On_Check_Button_Bounding_Volume();
afx_msg void On_Check_Button_Test_Point();
afx_msg void On_Key_Down_Tree_Ctrl_1(NMHDR* pNMHDR, LRESULT* pResult);
afx_msg void On_Begin_Change_Name_Tree_Ctrl_1(NMHDR* pNMHDR, LRESULT* pResult);
afx_msg void On_End_Change_Name_Tree_Ctrl_1(NMHDR* pNMHDR, LRESULT* pResult);
//}}AFX_MSG
afx_msg BOOL SetToolTipText(UINT uiControlId , NMHDR *pNMHDR, LRESULT *pResult);
DECLARE_MESSAGE_MAP()
// Private data
private:
ZDx_Interface * m_pZDxInterface;
CBitmap m_ButtonReturnBitmap;
CBitmap m_ButtonShowActorBitmap;
CBitmap m_ButtonShowModuleBitmap;
CBitmap m_ButtonShowModuleZDxBitmap;
CBitmap m_ButtonBoundingVolumeBitmap;
CBitmap m_ButtonTestPointBitmap;
CImageList m_stImageList;
CToolTipCtrl m_ToolTipCtrl;
tdeList1Type m_eList1Type;
CPA_BaseObject * m_pSelectedFamily;
CPA_BaseObject * m_pSelectedModel;
CPA_BaseObject * m_pSelectedActor;
CPA_SuperObject * m_pSelectedActorSuperObject;
EdtList * m_pSelectedBigGlobalZone;
BOOL m_bIsCreatingList; // Is TRUE when creating a list. Becomes FALSE when the list is created
BOOL m_bCanSelectListOfFamily;
BOOL m_bCanSelectListOfModel;
BOOL m_bCanSelectListOfModelOfFamily;
BOOL m_bCanSelectListOfInstance;
BOOL m_bCanSelectListOfModule;
BOOL ComboBoxLineEnabled (char * _szName);
void ComboBoxChoseCorrectName (char * _szNewName , char * _szOldName);
void ComboBoxDrawLine (LPDRAWITEMSTRUCT lpDrawItemStruct);
void CreateANewListOfZDx (tdeZDxType _eType);
void DeleteSelectedElement ();
HTREEITEM FindAnElementInTree (HTREEITEM _hItem , void * _pData , void * _pParentData = NULL);
void ChangeIconOfModuleAndChild (CPA_SuperObject * pSuperObject);
void SetCameraOnActor (CPA_SuperObject * _pActorSuperObject);
void ShowActorAlone ();
void ShowModuleAlone ();
public:
void SetZDxInterface (ZDx_Interface * _pZDxInterface) { m_pZDxInterface = _pZDxInterface; }
void CreateListOfFamily (CPA_BaseObject * _pFamilyToSelect = NULL ,
CPA_BaseObject * _pModelToSelect = NULL);
void CreateListOfModel (CPA_BaseObject * _pModelToSelect = NULL ,
CPA_BaseObject * _pInstanceToSelect = NULL);
void CreateListOfModelOfFamily (CPA_BaseObject * _pFamily ,
CPA_BaseObject * _pModelToSelect = NULL ,
CPA_BaseObject * _pInstanceToSelect = NULL);
void CreateListOfInstance (CPA_BaseObject * _pModel ,
CPA_BaseObject * _pInstanceToSelect = NULL ,
EdtList * _pBigGlobalZoneToSelect = NULL);
void CreateListOfModule (CPA_SuperObject * _pActorSuperObject ,
CPA_BaseObject * _pModuleToSelect = NULL ,
BOOL _bOpenGrid = TRUE);
void LeaveListOfModule ();
void ReCreateCurrentList ();
void SelectInstance (CPA_BaseObject * _pInstanceToSelect , BOOL bRefreshNeeded);
void SelectBigGlobalZone (CPA_BaseObject * _pInstance ,
EdtList * _pBigGlobalZone , BOOL bRefreshNeeded);
void SelectModule (CPA_BaseObject * _pModule , BOOL bRefreshNeeded);
void SelectZDxOfActor (CPA_BaseObject * _pInstance ,
ZDx_Object * _pZDxObject , BOOL bRefreshNeeded);
void SelectZDxOfModule (CPA_BaseObject * _pModule ,
ZDx_Object * _pZDxObject , BOOL bRefreshNeeded);
CPA_BaseObject * GetSelectedModule ();
CPA_SuperObject * GetSelectedModuleSuperObject ();
void SetShowActorButtonState (BOOL _bButtonChecked);
BOOL GetShowActorButtonState () { return m_Check_Button_Show_Actor . GetCheck (); }
CPA_BaseObject * GetSelectedActor () { return m_pSelectedActor; }
CPA_SuperObject * GetSelectedActorSuperObject () { return m_pSelectedActorSuperObject; }
BOOL IsEditingZDxOfModule () { return m_eList1Type == eListOfModule; }
BOOL IsEditingBoundingVolume () { return m_Check_Button_Bounding_Volume . GetCheck (); }
void EnterEditionOfBoundingVolume ();
void LeaveEditionOfBoundingVolume ();
// ANNECY AV CLEAN_MEC {
/*
BOOL IsEditingTestPoint () { return m_Check_Button_Test_Point . GetCheck (); }
void EnterEditionOfTestPoint ();
void LeaveEditionOfTestPoint ();
*/
// END ANNECY AV }
};
#endif // __ZWLIST1_HPP

View File

@@ -0,0 +1,226 @@
//*****************************************************************************
//* _zWList2.hpp *
//*****************************************************************************
//* *
//* This file contains the definitions of the second list window *
//* *
//*****************************************************************************
//* Author : Alexis Vaisse *
//*****************************************************************************
#ifndef __ZWLIST2_HPP
#define __ZWLIST2_HPP
#pragma once
// Actors dll "include"
class EdtList;
class CPA_tdoNameList;
// Physical Object dll "include"
class EditorPO;
// Family dll "include"
class CPA_Family;
// ANNECY AV CLEAN_MEC {
//class CPA_TestPointsList;
//class CPA_TestPointNode;
// END ANNECY AV }
// personal "include"
#include "_zRes.h" // File created by Microsoft Developer Studio
#include "_zObject.hpp"
class ZDx_Interface;
//-----------------------
typedef enum eSharedMode_ { eNoSharedMode , eCommon , eShared , eVirge } tdeSharedMode;
//-------------------------------
typedef struct stListElementData_
{
tdeTreeElementType eType;
ZDx_Object * pZDxObject;
CPA_SuperObject * pZDxSuperObject;
CString csNameInNameList;
tdeSharedMode eSharedMode;
// Used for the test points
// ANNECY AV CLEAN_MEC {
// DNM_tdeKindOfPoint eKindOfPoint;
// CPA_TestPointNode * pTestPoint;
// END ANNECY AV }
} tdstListElementData;
//-----------------------------------------------------------------------------
// class CList2Window
//
// Window that shows different lists
//-----------------------------------------------------------------------------
class CList2Window : public CFormView
{
// Construction
public:
CList2Window(CWnd* pParent = NULL); // standard constructor
DECLARE_DYNCREATE (CList2Window)
// Dialog Data
//{{AFX_DATA(CList2Window)
enum { IDD = IDD_ZDD_List2_Window };
CComboBox m_Combo_Box_List;
CListBox m_List_Ctrl_2;
BOOL m_bShowZDD;
BOOL m_bShowZDE;
BOOL m_bShowZDM;
BOOL m_bShowZDR;
CString m_Combo_Box_String_List;
//}}AFX_DATA
// Overrides
// ClassWizard generated virtual function overrides
//{{AFX_VIRTUAL(CList2Window)
public:
virtual BOOL Create(LPCTSTR lpszClassName, LPCTSTR lpszWindowName, DWORD dwStyle, const RECT& rect, CWnd* pParentWnd, UINT nID, CCreateContext* pContext = NULL);
virtual BOOL PreTranslateMessage(MSG* pMsg);
protected:
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
virtual BOOL OnCommand(WPARAM wParam, LPARAM lParam);
//}}AFX_VIRTUAL
// Implementation
protected:
// Generated message map functions
//{{AFX_MSG(CList2Window)
afx_msg void OnDrawItem(int nIDCtl, LPDRAWITEMSTRUCT lpDrawItemStruct);
afx_msg void On_Button_All_ZDx();
afx_msg void On_Button_No_ZDx();
afx_msg void On_Button_New_List();
afx_msg void On_Check_Boxes_ZDx();
afx_msg void On_Selection_Has_Changed_List_Ctrl_2(/*NMHDR* pNMHDR, LRESULT* pResult*/);
afx_msg void OnSize(UINT nType, int cx, int cy);
afx_msg void OnMouseMove(UINT nFlags, CPoint point);
afx_msg void On_Selection_Has_Changed_Combo_Box_List();
//}}AFX_MSG
afx_msg BOOL SetToolTipText(UINT uiControlId , NMHDR *pNMHDR, LRESULT *pResult);
DECLARE_MESSAGE_MAP()
// Personal data
private:
ZDx_Interface * m_pZDxInterface;
CImageList m_stImageList;
CToolTipCtrl m_ToolTipCtrl;
HCURSOR m_hCursorDragAndDrop;
HCURSOR m_hCursorNoDragAndDrop;
HCURSOR m_hPreviousCursor;
HICON m_hIconCommon;
HICON m_hIconShared;
HICON m_hIconVirge;
HICON m_hIconMotorDisplayOn;
HICON m_hIconMotorDisplayOff;
CPA_BaseObject * m_pActor;
CPA_SuperObject * m_pActorSuperObject;
EditorPO * m_pModule;
CPA_SuperObject * m_pModuleSuperObject;
EdtList * m_pListOfZdd;
EdtList * m_pListOfZde;
EdtList * m_pListOfZdm;
EdtList * m_pListOfZdr;
ZDx_Object * m_pZdd;
ZDx_Object * m_pZde;
ZDx_Object * m_pZdm;
ZDx_Object * m_pZdr;
BOOL m_bIsCreatingList; // Is TRUE when creating a list. Becomes FALSE when the list is created
BOOL m_bIsSelectingZDx; // Is TRUE when selecting a ZDx. Becomes FALSE when the ZDx is selected
BOOL m_bIsInsideOnHasChanged;// Is TRUE when we are inside the On_Selection_Has_Changed_List_Ctrl_2 (to prevent recursiv call)
BOOL m_bMustUpdateDisplay; // When TRUE, the On_Selection_Has_Changed_List_Ctrl_2 must update the display
BOOL m_bIsSelectingPoAsZdr;// Is TRUE when the user has to select a PO to set as Zdr
BOOL m_bRightDragAndDrop; // Is TRUE during a right drap and drop.
int m_DragedItem; // The draged element
int m_SwitchedItem; // which is switch with another element
char * GetToolTipTextForList ();
void OnMouseMoveRightDragAndDrop (CPoint Point);
void MoveWindow (CWnd * , int _TranslationX , int _TranslationY); // Used to move a control into the CList2Window
void DrawLineInList (LPDRAWITEMSTRUCT);
void OnLButtonDown (UINT, CPoint);
void OnRButtonDown (UINT, CPoint);
void OnRButtonUp (UINT, CPoint);
int InsertZDxObjectInList (ZDx_Object * , tdeTreeElementType , CString NameInNameList , tdeSharedMode);
void FillComboBoxList (tdeZDxType , EdtList *); // Fill the combo box list with the list of EdtList of the given type
// ANNECY AV CLEAN_MEC {
// void FillComboBoxList (CPA_Family * , CPA_TestPointsList * _pListOfTestPointToSelect);
// Fill the combo box list with the list of test points of the given family
// END ANNECY AV }
void FillComboBoxListWithSelection ();
void CreateOneListOfZDx (EdtList * _pListOfZDx , CPA_tdoNameList * _pNameList , tdeTreeElementType);
void SwitchItems (int _Item1 , int _Item2);
EdtList * GetBigGlobalZone (tdeTreeElementType);
EdtList * GetBigGlobalZone (tdeZDxType);
long GetIndexInList (int _Item , tdeTreeElementType eElementType);
tdeZDxType ConvertElementTypeToZDxType (tdeTreeElementType);
tdeTreeElementType ConvertZDxTypeToElementType (tdeZDxType);
void DeleteZDx ();
public:
CPA_BaseObject * GetActor () { return m_pActor; }
EditorPO * GetModule () { return m_pModule; }
CPA_SuperObject * GetActorSuperObject () { return m_pActorSuperObject; }
CPA_SuperObject * GetModuleSuperObject () { return m_pModuleSuperObject; }
CPA_SuperObject * GetSelectedZDxSuperObject ();
ZDx_Object * GetSelectedZDx (); // Get the selected ZDX
ZDx_Object * GetSelectedZDx (tdeZDxType * ,
long * plPosition); // Get the selected ZDx and its type and position
ZDx_Object * GetFirstZDxOfType (tdeZDxType); // Get the first ZDx of the given type in the list
tdeZDxType GetZDxTypeOfSelection (); // Get the type of the selected ZDx
// ANNECY AV CLEAN_MEC {
// DNM_tdeKindOfPoint GetTypeOfSelectedTestPoint (); // When editing the test points, return the type of the selected test point
// CPA_TestPointsList * GetListOfTestPoint (); // When editing the test points, return the selected list of test points
// END ANNECY AV }
long GetNumberOfUnusedPosition (); // Get the number of unused position into the list
void SetZDxInterface (ZDx_Interface * _pZDxInterface) { m_pZDxInterface = _pZDxInterface; }
void CreateListOfZDx (CPA_SuperObject * _pActorSuperObject ,
EdtList * _pListOfZdd ,
EdtList * _pListOfZde ,
EdtList * _pListOfZdm ,
EdtList * _pListOfZdr ,
BOOL _bUpdateDisplayAndEditWindow = TRUE ,
BOOL _bUpdateCheckBox = TRUE);
void CreateListOfZDxOfModule (CPA_SuperObject * _pModuleSuperObject ,
BOOL _bUpdateDisplayAndEditWindow = TRUE);
void CreateBoundingVolume (CPA_SuperObject * _pActorSuperObject , ZDx_Object * _pBoundingVolume ,
BOOL _bUdateEditWindow = TRUE, BOOL _bShowBdV = TRUE);
// ANNECY AV CLEAN_MEC {
/*
void CreateListOfTestPoint (CPA_SuperObject * _pActorSuperObject , CPA_TestPointsList * _pTestPointList = NULL ,
BOOL _bUpdateEditWindow = TRUE);
void LeaveEditionOfTestPoint ();
*/
// END ANNECY AV }
void ReCreateListOfZDx (BOOL _bUpdateDisplayAndEditWindow = TRUE ,
BOOL _bUpdateCheckBox = TRUE);
void CreateASpecificListOfZDx (CPA_SuperObject * _pActorSuperObject ,
EdtList * _pListOfZDx ,
tdeZDxType _eZDxType);
BOOL SelectZDx (ZDx_Object * _pZDxObjectToSelect ,
BOOL _bSelectEvenIfNull = FALSE ,
BOOL _bUpdateEditWindow = TRUE); // Select a ZDx in the list
BOOL SelectZDx (tdeZDxType _eZDxType , long _lPosition); // Select the ZDx which have the given
// type and the given position in the list
unsigned char GetZDxTypeToShow (); // Return the type of ZDx to show
void SetZDxCheckBoxes (tdeZDxType);
void SetZDxCheckBoxes (BOOL _bShowZDD , BOOL _bShowZDE , BOOL _bShowZDM , BOOL _bShowZDR);
};
#endif // __ZWLIST2_HPP

View File

@@ -0,0 +1,52 @@
#if !defined(AFX_CHECKZONES_H__18ADE2F1_05B7_11D2_B408_00A0244F34C3__INCLUDED_)
#define AFX_CHECKZONES_H__18ADE2F1_05B7_11D2_B408_00A0244F34C3__INCLUDED_
#if _MSC_VER >= 1000
#pragma once
#endif // _MSC_VER >= 1000
// checkzones.h : header file
//
/////////////////////////////////////////////////////////////////////////////
// CCheckZones dialog
class CPA_Actor;
class CCheckZones : public CDialog
{
// Construction
public:
CCheckZones(CPA_Actor *pActor, CStringList *pZonesList, CWnd* pParent = NULL); // standard constructor
// Dialog Data
//{{AFX_DATA(CCheckZones)
enum { IDD = IDD_CHECK_ZONES_AGAINST_BV };
CListBox m_ctrlZonesList;
CButton m_ctrlYes;
CButton m_ctrlCheckZonesAgainstBV;
//}}AFX_DATA
// Overrides
// ClassWizard generated virtual function overrides
//{{AFX_VIRTUAL(CCheckZones)
protected:
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
//}}AFX_VIRTUAL
// Implementation
protected:
CPA_Actor *m_pActor;
CStringList *m_pZonesList;
// Generated message map functions
//{{AFX_MSG(CCheckZones)
virtual void OnOK();
virtual BOOL OnInitDialog();
//}}AFX_MSG
DECLARE_MESSAGE_MAP()
};
//{{AFX_INSERT_LOCATION}}
// Microsoft Developer Studio will insert additional declarations immediately before the previous line.
#endif // !defined(AFX_CHECKZONES_H__18ADE2F1_05B7_11D2_B408_00A0244F34C3__INCLUDED_)