1 // NeL - MMORPG Framework <http://dev.ryzom.com/projects/nel/>
2 // Copyright (C) 2010 Winch Gate Property Limited
4 // This program is free software: you can redistribute it and/or modify
5 // it under the terms of the GNU Affero General Public License as
6 // published by the Free Software Foundation, either version 3 of the
7 // License, or (at your option) any later version.
9 // This program is distributed in the hope that it will be useful,
10 // but WITHOUT ANY WARRANTY; without even the implied warranty of
11 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 // GNU Affero General Public License for more details.
14 // You should have received a copy of the GNU Affero General Public License
15 // along with this program. If not, see <http://www.gnu.org/licenses/>.
18 #if !defined(AFX_VALUEBLENDERDLG_H__4242C860_C538_45BD_8348_C6DF314D688A__INCLUDED_)
19 #define AFX_VALUEBLENDERDLG_H__4242C860_C538_45BD_8348_C6DF314D688A__INCLUDED_
26 #include "particle_workspace.h"
29 class CEditAttribDlg
;
32 // user of the dialog must provide an implementation of this struct to provide indivual values edition
33 struct IValueBlenderDlgClient
35 /** Create a dialog to edit a single value.
36 * \param index must be 0 or 1, it says which value is being edited
38 virtual CEditAttribDlg
*createDialog(uint index
, CParticleWorkspace::CNode
*ownerNode
) = 0;
41 virtual ~IValueBlenderDlgClient() {}
44 class CValueBlenderDlg
: public CDialog
48 /** Create the dialog.
49 * \param createInterface interface that allows to create a dialog to edit one of the 2 values used for the blend.
50 * \param destroyInterface true if this object must take care to call 'delete' on the 'createInterface' pointer
52 CValueBlenderDlg(IValueBlenderDlgClient
*createInterface
,
53 bool destroyInterface
,
56 CParticleWorkspace::CNode
*ownerNode
57 ); // standard constructor
61 void init(CWnd
*pParent
);
64 //{{AFX_DATA(CValueBlenderDlg)
65 enum { IDD
= IDD_VALUE_BLENDER
};
72 // ClassWizard generated virtual function overrides
73 //{{AFX_VIRTUAL(CValueBlenderDlg)
75 virtual void DoDataExchange(CDataExchange
* pDX
); // DDX/DDV support
80 void childPopupDestroyed(CWnd
*child
);
81 IValueBlenderDlgClient
*_CreateInterface
;
82 // the 2 dialog used to choose the blending value
83 CEditAttribDlg
*_Dlg1
, *_Dlg2
;
85 bool _DestroyInterface
;
86 CParticleWorkspace::CNode
*_Node
;
87 // Generated message map functions
88 //{{AFX_MSG(CValueBlenderDlg)
89 virtual BOOL
OnInitDialog();
90 afx_msg
void OnClose();
96 //{{AFX_INSERT_LOCATION}}
97 // Microsoft Visual C++ will insert additional declarations immediately before the previous line.
99 #endif // !defined(AFX_VALUEBLENDERDLG_H__4242C860_C538_45BD_8348_C6DF314D688A__INCLUDED_)