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:
authorBastien Montagne <montagne29@wanadoo.fr>2014-04-02 14:59:48 +0400
committerBastien Montagne <montagne29@wanadoo.fr>2014-04-02 15:03:11 +0400
commit4faef1e10c9d1177eae6350b4471206e91afaff8 (patch)
tree507726457b31e3d27bac0669f709c2bf26804455 /source/blender/blenkernel/intern/screen.c
parent11ee2d8b97ddbdde9ef5a7b77df2b9f9eb2d0e91 (diff)
Add drag-resize to uiTemplatePreview (mat/tex/etc. preview widget).
This is done by adding a new button type, GRIP, similar to other numbuttons (scroll, slider, ...), which here controls the preview height. Then, we add a new DNA struct to be able to save that height in Blend files (note I choose not to use Panel struct for this, because we would then have the same limitation we used to have with uiLists, only one preview per panel and no preview outside panel). This implies a change to template_preview UI RNA/py API (each preview needs an ID), but this is backward compatible, as by default datablock type will be used if no ID is given (which means e.g. all material previews with no ID will have same height). Reviewers: brecht Reviewed By: brecht Differential Revision: https://developer.blender.org/D342
Diffstat (limited to 'source/blender/blenkernel/intern/screen.c')
-rw-r--r--source/blender/blenkernel/intern/screen.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/source/blender/blenkernel/intern/screen.c b/source/blender/blenkernel/intern/screen.c
index f471580547c..ef5507a649f 100644
--- a/source/blender/blenkernel/intern/screen.c
+++ b/source/blender/blenkernel/intern/screen.c
@@ -308,6 +308,7 @@ void BKE_area_region_free(SpaceType *st, ARegion *ar)
}
}
BLI_freelistN(&ar->ui_lists);
+ BLI_freelistN(&ar->ui_previews);
BLI_freelistN(&ar->panels_category);
BLI_freelistN(&ar->panels_category_active);
}