diff --git a/standalone/src/main.cpp b/standalone/src/main.cpp index 6ae6f8aa..a241c233 100644 --- a/standalone/src/main.cpp +++ b/standalone/src/main.cpp @@ -1,6 +1,7 @@ #include #include "imgui_impl_glfw_gl3.h" #include +#include #include #include #include @@ -9,6 +10,7 @@ #ifdef _WIN32 # include +# include #endif #include "../../server/TracyBadVersion.hpp" @@ -20,6 +22,17 @@ static void glfw_error_callback(int error, const char* description) fprintf(stderr, "Error %d: %s\n", error, description); } +void OpenWebpage( const char* url ) +{ +#ifdef _WIN32 + ShellExecuteA( nullptr, nullptr, url, nullptr, nullptr, 0 ); +#else + char buf[1024]; + sprintf( buf, "xdg-open %s", url ); + system( buf ); +#endif +} + int main( int argc, char** argv ) { std::unique_ptr view;