View2D: Cleanup of presets and fixed errors in various views
[blender.git] / source / blender / editors / space_image / image_header.c
index 44b068cebc17d67c7d841610148467abf96860be..a9cf0e03fe8d623d73c5228ec87ec9929bd913a1 100644 (file)
@@ -123,7 +123,7 @@ void image_header_buttons(const bContext *C, ARegion *ar)
        uiBlockSetEmboss(block, UI_EMBOSS);
 
        /* always as last  */
-       sa->headbutlen= xco+XIC+80; // +80 because the last button is not an icon
+       UI_view2d_totRect_set(&ar->v2d, xco+XIC+80, ar->v2d.tot.ymax-ar->v2d.tot.ymin);
        
        uiEndBlock(C, block);
        uiDrawBlock(block);