summaryrefslogtreecommitdiffstats
path: root/pacman-c++/audio.cpp
diff options
context:
space:
mode:
authormanuel <manuel@mausz.at>2011-04-10 21:34:29 +0200
committermanuel <manuel@mausz.at>2011-04-10 21:34:29 +0200
commit817dcc4e4493fb89c6d52b5e5ce1548b6a047d08 (patch)
tree81f0eea0617d05604e6636cb020509f9ec504e6e /pacman-c++/audio.cpp
parentd0eafb0124a39eeda6c00595a943ce9811d589c4 (diff)
downloadfoop-817dcc4e4493fb89c6d52b5e5ce1548b6a047d08.tar.gz
foop-817dcc4e4493fb89c6d52b5e5ce1548b6a047d08.tar.bz2
foop-817dcc4e4493fb89c6d52b5e5ce1548b6a047d08.zip
- first round of coding cleanup
- small sound fix
Diffstat (limited to 'pacman-c++/audio.cpp')
-rw-r--r--pacman-c++/audio.cpp7
1 files changed, 2 insertions, 5 deletions
diff --git a/pacman-c++/audio.cpp b/pacman-c++/audio.cpp
index 0692cd1..ebeda2b 100644
--- a/pacman-c++/audio.cpp
+++ b/pacman-c++/audio.cpp
@@ -22,6 +22,8 @@ AudioManager::AudioManager()
22 m_players.append(firstplayer); 22 m_players.append(firstplayer);
23 23
24 m_muted = false; 24 m_muted = false;
25#else
26 qDebug() << "Server has no sound"
25#endif // SERVER 27#endif // SERVER
26} 28}
27 29
@@ -61,7 +63,6 @@ void AudioManager::pause()
61{ 63{
62 if (!isWorking()) 64 if (!isWorking())
63 return; 65 return;
64 qDebug() << "pause";
65 for(int i = 0; i < m_players.count(); ++i) 66 for(int i = 0; i < m_players.count(); ++i)
66 m_players.at(i)->pause(); 67 m_players.at(i)->pause();
67} 68}
@@ -70,7 +71,6 @@ void AudioManager::stop()
70{ 71{
71 if (!isWorking()) 72 if (!isWorking())
72 return; 73 return;
73 qDebug() << "stop";
74 for(int i = 0; i < m_players.count(); ++i) 74 for(int i = 0; i < m_players.count(); ++i)
75 m_players.at(i)->stop(); 75 m_players.at(i)->stop();
76} 76}
@@ -79,7 +79,6 @@ void AudioManager::clear()
79{ 79{
80 if (!isWorking()) 80 if (!isWorking())
81 return; 81 return;
82 qDebug() << "clear";
83 for(int i = 0; i < m_players.count(); ++i) 82 for(int i = 0; i < m_players.count(); ++i)
84 m_players.at(i)->clear(); 83 m_players.at(i)->clear();
85} 84}
@@ -105,7 +104,6 @@ void AudioManager::play(Sound::Type sound)
105 return; 104 return;
106 } 105 }
107 106
108 qDebug() << "play";
109 AudioPlayer *player = audioPlayer(); 107 AudioPlayer *player = audioPlayer();
110 player->setCurrentSource(Phonon::MediaSource(m_sounds[sound])); 108 player->setCurrentSource(Phonon::MediaSource(m_sounds[sound]));
111 player->play(); 109 player->play();
@@ -115,7 +113,6 @@ void AudioManager::enqueue(Sound::Type sound)
115{ 113{
116 if (!isWorking()) 114 if (!isWorking())
117 return; 115 return;
118 qDebug() << "manager enqueue";
119 audioPlayer()->enqueue(Phonon::MediaSource(m_sounds[sound])); 116 audioPlayer()->enqueue(Phonon::MediaSource(m_sounds[sound]));
120} 117}
121 118