Merge remote-tracking branch 'origin/blender-v3.5-release' into main

This commit is contained in:
Germano Cavalcante
2023-03-27 10:28:22 -03:00
3 changed files with 10 additions and 4 deletions

View File

@@ -34,7 +34,7 @@ bke::SpanAttributeWriter<float> float_selection_ensure(Curves &curves_id)
attributes.add(".selection",
domain,
CD_PROP_FLOAT,
bke::AttributeInitVArray(VArray<float>::ForSingle(size, 1.0f)));
bke::AttributeInitVArray(VArray<float>::ForSingle(1.0f, size)));
}
return curves.attributes_for_write().lookup_for_write_span<float>(".selection");

View File

@@ -142,7 +142,7 @@ typedef enum {
/** Do not display Xform gizmo even though it is available. */
T_NO_GIZMO = 1 << 24,
} eTFlag;
ENUM_OPERATORS(eTFlag, T_NO_CURSOR_WRAP);
ENUM_OPERATORS(eTFlag, T_NO_GIZMO);
#define T_ALL_RESTRICTIONS (T_NO_CONSTRAINT | T_NULL_ONE)
#define T_PROP_EDIT_ALL (T_PROP_EDIT | T_PROP_CONNECTED | T_PROP_PROJECTED)

View File

@@ -2219,7 +2219,13 @@ void VIEW3D_GGT_xform_gizmo_context(wmGizmoGroupType *gzgt)
static wmGizmoGroup *gizmogroup_xform_find(TransInfo *t)
{
wmGizmo *gizmo_modal_current = WM_gizmomap_get_modal(t->region->gizmo_map);
struct wmGizmoMap *gizmo_map = t->region->gizmo_map;
if (gizmo_map == nullptr) {
BLI_assert_msg(false, "#T_NO_GIZMO should already be set to return early before.");
return nullptr;
}
wmGizmo *gizmo_modal_current = WM_gizmomap_get_modal(gizmo_map);
if (gizmo_modal_current) {
wmGizmoGroup *gzgroup = gizmo_modal_current->parent_gzgroup;
/* Check #wmGizmoGroup::customdata to make sure the GizmoGroup has been initialized. */
@@ -2229,7 +2235,7 @@ static wmGizmoGroup *gizmogroup_xform_find(TransInfo *t)
}
else {
/* See #WM_gizmomap_group_find_ptr. */
LISTBASE_FOREACH (wmGizmoGroup *, gzgroup, WM_gizmomap_group_list(t->region->gizmo_map)) {
LISTBASE_FOREACH (wmGizmoGroup *, gzgroup, WM_gizmomap_group_list(gizmo_map)) {
if (ELEM(gzgroup->type, g_GGT_xform_gizmo, g_GGT_xform_gizmo_context)) {
/* Choose the one that has been initialized. */
if (gzgroup->customdata) {