is the ifdef block supposed to surround the XBMC_Key() routine (or is only the debug stuff?)