Skip to content

ImGui::Selectable works only for first item #1556

@kklimek

Description

@kklimek

https://bitbucket.org/kamilklimek/tracy/src/30cc523634c3b8944e69ad5aa48194488d4ac4c6/server/TracyView.cpp?at=selectable-does-not-work&fileviewer=file-view-default#TracyView.cpp-4208

Could you please ivestigate code above. For some reason ImGui::Selectable returns true only for first item in each created TreeNode but ImGui::ItemIsClicked works always. I wasn't able to reproduce it on any minimal code sample or even on imgui demo, thats why I point out whole project, however I hope you will be able to run it.

How to reproduce
Compile and run 'standalone/build/win32/Tracy.sln'
Compile test

In application launched click "Connect"
Run tracy_test
Some data should start showing, click "Find Zone" button
In "Find Zone" window type "Test" and click "Find"
Expand TreeNode, click on first "Test function" and see that if( ImGui::Selectable hits
Click on second "Test function" and see that if( ImGui::Selectable does not hit
Do the same for if( ImGui::IsItemClicked() )

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions