From f2e96f9f89443d4df76c6c2815235207e33f295d Mon Sep 17 00:00:00 2001 From: Andrzej Rybczak Date: Sun, 22 Nov 2015 18:26:05 +0100 Subject: [PATCH] window: send mouse related escape codes to the terminal immediately --- src/window.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/window.cpp b/src/window.cpp index e475fa0d..970293ab 100644 --- a/src/window.cpp +++ b/src/window.cpp @@ -322,6 +322,8 @@ void enable() std::printf("\e[?1000h"); // try to enable extended (urxvt) mouse tracking std::printf("\e[?1015h"); + // send the above to the terminal immediately + std::fflush(stdout); } void disable() @@ -334,6 +336,8 @@ void disable() std::printf("\e[?1000l"); // restore old highlight mouse tracking std::printf("\e[?1001r"); + // send the above to the terminal immediately + std::fflush(stdout); } }