void Displaylist::ChooseActiveMap() { QStringList choices; for (int i = 0; i < MapCount(); i++) { if (i >= 100) { break; } EMap *emap = Maps[i]; choices += QString("%1: %2").arg(i).arg(emap->MapID().c_str()); } QString str = QInputDialog::getItem(0, "MIFit", "Choose Map to make active", choices, 0); if (str.isEmpty()) return; int selection = choices.indexOf(str); if (selection < MapCount()) { SetCurrentMap(Maps[selection]); } }