Fix horizontal scroll of main window.

Horizontal mouse scroll (or touchpad action) should map to navigation within
the trace. While this was true in most cases, there was an edge case, when the
top buttons row couldn't be entirely displayed, e.g. due to the window being
resized too small, or due to set zoom level. This change disables scroll
action on the main window, which fixes the issue.
This commit is contained in:
Bartosz Taudul 2022-04-22 22:38:05 +02:00
parent 6f126ce0f5
commit 37a4478127
No known key found for this signature in database
GPG Key ID: B7FE2008B7575DF3

View File

@ -818,7 +818,7 @@ bool View::DrawImpl()
ImGui::SetNextWindowPos( viewport->Pos );
ImGui::SetNextWindowSize( ImVec2( m_rootWidth, m_rootHeight ) );
ImGui::SetNextWindowViewport( viewport->ID );
ImGui::Begin( "Timeline view###Profiler", nullptr, ImGuiWindowFlags_NoScrollbar | ImGuiWindowFlags_NoBringToFrontOnFocus | ImGuiWindowFlags_NoTitleBar | ImGuiWindowFlags_NoResize | ImGuiWindowFlags_NoSavedSettings | ImGuiWindowFlags_NoFocusOnAppearing | ImGuiWindowFlags_NoMove | ImGuiWindowFlags_NoDocking | ImGuiWindowFlags_NoNavFocus );
ImGui::Begin( "Timeline view###Profiler", nullptr, ImGuiWindowFlags_NoScrollbar | ImGuiWindowFlags_NoScrollWithMouse | ImGuiWindowFlags_NoBringToFrontOnFocus | ImGuiWindowFlags_NoTitleBar | ImGuiWindowFlags_NoResize | ImGuiWindowFlags_NoSavedSettings | ImGuiWindowFlags_NoFocusOnAppearing | ImGuiWindowFlags_NoMove | ImGuiWindowFlags_NoDocking | ImGuiWindowFlags_NoNavFocus );
style.WindowRounding = wrPrev;
style.WindowBorderSize = wbsPrev;