diff options
author | George Hazan <ghazan@miranda.im> | 2020-07-26 18:18:43 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2020-07-26 18:18:43 +0300 |
commit | d0176baeca0f8ff96209560dfdc2a91ec871288a (patch) | |
tree | 3a5f52388b830a768b83792ba0473ac7a7c9b49d | |
parent | d4ec4d674c4d48b5bfc30bbd730da213d573d0bb (diff) |
fixes #2501 (Ability to disable incoming sounds in chats is lost)
-rw-r--r-- | plugins/Scriver/src/chat_options.cpp | 78 | ||||
-rw-r--r-- | plugins/TabSRMM/res/chat.rc | 115 | ||||
-rw-r--r-- | plugins/TabSRMM/src/chat_options.cpp | 100 | ||||
-rw-r--r-- | plugins/TabSRMM/src/chat_resource.h | 130 | ||||
-rw-r--r-- | plugins/TabSRMM/src/chat_tools.cpp | 3 | ||||
-rw-r--r-- | plugins/TabSRMM/src/resource.h | 129 | ||||
-rw-r--r-- | src/core/stdmsg/src/chat_options.cpp | 72 | ||||
-rw-r--r-- | src/mir_app/mir_app.vcxproj | 91 | ||||
-rw-r--r-- | src/mir_app/mir_app.vcxproj.filters | 263 | ||||
-rw-r--r-- | src/mir_app/res/resource.rc | 173 | ||||
-rw-r--r-- | src/mir_app/src/chat.h | 4 | ||||
-rw-r--r-- | src/mir_app/src/chat_opts.cpp | 5 | ||||
-rw-r--r-- | src/mir_app/src/chat_tools.cpp | 5 | ||||
-rw-r--r-- | src/mir_app/src/chat_ui.cpp | 119 | ||||
-rw-r--r-- | src/mir_app/src/resource.h | 63 | ||||
-rw-r--r-- | src/mir_app/src/srmm_toolbar.cpp | 5 |
16 files changed, 901 insertions, 454 deletions
diff --git a/plugins/Scriver/src/chat_options.cpp b/plugins/Scriver/src/chat_options.cpp index c3ae07d1d3..5f3dd45f95 100644 --- a/plugins/Scriver/src/chat_options.cpp +++ b/plugins/Scriver/src/chat_options.cpp @@ -27,8 +27,8 @@ static HWND hPathTip = nullptr; struct branch_t
{
- wchar_t* szDescr;
- char* szDBName;
+ wchar_t *szDescr;
+ char *szDBName;
int iMode;
BYTE bDefault;
HTREEITEM hItem;
@@ -60,53 +60,7 @@ static struct branch_t branch2[] = { { LPGENW("Enable 'event filter' for new rooms"), "FilterEnabled", 0, 0, nullptr }
};
-static struct branch_t branch3[] = {
- { LPGENW("Show topic changes"), "FilterFlags", GC_EVENT_TOPIC, 0, nullptr },
- { LPGENW("Show users joining"), "FilterFlags", GC_EVENT_JOIN, 0, nullptr },
- { LPGENW("Show users disconnecting"), "FilterFlags", GC_EVENT_QUIT, 0, nullptr },
- { LPGENW("Show messages"), "FilterFlags", GC_EVENT_MESSAGE, 1, nullptr },
- { LPGENW("Show actions"), "FilterFlags", GC_EVENT_ACTION, 1, nullptr },
- { LPGENW("Show users leaving"), "FilterFlags", GC_EVENT_PART, 0, nullptr },
- { LPGENW("Show users being kicked"), "FilterFlags", GC_EVENT_KICK, 1, nullptr },
- { LPGENW("Show notices"), "FilterFlags", GC_EVENT_NOTICE, 1, nullptr },
- { LPGENW("Show users changing name"), "FilterFlags", GC_EVENT_NICK, 0, nullptr },
- { LPGENW("Show information messages"), "FilterFlags", GC_EVENT_INFORMATION, 1, nullptr },
- { LPGENW("Show status changes of users"), "FilterFlags", GC_EVENT_ADDSTATUS, 0, nullptr },
-};
-
-static struct branch_t branch4[] = {
- { LPGENW("Show icons in tray only when the chat room is not active"), "TrayIconInactiveOnly", 0, 1, nullptr },
- { LPGENW("Show icon in tray for topic changes"), "TrayIconFlags", GC_EVENT_TOPIC, 0, nullptr },
- { LPGENW("Show icon in tray for users joining"), "TrayIconFlags", GC_EVENT_JOIN, 0, nullptr },
- { LPGENW("Show icon in tray for users disconnecting"), "TrayIconFlags", GC_EVENT_QUIT, 0, nullptr },
- { LPGENW("Show icon in tray for messages"), "TrayIconFlags", GC_EVENT_MESSAGE, 0, nullptr },
- { LPGENW("Show icon in tray for actions"), "TrayIconFlags", GC_EVENT_ACTION, 0, nullptr },
- { LPGENW("Show icon in tray for highlights"), "TrayIconFlags", GC_EVENT_HIGHLIGHT, 1, nullptr },
- { LPGENW("Show icon in tray for users leaving"), "TrayIconFlags", GC_EVENT_PART, 0, nullptr },
- { LPGENW("Show icon in tray for users kicking other user"), "TrayIconFlags", GC_EVENT_KICK, 0, nullptr },
- { LPGENW("Show icon in tray for notices"), "TrayIconFlags", GC_EVENT_NOTICE, 0, nullptr },
- { LPGENW("Show icon in tray for name changes"), "TrayIconFlags", GC_EVENT_NICK, 0, nullptr },
- { LPGENW("Show icon in tray for information messages"), "TrayIconFlags", GC_EVENT_INFORMATION, 0, nullptr },
- { LPGENW("Show icon in tray for status changes"), "TrayIconFlags", GC_EVENT_ADDSTATUS, 0, nullptr },
-};
-
-static struct branch_t branch6[] = {
- { LPGENW("Show popups only when the chat room is not active"), "PopupInactiveOnly", 0, 1, nullptr },
- { LPGENW("Show popup for topic changes"), "PopupFlags", GC_EVENT_TOPIC, 0, nullptr },
- { LPGENW("Show popup for users joining"), "PopupFlags", GC_EVENT_JOIN, 0, nullptr },
- { LPGENW("Show popup for users disconnecting"), "PopupFlags", GC_EVENT_QUIT, 0, nullptr },
- { LPGENW("Show popup for messages"), "PopupFlags", GC_EVENT_MESSAGE, 0, nullptr },
- { LPGENW("Show popup for actions"), "PopupFlags", GC_EVENT_ACTION, 0, nullptr },
- { LPGENW("Show popup for highlights"), "PopupFlags", GC_EVENT_HIGHLIGHT, 0, nullptr },
- { LPGENW("Show popup for users leaving"), "PopupFlags", GC_EVENT_PART, 0, nullptr },
- { LPGENW("Show popup for users kicking other user"), "PopupFlags", GC_EVENT_KICK, 0, nullptr },
- { LPGENW("Show popup for notices"), "PopupFlags", GC_EVENT_NOTICE, 0, nullptr },
- { LPGENW("Show popup for name changes"), "PopupFlags", GC_EVENT_NICK, 0, nullptr },
- { LPGENW("Show popup for information messages"), "PopupFlags", GC_EVENT_INFORMATION, 0, nullptr },
- { LPGENW("Show popup for status changes"), "PopupFlags", GC_EVENT_ADDSTATUS, 0, nullptr },
-};
-
-static HTREEITEM InsertBranch(HWND hwndTree, wchar_t* pszDescr, BOOL bExpanded)
+static HTREEITEM InsertBranch(HWND hwndTree, wchar_t *pszDescr, BOOL bExpanded)
{
TVINSERTSTRUCT tvis;
tvis.hParent = nullptr;
@@ -226,7 +180,6 @@ static INT CALLBACK BrowseCallbackProc(HWND hwnd, UINT uMsg, LPARAM lp, LPARAM p static INT_PTR CALLBACK DlgProcOptions1(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam)
{
static HTREEITEM hListHeading1 = nullptr;
- static HTREEITEM hListHeading4 = nullptr;
switch (uMsg) {
case WM_INITDIALOG:
TranslateDialogDefault(hwndDlg);
@@ -234,16 +187,13 @@ static INT_PTR CALLBACK DlgProcOptions1(HWND hwndDlg, UINT uMsg, WPARAM wParam, SendDlgItemMessage(hwndDlg, IDC_CHAT_SPIN2, UDM_SETRANGE, 0, MAKELONG(255, 10));
SendDlgItemMessage(hwndDlg, IDC_CHAT_SPIN2, UDM_SETPOS, 0, MAKELONG(db_get_b(0, CHAT_MODULE, "NicklistRowDist", 12), 0));
hListHeading1 = InsertBranch(GetDlgItem(hwndDlg, IDC_CHAT_CHECKBOXES), TranslateT("Appearance and functionality of chat windows"), db_get_b(0, CHAT_MODULE, "Branch1Exp", 0) ? TRUE : FALSE);
- hListHeading4 = InsertBranch(GetDlgItem(hwndDlg, IDC_CHAT_CHECKBOXES), TranslateT("Icons to display in the tray"), db_get_b(0, CHAT_MODULE, "Branch5Exp", 0) ? TRUE : FALSE);
FillBranch(GetDlgItem(hwndDlg, IDC_CHAT_CHECKBOXES), hListHeading1, branch1, _countof(branch1), 0);
- FillBranch(GetDlgItem(hwndDlg, IDC_CHAT_CHECKBOXES), hListHeading4, branch4, _countof(branch4), 0x1000);
SendMessage(hwndDlg, OPT_FIXHEADINGS, 0, 0);
SetDlgItemText(hwndDlg, IDC_CHAT_GROUP, ptrW(Chat_GetGroup()));
break;
case OPT_FIXHEADINGS:
CheckHeading(GetDlgItem(hwndDlg, IDC_CHAT_CHECKBOXES), hListHeading1);
- CheckHeading(GetDlgItem(hwndDlg, IDC_CHAT_CHECKBOXES), hListHeading4);
break;
case WM_COMMAND:
@@ -262,8 +212,6 @@ static INT_PTR CALLBACK DlgProcOptions1(HWND hwndDlg, UINT uMsg, WPARAM wParam, TreeView_GetItem((HWND)wParam, &tvi);
if (tvi.hItem == hListHeading1)
CheckBranches(GetDlgItem(hwndDlg, IDC_CHAT_CHECKBOXES), hListHeading1);
- else if (tvi.hItem == hListHeading4)
- CheckBranches(GetDlgItem(hwndDlg, IDC_CHAT_CHECKBOXES), hListHeading4);
else
PostMessage(hwndDlg, OPT_FIXHEADINGS, 0, 0);
SendMessage(GetParent(hwndDlg), PSM_CHANGED, 0, 0);
@@ -313,7 +261,6 @@ static INT_PTR CALLBACK DlgProcOptions1(HWND hwndDlg, UINT uMsg, WPARAM wParam, else
db_unset(0, CHAT_MODULE, "NicklistRowDist");
SaveBranch(GetDlgItem(hwndDlg, IDC_CHAT_CHECKBOXES), branch1, _countof(branch1));
- SaveBranch(GetDlgItem(hwndDlg, IDC_CHAT_CHECKBOXES), branch4, _countof(branch4));
}
return TRUE;
}
@@ -322,8 +269,6 @@ static INT_PTR CALLBACK DlgProcOptions1(HWND hwndDlg, UINT uMsg, WPARAM wParam, case WM_DESTROY:
BYTE b = TreeView_GetItemState(GetDlgItem(hwndDlg, IDC_CHAT_CHECKBOXES), hListHeading1, TVIS_EXPANDED)&TVIS_EXPANDED ? 1 : 0;
db_set_b(0, CHAT_MODULE, "Branch1Exp", b);
- b = TreeView_GetItemState(GetDlgItem(hwndDlg, IDC_CHAT_CHECKBOXES), hListHeading4, TVIS_EXPANDED)&TVIS_EXPANDED ? 1 : 0;
- db_set_b(0, CHAT_MODULE, "Branch5Exp", b);
break;
}
return FALSE;
@@ -332,7 +277,6 @@ static INT_PTR CALLBACK DlgProcOptions1(HWND hwndDlg, UINT uMsg, WPARAM wParam, static INT_PTR CALLBACK DlgProcOptions2(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam)
{
static HTREEITEM hListHeading2 = nullptr;
- static HTREEITEM hListHeading3 = nullptr;
switch (uMsg) {
case WM_INITDIALOG:
@@ -401,15 +345,12 @@ static INT_PTR CALLBACK DlgProcOptions2(HWND hwndDlg, UINT uMsg, WPARAM wParam, EnableWindow(GetDlgItem(hwndDlg, IDC_CHAT_LIMITTEXT2), g_Settings.bLoggingEnabled ? TRUE : FALSE);
hListHeading2 = InsertBranch(GetDlgItem(hwndDlg, IDC_CHAT_CHECKBOXES), TranslateT("Appearance"), db_get_b(0, CHAT_MODULE, "Branch2Exp", 0) ? TRUE : FALSE);
- hListHeading3 = InsertBranch(GetDlgItem(hwndDlg, IDC_CHAT_CHECKBOXES), TranslateT("Default events to show in new chat rooms if the 'event filter' is enabled"), db_get_b(0, CHAT_MODULE, "Branch3Exp", 0) ? TRUE : FALSE);
FillBranch(GetDlgItem(hwndDlg, IDC_CHAT_CHECKBOXES), hListHeading2, branch2, _countof(branch2), 0x0);
- FillBranch(GetDlgItem(hwndDlg, IDC_CHAT_CHECKBOXES), hListHeading3, branch3, _countof(branch3), 0x03E0);
SendMessage(hwndDlg, OPT_FIXHEADINGS, 0, 0);
break;
case OPT_FIXHEADINGS:
CheckHeading(GetDlgItem(hwndDlg, IDC_CHAT_CHECKBOXES), hListHeading2);
- CheckHeading(GetDlgItem(hwndDlg, IDC_CHAT_CHECKBOXES), hListHeading3);
break;
case WM_COMMAND:
@@ -472,8 +413,6 @@ static INT_PTR CALLBACK DlgProcOptions2(HWND hwndDlg, UINT uMsg, WPARAM wParam, TreeView_GetItem((HWND)wParam, &tvi);
if (tvi.hItem == hListHeading2)
CheckBranches(GetDlgItem(hwndDlg, IDC_CHAT_CHECKBOXES), hListHeading2);
- else if (tvi.hItem == hListHeading3)
- CheckBranches(GetDlgItem(hwndDlg, IDC_CHAT_CHECKBOXES), hListHeading3);
else
PostMessage(hwndDlg, OPT_FIXHEADINGS, 0, 0);
SendMessage(GetParent(hwndDlg), PSM_CHANGED, 0, 0);
@@ -582,7 +521,6 @@ static INT_PTR CALLBACK DlgProcOptions2(HWND hwndDlg, UINT uMsg, WPARAM wParam, db_set_w(0, CHAT_MODULE, "LoggingLimit", (WORD)iLen);
SaveBranch(GetDlgItem(hwndDlg, IDC_CHAT_CHECKBOXES), branch2, _countof(branch2));
- SaveBranch(GetDlgItem(hwndDlg, IDC_CHAT_CHECKBOXES), branch3, _countof(branch3));
mir_free(pszText);
@@ -590,8 +528,6 @@ static INT_PTR CALLBACK DlgProcOptions2(HWND hwndDlg, UINT uMsg, WPARAM wParam, g_Settings.dwTrayIconFlags = db_get_dw(0, CHAT_MODULE, "TrayIconFlags", 0x1000);
g_Settings.dwPopupFlags = db_get_dw(0, CHAT_MODULE, "PopupFlags", 0x0000);
g_Settings.bStripFormat = db_get_b(0, CHAT_MODULE, "TrimFormatting", 0) != 0;
- g_Settings.bTrayIconInactiveOnly = db_get_b(0, CHAT_MODULE, "TrayIconInactiveOnly", 1) != 0;
- g_Settings.bPopupInactiveOnly = db_get_b(0, CHAT_MODULE, "PopUpInactiveOnly", 1) != 0;
g_Settings.bLogIndentEnabled = (db_get_b(0, CHAT_MODULE, "LogIndentEnabled", 1) != 0) ? TRUE : FALSE;
g_chatApi.MM_FontsChanged();
@@ -612,10 +548,8 @@ static INT_PTR CALLBACK DlgProcOptions2(HWND hwndDlg, UINT uMsg, WPARAM wParam, hPathTip = nullptr;
}
- BYTE b = TreeView_GetItemState(GetDlgItem(hwndDlg, IDC_CHAT_CHECKBOXES), hListHeading2, TVIS_EXPANDED)&TVIS_EXPANDED ? 1 : 0;
+ BYTE b = TreeView_GetItemState(GetDlgItem(hwndDlg, IDC_CHAT_CHECKBOXES), hListHeading2, TVIS_EXPANDED) & TVIS_EXPANDED ? 1 : 0;
db_set_b(0, CHAT_MODULE, "Branch2Exp", b);
- b = TreeView_GetItemState(GetDlgItem(hwndDlg, IDC_CHAT_CHECKBOXES), hListHeading3, TVIS_EXPANDED)&TVIS_EXPANDED ? 1 : 0;
- db_set_b(0, CHAT_MODULE, "Branch3Exp", b);
break;
}
return FALSE;
@@ -643,7 +577,6 @@ static INT_PTR CALLBACK DlgProcOptionsPopup(HWND hwndDlg, UINT uMsg, WPARAM wPar SendDlgItemMessage(hwndDlg, IDC_CHAT_SPIN1, UDM_SETRANGE, 0, MAKELONG(100, -1));
SendDlgItemMessage(hwndDlg, IDC_CHAT_SPIN1, UDM_SETPOS, 0, MAKELONG(g_Settings.iPopupTimeout, 0));
- FillBranch(GetDlgItem(hwndDlg, IDC_CHAT_CHECKBOXES), nullptr, branch6, _countof(branch6), 0x0000);
break;
case WM_COMMAND:
@@ -703,7 +636,6 @@ static INT_PTR CALLBACK DlgProcOptionsPopup(HWND hwndDlg, UINT uMsg, WPARAM wPar db_set_dw(0, CHAT_MODULE, "PopupColorBG", (DWORD)SendDlgItemMessage(hwndDlg, IDC_CHAT_BKG, CPM_GETCOLOUR, 0, 0));
g_Settings.crPUTextColour = SendDlgItemMessage(hwndDlg, IDC_CHAT_TEXT, CPM_GETCOLOUR, 0, 0);
db_set_dw(0, CHAT_MODULE, "PopupColorText", (DWORD)SendDlgItemMessage(hwndDlg, IDC_CHAT_TEXT, CPM_GETCOLOUR, 0, 0));
- SaveBranch(GetDlgItem(hwndDlg, IDC_CHAT_CHECKBOXES), branch6, _countof(branch6));
}
return TRUE;
}
@@ -732,7 +664,7 @@ void ChatOptInitialize(WPARAM wParam) odp.pszTemplate = MAKEINTRESOURCEA(IDD_OPTIONS2);
odp.pfnDlgProc = DlgProcOptions2;
- odp.szTab.a = LPGEN("Event log");
+ odp.szTab.a = LPGEN("Log formatting");
g_plugin.addOptions(wParam, &odp);
////////////////////////////////////////////////////////////////////////////////////////
diff --git a/plugins/TabSRMM/res/chat.rc b/plugins/TabSRMM/res/chat.rc index 35c5f8db20..4c78a06712 100644 --- a/plugins/TabSRMM/res/chat.rc +++ b/plugins/TabSRMM/res/chat.rc @@ -1,16 +1,13 @@ // Microsoft Visual C++ generated resource script.
//
-#include "..\src\chat_resource.h"
#include "..\src\resource.h"
-#include "..\..\include\chat_resource.h"
#define APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 2 resource.
//
-#include "winres.h"
-#include "richedit.h"
+#include <winres.h>
/////////////////////////////////////////////////////////////////////////////
#undef APSTUDIO_READONLY_SYMBOLS
@@ -19,7 +16,7 @@ #if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_NEU)
LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL
-#pragma code_page(1252)
+#pragma code_page(1251)
/////////////////////////////////////////////////////////////////////////////
//
@@ -32,8 +29,8 @@ FONT 8, "MS Shell Dlg", 0, 0, 0x1 BEGIN
CONTROL "",IDC_SPLITTERX,"Static",SS_ENHMETAFILE,172,23,10,73
CONTROL "",IDC_SPLITTERY,"Static",SS_ENHMETAFILE,0,132,251,6
- CONTROL "",IDC_SRMM_MESSAGE,"RichEdit50W",WS_VSCROLL | WS_TABSTOP | ES_MULTILINE | ES_AUTOVSCROLL | ES_NOHIDESEL | ES_WANTRETURN,0,128,127,12,WS_EX_STATICEDGE
- CONTROL "",IDC_SRMM_LOG,"RichEdit50W",WS_VSCROLL | ES_MULTILINE | ES_AUTOVSCROLL | ES_NOHIDESEL | ES_READONLY,8,23,164,72,WS_EX_STATICEDGE
+ CONTROL "",IDC_SRMM_MESSAGE,"RichEdit50W",WS_VSCROLL | WS_TABSTOP | 0x1144,0,128,127,12,WS_EX_STATICEDGE
+ CONTROL "",IDC_SRMM_LOG,"RichEdit50W",WS_VSCROLL | 0x944,8,23,164,72,WS_EX_STATICEDGE
LISTBOX IDC_SRMM_NICKLIST,182,23,69,73,LBS_MULTIPLESEL | LBS_OWNERDRAWFIXED | LBS_NOINTEGRALHEIGHT | LBS_EXTENDEDSEL | LBS_NODATA | NOT WS_BORDER | WS_VSCROLL | WS_TABSTOP,WS_EX_STATICEDGE
CONTROL "",IDC_PANELSPLITTER,"Static",SS_ENHMETAFILE,0,32,252,1,WS_EX_TRANSPARENT
END
@@ -92,7 +89,7 @@ BEGIN EDITTEXT IDC_GROUP,152,208,142,14,ES_AUTOHSCROLL
END
-IDD_OPTIONS2 DIALOGEX 0, 0, 306, 189
+IDD_OPTIONS2 DIALOGEX 0, 0, 306, 209
STYLE DS_SETFONT | DS_FIXEDSYS | WS_CHILD
EXSTYLE WS_EX_CONTROLPARENT
FONT 8, "MS Shell Dlg", 0, 0, 0x1
@@ -115,75 +112,14 @@ BEGIN LTEXT "Timestamp (logfile)",IDC_STATIC,205,111,81,8
EDITTEXT IDC_LOGTIMESTAMP,205,121,81,14,ES_AUTOHSCROLL
LTEXT "Maximum number of events in the message window",IDC_STATIC,10,142,225,11
- EDITTEXT IDC_LOGLIMIT,248,139,38,14,ES_RIGHT | ES_AUTOHSCROLL | ES_NUMBER
- CONTROL "Spin1",IDC_CHAT_SPIN2,"msctls_updown32",UDS_SETBUDDYINT | UDS_ALIGNRIGHT | UDS_AUTOBUDDY | UDS_ARROWKEYS | UDS_NOTHOUSANDS | UDS_HOTTRACK,281,138,11,14
- LTEXT "Group chat nick list row height (pixels)",IDC_STATIC_ULIST,10,167,221,8
- EDITTEXT IDC_NICKROW2,247,164,29,14,ES_RIGHT | ES_AUTOHSCROLL | ES_NUMBER
- CONTROL "",IDC_CHAT_SPIN3,"msctls_updown32",UDS_SETBUDDYINT | UDS_ALIGNRIGHT | UDS_AUTOBUDDY | UDS_ARROWKEYS | UDS_NOTHOUSANDS | UDS_HOTTRACK,275,167,11,14
+ EDITTEXT IDC_LOGLIMIT,247,139,29,14,ES_RIGHT | ES_AUTOHSCROLL | ES_NUMBER
+ CONTROL "Spin1",IDC_CHAT_SPIN2,"msctls_updown32",UDS_SETBUDDYINT | UDS_ALIGNRIGHT | UDS_AUTOBUDDY | UDS_ARROWKEYS | UDS_NOTHOUSANDS | UDS_HOTTRACK,276,139,11,14
+ LTEXT "Group chat nick list row height (pixels)",IDC_STATIC_ULIST,10,161,221,8
+ EDITTEXT IDC_NICKROW2,247,158,29,14,ES_RIGHT | ES_AUTOHSCROLL | ES_NUMBER
+ CONTROL "",IDC_CHAT_SPIN3,"msctls_updown32",UDS_SETBUDDYINT | UDS_ALIGNRIGHT | UDS_AUTOBUDDY | UDS_ARROWKEYS | UDS_NOTHOUSANDS | UDS_HOTTRACK,275,158,11,14
PUSHBUTTON "Open log file base folder",IDC_MUC_OPENLOGBASEDIR,16,76,155,14
-END
-
-IDD_OPTIONS3 DIALOGEX 0, 0, 306, 224
-STYLE DS_SETFONT | DS_FIXEDSYS | WS_CHILD
-EXSTYLE WS_EX_CONTROLPARENT
-FONT 8, "MS Shell Dlg", 0, 0, 0x1
-BEGIN
- GROUPBOX "Default settings for known event types",IDC_STATIC,7,5,293,153
- LTEXT "Show when filter is active",IDC_STATIC,12,14,119,13,SS_CENTERIMAGE
- CTEXT "Log to file",IDC_TEXTO4,234,13,64,13,SS_CENTERIMAGE
- CTEXT "Show popup",IDC_TEXTO2,131,13,49,13,SS_CENTERIMAGE
- CTEXT "Notify in tray",IDC_TEXTO3,183,13,49,13,SS_CENTERIMAGE
- CONTROL "Actions",IDC_1,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,32,28,110,10
- CONTROL "Messages",IDC_2,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,32,38,110,10
- CONTROL "Nick changes",IDC_3,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,32,48,110,10
- CONTROL "Users joining",IDC_4,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,32,58,110,10
- CONTROL "Users leaving",IDC_5,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,32,68,110,10
- CONTROL "Topic changes",IDC_6,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,32,78,110,10
- CONTROL "Status changes",IDC_7,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,32,88,110,10
- CONTROL "Information",IDC_8,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,32,98,110,10
- CONTROL "Disconnects",IDC_9,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,32,108,110,10
- CONTROL "User kicks",IDC_10,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,32,118,110,10
- CONTROL "Notices",IDC_11,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,32,128,110,10
- CONTROL "",IDC_P1,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,152,28,21,10
- CONTROL "",IDC_P2,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,152,38,21,10
- CONTROL "",IDC_P3,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,152,48,21,10
- CONTROL "",IDC_P4,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,152,58,21,10
- CONTROL "",IDC_P5,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,152,68,21,10
- CONTROL "",IDC_P6,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,152,78,21,10
- CONTROL "",IDC_P7,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,152,88,21,10
- CONTROL "",IDC_P8,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,152,98,21,10
- CONTROL "",IDC_P9,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,152,108,21,10
- CONTROL "",IDC_P10,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,152,118,21,10
- CONTROL "",IDC_P11,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,152,128,21,10
- CONTROL "",IDC_P12,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,152,138,21,10
- CONTROL "",IDC_T1,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,204,28,21,10
- CONTROL "",IDC_T2,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,204,38,21,10
- CONTROL "",IDC_T3,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,204,48,21,10
- CONTROL "",IDC_T4,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,204,58,21,10
- CONTROL "",IDC_T5,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,204,68,21,10
- CONTROL "",IDC_T6,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,204,78,21,10
- CONTROL "",IDC_T7,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,204,88,21,10
- CONTROL "",IDC_T8,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,204,98,21,10
- CONTROL "",IDC_T9,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,204,108,21,10
- CONTROL "",IDC_T10,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,204,118,21,10
- CONTROL "",IDC_T11,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,204,128,21,10
- CONTROL "",IDC_T12,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,204,138,21,10
- CONTROL "",IDC_L1,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,263,28,21,10
- CONTROL "",IDC_L2,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,263,38,21,10
- CONTROL "",IDC_L3,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,263,48,21,10
- CONTROL "",IDC_L4,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,263,58,21,10
- CONTROL "",IDC_L5,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,263,68,21,10
- CONTROL "",IDC_L6,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,263,78,21,10
- CONTROL "",IDC_L7,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,263,88,21,10
- CONTROL "",IDC_L8,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,263,98,21,10
- CONTROL "",IDC_L9,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,263,108,21,10
- CONTROL "",IDC_L10,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,263,118,21,10
- CONTROL "",IDC_L11,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,263,128,21,10
- CONTROL "Suppress tray notifications for focused channel windows",IDC_TRAYONLYFORINACTIVE,
- "Button",BS_AUTOCHECKBOX | WS_TABSTOP,13,164,279,10
- LTEXT "Highlight event",IDC_STATIC,42,139,100,12
- COMBOBOX IDC_LOGICONTYPE,12,204,171,38,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP
- LTEXT "Line markers in the message log",IDC_STATIC,14,193,257,10
+ COMBOBOX IDC_LOGICONTYPE,12,189,171,38,CBS_DROPDOWNLIST | WS_VSCROLL | WS_TABSTOP
+ LTEXT "Line markers in the message log",IDC_STATIC,10,178,276,10
END
IDD_OPTIONS4 DIALOGEX 0, 0, 306, 230
@@ -206,6 +142,7 @@ BEGIN "Button",BS_AUTOCHECKBOX | WS_TABSTOP,11,211,278,11
END
+
/////////////////////////////////////////////////////////////////////////////
//
// DESIGNINFO
@@ -257,16 +194,16 @@ BEGIN VERTGUIDE, 60
VERTGUIDE, 286
TOPMARGIN, 1
+ BOTTOMMARGIN, 189
HORZGUIDE, 107
HORZGUIDE, 126
HORZGUIDE, 146
HORZGUIDE, 150
- HORZGUIDE, 174
END
IDD_OPTIONS3, DIALOG
BEGIN
- VERTGUIDE, 32
+ VERTGUIDE, 22
VERTGUIDE, 42
VERTGUIDE, 142
END
@@ -282,14 +219,12 @@ END 1 TEXTINCLUDE
BEGIN
- "..\\src\\chat_resource.h\r\n"
- "..\\src\\resource.h\0"
+ "..\\src\\resource.h\0"
END
2 TEXTINCLUDE
BEGIN
- "#include ""winres.h""\r\n"
- "#include ""richedit.h""\0"
+ "#include <winres.h>\0"
END
3 TEXTINCLUDE
@@ -300,6 +235,22 @@ END #endif // APSTUDIO_INVOKED
+
+/////////////////////////////////////////////////////////////////////////////
+//
+// AFX_DIALOG_LAYOUT
+//
+
+IDD_OPTIONS3 AFX_DIALOG_LAYOUT
+BEGIN
+ 0
+END
+
+IDD_OPTIONS2 AFX_DIALOG_LAYOUT
+BEGIN
+ 0
+END
+
#endif // Neutral resources
/////////////////////////////////////////////////////////////////////////////
diff --git a/plugins/TabSRMM/src/chat_options.cpp b/plugins/TabSRMM/src/chat_options.cpp index 79273619d5..1f3efd7646 100644 --- a/plugins/TabSRMM/src/chat_options.cpp +++ b/plugins/TabSRMM/src/chat_options.cpp @@ -582,6 +582,7 @@ class CChatLogOptionDlg : public CChatBaseOptionDlg CTimer m_timer;
CCtrlButton btnBaseDir, btnFontChoose;
CCtrlCheck chkLogging;
+ CCtrlCombo cmbIconType;
HWND hPathTip = nullptr;
public:
@@ -590,7 +591,8 @@ public: m_timer(this, 1),
btnBaseDir(this, IDC_MUC_OPENLOGBASEDIR),
chkLogging(this, IDC_LOGGING),
- btnFontChoose(this, IDC_FONTCHOOSE)
+ btnFontChoose(this, IDC_FONTCHOOSE),
+ cmbIconType(this, IDC_LOGICONTYPE)
{
btnBaseDir.OnClick = Callback(this, &CChatLogOptionDlg::onClick_BaseDir);
btnFontChoose.OnClick = Callback(this, &CChatLogOptionDlg::onClick_FontChoose);
@@ -618,6 +620,11 @@ public: SendDlgItemMessage(m_hwnd, IDC_CHAT_SPIN4, UDM_SETPOS, 0, MAKELONG(db_get_w(0, CHAT_MODULE, "LoggingLimit", 100), 0));
Utils::enableDlgControl(m_hwnd, IDC_LIMIT, g_Settings.bLoggingEnabled);
+ cmbIconType.AddString(TranslateT("No markers"));
+ cmbIconType.AddString(TranslateT("Show as icons"));
+ cmbIconType.AddString(TranslateT("Show as text symbols"));
+ cmbIconType.SetCurSel((g_Settings.bLogSymbols ? 2 : (g_Settings.dwIconFlags ? 1 : 0)));
+
CMStringW tszTooltipText(FORMAT,
L"%s - %s\n%s - %s\n%s - %s\n%s - %s\n\n"
L"%s - %s\n%s - %s\n%s - %s\n%s - %s\n%s - %s\n%s - %s\n%s - %s\n%s - %s\n%s - %s\n%s - %s\n\n"
@@ -716,6 +723,10 @@ public: }
else db_unset(0, CHAT_MODULE, "HeaderOutgoing");
+ LRESULT lr = cmbIconType.GetCurSel();
+ db_set_dw(0, CHAT_MODULE, "IconFlags", lr == 1);
+ db_set_b(0, CHAT_MODULE, "LogSymbols", lr == 2);
+
iLen = SendDlgItemMessage(m_hwnd, IDC_CHAT_SPIN2, UDM_GETPOS, 0, 0);
db_set_w(0, CHAT_MODULE, "LogLimit", (WORD)iLen);
mir_free(pszText);
@@ -818,89 +829,6 @@ public: };
/////////////////////////////////////////////////////////////////////////////////////////
-// Group chat - Events
-
-#define NR_GC_EVENTS 12
-
-static UINT _eventorder[] =
-{
- GC_EVENT_ACTION,
- GC_EVENT_MESSAGE,
- GC_EVENT_NICK,
- GC_EVENT_JOIN,
- GC_EVENT_PART,
- GC_EVENT_TOPIC,
- GC_EVENT_ADDSTATUS,
- GC_EVENT_INFORMATION,
- GC_EVENT_QUIT,
- GC_EVENT_KICK,
- GC_EVENT_NOTICE,
- GC_EVENT_HIGHLIGHT
-};
-
-class CChatEventOptionDlg : public CChatBaseOptionDlg
-{
-
-public:
- CChatEventOptionDlg() :
- CChatBaseOptionDlg(IDD_OPTIONS3)
- {}
-
- bool OnInitDialog() override
- {
- DWORD dwFilterFlags = db_get_dw(0, CHAT_MODULE, "FilterFlags", GC_EVENT_ALL);
- DWORD dwTrayFlags = db_get_dw(0, CHAT_MODULE, "TrayIconFlags", GC_EVENT_HIGHLIGHT);
- DWORD dwPopupFlags = db_get_dw(0, CHAT_MODULE, "PopupFlags", GC_EVENT_HIGHLIGHT);
- DWORD dwLogFlags = db_get_dw(0, CHAT_MODULE, "DiskLogFlags", GC_EVENT_ALL);
-
- for (int i = 0; i < _countof(_eventorder); i++) {
- if (_eventorder[i] != GC_EVENT_HIGHLIGHT) {
- CheckDlgButton(m_hwnd, IDC_1 + i, dwFilterFlags & _eventorder[i] ? BST_CHECKED : BST_UNCHECKED);
- CheckDlgButton(m_hwnd, IDC_L1 + i, dwLogFlags & _eventorder[i] ? BST_CHECKED : BST_UNCHECKED);
- }
- CheckDlgButton(m_hwnd, IDC_P1 + i, dwPopupFlags & _eventorder[i] ? BST_CHECKED : BST_UNCHECKED);
- CheckDlgButton(m_hwnd, IDC_T1 + i, dwTrayFlags & _eventorder[i] ? BST_CHECKED : BST_UNCHECKED);
- }
-
- SendDlgItemMessage(m_hwnd, IDC_LOGICONTYPE, CB_ADDSTRING, -1, (LPARAM)TranslateT("No markers"));
- SendDlgItemMessage(m_hwnd, IDC_LOGICONTYPE, CB_ADDSTRING, -1, (LPARAM)TranslateT("Show as icons"));
- SendDlgItemMessage(m_hwnd, IDC_LOGICONTYPE, CB_ADDSTRING, -1, (LPARAM)TranslateT("Show as text symbols"));
-
- SendDlgItemMessage(m_hwnd, IDC_LOGICONTYPE, CB_SETCURSEL, (g_Settings.bLogSymbols ? 2 : (g_Settings.dwIconFlags ? 1 : 0)), 0);
-
- CheckDlgButton(m_hwnd, IDC_TRAYONLYFORINACTIVE, db_get_b(0, CHAT_MODULE, "TrayIconInactiveOnly", 0) ? BST_CHECKED : BST_UNCHECKED);
- return true;
- }
-
- bool OnApply() override
- {
- DWORD dwFilterFlags = 0, dwTrayFlags = 0,
- dwPopupFlags = 0, dwLogFlags = 0;
-
- for (int i = 0; i < _countof(_eventorder); i++) {
- if (_eventorder[i] != GC_EVENT_HIGHLIGHT) {
- dwFilterFlags |= (IsDlgButtonChecked(m_hwnd, IDC_1 + i) ? _eventorder[i] : 0);
- dwLogFlags |= (IsDlgButtonChecked(m_hwnd, IDC_L1 + i) ? _eventorder[i] : 0);
- }
- dwPopupFlags |= (IsDlgButtonChecked(m_hwnd, IDC_P1 + i) ? _eventorder[i] : 0);
- dwTrayFlags |= (IsDlgButtonChecked(m_hwnd, IDC_T1 + i) ? _eventorder[i] : 0);
- }
- db_set_dw(0, CHAT_MODULE, "FilterFlags", dwFilterFlags);
- db_set_dw(0, CHAT_MODULE, "PopupFlags", dwPopupFlags);
- db_set_dw(0, CHAT_MODULE, "TrayIconFlags", dwTrayFlags);
- db_set_dw(0, CHAT_MODULE, "DiskLogFlags", dwLogFlags);
-
- LRESULT lr = SendDlgItemMessage(m_hwnd, IDC_LOGICONTYPE, CB_GETCURSEL, 0, 0);
-
- db_set_dw(0, CHAT_MODULE, "IconFlags", lr == 1 ? 1 : 0);
- db_set_b(0, CHAT_MODULE, "LogSymbols", lr == 2 ? 1 : 0);
-
- db_set_b(0, CHAT_MODULE, "TrayIconInactiveOnly", IsDlgButtonChecked(m_hwnd, IDC_TRAYONLYFORINACTIVE) ? 1 : 0);
- return true;
- }
-};
-
-/////////////////////////////////////////////////////////////////////////////////////////
// Group chat - Highlight
class CHighlighOptionDlg : public CChatBaseOptionDlg
@@ -988,10 +916,6 @@ void Chat_Options(WPARAM wParam) odp.pDialog = new CChatLogOptionDlg();
g_plugin.addOptions(wParam, &odp);
- odp.szTab.a = LPGEN("Events and filters");
- odp.pDialog = new CChatEventOptionDlg();
- g_plugin.addOptions(wParam, &odp);
-
odp.szTab.a = LPGEN("Highlighting");
odp.pDialog = new CHighlighOptionDlg();
g_plugin.addOptions(wParam, &odp);
diff --git a/plugins/TabSRMM/src/chat_resource.h b/plugins/TabSRMM/src/chat_resource.h deleted file mode 100644 index 6a6d833b9e..0000000000 --- a/plugins/TabSRMM/src/chat_resource.h +++ /dev/null @@ -1,130 +0,0 @@ -//{{NO_DEPENDENCIES}}
-// Microsoft Visual C++ generated include file.
-// Used by chat.rc
-//
-#define IDD_CHANNEL 401
-#define IDD_OPTIONS1 402
-#define IDD_OPTIONS2 403
-#define IDD_FILTER 404
-#define IDD_OPTIONSPOPUP 405
-#define IDD_OPTIONS3 407
-#define IDD_OPTIONS4 408
-#define IDC_CHECKBOXES 1021
-#define IDC_NICKROW2 1023
-#define IDC_NICKROW 1024
-#define IDC_LOGLIMIT 1024
-#define IDC_CHAT_SPIN2 1029
-#define IDC_CHAT_SPIN3 1030
-#define IDC_CHAT_SPIN4 1031
-#define IDC_PANELNICK 1032
-#define IDC_PANELUIN 1033
-#define IDC_INSTAMP 1041
-#define IDC_OUTSTAMP 1043
-#define IDC_TIMESTAMP 1046
-#define IDC_FONTCHOOSE 1047
-#define IDC_LOGDIRECTORY 1048
-#define IDC_LIMIT 1050
-#define IDC_LOGTIMESTAMP 1051
-#define IDC_GROUP 1057
-#define IDC_RADIO2 1062
-#define IDC_RADIO3 1063
-#define IDC_TEXT 1064
-#define IDC_BKG 1065
-#define IDC_TIMEOUT 1067
-#define IDC_TEXTO 1069
-#define IDC_LOGGING 1069
-#define IDC_TEXTO2 1070
-#define IDC_TEXTO3 1071
-#define IDC_TEXTO4 1072
-#define IDC_STATIC_ADD 1077
-#define IDC_STATIC_ULIST 1078
-#define IDC_STATIC_OTHER 1079
-#define IDC_STATIC110 1082
-#define IDC_STATIC112 1085
-#define IDC_TRAYONLYFORINACTIVE 1086
-#define IDC_LOGICONTYPE 1088
-#define IDC_HIGHLIGHTNICKENABLE 1089
-#define IDC_HIGHLIGHTNICKUID 1090
-#define IDC_HIGHLIGHTNICKPATTERN 1091
-#define IDC_HIGHLIGHTTEXTENABLE 1092
-#define IDC_HIGHLIGHTTEXTPATTERN 1093
-#define IDC_HIGHLIGHTME 1094
-#define IDC_MUC_OPENLOGBASEDIR 1096
-#define IDC_1 1200
-#define IDC_2 1201
-#define IDC_3 1202
-#define IDC_4 1203
-#define IDC_5 1204
-#define IDC_6 1205
-#define IDC_7 1206
-#define IDC_8 1207
-#define IDC_9 1208
-#define IDC_10 1209
-#define IDC_11 1210
-#define IDC_PANELSPLITTER 1216
-#define IDC_P1 1300
-#define IDC_P2 1301
-#define IDC_P3 1302
-#define IDC_P4 1303
-#define IDC_P5 1304
-#define IDC_P6 1305
-#define IDC_P7 1306
-#define IDC_P8 1307
-#define IDC_P9 1308
-#define IDC_P10 1309
-#define IDC_P11 1310
-#define IDC_P12 1311
-#define IDC_T1 1400
-#define IDC_T2 1401
-#define IDC_T3 1402
-#define IDC_T4 1403
-#define IDC_T5 1404
-#define IDC_T6 1405
-#define IDC_T7 1406
-#define IDC_T8 1407
-#define IDC_T9 1408
-#define IDC_T10 1409
-#define IDC_T11 1410
-#define IDC_T12 1411
-#define IDC_L1 1500
-#define IDC_L2 1501
-#define IDC_L3 1502
-#define IDC_L4 1503
-#define IDC_L5 1504
-#define IDC_L6 1505
-#define IDC_L7 1506
-#define IDC_L8 1507
-#define IDC_L9 1508
-#define IDC_L10 1509
-#define IDC_L11 1510
-#define IDC_WHITERECT 1600
-#define ID_MESS 40001
-#define ID_NEW 40002
-#define ID_CURR 40003
-#define ID_COPY 40004
-#define ID_COPYALL 40006
-#define ID_CLEARLOG 40009
-#define ID_MESSAGE_UNDO 40013
-#define ID_MESSAGE_COPY 40014
-#define ID_MESSAGE_CUT 40015
-#define ID_MESSAGE_CLEAR 40017
-#define ID_MESSAGE_SELECTALL 40018
-#define ID_MESSAGE_REDO 40019
-#define ID_MESSAGE_PASTE 40020
-#define ID_CLOSE 40022
-#define ID_CLOSEOTHER 40023
-#define ID_LOCKPOSITION 40024
-#define ID_SEARCH_GOOGLE 40027
-#define ID_SEARCH_WIKIPEDIA 40028
-#define ID_WIKIPEDIA_ 40029
-
-// Next default values for new objects
-//
-#ifdef APSTUDIO_INVOKED
-#ifndef APSTUDIO_READONLY_SYMBOLS
-#define _APS_NEXT_RESOURCE_VALUE 163
-#define _APS_NEXT_COMMAND_VALUE 40030
-#define _APS_NEXT_CONTROL_VALUE 1097
-#define _APS_NEXT_SYMED_VALUE 101
-#endif
-#endif
diff --git a/plugins/TabSRMM/src/chat_tools.cpp b/plugins/TabSRMM/src/chat_tools.cpp index 9b75597491..cc43998dd8 100644 --- a/plugins/TabSRMM/src/chat_tools.cpp +++ b/plugins/TabSRMM/src/chat_tools.cpp @@ -403,6 +403,9 @@ BOOL DoSoundsFlashPopupTrayStuff(SESSION_INFO *si, GCEVENT *gce, BOOL bHighlight params->hNotifyIcon = g_chatApi.hIcons[ICON_TOPIC];
break;
}
+
+ if (!(db_get_dw(0, CHAT_MODULE, "SoundFlags", GC_EVENT_HIGHLIGHT) & params->iEvent))
+ params->sound = nullptr;
}
else {
switch (params->iEvent) {
diff --git a/plugins/TabSRMM/src/resource.h b/plugins/TabSRMM/src/resource.h index aa34e55036..e0e728052a 100644 --- a/plugins/TabSRMM/src/resource.h +++ b/plugins/TabSRMM/src/resource.h @@ -1,8 +1,9 @@ //{{NO_DEPENDENCIES}}
// Microsoft Visual C++ generated include file.
-// Used by w:\miranda-ng\plugins\TabSRMM\res\resource.rc
+// Used by w:\miranda-ng\plugins\TabSRMM\res\chat.rc
//
#define IDD_TEMPLATEEDIT 1
+#define VS_VERSION_INFO 1
#define IDD_USERPREFS 2
#define IDOK2 2
#define IDD_USERPREFS1 3
@@ -55,6 +56,13 @@ #define IDD_SKINTABDIALOG 312
#define IDD_OPT_SKIN 313
#define IDD_OPTIONS_PLUS 333
+#define IDD_CHANNEL 401
+#define IDD_OPTIONS1 402
+#define IDD_OPTIONS2 403
+#define IDD_FILTER 404
+#define IDD_OPTIONSPOPUP 405
+#define IDD_OPTIONS3 407
+#define IDD_OPTIONS4 408
#define IDC_QMGR_REMOVE 1000
#define IDC_EXCEPTION_DETAILS 1000
#define IDC_UNLOAD 1000
@@ -87,13 +95,20 @@ #define IDC_CHKACTL_DISMISS 1019
#define IDC_QUOTE 1020
#define IDC_CHKACTL_OPEN 1021
+#define IDC_CHECKBOXES 1021
#define IDC_NAME 1022
+#define IDC_NICKROW2 1023
#define IDC_CHKACTL_REMOVE 1023
#define IDC_CHKWINDOWCHECK 1024
+#define IDC_NICKROW 1024
+#define IDC_LOGLIMIT 1024
#define IDC_CLOSE 1025
#define IDC_CHKACTR_DISMISS 1026
#define IDC_CHKACTR_OPEN 1028
#define IDC_CONTACTPIC 1029
+#define IDC_CHAT_SPIN2 1029
+#define IDC_CHAT_SPIN3 1030
+#define IDC_CHAT_SPIN4 1031
#define IDC_ST_ENTERMSG 1031
#define IDC_PANELNICK 1032
#define IDC_PANELUIN 1033
@@ -103,20 +118,28 @@ #define IDC_CHKDEFAULTCOL_MESSAGE 1038
#define IDC_CHKDEFAULTCOL_MUC 1039
#define IDC_CHKDEFAULTCOL_ERR 1040
+#define IDC_INSTAMP 1041
#define IDC_COLBACK_MESSAGE 1041
#define IDC_COLTEXT_MESSAGE 1042
#define IDC_COLTEXT_MUC 1043
+#define IDC_OUTSTAMP 1043
#define IDC_COLBACK_MUC 1044
#define IDC_COLTEXT_ERR 1045
#define IDC_COLBACK_ERR 1046
+#define IDC_TIMESTAMP 1046
#define IDC_SHOWNAMES 1047
+#define IDC_FONTCHOOSE 1047
+#define IDC_LOGDIRECTORY 1048
#define IDC_CHKDEFAULTCOL_OTHERS 1050
+#define IDC_LIMIT 1050
#define IDC_COLBACK_OTHERS 1051
+#define IDC_LOGTIMESTAMP 1051
#define IDC_CLOSEONREPLY 1052
#define IDC_COLTEXT_OTHERS 1053
#define IDC_SHOWFILES 1054
#define IDC_MERGEPOPUP 1056
#define IDC_CHKINFINITE_MESSAGE 1057
+#define IDC_GROUP 1057
#define IDC_CHKMERGEPOPUP 1058
#define IDC_IMGTAG 1058
#define IDC_SHOWURLS 1059
@@ -125,44 +148,67 @@ #define IDC_SCROLLFIX 1060
#define IDC_CLIENTINSTATBAR 1061
#define IDC_TYPINGSOUNDS 1062
+#define IDC_RADIO2 1062
#define IDC_OFFLINEMULTI 1063
#define IDC_CLIENTINSTATBAR2 1063
#define IDC_ICONWARNINGS 1063
+#define IDC_RADIO3 1063
#define IDC_AUTOCLOSEV2 1064
+#define IDC_TEXT 1064
#define IDC_RESTART 1065
+#define IDC_BKG 1065
#define IDC_DELAY_OTHERS 1066
#define IDC_CLIST 1067
#define IDC_DELAY_MUC 1067
+#define IDC_TIMEOUT 1067
#define IDC_NUMBERMSG 1068
#define IDC_MULTISPLITTER 1069
+#define IDC_TEXTO 1069
+#define IDC_LOGGING 1069
#define IDC_CHKSHOWDATE 1070
+#define IDC_TEXTO2 1070
#define IDC_SAVEPERCONTACT 1071
+#define IDC_TEXTO3 1071
#define IDC_CHKSHOWTIME 1072
+#define IDC_TEXTO4 1072
#define IDC_CHKSHOWHEADERS 1073
#define IDC_LOADCOUNTN 1074
+#define IDC_TEXTO5 1074
#define IDC_RDNEW 1075
#define IDC_LOADCOUNTSPIN 1076
#define IDC_RDOLD 1077
+#define IDC_STATIC_ADD 1077
#define IDC_SHOWINFOLINE 1078
+#define IDC_STATIC_ULIST 1078
#define IDC_LBNUMBERMSG 1079
+#define IDC_STATIC_OTHER 1079
#define IDC_SHOWBUTTONLINE 1080
#define IDC_CHKINFINITE_URL 1081
#define IDC_LOADUNREAD 1082
+#define IDC_STATIC110 1082
#define IDC_SENDONENTER 1083
#define IDC_CHKINFINITE_FILE 1084
#define IDC_LOADCOUNT 1085
+#define IDC_STATIC112 1085
#define IDC_SENDONDBLENTER 1086
#define IDC_CHKINFINITE_OTHERS 1087
#define IDC_LOADTIMEN 1088
#define IDC_LOADTIMESPIN 1089
+#define IDC_HIGHLIGHTNICKENABLE 1089
#define IDC_LOADTIME 1090
+#define IDC_HIGHLIGHTNICKUID 1090
#define IDC_CMDEDITHEADERS 1091
+#define IDC_HIGHLIGHTNICKPATTERN 1091
#define IDC_TRIM 1091
+#define IDC_HIGHLIGHTTEXTENABLE 1092
#define IDC_FONTLIST 1092
#define IDC_TRIMSPIN 1092
+#define IDC_HIGHLIGHTTEXTPATTERN 1093
#define IDC_USEOSD 1093
+#define IDC_HIGHLIGHTME 1094
#define IDC_CHOOSEFONT 1094
#define IDC_CHKACTTE_DISMISS 1095
+#define IDC_MUC_OPENLOGBASEDIR 1096
#define IDC_CHKACTTE_OPEN 1096
#define IDC_STMINSOLD 1097
#define IDC_CHKACTTE_REMOVE 1098
@@ -261,6 +307,7 @@ #define IDC_PANELSPLITTER 1216
#define IDC_AUTOCREATECONTAINER 1216
#define IDC_LIMITAVATARS 1217
+#define IDC_LOGICONTYPE 1218
#define IDC_DONTREPORT 1219
#define IDC_SPIN1 1220
#define IDC_CNTLIST 1221
@@ -495,6 +542,7 @@ #define IDC_O_STATIC_OWNAVATAR 1502
#define IDC_USEAERO 1531
#define IDC_USEAEROPEEK 1532
+#define IDC_WHITERECT 1600
#define IDC_O_EXPLAINGLOBALNOTIFY 1624
#define IDC_O_AUTOHIDE 1625
#define IDC_O_AUTOHIDESECONDS 1626
@@ -511,8 +559,66 @@ #define IDC_OPTIONSTAB 2111
#define IDC_HEADERBAR 2397
#define IDC_AVATARSONTASKBAR 2735
+#define IDC_SRMM_COLOR 3001
+#define IDC_SRMM_BKGCOLOR 3002
+#define IDC_SRMM_BOLD 3003
+#define IDC_SRMM_ITALICS 3004
+#define IDC_SRMM_UNDERLINE 3005
+#define IDC_SRMM_FILTER 3006
+#define IDC_SRMM_CHANMGR 3007
+#define IDC_SRMM_SHOWNICKLIST 3008
+#define IDC_SRMM_HISTORY 3009
+#define IDC_SRMM_NICKLIST 3010
+#define IDC_SRMM_LOG 3011
+#define IDC_SRMM_MESSAGE 3012
#define IDC_TSLABEL_EXPLAINTHEME 3123
#define IDC_TSLABEL_REOPENWARN 3124
+#define IDC_1 4200
+#define IDC_2 4201
+#define IDC_3 4202
+#define IDC_4 4203
+#define IDC_5 4204
+#define IDC_6 4205
+#define IDC_7 4206
+#define IDC_8 4207
+#define IDC_9 4208
+#define IDC_10 4209
+#define IDC_11 4210
+#define IDC_P1 4300
+#define IDC_P2 4301
+#define IDC_P3 4302
+#define IDC_P4 4303
+#define IDC_P5 4304
+#define IDC_P6 4305
+#define IDC_P7 4306
+#define IDC_P8 4307
+#define IDC_P9 4308
+#define IDC_P10 4309
+#define IDC_P11 4310
+#define IDC_P12 4311
+#define IDC_T1 4400
+#define IDC_T2 4401
+#define IDC_T3 4402
+#define IDC_T4 4403
+#define IDC_T5 4404
+#define IDC_T6 4405
+#define IDC_T7 4406
+#define IDC_T8 4407
+#define IDC_T9 4408
+#define IDC_T10 4409
+#define IDC_T11 4410
+#define IDC_T12 4411
+#define IDC_L1 4500
+#define IDC_L2 4501
+#define IDC_L3 4502
+#define IDC_L4 4503
+#define IDC_L5 4504
+#define IDC_L6 4505
+#define IDC_L7 4506
+#define IDC_L8 4507
+#define IDC_L9 4508
+#define IDC_L10 4509
+#define IDC_L11 4510
#define IDD_OPT_TYPINGNOTIFYPOPUP 30159
#define IDI_START1 30160
#define IDI_STOP1 30161
@@ -563,10 +669,29 @@ #define IDC_ICONS 31623
#define IDC_TIMEOUT_VALUE2 31624
#define IDC_PREVIEW_ALL 31625
+#define ID_MESS 40001
+#define ID_NEW 40002
+#define ID_CURR 40003
+#define ID_COPY 40004
+#define ID_COPYALL 40006
+#define ID_CLEARLOG 40009
+#define ID_MESSAGE_UNDO 40013
+#define ID_MESSAGE_COPY 40014
+#define ID_MESSAGE_CUT 40015
+#define ID_MESSAGE_CLEAR 40017
+#define ID_MESSAGE_SELECTALL 40018
+#define ID_MESSAGE_REDO 40019
+#define ID_MESSAGE_PASTE 40020
+#define ID_CLOSE 40022
+#define ID_CLOSEOTHER 40023
+#define ID_LOCKPOSITION 40024
#define ID_CLOSETAB_DETACHTAB 40025
#define ID_TABCONTEXT_NEXTTAB 40026
+#define ID_SEARCH_GOOGLE 40027
#define ID_TABCONTEXT_ATTACH 40027
+#define ID_SEARCH_WIKIPEDIA 40028
#define ID_TABCONTEXT_CLOSECONTAINER 40028
+#define ID_WIKIPEDIA_ 40029
#define ID_TABCONTEXT_PREVTAB 40029
#define ID_CLOSETAB 40030
#define ID_TABMENU_CLOSETAB 40031
@@ -706,7 +831,7 @@ //
#ifdef APSTUDIO_INVOKED
#ifndef APSTUDIO_READONLY_SYMBOLS
-#define _APS_NEXT_RESOURCE_VALUE 103
+#define _APS_NEXT_RESOURCE_VALUE 104
#define _APS_NEXT_COMMAND_VALUE 40001
#define _APS_NEXT_CONTROL_VALUE 1000
#define _APS_NEXT_SYMED_VALUE 101
diff --git a/src/core/stdmsg/src/chat_options.cpp b/src/core/stdmsg/src/chat_options.cpp index d7fb376c39..c047169cd9 100644 --- a/src/core/stdmsg/src/chat_options.cpp +++ b/src/core/stdmsg/src/chat_options.cpp @@ -53,20 +53,6 @@ static branch_t branch2[] = { { LPGENW("Enable the 'event filter' for new rooms"), "FilterEnabled", 0, 0 } }; -static branch_t branch3[] = { - { LPGENW("Show topic changes"), "FilterFlags", GC_EVENT_TOPIC, false }, - { LPGENW("Show users joining"), "FilterFlags", GC_EVENT_JOIN, false }, - { LPGENW("Show users disconnecting"), "FilterFlags", GC_EVENT_QUIT, false }, - { LPGENW("Show messages"), "FilterFlags", GC_EVENT_MESSAGE, true }, - { LPGENW("Show actions"), "FilterFlags", GC_EVENT_ACTION, true }, - { LPGENW("Show users leaving"), "FilterFlags", GC_EVENT_PART, false }, - { LPGENW("Show users being kicked"), "FilterFlags", GC_EVENT_KICK, true }, - { LPGENW("Show notices"), "FilterFlags", GC_EVENT_NOTICE, true }, - { LPGENW("Show users changing name"), "FilterFlags", GC_EVENT_NICK, false }, - { LPGENW("Show information messages"), "FilterFlags", GC_EVENT_INFORMATION, true }, - { LPGENW("Show status changes of users"), "FilterFlags", GC_EVENT_ADDSTATUS, false }, -}; - static branch_t branch4[] = { { LPGENW("Show icon for topic changes"), "IconFlags", GC_EVENT_TOPIC, false }, { LPGENW("Show icon for users joining"), "IconFlags", GC_EVENT_JOIN, true }, @@ -82,38 +68,6 @@ static branch_t branch4[] = { { LPGENW("Show icon for status changes"), "IconFlags", GC_EVENT_ADDSTATUS, false }, }; -static branch_t branch5[] = { - { LPGENW("Show icons in tray only when the chat room is not active"), "TrayIconInactiveOnly", 0, true }, - { LPGENW("Show icon in tray for topic changes"), "TrayIconFlags", GC_EVENT_TOPIC, false }, - { LPGENW("Show icon in tray for users joining"), "TrayIconFlags", GC_EVENT_JOIN, false }, - { LPGENW("Show icon in tray for users disconnecting"), "TrayIconFlags", GC_EVENT_QUIT, false }, - { LPGENW("Show icon in tray for messages"), "TrayIconFlags", GC_EVENT_MESSAGE, false }, - { LPGENW("Show icon in tray for actions"), "TrayIconFlags", GC_EVENT_ACTION, false }, - { LPGENW("Show icon in tray for highlights"), "TrayIconFlags", GC_EVENT_HIGHLIGHT, true }, - { LPGENW("Show icon in tray for users leaving"), "TrayIconFlags", GC_EVENT_PART, false }, - { LPGENW("Show icon in tray for users kicking other user"), "TrayIconFlags", GC_EVENT_KICK, false }, - { LPGENW("Show icon in tray for notices"), "TrayIconFlags", GC_EVENT_NOTICE, false }, - { LPGENW("Show icon in tray for name changes"), "TrayIconFlags", GC_EVENT_NICK, false }, - { LPGENW("Show icon in tray for information messages"), "TrayIconFlags", GC_EVENT_INFORMATION, false }, - { LPGENW("Show icon in tray for status changes"), "TrayIconFlags", GC_EVENT_ADDSTATUS, false }, -}; - -static branch_t branch6[] = { - { LPGENW("Show popups only when the chat room is not active"), "PopupInactiveOnly", 0, true }, - { LPGENW("Show popup for topic changes"), "PopupFlags", GC_EVENT_TOPIC, false }, - { LPGENW("Show popup for users joining"), "PopupFlags", GC_EVENT_JOIN, false }, - { LPGENW("Show popup for users disconnecting"), "PopupFlags", GC_EVENT_QUIT, false }, - { LPGENW("Show popup for messages"), "PopupFlags", GC_EVENT_MESSAGE, false }, - { LPGENW("Show popup for actions"), "PopupFlags", GC_EVENT_ACTION, false }, - { LPGENW("Show popup for highlights"), "PopupFlags", GC_EVENT_HIGHLIGHT, false }, - { LPGENW("Show popup for users leaving"), "PopupFlags", GC_EVENT_PART, false }, - { LPGENW("Show popup for users kicking other user"), "PopupFlags", GC_EVENT_KICK, false }, - { LPGENW("Show popup for notices"), "PopupFlags", GC_EVENT_NOTICE, false }, - { LPGENW("Show popup for name changes"), "PopupFlags", GC_EVENT_NICK, false }, - { LPGENW("Show popup for information messages"), "PopupFlags", GC_EVENT_INFORMATION, false }, - { LPGENW("Show popup for status changes"), "PopupFlags", GC_EVENT_ADDSTATUS, false }, -}; - static INT CALLBACK BrowseCallbackProc(HWND hwnd, UINT uMsg, LPARAM lp, LPARAM pData) { wchar_t szDir[MAX_PATH]; @@ -187,7 +141,7 @@ void AddIcons(void) class COptMainDlg : public CDlgBase { - HTREEITEM hListHeading1, hListHeading2, hListHeading3, hListHeading4, hListHeading5, hListHeading6 = 0; + HTREEITEM hListHeading1, hListHeading2, hListHeading4; CCtrlTreeView checkBoxes; @@ -299,10 +253,7 @@ class COptMainDlg : public CDlgBase { CheckHeading(hListHeading1); CheckHeading(hListHeading2); - CheckHeading(hListHeading3); CheckHeading(hListHeading4); - CheckHeading(hListHeading5); - CheckHeading(hListHeading6); } public: @@ -319,17 +270,11 @@ public: hListHeading1 = InsertBranch(LPGEN("Appearance and functionality of chat room windows"), db_get_b(0, CHAT_MODULE, "Branch1Exp", 0) ? TRUE : FALSE); hListHeading2 = InsertBranch(LPGEN("Appearance of the message log"), db_get_b(0, CHAT_MODULE, "Branch2Exp", 0) ? TRUE : FALSE); - hListHeading3 = InsertBranch(LPGEN("Default events to show in new chat rooms if the 'event filter' is enabled"), db_get_b(0, CHAT_MODULE, "Branch3Exp", 0) ? TRUE : FALSE); hListHeading4 = InsertBranch(LPGEN("Icons to display in the message log"), db_get_b(0, CHAT_MODULE, "Branch4Exp", 0) ? TRUE : FALSE); - hListHeading5 = InsertBranch(LPGEN("Icons to display in the tray"), db_get_b(0, CHAT_MODULE, "Branch5Exp", 0) ? TRUE : FALSE); - hListHeading6 = InsertBranch(LPGEN("Popups to display"), db_get_b(0, CHAT_MODULE, "Branch6Exp", 0) ? TRUE : FALSE); FillBranch(hListHeading1, branch1, _countof(branch1), 0); FillBranch(hListHeading2, branch2, _countof(branch2), 0); - FillBranch(hListHeading3, branch3, _countof(branch3), 0x03E0); FillBranch(hListHeading4, branch4, _countof(branch4), 0x0000); - FillBranch(hListHeading5, branch5, _countof(branch5), 0x1000); - FillBranch(hListHeading6, branch6, _countof(branch6), 0x0000); FixHeadings(); return true; @@ -339,10 +284,7 @@ public: { SaveBranch(branch1, _countof(branch1)); SaveBranch(branch2, _countof(branch2)); - SaveBranch(branch3, _countof(branch3)); SaveBranch(branch4, _countof(branch4)); - SaveBranch(branch5, _countof(branch5)); - SaveBranch(branch6, _countof(branch6)); g_chatApi.ReloadSettings(); Chat_UpdateOptions(); @@ -355,14 +297,8 @@ public: db_set_b(0, CHAT_MODULE, "Branch1Exp", b); b = checkBoxes.GetItemState(hListHeading2, TVIS_EXPANDED) & TVIS_EXPANDED ? 1 : 0; db_set_b(0, CHAT_MODULE, "Branch2Exp", b); - b = checkBoxes.GetItemState(hListHeading3, TVIS_EXPANDED) & TVIS_EXPANDED ? 1 : 0; - db_set_b(0, CHAT_MODULE, "Branch3Exp", b); b = checkBoxes.GetItemState(hListHeading4, TVIS_EXPANDED) & TVIS_EXPANDED ? 1 : 0; db_set_b(0, CHAT_MODULE, "Branch4Exp", b); - b = checkBoxes.GetItemState(hListHeading5, TVIS_EXPANDED) & TVIS_EXPANDED ? 1 : 0; - db_set_b(0, CHAT_MODULE, "Branch5Exp", b); - b = checkBoxes.GetItemState(hListHeading6, TVIS_EXPANDED) & TVIS_EXPANDED ? 1 : 0; - db_set_b(0, CHAT_MODULE, "Branch6Exp", b); } void onChange_Tree(CCtrlTreeView::TEventInfo *evt) @@ -381,14 +317,8 @@ public: CheckBranches(hListHeading1); else if (tvi.hItem == hListHeading2) CheckBranches(hListHeading2); - else if (tvi.hItem == hListHeading3) - CheckBranches(hListHeading3); else if (tvi.hItem == hListHeading4) CheckBranches(hListHeading4); - else if (tvi.hItem == hListHeading5) - CheckBranches(hListHeading5); - else if (tvi.hItem == hListHeading6) - CheckBranches(hListHeading6); else FixHeadings(); } diff --git a/src/mir_app/mir_app.vcxproj b/src/mir_app/mir_app.vcxproj index 3c7ca84a6f..c054553f42 100644 --- a/src/mir_app/mir_app.vcxproj +++ b/src/mir_app/mir_app.vcxproj @@ -36,6 +36,7 @@ <ClCompile Include="src\chat_rtf.cpp" />
<ClCompile Include="src\chat_svc.cpp" />
<ClCompile Include="src\chat_tools.cpp" />
+ <ClCompile Include="src\chat_ui.cpp" />
<ClCompile Include="src\clc.cpp" />
<ClCompile Include="src\clcfiledrop.cpp" />
<ClCompile Include="src\clcidents.cpp" />
@@ -207,7 +208,97 @@ <ResourceCompile Include="res\version.rc" />
</ItemGroup>
<ItemGroup>
+ <None Include="res\cursor_drag_copy.cur" />
+ <None Include="res\cursor_drop_user.cur" />
+ <None Include="res\cursor_hyperlink.cur" />
<None Include="src\mir_app.def" />
<None Include="src\mir_app64.def" />
</ItemGroup>
+ <ItemGroup>
+ <Text Include="..\docs\contributors.txt" />
+ </ItemGroup>
+ <ItemGroup>
+ <Image Include="res\addgroup.ico" />
+ <Image Include="res\always_visible.ico" />
+ <Image Include="res\auth_add.ico" />
+ <Image Include="res\auth_grant.ico" />
+ <Image Include="res\auth_request.ico" />
+ <Image Include="res\auth_revoke.ico" />
+ <Image Include="res\chat_channel.ico" />
+ <Image Include="res\chat_join.ico" />
+ <Image Include="res\chat_leave.ico" />
+ <Image Include="res\check_off.ico" />
+ <Image Include="res\check_on.ico" />
+ <Image Include="res\contact_add.ico" />
+ <Image Include="res\contact_delete.ico" />
+ <Image Include="res\contact_groups.ico" />
+ <Image Include="res\contact_rename.ico" />
+ <Image Include="res\contact_view_details.ico" />
+ <Image Include="res\female.ico" />
+ <Image Include="res\group_closed.ico" />
+ <Image Include="res\group_opened.ico" />
+ <Image Include="res\icon_accmgr.ico" />
+ <Image Include="res\icon_all.ico" />
+ <Image Include="res\icon_ansi.ico" />
+ <Image Include="res\icon_auth_request.ico" />
+ <Image Include="res\icon_connecting.ico" />
+ <Image Include="res\icon_down_arrow.ico" />
+ <Image Include="res\icon_error.ico" />
+ <Image Include="res\Icon_exit.ico" />
+ <Image Include="res\icon_fatal.ico" />
+ <Image Include="res\icon_file.ico" />
+ <Image Include="res\icon_find_user.ico" />
+ <Image Include="res\icon_frame.ico" />
+ <Image Include="res\icon_help.ico" />
+ <Image Include="res\icon_history.ico" />
+ <Image Include="res\icon_loaded_gray.ico" />
+ <Image Include="res\icon_mail.ico" />
+ <Image Include="res\icon_mainmenu.ico" />
+ <Image Include="res\icon_message.ico" />
+ <Image Include="res\icon_notify.ico" />
+ <Image Include="res\icon_notloaded.ico" />
+ <Image Include="res\icon_notloaded_gray.ico" />
+ <Image Include="res\icon_options.ico" />
+ <Image Include="res\icon_password.ico" />
+ <Image Include="res\icon_popup.ico" />
+ <Image Include="res\icon_popup_no.ico" />
+ <Image Include="res\icon_search_all.ico" />
+ <Image Include="res\Icon_show_hide.ico" />
+ <Image Include="res\icon_small_dot.ico" />
+ <Image Include="res\icon_sms.ico" />
+ <Image Include="res\icon_typing.ico" />
+ <Image Include="res\icon_undo.ico" />
+ <Image Include="res\icon_unicode.ico" />
+ <Image Include="res\icon_url.ico" />
+ <Image Include="res\icon_warning.ico" />
+ <Image Include="res\icon_window.ico" />
+ <Image Include="res\icon_windows.ico" />
+ <Image Include="res\male.ico" />
+ <Image Include="res\meta_add.ico" />
+ <Image Include="res\meta_convert.ico" />
+ <Image Include="res\meta_edit.ico" />
+ <Image Include="res\meta_menu.ico" />
+ <Image Include="res\meta_menuof.ico" />
+ <Image Include="res\meta_remove2.ico" />
+ <Image Include="res\meta_set_as_default.ico" />
+ <Image Include="res\miranda_home.ico" />
+ <Image Include="res\miranda_logo.ico" />
+ <Image Include="res\miranda_manager.ico" />
+ <Image Include="res\never_visible.ico" />
+ <Image Include="res\Off.ico" />
+ <Image Include="res\On.ico" />
+ <Image Include="res\status_away.ico" />
+ <Image Include="res\status_DND.ico" />
+ <Image Include="res\status_free4chat.ico" />
+ <Image Include="res\status_invisible.ico" />
+ <Image Include="res\status_locked.ico" />
+ <Image Include="res\status_NA.ico" />
+ <Image Include="res\status_occupied.ico" />
+ <Image Include="res\status_offline.ico" />
+ <Image Include="res\status_online.ico" />
+ <Image Include="res\status_on_the_phone.ico" />
+ <Image Include="res\status_out2lunch.ico" />
+ <Image Include="res\status_user_online.ico" />
+ <Image Include="res\_blank.ico" />
+ </ItemGroup>
</Project>
\ No newline at end of file diff --git a/src/mir_app/mir_app.vcxproj.filters b/src/mir_app/mir_app.vcxproj.filters index 8dbf493879..0d94a10dcc 100644 --- a/src/mir_app/mir_app.vcxproj.filters +++ b/src/mir_app/mir_app.vcxproj.filters @@ -386,6 +386,9 @@ <ClCompile Include="src\proto_interface.cpp">
<Filter>Source Files</Filter>
</ClCompile>
+ <ClCompile Include="src\chat_ui.cpp">
+ <Filter>Source Files</Filter>
+ </ClCompile>
</ItemGroup>
<ItemGroup>
<ClInclude Include="src\chat.h">
@@ -460,5 +463,265 @@ <ItemGroup>
<None Include="src\mir_app.def" />
<None Include="src\mir_app64.def" />
+ <None Include="res\cursor_hyperlink.cur">
+ <Filter>Resource Files</Filter>
+ </None>
+ <None Include="res\cursor_drag_copy.cur">
+ <Filter>Resource Files</Filter>
+ </None>
+ <None Include="res\cursor_drop_user.cur">
+ <Filter>Resource Files</Filter>
+ </None>
+ </ItemGroup>
+ <ItemGroup>
+ <Text Include="..\docs\contributors.txt" />
+ </ItemGroup>
+ <ItemGroup>
+ <Image Include="res\miranda_logo.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\miranda_home.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\miranda_manager.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\contact_view_details.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\contact_add.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\contact_rename.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\contact_delete.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\group_closed.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\group_opened.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\status_user_online.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\status_online.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\status_away.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\status_NA.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\status_occupied.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\status_DND.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\status_free4chat.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\status_invisible.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\status_on_the_phone.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\status_out2lunch.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\status_offline.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\icon_connecting.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\icon_typing.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\icon_find_user.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\icon_search_all.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\icon_options.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\icon_accmgr.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\icon_mainmenu.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\icon_help.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\icon_message.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\icon_file.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\icon_history.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\icon_url.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\icon_sms.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\icon_mail.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\icon_small_dot.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\icon_auth_request.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\icon_all.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\icon_down_arrow.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\check_off.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\check_on.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\icon_unicode.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\icon_ansi.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\icon_loaded_gray.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\icon_notloaded.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\icon_notloaded_gray.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\icon_frame.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\icon_fatal.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\icon_error.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\icon_warning.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\icon_notify.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\_blank.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\icon_undo.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\icon_window.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\icon_windows.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\chat_join.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\chat_leave.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\status_locked.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\Icon_show_hide.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\Icon_exit.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\contact_groups.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\On.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\Off.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\always_visible.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\never_visible.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\chat_channel.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\male.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\female.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\auth_add.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\auth_grant.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\auth_request.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\auth_revoke.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\meta_menu.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\meta_menuof.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\meta_edit.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\meta_remove2.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\meta_convert.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\meta_add.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\meta_set_as_default.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\addgroup.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\icon_popup.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\icon_popup_no.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
+ <Image Include="res\icon_password.ico">
+ <Filter>Resource Files</Filter>
+ </Image>
</ItemGroup>
</Project>
\ No newline at end of file diff --git a/src/mir_app/res/resource.rc b/src/mir_app/res/resource.rc index 1a3e54ef0b..8a5b27754c 100644 --- a/src/mir_app/res/resource.rc +++ b/src/mir_app/res/resource.rc @@ -791,8 +791,84 @@ BEGIN CONTROL "",IDC_HIDEOFFLINEOPTS,"SysTreeView32",TVS_DISABLEDRAGDROP | TVS_NOTOOLTIPS | TVS_NONEVENHEIGHT | WS_BORDER | WS_HSCROLL | WS_TABSTOP,183,24,105,104
END
+IDD_OPT_CHAT_EVENTS DIALOGEX 0, 0, 306, 194
+STYLE DS_SETFONT | DS_FIXEDSYS | WS_CHILD
+EXSTYLE WS_EX_CONTROLPARENT
+FONT 8, "MS Shell Dlg", 0, 0, 0x1
+BEGIN
+ GROUPBOX "Default settings for known event types",IDC_STATIC,7,5,293,153
+ LTEXT "Show when filter is active",IDC_STATIC,12,16,119,8,SS_CENTERIMAGE
+ CTEXT "Log to file",IDC_STATIC,260,16,37,8,SS_CENTERIMAGE
+ CTEXT "Popup",IDC_STATIC,142,16,31,8,SS_CENTERIMAGE
+ CTEXT "Tray",IDC_STATIC,181,16,31,8,SS_CENTERIMAGE
+ CTEXT "Sound",IDC_STATIC,221,16,31,8,SS_CENTERIMAGE
+ CONTROL "Actions",IDC_1,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,22,28,120,10
+ CONTROL "Messages",IDC_2,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,22,38,120,10
+ CONTROL "Nick changes",IDC_3,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,22,48,120,10
+ CONTROL "Users joining",IDC_4,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,22,58,120,10
+ CONTROL "Users leaving",IDC_5,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,22,68,120,10
+ CONTROL "Topic changes",IDC_6,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,22,78,120,10
+ CONTROL "Status changes",IDC_7,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,22,88,120,10
+ CONTROL "Information",IDC_8,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,22,98,120,10
+ CONTROL "Disconnects",IDC_9,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,22,108,120,10
+ CONTROL "User kicks",IDC_10,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,22,118,120,10
+ CONTROL "Notices",IDC_11,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,22,128,120,10
+ CONTROL "",IDC_P1,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,153,28,21,10
+ CONTROL "",IDC_P2,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,153,38,21,10
+ CONTROL "",IDC_P3,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,153,48,21,10
+ CONTROL "",IDC_P4,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,153,58,21,10
+ CONTROL "",IDC_P5,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,153,68,21,10
+ CONTROL "",IDC_P6,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,153,78,21,10
+ CONTROL "",IDC_P7,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,153,88,21,10
+ CONTROL "",IDC_P8,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,153,98,21,10
+ CONTROL "",IDC_P9,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,153,108,21,10
+ CONTROL "",IDC_P10,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,153,118,21,10
+ CONTROL "",IDC_P11,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,153,128,21,10
+ CONTROL "",IDC_P12,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,153,138,21,10
+ CONTROL "",IDC_T1,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,193,28,21,10
+ CONTROL "",IDC_T2,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,193,38,21,10
+ CONTROL "",IDC_T3,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,193,48,21,10
+ CONTROL "",IDC_T4,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,193,58,21,10
+ CONTROL "",IDC_T5,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,193,68,21,10
+ CONTROL "",IDC_T6,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,193,78,21,10
+ CONTROL "",IDC_T7,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,193,88,21,10
+ CONTROL "",IDC_T8,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,193,98,21,10
+ CONTROL "",IDC_T9,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,193,108,21,10
+ CONTROL "",IDC_T10,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,193,118,21,10
+ CONTROL "",IDC_T11,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,193,128,21,10
+ CONTROL "",IDC_T12,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,193,138,21,10
+ CONTROL "",IDC_S1,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,233,28,21,10
+ CONTROL "",IDC_S2,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,233,38,21,10
+ CONTROL "",IDC_S3,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,233,48,21,10
+ CONTROL "",IDC_S4,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,233,58,21,10
+ CONTROL "",IDC_S5,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,233,68,21,10
+ CONTROL "",IDC_S6,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,233,78,21,10
+ CONTROL "",IDC_S7,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,233,88,21,10
+ CONTROL "",IDC_S8,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,233,98,21,10
+ CONTROL "",IDC_S9,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,233,108,21,10
+ CONTROL "",IDC_S10,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,233,118,21,10
+ CONTROL "",IDC_S11,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,233,128,21,10
+ CONTROL "",IDC_S12,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,233,138,21,10
+ CONTROL "",IDC_L1,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,274,28,21,10
+ CONTROL "",IDC_L2,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,274,38,21,10
+ CONTROL "",IDC_L3,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,274,48,21,10
+ CONTROL "",IDC_L4,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,274,58,21,10
+ CONTROL "",IDC_L5,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,274,68,21,10
+ CONTROL "",IDC_L6,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,274,78,21,10
+ CONTROL "",IDC_L7,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,274,88,21,10
+ CONTROL "",IDC_L8,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,274,98,21,10
+ CONTROL "",IDC_L9,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,274,108,21,10
+ CONTROL "",IDC_L10,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,274,118,21,10
+ CONTROL "",IDC_L11,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,274,128,21,10
+ CONTROL "Show icons in tray only when the chat room is not active",IDC_TRAYONLYFORINACTIVE,
+ "Button",BS_AUTOCHECKBOX | WS_TABSTOP,13,164,279,8
+ LTEXT "Highlight event",IDC_STATIC,42,139,100,12
+ CONTROL "Show popups only when the chat room is not active",IDC_POPUPONLYFORINACTIVE,
+ "Button",BS_AUTOCHECKBOX | WS_TABSTOP,13,176,279,8
+END
+
IDD_EMPTY DIALOGEX 0, 0, 212, 131
-STYLE DS_FIXEDSYS | WS_POPUP
+STYLE DS_FIXEDSYS | WS_POPUP | WS_CAPTION
CAPTION "Hidden window"
BEGIN
END
@@ -1094,6 +1170,10 @@ BEGIN IDD_OPT_CLIST, DIALOG
BEGIN
END
+
+ IDD_OPT_CHAT_EVENTS, DIALOG
+ BEGIN
+ END
END
#endif // APSTUDIO_INVOKED
@@ -1133,6 +1213,7 @@ END IDR_CREDITS TEXT "../../docs/contributors.txt"
+
/////////////////////////////////////////////////////////////////////////////
//
// Icon
@@ -1141,97 +1222,182 @@ IDR_CREDITS TEXT "../../docs/contributors.txt" // Icon with lowest ID value placed first to ensure application icon
// remains consistent on all systems.
IDI_MIRANDA ICON "miranda_logo.ico"
+
IDI_MIRANDAWEBSITE ICON "miranda_home.ico"
+
IDI_DETAILSLOGO ICON "miranda_manager.ico"
+
IDI_USERDETAILS ICON "contact_view_details.ico"
+
IDI_ADDCONTACT ICON "contact_add.ico"
+
IDI_RENAME ICON "contact_rename.ico"
+
IDI_DELETE ICON "contact_delete.ico"
+
IDI_GROUPSHUT ICON "group_closed.ico"
+
IDI_GROUPOPEN ICON "group_opened.ico"
+
IDI_USERONLINE ICON "status_user_online.ico"
+
IDI_ONLINE ICON "status_online.ico"
+
IDI_AWAY ICON "status_away.ico"
+
IDI_NA ICON "status_NA.ico"
+
IDI_OCCUPIED ICON "status_occupied.ico"
+
IDI_DND ICON "status_DND.ico"
+
IDI_FREE4CHAT ICON "status_free4chat.ico"
+
IDI_INVISIBLE ICON "status_invisible.ico"
+
IDI_ONTHEPHONE ICON "status_on_the_phone.ico"
+
IDI_OUTTOLUNCH ICON "status_out2lunch.ico"
+
IDI_OFFLINE ICON "status_offline.ico"
+
IDI_LOAD ICON "icon_connecting.ico"
+
IDI_TYPING ICON "icon_typing.ico"
+
IDI_FINDUSER ICON "icon_find_user.ico"
+
IDI_SEARCHALL ICON "icon_search_all.ico"
+
IDI_OPTIONS ICON "icon_options.ico"
+
IDI_ACCMGR ICON "icon_accmgr.ico"
+
IDI_MAINMENU ICON "icon_mainmenu.ico"
+
IDI_HELP ICON "icon_help.ico"
+
IDI_RECVMSG ICON "icon_message.ico"
+
IDI_FILE ICON "icon_file.ico"
+
IDI_HISTORY ICON "icon_history.ico"
+
IDI_URL ICON "icon_url.ico"
+
IDI_SMS ICON "icon_sms.ico"
+
IDI_SENDEMAIL ICON "icon_mail.ico"
+
IDI_SMALLDOT ICON "icon_small_dot.ico"
+
IDI_FILLEDBLOB ICON "icon_auth_request.ico"
+
IDI_EMPTYBLOB ICON "icon_all.ico"
+
IDI_DOWNARROW ICON "icon_down_arrow.ico"
+
IDI_NOTICK ICON "check_off.ico"
+
IDI_TICK ICON "check_on.ico"
+
IDI_UNICODE ICON "icon_unicode.ico"
+
IDI_ANSI ICON "icon_ansi.ico"
+
IDI_LOADED_GRAY ICON "icon_loaded_gray.ico"
+
IDI_NOTLOADED ICON "icon_notloaded.ico"
+
IDI_NOTLOADED_GRAY ICON "icon_notloaded_gray.ico"
+
IDI_FRAME ICON "icon_frame.ico"
+
IDI_MFATAL ICON "icon_fatal.ico"
+
IDI_MERROR ICON "icon_error.ico"
+
IDI_MWARNING ICON "icon_warning.ico"
+
IDI_MINFO ICON "icon_notify.ico"
+
IDI_BLANK ICON "_blank.ico"
+
IDI_UNDO ICON "icon_undo.ico"
+
IDI_WINDOW ICON "icon_window.ico"
+
IDI_WINDOWS ICON "icon_windows.ico"
+
IDI_JOINCHAT ICON "chat_join.ico"
+
IDI_LEAVECHAT ICON "chat_leave.ico"
+
IDI_STATUS_LOCKED ICON "status_locked.ico"
+
IDI_SHOWHIDE ICON "Icon_show_hide.ico"
+
IDI_EXIT ICON "Icon_exit.ico"
+
IDI_MOVETOGROUP ICON "contact_groups.ico"
+
IDI_ON ICON "On.ico"
+
IDI_OFF ICON "Off.ico"
+
IDI_ALWAYSVIS ICON "always_visible.ico"
+
IDI_NEVERVIS ICON "never_visible.ico"
+
IDI_CHAT ICON "chat_channel.ico"
+
IDI_MALE ICON "male.ico"
+
IDI_FEMALE ICON "female.ico"
+
IDI_AUTH_ADD ICON "auth_add.ico"
+
IDI_AUTH_GRANT ICON "auth_grant.ico"
+
IDI_AUTH_REQUEST ICON "auth_request.ico"
+
IDI_AUTH_REVOKE ICON "auth_revoke.ico"
+
IDI_MCMENU ICON "meta_menu.ico"
+
IDI_MCMENUOFF ICON "meta_menuof.ico"
+
IDI_MCEDIT ICON "meta_edit.ico"
+
IDI_MCREMOVE ICON "meta_remove2.ico"
+
IDI_MCCONVERT ICON "meta_convert.ico"
+
IDI_MCADD ICON "meta_add.ico"
+
IDI_MCSETDEFAULT ICON "meta_set_as_default.ico"
+
IDI_ADDGROUP ICON "addgroup.ico"
+
IDI_POPUP ICON "icon_popup.ico"
+
IDI_NOPOPUP ICON "icon_popup_no.ico"
+
IDI_PASSWORD ICON "icon_password.ico"
+
/////////////////////////////////////////////////////////////////////////////
//
// Cursor
//
IDC_HYPERLINKHAND CURSOR "cursor_hyperlink.cur"
+
IDC_DROP CURSOR "cursor_drag_copy.cur"
+
IDC_DROPUSER CURSOR "cursor_drop_user.cur"
+
/////////////////////////////////////////////////////////////////////////////
//
// Menu
@@ -1379,6 +1545,11 @@ BEGIN 0
END
+IDD_OPT_CHAT_EVENTS AFX_DIALOG_LAYOUT
+BEGIN
+ 0
+END
+
#endif // English (United States) resources
/////////////////////////////////////////////////////////////////////////////
diff --git a/src/mir_app/src/chat.h b/src/mir_app/src/chat.h index e3fa0461fa..2ac72235f9 100644 --- a/src/mir_app/src/chat.h +++ b/src/mir_app/src/chat.h @@ -43,6 +43,8 @@ extern LIST<SESSION_INFO> g_arSessions; extern MWindowList g_hWindowList;
extern HANDLE hevSendEvent, hevBuildMenuEvent;
+extern CMOption<bool> g_bChatTrayInactive, g_bChatPopupInactive;
+
// log.c
void LoadMsgLogBitmaps(void);
void FreeMsgLogBitmaps(void);
@@ -94,6 +96,8 @@ INT_PTR LeaveChat(WPARAM wParam, LPARAM lParam); int PrebuildContactMenu(WPARAM wParam, LPARAM lParam);
// options.c
+void ChatOptionsInit(WPARAM wParam);
+
int OptionsInit(void);
int OptionsUnInit(void);
void LoadMsgDlgFont(int i, LOGFONT * lf, COLORREF * colour);
diff --git a/src/mir_app/src/chat_opts.cpp b/src/mir_app/src/chat_opts.cpp index 450a1629c7..229f7da5a7 100644 --- a/src/mir_app/src/chat_opts.cpp +++ b/src/mir_app/src/chat_opts.cpp @@ -33,6 +33,7 @@ wchar_t *g_szFontGroup; #define FONTF_BOLD 1
#define FONTF_ITALIC 2
+
struct FontOptionsList
{
LPCTSTR szDescr;
@@ -220,8 +221,8 @@ void LoadGlobalSettings(void) g_Settings->crUserListColor = db_get_dw(0, CHATFONT_MODULE, "Font18Col", RGB(0, 0, 0));
g_Settings->crUserListHeadingsColor = db_get_dw(0, CHATFONT_MODULE, "Font19Col", RGB(170, 170, 170));
g_Settings->bStripFormat = db_get_b(0, CHAT_MODULE, "StripFormatting", 0) != 0;
- g_Settings->bTrayIconInactiveOnly = db_get_b(0, CHAT_MODULE, "TrayIconInactiveOnly", 1) != 0;
- g_Settings->bPopupInactiveOnly = db_get_b(0, CHAT_MODULE, "PopupInactiveOnly", 1) != 0;
+ g_Settings->bTrayIconInactiveOnly = g_bChatTrayInactive;
+ g_Settings->bPopupInactiveOnly = g_bChatPopupInactive;
g_Settings->bAddColonToAutoComplete = db_get_b(0, CHAT_MODULE, "AddColonToAutoComplete", 1) != 0;
g_Settings->iPopupStyle = db_get_b(0, CHAT_MODULE, "PopupStyle", 1);
g_Settings->iPopupTimeout = db_get_w(0, CHAT_MODULE, "PopupTimeout", 3);
diff --git a/src/mir_app/src/chat_tools.cpp b/src/mir_app/src/chat_tools.cpp index d3a190b80b..335ab64cbc 100644 --- a/src/mir_app/src/chat_tools.cpp +++ b/src/mir_app/src/chat_tools.cpp @@ -358,8 +358,9 @@ BOOL DoSoundsFlashPopupTrayStuff(SESSION_INFO *si, GCEVENT *gce, BOOL bHighlight break;
}
- if (szSound && (bInactive || !g_Settings->bSoundsFocus))
- Skin_PlaySound(szSound);
+ if (db_get_dw(0, CHAT_MODULE, "SoundFlags", GC_EVENT_HIGHLIGHT) & iEvent)
+ if (szSound && (bInactive || !g_Settings->bSoundsFocus))
+ Skin_PlaySound(szSound);
}
return TRUE;
diff --git a/src/mir_app/src/chat_ui.cpp b/src/mir_app/src/chat_ui.cpp new file mode 100644 index 0000000000..db2fbeaeee --- /dev/null +++ b/src/mir_app/src/chat_ui.cpp @@ -0,0 +1,119 @@ +/* +Chat module plugin for Miranda IM + +Copyright 2000-12 Miranda IM, 2012-20 Miranda NG team, +all portions of this codebase are copyrighted to the people +listed in contributors.txt. + +This program is free software; you can redistribute it and/or +modify it under the terms of the GNU General Public License +as published by the Free Software Foundation; either version 2 +of the License, or (at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program; if not, write to the Free Software +Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +*/ + +#include "stdafx.h" + +#include "chat.h" + +CMOption<bool> g_bChatPopupInactive(CHAT_MODULE, "PopupInactiveOnly", true); +CMOption<bool> g_bChatTrayInactive(CHAT_MODULE, "TrayIconInactiveOnly", true); + +///////////////////////////////////////////////////////////////////////////////////////// +// Group chat - Events + +#define NR_GC_EVENTS 12 + +static UINT _eventorder[] = +{ + GC_EVENT_ACTION, + GC_EVENT_MESSAGE, + GC_EVENT_NICK, + GC_EVENT_JOIN, + GC_EVENT_PART, + GC_EVENT_TOPIC, + GC_EVENT_ADDSTATUS, + GC_EVENT_INFORMATION, + GC_EVENT_QUIT, + GC_EVENT_KICK, + GC_EVENT_NOTICE, + GC_EVENT_HIGHLIGHT +}; + +class CChatEventOptionDlg : public CDlgBase +{ + CCtrlCheck chkTray, chkPopup; + +public: + CChatEventOptionDlg() : + CDlgBase(g_plugin, IDD_OPT_CHAT_EVENTS), + chkTray(this, IDC_TRAYONLYFORINACTIVE), + chkPopup(this, IDC_POPUPONLYFORINACTIVE) + { + CreateLink(chkTray, g_bChatTrayInactive); + CreateLink(chkPopup, g_bChatPopupInactive); + } + + bool OnInitDialog() override + { + DWORD dwFilterFlags = db_get_dw(0, CHAT_MODULE, "FilterFlags", GC_EVENT_ALL); + DWORD dwTrayFlags = db_get_dw(0, CHAT_MODULE, "TrayIconFlags", GC_EVENT_HIGHLIGHT); + DWORD dwPopupFlags = db_get_dw(0, CHAT_MODULE, "PopupFlags", GC_EVENT_HIGHLIGHT); + DWORD dwSoundFlags = db_get_dw(0, CHAT_MODULE, "SoundFlags", GC_EVENT_HIGHLIGHT); + DWORD dwLogFlags = db_get_dw(0, CHAT_MODULE, "DiskLogFlags", GC_EVENT_ALL); + + for (int i = 0; i < _countof(_eventorder); i++) { + if (_eventorder[i] != GC_EVENT_HIGHLIGHT) { + CheckDlgButton(m_hwnd, IDC_1 + i, dwFilterFlags & _eventorder[i] ? BST_CHECKED : BST_UNCHECKED); + CheckDlgButton(m_hwnd, IDC_L1 + i, dwLogFlags & _eventorder[i] ? BST_CHECKED : BST_UNCHECKED); + } + CheckDlgButton(m_hwnd, IDC_P1 + i, dwPopupFlags & _eventorder[i] ? BST_CHECKED : BST_UNCHECKED); + CheckDlgButton(m_hwnd, IDC_T1 + i, dwTrayFlags & _eventorder[i] ? BST_CHECKED : BST_UNCHECKED); + CheckDlgButton(m_hwnd, IDC_S1 + i, dwSoundFlags & _eventorder[i] ? BST_CHECKED : BST_UNCHECKED); + } + return true; + } + + bool OnApply() override + { + DWORD dwFilterFlags = 0, dwTrayFlags = 0, dwPopupFlags = 0, dwSoundFlags = 0, dwLogFlags = 0; + + for (int i = 0; i < _countof(_eventorder); i++) { + if (_eventorder[i] != GC_EVENT_HIGHLIGHT) { + dwFilterFlags |= (IsDlgButtonChecked(m_hwnd, IDC_1 + i) ? _eventorder[i] : 0); + dwLogFlags |= (IsDlgButtonChecked(m_hwnd, IDC_L1 + i) ? _eventorder[i] : 0); + } + dwSoundFlags |= (IsDlgButtonChecked(m_hwnd, IDC_S1 + i) ? _eventorder[i] : 0); + dwPopupFlags |= (IsDlgButtonChecked(m_hwnd, IDC_P1 + i) ? _eventorder[i] : 0); + dwTrayFlags |= (IsDlgButtonChecked(m_hwnd, IDC_T1 + i) ? _eventorder[i] : 0); + } + db_set_dw(0, CHAT_MODULE, "FilterFlags", dwFilterFlags); + db_set_dw(0, CHAT_MODULE, "PopupFlags", dwPopupFlags); + db_set_dw(0, CHAT_MODULE, "SoundFlags", dwSoundFlags); + db_set_dw(0, CHAT_MODULE, "TrayIconFlags", dwTrayFlags); + db_set_dw(0, CHAT_MODULE, "DiskLogFlags", dwLogFlags); + + LoadGlobalSettings(); + return true; + } +}; + +void ChatOptionsInit(WPARAM wParam) +{ + OPTIONSDIALOGPAGE odp = {}; + odp.flags = ODPF_BOLDGROUPS; + odp.position = 910000000; + odp.szGroup.a = LPGEN("Message sessions"); + odp.szTitle.a = LPGEN("Group chats"); + odp.szTab.a = LPGEN("Events and filters"); + odp.pDialog = new CChatEventOptionDlg(); + g_plugin.addOptions(wParam, &odp); +} diff --git a/src/mir_app/src/resource.h b/src/mir_app/src/resource.h index add1f10211..491cacf3d6 100644 --- a/src/mir_app/src/resource.h +++ b/src/mir_app/src/resource.h @@ -26,6 +26,7 @@ #define IDI_ADDGROUP 117
#define IDD_EMPTY 118
#define IDD_OPT_CLIST 119
+#define IDD_OPT_CHAT_EVENTS 120
#define IDD_AUTHREQ 121
#define IDD_DETAILS 125
#define IDD_HISTORY 127
@@ -214,6 +215,8 @@ #define IDC_SHOWNAMES 1031
#define IDC_ABOUT 1032
#define IDC_MYNOTES 1033
+#define IDC_TRAYONLYFORINACTIVE 1034
+#define IDC_POPUPONLYFORINACTIVE 1035
#define IDC_URLS 1037
#define IDC_COLORTEXT 1038
#define IDC_REPLY 1039
@@ -558,6 +561,64 @@ #define IDC_EFFECT_COLOUR_TEXT1 1853
#define IDC_EFFECT_COLOUR_SPIN1 1854
#define IDC_EXTRAORDER 1889
+#define IDC_1 4200
+#define IDC_2 4201
+#define IDC_3 4202
+#define IDC_4 4203
+#define IDC_5 4204
+#define IDC_6 4205
+#define IDC_7 4206
+#define IDC_8 4207
+#define IDC_9 4208
+#define IDC_10 4209
+#define IDC_11 4210
+#define IDC_P1 4300
+#define IDC_P2 4301
+#define IDC_P3 4302
+#define IDC_P4 4303
+#define IDC_P5 4304
+#define IDC_P6 4305
+#define IDC_P7 4306
+#define IDC_P8 4307
+#define IDC_P9 4308
+#define IDC_P10 4309
+#define IDC_P11 4310
+#define IDC_P12 4311
+#define IDC_T1 4400
+#define IDC_T2 4401
+#define IDC_T3 4402
+#define IDC_T4 4403
+#define IDC_T5 4404
+#define IDC_T6 4405
+#define IDC_T7 4406
+#define IDC_T8 4407
+#define IDC_T9 4408
+#define IDC_T10 4409
+#define IDC_T11 4410
+#define IDC_T12 4411
+#define IDC_L1 4500
+#define IDC_L2 4501
+#define IDC_L3 4502
+#define IDC_L4 4503
+#define IDC_L5 4504
+#define IDC_L6 4505
+#define IDC_L7 4506
+#define IDC_L8 4507
+#define IDC_L9 4508
+#define IDC_L10 4509
+#define IDC_L11 4510
+#define IDC_S1 4600
+#define IDC_S2 4601
+#define IDC_S3 4602
+#define IDC_S4 4603
+#define IDC_S5 4604
+#define IDC_S6 4605
+#define IDC_S7 4606
+#define IDC_S8 4607
+#define IDC_S9 4608
+#define IDC_S10 4609
+#define IDC_S11 4610
+#define IDC_S12 4611
#define IDC_EFFECT_COLOUR_TEXT2 11803
#define IDC_EFFECT_COLOUR_SPIN2 11806
#define IDI_SEARCHALL 32548
@@ -603,7 +664,7 @@ //
#ifdef APSTUDIO_INVOKED
#ifndef APSTUDIO_READONLY_SYMBOLS
-#define _APS_NEXT_RESOURCE_VALUE 331
+#define _APS_NEXT_RESOURCE_VALUE 332
#define _APS_NEXT_COMMAND_VALUE 40018
#define _APS_NEXT_CONTROL_VALUE 1749
#define _APS_NEXT_SYMED_VALUE 101
diff --git a/src/mir_app/src/srmm_toolbar.cpp b/src/mir_app/src/srmm_toolbar.cpp index 5aa899f31b..7b8ecfd5f6 100644 --- a/src/mir_app/src/srmm_toolbar.cpp +++ b/src/mir_app/src/srmm_toolbar.cpp @@ -777,6 +777,7 @@ static int SrmmOptionsInit(WPARAM wParam, LPARAM) odp.pDialog = new CSrmmToolbarOptions(); g_plugin.addOptions(wParam, &odp); + ChatOptionsInit(wParam); SrmmLogOptionsInit(wParam); return 0; } @@ -801,6 +802,8 @@ static void CALLBACK SrmmLoadToolbar() { NotifyEventHooks(hHookToolBarLoadedEvt, 0, 0); DestroyHookableEvent(hHookToolBarLoadedEvt); + + HookEvent(ME_OPT_INITIALISE, SrmmOptionsInit); } static int ConvertToolbarData(const char *szSetting, void*) @@ -817,8 +820,6 @@ void LoadSrmmToolbarModule() { CreateServiceFunction("SRMsg/BroadcastMessage", BroadcastMessage); - HookEvent(ME_OPT_INITIALISE, SrmmOptionsInit); - Miranda_WaitOnHandle(SrmmLoadToolbar); hHookButtonPressedEvt = CreateHookableEvent(ME_MSG_BUTTONPRESSED); |