diff options
Diffstat (limited to 'plugins/FingerPrintModPlus')
-rw-r--r-- | plugins/FingerPrintModPlus/src/finger_groups.h | 46 | ||||
-rw-r--r-- | plugins/FingerPrintModPlus/src/fingerprint.cpp | 21 | ||||
-rw-r--r-- | plugins/FingerPrintModPlus/src/global.h | 2 | ||||
-rw-r--r-- | plugins/FingerPrintModPlus/src/options.cpp | 10 | ||||
-rw-r--r-- | plugins/FingerPrintModPlus/src/resource.h | 1 |
5 files changed, 35 insertions, 45 deletions
diff --git a/plugins/FingerPrintModPlus/src/finger_groups.h b/plugins/FingerPrintModPlus/src/finger_groups.h index e125051cd2..75c595a491 100644 --- a/plugins/FingerPrintModPlus/src/finger_groups.h +++ b/plugins/FingerPrintModPlus/src/finger_groups.h @@ -1,93 +1,93 @@ case MIRANDA_CASE:
- if (DBGetContactSettingByte(NULL, "Finger", "GroupMiranda", 1))
+ if ( db_get_b(NULL, "Finger", "GroupMiranda", 1))
return _T("Client Icons/Miranda");
break;
case MULTIPROTOCOL_CASE:
- if (DBGetContactSettingByte(NULL, "Finger", "GroupMulti", 1))
+ if ( db_get_b(NULL, "Finger", "GroupMulti", 1))
return _T("Client Icons/Multi-Protocol");
break;
case ICQ_OFF_CASE:
- if (DBGetContactSettingByte(NULL, "Finger", "GroupIcq", 1))
+ if ( db_get_b(NULL, "Finger", "GroupIcq", 1))
return _T("Client Icons/ICQ/Official");
break;
case ICQ_UNOFF_CASE:
- if (DBGetContactSettingByte(NULL, "Finger", "GroupIcq", 1))
+ if ( db_get_b(NULL, "Finger", "GroupIcq", 1))
return _T("Client Icons/ICQ/Unofficial");
break;
case JABBER_CASE:
- if (DBGetContactSettingByte(NULL, "Finger", "GroupJabber", 1))
+ if ( db_get_b(NULL, "Finger", "GroupJabber", 1))
return _T("Client Icons/Jabber");
break;
case MSN_CASE:
- if (DBGetContactSettingByte(NULL, "Finger", "GroupMsn", 1))
+ if ( db_get_b(NULL, "Finger", "GroupMsn", 1))
return _T("Client Icons/MSN");
break;
case AIM_CASE:
- if (DBGetContactSettingByte(NULL, "Finger", "GroupAim", 1))
+ if ( db_get_b(NULL, "Finger", "GroupAim", 1))
return _T("Client Icons/AIM");
break;
case YAHOO_CASE:
- if (DBGetContactSettingByte(NULL, "Finger", "GroupYahoo", 1))
+ if ( db_get_b(NULL, "Finger", "GroupYahoo", 1))
return _T("Client Icons/Yahoo");
break;
case IRC_CASE:
- if (DBGetContactSettingByte(NULL, "Finger", "GroupIrc", 1))
+ if ( db_get_b(NULL, "Finger", "GroupIrc", 1))
return _T("Client Icons/IRC");
break;
case VOIP_CASE:
- if (DBGetContactSettingByte(NULL, "Finger", "GroupVoIP", 1))
+ if ( db_get_b(NULL, "Finger", "GroupVoIP", 1))
return _T("Client Icons/VoIP");
break;
case SKYPE_CASE:
- if (DBGetContactSettingByte(NULL, "Finger", "GroupSkype", 1))
+ if ( db_get_b(NULL, "Finger", "GroupSkype", 1))
return _T("Client Icons/Skype");
break;
case GADU_CASE:
- if (DBGetContactSettingByte(NULL, "Finger", "GroupGadu", 1))
+ if ( db_get_b(NULL, "Finger", "GroupGadu", 1))
return _T("Client Icons/Gadu-Gadu");
break;
case PACKS_CASE:
- if (DBGetContactSettingByte(NULL, "Finger", "GroupPacks", 1))
+ if ( db_get_b(NULL, "Finger", "GroupPacks", 1))
return _T("Client Icons/Miranda/Pack overlays");
break;
case MRA_CASE:
- if (DBGetContactSettingByte(NULL, "Finger", "GroupMail", 1))
+ if ( db_get_b(NULL, "Finger", "GroupMail", 1))
return _T("Client Icons/Mail.Ru Agent");
break;
case OVER1_CASE:
- if (DBGetContactSettingByte(NULL, "Finger", "GroupMiranda", 1))
+ if ( db_get_b(NULL, "Finger", "GroupMiranda", 1))
return _T("Client Icons/Miranda/Overlays#1");
break;
case SECURITY_CASE:
- if (DBGetContactSettingByte(NULL, "Finger", "GroupOtherProtos", 1))
+ if ( db_get_b(NULL, "Finger", "GroupOtherProtos", 1))
return _T("Client Icons/Overlays/Security");
break;
case OTHER_CASE:
- if (DBGetContactSettingByte(NULL, "Finger", "GroupOtherProtos", 1))
+ if ( db_get_b(NULL, "Finger", "GroupOtherProtos", 1))
return _T("Client Icons/Other");
break;
case OVER2_CASE:
- if (DBGetContactSettingByte(NULL, "Finger", "GroupMiranda", 1))
+ if ( db_get_b(NULL, "Finger", "GroupMiranda", 1))
return _T("Client Icons/Miranda/Overlays#2");
break;
case PLATFORM_CASE:
- if (DBGetContactSettingByte(NULL, "Finger", "GroupOtherProtos", 1))
+ if ( db_get_b(NULL, "Finger", "GroupOtherProtos", 1))
return _T("Client Icons/Overlays/Platform");
break;
case WEATHER_CASE:
- if (DBGetContactSettingByte(NULL, "Finger", "GroupWeather", 1))
+ if ( db_get_b(NULL, "Finger", "GroupWeather", 1))
return _T("Client Icons/Weather");
break;
case RSS_CASE:
- if (DBGetContactSettingByte(NULL, "Finger", "GroupRSS", 1))
+ if ( db_get_b(NULL, "Finger", "GroupRSS", 1))
return _T("Client Icons/RSS");
break;
case QQ_CASE:
- if (DBGetContactSettingByte(NULL, "Finger", "GroupQQ", 1))
+ if ( db_get_b(NULL, "Finger", "GroupQQ", 1))
return _T("Client Icons/QQ");
break;
case TLEN_CASE:
- if (DBGetContactSettingByte(NULL, "Finger", "GroupTlen", 1))
+ if ( db_get_b(NULL, "Finger", "GroupTlen", 1))
return _T("Client Icons/Tlen");
break;
default:
diff --git a/plugins/FingerPrintModPlus/src/fingerprint.cpp b/plugins/FingerPrintModPlus/src/fingerprint.cpp index f89b51374a..7267610ee2 100644 --- a/plugins/FingerPrintModPlus/src/fingerprint.cpp +++ b/plugins/FingerPrintModPlus/src/fingerprint.cpp @@ -21,7 +21,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. //Start of header
#include "global.h"
-static BYTE bColumn = EXTRA_ICON_CLIENT;
static UINT g_LPCodePage;
static TCHAR g_szSkinLib[MAX_PATH];
static HANDLE hExtraIcon = NULL;
@@ -104,12 +103,12 @@ void RegisterIcons() for (i=0; i < DEFAULT_KN_FP_MASK_COUNT; i++)
Prepare(&def_kn_fp_mask[i], true);
- bool bEnable = DBGetContactSettingByte(NULL, "Finger", "Overlay1", 1) != 0;
+ bool bEnable = db_get_b(NULL, "Finger", "Overlay1", 1) != 0;
for (i=0; i < DEFAULT_KN_FP_OVERLAYS_COUNT; i++)
Prepare(&def_kn_fp_overlays_mask[i], bEnable);
- bEnable = DBGetContactSettingByte(NULL, "Finger", "Overlay2", 1) != 0;
- if (DBGetContactSettingByte(NULL, "Finger", "ShowVersion", 0)) {
+ bEnable = db_get_b(NULL, "Finger", "Overlay2", 1) != 0;
+ if ( db_get_b(NULL, "Finger", "ShowVersion", 0)) {
for (i = 0; i < DEFAULT_KN_FP_OVERLAYS2_COUNT; i++)
Prepare(&def_kn_fp_overlays2_mask[i], bEnable);
}
@@ -120,7 +119,7 @@ void RegisterIcons() Prepare(&def_kn_fp_overlays2_mask[i], false);
}
- bEnable = DBGetContactSettingByte(NULL, "Finger", "Overlay3", 1) != 0;
+ bEnable = db_get_b(NULL, "Finger", "Overlay3", 1) != 0;
for (i=0; i < DEFAULT_KN_FP_OVERLAYS3_COUNT; i++)
Prepare(&def_kn_fp_overlays3_mask[i], bEnable);
}
@@ -166,13 +165,11 @@ int FASTCALL ApplyFingerprintImage(HANDLE hContact, LPTSTR szMirVer) if (szMirVer)
hImage = GetIconIndexFromFI(szMirVer);
- if (hExtraIcon != INVALID_HANDLE_VALUE && hExtraIcon != NULL)
- ExtraIcon_SetIcon(hExtraIcon,hContact,hImage);
-
+ ExtraIcon_SetIcon(hExtraIcon,hContact,hImage);
return 0;
}
-int OnExtraIconClick(WPARAM wParam, LPARAM lParam,LPARAM)
+int OnExtraIconClick(WPARAM wParam, LPARAM lParam)
{
CallService(MS_USERINFO_SHOWDIALOG, wParam, NULL);
return 0;
@@ -1020,8 +1017,7 @@ HICON FASTCALL CreateJoinedIcon(HICON hBottom, HICON hTop) DeleteObject(iciTop.hbmMask);
}
- if (!drawn)
- {
+ if (!drawn) {
DrawIconEx(tempDC, 0, 0, hBottom, 16, 16, 0, NULL, DI_NORMAL);
DrawIconEx(tempDC, 0, 0, hTop, 16, 16, 0, NULL, DI_NORMAL);
}
@@ -1098,11 +1094,10 @@ HANDLE FASTCALL GetIconIndexFromFI(LPTSTR szMirVer) return hFoundImage;
}
-VOID FASTCALL ClearFI()
+VOID ClearFI()
{
if (fiList != NULL)
mir_free(fiList);
fiList = NULL;
nFICount = 0;
- return;
}
diff --git a/plugins/FingerPrintModPlus/src/global.h b/plugins/FingerPrintModPlus/src/global.h index f4971c1cee..408b36e07e 100644 --- a/plugins/FingerPrintModPlus/src/global.h +++ b/plugins/FingerPrintModPlus/src/global.h @@ -131,7 +131,7 @@ typedef struct _foundInfo #define DEFAULT_SKIN_FOLDER _T("Icons\\Fp_ClientIcons")
-void FASTCALL ClearFI();
+void ClearFI();
int OnIconsChanged(WPARAM wParam, LPARAM lParam);
int OnExtraIconClick(WPARAM wParam, LPARAM lParam,LPARAM);
diff --git a/plugins/FingerPrintModPlus/src/options.cpp b/plugins/FingerPrintModPlus/src/options.cpp index 8d6378053b..2e710faaff 100644 --- a/plugins/FingerPrintModPlus/src/options.cpp +++ b/plugins/FingerPrintModPlus/src/options.cpp @@ -63,12 +63,12 @@ static void OptDlgChanged(HWND hwndDlg, BOOL show) static void LoadDBCheckState(HWND hwndDlg, int idCtrl, LPCSTR szSetting, BYTE bDef)
{
- CheckDlgButton(hwndDlg, idCtrl, DBGetContactSettingByte(NULL, "Finger", szSetting, bDef));
+ CheckDlgButton(hwndDlg, idCtrl, db_get_b(NULL, "Finger", szSetting, bDef));
}
static void StoreDBCheckState(HWND hwndDlg, int idCtrl, LPCSTR szSetting)
{
- DBWriteContactSettingByte(NULL, "Finger", szSetting, (BYTE)IsDlgButtonChecked(hwndDlg, idCtrl));
+ db_set_b(NULL, "Finger", szSetting, (BYTE)IsDlgButtonChecked(hwndDlg, idCtrl));
}
static INT_PTR CALLBACK DlgProcOptions(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam)
@@ -90,11 +90,6 @@ static INT_PTR CALLBACK DlgProcOptions(HWND hwndDlg, UINT msg, WPARAM wParam, LP case WM_COMMAND:
switch(LOWORD(wParam)) {
- case IDC_ADVICON:
- if (HIWORD(wParam) == CBN_SELCHANGE)
- OptDlgChanged(hwndDlg, true);
- break;
-
case IDC_OVERLAY1:
case IDC_OVERLAY2:
case IDC_OVERLAY3:
@@ -122,6 +117,7 @@ static INT_PTR CALLBACK DlgProcOptions(HWND hwndDlg, UINT msg, WPARAM wParam, LP case IDC_GROUPYAHOO:
OptDlgChanged(hwndDlg, false);
break;
+
default:
return 0;
}
diff --git a/plugins/FingerPrintModPlus/src/resource.h b/plugins/FingerPrintModPlus/src/resource.h index ec5876b447..aeed13978d 100644 --- a/plugins/FingerPrintModPlus/src/resource.h +++ b/plugins/FingerPrintModPlus/src/resource.h @@ -604,7 +604,6 @@ //##############################################################################################################
//resources
#define IDD_DIALOG 10000
-#define IDC_ADVICON 10001
#define IDC_OVERLAY1 10002
#define IDC_OVERLAY2 10003
#define IDC_OVERLAY3 10004
|