diff options
author | Ton Roosendaal <ton@blender.org> | 2007-04-16 14:55:59 +0400 |
---|---|---|
committer | Ton Roosendaal <ton@blender.org> | 2007-04-16 14:55:59 +0400 |
commit | 3f7bcc44cef02996cd4e5e1186b27187e5ea7168 (patch) | |
tree | 8422b125316e79152c1c998ab6a4eac250e46760 /source/blender/src/butspace.c | |
parent | 41142b05d2f9931314b80aa7aa421c0c7f82a69c (diff) |
Bugfix #6565
Nice discovery by Ralf (cheleb): crasher with colorband, caused by NULL
pointer reading. It actually reveiled a weakness in code too, the
buttonswindow context was not set appropriate when buttons window had not
a header...
Diffstat (limited to 'source/blender/src/butspace.c')
-rw-r--r-- | source/blender/src/butspace.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/source/blender/src/butspace.c b/source/blender/src/butspace.c index 20270f8f00e..e58b3d5542f 100644 --- a/source/blender/src/butspace.c +++ b/source/blender/src/butspace.c @@ -698,11 +698,16 @@ void redraw_test_buttons(Object *new) /* callback */ void drawbutspace(ScrArea *sa, void *spacedata) { + ID *id, *idfrom; SpaceButs *sbuts= sa->spacedata.first; View2D *v2d= &sbuts->v2d; float col[3]; int tab, align=0; + /* context */ + buttons_active_id(&id, &idfrom); + G.buts->lockpoin= id; + myortho2(v2d->cur.xmin, v2d->cur.xmax, v2d->cur.ymin, v2d->cur.ymax); BIF_GetThemeColor3fv(TH_BACK, col); |