Sim GUI: Add a bit of spacing to the analog inputs (#2170)

This helps make it clear they are separate controls.
This commit is contained in:
Peter Johnson
2019-12-14 10:49:01 -08:00
committed by GitHub
parent b78f115fcf
commit f8294e689b

View File

@@ -24,9 +24,18 @@ static void DisplayAnalogInputs() {
bool hasInputs = false;
static int numAnalog = HAL_GetNumAnalogInputs();
static int numAccum = HAL_GetNumAccumulators();
bool first = true;
for (int i = 0; i < numAnalog; ++i) {
if (HALSIM_GetAnalogInInitialized(i)) {
hasInputs = true;
if (!first) {
ImGui::Spacing();
ImGui::Spacing();
} else {
first = false;
}
char name[32];
std::snprintf(name, sizeof(name), "In[%d]", i);
if (i < numAccum && HALSIM_GetAnalogGyroInitialized(i)) {