summaryrefslogtreecommitdiff
path: root/protocols/IcqOscarJ
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2012-06-02 20:55:18 +0000
committerGeorge Hazan <george.hazan@gmail.com>2012-06-02 20:55:18 +0000
commit78c0815c4118fe24ab78cce2dc48a6232dcd824a (patch)
tree8512c50df70b8dd80c919e88ade3419207c95956 /protocols/IcqOscarJ
parentce816d83a8c75808e0eb06832592bffefe4a8dc4 (diff)
- code cleaning
git-svn-id: http://svn.miranda-ng.org/main/trunk@270 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/IcqOscarJ')
-rw-r--r--protocols/IcqOscarJ/chan_05ping.cpp2
-rw-r--r--protocols/IcqOscarJ/changeinfo/dlgproc.cpp4
-rw-r--r--protocols/IcqOscarJ/changeinfo/editstring.cpp20
-rw-r--r--protocols/IcqOscarJ/changeinfo/upload.cpp2
-rw-r--r--protocols/IcqOscarJ/i18n.cpp4
-rw-r--r--protocols/IcqOscarJ/icq_direct.cpp2
-rw-r--r--protocols/IcqOscarJ/icq_popups.cpp2
7 files changed, 18 insertions, 18 deletions
diff --git a/protocols/IcqOscarJ/chan_05ping.cpp b/protocols/IcqOscarJ/chan_05ping.cpp
index ac0dc1d87f..d245bd65bf 100644
--- a/protocols/IcqOscarJ/chan_05ping.cpp
+++ b/protocols/IcqOscarJ/chan_05ping.cpp
@@ -53,7 +53,7 @@ void __cdecl CIcqProto::KeepAliveThread(void *arg)
info->hKeepAliveEvent = CreateEvent(NULL, TRUE, FALSE, NULL);
- for(;;)
+ for (;;)
{
DWORD dwWait = ICQWaitForSingleObject(info->hKeepAliveEvent, dwInterval);
if (serverThreadHandle == NULL) // connection lost, end
diff --git a/protocols/IcqOscarJ/changeinfo/dlgproc.cpp b/protocols/IcqOscarJ/changeinfo/dlgproc.cpp
index dd9b9800a8..8d80430f0e 100644
--- a/protocols/IcqOscarJ/changeinfo/dlgproc.cpp
+++ b/protocols/IcqOscarJ/changeinfo/dlgproc.cpp
@@ -427,8 +427,8 @@ INT_PTR CALLBACK ChangeInfoDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM
return TRUE;
}
case NM_KILLFOCUS:
- if(!IsStringEditWindow(GetFocus())) dat->EndStringEdit(1);
- if(!IsListEditWindow(GetFocus())) dat->EndListEdit(1);
+ if (!IsStringEditWindow(GetFocus())) dat->EndStringEdit(1);
+ if (!IsListEditWindow(GetFocus())) dat->EndListEdit(1);
break;
}
break;
diff --git a/protocols/IcqOscarJ/changeinfo/editstring.cpp b/protocols/IcqOscarJ/changeinfo/editstring.cpp
index 1a4d7138c6..f105ac914a 100644
--- a/protocols/IcqOscarJ/changeinfo/editstring.cpp
+++ b/protocols/IcqOscarJ/changeinfo/editstring.cpp
@@ -76,15 +76,15 @@ static void EscapesToMultiline(WCHAR *str,PDWORD selStart,PDWORD selEnd)
static void EscapesToBinary(char *str)
{
- for(;*str;str++)
+ for (;*str;str++)
{
- if(*str!='\\') continue;
+ if (*str!='\\') continue;
if(str[1]=='n') {*str++='\r'; *str='\n'; continue;}
if(str[1]=='0')
{
char *codeend;
*str=(char)strtol(str+1,&codeend,8);
- if(*str==0) {*str='\\'; continue;}
+ if (*str==0) {*str='\\'; continue;}
memmove(str+1,codeend,strlennull(codeend)+1);
continue;
}
@@ -106,9 +106,9 @@ char *BinaryToEscapes(char *str)
char *out,*pout;
out=pout=(char*)SAFE_MALLOC(len);
- for(;*str;str++)
+ for (;*str;str++)
{
- if((unsigned char)*str>=' ')
+ if ((unsigned char)*str>=' ')
{
*pout++=*str;
continue;
@@ -127,7 +127,7 @@ char *BinaryToEscapes(char *str)
}
*pout++='\\';
for(i = 0; i < SIZEOF(escapes); i += 2)
- if(*str==escapes[i+1])
+ if (*str==escapes[i+1])
{
*pout++=escapes[i];
extra--;
@@ -135,7 +135,7 @@ char *BinaryToEscapes(char *str)
}
if(i < SIZEOF(escapes)) continue;
*pout++='0'; extra--;
- if(*str>=8)
+ if (*str>=8)
{
*pout++=(*str>>3)+'0';
extra--;
@@ -218,7 +218,7 @@ static LRESULT CALLBACK ExpandButtonSubclassProc(HWND hwnd,UINT msg,WPARAM wPara
{
DWORD startTime,timeNow;
startTime=GetTickCount();
- for(;;)
+ for (;;)
{
UpdateWindow(hwndEdit);
timeNow=GetTickCount();
@@ -285,7 +285,7 @@ void ChangeInfoData::BeginStringEdit(int iItem, RECT *rc, int i, WORD wVKey)
hwndUpDown=CreateWindow(UPDOWN_CLASS,_T(""),WS_VISIBLE|WS_CHILD|UDS_AUTOBUDDY|UDS_ALIGNRIGHT|UDS_HOTTRACK|UDS_NOTHOUSANDS|UDS_SETBUDDYINT,0,0,0,0,hwndList,NULL,hInst,NULL);
SendMessage(hwndUpDown, UDM_SETRANGE32, range[0], range[1]);
SendMessage(hwndUpDown, UDM_SETPOS32, 0, settingData[i].value);
- if(!(setting[i].displayType & LIF_ZEROISVALID) && settingData[i].value==0)
+ if (!(setting[i].displayType & LIF_ZEROISVALID) && settingData[i].value==0)
SetWindowTextA(hwndEdit, "");
GetClientRect(hwndUpDown, &rcUpDown);
rc->right -= rcUpDown.right;
@@ -306,7 +306,7 @@ void ChangeInfoData::EndStringEdit(int save)
GetWindowTextA(hwndEdit,(char*)text,GetWindowTextLength(hwndEdit)+1);
EscapesToBinary(text);
- if((setting[iEditItem].displayType&LIM_TYPE)==LI_NUMBER)
+ if ((setting[iEditItem].displayType&LIM_TYPE)==LI_NUMBER)
{
LPARAM newValue;
int *range=(int*)setting[iEditItem].pList;
diff --git a/protocols/IcqOscarJ/changeinfo/upload.cpp b/protocols/IcqOscarJ/changeinfo/upload.cpp
index 0f82a87b99..05193e467b 100644
--- a/protocols/IcqOscarJ/changeinfo/upload.cpp
+++ b/protocols/IcqOscarJ/changeinfo/upload.cpp
@@ -40,7 +40,7 @@ int CIcqProto::StringToListItemId(const char *szSetting,int def)
int i;
for(i=0;i<settingCount;i++)
- if(!strcmpnull(szSetting,setting[i].szDbSetting))
+ if (!strcmpnull(szSetting,setting[i].szDbSetting))
break;
if (i==settingCount) return def;
diff --git a/protocols/IcqOscarJ/i18n.cpp b/protocols/IcqOscarJ/i18n.cpp
index afd61d2583..5ebfded9ce 100644
--- a/protocols/IcqOscarJ/i18n.cpp
+++ b/protocols/IcqOscarJ/i18n.cpp
@@ -228,11 +228,11 @@ WCHAR* __stdcall make_unicode_string_static(const char *utf8, WCHAR *unicode, si
while (c)
{
if (out_index + 1 >= unicode_size) break;
- if((c & 0x80) == 0)
+ if ((c & 0x80) == 0)
{
unicode[out_index++] = c;
}
- else if((c & 0xe0) == 0xe0)
+ else if ((c & 0xe0) == 0xe0)
{
unicode[out_index] = (c & 0x1F) << 12;
c = utf8[index++];
diff --git a/protocols/IcqOscarJ/icq_direct.cpp b/protocols/IcqOscarJ/icq_direct.cpp
index 6a81a9b253..55e860adea 100644
--- a/protocols/IcqOscarJ/icq_direct.cpp
+++ b/protocols/IcqOscarJ/icq_direct.cpp
@@ -964,7 +964,7 @@ int DecryptDirectPacket(directconnect* dc, PBYTE buf, WORD wLen)
}
X1 = buf[M1] ^ 0xFF;
- if(((B1 >> 16) & 0xFF) != X1)
+ if (((B1 >> 16) & 0xFF) != X1)
{
return 0;
}
diff --git a/protocols/IcqOscarJ/icq_popups.cpp b/protocols/IcqOscarJ/icq_popups.cpp
index e1cdadada6..3bc1382ef2 100644
--- a/protocols/IcqOscarJ/icq_popups.cpp
+++ b/protocols/IcqOscarJ/icq_popups.cpp
@@ -124,7 +124,7 @@ INT_PTR CALLBACK DlgProcIcqPopupOpts(HWND hwndDlg, UINT msg, WPARAM wParam, LPAR
case IDC_POPUP_LOG2_TIMEOUT:
case IDC_POPUP_LOG3_TIMEOUT:
case IDC_POPUP_SPAM_TIMEOUT:
- if((HIWORD(wParam) == EN_CHANGE) && bInitDone)
+ if ((HIWORD(wParam) == EN_CHANGE) && bInitDone)
SendMessage(GetParent(hwndDlg), PSM_CHANGED, 0, 0);
break;
default: