mirror of
https://github.com/SFML/SFML.git
synced 2024-11-25 12:51:05 +08:00
Avoid warning message
This commit is contained in:
parent
00bc73f1f3
commit
d77fce1b77
@ -252,9 +252,10 @@
|
||||
// custom OpenGL view. See -[SFOpenGLView sfKeyUp:] for more details.
|
||||
|
||||
id firstResponder = [[anEvent window] firstResponder];
|
||||
if ([anEvent type] == NSKeyUp && [firstResponder respondsToSelector:@selector(sfKeyUp:)]) {
|
||||
[firstResponder sfKeyUp:anEvent];
|
||||
} else {
|
||||
if ([anEvent type] != NSKeyUp
|
||||
|| ![firstResponder tryToPerform:@selector(sfKeyUp:) with:anEvent]) {
|
||||
// It's either not a key up event or no responder has a sfKeyUp
|
||||
// message implemented.
|
||||
[super sendEvent:anEvent];
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user