Ticket #3495: t3495_fix_hotkey_combos_v1.patch
File t3495_fix_hotkey_combos_v1.patch, 1.2 KB (added by , 9 years ago) |
---|
-
source/ps/Hotkey.cpp
void LoadHotkeys() 125 125 bool allNegated = true; 126 126 127 127 for (const SKey& k : hotkey.requires) 128 128 if (!k.negated) 129 129 allNegated = false; 130 130 131 131 if (allNegated) 132 132 g_HotkeyStatus[hotkey.name] = true; 133 133 } 134 134 } 135 135 … … InReaction HotkeyInputHandler(const SDL_ 297 297 continue; 298 298 299 299 // Check for no unpermitted keys 300 300 bool accept = true; 301 301 for (const SKey& k : hotkey.requires) 302 { 302 303 accept = isNegated(k); 304 if (!accept) 305 break; 306 } 303 307 304 308 if (accept && !(consoleCapture && hotkey.name != "console.toggle")) 305 309 { 306 310 // Check if this is an equally precise or more precise match 307 311 if (hotkey.requires.size() + 1 >= closestMapMatch) … … InReaction HotkeyInputHandler(const SDL_ 339 343 continue; 340 344 341 345 // Check for no unpermitted keys 342 346 bool accept = true; 343 347 for (const SKey& k : hotkey.requires) 348 { 344 349 accept = isNegated(k); 350 if (!accept) 351 break; 352 } 345 353 346 354 if (accept) 347 355 { 348 356 SDL_Event_ hotkeyNotification; 349 357 hotkeyNotification.ev.type = SDL_HOTKEYUP;