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:
authorBrecht Van Lommel <brechtvanlommel@pandora.be>2009-06-20 18:55:28 +0400
committerBrecht Van Lommel <brechtvanlommel@pandora.be>2009-06-20 18:55:28 +0400
commitad07fc19c0fb97540bfe8d259c0b39098b9d7b9b (patch)
treeb65d7c340dc32cd6e7988bea3266962176568d9b /source/blender/editors/space_text
parent980dab90282ab3ca63ac44b174344a6607934fb9 (diff)
Context
Python dir(context) now gives the items from the data context too, modified context callbacks to also return a list of items in the context.
Diffstat (limited to 'source/blender/editors/space_text')
-rw-r--r--source/blender/editors/space_text/space_text.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/source/blender/editors/space_text/space_text.c b/source/blender/editors/space_text/space_text.c
index d3c3b78cc50..8759fd00f74 100644
--- a/source/blender/editors/space_text/space_text.c
+++ b/source/blender/editors/space_text/space_text.c
@@ -293,7 +293,12 @@ static int text_context(const bContext *C, const char *member, bContextDataResul
{
SpaceText *st= CTX_wm_space_text(C);
- if(CTX_data_equals(member, "edit_text")) {
+ if(CTX_data_dir(member)) {
+ static const char *dir[] = {"edit_text", NULL};
+ CTX_data_dir_set(result, dir);
+ return 1;
+ }
+ else if(CTX_data_equals(member, "edit_text")) {
CTX_data_id_pointer_set(result, &st->text->id);
return 1;
}