summaryrefslogtreecommitdiff
path: root/plugins/Utils/mir_options.cpp
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2013-06-10 13:12:03 +0000
committerGeorge Hazan <george.hazan@gmail.com>2013-06-10 13:12:03 +0000
commitf57abcc041abea72297fa3571cc07e46cf9802cd (patch)
treeb10be66a1891e14b7546799f80995bcb3ee144ae /plugins/Utils/mir_options.cpp
parentf7ebad081fecfe49cbe70948c87d937074461825 (diff)
unused code -> ftopku
git-svn-id: http://svn.miranda-ng.org/main/trunk@4909 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/Utils/mir_options.cpp')
-rw-r--r--plugins/Utils/mir_options.cpp66
1 files changed, 0 insertions, 66 deletions
diff --git a/plugins/Utils/mir_options.cpp b/plugins/Utils/mir_options.cpp
index 5fb8c4b6ad..1e0b5189df 100644
--- a/plugins/Utils/mir_options.cpp
+++ b/plugins/Utils/mir_options.cpp
@@ -134,29 +134,6 @@ static void LoadOpt(OptPageControl *ctrl, char *module)
MyDBGetContactSettingTString(NULL, module, ctrl->setting, ((TCHAR *) ctrl->var), min(ctrl->max <= 0 ? 1024 : ctrl->max, 1024), ctrl->tszDefValue == NULL ? NULL : TranslateTS(ctrl->tszDefValue));
break;
- case CONTROL_PASSWORD:
- {
- char tmp[1024];
- tmp[0]=0;
-
- DBVARIANT dbv = {0};
- if ( !db_get_s(NULL, module, ctrl->setting, &dbv))
- {
- lstrcpynA(tmp, dbv.pszVal, SIZEOF(tmp));
- db_free(&dbv);
- }
-
- if (tmp[0] != 0)
- CallService(MS_DB_CRYPT_DECODESTRING, SIZEOF(tmp), (LPARAM) tmp);
- else if (ctrl->szDefValue != NULL)
- lstrcpynA(tmp, ctrl->szDefValue, SIZEOF(tmp));
-
- char *var = (char *) ctrl->var;
- int size = min(ctrl->max <= 0 ? 1024 : ctrl->max, 1024);
- lstrcpynA(var, tmp, size);
- }
- break;
-
case CONTROL_INT:
*((int *) ctrl->var) = (int) db_get_dw(NULL, module, ctrl->setting, ctrl->dwDefValue);
break;
@@ -270,26 +247,6 @@ INT_PTR CALLBACK SaveOptsDlgProc(OptPageControl *controls, int controlsSize, cha
SendDlgItemMessage(hwndDlg, ctrl->nID, EM_LIMITTEXT, min(ctrl->max <= 0 ? 1024 : ctrl->max, 1024), 0);
}
break;
- case CONTROL_PASSWORD:
- {
- char tmp[1024];
- tmp[0]=0;
-
- DBVARIANT dbv = {0};
- if ( !db_get_s(NULL, module, ctrl->setting, &dbv)) {
- lstrcpynA(tmp, dbv.pszVal, SIZEOF(tmp));
- db_free(&dbv);
- }
-
- if (tmp[0] != 0)
- CallService(MS_DB_CRYPT_DECODESTRING, SIZEOF(tmp), (LPARAM) tmp);
- else if (ctrl->szDefValue != NULL)
- lstrcpynA(tmp, ctrl->szDefValue, SIZEOF(tmp));
-
- SetDlgItemTextA(hwndDlg, ctrl->nID, tmp);
- SendDlgItemMessage(hwndDlg, ctrl->nID, EM_LIMITTEXT, min(ctrl->max <= 0 ? 1024 : ctrl->max, 1024), 0);
- }
- break;
case CONTROL_INT:
{
DWORD var = db_get_dw(NULL, module, ctrl->setting, ctrl->dwDefValue);
@@ -345,7 +302,6 @@ INT_PTR CALLBACK SaveOptsDlgProc(OptPageControl *controls, int controlsSize, cha
case CONTROL_TEXT:
case CONTROL_SPIN:
case CONTROL_INT:
- case CONTROL_PASSWORD:
// Don't make apply enabled during buddy set
if (HIWORD(wParam) != EN_CHANGE || (HWND)lParam != GetFocus())
return 0;
@@ -425,28 +381,6 @@ INT_PTR CALLBACK SaveOptsDlgProc(OptPageControl *controls, int controlsSize, cha
}
break;
- case CONTROL_PASSWORD:
- {
- char tmp[1024];
- GetDlgItemTextA(hwndDlg, ctrl->nID, tmp, SIZEOF(tmp));
-
- if (ctrl->var != NULL) {
- char *var = (char *) ctrl->var;
- int size = min(ctrl->max <= 0 ? 1024 : ctrl->max, 1024);
- lstrcpynA(var, tmp, size);
- }
-
- if (ctrl->checkboxID != 0 && !IsDlgButtonChecked(hwndDlg, ctrl->checkboxID)) {
- db_unset(NULL, module, ctrl->setting);
- continue;
- }
-
- CallService(MS_DB_CRYPT_ENCODESTRING, SIZEOF(tmp), (LPARAM) tmp);
- db_set_s(NULL, module, ctrl->setting, tmp);
-
- // Don't load from DB
- continue;
- }
case CONTROL_INT:
{
BOOL trans;