core: all SGR mouse report modes can tell button differences

Fixes #478
This commit is contained in:
Mitchell Hashimoto
2023-09-17 10:24:51 -07:00
parent 083e42f5d2
commit d6b827cce7

View File

@ -1325,7 +1325,10 @@ fn mouseReport(
if (button == null) {
// Null button means motion without a button pressed
acc = 3;
} else if (action == .release and self.io.terminal.flags.mouse_format != .sgr) {
} else if (action == .release and
self.io.terminal.flags.mouse_format != .sgr and
self.io.terminal.flags.mouse_format != .sgr_pixels)
{
// Release is 3. It is NOT 3 in SGR mode because SGR can tell
// the application what button was released.
acc = 3;