Commit fce7510d authored by Laurent Aimar's avatar Laurent Aimar

Split out event functions in its own header (msw).

parent ed50ccdc
SOURCES_directx = \
directx.c \
vout.h \
events.h \
events.c \
common.c \
$(NULL)
......@@ -8,6 +9,7 @@ SOURCES_directx = \
SOURCES_direct3d = \
direct3d.c \
vout.h \
events.h \
events.c \
common.c \
$(NULL)
......@@ -15,6 +17,7 @@ SOURCES_direct3d = \
SOURCES_glwin32 = \
glwin32.c \
vout.h \
events.h \
events.c \
common.c \
$(NULL)
......@@ -22,6 +25,7 @@ SOURCES_glwin32 = \
SOURCES_wingdi = \
wingdi.c \
vout.h \
events.h \
events.c \
common.c \
$(NULL)
......@@ -29,6 +33,7 @@ SOURCES_wingdi = \
SOURCES_wingapi = \
wingdi.c \
vout.h \
events.h \
events.c \
common.c \
$(NULL)
......@@ -73,10 +73,34 @@
BOOL SHFullScreen(HWND hwndRequester, DWORD dwState);
#endif*/
/*****************************************************************************
* Local prototypes.
*****************************************************************************/
struct event_thread_t
{
vout_thread_t *p_vout;
/* */
vlc_thread_t thread;
vlc_mutex_t lock;
vlc_cond_t wait;
bool b_ready;
bool b_done;
bool b_error;
/* Mouse */
volatile bool b_cursor_hidden;
volatile mtime_t i_lastmoved;
mtime_t i_mouse_hide_timeout;
/* Title */
char *psz_title;
/* */
unsigned i_changes;
};
static int DirectXCreateWindow( vout_thread_t *p_vout );
static void DirectXCloseWindow ( vout_thread_t *p_vout );
static long FAR PASCAL DirectXEventProc( HWND, UINT, WPARAM, LPARAM );
......
/*****************************************************************************
* event.h: Windows video output header file
*****************************************************************************
* Copyright (C) 2001-2009 the VideoLAN team
* $Id$
*
* Authors: Gildas Bazin <gbazin@videolan.org>
* Damien Fouilleul <damienf@videolan.org>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
*****************************************************************************/
/**
* HWNDs manager.
*/
typedef struct event_thread_t event_thread_t;
event_thread_t *EventThreadCreate( vout_thread_t * );
void EventThreadDestroy( event_thread_t * );
int EventThreadStart( event_thread_t * );
void EventThreadStop( event_thread_t * );
void EventThreadMouseAutoHide( event_thread_t * );
void EventThreadUpdateTitle( event_thread_t *, const char *psz_fallback );
unsigned EventThreadRetreiveChanges( event_thread_t * );
......@@ -25,30 +25,7 @@
/*****************************************************************************
* event_thread_t: event thread
*****************************************************************************/
typedef struct
{
vout_thread_t *p_vout;
/* */
vlc_thread_t thread;
vlc_mutex_t lock;
vlc_cond_t wait;
bool b_ready;
bool b_done;
bool b_error;
/* Mouse */
volatile bool b_cursor_hidden;
volatile mtime_t i_lastmoved;
mtime_t i_mouse_hide_timeout;
/* Title */
char *psz_title;
/* */
unsigned i_changes;
} event_thread_t;
#include "events.h"
#ifdef MODULE_NAME_IS_wingapi
typedef struct GXDisplayProperties {
......@@ -260,18 +237,6 @@ struct vout_sys_t
*****************************************************************************/
int DirectDrawUpdateOverlay( vout_thread_t *p_vout );
/*****************************************************************************
* Prototypes from events.c
*****************************************************************************/
event_thread_t *EventThreadCreate( vout_thread_t * );
void EventThreadDestroy( event_thread_t * );
int EventThreadStart( event_thread_t * );
void EventThreadStop( event_thread_t * );
void EventThreadMouseAutoHide( event_thread_t * );
void EventThreadUpdateTitle( event_thread_t *, const char *psz_fallback );
unsigned EventThreadRetreiveChanges( event_thread_t * );
/*****************************************************************************
* Prototypes from common.c
*****************************************************************************/
......
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