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:
Diffstat (limited to 'source/blender/src/interface_icons.c')
-rw-r--r--source/blender/src/interface_icons.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/source/blender/src/interface_icons.c b/source/blender/src/interface_icons.c
index d245e0e1427..dc487ae72fe 100644
--- a/source/blender/src/interface_icons.c
+++ b/source/blender/src/interface_icons.c
@@ -733,8 +733,11 @@ void BIF_icon_draw(float x, float y, int icon_id)
ui_rasterpos_safe(x, y, di->aspect);
+ if(di->w<1 || di->h<1) {
+ printf("what the heck!\n");
+ }
/* di->rect contains image in 'rendersize', we only scale if needed */
- if(di->rw!=di->w && di->rh!=di->h) {
+ else if(di->rw!=di->w && di->rh!=di->h) {
ImBuf *ima;
/* first allocate imbuf for scaling and copy preview into it */
ima = IMB_allocImBuf(di->rw, di->rh, 32, IB_rect, 0);