CMakeSetupDialog.h 3.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110
  1. // CMakeSetupDialogDlg.h : header file
  2. //
  3. #if !defined(AFX_CMakeSetupDialogDLG_H__AC17A6F6_4634_11D4_8F21_00A0CC33FCD3__INCLUDED_)
  4. #define AFX_CMakeSetupDialogDLG_H__AC17A6F6_4634_11D4_8F21_00A0CC33FCD3__INCLUDED_
  5. #if _MSC_VER > 1000
  6. #pragma once
  7. #endif // _MSC_VER > 1000
  8. #include "PropertyList.h"
  9. /////////////////////////////////////////////////////////////////////////////
  10. // CMakeSetupDialog dialog
  11. class CMakeCommandLineInfo;
  12. class CMakeSetupDialog : public CDialog
  13. {
  14. // Construction
  15. public:
  16. CMakeSetupDialog(const CMakeCommandLineInfo& cmdInfo,
  17. CWnd* pParent = NULL);
  18. protected:
  19. //! Load cache file from m_WhereBuild and display in GUI editor
  20. void LoadCacheFromDiskToGUI();
  21. //! Save GUI values to cmCacheManager and then save to disk.
  22. void SaveCacheFromGUI();
  23. void SaveToRegistry();
  24. void LoadFromRegistry();
  25. bool Browse(CString&, const char* title);
  26. void ReadRegistryValue(HKEY hKey,
  27. CString *val,
  28. const char *key,
  29. const char *aadefault);
  30. void ShowAdvancedValues();
  31. void RemoveAdvancedValues();
  32. // Dialog Data
  33. //{{AFX_DATA(CMakeSetupDialog)
  34. enum { IDD = IDD_CMakeSetupDialog_DIALOG };
  35. CButton m_HelpButton;
  36. CComboBox m_GeneratorChoice;
  37. CButton m_OKButton;
  38. CButton m_CancelButton;
  39. CString m_WhereSource;
  40. CString m_WhereBuild;
  41. CButton m_ListFrame;
  42. bool m_BuildPathChanged;
  43. CComboBox m_WhereSourceControl;
  44. CComboBox m_WhereBuildControl;
  45. CPropertyList m_CacheEntriesList;
  46. CStatic m_MouseHelp;
  47. CStatic m_VersionDisplay;
  48. CButton m_Configure;
  49. CString m_GeneratorChoiceString;
  50. BOOL m_AdvancedValues;
  51. //}}AFX_DATA
  52. // ClassWizard generated virtual function overrides
  53. //{{AFX_VIRTUAL(CMakeSetupDialog)
  54. protected:
  55. virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
  56. //}}AFX_VIRTUAL
  57. // Implementation
  58. protected:
  59. void RunCMake(bool generateProjectFiles);
  60. // copy from the cache manager to the cache edit list box
  61. void FillCacheGUIFromCacheManager();
  62. // copy from the list box to the cache manager
  63. void FillCacheManagerFromCacheGUI();
  64. // Create a shortcut on the desktop with the current Source/Build dir.
  65. int CreateShortcut();
  66. HICON m_hIcon;
  67. CString m_RegistryKey;
  68. CString m_PathToExecutable;
  69. // Generated message map functions
  70. //{{AFX_MSG(CMakeSetupDialog)
  71. virtual BOOL OnInitDialog();
  72. afx_msg void OnSysCommand(UINT nID, LPARAM lParam);
  73. afx_msg void OnCancel();
  74. afx_msg void OnPaint();
  75. afx_msg HCURSOR OnQueryDragIcon();
  76. afx_msg void OnBrowseWhereSource();
  77. virtual void OnConfigure();
  78. afx_msg void OnBrowseWhereBuild();
  79. afx_msg void OnChangeWhereBuild();
  80. afx_msg void OnSelendokWhereBuild();
  81. afx_msg void OnChangeWhereSource();
  82. afx_msg void OnSelendokWhereSource();
  83. afx_msg void OnSize(UINT nType, int cx, int cy);
  84. afx_msg void OnGetMinMaxInfo( MINMAXINFO FAR* lpMMI );
  85. afx_msg void OnOk();
  86. afx_msg void OnEditchangeGenerator();
  87. afx_msg void OnHelpButton();
  88. afx_msg void OnAdvancedValues();
  89. afx_msg void OnDoubleclickedAdvancedValues();
  90. //}}AFX_MSG
  91. DECLARE_MESSAGE_MAP()
  92. int m_oldCX;
  93. int m_oldCY;
  94. float m_deltaXRemainder;
  95. };
  96. //{{AFX_INSERT_LOCATION}}
  97. // Microsoft Visual C++ will insert additional declarations immediately before the previous line.
  98. #endif // !defined(AFX_CMakeSetupDialogDLG_H__AC17A6F6_4634_11D4_8F21_00A0CC33FCD3__INCLUDED_)