1
0
mirror of https://github.com/wolfpld/tracy.git synced 2025-03-20 07:40:02 +08:00

Keep one profiler window size for all captures.

This commit is contained in:
Bartosz Taudul
2018-07-10 20:47:09 +02:00
parent 27a1eb94fe
commit 045f792e84
2 changed files with 8 additions and 2 deletions
+6 -2
View File
@@ -333,7 +333,9 @@ bool View::DrawImpl()
{
if( !m_worker.HasData() )
{
ImGui::Begin( m_worker.GetAddr().c_str(), nullptr, ImGuiWindowFlags_AlwaysAutoResize );
char tmp[2048];
sprintf( tmp, "%s###Connection", m_worker.GetAddr().c_str() );
ImGui::Begin( tmp, nullptr, ImGuiWindowFlags_AlwaysAutoResize );
ImGui::Text( "Waiting for connection..." );
ImGui::End();
return true;
@@ -359,7 +361,9 @@ bool View::DrawImpl()
}
std::lock_guard lock( m_worker.GetDataLock() );
ImGui::Begin( m_worker.GetCaptureName().c_str(), keepOpenPtr, ImVec2( 1550, 800 ), -1, ImGuiWindowFlags_NoScrollbar );
char tmp[2048];
sprintf( tmp, "%s###Profiler", m_worker.GetCaptureName().c_str() );
ImGui::Begin( tmp, keepOpenPtr, ImVec2( 1550, 800 ), -1, ImGuiWindowFlags_NoScrollbar );
if( !m_worker.IsDataStatic() )
{
if( ImGui::Button( m_pause ? MainWindowButtons[0] : MainWindowButtons[1], ImVec2( bw, 0 ) ) ) m_pause = !m_pause;