1
0
mirror of https://github.com/wolfpld/tracy synced 2025-04-29 12:23:53 +00:00

Fix detection of hovering over source lines.

This commit is contained in:
Bartosz Taudul 2020-04-12 16:21:03 +02:00
parent 0794cf56ff
commit 078014826b

View File

@ -1143,7 +1143,7 @@ void SourceView::RenderLine( const Line& line, int lineNum, uint32_t ipcnt, uint
ImGui::SameLine( 0, ty );
ImGui::TextUnformatted( line.begin, line.end );
if( match > 0 && ImGui::IsMouseHoveringRect( wpos, wpos + ImVec2( w, ty+1 ) ) )
if( match > 0 && ImGui::IsWindowHovered() && ImGui::IsMouseHoveringRect( wpos, wpos + ImVec2( w, ty+1 ) ) )
{
draw->AddRectFilled( wpos, wpos + ImVec2( w, ty+1 ), 0x11FFFFFF );
if( ImGui::IsMouseClicked( 0 ) || ImGui::IsMouseClicked( 1 ) )