Skip to content
Merged
Show file tree
Hide file tree
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
16 changes: 13 additions & 3 deletions editor/animation/animation_bezier_editor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -304,13 +304,23 @@ void AnimationBezierTrackEdit::_notification(int p_what) {
const int v_separation = get_theme_constant(SNAME("h_separation"), SNAME("AnimationBezierTrackEdit"));

if (has_focus(true)) {
draw_rect(Rect2(Point2(), get_size()), focus_color, false, Math::round(EDSCALE));
draw_rect(Rect2(Point2(1, 1), get_size() - Point2(1, 1)), focus_color, false, Math::round(EDSCALE));
}

draw_line(Point2(limit, 0), Point2(limit, get_size().height), v_line_color, Math::round(EDSCALE));

int right_limit = get_size().width;

// Unavailable timeline.
{
int px = (editor->get_current_animation()->get_length() - timeline->get_value()) * timeline->get_zoom_scale() + timeline->get_name_limit();
px = MAX(px, timeline->get_name_limit());
Rect2 rect = Rect2(px, 0, right_limit - px, get_size().height);
if (rect.size.width > 0) {
draw_rect(rect, Color(0, 0, 0, 0.2));
}
}

draw_line(Point2(limit, 0), Point2(limit, get_size().height), v_line_color, Math::round(EDSCALE));

track_v_scroll_max = v_separation;

int vofs = v_separation + track_v_scroll;
Expand Down
Loading