1
0
mirror of https://github.com/tomahawk-player/tomahawk.git synced 2025-08-06 06:07:37 +02:00

Make more accessors constant

This commit is contained in:
Uwe L. Korn
2014-10-22 18:43:42 +02:00
parent 5298640f63
commit 223df09a8f
2 changed files with 8 additions and 11 deletions

View File

@@ -256,9 +256,8 @@ AudioOutput::setCurrentSource( MediaStream* stream )
AudioOutput::AudioState AudioOutput::AudioState
AudioOutput::state() AudioOutput::state() const
{ {
tDebug() << Q_FUNC_INFO;
return m_currentState; return m_currentState;
} }
@@ -274,7 +273,7 @@ AudioOutput::setState( AudioState state )
qint64 qint64
AudioOutput::currentTime() AudioOutput::currentTime() const
{ {
return m_currentTime; return m_currentTime;
} }
@@ -313,7 +312,7 @@ AudioOutput::setCurrentTime( qint64 time )
qint64 qint64
AudioOutput::totalTime() AudioOutput::totalTime() const
{ {
return m_totalTime; return m_totalTime;
} }
@@ -429,10 +428,8 @@ AudioOutput::setMuted(bool m)
qreal qreal
AudioOutput::volume() AudioOutput::volume() const
{ {
tDebug() << Q_FUNC_INFO;
return m_muted ? 0 : m_volume; return m_muted ? 0 : m_volume;
} }

View File

@@ -43,7 +43,7 @@ public:
explicit AudioOutput( QObject* parent = nullptr ); explicit AudioOutput( QObject* parent = nullptr );
~AudioOutput(); ~AudioOutput();
AudioState state(); AudioState state() const;
void setCurrentSource( const QUrl& stream ); void setCurrentSource( const QUrl& stream );
void setCurrentSource( QIODevice* stream ); void setCurrentSource( QIODevice* stream );
@@ -58,9 +58,9 @@ public:
bool isMuted() const; bool isMuted() const;
void setMuted( bool m ); void setMuted( bool m );
void setVolume( qreal vol ); void setVolume( qreal vol );
qreal volume(); qreal volume() const;
qint64 currentTime(); qint64 currentTime() const;
qint64 totalTime(); qint64 totalTime() const;
void setAutoDelete ( bool ad ); void setAutoDelete ( bool ad );
void setDspCallback( std::function< void( int, int, float*, int, int ) > cb ); void setDspCallback( std::function< void( int, int, float*, int, int ) > cb );