mirror of
https://codeberg.org/unspeaker/tek.git
synced 2025-12-09 05:06:43 +01:00
clone ports as unowned and pass outwards
This commit is contained in:
parent
394355331d
commit
ddaf870271
9 changed files with 123 additions and 112 deletions
|
|
@ -64,7 +64,8 @@ impl<'a> ChainView<'a> {
|
|||
//y2 = y2 + 1;
|
||||
//}
|
||||
let width = width.saturating_sub(x).saturating_sub(x2);
|
||||
let frame = device.render(buf, Rect { x: x + x2, y, width, height })?;
|
||||
let frame = device.state.lock().unwrap()
|
||||
.render(buf, Rect { x: x + x2, y, width, height })?;
|
||||
let style = if i == track.device {
|
||||
Some(if self.focused {
|
||||
Style::default().green().bold().not_dim()
|
||||
|
|
@ -145,13 +146,13 @@ pub fn draw_as_column (
|
|||
let mut w = 0u16;
|
||||
let mut frames = vec![];
|
||||
for device in state.devices.iter() {
|
||||
let device = device.lock().unwrap();
|
||||
let style_midi = Style::default().black().bold().on_green();
|
||||
let style_audio = Style::default().black().bold().on_red();
|
||||
let midi_ins = device.midi_ins()?;
|
||||
let midi_outs = device.midi_outs()?;
|
||||
let audio_ins = device.audio_ins()?;
|
||||
let audio_outs = device.audio_outs()?;
|
||||
let device = device.state.lock().unwrap();
|
||||
let style_midi = Style::default().black().bold().on_green();
|
||||
let style_audio = Style::default().black().bold().on_red();
|
||||
y = y + midi_ins.len() as u16;
|
||||
let frame = device.render(buf, Rect {
|
||||
x, y, width, height: height.saturating_sub(y)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue