Skip to content

Commit 725abbe

Browse files
committed
控件位置调整
1 parent f0cdbe7 commit 725abbe

File tree

8 files changed

+30
-1
lines changed

8 files changed

+30
-1
lines changed

TrafficMonitor/CAutoAdaptSettingsDlg.cpp

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,11 @@ void CAutoAdaptSettingsDlg::DoDataExchange(CDataExchange* pDX)
4747
DDX_Control(pDX, IDC_LIGHT_MODE_DEFAULT_STYLE_COMBO, m_light_mode_default_style_combo);
4848
}
4949

50+
CString CAutoAdaptSettingsDlg::GetDialogName() const
51+
{
52+
return _T("AutoAdaptSettingsDlg");
53+
}
54+
5055
bool CAutoAdaptSettingsDlg::InitializeControls()
5156
{
5257
RepositionTextBasedControls({

TrafficMonitor/CAutoAdaptSettingsDlg.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ class CAutoAdaptSettingsDlg : public CBaseDialog
2828

2929
protected:
3030
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV 支持
31+
virtual CString GetDialogName() const override;
3132
virtual bool InitializeControls() override;
3233

3334
DECLARE_MESSAGE_MAP()

TrafficMonitor/MainWndSettingsDlg.cpp

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,13 @@ void CMainWndSettingsDlg::SetControlMouseWheelEnable(bool enable)
3333

3434
bool CMainWndSettingsDlg::InitializeControls()
3535
{
36+
RepositionTextBasedControls({
37+
{ CtrlTextInfo::L4, IDC_FONT_STATIC },
38+
{ CtrlTextInfo::C0, IDC_FONT_NAME_EDIT },
39+
{ CtrlTextInfo::R1, IDC_FONT_SIZE_STATIC },
40+
{ CtrlTextInfo::R2, IDC_FONT_SIZE_EDIT },
41+
{ CtrlTextInfo::R3, IDC_SET_FONT_BUTTON, CtrlTextInfo::W16 }
42+
});
3643
RepositionTextBasedControls({
3744
{ CtrlTextInfo::L4, IDC_TXT_COLOR_LABEL_STATIC },
3845
{ CtrlTextInfo::L3, IDC_TEXT_COLOR_STATIC },

TrafficMonitor/SkinAutoAdaptSettingDlg.cpp

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,11 @@ void CSkinAutoAdaptSettingDlg::DoDataExchange(CDataExchange* pDX)
3737
DDX_Control(pDX, IDC_LIGHT_MODE_SKIN_COMBO, m_light_mode_skin_combo);
3838
}
3939

40+
CString CSkinAutoAdaptSettingDlg::GetDialogName() const
41+
{
42+
return _T("SkinAutoAdaptSettingDlg");
43+
}
44+
4045
bool CSkinAutoAdaptSettingDlg::InitializeControls()
4146
{
4247
RepositionTextBasedControls({

TrafficMonitor/SkinAutoAdaptSettingDlg.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ class CSkinAutoAdaptSettingDlg : public CBaseDialog
3333

3434
protected:
3535
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV 支持
36+
virtual CString GetDialogName() const override;
3637
virtual bool InitializeControls() override;
3738

3839
DECLARE_MESSAGE_MAP()

TrafficMonitor/TaskBarSettingsDlg.cpp

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -135,10 +135,18 @@ void CTaskBarSettingsDlg::SetControlMouseWheelEnable(bool enable)
135135

136136
bool CTaskBarSettingsDlg::InitializeControls()
137137
{
138+
RepositionTextBasedControls({
139+
{ CtrlTextInfo::L1, IDC_FONT_STATIC },
140+
{ CtrlTextInfo::C0, IDC_FONT_NAME_EDIT1 },
141+
{ CtrlTextInfo::R1, IDC_FONT_SIZE_STATIC },
142+
{ CtrlTextInfo::R2, IDC_FONT_SIZE_EDIT1 },
143+
{ CtrlTextInfo::R3, IDC_SET_FONT_BUTTON1, CtrlTextInfo::W16 }
144+
});
138145
RepositionTextBasedControls({
139146
{ CtrlTextInfo::L2, IDC_TXT_COLOR_STATIC },
140147
{ CtrlTextInfo::L1, IDC_TEXT_COLOR_STATIC1 },
141148
{ CtrlTextInfo::C0, IDC_SPECIFY_EACH_ITEM_COLOR_CHECK, CtrlTextInfo::W16 },
149+
{ CtrlTextInfo::R1, IDC_DEFAULT_STYLE_BUTTON, CtrlTextInfo::W16 },
142150
{ CtrlTextInfo::L2, IDC_BACK_COLOR_STATIC },
143151
{ CtrlTextInfo::L1, IDC_TEXT_COLOR_STATIC2 },
144152
{ CtrlTextInfo::C0, IDC_BACKGROUND_TRANSPARENT_CHECK, CtrlTextInfo::W16 }

TrafficMonitor/TrafficMonitor.rc

60 Bytes
Binary file not shown.

TrafficMonitor/resource.h

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -335,6 +335,8 @@
335335
#define IDC_GRAPH_DISPLAY_MODE_STATIC 1201
336336
#define IDC_DARK_MODE_STATIC 1202
337337
#define IDC_LIGHT_MODE_STATIC 1203
338+
#define IDC_FONT_STATIC 1204
339+
#define IDC_FONT_SIZE_STATIC 1205
338340
#define ID_32771 32771
339341
#define ID_NETWORK_INFO 32772
340342
#define ID_32773 32773
@@ -456,7 +458,7 @@
456458
#ifndef APSTUDIO_READONLY_SYMBOLS
457459
#define _APS_NEXT_RESOURCE_VALUE 348
458460
#define _APS_NEXT_COMMAND_VALUE 33665
459-
#define _APS_NEXT_CONTROL_VALUE 1204
461+
#define _APS_NEXT_CONTROL_VALUE 1206
460462
#define _APS_NEXT_SYMED_VALUE 101
461463
#endif
462464
#endif

0 commit comments

Comments
 (0)