Some comments: * The object mode menu is too narrow now, the tranform space menu too wide. * EnumPropertyItem manipulators_items[] values should not have MANIPULATOR_ prefix for the item identifiers. * Regarding PROP_ENUM_NO_CONTEXT in rna_access.c. This is to ensure the callback always gets the same NULL pointer, to avoid subtle bugs due to things working ok in some usage of the callback but crashing in others. Not sure if you needed this to make things work, things can be unreliable when enum items give different results depending if context happens to be available but maybe it goes fine here.
On Sat, May 11, 2013 at 3:11 PM, Bastien Montagne <montagn...@wanadoo.fr> wrote: > Hi devs, > > Here is a patch that was first intended to fix [#35224] "Transform > orientation - order inconsistency" : http://www.pasteall.org/42132/diff > > It’s not a big deal in itself, but as it affects quite a few areas, I > thought it would be better to post it here, so that all core devs have a > chance to give it a look. > > This patch adds several fixes/enhancements/simplifications (deduplications): > * Its main goal is to remove as much "manual UI" from 3D view header as > possible. In current state, it moves mode selector and all transform > manipulators/orientations stuff to RNA (leaving basically only edit mesh > select modes with custom handlers, as they have some quite specific > features). > * To achieve this, three main modifications were done: > ** enum-operator-generated menus are now PULLDOWN in headers too. > ** All bit-flag enums expanded in ROW buttons now have a handling > consistent with e.g. layers, or what we already have for transform > manipulators, i.e. clicking select only one element, shift-click to > select multiple ones. > ** Consequently, the three RNA booleans manipulators flags are merged > into a single bit-flag enum (yes, this is also an API change, though I > doubt many scripts use it). > > All this allows to remove some code in 3DView/transform areas, that was > actually mostly duplicating RNA/operator one. > > Also done a few optimizations here and there (among other, do not pass > &numitems to RNA_property_enum_items() when you do not need it, saves at > least an iteration over enum items to count them ;) ). > > Best regards, > Bastien > _______________________________________________ > Bf-committers mailing list > Bf-committers@blender.org > http://lists.blender.org/mailman/listinfo/bf-committers _______________________________________________ Bf-committers mailing list Bf-committers@blender.org http://lists.blender.org/mailman/listinfo/bf-committers