project64/Source/Project64/UserInterface/SettingsConfig.h

49 lines
1.6 KiB
C
Raw Normal View History

2016-01-27 09:11:59 +00:00
#pragma once
#include <commctrl.h>
class CConfigSettingSection;
class CSettingsPage;
class CSettingConfig :
public CDialogImpl < CSettingConfig >
{
public:
BEGIN_MSG_MAP_EX(CSettingConfig)
MESSAGE_HANDLER(WM_INITDIALOG, OnInitDialog)
COMMAND_CODE_HANDLER(BN_CLICKED, OnClicked)
NOTIFY_HANDLER_EX(IDC_PAGELIST, TVN_SELCHANGED, OnPageListItemChanged)
NOTIFY_HANDLER_EX(IDC_PAGELIST, NM_CLICK, OnPageListClicked)
2016-01-27 09:11:59 +00:00
MESSAGE_HANDLER_EX(PSM_CHANGED, OnSettingPageChanged)
REFLECT_NOTIFICATIONS()
END_MSG_MAP()
2016-01-27 09:11:59 +00:00
enum { IDD = IDD_Settings_Config };
2016-01-27 09:11:59 +00:00
LRESULT OnInitDialog(UINT /*uMsg*/, WPARAM /*wParam*/, LPARAM /*lParam*/, BOOL& /*bHandled*/);
LRESULT OnClicked(WORD wNotifyCode, WORD wID, HWND /*hWndCtl*/, BOOL& bHandled);
LRESULT OnPageListItemChanged(NMHDR* phdr);
LRESULT OnPageListClicked(NMHDR* phdr);
LRESULT OnSettingPageChanged(UINT /*uMsg*/, WPARAM wPage, LPARAM /*lParam*/);
2016-01-27 09:11:59 +00:00
public:
CSettingConfig(bool bJustGameSetting = false);
~CSettingConfig(void);
void Display(void * ParentWindow);
void UpdateAdvanced(bool AdvancedMode);
private:
void UpdateAdvanced(bool AdvancedMode, HTREEITEM hItem);
2016-01-27 09:11:59 +00:00
void ApplySettings(bool UpdateScreen);
void BoldChangedPages(HTREEITEM hItem);
typedef std::list<CConfigSettingSection *> SETTING_SECTIONS;
CTreeViewCtrl m_PagesTreeList;
SETTING_SECTIONS m_Sections;
CSettingsPage * m_CurrentPage, *m_GeneralOptionsPage, *m_AdvancedPage, *m_DefaultsPage, *m_DiskDrivePage;
2016-01-27 09:11:59 +00:00
bool m_GameConfig;
bool m_bTVNSelChangedSupported;
2016-01-27 09:11:59 +00:00
};