Thanks guys, if you don’t mind, I have another que...
# announcements
e
Thanks guys, if you don’t mind, I have another question: I have queue of commands (
synchronizedList(mutableList())
). I want to process command and remove it. Now I do it that way:
Copy code
commands.removeAll {
    when (it){
        is Clear -> plot.clear()
        is AddPoints -> plot.addPoints(it.x, it.y)
        is AddPoint -> plot.addPoint(it.x, it.y)
    }
    true
}
Is that ok?