Mercurial > mplayer.hg
changeset 31017:fca6cfc4d5ca
rename 'struct keymap' -> 'struct mp_keymap'
This avoids the compilation failure on kFreeBSD (at least amd64):
In file included from libvo/vo_directfb2.c:44:
libvo/video_out.h:267: error: redefinition of 'struct keymap'
This is because libvo/vo_directfb2.c #includes sys/kd.h, which in turn
includes sys/kbio.h, which defines another 'struct keymap'.
author | siretart |
---|---|
date | Fri, 23 Apr 2010 10:22:44 +0000 |
parents | 37bb4d020f50 |
children | 6ffd2e644c04 |
files | libvo/osx_common.c libvo/video_out.c libvo/video_out.h libvo/vo_kva.c libvo/w32_common.c libvo/x11_common.c |
diffstat | 6 files changed, 10 insertions(+), 10 deletions(-) [+] |
line wrap: on
line diff
--- a/libvo/osx_common.c Fri Apr 23 10:04:56 2010 +0000 +++ b/libvo/osx_common.c Fri Apr 23 10:22:44 2010 +0000 @@ -76,7 +76,7 @@ #define kVK_UpArrow 0x7e #endif /* MAC_OS_X_VERSION_MAX_ALLOWED <= 1040 */ -static const struct keymap keymap[] = { +static const struct mp_keymap keymap[] = { // special keys {0x34, KEY_ENTER}, // Enter key on some iBooks? {kVK_Return, KEY_ENTER},
--- a/libvo/video_out.c Fri Apr 23 10:04:56 2010 +0000 +++ b/libvo/video_out.c Fri Apr 23 10:22:44 2010 +0000 @@ -371,7 +371,7 @@ * \result translation corresponding to key or "to" value of last mapping * if not found. */ -int lookup_keymap_table(const struct keymap *map, int key) { +int lookup_keymap_table(const struct mp_keymap *map, int key) { while (map->from && map->from != key) map++; return map->to; }
--- a/libvo/video_out.h Fri Apr 23 10:04:56 2010 +0000 +++ b/libvo/video_out.h Fri Apr 23 10:22:44 2010 +0000 @@ -269,11 +269,11 @@ extern char *monitor_vfreq_str; extern char *monitor_dotclock_str; -struct keymap { +struct mp_keymap { int from; int to; }; -int lookup_keymap_table(const struct keymap *map, int key); +int lookup_keymap_table(const struct mp_keymap *map, int key); struct vo_rect { int left, right, top, bottom, width, height; };
--- a/libvo/vo_kva.c Fri Apr 23 10:04:56 2010 +0000 +++ b/libvo/vo_kva.c Fri Apr 23 10:22:44 2010 +0000 @@ -70,7 +70,7 @@ #define HWNDFROMWINID(wid) ((wid) + 0x80000000UL) -static const struct keymap m_vk_map[] = { +static const struct mp_keymap m_vk_map[] = { {VK_NEWLINE, KEY_ENTER}, {VK_TAB, KEY_TAB}, {VK_SPACE, ' '}, // control keys @@ -92,7 +92,7 @@ {0, 0} }; -static const struct keymap m_keypad_map[] = { +static const struct mp_keymap m_keypad_map[] = { // keypad keys {0x52, KEY_KP0}, {0x4F, KEY_KP1}, {0x50, KEY_KP2}, {0x51, KEY_KP3}, {0x4B, KEY_KP4}, {0x4C, KEY_KP5}, {0x4D, KEY_KP6}, {0x47, KEY_KP7}, @@ -101,7 +101,7 @@ {0, 0} }; -static const struct keymap m_mouse_map[] = { +static const struct mp_keymap m_mouse_map[] = { {WM_BUTTON1DOWN, MOUSE_BTN0}, {WM_BUTTON3DOWN, MOUSE_BTN1}, {WM_BUTTON2DOWN, MOUSE_BTN2},
--- a/libvo/w32_common.c Fri Apr 23 10:04:56 2010 +0000 +++ b/libvo/w32_common.c Fri Apr 23 10:22:44 2010 +0000 @@ -60,7 +60,7 @@ static BOOL (WINAPI* myGetMonitorInfo)(HMONITOR, LPMONITORINFO); static BOOL (WINAPI* myEnumDisplayMonitors)(HDC, LPCRECT, MONITORENUMPROC, LPARAM); -static const struct keymap vk_map[] = { +static const struct mp_keymap vk_map[] = { // special keys {VK_ESCAPE, KEY_ESC}, {VK_BACK, KEY_BS}, {VK_TAB, KEY_TAB}, {VK_CONTROL, KEY_CTRL},
--- a/libvo/x11_common.c Fri Apr 23 10:04:56 2010 +0000 +++ b/libvo/x11_common.c Fri Apr 23 10:22:44 2010 +0000 @@ -561,7 +561,7 @@ #include "wskeys.h" #ifdef XF86XK_AudioPause -static const struct keymap keysym_map[] = { +static const struct mp_keymap keysym_map[] = { {XF86XK_MenuKB, KEY_MENU}, {XF86XK_AudioPlay, KEY_PLAY}, {XF86XK_AudioPause, KEY_PAUSE}, {XF86XK_AudioStop, KEY_STOP}, {XF86XK_AudioPrev, KEY_PREV}, {XF86XK_AudioNext, KEY_NEXT}, @@ -577,7 +577,7 @@ } #endif -static const struct keymap keymap[] = { +static const struct mp_keymap keymap[] = { // special keys {wsEscape, KEY_ESC}, {wsBackSpace, KEY_BS}, {wsTab, KEY_TAB}, {wsEnter, KEY_ENTER},