Removed SDL_bool in favor of plain bool
We require stdbool.h in the build environment, so we might as well use the plain bool type. If your environment doesn't have stdbool.h, this simple replacement will suffice: typedef signed char bool;
This commit is contained in:
parent
9dd8859240
commit
a90ad3b0e2
258 changed files with 4052 additions and 4057 deletions
|
@ -252,12 +252,12 @@ typedef Uint32 SDL_GlobFlags;
|
|||
* Create a directory.
|
||||
*
|
||||
* \param path the path of the directory to create.
|
||||
* \returns SDL_TRUE on success or SDL_FALSE on failure; call SDL_GetError()
|
||||
* \returns true on success or false on failure; call SDL_GetError()
|
||||
* for more information.
|
||||
*
|
||||
* \since This function is available since SDL 3.0.0.
|
||||
*/
|
||||
extern SDL_DECLSPEC SDL_bool SDLCALL SDL_CreateDirectory(const char *path);
|
||||
extern SDL_DECLSPEC bool SDLCALL SDL_CreateDirectory(const char *path);
|
||||
|
||||
/* Callback for directory enumeration. Return 1 to keep enumerating,
|
||||
0 to stop enumerating (no error), -1 to stop enumerating and
|
||||
|
@ -275,47 +275,47 @@ typedef int (SDLCALL *SDL_EnumerateDirectoryCallback)(void *userdata, const char
|
|||
* \param path the path of the directory to enumerate.
|
||||
* \param callback a function that is called for each entry in the directory.
|
||||
* \param userdata a pointer that is passed to `callback`.
|
||||
* \returns SDL_TRUE on success or SDL_FALSE on failure; call SDL_GetError()
|
||||
* \returns true on success or false on failure; call SDL_GetError()
|
||||
* for more information.
|
||||
*
|
||||
* \since This function is available since SDL 3.0.0.
|
||||
*/
|
||||
extern SDL_DECLSPEC SDL_bool SDLCALL SDL_EnumerateDirectory(const char *path, SDL_EnumerateDirectoryCallback callback, void *userdata);
|
||||
extern SDL_DECLSPEC bool SDLCALL SDL_EnumerateDirectory(const char *path, SDL_EnumerateDirectoryCallback callback, void *userdata);
|
||||
|
||||
/**
|
||||
* Remove a file or an empty directory.
|
||||
*
|
||||
* \param path the path of the directory to enumerate.
|
||||
* \returns SDL_TRUE on success or SDL_FALSE on failure; call SDL_GetError()
|
||||
* \returns true on success or false on failure; call SDL_GetError()
|
||||
* for more information.
|
||||
*
|
||||
* \since This function is available since SDL 3.0.0.
|
||||
*/
|
||||
extern SDL_DECLSPEC SDL_bool SDLCALL SDL_RemovePath(const char *path);
|
||||
extern SDL_DECLSPEC bool SDLCALL SDL_RemovePath(const char *path);
|
||||
|
||||
/**
|
||||
* Rename a file or directory.
|
||||
*
|
||||
* \param oldpath the old path.
|
||||
* \param newpath the new path.
|
||||
* \returns SDL_TRUE on success or SDL_FALSE on failure; call SDL_GetError()
|
||||
* \returns true on success or false on failure; call SDL_GetError()
|
||||
* for more information.
|
||||
*
|
||||
* \since This function is available since SDL 3.0.0.
|
||||
*/
|
||||
extern SDL_DECLSPEC SDL_bool SDLCALL SDL_RenamePath(const char *oldpath, const char *newpath);
|
||||
extern SDL_DECLSPEC bool SDLCALL SDL_RenamePath(const char *oldpath, const char *newpath);
|
||||
|
||||
/**
|
||||
* Copy a file.
|
||||
*
|
||||
* \param oldpath the old path.
|
||||
* \param newpath the new path.
|
||||
* \returns SDL_TRUE on success or SDL_FALSE on failure; call SDL_GetError()
|
||||
* \returns true on success or false on failure; call SDL_GetError()
|
||||
* for more information.
|
||||
*
|
||||
* \since This function is available since SDL 3.0.0.
|
||||
*/
|
||||
extern SDL_DECLSPEC SDL_bool SDLCALL SDL_CopyFile(const char *oldpath, const char *newpath);
|
||||
extern SDL_DECLSPEC bool SDLCALL SDL_CopyFile(const char *oldpath, const char *newpath);
|
||||
|
||||
/**
|
||||
* Get information about a filesystem path.
|
||||
|
@ -323,12 +323,12 @@ extern SDL_DECLSPEC SDL_bool SDLCALL SDL_CopyFile(const char *oldpath, const cha
|
|||
* \param path the path to query.
|
||||
* \param info a pointer filled in with information about the path, or NULL to
|
||||
* check for the existence of a file.
|
||||
* \returns SDL_TRUE on success or SDL_FALSE if the file doesn't exist, or
|
||||
* \returns true on success or false if the file doesn't exist, or
|
||||
* another failure; call SDL_GetError() for more information.
|
||||
*
|
||||
* \since This function is available since SDL 3.0.0.
|
||||
*/
|
||||
extern SDL_DECLSPEC SDL_bool SDLCALL SDL_GetPathInfo(const char *path, SDL_PathInfo *info);
|
||||
extern SDL_DECLSPEC bool SDLCALL SDL_GetPathInfo(const char *path, SDL_PathInfo *info);
|
||||
|
||||
/**
|
||||
* Enumerate a directory tree, filtered by pattern, and return a list.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue