Skip to content
This repository has been archived by the owner on Oct 1, 2023. It is now read-only.

Commit

Permalink
Simplify OpenURL() usage (#528)
Browse files Browse the repository at this point in the history
  • Loading branch information
calcmogul authored Sep 29, 2023
1 parent 62e7b3d commit 4063da8
Showing 1 changed file with 3 additions and 9 deletions.
12 changes: 3 additions & 9 deletions sysid-application/src/main/native/cpp/App.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -166,10 +166,11 @@ void Application(std::string_view saveDir) {
ImGui::EndMenu();
}

bool docs = false;
if (ImGui::BeginMenu("Docs")) {
if (ImGui::MenuItem("Online documentation")) {
docs = true;
wpi::gui::OpenURL(
"https://docs.wpilib.org/en/stable/docs/software/pathplanning/"
"system-identification/");
}

ImGui::EndMenu();
Expand All @@ -182,13 +183,6 @@ void Application(std::string_view saveDir) {
toCSV = false;
}

if (docs) {
wpi::gui::OpenURL(
"https://docs.wpilib.org/en/stable/docs/software/pathplanning/"
"system-identification/");
docs = false;
}

if (ImGui::BeginPopupModal("SysId JSON to CSV Converter")) {
gJSONConverter->DisplayCSVConvert();
if (ImGui::Button("Close")) {
Expand Down

0 comments on commit 4063da8

Please sign in to comment.