forge
Explore
Log in

Don't you dare go Hollow

Top speaker strip counts screen-share audio as speaking (Waves::audible)

Browse files at this commit

0f0df0850090146e6b9fbde10e781ae76d9b9c6fAhmet Kaan GümüşParent: 92a0938
  • fix
    • top speaker strip counts screen-share audio as speaking (Waves::audible)
Show full message
🐛 fix: top speaker strip counts screen-share audio as speaking (Waves::audible)
crates/client/src/gui/camera_view.rsmodified+1 -1
@@ -260,7 +260,7 @@ impl Yumush {
260 }260 }
261 261
262 fn slots(&self, ids: &[Id]) -> (Vec<Id>, usize) {262 fn slots(&self, ids: &[Id]) -> (Vec<Id>, usize) {
263- let speaking = |id: &Id| self.chat.waves.speaking.contains(id);263+ let speaking = |id: &Id| self.chat.waves.audible(*id);
264 let mut shown: Vec<Id> = ids264 let mut shown: Vec<Id> = ids
265 .iter()265 .iter()
266 .filter(|id| speaking(id))266 .filter(|id| speaking(id))
crates/client/src/gui/wave.rsmodified+4 -0
@@ -138,6 +138,10 @@ impl Waves {
138 }))138 }))
139 }139 }
140 140
141+ pub fn audible(&self, id: Id) -> bool {
142+ self.speaking.contains(&id) || self.share.contains_key(&id)
143+ }
144+
141 pub fn share(&self, id: Id) -> Option<&VecDeque<f32>> {145 pub fn share(&self, id: Id) -> Option<&VecDeque<f32>> {
142 self.share.get(&id).map(|wave| &wave.bars)146 self.share.get(&id).map(|wave| &wave.bars)
143 }147 }