Index: samples/swarm/swarm_ui_lib/view/SliderMenu.dart |
diff --git a/samples/swarm/swarm_ui_lib/view/SliderMenu.dart b/samples/swarm/swarm_ui_lib/view/SliderMenu.dart |
index 3eae27ed91bb466f1f9ea2a555ad3c91665cf106..e3b955f77715007af1ecdc99bac213c17e79001f 100644 |
--- a/samples/swarm/swarm_ui_lib/view/SliderMenu.dart |
+++ b/samples/swarm/swarm_ui_lib/view/SliderMenu.dart |
@@ -157,7 +157,7 @@ class SliderMenu extends View { |
void updateIndicator(bool animate) { |
if (selectedItem != null) { |
// calculate where we want to put the triangle |
- window.setImmediate(() { |
+ window.immediate.then((_) { |
num x = selectedItem.offsetLeft + |
selectedItem.offsetWidth / 2 - TRIANGLE_WIDTH / 2; |
_moveIndicator(x, animate); |