Skip to content

Commit

Permalink
move time.sleep to core go update plot
Browse files Browse the repository at this point in the history
  • Loading branch information
rcoreilly committed Aug 20, 2024
1 parent 40d67f5 commit 1964b3f
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions egui/plots.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,10 @@ package egui
import (
"fmt"
"log"
"time"

"cogentcore.org/core/base/errors"
"cogentcore.org/core/colors/gradient"
"cogentcore.org/core/core"
"cogentcore.org/core/plot/plotcore"
"cogentcore.org/core/system"
"cogentcore.org/core/tensor/tensorcore"
"github.com/emer/emergent/v2/elog"
"github.com/emer/emergent/v2/etime"
Expand Down Expand Up @@ -120,9 +117,6 @@ func (gui *GUI) GoUpdatePlot(mode etime.Modes, tm etime.Times) *plotcore.PlotEdi
plot := gui.Plot(mode, tm)
if plot != nil {
plot.GoUpdatePlot()
if core.TheApp.Platform() == system.Web {
time.Sleep(time.Millisecond) // critical to prevent hanging!
}
}
return plot
}
Expand Down

0 comments on commit 1964b3f

Please sign in to comment.