浏览代码

Remove TABS

pull/762/head
Ray 6 年前
父节点
当前提交
a886f5e743
共有 5 个文件被更改,包括 10 次插入10 次删除
  1. +2
    -2
      src/core.c
  2. +2
    -2
      src/raudio.c
  3. +1
    -1
      src/shapes.c
  4. +4
    -4
      src/text.c
  5. +1
    -1
      src/textures.c

+ 2
- 2
src/core.c 查看文件

@ -871,7 +871,7 @@ void *GetWindowHandle(void)
{ {
#if defined(_WIN32) #if defined(_WIN32)
// NOTE: Returned handle is: void *HWND (windows.h) // NOTE: Returned handle is: void *HWND (windows.h)
return glfwGetWin32Window(window);
return glfwGetWin32Window(window);
#elif defined(__linux__) #elif defined(__linux__)
// NOTE: Returned handle is: unsigned long Window (X.h) // NOTE: Returned handle is: unsigned long Window (X.h)
// typedef unsigned long XID; // typedef unsigned long XID;
@ -2213,7 +2213,7 @@ void SetMouseOffset(int offsetX, int offsetY)
// NOTE: Useful when rendering to different size targets // NOTE: Useful when rendering to different size targets
void SetMouseScale(float scaleX, float scaleY) void SetMouseScale(float scaleX, float scaleY)
{ {
mouseScale = (Vector2){ scaleX, scaleY };
mouseScale = (Vector2){ scaleX, scaleY };
} }
// Returns mouse wheel movement Y // Returns mouse wheel movement Y

+ 2
- 2
src/raudio.c 查看文件

@ -1406,8 +1406,8 @@ void UpdateMusicStream(Music music)
UpdateAudioStream(music->stream, pcm, samplesCount); UpdateAudioStream(music->stream, pcm, samplesCount);
if ((music->ctxType == MUSIC_MODULE_XM) || (music->ctxType == MUSIC_MODULE_MOD)) if ((music->ctxType == MUSIC_MODULE_XM) || (music->ctxType == MUSIC_MODULE_MOD))
{ {
if (samplesCount > 1) music->samplesLeft -= samplesCount/2;
else music->samplesLeft -= samplesCount;
if (samplesCount > 1) music->samplesLeft -= samplesCount/2;
else music->samplesLeft -= samplesCount;
} }
else music->samplesLeft -= samplesCount; else music->samplesLeft -= samplesCount;

+ 1
- 1
src/shapes.c 查看文件

@ -644,7 +644,7 @@ bool CheckCollisionCircleRec(Vector2 center, float radius, Rectangle rec)
if (dy <= (rec.height/2.0f)) { return true; } if (dy <= (rec.height/2.0f)) { return true; }
float cornerDistanceSq = (dx - rec.width/2.0f)*(dx - rec.width/2.0f) + float cornerDistanceSq = (dx - rec.width/2.0f)*(dx - rec.width/2.0f) +
(dy - rec.height/2.0f)*(dy - rec.height/2.0f);
(dy - rec.height/2.0f)*(dy - rec.height/2.0f);
return (cornerDistanceSq <= (radius*radius)); return (cornerDistanceSq <= (radius*radius));
} }

+ 4
- 4
src/text.c 查看文件

@ -1386,10 +1386,10 @@ static Font LoadBMFont(const char *fileName)
char *lastSlash = NULL; char *lastSlash = NULL;
lastSlash = strrchr(fileName, '/'); lastSlash = strrchr(fileName, '/');
if (lastSlash == NULL)
{
lastSlash = strrchr(fileName, '\\');
}
if (lastSlash == NULL)
{
lastSlash = strrchr(fileName, '\\');
}
// NOTE: We need some extra space to avoid memory corruption on next allocations! // NOTE: We need some extra space to avoid memory corruption on next allocations!
texPath = malloc(strlen(fileName) - strlen(lastSlash) + strlen(texFileName) + 4); texPath = malloc(strlen(fileName) - strlen(lastSlash) + strlen(texFileName) + 4);

+ 1
- 1
src/textures.c 查看文件

@ -1631,7 +1631,7 @@ Color *ImageExtractPalette(Image image, int maxPaletteSize, int *extractCount)
if (palCount >= maxPaletteSize) if (palCount >= maxPaletteSize)
{ {
i = image.width*image.height; // Finish palette get i = image.width*image.height; // Finish palette get
printf("WARNING: Image palette is greater than %i colors!\n", maxPaletteSize);
TraceLog(LOG_WARNING, "Image palette is greater than %i colors!", maxPaletteSize);
} }
} }
} }

正在加载...
取消
保存