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:
authorAntony Riakiotakis <kalast@gmail.com>2013-06-21 03:20:33 +0400
committerAntony Riakiotakis <kalast@gmail.com>2013-06-21 03:20:33 +0400
commite101b043e15630f3427ed648e76f773d604852f2 (patch)
treee92bb288ce7ad6bbc571670bc8cd05818fd921f0 /source/blender/blenkernel/intern/paint.c
parentd3fc2bd95bd722f46e9ad3034e519e4bfcaa41e2 (diff)
Default paint context will be image paint if object is not in a paint mode. It solves not being able to tweak textures in the new texture context button system if an image editor is set up for painting and active object is in object mode.
Diffstat (limited to 'source/blender/blenkernel/intern/paint.c')
-rw-r--r--source/blender/blenkernel/intern/paint.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/source/blender/blenkernel/intern/paint.c b/source/blender/blenkernel/intern/paint.c
index 8218f474620..0dbe4c56a09 100644
--- a/source/blender/blenkernel/intern/paint.c
+++ b/source/blender/blenkernel/intern/paint.c
@@ -189,6 +189,8 @@ Paint *BKE_paint_get_active_from_context(const bContext *C)
return &ts->uvsculpt->paint;
else
return &ts->imapaint.paint;
+ default:
+ return &ts->imapaint.paint;
}
}
else {
@@ -238,6 +240,8 @@ PaintMode BKE_paintmode_get_active_from_context(const bContext *C)
return PAINT_SCULPT_UV;
else
return PAINT_TEXTURE_2D;
+ default:
+ return PAINT_TEXTURE_2D;
}
}
else {