Commit 4758ccba authored by gbazin's avatar gbazin

* modules/gui/wxwindows/*: work-around a wxwindows bug with accelerators registration on win32.

parent e9a6f99b
......@@ -279,6 +279,12 @@ Interface::~Interface()
delete timer;
}
void Interface::Init()
{
/* Misc init */
SetupHotkeys();
}
void Interface::Update()
{
/* Misc updates */
......
......@@ -49,6 +49,7 @@ Timer::Timer( intf_thread_t *_p_intf, Interface *_p_main_interface )
{
p_intf = _p_intf;
p_main_interface = _p_main_interface;
b_init = 0;
i_old_playing_status = PAUSE_S;
i_old_rate = INPUT_RATE_DEFAULT;
......@@ -90,6 +91,14 @@ Timer::~Timer()
*****************************************************************************/
void Timer::Notify()
{
#if defined( __WXMSW__ ) /* Work-around a bug with accelerators */
if( !b_init )
{
p_main_interface->Init();
b_init = VLC_TRUE;
}
#endif
vlc_mutex_lock( &p_intf->change_lock );
/* Update the input */
......
......@@ -181,6 +181,7 @@ public:
private:
intf_thread_t *p_intf;
Interface *p_main_interface;
vlc_bool_t b_init;
int i_old_playing_status;
int i_old_rate;
vlc_bool_t b_old_seekable;
......@@ -291,6 +292,7 @@ public:
/* Constructor */
Interface( intf_thread_t *p_intf );
virtual ~Interface();
void Init();
void TogglePlayButton( int i_playing_status );
void Update();
......
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