diff --git a/profiler/src/main.cpp b/profiler/src/main.cpp index ac70ae97..021ceb71 100644 --- a/profiler/src/main.cpp +++ b/profiler/src/main.cpp @@ -32,6 +32,7 @@ #include "../../server/tracy_pdqsort.h" #include "../../server/tracy_robin_hood.h" #include "../../server/TracyBadVersion.hpp" +#include "../../server/TracyFileHeader.hpp" #include "../../server/TracyFileRead.hpp" #include "../../server/TracyImGui.hpp" #include "../../server/TracyMouse.hpp" @@ -617,6 +618,16 @@ static void DrawContents() { OpenWebpage( "https://github.com/sponsors/wolfpld/" ); } + if( updateVersion != 0 && updateVersion > tracy::FileVersion( tracy::Version::Major, tracy::Version::Minor, tracy::Version::Patch ) ) + { + ImGui::Separator(); + ImGui::TextColored( ImVec4( 1, 1, 0, 1 ), ICON_FA_EXCLAMATION_TRIANGLE " Update to %i.%i.%i is available!", ( updateVersion >> 16 ) & 0xFF, ( updateVersion >> 8 ) & 0xFF, updateVersion & 0xFF ); + ImGui::SameLine(); + if( ImGui::SmallButton( ICON_FA_DOWNLOAD " Get it!" ) ) + { + OpenWebpage( "https://github.com/wolfpld/tracy/releases" ); + } + } ImGui::Separator(); ImGui::TextUnformatted( "Client address" ); bool connectClicked = false;