diff options
author | John Rennie <john.rennie@ratsauce.co.uk> | 2013-01-15 12:13:19 +0000 |
---|---|---|
committer | John Rennie <john.rennie@ratsauce.co.uk> | 2013-01-15 12:13:19 +0000 |
commit | 169be40560488d0e6ca9548dc694e7ca0005288e (patch) | |
tree | 85bb64f5d6cbbbb4fd5d1e4e8877eb8dbbc43db6 | |
parent | 52dac5c61cc4dc97ca74aa8398589bc1dfc25a1e (diff) |
Add support for sleep key in Linux
-rw-r--r-- | xbmc/input/XBMC_keysym.h | 1 | ||||
-rw-r--r-- | xbmc/input/XBMC_keytable.cpp | 1 | ||||
-rw-r--r-- | xbmc/input/XBMC_vkeys.h | 1 | ||||
-rw-r--r-- | xbmc/windowing/WinEventsSDL.cpp | 2 |
4 files changed, 4 insertions, 1 deletions
diff --git a/xbmc/input/XBMC_keysym.h b/xbmc/input/XBMC_keysym.h index 0d8ba07891..20d12b365a 100644 --- a/xbmc/input/XBMC_keysym.h +++ b/xbmc/input/XBMC_keysym.h @@ -214,6 +214,7 @@ typedef enum { XBMCK_POWER = 0x140, // Power Macintosh power key XBMCK_EURO = 0x141, // Some european keyboards XBMCK_UNDO = 0x142, // Atari keyboard has Undo + XBMCK_SLEEP = 0x143, // Sleep button on Nyxboard remote (and others?) // Add any other keys here diff --git a/xbmc/input/XBMC_keytable.cpp b/xbmc/input/XBMC_keytable.cpp index dbc28a7e57..aaf65ba639 100644 --- a/xbmc/input/XBMC_keytable.cpp +++ b/xbmc/input/XBMC_keytable.cpp @@ -222,6 +222,7 @@ static const XBMCKEYTABLE XBMCKeyTable[] = , { XBMCK_SCROLLOCK, 0, 0, XBMCVK_SCROLLLOCK, "scrolllock" } , { XBMCK_PRINT, 0, 0, XBMCVK_PRINTSCREEN, "printscreen" } , { XBMCK_POWER, 0, 0, XBMCVK_POWER, "power" } +, { XBMCK_SLEEP, 0, 0, XBMCVK_SLEEP, "sleep" } }; static int XBMCKeyTableSize = sizeof(XBMCKeyTable)/sizeof(XBMCKEYTABLE); diff --git a/xbmc/input/XBMC_vkeys.h b/xbmc/input/XBMC_vkeys.h index 38f675db7e..70b27e3841 100644 --- a/xbmc/input/XBMC_vkeys.h +++ b/xbmc/input/XBMC_vkeys.h @@ -205,6 +205,7 @@ typedef enum { XBMCVK_SCROLLLOCK = 0xDC, XBMCVK_PAUSE = 0XDD, XBMCVK_POWER = 0XDE, + XBMCVK_SLEEP = 0XDF, XBMCVK_LAST = 0xFF } XBMCVKey; diff --git a/xbmc/windowing/WinEventsSDL.cpp b/xbmc/windowing/WinEventsSDL.cpp index 0acf810080..c3c385ff0f 100644 --- a/xbmc/windowing/WinEventsSDL.cpp +++ b/xbmc/windowing/WinEventsSDL.cpp @@ -69,7 +69,7 @@ static uint16_t SymMappingsEvdev[][2] = , { 138, 0x69 /* 'i' */} // Info , { 147, 0x6d /* 'm' */} // Menu , { 148, XBMCK_LAUNCH_APP2 } // Launch app 2 -, { 150, 0x9f } // Sleep +, { 150, XBMCK_SLEEP } // Sleep , { 152, XBMCK_LAUNCH_APP1 } // Launch app 1 , { 163, XBMCK_LAUNCH_MAIL } // Launch Mail , { 164, XBMCK_BROWSER_FAVORITES } // Browser favorites |