display a sample line in the hue correct, handy to sample the image to know what...
[blender.git] / source / blender / editors / space_image / image_ops.c
index 7e67e737cc2bd645336dc8088c174919e285959c..3dc1fbd738fe7f346ecb73779ce1ae4c835ae44e 100644 (file)
@@ -1926,6 +1926,7 @@ static void image_sample_apply(bContext *C, wmOperator *op, wmEvent *event)
        
        if (ibuf == NULL) {
                ED_space_image_release_buffer(sima, lock);
+               info->draw = 0;
                return;
        }
 
@@ -2018,8 +2019,9 @@ static void image_sample_apply(bContext *C, wmOperator *op, wmEvent *event)
                }
 #endif
        }
-       else
+       else {
                info->draw = 0;
+       }
 
        ED_space_image_release_buffer(sima, lock);
        ED_area_tag_redraw(CTX_wm_area(C));