-
Notifications
You must be signed in to change notification settings - Fork 89
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
CSFML: Get rid of "typedef struct" c-ism
- Loading branch information
1 parent
a425cd7
commit 2fc42e9
Showing
8 changed files
with
43 additions
and
62 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,20 +1,18 @@ | ||
#ifndef SFML_RECT_H | ||
#define SFML_RECT_H | ||
|
||
typedef struct | ||
{ | ||
struct sfFloatRect { | ||
float left; | ||
float top; | ||
float width; | ||
float height; | ||
} sfFloatRect; | ||
}; | ||
|
||
typedef struct | ||
{ | ||
struct sfIntRect { | ||
int left; | ||
int top; | ||
int width; | ||
int height; | ||
} sfIntRect; | ||
}; | ||
|
||
#endif // SFML_RECT_H |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,22 +1,19 @@ | ||
#ifndef SFML_VECTOR2_H | ||
#define SFML_VECTOR2_H | ||
|
||
typedef struct | ||
{ | ||
struct sfVector2i { | ||
int x; | ||
int y; | ||
} sfVector2i; | ||
}; | ||
|
||
typedef struct | ||
{ | ||
struct sfVector2u { | ||
unsigned int x; | ||
unsigned int y; | ||
} sfVector2u; | ||
}; | ||
|
||
typedef struct | ||
{ | ||
struct sfVector2f { | ||
float x; | ||
float y; | ||
} sfVector2f; | ||
}; | ||
|
||
#endif // SFML_VECTOR2_H |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,10 @@ | ||
#ifndef SFML_VECTOR3_H | ||
#define SFML_VECTOR3_H | ||
|
||
typedef struct | ||
{ | ||
struct sfVector3f { | ||
float x; | ||
float y; | ||
float z; | ||
} sfVector3f; | ||
}; | ||
|
||
#endif // SFML_VECTOR3_H |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,10 @@ | ||
#ifndef SFML_VIDEOMODE_H | ||
#define SFML_VIDEOMODE_H | ||
|
||
typedef struct | ||
{ | ||
unsigned int width; ///< Video mode width, in pixels | ||
unsigned int height; ///< Video mode height, in pixels | ||
unsigned int bitsPerPixel; ///< Video mode pixel depth, in bits per pixels | ||
} sfVideoMode; | ||
struct sfVideoMode { | ||
unsigned int width; | ||
unsigned int height; | ||
unsigned int bitsPerPixel; | ||
}; | ||
|
||
#endif // SFML_VIDEOMODE_H |