diff options
author | Kirill Volinsky <mataes2007@gmail.com> | 2013-07-10 18:51:18 +0000 |
---|---|---|
committer | Kirill Volinsky <mataes2007@gmail.com> | 2013-07-10 18:51:18 +0000 |
commit | 343ed18d264ae1b90eda3c64ffb066035997489f (patch) | |
tree | 2bbd32531d86fe385c003e8fc39e584076356f5a /protocols/Skype/src/skype_dialogs.cpp | |
parent | c93ec058116d2c607146d8c2c535d6a706144ec9 (diff) |
options page for privacy settings
git-svn-id: http://svn.miranda-ng.org/main/trunk@5312 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/Skype/src/skype_dialogs.cpp')
-rw-r--r-- | protocols/Skype/src/skype_dialogs.cpp | 81 |
1 files changed, 81 insertions, 0 deletions
diff --git a/protocols/Skype/src/skype_dialogs.cpp b/protocols/Skype/src/skype_dialogs.cpp index 427c924c7f..010e599ec4 100644 --- a/protocols/Skype/src/skype_dialogs.cpp +++ b/protocols/Skype/src/skype_dialogs.cpp @@ -187,6 +187,45 @@ INT_PTR CALLBACK CSkypeProto::SkypeMainOptionsProc(HWND hwnd, UINT message, WPAR return FALSE;
}
+INT_PTR CALLBACK CSkypeProto::SkypePrivacyOptionsProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam)
+{
+ CSkypeProto *ppro = (CSkypeProto *)GetWindowLongPtr(hwndDlg, GWLP_USERDATA);
+
+ switch (msg)
+ {
+ case WM_INITDIALOG:
+ if (lParam)
+ {
+ ppro = (CSkypeProto *)lParam;
+ ::SetWindowLongPtr(hwndDlg, GWLP_USERDATA, lParam);
+
+ ::TranslateDialogDefault(hwndDlg);
+ }
+ break;
+
+ case WM_COMMAND:
+ {
+ switch(LOWORD(wParam))
+ {
+ }
+ }
+ break;
+
+ case WM_NOTIFY:
+ if (reinterpret_cast<NMHDR*>(lParam)->code == PSN_APPLY && !ppro->IsOnline())
+ {
+ return TRUE;
+ }
+ break;
+
+ switch(LOWORD(wParam))
+ {
+ }
+ break;
+ }
+ return FALSE;
+}
+
INT_PTR CALLBACK CSkypeProto::SkypePasswordRequestProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam)
{
PasswordRequestBoxParam *param = reinterpret_cast<PasswordRequestBoxParam *>(::GetWindowLongPtr(hwndDlg, GWLP_USERDATA));
@@ -781,4 +820,46 @@ INT_PTR CALLBACK CSkypeProto::HomeSkypeDlgProc(HWND hwndDlg, UINT msg, WPARAM wP break;
}
return FALSE;
+}
+
+INT_PTR CALLBACK CSkypeProto::AccountSkypeDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam)
+{
+ const unsigned long iPageId = 3;
+ CSkypeProto *ppro = (CSkypeProto *)GetWindowLongPtr(hwndDlg, GWLP_USERDATA);
+
+ switch (msg) {
+ case WM_INITDIALOG:
+ if (lParam) {
+ ppro = (CSkypeProto *)lParam;
+ ::TranslateDialogDefault(hwndDlg);
+
+ ::SetWindowLongPtr(hwndDlg, GWLP_USERDATA, lParam);
+ }
+ break;
+
+ case WM_COMMAND:
+ if (((HWND)lParam == GetFocus() && HIWORD(wParam) == EN_CHANGE))
+ {
+ ppro->NeedUpdate = 1;
+ SendMessage(GetParent(hwndDlg), PSM_CHANGED, 0, 0);
+ }
+ break;
+
+ case WM_NOTIFY:
+ if (((LPNMHDR)lParam)->idFrom == 0) {
+ switch (((LPNMHDR)lParam)->code) {
+ case PSN_PARAMCHANGED:
+ SendMessage(hwndDlg, WM_INITDIALOG, 0, ((PSHNOTIFY *)lParam)->lParam);
+ break;
+ case PSN_APPLY:
+ if (ppro->IsOnline() && ppro->NeedUpdate)
+ ppro->SaveOwnInfoToServer(hwndDlg, iPageId);
+ else if ( !ppro->IsOnline())
+ ppro->ShowNotification(::TranslateT("You are not currently connected to the Skype network. You must be online in order to update your information on the server."));
+ break;
+ }
+ }
+ break;
+ }
+ return FALSE;
}
\ No newline at end of file |