| 28 | } |
| 29 | |
| 30 | std::string KeyBinding::to_string() const { |
| 31 | std::string keys = (this->getKey() == ImGuiKey_None) ? "" : ImGui::GetKeyName(this->getKey()); |
| 32 | |
| 33 | auto modifiers = this->getModifiers(); |
| 34 | for (auto im = modifiers.rbegin(); im != modifiers.rend(); ++im ) { |
| 35 | keys = std::string(ImGui::GetKeyName(*im)) + "+" + keys; |
| 36 | } |
| 37 | |
| 38 | return keys; |
| 39 | } |
no test coverage detected