Commit b5386f68 authored by Jean-Baptiste Kempf's avatar Jean-Baptiste Kempf

Qt: more of the same simplifications and warnings

parent ecd17cb6
...@@ -997,6 +997,8 @@ static int FullscreenControllerWidgetFullscreenChanged( vlc_object_t *vlc_object ...@@ -997,6 +997,8 @@ static int FullscreenControllerWidgetFullscreenChanged( vlc_object_t *vlc_object
const char *variable, vlc_value_t old_val, const char *variable, vlc_value_t old_val,
vlc_value_t new_val, void *data ) vlc_value_t new_val, void *data )
{ {
VLC_UNUSED( variable ); VLC_UNUSED( old_val );
vout_thread_t *p_vout = (vout_thread_t *) vlc_object; vout_thread_t *p_vout = (vout_thread_t *) vlc_object;
msg_Dbg( p_vout, "Qt4: Fullscreen state changed" ); msg_Dbg( p_vout, "Qt4: Fullscreen state changed" );
...@@ -1011,6 +1013,8 @@ static int FullscreenControllerWidgetMouseMoved( vlc_object_t *vlc_object, const ...@@ -1011,6 +1013,8 @@ static int FullscreenControllerWidgetMouseMoved( vlc_object_t *vlc_object, const
vlc_value_t old_val, vlc_value_t new_val, vlc_value_t old_val, vlc_value_t new_val,
void *data ) void *data )
{ {
VLC_UNUSED( variable ); VLC_UNUSED( old_val );
vout_thread_t *p_vout = (vout_thread_t *)vlc_object; vout_thread_t *p_vout = (vout_thread_t *)vlc_object;
FullscreenControllerWidget *p_fs = (FullscreenControllerWidget *)data; FullscreenControllerWidget *p_fs = (FullscreenControllerWidget *)data;
...@@ -1115,7 +1119,7 @@ void FullscreenControllerWidget::fullscreenChanged( vout_thread_t *p_vout, ...@@ -1115,7 +1119,7 @@ void FullscreenControllerWidget::fullscreenChanged( vout_thread_t *p_vout,
/** /**
* Mouse change callback (show/hide the controller on mouse movement) * Mouse change callback (show/hide the controller on mouse movement)
*/ */
void FullscreenControllerWidget::mouseChanged( vout_thread_t *p_vout, int i_mousex, int i_mousey ) void FullscreenControllerWidget::mouseChanged( vout_thread_t *, int i_mousex, int i_mousey )
{ {
bool b_toShow; bool b_toShow;
......
...@@ -667,7 +667,7 @@ void UrlValidator::fixup( QString& str ) const ...@@ -667,7 +667,7 @@ void UrlValidator::fixup( QString& str ) const
str = str.trimmed(); str = str.trimmed();
} }
QValidator::State UrlValidator::validate( QString& str, int& pos ) const QValidator::State UrlValidator::validate( QString& str, int& ) const
{ {
if( str.contains( ' ' ) ) if( str.contains( ' ' ) )
return QValidator::Invalid; return QValidator::Invalid;
......
...@@ -63,7 +63,7 @@ void QElidingLabel::setElideMode( Qt::TextElideMode mode ) ...@@ -63,7 +63,7 @@ void QElidingLabel::setElideMode( Qt::TextElideMode mode )
repaint(); repaint();
} }
void QElidingLabel::paintEvent( QPaintEvent * event ) void QElidingLabel::paintEvent( QPaintEvent * )
{ {
QPainter p( this ); QPainter p( this );
int space = frameWidth() + margin(); int space = frameWidth() + margin();
...@@ -409,11 +409,8 @@ SpinningIcon::SpinningIcon( QWidget *parent, bool noIdleFrame ) ...@@ -409,11 +409,8 @@ SpinningIcon::SpinningIcon( QWidget *parent, bool noIdleFrame )
setFixedSize( 16, 16 ); setFixedSize( 16, 16 );
} }
SpinningIcon::~SpinningIcon() QToolButtonExt::QToolButtonExt(QWidget *parent, int ms )
{ :QToolButton( parent ), longClick( false )
}
QToolButtonExt::QToolButtonExt(QWidget *parent, int ms ): longClick( false )
{ {
setAutoRepeat( true ); setAutoRepeat( true );
/* default to twice the doubleclick delay */ /* default to twice the doubleclick delay */
......
...@@ -166,7 +166,6 @@ class SpinningIcon : public AnimatedIcon ...@@ -166,7 +166,6 @@ class SpinningIcon : public AnimatedIcon
public: public:
SpinningIcon( QWidget *parent, bool noIdleFrame = false ); SpinningIcon( QWidget *parent, bool noIdleFrame = false );
virtual ~SpinningIcon();
}; };
/* VLC Key/Wheel hotkeys interactions */ /* VLC Key/Wheel hotkeys interactions */
......
...@@ -72,7 +72,7 @@ SeekSlider::SeekSlider( Qt::Orientation q, QWidget *_parent ) ...@@ -72,7 +72,7 @@ SeekSlider::SeekSlider( Qt::Orientation q, QWidget *_parent )
setPosition( -1.0, 0, 0 ); setPosition( -1.0, 0, 0 );
secstotimestr( psz_length, 0 ); secstotimestr( psz_length, 0 );
CONNECT( this, sliderMoved( int ), this, startSeekTimer( int ) ); CONNECT( this, sliderMoved( int ), this, startSeekTimer() );
CONNECT( seekLimitTimer, timeout(), this, updatePos() ); CONNECT( seekLimitTimer, timeout(), this, updatePos() );
mTimeTooltip->installEventFilter( this ); mTimeTooltip->installEventFilter( this );
...@@ -101,7 +101,7 @@ void SeekSlider::setPosition( float pos, int64_t time, int length ) ...@@ -101,7 +101,7 @@ void SeekSlider::setPosition( float pos, int64_t time, int length )
inputLength = length; inputLength = length;
} }
void SeekSlider::startSeekTimer( int new_value ) void SeekSlider::startSeekTimer()
{ {
/* Only fire one update, when sliding, every 150ms */ /* Only fire one update, when sliding, every 150ms */
if( b_isSliding && !seekLimitTimer->isActive() ) if( b_isSliding && !seekLimitTimer->isActive() )
...@@ -176,14 +176,14 @@ void SeekSlider::wheelEvent( QWheelEvent *event ) ...@@ -176,14 +176,14 @@ void SeekSlider::wheelEvent( QWheelEvent *event )
event->accept(); event->accept();
} }
void SeekSlider::enterEvent( QEvent *e ) void SeekSlider::enterEvent( QEvent * )
{ {
/* Don't show the tooltip if the slider is disabled */ /* Don't show the tooltip if the slider is disabled */
if( isEnabled() && inputLength > 0 ) if( isEnabled() && inputLength > 0 )
mTimeTooltip->show(); mTimeTooltip->show();
} }
void SeekSlider::leaveEvent( QEvent *e ) void SeekSlider::leaveEvent( QEvent * )
{ {
if( !rect().contains( mapFromGlobal( QCursor::pos() ) ) ) if( !rect().contains( mapFromGlobal( QCursor::pos() ) ) )
mTimeTooltip->hide(); mTimeTooltip->hide();
......
...@@ -71,7 +71,7 @@ public slots: ...@@ -71,7 +71,7 @@ public slots:
void setPosition( float, int64_t, int ); void setPosition( float, int64_t, int );
private slots: private slots:
void startSeekTimer( int ); void startSeekTimer();
void updatePos(); void updatePos();
signals: signals:
......
...@@ -48,6 +48,8 @@ QVLCVariable::~QVLCVariable (void) ...@@ -48,6 +48,8 @@ QVLCVariable::~QVLCVariable (void)
int QVLCVariable::callback (vlc_object_t *object, const char *, int QVLCVariable::callback (vlc_object_t *object, const char *,
vlc_value_t old, vlc_value_t cur, void *data) vlc_value_t old, vlc_value_t cur, void *data)
{ {
VLC_UNUSED(object);
QVLCVariable *self = static_cast<QVLCVariable *>(data); QVLCVariable *self = static_cast<QVLCVariable *>(data);
self->trigger (self->object, old, cur); self->trigger (self->object, old, cur);
......
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