Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2019-02-27 07:07:50 +0300
committerCampbell Barton <ideasman42@gmail.com>2019-02-27 07:09:48 +0300
commit6a03199b50e02d57a50eb24441ef7be0b7e965ac (patch)
treea5e5374cb81742d2c2df05ecf315afaafcaf3d0e /source/blender/makesdna/DNA_screen_types.h
parentea69d9858058e027a8b49d0cf313c8d4abb777a4 (diff)
Cleanup: use '_pad' convention for padding in all DNA structs
Avoids mixing these in with regular variables in code-completion. Use char for pad members except for 'void *', to make size clearer. Removed/shrink a few redundant padding vars which were >= 8 bytes.
Diffstat (limited to 'source/blender/makesdna/DNA_screen_types.h')
-rw-r--r--source/blender/makesdna/DNA_screen_types.h17
1 files changed, 9 insertions, 8 deletions
diff --git a/source/blender/makesdna/DNA_screen_types.h b/source/blender/makesdna/DNA_screen_types.h
index e0dca9cd646..c85042cbf2d 100644
--- a/source/blender/makesdna/DNA_screen_types.h
+++ b/source/blender/makesdna/DNA_screen_types.h
@@ -87,7 +87,7 @@ typedef struct bScreen {
char skip_handling;
/** Set when scrubbing to avoid some costly updates. */
char scrubbing;
- char pad[1];
+ char _pad[1];
/** Active region that has mouse focus. */
struct ARegion *active_region;
@@ -116,7 +116,7 @@ typedef struct ScrEdge {
/** 1 when at edge of screen. */
short border;
short flag;
- int pad;
+ char _pad[4];
} ScrEdge;
typedef struct ScrAreaMap {
@@ -149,7 +149,8 @@ typedef struct Panel {
int sizex, sizey;
/** Panel size excluding children. */
int blocksizex, blocksizey;
- short labelofs, pad;
+ short labelofs;
+ char _pad[2];
short flag, runtime_flag;
short control;
short snap;
@@ -260,7 +261,7 @@ typedef struct TransformOrientation {
/** MAX_NAME. */
char name[64];
float mat[3][3];
- int pad;
+ char _pad[4];
} TransformOrientation;
/** Some preview UI data need to be saved in file. */
@@ -270,7 +271,7 @@ typedef struct uiPreview {
/** Defined as UI_MAX_NAME_STR. */
char preview_id[64];
short height;
- short pad1[3];
+ char _pad1[6];
} uiPreview;
/* These two lines with # tell makesdna this struct can be excluded.
@@ -292,7 +293,7 @@ typedef struct ScrGlobalAreaData {
/** GlobalAreaFlag. */
short flag;
- short pad;
+ char _pad[2];
} ScrGlobalAreaData;
enum GlobalAreaFlag {
@@ -346,7 +347,7 @@ typedef struct ScrArea {
* runtime variable, updated by executing operators.
*/
short region_active_win;
- char temp, pad;
+ char temp, _pad;
/** Callbacks for this space type. */
struct SpaceType *type;
@@ -414,7 +415,7 @@ typedef struct ARegion {
short overlap;
/** Temporary copy of flag settings for clean fullscreen. */
short flagfullscreen;
- short pad1, pad2;
+ char _pad[4];
/** Callbacks for this region type. */
struct ARegionType *type;