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-04-22 22:39:44 +0400
committerBrecht Van Lommel <brechtvanlommel@pandora.be>2009-04-22 22:39:44 +0400
commitaf02a0aa4e0b80c3c1154e7be095f4a387f81179 (patch)
tree3f714e683c96929cc4e44962570860ab0f635bc9 /source/blender/editors/physics
parent643d59bb9bf3bdd46f41a0b8c79384146629f9c8 (diff)
UI
* Headers and menus can now be created in python. * Replaced the uiMenuItem functions to create menus with equivalent uiItem functions using a layout, removing duplicated code. * More uiItem functions are now exposed to python. * The text editor header, panels and one of its menus are now created in space_text.py. * Buttons window data context icon new changes depending on active object. Issues * Icons are not wrapped yet, hardcoded ints at the moment. * The ID browse template is unfinished.
Diffstat (limited to 'source/blender/editors/physics')
-rw-r--r--source/blender/editors/physics/editparticle.c18
1 files changed, 10 insertions, 8 deletions
diff --git a/source/blender/editors/physics/editparticle.c b/source/blender/editors/physics/editparticle.c
index 96f3ad2f8df..0d58a0bfdcd 100644
--- a/source/blender/editors/physics/editparticle.c
+++ b/source/blender/editors/physics/editparticle.c
@@ -3839,19 +3839,21 @@ void PE_change_act_psys(Scene *scene, Object *ob, ParticleSystem *psys)
static int specials_menu_invoke(bContext *C, wmOperator *op, wmEvent *event)
{
Scene *scene= CTX_data_scene(C);
- uiMenuItem *head;
+ uiPopupMenu *pup;
+ uiLayout *layout;
- head= uiPupMenuBegin("Specials", 0);
+ pup= uiPupMenuBegin("Specials", 0);
+ layout= uiPupMenuLayout(pup);
- uiMenuItemO(head, 0, "PARTICLE_OT_rekey");
+ uiItemO(layout, NULL, 0, "PARTICLE_OT_rekey");
if(scene->selectmode & SCE_SELECT_POINT) {
- uiMenuItemO(head, 0, "PARTICLE_OT_subdivide");
- uiMenuItemO(head, 0, "PARTICLE_OT_select_first");
- uiMenuItemO(head, 0, "PARTICLE_OT_select_last");
+ uiItemO(layout, NULL, 0, "PARTICLE_OT_subdivide");
+ uiItemO(layout, NULL, 0, "PARTICLE_OT_select_first");
+ uiItemO(layout, NULL, 0, "PARTICLE_OT_select_last");
}
- uiMenuItemO(head, 0, "PARTICLE_OT_remove_doubles");
+ uiItemO(layout, NULL, 0, "PARTICLE_OT_remove_doubles");
- uiPupMenuEnd(C, head);
+ uiPupMenuEnd(C, pup);
return OPERATOR_CANCELLED;
}