MCPcopy Create free account
hub / github.com/OpenStarbound/OpenStarbound / printInputDescriptor

Function printInputDescriptor

source/windowing/StarKeyBindings.cpp:136–144  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

134}
135
136String printInputDescriptor(KeyChord chord) {
137 StringList modNames;
138 for (auto const& p : KeyModNames) {
139 if ((chord.mods & p.first) != KeyMod::NoMod)
140 modNames.append(p.second);
141 }
142
143 return String::joinWith(" + ", modNames.join(" + "), KeyNames.getRight(chord.key));
144}
145
146KeyBindings::KeyBindings() {}
147

Callers 1

setKeybindingMethod · 0.85

Calls 2

appendMethod · 0.45
joinMethod · 0.45

Tested by

no test coverage detected