summaryrefslogtreecommitdiff
path: root/plugins/Scriver/src/msgs.h
diff options
context:
space:
mode:
authorGeorge Hazan <ghazan@miranda.im>2017-03-05 20:20:14 +0300
committerGeorge Hazan <ghazan@miranda.im>2017-03-05 20:20:14 +0300
commit7e71db53bdd51a213e9262723d52957a0961793d (patch)
treee23f78dd8739580c739c45d6e1990f90e5d8c040 /plugins/Scriver/src/msgs.h
parent3c78e3b9659ea8903d46cdcc0d95288e65f50e0b (diff)
Scriver -> core splitters
also: - structure of Scriver SRMM classes redesigned to avoid problems with MS compilers; - unused cursors removed; - now splitter position is being saved & restored;
Diffstat (limited to 'plugins/Scriver/src/msgs.h')
-rw-r--r--plugins/Scriver/src/msgs.h43
1 files changed, 38 insertions, 5 deletions
diff --git a/plugins/Scriver/src/msgs.h b/plugins/Scriver/src/msgs.h
index a9a0e996dd..276959c0e8 100644
--- a/plugins/Scriver/src/msgs.h
+++ b/plugins/Scriver/src/msgs.h
@@ -75,6 +75,8 @@ struct ParentWindowData
int bMinimized;
int bVMaximized;
int bTopmost;
+ int iSplitterX, iSplitterY;
+
int windowWasCascaded;
TabCtrlData *tabCtrlDat;
BOOL isChat;
@@ -92,24 +94,29 @@ struct MessageWindowTabData
#define NMWLP_INCOMING 1
-struct CommonWindowData
+class CScriverWindow : public CSrmmBaseDialog
{
+protected:
+ CScriverWindow(int iDialog) :
+ CSrmmBaseDialog(g_hInst, iDialog)
+ {}
+
+public:
ParentWindowData *m_pParent;
int m_minLogBoxHeight, m_minEditBoxHeight;
HWND m_hwndIeview;
TCmdList *cmdList, *cmdListCurrent;
};
-class CSrmmWindow : public CSrmmBaseDialog, public CommonWindowData
+class CSrmmWindow : public CScriverWindow
{
CCtrlEdit m_log, m_message;
+ CSplitter m_splitter;
wchar_t *m_wszInitialText;
bool m_bIncoming, m_bShowTyping;
MEVENT m_hDbEventFirst, m_hDbEventLast, m_hDbUnreadEventFirst;
- int m_iSplitterPos;
- int m_iDesiredInputAreaHeight;
SIZE m_toolbarSize;
int m_iWindowWasCascaded;
int m_nTypeSecs, m_nTypeMode, m_nLastTyping;
@@ -154,13 +161,39 @@ public:
virtual void OnDestroy() override;
virtual INT_PTR DlgProc(UINT msg, WPARAM wParam, LPARAM lParam) override;
+
+ void OnSplitterMoved(CSplitter *pSplitter);
+};
+
+class CChatRoomDlg : public CScriverWindow
+{
+ CCtrlEdit m_message, m_log;
+ CCtrlListBox m_nickList;
+ CSplitter m_splitterX, m_splitterY;
+
+ void MessageDialogResize(int w, int h);
+
+public:
+ SESSION_INFO *m_si;
+ wchar_t m_wszSearch[255];
+
+public:
+ CChatRoomDlg(SESSION_INFO *si);
+
+ virtual void OnInitDialog() override;
+ virtual void OnDestroy() override;
+
+ virtual INT_PTR DlgProc(UINT uMsg, WPARAM wParam, LPARAM lParam) override;
+
+ void OnSplitterX(CSplitter *pSplitter);
+ void OnSplitterY(CSplitter *pSplitter);
+
};
#define HM_DBEVENTADDED (WM_USER+10)
#define DM_REMAKELOG (WM_USER+11)
#define DM_CASCADENEWWINDOW (WM_USER+13)
#define DM_OPTIONSAPPLIED (WM_USER+14)
-#define DM_SPLITTERMOVED (WM_USER+15)
#define DM_APPENDTOLOG (WM_USER+17)
#define DM_ERRORDECIDED (WM_USER+18)
#define DM_SCROLLLOGTOBOTTOM (WM_USER+19)