Hi, I think you may look at keyboardHandler.py in different functions including internal_keyDownEvent, internal_keyUpEvent and _reportToggleKey, since there are things that maybe common to other modifiers, not just capsLoc.
Alberto: Yeah, found. Thanks Noelia, I forgot the other toggle keys, so I have no results in search previously. Alberto