summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2014-01-24 21:24:48 +0000
committerGeorge Hazan <george.hazan@gmail.com>2014-01-24 21:24:48 +0000
commit06e18e1c3973b4260ba09072b430196b00e25799 (patch)
tree13ce768a39eb985c0bce704226068b330da55e4e
parente14c5d3a04e44b893b10b8860893fc4e2b675fb8 (diff)
git-svn-id: http://svn.miranda-ng.org/main/trunk@7871 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
-rw-r--r--plugins/Clist_modern/src/modern_clcpaint.cpp11
-rw-r--r--plugins/TabSRMM/src/chat/window.cpp25
-rw-r--r--plugins/TipperYM/src/translations.cpp8
3 files changed, 21 insertions, 23 deletions
diff --git a/plugins/Clist_modern/src/modern_clcpaint.cpp b/plugins/Clist_modern/src/modern_clcpaint.cpp
index e56b60f31e..633aa898d0 100644
--- a/plugins/Clist_modern/src/modern_clcpaint.cpp
+++ b/plugins/Clist_modern/src/modern_clcpaint.cpp
@@ -167,17 +167,14 @@ int CLCPaint::GetBasicFontID(ClcContact *contact)
return FONTID_DIVIDERS;
case CLCIT_CONTACT:
- if ( contact->flags & CONTACTF_NOTONLIST )
+ if (contact->flags & CONTACTF_NOTONLIST)
return FONTID_NOTONLIST;
- if (( contact->flags&CONTACTF_INVISTO
- && _GetRealStatus( contact, ID_STATUS_OFFLINE ) != ID_STATUS_INVISIBLE )
- ||
- ( contact->flags&CONTACTF_VISTO
- && _GetRealStatus( contact, ID_STATUS_OFFLINE ) == ID_STATUS_INVISIBLE ))
+ if (((contact->flags & CONTACTF_INVISTO) && _GetRealStatus(contact, ID_STATUS_OFFLINE) != ID_STATUS_INVISIBLE) ||
+ ((contact->flags & CONTACTF_VISTO && _GetRealStatus(contact, ID_STATUS_OFFLINE) == ID_STATUS_INVISIBLE)))
{
// the contact is in the always visible list and the proto is invisible
// the contact is in the always invisible and the proto is in any other mode
- return contact->flags & CONTACTF_ONLINE ? FONTID_INVIS : FONTID_OFFINVIS;
+ return (contact->flags & CONTACTF_ONLINE) ? FONTID_INVIS : FONTID_OFFINVIS;
}
switch( pdnce___GetStatus( pdnce )) {
diff --git a/plugins/TabSRMM/src/chat/window.cpp b/plugins/TabSRMM/src/chat/window.cpp
index 4280716d4b..4415029805 100644
--- a/plugins/TabSRMM/src/chat/window.cpp
+++ b/plugins/TabSRMM/src/chat/window.cpp
@@ -144,13 +144,13 @@ static BOOL CheckCustomLink(HWND hwndDlg, POINT* ptClient, UINT uMsg, WPARAM wPa
POINT pt = *ptClient;
ClientToScreen(hwndDlg, &pt);
- do {
+ do {
if (!SendMessage(hwndDlg, EM_GETOLEINTERFACE, 0, (LPARAM)&RichEditOle)) break;
if (RichEditOle->QueryInterface(IID_ITextDocument, (void**)&TextDocument) != S_OK) break;
if (TextDocument->RangeFromPoint(pt.x, pt.y, &TextRange) != S_OK) break;
TextRange->GetStart(&cpMin);
- cpMax = cpMin+1;
+ cpMax = cpMin + 1;
TextRange->SetEnd(cpMax);
if (TextRange->GetFont(&TextFont) != S_OK)
@@ -160,7 +160,7 @@ static BOOL CheckCustomLink(HWND hwndDlg, POINT* ptClient, UINT uMsg, WPARAM wPa
if (res != tomTrue)
break;
- TextRange->GetPoint(tomEnd+TA_BOTTOM+TA_RIGHT, &ptEnd.x, &ptEnd.y);
+ TextRange->GetPoint(tomEnd + TA_BOTTOM + TA_RIGHT, &ptEnd.x, &ptEnd.y);
if (pt.x > ptEnd.x || pt.y > ptEnd.y)
break;
@@ -168,13 +168,13 @@ static BOOL CheckCustomLink(HWND hwndDlg, POINT* ptClient, UINT uMsg, WPARAM wPa
TextRange->GetStoryLength(&cnt);
for (; cpMin > 0; cpMin--) {
res = tomTrue;
- TextRange->SetIndex(tomCharacter, cpMin+1, tomTrue);
+ TextRange->SetIndex(tomCharacter, cpMin + 1, tomTrue);
TextFont->GetProtected(&res);
if (res != tomTrue) { cpMin++; break; }
}
for (cpMax--; cpMax < cnt; cpMax++) {
res = tomTrue;
- TextRange->SetIndex(tomCharacter, cpMax+1, tomTrue);
+ TextRange->SetIndex(tomCharacter, cpMax + 1, tomTrue);
TextFont->GetProtected(&res);
if (res != tomTrue)
break;
@@ -182,7 +182,8 @@ static BOOL CheckCustomLink(HWND hwndDlg, POINT* ptClient, UINT uMsg, WPARAM wPa
}
bIsCustomLink = (cpMin < cpMax);
- } while(FALSE);
+ }
+ while (FALSE);
if (TextFont) TextFont->Release();
if (TextRange) TextRange->Release();
@@ -190,7 +191,7 @@ static BOOL CheckCustomLink(HWND hwndDlg, POINT* ptClient, UINT uMsg, WPARAM wPa
if (RichEditOle) RichEditOle->Release();
if (bIsCustomLink) {
- ENLINK enlink = {0};
+ ENLINK enlink = { 0 };
enlink.nmhdr.hwndFrom = hwndDlg;
enlink.nmhdr.idFrom = IDC_CHAT_LOG;
enlink.nmhdr.code = EN_LINK;
@@ -275,8 +276,8 @@ static void Chat_UpdateWindowState(TWindowData *dat, UINT msg)
dat->hTabIcon = dat->hTabStatusIcon;
if (dat->iTabID >= 0) {
- if (db_get_w(si->hContact, si->pszModule , "ApparentMode", 0) != 0)
- db_set_w(si->hContact, si->pszModule , "ApparentMode", 0);
+ if (db_get_w(si->hContact, si->pszModule, "ApparentMode", 0) != 0)
+ db_set_w(si->hContact, si->pszModule, "ApparentMode", 0);
if (CallService(MS_CLIST_GETEVENT, (WPARAM)si->hContact, 0))
CallService(MS_CLIST_REMOVEEVENT, (WPARAM)si->hContact, (LPARAM)GC_FAKE_EVENT);
@@ -400,7 +401,7 @@ static int RoomWndResize(HWND hwndDlg, LPARAM lParam, UTILRESIZECONTROL *urc)
Utils::enableDlgControl(hwndDlg, IDC_SHOWNICKLIST, TRUE);
Utils::enableDlgControl(hwndDlg, IDC_FILTER, TRUE);
- if (si->iType == GCW_CHATROOM) {
+ if (si->iType == GCW_CHATROOM) {
MODULEINFO* tmp = pci->MM_FindModule(si->pszModule);
if (tmp)
Utils::enableDlgControl(hwndDlg, IDC_CHANMGR, tmp->bChanMgr);
@@ -443,7 +444,7 @@ static int RoomWndResize(HWND hwndDlg, LPARAM lParam, UTILRESIZECONTROL *urc)
case IDC_LIST:
urc->rcItem.top = 0;
- urc->rcItem.right = urc->dlgNewSize.cx ;
+ urc->rcItem.right = urc->dlgNewSize.cx;
urc->rcItem.left = urc->dlgNewSize.cx - si->iSplitterX + 2;
urc->rcItem.bottom = (bToolbar && !bBottomToolbar) ? (urc->dlgNewSize.cy - si->iSplitterY - DPISCALEY_S(23)) : (urc->dlgNewSize.cy - si->iSplitterY - DPISCALEY_S(2));
if (bInfoPanel)
@@ -478,7 +479,7 @@ static int RoomWndResize(HWND hwndDlg, LPARAM lParam, UTILRESIZECONTROL *urc)
return RD_ANCHORX_CUSTOM | RD_ANCHORY_CUSTOM;
case IDC_CHAT_MESSAGE:
- urc->rcItem.right = urc->dlgNewSize.cx ;
+ urc->rcItem.right = urc->dlgNewSize.cx;
urc->rcItem.top = urc->dlgNewSize.cy - si->iSplitterY + 3;
urc->rcItem.bottom = urc->dlgNewSize.cy; // - 1 ;
diff --git a/plugins/TipperYM/src/translations.cpp b/plugins/TipperYM/src/translations.cpp
index c037fe8035..24276afbbe 100644
--- a/plugins/TipperYM/src/translations.cpp
+++ b/plugins/TipperYM/src/translations.cpp
@@ -706,7 +706,7 @@ static DBVTranslation internalTranslations[] =
{ WordToCountry, LPGENT("WORD to country name") },
{ DwordToIp, LPGENT("DWORD to ip address") },
{ DayMonthYearToDate, LPGENT("<prefix>Day|Month|Year to date") },
- { DayMonthYearToAge, LPGENT("<prefix>Day|Month|Year to age") },
+ { DayMonthYearToAge, LPGENT("<prefix>Day|Month|Year to age") },
{ HoursMinutesSecondsToTime, LPGENT("<prefix>Hours|Minutes|Seconds to time") },
{ DmyToTimeDifference, LPGENT("<prefix>Day|Month|Year|Hours|Minutes|Seconds to time difference") },
{ DayMonthToDaysToNextBirthday, LPGENT("<prefix>Day|Month to days to next birthday") },
@@ -725,13 +725,13 @@ static DBVTranslation internalTranslations[] =
void InitTranslations()
{
dwNextFuncId = db_get_dw(0, MODULE_ITEMS, "NextFuncId", 1);
- for (int i = 0; i < SIZEOF(internalTranslations); i++)
- AddTranslation( &internalTranslations[i] );
+ for (int i = 0; i < SIZEOF(internalTranslations); i++)
+ AddTranslation(&internalTranslations[i]);
hServiceAdd = CreateServiceFunction(MS_TIPPER_ADDTRANSLATION, ServiceAddTranslation);
}
-void DeinitTranslations()
+void DeinitTranslations()
{
DestroyServiceFunction(hServiceAdd);
mir_free(translations);