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-06-09 20:18:23 +0400
committerBastien Montagne <montagne29@wanadoo.fr>2013-06-09 20:18:23 +0400
commit0123c7d2be0036435192318a2a3fa7949bc3d5f7 (patch)
treec635749563ffda7550224cb5790a24e1c7579130 /source/blender/makesrna/intern/rna_screen.c
parent49115b4dd38443c77b18f0b627a97f60975ada1d (diff)
This commit replaces old "manual" Editors menu with nice RNA-based one (so once again, some cleanup of old UI code). It makes the following changes:
* RNA's editor types enum (space_type_items) has been re-ordered, added icons, and removed internal-only SPACE_EMPTY value, so that it matches the menu. * Two fixes in code drawing enums as dropdown menu: ** All items were taken into account when computing the number of needed columns, now simple separators (void string items) are ignored. ** Simple separators items were drawn as labels, taking far too much space! And now translators will be free from that ugly, insane menu-string! :P Thanks to Brecht for the review.
Diffstat (limited to 'source/blender/makesrna/intern/rna_screen.c')
-rw-r--r--source/blender/makesrna/intern/rna_screen.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/source/blender/makesrna/intern/rna_screen.c b/source/blender/makesrna/intern/rna_screen.c
index 32e388598f5..7db522d7f5e 100644
--- a/source/blender/makesrna/intern/rna_screen.c
+++ b/source/blender/makesrna/intern/rna_screen.c
@@ -105,6 +105,7 @@ static int rna_Screen_fullscreen_get(PointerRNA *ptr)
return (sc->full != 0);
}
+
static void rna_Area_type_set(PointerRNA *ptr, int value)
{
ScrArea *sa = (ScrArea *)ptr->data;
@@ -204,8 +205,9 @@ static void rna_def_area(BlenderRNA *brna)
RNA_def_property_enum_sdna(prop, NULL, "spacetype");
RNA_def_property_enum_items(prop, space_type_items);
RNA_def_property_enum_funcs(prop, NULL, "rna_Area_type_set", NULL);
- RNA_def_property_ui_text(prop, "Type", "Space type");
+ RNA_def_property_ui_text(prop, "Editor Type", "Current editor type for this area");
RNA_def_property_flag(prop, PROP_CONTEXT_UPDATE);
+ RNA_def_property_clear_flag(prop, PROP_ANIMATABLE);
RNA_def_property_update(prop, 0, "rna_Area_type_update");
prop = RNA_def_property(srna, "x", PROP_INT, PROP_NONE);