From 5e686292c537275c8ea1399f311c082d905e8a63 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Wed, 13 Jun 2012 17:26:45 +0000 Subject: code cleaning git-svn-id: http://svn.miranda-ng.org/main/trunk@398 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- src/modules/useronline/useronline.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/modules/useronline/useronline.cpp') diff --git a/src/modules/useronline/useronline.cpp b/src/modules/useronline/useronline.cpp index 543b0c4e95..5fec748a17 100644 --- a/src/modules/useronline/useronline.cpp +++ b/src/modules/useronline/useronline.cpp @@ -29,13 +29,13 @@ static int UserOnlineSettingChanged(WPARAM wParam,LPARAM lParam) DBCONTACTWRITESETTING *cws=(DBCONTACTWRITESETTING*)lParam; int newStatus,oldStatus; - if ((HANDLE)wParam==NULL || strcmp(cws->szSetting,"Status")) return 0; + if ((HANDLE)wParam == NULL || strcmp(cws->szSetting,"Status")) return 0; newStatus=cws->value.wVal; oldStatus=DBGetContactSettingWord((HANDLE)wParam,"UserOnline","OldStatus",ID_STATUS_OFFLINE); DBWriteContactSettingWord((HANDLE)wParam,"UserOnline","OldStatus",(WORD)newStatus); if (CallService(MS_IGNORE_ISIGNORED,wParam,IGNOREEVENT_USERONLINE)) return 0; if (DBGetContactSettingByte((HANDLE)wParam,"CList","Hidden",0)) return 0; - if (newStatus==ID_STATUS_OFFLINE&&oldStatus!=ID_STATUS_OFFLINE) { + if (newStatus == ID_STATUS_OFFLINE&&oldStatus != ID_STATUS_OFFLINE) { // Remove the event from the queue if it exists since they are now offline int lastEvent = (int)DBGetContactSettingDword((HANDLE)wParam,"UserOnline","LastEvent",0); @@ -44,8 +44,8 @@ static int UserOnlineSettingChanged(WPARAM wParam,LPARAM lParam) DBWriteContactSettingDword((HANDLE)wParam,"UserOnline", "LastEvent", 0); } } - if ((newStatus==ID_STATUS_ONLINE || newStatus==ID_STATUS_FREECHAT) && - oldStatus!=ID_STATUS_ONLINE && oldStatus!=ID_STATUS_FREECHAT) { + if ((newStatus == ID_STATUS_ONLINE || newStatus == ID_STATUS_FREECHAT) && + oldStatus != ID_STATUS_ONLINE && oldStatus != ID_STATUS_FREECHAT) { { DWORD ticked = db_dword_get(NULL, "UserOnline", cws->szModule, GetTickCount()); // only play the sound (or show event) if this event happens at least 10 secs after the proto went from offline -- cgit v1.2.3