mirror of
https://github.com/gui-cs/Terminal.Gui.git
synced 2025-12-30 09:47:58 +01:00
Fixes #3729. ProcessContinuousButtonPressedAsync is using a stale MouseEvent.
This commit is contained in:
@@ -1811,12 +1811,6 @@ internal class WindowsDriver : ConsoleDriver
|
||||
int delay = startDelay;
|
||||
while (_isButtonPressed)
|
||||
{
|
||||
var me = new MouseEvent
|
||||
{
|
||||
Position = _pointMove,
|
||||
Flags = mouseFlag
|
||||
};
|
||||
|
||||
// TODO: This makes ConsoleDriver dependent on Application, which is not ideal. This should be moved to Application.
|
||||
View view = Application.WantContinuousButtonPressedView;
|
||||
|
||||
@@ -1831,6 +1825,12 @@ internal class WindowsDriver : ConsoleDriver
|
||||
}
|
||||
await Task.Delay (delay);
|
||||
|
||||
var me = new MouseEvent
|
||||
{
|
||||
Position = _pointMove,
|
||||
Flags = mouseFlag
|
||||
};
|
||||
|
||||
//Debug.WriteLine($"ProcessContinuousButtonPressedAsync: {view}");
|
||||
if (_isButtonPressed && (mouseFlag & MouseFlags.ReportMousePosition) == 0)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user