Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/wolfpld/tracy.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBartosz Taudul <wolf@nereid.pl>2022-09-28 01:26:03 +0300
committerBartosz Taudul <wolf@nereid.pl>2022-09-28 01:26:03 +0300
commitb3e9a03856129eccd3bc7617d394312c27af9b1a (patch)
treed806b8f4bdd64db41a67c34d762f10bab72d0f59 /profiler
parenta8276c41c34ed0321ddcc9e41623be830fde0a30 (diff)
Check for activity in View.
Diffstat (limited to 'profiler')
-rw-r--r--profiler/src/main.cpp19
1 files changed, 13 insertions, 6 deletions
diff --git a/profiler/src/main.cpp b/profiler/src/main.cpp
index cbf9437d..e67ab0fe 100644
--- a/profiler/src/main.cpp
+++ b/profiler/src/main.cpp
@@ -271,15 +271,22 @@ static void DrawContents()
bptr->NewFrame( display_w, display_h );
static int activeFrames = 3;
- auto& inputQueue = ImGui::GetCurrentContext()->InputEventsQueue;
- if( !inputQueue.empty() )
+ if( view && view->WasActive() )
{
- for( auto& v : inputQueue )
+ activeFrames = 3;
+ }
+ else
+ {
+ auto& inputQueue = ImGui::GetCurrentContext()->InputEventsQueue;
+ if( !inputQueue.empty() )
{
- if( v.Type != ImGuiInputEventType_MouseViewport )
+ for( auto& v : inputQueue )
{
- activeFrames = 3;
- break;
+ if( v.Type != ImGuiInputEventType_MouseViewport )
+ {
+ activeFrames = 3;
+ break;
+ }
}
}
}