mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-09-03 14:10:33 +03:00
0026171: Coding rules - eliminate -Wshorten-64-to-32 CLang warnings
This commit is contained in:
@@ -690,7 +690,7 @@ TCollection_AsciiString Draw_Interpretor::GetLog ()
|
||||
char buffer[BUFSIZE + 1];
|
||||
for (;;)
|
||||
{
|
||||
int nbRead = read (myFDLog, buffer, BUFSIZE);
|
||||
int nbRead = (int )read (myFDLog, buffer, BUFSIZE);
|
||||
if (nbRead <= 0)
|
||||
{
|
||||
break;
|
||||
|
@@ -1084,7 +1084,7 @@ void Draw_Viewer::Select (Standard_Integer& theId,
|
||||
theId = MAXVIEW;
|
||||
while (theId >= MAXVIEW)
|
||||
{
|
||||
Standard_Integer aWindowNumber = 0;
|
||||
long aWindowNumber = 0;
|
||||
Draw_Window::GetNextEvent (theToWait, aWindowNumber, theX, theY, theButton);
|
||||
if (theY < 0)
|
||||
{
|
||||
|
@@ -853,7 +853,7 @@ void Draw_Window::DrawString (Standard_Integer theX, Standard_Integer theY,
|
||||
}
|
||||
ReleaseDC (myWindow, hDC);
|
||||
#elif defined(HAVE_XLIB)
|
||||
XDrawString (Draw_WindowDisplay, GetDrawable(), myBase->gc, theX, theY, (char* )theText, strlen(theText));
|
||||
XDrawString (Draw_WindowDisplay, GetDrawable(), myBase->gc, theX, theY, (char* )theText, (int )strlen(theText));
|
||||
#else
|
||||
(void )theX;
|
||||
(void )theY;
|
||||
|
@@ -249,10 +249,10 @@ public:
|
||||
|
||||
void Wait (Standard_Boolean theToWait = Standard_True);
|
||||
#elif defined(__APPLE__)
|
||||
Standard_Boolean IsEqualWindows (const Standard_Integer& theWindowNumber);
|
||||
Standard_Boolean IsEqualWindows (const long theWindowNumber);
|
||||
|
||||
static void GetNextEvent (Standard_Boolean theWait,
|
||||
Standard_Integer& theWindowNumber,
|
||||
long& theWindowNumber,
|
||||
Standard_Integer& theX,
|
||||
Standard_Integer& theY,
|
||||
Standard_Integer& theButton);
|
||||
|
@@ -552,13 +552,13 @@ Standard_Boolean Draw_Window::Save (Standard_CString theFileName) const
|
||||
return isSuccess;
|
||||
}
|
||||
|
||||
Standard_Boolean Draw_Window::IsEqualWindows (const Standard_Integer& theWindowNumber)
|
||||
Standard_Boolean Draw_Window::IsEqualWindows (const long theWindowNumber)
|
||||
{
|
||||
return ([myWindow windowNumber] == theWindowNumber);
|
||||
}
|
||||
|
||||
void Draw_Window::GetNextEvent (Standard_Boolean theWait,
|
||||
Standard_Integer& theWindowNumber,
|
||||
long& theWindowNumber,
|
||||
Standard_Integer& theX,
|
||||
Standard_Integer& theY,
|
||||
Standard_Integer& theButton)
|
||||
|
Reference in New Issue
Block a user