[MPlayer-cvslog] r31059 - in trunk/libvo: osx_common.c video_out.c video_out.h vo_kva.c w32_common.c x11_common.c

siretart subversion at mplayerhq.hu
Fri Apr 23 12:22:44 CEST 2010


Author: siretart
Date: Fri Apr 23 12:22:44 2010
New Revision: 31059

Log:
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'.

Modified:
   trunk/libvo/osx_common.c
   trunk/libvo/video_out.c
   trunk/libvo/video_out.h
   trunk/libvo/vo_kva.c
   trunk/libvo/w32_common.c
   trunk/libvo/x11_common.c

Modified: trunk/libvo/osx_common.c
==============================================================================
--- trunk/libvo/osx_common.c	Fri Apr 23 12:04:56 2010	(r31058)
+++ trunk/libvo/osx_common.c	Fri Apr 23 12:22:44 2010	(r31059)
@@ -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},

Modified: trunk/libvo/video_out.c
==============================================================================
--- trunk/libvo/video_out.c	Fri Apr 23 12:04:56 2010	(r31058)
+++ trunk/libvo/video_out.c	Fri Apr 23 12:22:44 2010	(r31059)
@@ -371,7 +371,7 @@ int config_video_out(const vo_functions_
  * \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;
 }

Modified: trunk/libvo/video_out.h
==============================================================================
--- trunk/libvo/video_out.h	Fri Apr 23 12:04:56 2010	(r31058)
+++ trunk/libvo/video_out.h	Fri Apr 23 12:22:44 2010	(r31059)
@@ -269,11 +269,11 @@ extern char *monitor_hfreq_str;
 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;
 };

Modified: trunk/libvo/vo_kva.c
==============================================================================
--- trunk/libvo/vo_kva.c	Fri Apr 23 12:04:56 2010	(r31058)
+++ trunk/libvo/vo_kva.c	Fri Apr 23 12:22:44 2010	(r31059)
@@ -70,7 +70,7 @@ const LIBVO_EXTERN(kva)
 
 #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 @@ static const struct keymap m_vk_map[] = 
     {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 @@ static const struct keymap m_keypad_map[
     {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},

Modified: trunk/libvo/w32_common.c
==============================================================================
--- trunk/libvo/w32_common.c	Fri Apr 23 12:04:56 2010	(r31058)
+++ trunk/libvo/w32_common.c	Fri Apr 23 12:22:44 2010	(r31059)
@@ -60,7 +60,7 @@ static HMONITOR (WINAPI* myMonitorFromWi
 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},
 

Modified: trunk/libvo/x11_common.c
==============================================================================
--- trunk/libvo/x11_common.c	Fri Apr 23 12:04:56 2010	(r31058)
+++ trunk/libvo/x11_common.c	Fri Apr 23 12:22:44 2010	(r31059)
@@ -561,7 +561,7 @@ void vo_uninit(void)
 #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 @@ static void vo_x11_putkey_ext(int keysym
 }
 #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},
 


More information about the MPlayer-cvslog mailing list