Mercurial > mplayer.hg
comparison input/input.c @ 4432:5105f5da01d6
Added lirc support in input
author | albeu |
---|---|
date | Thu, 31 Jan 2002 09:39:11 +0000 |
parents | 8141d2c399e4 |
children | 83128eed25f1 |
comparison
equal
deleted
inserted
replaced
4431:44c23fd75005 | 4432:5105f5da01d6 |
---|---|
21 #include "../linux/keycodes.h" | 21 #include "../linux/keycodes.h" |
22 #include "../linux/timer.h" | 22 #include "../linux/timer.h" |
23 | 23 |
24 #ifdef HAVE_JOYSTICK | 24 #ifdef HAVE_JOYSTICK |
25 #include "joystick.h" | 25 #include "joystick.h" |
26 #endif | |
27 | |
28 #ifdef HAVE_LIRC | |
29 #include "lirc.h" | |
26 #endif | 30 #endif |
27 | 31 |
28 // If the args field is not NULL, the command will only be passed if | 32 // If the args field is not NULL, the command will only be passed if |
29 // an argument exist. | 33 // an argument exist. |
30 | 34 |
791 else | 795 else |
792 mp_input_add_key_fd(fd,1,mp_input_joystick_read,(mp_close_func_t)close); | 796 mp_input_add_key_fd(fd,1,mp_input_joystick_read,(mp_close_func_t)close); |
793 } | 797 } |
794 #endif | 798 #endif |
795 | 799 |
800 #ifdef HAVE_LIRC | |
801 { | |
802 int fd = mp_input_lirc_init(); | |
803 if(fd > 0) | |
804 mp_input_add_cmd_fd(fd,1,NULL,(mp_close_func_t)close); | |
805 } | |
806 #endif | |
807 | |
808 } | |
809 | |
810 void | |
811 mp_input_uninit(void) { | |
812 | |
813 #ifdef HAVE_LIRC | |
814 mp_input_lirc_uninit(); | |
815 #endif | |
816 | |
796 } | 817 } |
797 | 818 |
798 #endif /* HAVE_NEW_INPUT */ | 819 #endif /* HAVE_NEW_INPUT */ |