summaryrefslogtreecommitdiff
path: root/hammer/filtercontrol.h
blob: a3106e6d19e7ec616a37ebad917e32611cb967cb (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
//========= Copyright Valve Corporation, All rights reserved. ============//
//
// Purpose: 
//
//=============================================================================//

#ifndef FILTERCONTROL_H
#define FILTERCONTROL_H
#pragma once


#include "resource.h"
#include "GroupList.h"
#include "HammerBar.h"


class CFilterControl : public CHammerBar
{
public:
	CFilterControl() : CHammerBar() { bInitialized = FALSE; }
	BOOL Create(CWnd *pParentWnd);

	void UpdateGroupList(void);
	void UpdateGroupListChecks(void);

	virtual void OnUpdateCmdUI(CFrameWnd* pTarget, BOOL bDisableIfNoHndler);
	virtual CSize CalcDynamicLayout(int nLength, DWORD dwMode);

private:
	//{{AFX_DATA(CFilterControl)
	enum { IDD = IDD_MAPVIEWBAR };
	//}}AFX_DATA

	CBitmapButton m_cMoveUpButton;
	CBitmapButton m_cMoveDownButton;
	CGroupList m_cGroupBox;
	CTabCtrl m_cTabControl;

	BOOL bInitialized;
	BOOL m_bShowingAuto;

protected:

	virtual BOOL OnNotify(WPARAM wParam, LPARAM lParam, LRESULT *pResult);
	virtual BOOL OnInitDialog(void);
	void OnSelChangeTab(NMHDR *header, LRESULT *result); 

	//{{AFX_MSG(CFilterControl)
	afx_msg void OnSize(UINT nType, int cx, int cy);
	afx_msg void OnEditGroups();
	afx_msg void OnMarkMembers();
	afx_msg BOOL OnMoveUpDown(UINT uCmd);
	afx_msg void UpdateControl(CCmdUI *);
	afx_msg void UpdateControlGroups(CCmdUI *pCmdUI);
	afx_msg void OnActivate(UINT nState, CWnd*, BOOL);
	afx_msg void OnShowWindow(BOOL bShow, UINT nStatus);
	afx_msg void OnWindowPosChanged(WINDOWPOS *pPos);
	afx_msg void OnEndlabeleditGrouplist(NMHDR*, LRESULT*);
	afx_msg void OnBegindragGrouplist(NMHDR*, LRESULT*);
	afx_msg void OnMousemoveGrouplist(NMHDR*, LRESULT*);
	afx_msg void OnEnddragGrouplist(NMHDR*, LRESULT*);
	afx_msg LRESULT OnListToggleState(WPARAM wParam, LPARAM lParam);
	afx_msg LRESULT OnListLeftDragDrop(WPARAM wParam, LPARAM lParam);
	afx_msg LRESULT OnListRightDragDrop(WPARAM wParam, LPARAM lParam);
	afx_msg void OnShowAllGroups(void);
	//}}AFX_MSG

	CImageList *m_pDragImageList;

	DECLARE_MESSAGE_MAP()
};


#endif // FILTERCONTROL_H