WIP mac keyboard cleanup. Possibly fix sticky control.
parent
910a1d6811
commit
49bb37e11d
|
|
@ -175,7 +175,7 @@ void LLKeyboardMacOSX::resetMaskKeys()
|
|||
mKeyLevel[KEY_SHIFT] = TRUE;
|
||||
}
|
||||
|
||||
if(mask & MAC_CTRL_KEY)
|
||||
if(mask & (MAC_CTRL_KEY | MAC_CMD_KEY))
|
||||
{
|
||||
mKeyLevel[KEY_CONTROL] = TRUE;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -250,13 +250,12 @@ attributedStringInfo getSegments(NSAttributedString *str)
|
|||
{
|
||||
// Apparently people still use this?
|
||||
if ([theEvent modifierFlags] & NSCommandKeyMask &&
|
||||
!([theEvent modifierFlags] & NSControlKeyMask) &&
|
||||
!([theEvent modifierFlags] & NSShiftKeyMask) &&
|
||||
!([theEvent modifierFlags] & NSAlternateKeyMask) &&
|
||||
!([theEvent modifierFlags] & NSAlphaShiftKeyMask) &&
|
||||
!([theEvent modifierFlags] & NSFunctionKeyMask) &&
|
||||
!([theEvent modifierFlags] & NSHelpKeyMask))
|
||||
{
|
||||
!([theEvent modifierFlags] & (NSControlKeyMask | NSShiftKeyMask
|
||||
| NSAlternateKeyMask | NSAlphaShiftKeyMask
|
||||
| NSFunctionKeyMask | NSHelpKeyMask)
|
||||
)
|
||||
)
|
||||
{
|
||||
callRightMouseDown(mMousePos, mModifiers);
|
||||
mSimulatedRightClick = true;
|
||||
} else {
|
||||
|
|
@ -562,9 +561,7 @@ attributedStringInfo getSegments(NSAttributedString *str)
|
|||
|
||||
- (void) insertNewline:(id)sender
|
||||
{
|
||||
if (!(mModifiers & NSCommandKeyMask) &&
|
||||
!(mModifiers & NSShiftKeyMask) &&
|
||||
!(mModifiers & NSAlternateKeyMask))
|
||||
if (!(mModifiers & (NSCommandKeyMask | NSShiftKeyMask | NSAlternateKeyMask)))
|
||||
{
|
||||
callUnicodeCallback(13, 0);
|
||||
} else {
|
||||
|
|
|
|||
Loading…
Reference in New Issue