Skip to content

Fix 4193 - set hidden_by_parent when adding to displayio group #4915

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jun 24, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions shared-module/displayio/Group.c
Original file line number Diff line number Diff line change
Expand Up @@ -258,6 +258,8 @@ static void _add_layer(displayio_group_t *self, mp_obj_t layer) {
tilegrid->in_group = true;
}
displayio_tilegrid_update_transform(tilegrid, &self->absolute_transform);
displayio_tilegrid_set_hidden_by_parent(
tilegrid, self->hidden || self->hidden_by_parent);
return;
}
native_layer = mp_obj_cast_to_native_base(layer, &displayio_group_type);
Expand All @@ -269,6 +271,8 @@ static void _add_layer(displayio_group_t *self, mp_obj_t layer) {
group->in_group = true;
}
displayio_group_update_transform(group, &self->absolute_transform);
displayio_group_set_hidden_by_parent(
group, self->hidden || self->hidden_by_parent);
return;
}
mp_raise_ValueError(translate("Layer must be a Group or TileGrid subclass."));
Expand Down