Michael,

On Mon, Jul 3, 2017 at 8:21 PM, Michael Rueger <lists@andience.co.nz> wrote:
 
Hi all,

so continuing on with the below mentioned hack I got a version running that correctly displays colors (although not the image desktop image) and accepts mouse/touch input.

If you hit the back button the next touch will be interpreted as right button click.

There is still something wrong with the display endianess, have to swap the bytes for display.

Display updates are done directly from the VM async via SurfaceView, avoids some of the bit copying.

Events are also directly sent from Android and added to the queue, but still polled from the queue within the VM.

Not handling rotation or backgrounding yet, needs a bit more work.

Please feel free to take a look at the code in https://github.com/mrueger42/st-android (development branch), project CogDroid.

Congratulations and thank you!  Are you planning to fold the vm changes back into opensmalltalk/vm?

 

Cheers

Michael


On 26/06/17 7:51 PM, Michael Rueger wrote:


after a bit more digging it seems that the getRedzoneSize (sqUnixMain.c) magic doesn't work as expected in Android if it is called on a non-UI thread.
The behavior isn't consistent, it simply crashes or gives back impossibly large (negative) numbers.

Just for proof of concept I hard coded a value that I got from executing getRedzoneSize on the main thread and the VM now runs (I see regular calls to invalidate display in the log).




--
_,,,^..^,,,_
best, Eliot