1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 16:17:45 +00:00

Profiler: Limit the initial size of the timeline container

If there are a lot of process timeline tracks, we don't want to make the
window gigantic. So let's just put a limit on it.
This commit is contained in:
Andreas Kling 2021-08-18 13:04:40 +02:00
parent 16efe603cb
commit 4eb198baf3

View file

@ -22,7 +22,8 @@ TimelineContainer::TimelineContainer(GUI::Widget& header_container, TimelineView
update_widget_sizes();
update_widget_positions();
set_fixed_height(timeline_view.height() + frame_thickness() * 2);
int initial_height = min(300, timeline_view.height() + frame_thickness() * 2);
set_fixed_height(initial_height);
m_timeline_view->on_scale_change = [this] {
update_widget_sizes();