Files
SimpleRemoter/server/2015Remote/SystemDlg.h
yuanyuanxiang 9d2e9ec8ca Feature: Remember process/window list sort preference
Persist the sort column and direction chosen via the list header so the
next time the process or window management dialog opens it defaults to
the same sort. Process and window lists are remembered separately
(list\ProcessListSort and list\WindowListSort registry keys) since their
columns have different meanings.

Co-Authored-By: deepseek-v4-pro
2026-08-13 12:59:29 +02:00

59 lines
1.8 KiB
C++
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
#pragma once
#include "afxcmn.h"
#include "IOCPServer.h"
// CSystemDlg 对话框
class CSystemDlg : public DialogBase
{
DECLARE_DYNAMIC(CSystemDlg)
public:
CSystemDlg(CWnd* pParent = NULL, Server* IOCPServer = NULL, CONTEXT_OBJECT *ContextObject = NULL);
virtual ~CSystemDlg();
VOID GetProcessList(void);
VOID ShowProcessList(void);
void ShowWindowsList(void);
void GetWindowsList(void);
void OnReceiveComplete(void);
CWnd* m_pParent;
BOOL m_bHow;
int m_nSortColumn = -1; // 当前排序列,-1 表示未排序
bool m_bSortAscending = true; // 排序方向true=升序)
// 对话框数据
enum { IDD = IDD_DIALOG_SYSTEM };
protected:
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV 支持
DECLARE_MESSAGE_MAP()
public:
CListCtrl m_ControlList;
virtual BOOL OnInitDialog();
void DeleteAllItems();
void SortByColumn(int nColumn);
void ApplySort();
void LoadSortPreference();
void SaveSortPreference();
afx_msg VOID OnHdnItemclickList(NMHDR* pNMHDR, LRESULT* pResult);
static int CALLBACK CompareFunction(LPARAM lParam1, LPARAM lParam2, LPARAM lParamSort);
afx_msg void OnClose();
afx_msg void OnNMRClickListSystem(NMHDR *pNMHDR, LRESULT *pResult);
afx_msg void OnPlistKill();
afx_msg void OnPlistRefresh();
afx_msg void OnWlistRefresh();
afx_msg void OnWlistClose();
afx_msg void OnWlistHide();
afx_msg void OnWlistRecover();
afx_msg void OnWlistMax();
afx_msg void OnWlistMin();
afx_msg void OnSize(UINT nType, int cx, int cy);
afx_msg void OnPlistInject();
afx_msg void OnPlistAntiBlackScreen();
afx_msg void OnWlistView();
afx_msg void OnNMDblclkListSystem(NMHDR* pNMHDR, LRESULT* pResult);
};