osx: cocoa_common: use default wakeup period

Now that Cocoa's input handling is done on a separate thread from the playloop
it is ridicolously simple to have longer asynchronous sleeps when paused.
This commit is contained in:
Stefano Pigozzi 2013-06-02 17:58:48 +02:00
parent f13f0db33a
commit f0d2120347
2 changed files with 8 additions and 1 deletions

View File

@ -118,6 +118,14 @@ static NSString *escape_loadfile_name(NSString *input)
@synthesize eventsResponder = _events_responder; @synthesize eventsResponder = _events_responder;
@synthesize menuItems = _menu_items; @synthesize menuItems = _menu_items;
- (void)sendEvent:(NSEvent *)event
{
[super sendEvent:event];
if (self.inputContext)
mp_input_wakeup(self.inputContext);
}
- (id)init - (id)init
{ {
if (self = [super init]) { if (self = [super init]) {

View File

@ -149,7 +149,6 @@ static void disable_power_management(struct vo *vo)
int vo_cocoa_init(struct vo *vo) int vo_cocoa_init(struct vo *vo)
{ {
vo->cocoa = vo_cocoa_init_state(vo); vo->cocoa = vo_cocoa_init_state(vo);
vo->wakeup_period = 0.02;
disable_power_management(vo); disable_power_management(vo);
return 1; return 1;