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:
authorTon Roosendaal <ton@blender.org>2009-06-07 15:12:35 +0400
committerTon Roosendaal <ton@blender.org>2009-06-07 15:12:35 +0400
commita2f9ca3b3fcd020e5124b6c3fb6523545377b5e2 (patch)
tree83830cf58852e6b2a6572d36b244bd6bdeddfebc /source/blender/editors/interface/interface.c
parent1bb8d745b914aade700d69220e665096d5db43d0 (diff)
2.5
Nice goodie: Preview renders! - Added new preview.blend, allowing super wide cinemascope previews - Draws nicely blended inside widget type, rounded corners - Preview now renders using all available cpus/cores. - Uses - hopefully rock stable - method, which doesn't copy or allocate anything for previews, but just uses render API calls. - Multiple previews are possible! But, added provision in Jobs manager to only render one preview job at a time. If you start more preview jobs, they're suspended until it's their turn. Bugfix: new buttons context code crashed when going full-window. Tweaks are still needed for notifiers. I have to figure out still how to retrieve SpaceButs button view types...
Diffstat (limited to 'source/blender/editors/interface/interface.c')
-rw-r--r--source/blender/editors/interface/interface.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/source/blender/editors/interface/interface.c b/source/blender/editors/interface/interface.c
index 68973fe540c..740b889dccf 100644
--- a/source/blender/editors/interface/interface.c
+++ b/source/blender/editors/interface/interface.c
@@ -662,12 +662,16 @@ void uiDrawBlock(const bContext *C, uiBlock *block)
else if(block->panel)
ui_draw_aligned_panel(ar, &style, block, &rect);
- if(block->drawextra) block->drawextra(C, block);
-
/* widgets */
for(but= block->buttons.first; but; but= but->next) {
ui_but_to_pixelrect(&rect, ar, block, but);
ui_draw_but(ar, &style, but, &rect);
+
+ /* temp? roundbox defines size/location of preview, and ID type */
+ if(but->type==ROUNDBOX)
+ if(block->drawextra)
+ block->drawextra(C, but->poin, &rect);
+
}
/* restore matrix */
@@ -2968,7 +2972,7 @@ void uiBlockSetRenameFunc(uiBlock *block, uiButHandleRenameFunc func, void *arg1
}
-void uiBlockSetDrawExtraFunc(uiBlock *block, void (*func)())
+void uiBlockSetDrawExtraFunc(uiBlock *block, void (*func)(const bContext *C, void *idv, rcti *rect))
{
block->drawextra= func;
}