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>2013-08-22 01:35:45 +0400
committerBastien Montagne <montagne29@wanadoo.fr>2013-08-22 01:35:45 +0400
commitc26a4be5c013650f339f446185339aa71f2b88c4 (patch)
tree6879a4f3030d1e75206a4cb50ed4c00343b91247 /source/blender/makesdna
parent2a5b6d9c8f167724d2ddd2bf1a2b59036121ac81 (diff)
Fix [#36530] Texture tab refreshing problem
That was not really a bug (code working as expected), but the way tex context was handled was a bit raw, now it is much smarter: * Default fallback context (when current one is no more valid) will now choose "most specific" ones first (i.e. material/lamp/particules before world and "others"). * When using that default fallback context, previous one is stored and we try to revive it later, if possible. Thus e.g. object[mat tex ctxt] -> empty[default world ctxt] -> object[mat tex ctxt] is now working as expected. * However, when user explicitely or implicitely (through e.g. going to Material context...) sets a tex context, previous one is not stored, so that only default fallback context switch may later automatically revive a previous (presumably user-set) context.
Diffstat (limited to 'source/blender/makesdna')
-rw-r--r--source/blender/makesdna/DNA_space_types.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/source/blender/makesdna/DNA_space_types.h b/source/blender/makesdna/DNA_space_types.h
index 3e1196fb45a..5c308083f3c 100644
--- a/source/blender/makesdna/DNA_space_types.h
+++ b/source/blender/makesdna/DNA_space_types.h
@@ -132,8 +132,9 @@ typedef struct SpaceButs {
short mainb, mainbo, mainbuser; /* context tabs */
short re_align, align; /* align for panels */
short preview; /* preview is signal to refresh */
- short texture_context; /* texture context selector (material, world, brush)*/
- char flag, pad;
+ /* texture context selector (material, lamp, particles, world, other)*/
+ short texture_context, texture_context_prev;
+ char flag, pad[7];
void *path; /* runtime */
int pathflag, dataicon; /* runtime */