(bytes: usize)
| 357 | format!("{} B", bytes) |
| 358 | } else if bytes < 1024 * 1024 { |
| 359 | format!("{:.1} KB", bytes as f64 / 1024.0) |
| 360 | } else { |
| 361 | format!("{:.1} MB", bytes as f64 / (1024.0 * 1024.0)) |
| 362 | } |
| 363 | } |
| 364 | |
| 365 | fn volume_percent(&self) -> u32 { |
| 366 | (self.volume * 100.0).round() as u32 |
| 367 | } |
| 368 | |
| 369 | fn status_text(&self) -> &'static str { |
| 370 | match self.playback_state { |
nothing calls this directly
no outgoing calls
no test coverage detected