summaryrefslogtreecommitdiff
path: root/plugins/TabSRMM/src/msgs.h
diff options
context:
space:
mode:
authorGeorge Hazan <ghazan@miranda.im>2020-04-28 20:42:01 +0300
committerGeorge Hazan <ghazan@miranda.im>2020-04-28 20:42:01 +0300
commit01b474dd8a9e43945a996a2b1a7c4b4322358b32 (patch)
treed6613e67b3981aa99a6f573d38aa9adcf725e9be /plugins/TabSRMM/src/msgs.h
parenta3bba4bd09b0df2f4331cf7a8c333b7b4a86a195 (diff)
tabSRMM: code cleaning
Diffstat (limited to 'plugins/TabSRMM/src/msgs.h')
-rw-r--r--plugins/TabSRMM/src/msgs.h59
1 files changed, 13 insertions, 46 deletions
diff --git a/plugins/TabSRMM/src/msgs.h b/plugins/TabSRMM/src/msgs.h
index 31da231d74..8be03332b3 100644
--- a/plugins/TabSRMM/src/msgs.h
+++ b/plugins/TabSRMM/src/msgs.h
@@ -72,21 +72,25 @@
#define MSGDLGFONTCOUNT 22
#define CHATFONTCOUNT 19
-#define TMPL_MSGIN 0
-#define TMPL_MSGOUT 1
-#define TMPL_GRPSTARTIN 2
-#define TMPL_GRPSTARTOUT 3
-#define TMPL_GRPINNERIN 4
-#define TMPL_GRPINNEROUT 5
-#define TMPL_STATUSCHG 6
-#define TMPL_ERRMSG 7
+enum
+{
+ TMPL_MSGIN = 0,
+ TMPL_MSGOUT,
+ TMPL_GRPSTARTIN,
+ TMPL_GRPSTARTOUT,
+ TMPL_GRPINNERIN,
+ TMPL_GRPINNEROUT,
+ TMPL_STATUSCHG,
+ TMPL_ERRMSG,
+ TMPL_MAX
+};
#define TEMPLATE_LENGTH 150
#define CUSTOM_COLORS 5
struct TTemplateSet {
BOOL valid; // all templates populated (may still contain crap.. so it's only half-assed safety :)
- wchar_t szTemplates[TMPL_ERRMSG + 1][TEMPLATE_LENGTH]; // the template strings
+ wchar_t szTemplates[TMPL_MAX][TEMPLATE_LENGTH]; // the template strings
char szSetName[20]; // everything in this world needs a name. so does this poor template set.
};
@@ -620,43 +624,6 @@ public:
void UpdateToolbarBG(void);
};
-class CTemplateEditDlg : public CMsgDialog
-{
- typedef CMsgDialog CSuper;
-
- BOOL rtl;
- BOOL changed; // template in edit field is changed
- BOOL selchanging;
- int inEdit; // template currently in editor
- BOOL updateInfo[TMPL_ERRMSG + 1]; // item states...
-
- TTemplateSet *tSet;
-
- CCtrlEdit edtText;
- CCtrlButton btnResetAll, btnSave, btnForget, btnRevert, btnPreview;
- CCtrlListBox listTemplates;
- CCtrlHyperlink urlHelp;
-
-public:
- CTemplateEditDlg(BOOL rtl, HWND hwndParent);
-
- bool OnInitDialog() override;
- void OnDestroy() override;
-
- INT_PTR DlgProc(UINT uMsg, WPARAM wParam, LPARAM lParam) override;
-
- void onChange_Text(CCtrlEdit*);
-
- void onClick_Forget(CCtrlButton*);
- void onClick_Preview(CCtrlButton*);
- void onClick_Reset(CCtrlButton*);
- void onClick_Revert(CCtrlButton*);
- void onClick_Save(CCtrlButton*);
-
- void onDblClick_List(CCtrlListBox*);
- void onSelChange_List(CCtrlListBox*);
-};
-
extern LIST<void> g_arUnreadWindows;
#define MESSAGE_WINDOW_DATA_SIZE offsetof(_MessageWindowData, hdbEventFirst);