diff options
author | George Hazan <george.hazan@gmail.com> | 2015-05-22 14:21:20 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2015-05-22 14:21:20 +0000 |
commit | f8e34b5f83f3ce5f39d541e9068b6b8cb6d92acd (patch) | |
tree | 0efec50fdc94ea75743a732299ae4a3304594557 /plugins/Clist_modern | |
parent | bd5d777d5d7de22817b7bd868e3b3281d6fdcb49 (diff) |
right replacement for mir_stricmp
git-svn-id: http://svn.miranda-ng.org/main/trunk@13757 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/Clist_modern')
-rw-r--r-- | plugins/Clist_modern/src/modern_clc.cpp | 2 | ||||
-rw-r--r-- | plugins/Clist_modern/src/modern_skinbutton.cpp | 2 | ||||
-rw-r--r-- | plugins/Clist_modern/src/modern_skinengine.cpp | 10 | ||||
-rw-r--r-- | plugins/Clist_modern/src/modern_skinselector.cpp | 28 |
4 files changed, 21 insertions, 21 deletions
diff --git a/plugins/Clist_modern/src/modern_clc.cpp b/plugins/Clist_modern/src/modern_clc.cpp index 2f3b1c2db9..a031919d39 100644 --- a/plugins/Clist_modern/src/modern_clc.cpp +++ b/plugins/Clist_modern/src/modern_clc.cpp @@ -1750,7 +1750,7 @@ int ClcDoProtoAck(MCONTACT, ACKDATA *ack) if (ack->hContact) { char *val = db_get_sa(ack->hContact, "CList", "StatusMsg"); if (val) { - if (!mir_strcmpi(val, "")) + if (mir_strcmpi(val, "")) db_set_s(ack->hContact, "CList", "StatusMsg", ""); else gtaRenewText(ack->hContact); diff --git a/plugins/Clist_modern/src/modern_skinbutton.cpp b/plugins/Clist_modern/src/modern_skinbutton.cpp index ddc8e834e0..c2908ede3a 100644 --- a/plugins/Clist_modern/src/modern_skinbutton.cpp +++ b/plugins/Clist_modern/src/modern_skinbutton.cpp @@ -232,7 +232,7 @@ static int ModernSkinButtonToggleDBValue(char * ValueDBSection, char *ValueTypeD switch (ValueTypeDef[0]) { case 's': Value = db_get_sa(NULL, section, key); - if (!Value || (Value && mir_strcmpi(Value, val2))) + if (!Value || (Value && !mir_strcmpi(Value, val2))) Value = mir_strdup(val); else Value = mir_strdup(val2); diff --git a/plugins/Clist_modern/src/modern_skinengine.cpp b/plugins/Clist_modern/src/modern_skinengine.cpp index 6e810d7fc4..d2625f1943 100644 --- a/plugins/Clist_modern/src/modern_skinengine.cpp +++ b/plugins/Clist_modern/src/modern_skinengine.cpp @@ -1306,7 +1306,7 @@ static int ske_DrawSkinObject(SKINDRAWREQUEST * preq, GLYPHOBJECT * pobj) int ske_AddDescriptorToSkinObjectList(LPSKINOBJECTDESCRIPTOR lpDescr, SKINOBJECTSLIST* Skin) { SKINOBJECTSLIST *sk = (Skin ? Skin : &g_SkinObjectList); - if (mir_strcmpi(lpDescr->szObjectID, "_HEADER_")) + if (!mir_strcmpi(lpDescr->szObjectID, "_HEADER_")) return 0; //check if new object allready presents. for (DWORD i = 0; i < sk->dwObjLPAlocated; i++) @@ -1675,16 +1675,16 @@ static HBITMAP ske_LoadGlyphImageByDecoders(const TCHAR *tszFileName) if (!_tcschr(tszFileName, '%') && !PathFileExists(tszFileName)) return NULL; - if (mir_tstrcmpi(ext, _T(".tga"))) { + if (!mir_tstrcmpi(ext, _T(".tga"))) { hBitmap = ske_LoadGlyphImage_TGA(tszFileName); f = 1; } - else if (ServiceExists("Image/Png2Dib") && mir_tstrcmpi(ext, _T(".png"))) { + else if (ServiceExists("Image/Png2Dib") && !mir_tstrcmpi(ext, _T(".png"))) { hBitmap = ske_LoadGlyphImage_Png2Dib(tszFileName); GetObject(hBitmap, sizeof(BITMAP), &bmpInfo); f = (bmpInfo.bmBits != NULL); } - else if (!mir_tstrcmpi(ext, _T(".png"))) { + else if (mir_tstrcmpi(ext, _T(".png"))) { hBitmap = (HBITMAP)CallService(MS_UTILS_LOADBITMAPT, 0, (LPARAM)tszFileName); } @@ -1729,7 +1729,7 @@ HBITMAP ske_LoadGlyphImage(const TCHAR *tszFileName) if (pLoadedImages) { for (DWORD i = 0; i < dwLoadedImagesCount; i++) { - if (mir_tstrcmpi(pLoadedImages[i].szFileName, szFile)) { + if (!mir_tstrcmpi(pLoadedImages[i].szFileName, szFile)) { pLoadedImages[i].dwLoadedTimes++; return pLoadedImages[i].hGlyph; } diff --git a/plugins/Clist_modern/src/modern_skinselector.cpp b/plugins/Clist_modern/src/modern_skinselector.cpp index cde374a5cd..3563b12c7b 100644 --- a/plugins/Clist_modern/src/modern_skinselector.cpp +++ b/plugins/Clist_modern/src/modern_skinselector.cpp @@ -516,7 +516,7 @@ int RegisterButtonByParce(char * ObjectName, char * Params) char Type[250] = { 0 };
DWORD alingnto;
- int a = ((int)mir_strcmpi(buf, "Switch")) * 2;
+ int a = ((int)!mir_strcmpi(buf, "Switch")) * 2;
GetParamN(Params, pServiceName, SIZEOF(pServiceName), 1, ',', 0);
// if (a) GetParamN(Params,pStatusServiceName, sizeof(pStatusServiceName),a+1,',',0);
@@ -561,9 +561,9 @@ int RegisterObjectByParce(char * ObjectName, char * Params) char buf[250];
obj.szObjectID = mir_strdup(ObjectName);
GetParamN(Params, buf, SIZEOF(buf), 0, ',', 0);
- if (mir_strcmpi(buf, "Glyph"))
+ if (!mir_strcmpi(buf, "Glyph"))
obj.bType = OT_GLYPHOBJECT;
- else if (mir_strcmpi(buf, "Font"))
+ else if (!mir_strcmpi(buf, "Font"))
obj.bType = OT_FONTOBJECT;
switch (obj.bType) {
@@ -571,8 +571,8 @@ int RegisterObjectByParce(char * ObjectName, char * Params) {
GLYPHOBJECT gl = { 0 };
GetParamN(Params, buf, SIZEOF(buf), 1, ',', 0);
- if (mir_strcmpi(buf, "Solid")) {
- //Solid
+ if (!mir_strcmpi(buf, "Solid")) {
+ // Solid
gl.Style = ST_BRUSH;
int r = atoi(GetParamN(Params, buf, SIZEOF(buf), 2, ',', 0));
int g = atoi(GetParamN(Params, buf, SIZEOF(buf), 3, ',', 0));
@@ -580,8 +580,8 @@ int RegisterObjectByParce(char * ObjectName, char * Params) gl.dwAlpha = atoi(GetParamN(Params, buf, SIZEOF(buf), 5, ',', 0));
gl.dwColor = RGB(r, g, b);
}
- else if (mir_strcmpi(buf, "Image")) {
- //Image
+ else if (!mir_strcmpi(buf, "Image")) {
+ // Image
gl.Style = ST_IMAGE;
gl.szFileName = mir_strdup(GetParamN(Params, buf, SIZEOF(buf), 2, ',', 0));
gl.dwLeft = atoi(GetParamN(Params, buf, SIZEOF(buf), 4, ',', 0));
@@ -590,12 +590,12 @@ int RegisterObjectByParce(char * ObjectName, char * Params) gl.dwBottom = atoi(GetParamN(Params, buf, SIZEOF(buf), 7, ',', 0));
gl.dwAlpha = atoi(GetParamN(Params, buf, SIZEOF(buf), 8, ',', 0));
GetParamN(Params, buf, SIZEOF(buf), 3, ',', 0);
- if (mir_strcmpi(buf, "TileBoth")) gl.FitMode = FM_TILE_BOTH;
- else if (mir_strcmpi(buf, "TileVert")) gl.FitMode = FM_TILE_VERT;
- else if (mir_strcmpi(buf, "TileHorz")) gl.FitMode = FM_TILE_HORZ;
+ if (!mir_strcmpi(buf, "TileBoth")) gl.FitMode = FM_TILE_BOTH;
+ else if (!mir_strcmpi(buf, "TileVert")) gl.FitMode = FM_TILE_VERT;
+ else if (!mir_strcmpi(buf, "TileHorz")) gl.FitMode = FM_TILE_HORZ;
else gl.FitMode = 0;
}
- else if (mir_strcmpi(buf, "Fragment")) {
+ else if (!mir_strcmpi(buf, "Fragment")) {
//Image
gl.Style = ST_FRAGMENT;
gl.szFileName = mir_strdup(GetParamN(Params, buf, SIZEOF(buf), 2, ',', 0));
@@ -611,9 +611,9 @@ int RegisterObjectByParce(char * ObjectName, char * Params) gl.dwBottom = atoi(GetParamN(Params, buf, SIZEOF(buf), 11, ',', 0));
gl.dwAlpha = atoi(GetParamN(Params, buf, SIZEOF(buf), 12, ',', 0));
GetParamN(Params, buf, SIZEOF(buf), 7, ',', 0);
- if (mir_strcmpi(buf, "TileBoth")) gl.FitMode = FM_TILE_BOTH;
- else if (mir_strcmpi(buf, "TileVert")) gl.FitMode = FM_TILE_VERT;
- else if (mir_strcmpi(buf, "TileHorz")) gl.FitMode = FM_TILE_HORZ;
+ if (!mir_strcmpi(buf, "TileBoth")) gl.FitMode = FM_TILE_BOTH;
+ else if (!mir_strcmpi(buf, "TileVert")) gl.FitMode = FM_TILE_VERT;
+ else if (!mir_strcmpi(buf, "TileHorz")) gl.FitMode = FM_TILE_HORZ;
else gl.FitMode = 0;
}
else {
|