summaryrefslogtreecommitdiff
path: root/plugins/HistorySweeperLight/src/options.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/HistorySweeperLight/src/options.cpp')
-rw-r--r--plugins/HistorySweeperLight/src/options.cpp17
1 files changed, 6 insertions, 11 deletions
diff --git a/plugins/HistorySweeperLight/src/options.cpp b/plugins/HistorySweeperLight/src/options.cpp
index d77d4946f9..06686fe2d6 100644
--- a/plugins/HistorySweeperLight/src/options.cpp
+++ b/plugins/HistorySweeperLight/src/options.cpp
@@ -102,17 +102,13 @@ void ResetListOptions(HWND hwndList)
static void ShowAllContactIcons(HWND hwndList)
{
- HANDLE hContact, hItem;
-
SendMessage(hwndList, CLM_SETEXTRAIMAGE, (WPARAM)hAllContacts,
MAKELPARAM(0, db_get_b(NULL, ModuleName, "SweepHistory", 0)));
SendMessage(hwndList, CLM_SETEXTRAIMAGE, (WPARAM)hSystemHistory,
MAKELPARAM(0, db_get_b(NULL, ModuleName, "SweepSHistory", 0)));
- for (hContact=db_find_first(); hContact;
- hContact=db_find_next(hContact))
- {
- hItem = (HANDLE)SendMessage(hwndList, CLM_FINDCONTACT, (WPARAM)hContact, 0);
+ for (HANDLE hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) {
+ HANDLE hItem = (HANDLE)SendMessage(hwndList, CLM_FINDCONTACT, (WPARAM)hContact, 0);
SendMessage(hwndList, CLM_SETEXTRAIMAGE, (WPARAM)hItem,
MAKELPARAM(0, db_get_b(hContact, ModuleName, "SweepHistory", 0)));
}
@@ -161,7 +157,8 @@ void LoadSettings(HWND hwndDlg)
void SaveSettings(HWND hwndDlg)
{
- int st, i; StatusIconData sid = {0}; HANDLE hContact, hItem; HWND hwndList = GetDlgItem(hwndDlg, IDC_LIST);
+ int st, i; StatusIconData sid = {0};
+ HWND hwndList = GetDlgItem(hwndDlg, IDC_LIST);
db_set_b(NULL, ModuleName, "StartupShutdownOlder", (BYTE)SendDlgItemMessage(hwndDlg, IDC_SSOLDER, CB_GETCURSEL, 0, 0));
db_set_b(NULL, ModuleName, "StartupShutdownKeep", (BYTE)SendDlgItemMessage(hwndDlg, IDC_SSKEEP, CB_GETCURSEL, 0, 0));
@@ -177,10 +174,8 @@ void SaveSettings(HWND hwndDlg)
db_set_b(NULL, ModuleName, "SweepSHistory",
(BYTE)SendMessage(hwndList, CLM_GETEXTRAIMAGE, (WPARAM)hSystemHistory, 0));
- for (hContact=db_find_first(); hContact;
- hContact=db_find_next(hContact))
- {
- hItem = (HANDLE)SendMessage(hwndList, CLM_FINDCONTACT, (WPARAM)hContact, 0);
+ for (HANDLE hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) {
+ HANDLE hItem = (HANDLE)SendMessage(hwndList, CLM_FINDCONTACT, (WPARAM)hContact, 0);
st = SendMessage(hwndList, CLM_GETEXTRAIMAGE, (WPARAM)hItem, 0);
if ( st != 0 ) db_set_b(hContact, ModuleName, "SweepHistory", (BYTE)st);