OnMouseMove gives wrong Y on classic amiga

Report any Hollywood bugs here
Post Reply
peceha
Posts: 111
Joined: Tue Dec 13, 2016 8:39 am
Location: Poland

OnMouseMove gives wrong Y on classic amiga

Post by peceha » Fri Oct 06, 2017 10:18 pm

Hi,

please run that script on PC (all is working fine) and classic amiga (wb3.1 in my case - there is an offset to Y position given by OnMouseMove)

To see something going on you have to start clicking inside the window - that clicking will create points under the coursor (on PC but not on amiga).
Observe the window title for coordinates returned by OnMouseMove

Code: Select all

mx=0
my=0

Function p_HandlerFunc(msg)
	if msg.action="OnMouseDown"
		setTitle(mx..":"..my)
		plot(mx,my,#WHITE)
	endif
	if msg.action="OnMouseMove"
			mx=msg.x
			my=msg.y
	endif
EndFunction

InstallEventHandler({
	OnMouseDown=p_HandlerFunc,
	OnMouseMove=p_HandlerFunc
})

Repeat
	WaitEvent
Forever

User avatar
airsoftsoftwair
Posts: 2670
Joined: Fri Feb 12, 2010 2:33 pm
Location: Germany
Contact:

Re: OnMouseMove gives wrong Y on classic amiga

Post by airsoftsoftwair » Sun Oct 22, 2017 8:35 pm

Right, but this isn't a Hollywood bug but a bug in Plananarama. It works correctly with Hollywood's inbuilt display handler but as soon as Plananarama is active, it doesn't work so this needs to be fixed in Plananarama.

Post Reply