From: <jmv...@gm...> - 2007-02-05 16:18:02
|
Hi =20 I=92m running a program with a graphical interface in wxHaskell.=20 My program have one button that starts a sometimes very long computation that even could get cyclic in some cases. I created a Stop button that = when pressed changes the State of the application (type State =3D Var = MyRecordType from = http://wxhaskell.sourceforge.net/doc/Graphics.UI.WX.Types.html#t%3AVar ). Then my very long computation, before calling the recursive call, = checks if the State is saying to continue or stop. =20 In theory this seems the solution but when I tested it I find out that = it doesn=92t. The very long computation gets the attention of the processor = and blocks the graphical interface; clicking the Stop button don=92t fire = the actions. =20 I=92m not sure but is this running sequencially? Which ways have I to = overcome this block? =20 Best Miguel=20 =20 =20 |