Mouse Down/Up/Enter/Leave - window or canvas
BlitzPlus Forums/BlitzPlus Programming/Mouse Down/Up/Enter/Leave - window or canvas
| ||
Is there a way to tell whether the mouse events involve a canvas or window?If EventID() = $205 SetBuffer CanvasBuffer(EventSource()) DrawImage helpBtn, 0, 0, 1 FlipCanvas(EventSource()) End If In this i want it to only happen when it's a canvas. How do i tell the difference between a window and canvas in this sort of example? |
| ||
$205 is defined in the docs as only happening when a mouse enters a canvas... Is it firing when it enters the form as well? |
| ||
Sorry. I also have the mouse down and up in the same sort of way. I should have put one of those in. The MouseDown is on canvases, windows and panels so i just want to run the code (which is basically the same as above but with $201) only if it is on a canvas. |
| ||
you'd probably just ahve to check the mouse position and determine if it were in the canvas or not. |
| ||
Not test but ...If EventID() = $201 ; mouse down If EventSource()=mycanvas SetBuffer CanvasBuffer(mycanvas) DrawImage helpBtn, 0, 0, 1 FlipCanvas mycanvas End If End If |