On 13/03/18 09:00, José Mejuto via Lazarus wrote:
El 13/03/2018 a las 9:21, Mark Morgan Lloyd via Lazarus escribió:>>> Yes, the modal form appears while the mouse button is held down (for >>> both GTK2 and Qt).>>>>>>> So, yes, seem that grid expects mouseup>


I think the proper solution is to instruct GTK2 to use the MOUSE_UP event, but meanwhile QueueAsyncCall will not be the solution as when the AsyncCall will be processed grid will be still waiting for MOUSE_UP, so my solution would be add a MOUSE_UP and MOUSE_DOWN handlers, something like this in pseudo code:
MOUSE_DOWN:   SelectChanged:=false;
ON_SELECT:   SelectChanged:=true;
MOUSE_UP:   if SelectChanged then Form.ShowModal();

I can confirm that that approach appears reliable.

--
Mark Morgan Lloyd
markMLl .AT. telemetry.co .DOT. uk

[Opinions above are the author's, not those of his employers or colleagues]
--
_______________________________________________
Lazarus mailing list
Lazarus@lists.lazarus-ide.org
https://lists.lazarus-ide.org/listinfo/lazarus

Reply via email to