MCPcopy Create free account
hub / github.com/clementgallet/libTAS / default_hotkey

Method default_hotkey

src/program/KeyMapping.cpp:247–263  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

245}
246
247void KeyMapping::default_hotkey(int hotkey_index)
248{
249 /* Hotkey selected */
250 HotKey hk = hotkey_list[hotkey_index];
251
252 /* Remove previous mapping from this key */
253 for (auto iter : hotkey_mapping) {
254 if (iter.second == hk) {
255 hotkey_mapping.erase(iter.first);
256 break;
257 }
258 }
259
260 if (hk.default_input.type == SingleInput::IT_KEYBOARD)
261 hotkey_mapping[hk.default_input.which] = hk;
262
263}
264
265void KeyMapping::reassign_hotkey(int hotkey_index, keysym_t ks)
266{

Callers 1

slotDefaultMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected