diff options
author | George Hazan <ghazan@miranda.im> | 2017-03-09 23:27:40 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2017-03-09 23:27:40 +0300 |
commit | 063a61cf745e1c51f4c9791d03832740f7dc0347 (patch) | |
tree | 960bae1ec8b3869c561cf95e9717c01dd08c735b /protocols/IRCG | |
parent | f3ff9ad5341bb0b0a0453e61a2d419e8c02f14b0 (diff) |
- GCSessionInfoBase fields iWidth and iHeight moved to StdMSg;
- CHAT_MANAGER methods DoEventHook & DoEventHookAsync removed from CHAT_API;
- CSrmmBaseDialog::DoEventHook introduced instead
Diffstat (limited to 'protocols/IRCG')
-rw-r--r-- | protocols/IRCG/src/services.cpp | 60 |
1 files changed, 28 insertions, 32 deletions
diff --git a/protocols/IRCG/src/services.cpp b/protocols/IRCG/src/services.cpp index e60957ab47..28b070caf3 100644 --- a/protocols/IRCG/src/services.cpp +++ b/protocols/IRCG/src/services.cpp @@ -410,14 +410,14 @@ static void DoChatFormatting(wchar_t* pszText) iRemoveChars = 2;
break;
case 'c':
- {
- mir_wstrcpy(InsertThis, L"\003");
- iRemoveChars = 2;
+ {
+ mir_wstrcpy(InsertThis, L"\003");
+ iRemoveChars = 2;
- wchar_t szTemp[3];
- mir_wstrncpy(szTemp, p1 + 2, 3);
- iFG = _wtoi(szTemp);
- }
+ wchar_t szTemp[3];
+ mir_wstrncpy(szTemp, p1 + 2, 3);
+ iFG = _wtoi(szTemp);
+ }
break;
case 'C':
if (p1[2] == '%' && p1[3] == 'F') {
@@ -505,11 +505,7 @@ int __cdecl CIrcProto::GCEventHook(WPARAM, LPARAM lParam) break;
case GC_USER_PRIVMESS:
- {
- wchar_t szTemp[4000];
- mir_snwprintf(szTemp, L"/QUERY %s", gch->ptszUID);
- PostIrcMessageWnd(p1, NULL, szTemp);
- }
+ PostIrcMessageWnd(p1, NULL, CMStringW(FORMAT, L"/QUERY %s", gch->ptszUID));
break;
case GC_USER_LOGMENU:
@@ -544,29 +540,29 @@ int __cdecl CIrcProto::GCEventHook(WPARAM, LPARAM lParam) PostIrcMessage(L"/nickserv DROP");
break;
case 8: // nickserv Identify
- {
- CQuestionDlg* dlg = new CQuestionDlg(this);
- dlg->Show();
- HWND question_hWnd = dlg->GetHwnd();
- HWND hEditCtrl = GetDlgItem(question_hWnd, IDC_EDIT);
- SetDlgItemText(question_hWnd, IDC_CAPTION, TranslateT("Identify nick"));
- SetDlgItemText(question_hWnd, IDC_TEXT, TranslateT("Please enter your password"));
- SetDlgItemText(question_hWnd, IDC_HIDDENEDIT, L"/nickserv IDENTIFY %question=\"%s\",\"%s\"");
- SetWindowLongPtr(GetDlgItem(question_hWnd, IDC_EDIT), GWL_STYLE,
- (LONG)GetWindowLongPtr(GetDlgItem(question_hWnd, IDC_EDIT), GWL_STYLE) | ES_PASSWORD);
- SendMessage(hEditCtrl, EM_SETPASSWORDCHAR, (WPARAM)'*', 0);
- SetFocus(hEditCtrl);
- dlg->Activate();
- }
+ {
+ CQuestionDlg* dlg = new CQuestionDlg(this);
+ dlg->Show();
+ HWND question_hWnd = dlg->GetHwnd();
+ HWND hEditCtrl = GetDlgItem(question_hWnd, IDC_EDIT);
+ SetDlgItemText(question_hWnd, IDC_CAPTION, TranslateT("Identify nick"));
+ SetDlgItemText(question_hWnd, IDC_TEXT, TranslateT("Please enter your password"));
+ SetDlgItemText(question_hWnd, IDC_HIDDENEDIT, L"/nickserv IDENTIFY %question=\"%s\",\"%s\"");
+ SetWindowLongPtr(GetDlgItem(question_hWnd, IDC_EDIT), GWL_STYLE,
+ (LONG)GetWindowLongPtr(GetDlgItem(question_hWnd, IDC_EDIT), GWL_STYLE) | ES_PASSWORD);
+ SendMessage(hEditCtrl, EM_SETPASSWORDCHAR, (WPARAM)'*', 0);
+ SetFocus(hEditCtrl);
+ dlg->Activate();
+ }
break;
case 9: // nickserv remind password
- {
- DBVARIANT dbv;
- if (!getWString("Nick", &dbv)) {
- PostIrcMessage(L"/nickserv SENDPASS %s", dbv.ptszVal);
- db_free(&dbv);
+ {
+ DBVARIANT dbv;
+ if (!getWString("Nick", &dbv)) {
+ PostIrcMessage(L"/nickserv SENDPASS %s", dbv.ptszVal);
+ db_free(&dbv);
+ }
}
- }
break;
case 10: // nickserv set new password
PostIrcMessage(L"/nickserv SET PASSWORD %%question=\"%s\",\"%s\"",
|