1
0
Fork 0
mirror of https://github.com/gwm17/glfw.git synced 2024-11-29 21:48:52 -05:00

Cleanup of size_t use.

This commit is contained in:
siavash 2013-07-15 18:37:02 +02:00 committed by Camilla Berglund
parent b12c973922
commit 0463e196b4
6 changed files with 8 additions and 7 deletions

View File

@ -668,7 +668,7 @@ static int translateKey(unsigned int key)
//
static NSString* findAppName(void)
{
unsigned int i;
size_t i;
NSDictionary* infoDictionary = [[NSBundle mainBundle] infoDictionary];
// Keys to search for as potential application names

View File

@ -246,7 +246,7 @@ void _glfwTerminateContextAPI(void)
{ \
attribs[index++] = attribName; \
attribs[index++] = attribValue; \
assert(index < sizeof(attribs) / sizeof(attribs[0])); \
assert((size_t) index < sizeof(attribs) / sizeof(attribs[0])); \
}
// Prepare for creation of the OpenGL context

View File

@ -344,7 +344,7 @@ void _glfwTerminateContextAPI(void)
{ \
attribs[index++] = attribName; \
attribs[index++] = attribValue; \
assert(index < sizeof(attribs) / sizeof(attribs[0])); \
assert((size_t) index < sizeof(attribs) / sizeof(attribs[0])); \
}
// Prepare for creation of the OpenGL context

View File

@ -332,7 +332,7 @@ void _glfwTerminateContextAPI(void)
{ \
attribs[index++] = attribName; \
attribs[index++] = attribValue; \
assert(index < sizeof(attribs) / sizeof(attribs[0])); \
assert((size_t) index < sizeof(attribs) / sizeof(attribs[0])); \
}
// Prepare for creation of the OpenGL context

View File

@ -273,11 +273,11 @@ void _glfwPlatformSetClipboardString(_GLFWwindow* window, const char* string)
const char* _glfwPlatformGetClipboardString(_GLFWwindow* window)
{
int i;
size_t i;
const Atom formats[] = { _glfw.x11.UTF8_STRING,
_glfw.x11.COMPOUND_STRING,
XA_STRING };
const int formatCount = sizeof(formats) / sizeof(formats[0]);
const size_t formatCount = sizeof(formats) / sizeof(formats[0]);
if (_glfwFindWindowByHandle(XGetSelectionOwner(_glfw.x11.display,
_glfw.x11.CLIPBOARD)))

View File

@ -162,7 +162,8 @@ static void pollJoystickEvents(void)
void _glfwInitJoysticks(void)
{
#ifdef __linux__
int i, joy = 0;
int joy = 0;
size_t i;
regex_t regex;
DIR* dir;
const char* dirs[] =