Make event_manager.h build on MSVC

experimental
Perttu Ahola 2012-03-25 04:06:43 +03:00
parent c8997e48c0
commit 04085cad3c
1 changed files with 10 additions and 10 deletions

View File

@ -77,26 +77,26 @@ public:
std::map<std::string, Dest>::iterator i = m_dest.find(type); std::map<std::string, Dest>::iterator i = m_dest.find(type);
if(i != m_dest.end()){ if(i != m_dest.end()){
std::list<FuncSpec> &funcs = i->second.funcs; std::list<FuncSpec> &funcs = i->second.funcs;
std::list<FuncSpec>::iterator i = funcs.begin(); std::list<FuncSpec>::iterator j = funcs.begin();
while(i != funcs.end()){ while(j != funcs.end()){
bool remove = (i->f == f && (!data || i->d == data)); bool remove = (j->f == f && (!data || j->d == data));
if(remove) if(remove)
funcs.erase(i++); funcs.erase(j++);
else else
i++; j++;
} }
} }
} else{ } else{
for(std::map<std::string, Dest>::iterator for(std::map<std::string, Dest>::iterator
i = m_dest.begin(); i != m_dest.end(); i++){ i = m_dest.begin(); i != m_dest.end(); i++){
std::list<FuncSpec> &funcs = i->second.funcs; std::list<FuncSpec> &funcs = i->second.funcs;
std::list<FuncSpec>::iterator i = funcs.begin(); std::list<FuncSpec>::iterator j = funcs.begin();
while(i != funcs.end()){ while(j != funcs.end()){
bool remove = (i->f == f && (!data || i->d == data)); bool remove = (j->f == f && (!data || j->d == data));
if(remove) if(remove)
funcs.erase(i++); funcs.erase(j++);
else else
i++; j++;
} }
} }
} }