Commit 2f6eb75c authored by KO Myung-Hun's avatar KO Myung-Hun Committed by Rémi Denis-Courmont

Add vout window support for OS/2

Signed-off-by: Rémi Denis-Courmont's avatarRémi Denis-Courmont <remi@remlab.net>
parent 2aea85fb
......@@ -46,7 +46,7 @@ enum {
VOUT_WINDOW_TYPE_NSOBJECT,
};
#if defined (WIN32)
#if defined (WIN32) || defined (__OS2__)
# define VOUT_WINDOW_TYPE_NATIVE VOUT_WINDOW_TYPE_HWND
#elif defined (__unix__)
# define VOUT_WINDOW_TYPE_NATIVE VOUT_WINDOW_TYPE_XID
......@@ -113,7 +113,7 @@ struct vout_window_t {
vout_window_sys_t *sys;
};
/**
/**
* Creates a new window.
*
* @param module plugin name (usually "$window")
......
......@@ -413,7 +413,7 @@ libvlc_media_player_new( libvlc_instance_t *instance )
var_Create (mp, "vmem-height", VLC_VAR_INTEGER | VLC_VAR_DOINHERIT);
var_Create (mp, "vmem-pitch", VLC_VAR_INTEGER | VLC_VAR_DOINHERIT);
var_Create (mp, "drawable-xid", VLC_VAR_INTEGER);
#ifdef WIN32
#if defined (WIN32) || defined (__OS2__)
var_Create (mp, "drawable-hwnd", VLC_VAR_INTEGER);
#endif
#ifdef __APPLE__
......@@ -935,7 +935,7 @@ void libvlc_media_player_set_hwnd( libvlc_media_player_t *p_mi,
void *drawable )
{
assert (p_mi != NULL);
#ifdef WIN32
#if defined (WIN32) || defined (__OS2__)
var_SetString (p_mi, "window",
(drawable != NULL) ? "embed-hwnd,any" : "");
var_SetInteger (p_mi, "drawable-hwnd", (uintptr_t)drawable);
......@@ -950,7 +950,7 @@ void libvlc_media_player_set_hwnd( libvlc_media_player_t *p_mi,
void *libvlc_media_player_get_hwnd( libvlc_media_player_t *p_mi )
{
assert (p_mi != NULL);
#ifdef WIN32
#if defined (WIN32) || defined (__OS2__)
return (void *)(uintptr_t)var_GetInteger (p_mi, "drawable-hwnd");
#else
return NULL;
......
......@@ -705,7 +705,7 @@ int libvlc_InternalInit( libvlc_int_t *p_libvlc, int i_argc,
var_Create( p_libvlc, "drawable-clip-right", VLC_VAR_INTEGER );
var_Create( p_libvlc, "drawable-nsobject", VLC_VAR_ADDRESS );
#endif
#ifdef WIN32
#if defined (WIN32) || defined (__OS2__)
var_Create( p_libvlc, "drawable-hwnd", VLC_VAR_INTEGER );
#endif
......
......@@ -64,7 +64,7 @@ vout_window_t *vout_window_New(vlc_object_t *obj,
const char *type;
switch (cfg->type) {
#ifdef WIN32
#if defined(WIN32) || defined(__OS2__)
case VOUT_WINDOW_TYPE_HWND:
type = "vout window hwnd";
window->handle.hwnd = NULL;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment