: 31;
// can it be day?
- if ( (val == 0) || (val > maxDays) )
+ if ( (val == 0) || (val > (unsigned long)maxDays) ) // cast to shut up compiler warning in BCC
{
isYear = TRUE;
}
if (node != NULL)
return ((wxLibrary *)node->Data());
#else // !OS/2
- if ( (node = m_loaded.Find(name.GetData())) )
+ node = m_loaded.Find(name.GetData());
+ if ( node )
return ((wxLibrary *)node->Data());
#endif
// If DLL shares data, this is necessary.
s_triedToLoad = TRUE;
wxDllType dllKernel = wxDllLoader::LoadLibrary(_T("kernel32"));
- if ( 0 ) // dllKernel )
+ short avoidCompilerWarning = 0;
+ if ( avoidCompilerWarning ) // dllKernel )
{
// may succeed or fail depending on the Windows version
#ifdef _UNICODE
{
wxExpr *valueList = (wxExpr *) NULL;
- if ((valueList = expr->Nth(count)) && (valueList->Type() == PrologList))
+ valueList = expr->Nth(count);
+ if (valueList && (valueList->Type() == PrologList))
{
wxStringList stringList;
wxExpr *stringExpr = valueList->GetFirst();
/*
controlItem->SetValue1(wxLB_SINGLE);
*/
- if ((mult = expr->Nth(count)) && ((mult->Type() == PrologString)||(mult->Type() == PrologWord)))
+ mult = expr->Nth(count);
+ if (mult && ((mult->Type() == PrologString)||(mult->Type() == PrologWord)))
{
/*
wxString m(mult->StringValue());
{
wxExpr *valueList = (wxExpr *) NULL;
// Check for default value list
- if ((valueList = expr->Nth(count)) && (valueList->Type() == PrologList))
+ valueList = expr->Nth(count);
+ if (valueList && (valueList->Type() == PrologList))
{
wxStringList stringList;
wxExpr *stringExpr = valueList->GetFirst();
wxExpr *valueList = (wxExpr *) NULL;
// Check for default value list
- if ((valueList = expr->Nth(count)) && (valueList->Type() == PrologList))
+ valueList = expr->Nth(count);
+ if (valueList && (valueList->Type() == PrologList))
{
wxStringList stringList;
wxExpr *stringExpr = valueList->GetFirst();
{
wxExpr *valueList = (wxExpr *) NULL;
// Check for default value list
- if ((valueList = expr->Nth(count)) && (valueList->Type() == PrologList))
+ valueList = expr->Nth(count);
+ if (valueList && (valueList->Type() == PrologList))
{
wxStringList stringList;
wxExpr *stringExpr = valueList->GetFirst();
{
#ifdef __WXGTK__
wxLogWarning(_("Icon resource specification %s not found."), (const wxChar*) resource);
+ break;
#else
return wxIcon(name, bitmapType);
#endif
- break;
}
}
return wxNullIcon;
}
#endif // wxUSE_METAFILE
}
+ return FALSE;
#else // !wxUSE_DATAOBJ
wxFAIL_MSG( wxT("no clipboard implementation") );
-#endif // wxUSE_OLE_CLIPBOARD/wxUSE_DATAOBJ
-
return FALSE;
+#endif // wxUSE_OLE_CLIPBOARD/wxUSE_DATAOBJ
}
#else
return (HANDLE) NULL;
// inserted by P.S.
- while( ((unsigned)nDirEntries < iconFileHead.wResourceCount) &&
+ while( (nDirEntries < iconFileHead.wResourceCount) &&
((iconFileRes.bWidth != nWidth) || (iconFileRes.bHeight != nHeight)))
{
cbRes = _lread( hFile, (LPSTR )&iconFileRes, sizeof( ICONFILERES));
return (HANDLE) NULL;
// following added by P.S.
- while( ((unsigned)nDirEntries < curFileHead.wResourceCount) &&
+ while( (nDirEntries < curFileHead.wResourceCount) &&
((curFileRes.bWidth != nWidth) || (curFileRes.bHeight != nHeight)))
{
cbRes = _lread( hFile, (LPSTR )&curFileRes, sizeof( CURFILERES));
ul -= MAXREAD;
hp += MAXREAD;
}
- if (_lread(fh, (LPSTR) hp, (WORD) ul) != (WORD) ul)
+ if (_lread(fh, (LPSTR) hp, (WXUINT) ul) != (WXUINT) ul)
return 0;
return ulT;
}
ul -= MAXREAD;
hp += MAXREAD;
}
- if (_lwrite(fh, (LPSTR) hp, (WORD) ul) != (WORD) ul)
+ if (_lwrite(fh, (LPSTR) hp, (WXUINT) ul) != (WXUINT) ul)
return 0;
return ulT;
}
lpRGB = (RGBQUAD FAR *)((LPSTR)lpInfo + lpInfo->biSize);
/* copy colors from the color table to the LogPalette structure */
- for (i = 0; i < lpInfo->biClrUsed; i++, lpRGB++)
+ for (i = 0; (DWORD)i < lpInfo->biClrUsed; i++, lpRGB++)
{
npPal->palPalEntry[i].peRed = lpRGB->rgbRed;
npPal->palPalEntry[i].peGreen = lpRGB->rgbGreen;
return TRUE;
}
}
- break;
+// break; // can never be reached
#endif // _WIN32_IE >= 0x300
default:
{
case wxSYS_COLOUR_LISTBOX:
return *wxWHITE;
- break;
default:
COLORREF ref = ::GetSysColor(index);
wxColour col(GetRValue(ref), GetGValue(ref), GetBValue(ref));
return col;
- break;
}
}
return TRUE;
}
}
- break;
+// break; // can never be reached
#endif // _WIN32_IE >= 0x300
case NM_DBLCLK:
{
#if defined(__WIN32__)
DWORD attribs = GetFileAttributes(dir);
- return ((attribs != -1) && (attribs & FILE_ATTRIBUTE_DIRECTORY));
+ return ((attribs != (DWORD)-1) && (attribs & FILE_ATTRIBUTE_DIRECTORY));
#else // Win16
#ifdef __BORLANDC__
struct ffblk fileInfo;