summaryrefslogtreecommitdiff
path: root/plugins/YAPP
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 /plugins/YAPP
parentce816d83a8c75808e0eb06832592bffefe4a8dc4 (diff)
- code cleaning
git-svn-id: http://svn.miranda-ng.org/main/trunk@270 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/YAPP')
-rw-r--r--plugins/YAPP/message_pump.cpp4
-rw-r--r--plugins/YAPP/options.cpp6
-rw-r--r--plugins/YAPP/popwin.cpp8
-rw-r--r--plugins/YAPP/services.cpp12
4 files changed, 15 insertions, 15 deletions
diff --git a/plugins/YAPP/message_pump.cpp b/plugins/YAPP/message_pump.cpp
index 1d88388002..ff35ade82e 100644
--- a/plugins/YAPP/message_pump.cpp
+++ b/plugins/YAPP/message_pump.cpp
@@ -79,7 +79,7 @@ unsigned __stdcall MessagePumpThread(void* param) {
MSG hwndMsg = {0};
while(GetMessage(&hwndMsg, 0, 0, 0) > 0 && !Miranda_Terminated()) {
- if(!IsDialogMessage(hwndMsg.hwnd, &hwndMsg)) {
+ if (!IsDialogMessage(hwndMsg.hwnd, &hwndMsg)) {
switch(hwndMsg.message) {
case MUM_CREATEPOPUP:
{
@@ -87,7 +87,7 @@ unsigned __stdcall MessagePumpThread(void* param) {
int status = CallService(MS_CLIST_GETSTATUSMODE, 0, 0);
if(status >= ID_STATUS_OFFLINE && status <= ID_STATUS_OUTTOLUNCH && options.disable_status[status - ID_STATUS_OFFLINE])
enabled = false;
- if((options.disable_full_screen && is_full_screen()) || is_workstation_locked())
+ if ((options.disable_full_screen && is_full_screen()) || is_workstation_locked())
enabled = false;
PopupData *pd = (PopupData *)hwndMsg.lParam;
diff --git a/plugins/YAPP/options.cpp b/plugins/YAPP/options.cpp
index f039c0e958..d161234afe 100644
--- a/plugins/YAPP/options.cpp
+++ b/plugins/YAPP/options.cpp
@@ -184,7 +184,7 @@ static INT_PTR CALLBACK DlgProcOpts1(HWND hwndDlg, UINT msg, WPARAM wParam, LPAR
char *strptr;
int i = 0;
- for(; i < 10; i++) {
+ for (; i < 10; i++) {
strptr = (char *)CallService(MS_CLIST_GETSTATUSMODEDESCRIPTION, (WPARAM)(ID_STATUS_OFFLINE + i), (LPARAM)0);
lvI.pszText = mir_a2t(strptr);
lvI.iItem = i;
@@ -290,7 +290,7 @@ static INT_PTR CALLBACK DlgProcOpts1(HWND hwndDlg, UINT msg, WPARAM wParam, LPAR
case LVN_ITEMCHANGED:
{
NMLISTVIEW *nmlv = (NMLISTVIEW *)lParam;
- if((nmlv->uNewState ^ nmlv->uOldState) & LVIS_STATEIMAGEMASK) {
+ if ((nmlv->uNewState ^ nmlv->uOldState) & LVIS_STATEIMAGEMASK) {
SendMessage( GetParent( hwndDlg ), PSM_CHANGED, 0, 0 );
}
}
@@ -340,7 +340,7 @@ static INT_PTR CALLBACK DlgProcOpts1(HWND hwndDlg, UINT msg, WPARAM wParam, LPAR
options.global_hover = IsDlgButtonChecked(hwndDlg, IDC_CHK_GLOBALHOVER) ? true : false;
int i = 0;
- for(; i < 10; i++)
+ for (; i < 10; i++)
options.disable_status[i] = (ListView_GetCheckState(GetDlgItem(hwndDlg, IDC_LST_STATUS), i) == 1);
options.disable_full_screen = (ListView_GetCheckState(GetDlgItem(hwndDlg, IDC_LST_STATUS), i) == 1);
diff --git a/plugins/YAPP/popwin.cpp b/plugins/YAPP/popwin.cpp
index 64ed48c347..85fcc6c92a 100644
--- a/plugins/YAPP/popwin.cpp
+++ b/plugins/YAPP/popwin.cpp
@@ -340,7 +340,7 @@ LRESULT CALLBACK PopupWindowProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lPa
InvalidateRect(hwnd, 0, TRUE);
*/
- if(!IsWindowVisible(hwnd)) {
+ if (!IsWindowVisible(hwnd)) {
ShowWindow(hwnd, SW_SHOWNOACTIVATE);
UpdateWindow(hwnd);
}
@@ -506,7 +506,7 @@ LRESULT CALLBACK PopupWindowProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lPa
// second line(s)
if(pd->pwzText[0]) {
if(hFontSecondLine) SelectObject(ps.hdc, (HGDIOBJ)hFontSecondLine);
- if(!pwd->custom_col)
+ if (!pwd->custom_col)
SetTextColor(ps.hdc, colSecondLine);
// expand text if no avatar and the time isn't too large
@@ -574,7 +574,7 @@ LRESULT CALLBACK PopupWindowProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lPa
SetTimer(hwnd, ID_MOVETIMER, 10, 0);
} else {
SetWindowPos(hwnd, 0, (int)wParam, (int)lParam, 0, 0, SWP_NOZORDER | SWP_NOSIZE | SWP_NOACTIVATE);
- if(!IsWindowVisible(hwnd)) {
+ if (!IsWindowVisible(hwnd)) {
ShowWindow(hwnd, SW_SHOWNOACTIVATE);
UpdateWindow(hwnd);
}
@@ -669,7 +669,7 @@ LRESULT CALLBACK PopupWindowProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lPa
else
*pHeight = max(pwd->tb_height + pwd->text_height + 3 * options.padding, pwd->av_height + 2 * options.av_padding);
- if(*pHeight > options.win_max_height) *pHeight = options.win_max_height;
+ if (*pHeight > options.win_max_height) *pHeight = options.win_max_height;
RECT r;
GetWindowRect(hwnd, &r);
diff --git a/plugins/YAPP/services.cpp b/plugins/YAPP/services.cpp
index 857b814790..751b82387e 100644
--- a/plugins/YAPP/services.cpp
+++ b/plugins/YAPP/services.cpp
@@ -69,7 +69,7 @@ INT_PTR OldCreatePopupA(WPARAM wParam, LPARAM lParam) {
lstPopupHistory.Add(pd_out->pwzTitle, pd_out->pwzText, time(0));
- if(!DBGetContactSettingByte(0, MODULE, "Enabled", 1)) {
+ if (!DBGetContactSettingByte(0, MODULE, "Enabled", 1)) {
mir_free(pd_out->pwzTitle);
mir_free(pd_out->pwzText);
mir_free(pd_out);
@@ -106,7 +106,7 @@ INT_PTR OldCreatePopupExA(WPARAM wParam, LPARAM lParam) {
pd_out->timeout = pd_in->iSeconds;
lstPopupHistory.Add(pd_out->pwzTitle, pd_out->pwzText, time(0));
- if(!DBGetContactSettingByte(0, MODULE, "Enabled", 1)) {
+ if (!DBGetContactSettingByte(0, MODULE, "Enabled", 1)) {
mir_free(pd_out->pwzTitle);
mir_free(pd_out->pwzText);
mir_free(pd_out);
@@ -143,7 +143,7 @@ INT_PTR OldCreatePopupW(WPARAM wParam, LPARAM lParam) {
pd_out->timeout = pd_in->iSeconds;
lstPopupHistory.Add(pd_out->pwzTitle, pd_out->pwzText, time(0));
- if(!DBGetContactSettingByte(0, MODULE, "Enabled", 1)) {
+ if (!DBGetContactSettingByte(0, MODULE, "Enabled", 1)) {
mir_free(pd_out->pwzTitle);
mir_free(pd_out->pwzText);
mir_free(pd_out);
@@ -197,7 +197,7 @@ void ShowPopup(PopupData &pd_in)
lstPopupHistory.Add(pd_out->pwzTitle, pd_out->pwzText, time(0));
- if(!DBGetContactSettingByte(0, MODULE, "Enabled", 1))
+ if (!DBGetContactSettingByte(0, MODULE, "Enabled", 1))
{
mir_free(pd_out->pwzTitle);
mir_free(pd_out->pwzText);
@@ -352,7 +352,7 @@ INT_PTR PopupChangeW(WPARAM wParam, LPARAM lParam) {
}
INT_PTR ShowMessage(WPARAM wParam, LPARAM lParam) {
- if(!DBGetContactSettingByte(0, MODULE, "Enabled", 1)) return 0;
+ if (!DBGetContactSettingByte(0, MODULE, "Enabled", 1)) return 0;
POPUPDATAT pd = {0};
_tcscpy(pd.lptzContactName, lParam == SM_WARNING ? _T("Warning") : _T("Notification"));
@@ -367,7 +367,7 @@ INT_PTR ShowMessage(WPARAM wParam, LPARAM lParam) {
}
INT_PTR ShowMessageW(WPARAM wParam, LPARAM lParam) {
- if(!DBGetContactSettingByte(0, MODULE, "Enabled", 1)) return 0;
+ if (!DBGetContactSettingByte(0, MODULE, "Enabled", 1)) return 0;
POPUPDATAW pd = {0};
wcscpy(pd.lpwzContactName, lParam == SM_WARNING ? L"Warning" : L"Notification");