Use configured resolution for login/outgame/ingame
[ryzomcore.git] / ryzom / tools / leveldesign / georges_dll / dfn_dialog.h
blob81c04efb4ab165f6c7b490d88ea66ef2a2b1ddc7
1 // Ryzom - MMORPG Framework <http://dev.ryzom.com/projects/ryzom/>
2 // Copyright (C) 2010 Winch Gate Property Limited
3 //
4 // This source file has been modified by the following contributors:
5 // Copyright (C) 2019 Jan BOON (Kaetemi) <jan.boon@kaetemi.be>
6 //
7 // This program is free software: you can redistribute it and/or modify
8 // it under the terms of the GNU Affero General Public License as
9 // published by the Free Software Foundation, either version 3 of the
10 // License, or (at your option) any later version.
12 // This program is distributed in the hope that it will be useful,
13 // but WITHOUT ANY WARRANTY; without even the implied warranty of
14 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 // GNU Affero General Public License for more details.
17 // You should have received a copy of the GNU Affero General Public License
18 // along with this program. If not, see <http://www.gnu.org/licenses/>.
20 #if !defined(DFN_TYPE_H_INCLUDED)
21 #define DFN_TYPE_H_INCLUDED
23 #include "base_dialog.h"
24 #include "edit_list_ctrl.h"
26 #if _MSC_VER > 1000
27 #pragma once
28 #endif // _MSC_VER > 1000
29 // dfn_dialog.h : header file
32 class CGeorgesEditView;
34 /////////////////////////////////////////////////////////////////////////////
35 // CDfnDialog dialog
37 class CDfnParentEditListCtrl : public CEditListCtrl
39 CEditListCtrl::TItemEdit getItemEditMode (uint item, uint subItem);
40 void getMemComboBoxProp (uint item, uint subItem, std::string &regAdr, bool &browse);
41 void getNewItemText (uint item, uint subItem, std::string &ret);
42 void getBrowseInfo (uint item, uint subItem, std::string &defExt, std::string &defFilename, std::string &defDir, NLMISC::tstring &filter);
43 public:
44 class CDfnDialog *Dialog;
47 class CDfnEditListCtrl : public CEditListCtrl
49 CEditListCtrl::TItemEdit getItemEditMode (uint item, uint subItem);
50 void getComboBoxStrings (uint item, uint subItem, std::vector<std::string> &retStrings);
51 void getMemComboBoxProp (uint item, uint subItem, std::string &regAdr, bool &browse);
52 void getNewItemText (uint item, uint subItem, std::string &ret);
53 void getBrowseInfo (uint item, uint subItem, std::string &defExt, std::string &defFilename, std::string &defDir, NLMISC::tstring &filter);
54 void onItemChanged (uint item, uint subItem);
55 public:
56 class CDfnDialog *Dialog;
59 /**
60 * The dialog class for a DFN edition right window.
62 class CDfnDialog : public CBaseDialog
64 // Construction
65 public:
66 CDfnDialog (); // standard constructor
68 enum
70 TypeCombo= 100,
73 enum
75 LtParents,
76 LtStruct,
79 enum
81 ParentHeight = 80,
82 DfnHeight = 80,
85 // The widgets
86 CStatic LabelParents;
87 CDfnParentEditListCtrl Parents;
88 CStatic LabelStruct;
89 CDfnEditListCtrl Struct;
91 // From CDialog
92 virtual void OnOK ();
93 virtual void OnCancel ();
95 // From CBaseDialog
96 void onOpenSelected ();
97 void onFirstFocus ();
98 void onLastFocus ();
100 // Get from document, update rightview UI
101 void getFromDocument (const NLGEORGES::CFormDfn &type);
103 // Set to document, update document with rightview UI
104 void setParentsToDocument ();
105 void setStructToDocument ();
107 // Resize widget callback
108 void resizeWidgets ();
110 CWnd* GetNextDlgTabItem( CWnd* pWndCtl, BOOL bPrevious = FALSE ) const;
112 // Overrides
113 // ClassWizard generated virtual function overrides
114 //{{AFX_VIRTUAL(CDfnDialog)
115 protected:
116 virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
117 virtual LRESULT WindowProc(UINT message, WPARAM wParam, LPARAM lParam);
118 //}}AFX_VIRTUAL
120 // Implementation
121 protected:
123 // Generated message map functions
124 //{{AFX_MSG(CDfnDialog)
125 afx_msg void OnSize(UINT nType, int cx, int cy);
126 afx_msg BOOL OnInitDialog();
127 afx_msg void OnSetFocus(CWnd* pOldWnd);
128 //}}AFX_MSG
129 DECLARE_MESSAGE_MAP()
132 //{{AFX_INSERT_LOCATION}}
133 // Microsoft Visual C++ will insert additional declarations immediately before the previous line.
135 #endif // !defined(DFN_TYPE_H_INCLUDED)