| 125 | } |
| 126 | |
| 127 | void GroupsEditor::_load_scene_groups(Node *p_node) { |
| 128 | List<Node::GroupInfo> groups; |
| 129 | p_node->get_groups(&groups); |
| 130 | |
| 131 | for (const GroupInfo &gi : groups) { |
| 132 | if (!gi.persistent) { |
| 133 | continue; |
| 134 | } |
| 135 | |
| 136 | if (global_groups.has(gi.name)) { |
| 137 | continue; |
| 138 | } |
| 139 | |
| 140 | bool is_editable = can_edit(p_node, gi.name); |
| 141 | if (scene_groups.has(gi.name)) { |
| 142 | scene_groups[gi.name] = scene_groups[gi.name] && is_editable; |
| 143 | } else { |
| 144 | scene_groups[gi.name] = is_editable; |
| 145 | } |
| 146 | } |
| 147 | |
| 148 | for (int i = 0; i < p_node->get_child_count(); i++) { |
| 149 | _load_scene_groups(p_node->get_child(i)); |
| 150 | } |
| 151 | } |
| 152 | |
| 153 | void GroupsEditor::_update_groups() { |
| 154 | if (!is_visible_in_tree()) { |
nothing calls this directly
no test coverage detected