From 30ce3b4c264c51c98f280e88e23792ff7deb2317 Mon Sep 17 00:00:00 2001 From: Daniel Lange Date: Fri, 15 Oct 2021 09:03:04 +0200 Subject: New upstream version 3.1.1 --- MainPanel.c | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) (limited to 'MainPanel.c') diff --git a/MainPanel.c b/MainPanel.c index e7033bf..07dc631 100644 --- a/MainPanel.c +++ b/MainPanel.c @@ -2,7 +2,7 @@ htop - ColumnsPanel.c (C) 2004-2015 Hisham H. Muhammad (C) 2020 Red Hat, Inc. All Rights Reserved. -Released under the GNU GPLv2, see the COPYING file +Released under the GNU GPLv2+, see the COPYING file in the source distribution for its full text. */ @@ -61,8 +61,14 @@ static HandlerResult MainPanel_eventHandler(Panel* super, int ch) { if (ch == KEY_RESIZE) return IGNORED; - /* reset on every normal key, except mouse events while mouse support is disabled */ - if (ch != ERR && (ch != KEY_MOUSE || this->state->settings->enableMouse)) + /* reset on every normal key */ + bool needReset = ch != ERR; + #ifdef HAVE_GETMOUSE + /* except mouse events while mouse support is disabled */ + if (!(ch != KEY_MOUSE || this->state->settings->enableMouse)) + needReset = false; + #endif + if (needReset) this->state->hideProcessSelection = false; if (EVENT_IS_HEADER_CLICK(ch)) { -- cgit v1.2.3