Commit 7ef8e0ab authored by Jean-Baptiste Kempf's avatar Jean-Baptiste Kempf

Qt4: win32 simplification

parent 4b5229c8
...@@ -825,6 +825,7 @@ static int ffmpeg_OpenCodec( decoder_t *p_dec ) ...@@ -825,6 +825,7 @@ static int ffmpeg_OpenCodec( decoder_t *p_dec )
p_sys->b_delayed_open = false; p_sys->b_delayed_open = false;
msg_Info( p_dec, "Here" );
if( p_sys->p_va && p_sys->p_va->description ) if( p_sys->p_va && p_sys->p_va->description )
msg_Info( p_dec, "Using %s for hardware decoding.", p_sys->p_va->description ); msg_Info( p_dec, "Using %s for hardware decoding.", p_sys->p_va->description );
......
...@@ -584,14 +584,6 @@ void MainInterface::createTaskBarButtons() ...@@ -584,14 +584,6 @@ void MainInterface::createTaskBarButtons()
msg_Err( p_intf, "ThumbBarAddButtons failed with error %08x", hr ); msg_Err( p_intf, "ThumbBarAddButtons failed with error %08x", hr );
} }
CONNECT( THEMIM->getIM(), statusChanged( int ), this, changeThumbbarButtons( int ) ); CONNECT( THEMIM->getIM(), statusChanged( int ), this, changeThumbbarButtons( int ) );
CONNECT( this, playPauseSignal(), THEMIM, togglePlayPause() );
CONNECT( this, prevSignal(), THEMIM, prev() );
CONNECT( this, nextSignal(), THEMIM, next() );
CONNECT( this, play(), THEMIM, play() );
CONNECT( this, pause(), THEMIM, pause() );
CONNECT( this, mute(), ActionsManager::getInstance( p_intf ), toggleMuteAudio() );
CONNECT( this, volumeUp(), ActionsManager::getInstance( p_intf ), AudioUp() );
CONNECT( this, volumeDown(), ActionsManager::getInstance( p_intf ), AudioDown() );
} }
} }
else else
...@@ -618,13 +610,13 @@ bool MainInterface::winEvent ( MSG * msg, long * result ) ...@@ -618,13 +610,13 @@ bool MainInterface::winEvent ( MSG * msg, long * result )
switch(LOWORD(msg->wParam)) switch(LOWORD(msg->wParam))
{ {
case 0: case 0:
emit prevSignal(); THEMIM->prev();
break; break;
case 1: case 1:
emit playPauseSignal(); THEMIM->togglePlayPause();
break; break;
case 2: case 2:
emit nextSignal(); THEMIM->next();
break; break;
} }
} }
...@@ -634,31 +626,31 @@ bool MainInterface::winEvent ( MSG * msg, long * result ) ...@@ -634,31 +626,31 @@ bool MainInterface::winEvent ( MSG * msg, long * result )
switch(cmd) switch(cmd)
{ {
case APPCOMMAND_MEDIA_PLAY_PAUSE: case APPCOMMAND_MEDIA_PLAY_PAUSE:
emit playPauseSignal(); THEMIM->togglePlayPause();
break; break;
case APPCOMMAND_MEDIA_PLAY: case APPCOMMAND_MEDIA_PLAY:
emit play(); THEMIM->play();
break; break;
case APPCOMMAND_MEDIA_PAUSE: case APPCOMMAND_MEDIA_PAUSE:
emit pause(); THEMIM->pause();
break; break;
case APPCOMMAND_MEDIA_PREVIOUSTRACK: case APPCOMMAND_MEDIA_PREVIOUSTRACK:
emit prevSignal(); THEMIM->prev();
break; break;
case APPCOMMAND_MEDIA_NEXTTRACK: case APPCOMMAND_MEDIA_NEXTTRACK:
emit nextSignal(); THEMIM->next();
break; break;
case APPCOMMAND_MEDIA_STOP: case APPCOMMAND_MEDIA_STOP:
emit stop(); THEMIM->stop();
break; break;
case APPCOMMAND_VOLUME_DOWN: case APPCOMMAND_VOLUME_DOWN:
emit volumeDown(); THEAM->AudioDown();
break; break;
case APPCOMMAND_VOLUME_UP: case APPCOMMAND_VOLUME_UP:
emit volumeUp(); THEAM->AudioUp();
break; break;
case APPCOMMAND_VOLUME_MUTE: case APPCOMMAND_VOLUME_MUTE:
emit mute(); THEAM->toggleMuteAudio();
break; break;
default: default:
msg_Dbg( p_intf, "unknown APPCOMMAND = %d", cmd); msg_Dbg( p_intf, "unknown APPCOMMAND = %d", cmd);
......
...@@ -226,15 +226,7 @@ signals: ...@@ -226,15 +226,7 @@ signals:
void askUpdate(); void askUpdate();
void minimalViewToggled( bool ); void minimalViewToggled( bool );
void fullscreenInterfaceToggled( bool ); void fullscreenInterfaceToggled( bool );
void playPauseSignal();
void play();
void pause();
void stop();
void volumeUp();
void volumeDown();
void mute();
void prevSignal();
void nextSignal();
}; };
#ifdef WIN32 #ifdef WIN32
......
...@@ -86,6 +86,7 @@ struct intf_sys_t ...@@ -86,6 +86,7 @@ struct intf_sys_t
#define THEDP DialogsProvider::getInstance() #define THEDP DialogsProvider::getInstance()
#define THEMIM MainInputManager::getInstance( p_intf ) #define THEMIM MainInputManager::getInstance( p_intf )
#define THEAM ActionsManager::getInstance( p_intf )
#define qfu( i ) QString::fromUtf8( i ) #define qfu( i ) QString::fromUtf8( i )
#define qtr( i ) QString::fromUtf8( vlc_gettext(i) ) #define qtr( i ) QString::fromUtf8( vlc_gettext(i) )
......
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