diff --git a/indra/llwindow/llkeyboardmacosx.cpp b/indra/llwindow/llkeyboardmacosx.cpp
index 3db94e8835..59cc2acaec 100644
--- a/indra/llwindow/llkeyboardmacosx.cpp
+++ b/indra/llwindow/llkeyboardmacosx.cpp
@@ -200,9 +200,25 @@ static BOOL translateKeyMac(const U16 key, const U32 mask, KEY &outKey, U32 &out
MASK LLKeyboardMacOSX::updateModifiers(const U32 mask)
{
- // This is handled for us in LLNSWindow on OS X.
-
- return mask;
+ // translate the mask
+ MASK out_mask = 0;
+
+ if(mask & MAC_SHIFT_KEY)
+ {
+ out_mask |= MASK_SHIFT;
+ }
+
+ if(mask & MAC_CTRL_KEY || mask & MAC_CMD_KEY)
+ {
+ out_mask |= MASK_CONTROL;
+ }
+
+ if(mask & MAC_ALT_KEY)
+ {
+ out_mask |= MASK_ALT;
+ }
+
+ return out_mask;
}
BOOL LLKeyboardMacOSX::handleKeyDown(const U16 key, const U32 mask)
@@ -232,6 +248,7 @@ BOOL LLKeyboardMacOSX::handleKeyUp(const U16 key, const U32 mask)
if(translateNumpadKey(key, &translated_key))
{
+ LL_INFOS("Keyboard") << "Handled key!" << LL_ENDL;
handled = handleTranslatedKeyUp(translated_key, translated_mask);
}
@@ -252,8 +269,8 @@ MASK LLKeyboardMacOSX::currentMask(BOOL for_mouse_event)
{
if (mask & MAC_CMD_KEY) result |= MASK_CONTROL;
}
-
- return mask;
+
+ return result;
}
void LLKeyboardMacOSX::scanKeyboard()
diff --git a/indra/llwindow/llopenglview-objc.mm b/indra/llwindow/llopenglview-objc.mm
index d91601152b..25669b25d3 100644
--- a/indra/llwindow/llopenglview-objc.mm
+++ b/indra/llwindow/llopenglview-objc.mm
@@ -190,6 +190,11 @@
[_window flagsChanged:theEvent];
}
+- (void) mouseExited:(NSEvent *)theEvent
+{
+ [_window mouseExited:theEvent];
+}
+
- (BOOL) becomeFirstResponder
{
return [_window becomeFirstResponder];
@@ -217,6 +222,7 @@
- (void) keyDown:(NSEvent *)theEvent
{
callKeyDown([theEvent keyCode], mModifiers);
+ NSLog(@"Keycode: %hu", [theEvent keyCode]);
NSString *chars = [theEvent characters];
for (uint i = 0; i < [chars length]; i++)
{
@@ -254,30 +260,7 @@
}
- (void)flagsChanged:(NSEvent *)theEvent {
- uint modifiers = [theEvent modifierFlags];
-
- // Filter through our modifier keys, and only pick out the ones we care about.
-
- mModifiers = 0;
- if (modifiers & NSCommandKeyMask)
- {
- mModifiers |= 0x0001;
- }
-
- if (modifiers & NSAlternateKeyMask)
- {
- mModifiers |= 0x0002;
- }
-
- if (modifiers & NSShiftKeyMask)
- {
- mModifiers |= 0x0004;
- }
-
- if (modifiers & NSControlKeyMask)
- {
- mModifiers |= 0x0001;
- }
+ mModifiers = [theEvent modifierFlags];
}
- (void) mouseDown:(NSEvent *)theEvent
diff --git a/indra/newview/SecondLife.nib b/indra/newview/SecondLife.nib
index cd69b1b812..ca89033300 100644
Binary files a/indra/newview/SecondLife.nib and b/indra/newview/SecondLife.nib differ
diff --git a/indra/newview/SecondLife.xib b/indra/newview/SecondLife.xib
index 212bc5830d..b4e77279fd 100644
--- a/indra/newview/SecondLife.xib
+++ b/indra/newview/SecondLife.xib
@@ -193,29 +193,6 @@
-
-
-
-
-
-
@@ -350,23 +281,6 @@
-
-
-
-
-
-
-
-
@@ -776,13 +393,10 @@
{1024, 768}
{{0, 0}, {1920, 1178}}
@@ -834,30 +448,6 @@
39
-
-
-
- runPageLayout:
-
-
-
- 87
-
-
-
- clearRecentDocuments:
-
-
-
- 127
-
performClose:
@@ -882,22 +472,6 @@
360
-
-
- saveDocument:
-
-
-
- 362
-
-
-
- revertDocumentToSaved:
-
-
-
- 364
-
hide:
@@ -938,38 +512,6 @@
769
-
-
- toggleSmartInsertDelete:
-
-
-
- 770
-
-
-
- toggleAutomaticDashSubstitution:
-
-
-
- 773
-
-
-
- toggleContinuousSpellChecking:
-
-
-
- 774
-
-
-
- toggleAutomaticDataDetection:
-
-
-
- 775
-
undo:
@@ -978,30 +520,6 @@
776
-
-
- startSpeaking:
-
-
-
- 778
-
-
-
- showGuessPanel:
-
-
-
- 779
-
-
-
- checkSpelling:
-
-
-
- 780
-
copy:
@@ -1010,14 +528,6 @@
782
-
-
- delete:
-
-
-
- 783
-
selectAll:
@@ -1026,38 +536,6 @@
785
-
-
- stopSpeaking:
-
-
-
- 786
-
-
-
- orderFrontSubstitutionsPanel:
-
-
-
- 787
-
-
-
- toggleAutomaticTextReplacement:
-
-
-
- 788
-
-
-
- toggleAutomaticSpellingCorrection:
-
-
-
- 790
-
toggleFullScreen:
@@ -1150,85 +628,18 @@
81
-
-
-
-
-
-
-
- 75
-
-
-
-
- 78
-
-
-
-
- 72
-
-
-
-
- 82
-
-
-
-
- 124
-
-
-
-
-
-
-
- 77
-
-
-
73
-
- 79
-
-
-
-
- 112
-
-
-
-
- 74
-
-
-
-
- 125
-
-
-
-
-
-
-
- 126
-
-
-
106
@@ -1373,33 +784,10 @@
-
-
-
-
-
-
-
-
-
- 713
-
-
-
-
- 714
-
-
-
-
- 715
-
-
-
716
@@ -1415,251 +803,11 @@
-
- 719
-
-
-
-
- 720
-
-
-
721
-
- 722
-
-
-
-
- 723
-
-
-
-
-
-
-
- 724
-
-
-
-
-
-
-
- 725
-
-
-
-
-
-
-
- 726
-
-
-
-
-
-
-
- 727
-
-
-
-
-
-
-
- 738
-
-
-
-
-
-
-
-
- 739
-
-
-
-
- 740
-
-
-
-
- 741
-
-
-
-
-
-
-
-
-
- 742
-
-
-
-
- 743
-
-
-
-
- 744
-
-
-
-
- 745
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- 746
-
-
-
-
- 747
-
-
-
-
- 748
-
-
-
-
- 749
-
-
-
-
- 750
-
-
-
-
- 751
-
-
-
-
- 752
-
-
-
-
- 753
-
-
-
-
- 754
-
-
-
-
-
-
-
-
-
-
-
-
- 755
-
-
-
-
- 756
-
-
-
-
- 757
-
-
-
-
- 758
-
-
-
-
- 759
-
-
-
-
- 760
-
-
-
-
- 761
-
-
-
-
-
-
-
-
-
-
-
-
- 762
-
-
-
-
- 763
-
-
-
-
- 764
-
-
-
-
- 765
-
-
-
-
- 766
-
-
-
-
- 821
-
-
-
824
@@ -1684,6 +832,36 @@
+
+ 713
+
+
+
+
+ 714
+
+
+
+
+ 715
+
+
+
+
+ 82
+
+
+
+
+ 79
+
+
+
+
+ 72
+
+
+
@@ -1693,10 +871,6 @@
com.apple.InterfaceBuilder.CocoaPlugin
com.apple.InterfaceBuilder.CocoaPlugin
com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
com.apple.InterfaceBuilder.CocoaPlugin
com.apple.InterfaceBuilder.CocoaPlugin
com.apple.InterfaceBuilder.CocoaPlugin
@@ -1725,54 +899,12 @@
com.apple.InterfaceBuilder.CocoaPlugin
com.apple.InterfaceBuilder.CocoaPlugin
com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
com.apple.InterfaceBuilder.CocoaPlugin
com.apple.InterfaceBuilder.CocoaPlugin
com.apple.InterfaceBuilder.CocoaPlugin
- com.apple.InterfaceBuilder.CocoaPlugin
com.apple.InterfaceBuilder.CocoaPlugin
@@ -1794,20 +926,17 @@
LLAppDelegate
NSObject
-
- LLOpenGLView
- LLNSWindow
-
-
-
- glview
- LLOpenGLView
-
-
+
+ window
+ LLNSWindow
+
+
+ window
+
window
LLNSWindow
-
+
IBProjectSource
./Classes/LLAppDelegate.h
@@ -1821,14 +950,6 @@
./Classes/LLNSWindow.h
-
- LLOpenGLView
- NSOpenGLView
-
- IBProjectSource
- ./Classes/LLOpenGLView.h
-
-
0