Skip to content

Commit

Permalink
Mac: Fix inconsistent repeat of SDL_TEXTINPUT events on 10.7+
Browse files Browse the repository at this point in the history
Due to the new "tap and hold" IME in Mountain Lion and above, we were getting
inconsistent repeat of SDL_TEXTINPUT events. Disabling that functionality (since
you can't see the popover anyway) solves this.

Bug: https://bugzilla.libsdl.org/show_bug.cgi?id=2387
  • Loading branch information
jorgenpt committed Feb 25, 2014
1 parent 6ee12d6 commit d6b1218
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/video/cocoa/SDL_cocoaevents.m
Expand Up @@ -271,7 +271,10 @@ - (BOOL)application:(NSApplication *)theApplication openFile:(NSString *)filenam
CreateApplicationMenus();
}
[NSApp finishLaunching];
NSDictionary *appDefaults = [NSDictionary dictionaryWithObject:@"NO" forKey:@"AppleMomentumScrollSupported"];
NSDictionary *appDefaults = @{
@"AppleMomentumScrollSupported": @NO,
@"ApplePressAndHoldEnabled": @NO,
};
[[NSUserDefaults standardUserDefaults] registerDefaults:appDefaults];

}
Expand Down

0 comments on commit d6b1218

Please sign in to comment.