Browse Source

For range loops

pull/1730/head
Daniel Hrabovcak 10 years ago
parent
commit
051a88a7e8
  1. 4
      src/core/core.cpp
  2. 4
      src/core/coreav.cpp

4
src/core/core.cpp

@ -1330,8 +1330,8 @@ void Core::resetCallSources() @@ -1330,8 +1330,8 @@ void Core::resetCallSources()
{
for (ToxGroupCall& call : groupCalls)
{
for (QHash<int, ALuint>::iterator i = call.alSources.begin(); i != call.alSources.end(); ++i)
alDeleteSources(1, &i.value());
for (ALuint source : call.alSources)
alDeleteSources(1, &source);
call.alSources.clear();
}

4
src/core/coreav.cpp

@ -629,8 +629,8 @@ void Core::leaveGroupCall(int groupId) @@ -629,8 +629,8 @@ void Core::leaveGroupCall(int groupId)
groupCalls[groupId].active = false;
disconnect(groupCalls[groupId].sendAudioTimer,0,0,0);
groupCalls[groupId].sendAudioTimer->stop();
for (QHash<int, ALuint>::iterator i = groupCalls[groupId].alSources.begin(); i != groupCalls[groupId].alSources.end(); ++i)
alDeleteSources(1, &i.value());
for (ALuint source : groupCalls[groupId].alSources)
alDeleteSources(1, &source);
groupCalls[groupId].alSources.clear();
Audio::unsuscribeInput();
delete groupCalls[groupId].sendAudioTimer;

Loading…
Cancel
Save