Switch audio loop to late dispatch

This commit is contained in:
scorpion-26 2023-01-29 12:43:05 +01:00
parent 3c6850b530
commit dfae74e169

View file

@ -87,6 +87,8 @@ namespace AudioFlyin
mainWidget->SetSpacing({8, false});
mainWidget->SetVerticalTransform({16, true, Alignment::Fill});
mainWidget->SetClass("bar");
// We update the margin in the timer, so we need late dispatch.
mainWidget->AddTimer<Box>(DynCtx::Main, 1, TimerDispatchBehaviour::LateDispatch);
auto padding = Widget::Create<Box>();
padding->SetHorizontalTransform({8, true, Alignment::Fill});
@ -97,8 +99,6 @@ namespace AudioFlyin
padding = Widget::Create<Box>();
mainWidget->AddChild(std::move(padding));
mainWidget->AddTimer<Box>(DynCtx::Main, 1);
window = Window(std::move(mainWidget), monitor);
window.SetExclusive(false);
window.SetAnchor(Anchor::Bottom);