### Godot version

4.0.rc

### System information

Any

### Issue description

If the RESET animation is generated at the same time as the Bezier track is generated, the bezier edit button will not be active.

![image](https://user-images.githubusercontent.com/61938263/218256176-88b1b196-7b6b-4404-84ad-e8694f23bb1b.png)

Also, if you delete a track in the Bezier Editor, or in undo redo, it will not update correctly.

### Steps to reproduce

![image](https://user-images.githubusercontent.com/61938263/218256230-4b0219d5-87e4-453a-8294-59f8feb0cfd5.png)


### Minimal reproduction project

N/A
int limit_end = get_size().width - timeline->get_buttons_width();
				for (int i = 0; i < animation->track_get_key_count(track); i++) {
					float offset = animation->track_get_key_time(track, i) - timeline->get_value();
					if (editor->is_key_selected(track, i) && editor->is_moving_selection()) {
						offset = editor->snap_time(offset + editor->get_moving_selection_offset(), true);
					}
					offset = offset * scale + limit;
					if (i < animation->track_get_key_count(track) - 1) {
						float offset_n = animation->track_get_key_time(track, i + 1) - timeline->get_value();
						if (editor->is_key_selected(track, i + 1) && editor->is_moving_selection()) {
							offset_n = editor->snap_time(offset_n + editor->get_moving_selection_offset());
						}
						offset_n = offset_n * scale + limit;
						draw_key_link(i, scale, int(offset), int(offset_n), limit, limit_end);
					}
					draw_key(i, scale, int(offset), editor->is_key_selected(track, i), limit, limit_end);
				}
			}
			draw_fg(limit, get_size().width - timeline->get_buttons_width());
			
			{
				Ref<Texture2D> wrap_icon[2] = {
					get_theme_icon(SNAME("InterpWrapClamp"), SNAME("EditorIcons")),
					get_theme_icon(SNAME("InterpWrapLoop"), SNAME("EditorIcons")),
				};
				Ref<Texture2D> interp_icon[5] = {
					get_theme_icon(SNAME("InterpRaw"), SNAME("EditorIcons")),
					get_theme_icon(SNAME("InterpLinear"), SNAME("EditorIcons")),
					get_theme_icon(SNAME("InterpCubic"), SNAME("EditorIcons")),
					get_theme_icon(SNAME("InterpLinearAngle"), SNAME("EditorIcons")),