diff options
author | MikalaiR <nikolay.romanovich@narod.ru> | 2015-04-21 12:04:11 +0000 |
---|---|---|
committer | MikalaiR <nikolay.romanovich@narod.ru> | 2015-04-21 12:04:11 +0000 |
commit | 8e0c5ae195e5af8d8e371b02cbe0e0f99f4a9e29 (patch) | |
tree | d67e36f5119bed3907af8174a986b0089f86ec10 | |
parent | 79d1080c7515ca36601455f5fffcd39f3bd025cf (diff) |
SkypeWeb: Chat creating part 2
git-svn-id: http://svn.miranda-ng.org/main/trunk@13004 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
-rw-r--r-- | protocols/SkypeWeb/res/resource.rc | 9 | ||||
-rw-r--r-- | protocols/SkypeWeb/src/resource.h | 3 | ||||
-rw-r--r-- | protocols/SkypeWeb/src/skype_chatrooms.cpp | 7 | ||||
-rw-r--r-- | protocols/SkypeWeb/src/skype_menus.cpp | 2 | ||||
-rw-r--r-- | protocols/SkypeWeb/src/skype_proto.h | 19 | ||||
-rw-r--r-- | protocols/SkypeWeb/src/skype_utils.cpp | 1 |
6 files changed, 24 insertions, 17 deletions
diff --git a/protocols/SkypeWeb/res/resource.rc b/protocols/SkypeWeb/res/resource.rc index e52911174e..0b71e5b789 100644 --- a/protocols/SkypeWeb/res/resource.rc +++ b/protocols/SkypeWeb/res/resource.rc @@ -69,17 +69,18 @@ END // Dialog
//
-IDD_GC_CREATE DIALOGEX 0, 0, 205, 254
-STYLE DS_SETFONT | DS_MODALFRAME | DS_FIXEDSYS | WS_POPUP | WS_CAPTION | WS_SYSMENU
+IDD_GC_CREATE DIALOGEX 0, 0, 206, 254
+STYLE DS_SETFONT | DS_MODALFRAME | DS_FIXEDSYS | DS_CENTER | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
+EXSTYLE WS_EX_TOPMOST
CAPTION "Create group chat"
FONT 8, "MS Shell Dlg", 400, 0, 0x1
BEGIN
DEFPUSHBUTTON "ОК",IDOK,96,233,50,14
PUSHBUTTON "Cancel",IDCANCEL,148,233,50,14
- CONTROL "Настраиваемый1",IDC_CLIST,"",WS_TABSTOP,7,20,191,122
EDITTEXT IDC_TITLE,7,161,191,61,ES_AUTOHSCROLL | ES_WANTRETURN
CTEXT "New chat's title:",IDC_STATIC,7,148,191,11
CTEXT "Mark users you want to invite to a new chat",IDC_STATIC,7,7,191,8
+ CONTROL "",IDC_CLIST,"CListControl",WS_TABSTOP | 0x1,7,22,192,122,WS_EX_CLIENTEDGE
END
IDD_GC_INVITE DIALOGEX 0, 0, 220, 78
@@ -106,7 +107,7 @@ BEGIN IDD_GC_CREATE, DIALOG
BEGIN
LEFTMARGIN, 7
- RIGHTMARGIN, 198
+ RIGHTMARGIN, 199
TOPMARGIN, 7
BOTTOMMARGIN, 247
END
diff --git a/protocols/SkypeWeb/src/resource.h b/protocols/SkypeWeb/src/resource.h index 4b77d63e7d..b7520ae226 100644 --- a/protocols/SkypeWeb/src/resource.h +++ b/protocols/SkypeWeb/src/resource.h @@ -22,6 +22,7 @@ #define IDC_CLIST 1035
#define IDC_TITLE 1036
#define IDC_CONTACT 1037
+#define IDC_CUSTOM1 1041
// Next default values for new objects
//
@@ -29,7 +30,7 @@ #ifndef APSTUDIO_READONLY_SYMBOLS
#define _APS_NEXT_RESOURCE_VALUE 113
#define _APS_NEXT_COMMAND_VALUE 40001
-#define _APS_NEXT_CONTROL_VALUE 1038
+#define _APS_NEXT_CONTROL_VALUE 1042
#define _APS_NEXT_SYMED_VALUE 101
#endif
#endif
diff --git a/protocols/SkypeWeb/src/skype_chatrooms.cpp b/protocols/SkypeWeb/src/skype_chatrooms.cpp index f2dbe7b229..9b915c81aa 100644 --- a/protocols/SkypeWeb/src/skype_chatrooms.cpp +++ b/protocols/SkypeWeb/src/skype_chatrooms.cpp @@ -571,7 +571,7 @@ INT_PTR CSkypeProto::SvcCreateChat(WPARAM, LPARAM) return 0;
}
-static void FilterContacts(HWND hwndDlg, CSkypeProto *ppro)
+void CSkypeProto::FilterContacts(HWND hwndDlg, CSkypeProto *ppro)
{
HWND hwndClist = GetDlgItem(hwndDlg, IDC_CLIST);
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) {
@@ -582,7 +582,7 @@ static void FilterContacts(HWND hwndDlg, CSkypeProto *ppro) }
}
-static void ResetOptions(HWND hwndDlg)
+void CSkypeProto::ResetOptions(HWND hwndDlg)
{
HWND hwndClist = GetDlgItem(hwndDlg, IDC_CLIST);
SendMessage(hwndClist, CLM_SETHIDEEMPTYGROUPS, 1, 0);
@@ -594,7 +594,8 @@ INT_PTR CSkypeProto::GcCreateDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPAR CSkypeProto *ppro = (CSkypeProto*)GetWindowLongPtr(hwndDlg, GWLP_USERDATA);
NMCLISTCONTROL* nmc;
- switch (msg) {
+ switch (msg)
+ {
case WM_INITDIALOG:
TranslateDialogDefault(hwndDlg);
diff --git a/protocols/SkypeWeb/src/skype_menus.cpp b/protocols/SkypeWeb/src/skype_menus.cpp index 0428bfc9e5..3dce8a1566 100644 --- a/protocols/SkypeWeb/src/skype_menus.cpp +++ b/protocols/SkypeWeb/src/skype_menus.cpp @@ -121,7 +121,7 @@ int CSkypeProto::OnInitStatusMenu() CreateProtoService(tDest, &CSkypeProto::SvcCreateChat);
mi.ptszName = LPGENT("Create new chat");
mi.position = SMI_POSITION + PMI_CREATECHAT;
- mi.icolibItem = GetSkinIconHandle("conference");
+ mi.icolibItem = LoadSkinnedIconHandle(SKINICON_CHAT_JOIN);
Menu_AddProtoMenuItem(&mi);
return 0;
diff --git a/protocols/SkypeWeb/src/skype_proto.h b/protocols/SkypeWeb/src/skype_proto.h index 72e4886223..1d7dd5b491 100644 --- a/protocols/SkypeWeb/src/skype_proto.h +++ b/protocols/SkypeWeb/src/skype_proto.h @@ -185,7 +185,7 @@ private: void LoadContactsAuth(const NETLIBHTTPREQUEST *response);
void LoadContactsInfo(const NETLIBHTTPREQUEST *response);
- void LoadContactList(const NETLIBHTTPREQUEST *response);
+ void LoadContactList (const NETLIBHTTPREQUEST *response);
INT_PTR __cdecl OnRequestAuth(WPARAM hContact, LPARAM lParam);
INT_PTR __cdecl OnGrantAuth(WPARAM hContact, LPARAM);
@@ -219,18 +219,18 @@ private: void InitGroupChatModule();
void CloseAllChatChatSessions();
- MCONTACT FindChatRoom(const char *chatname);
- MCONTACT AddChatRoom(const char *chatname);
+ MCONTACT FindChatRoom (const char *chatname);
+ MCONTACT AddChatRoom (const char *chatname);
int __cdecl OnGroupChatEventHook(WPARAM, LPARAM lParam);
- int __cdecl OnGroupChatMenuHook(WPARAM, LPARAM lParam);
+ int __cdecl OnGroupChatMenuHook (WPARAM, LPARAM lParam);
void StartChatRoom(const TCHAR *tid, const TCHAR *tname);
void OnGetChatInfo(const NETLIBHTTPREQUEST *response);
- INT_PTR __cdecl OnJoinChatRoom(WPARAM hContact, LPARAM);
- INT_PTR __cdecl OnLeaveChatRoom(WPARAM hContact, LPARAM);
+ INT_PTR __cdecl OnJoinChatRoom (WPARAM hContact, LPARAM);
+ INT_PTR __cdecl OnLeaveChatRoom (WPARAM hContact, LPARAM);
void OnChatEvent(JSONNODE *node);
@@ -243,8 +243,11 @@ private: void RenameChat(const char *chat_id, const char *name);
void ChangeChatTopic(const char * chat_id, const char *topic, const char *initiator);
- static INT_PTR __stdcall InviteDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam);
- static INT_PTR __stdcall GcCreateDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam);
+ static INT_PTR CALLBACK InviteDlgProc (HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam);
+ static INT_PTR CALLBACK GcCreateDlgProc (HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam);
+
+ static void ResetOptions(HWND hwndDlg);
+ static void FilterContacts(HWND hwndDlg, CSkypeProto *ppro);
INT_PTR __cdecl SvcCreateChat(WPARAM, LPARAM);
diff --git a/protocols/SkypeWeb/src/skype_utils.cpp b/protocols/SkypeWeb/src/skype_utils.cpp index cbc5086cba..3d0a945004 100644 --- a/protocols/SkypeWeb/src/skype_utils.cpp +++ b/protocols/SkypeWeb/src/skype_utils.cpp @@ -555,6 +555,7 @@ INT_PTR CSkypeProto::ParseSkypeUriService(WPARAM, LPARAM lParam) CallService(MS_MSG_SENDMESSAGE, (WPARAM)hContact, NULL);
return 0;
}
+ else if (szCommand && !_tcsicmp(szCommand, _T("userinfo"))){ return 0;}
return 1; /* parse failed */
}
|