Linux multi-monitor fullscreen support
[ryzomcore.git] / nel / tools / 3d / object_viewer / edit_spinner.h
blobc146227bcee40e3ff8e1f7ecab420d0d383c4b5e
1 // NeL - MMORPG Framework <http://dev.ryzom.com/projects/nel/>
2 // Copyright (C) 2010 Winch Gate Property Limited
3 //
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.
8 //
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_EDIT_SPINNER_H__CFDBE30D_F8C9_432E_9F17_0AFACE143BB0__INCLUDED_)
19 #define AFX_EDIT_SPINNER_H__CFDBE30D_F8C9_432E_9F17_0AFACE143BB0__INCLUDED_
21 #if _MSC_VER > 1000
22 #pragma once
23 #endif
25 struct IPopupNotify;
27 #include "ps_wrapper.h"
28 #include "nel/3d/ps_plane_basis_maker.h"
29 #include "editable_range.h"
30 #include "particle_workspace.h"
32 class CDirectionAttr;
34 class CEditSpinner : public CDialog
36 // Construction
37 public:
38 CEditSpinner(NL3D::CPSBasisSpinner *sf, CParticleWorkspace::CNode *ownerNode, CWnd *pParent, IPopupNotify *pn);
40 // dtor
41 ~CEditSpinner();
43 /// init this dialog
44 void init(CWnd *pParent);
46 // Dialog Data
47 //{{AFX_DATA(CEditSpinner)
48 enum { IDD = IDD_EDITSPINNER };
49 // NOTE: the ClassWizard will add data members here
50 //}}AFX_DATA
53 // Overrides
54 // ClassWizard generated virtual function overrides
55 //{{AFX_VIRTUAL(CEditSpinner)
56 protected:
57 virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
58 //}}AFX_VIRTUAL
60 // Implementation
61 protected:
62 NL3D::CPSBasisSpinner *_Spinner; // the spinner being edited
63 CDirectionAttr *_DirDlg;
64 CEditableRangeUInt *_NbSamplesDlg;
65 IPopupNotify *_PN;
66 CParticleWorkspace::CNode *_Node;
68 // Generated message map functions
69 //{{AFX_MSG(CEditSpinner)
70 virtual BOOL OnInitDialog();
71 afx_msg void OnClose();
72 //}}AFX_MSG
74 // wrapper to set the number of samples in the spinner
75 struct CNbSampleWrapper : public IPSWrapperUInt
77 NL3D::CPSBasisSpinner *S;
78 uint32 get(void) const { return S->_F.getNumSamples(); }
79 void set(const uint32 &val) { S->_F.setNumSamples(val); }
80 } _NbSampleWrapper;
83 // wrapper to set the axis of the spinner
84 struct CAxisWrapper : public IPSWrapper<NLMISC::CVector>
86 NL3D::CPSBasisSpinner *S;
87 NLMISC::CVector get(void) const { return S->_F.getAxis(); }
88 void set(const NLMISC::CVector &axis) { S->_F.setAxis(axis); }
89 } _AxisWrapper;
92 DECLARE_MESSAGE_MAP()
95 //{{AFX_INSERT_LOCATION}}
96 // Microsoft Visual C++ will insert additional declarations immediately before the previous line.
98 #endif // !defined(AFX_EDIT_SPINNER_H__CFDBE30D_F8C9_432E_9F17_0AFACE143BB0__INCLUDED_)