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>2011-05-01 14:14:09 +0400
committerCampbell Barton <ideasman42@gmail.com>2011-05-01 14:14:09 +0400
commit1093f69e506e56e0bf605c44aefc34d6f9bc27fe (patch)
treed639e38ba6021c1e307bca0ba31a54f47a1fdec4 /source/blender/editors/interface/interface_draw.c
parentb6ec6e5ca54ae7d5747f7aa6412be1ab6103ce2d (diff)
Style Cleanup
- duplicate cases in if/else - calc inside sizeof(...) - redundant NULL checks. - assignment to self. - fix error getting text prefix for screen ID button.
Diffstat (limited to 'source/blender/editors/interface/interface_draw.c')
-rw-r--r--source/blender/editors/interface/interface_draw.c14
1 files changed, 12 insertions, 2 deletions
diff --git a/source/blender/editors/interface/interface_draw.c b/source/blender/editors/interface/interface_draw.c
index c9b5b9f2848..f9c97c36bdd 100644
--- a/source/blender/editors/interface/interface_draw.c
+++ b/source/blender/editors/interface/interface_draw.c
@@ -1578,7 +1578,7 @@ void uiDrawBoxShadow(unsigned char alpha, float minx, float miny, float maxx, fl
}
-void ui_dropshadow(rctf *rct, float radius, float aspect, int select)
+void ui_dropshadow(rctf *rct, float radius, float aspect, int UNUSED(select))
{
int i;
float rad;
@@ -1593,7 +1593,17 @@ void ui_dropshadow(rctf *rct, float radius, float aspect, int select)
rad= radius;
i= 12;
- if(select) a= i*aspect; else a= i*aspect;
+#if 0
+ if(select) {
+ a= i*aspect; /* same as below */
+ }
+ else
+#endif
+ {
+ a= i*aspect;
+
+ }
+
for(; i--; a-=aspect) {
/* alpha ranges from 2 to 20 or so */
glColor4ub(0, 0, 0, alpha);