BUGFIX: behavior of 'F' (follow) key was broken, also affecting the

persistence of mouse selections. Closes #3165065.
This commit is contained in:
Hisham Muhammad
2012-02-02 23:45:40 +00:00
parent 58676d7001
commit 1a604a05a5
4 changed files with 12 additions and 11 deletions

3
htop.c
View File

@ -440,6 +440,7 @@ int main(int argc, char** argv) {
gettimeofday(&tv, NULL);
newTime = ((double)tv.tv_sec * 10) + ((double)tv.tv_usec / 100000);
recalculate = (newTime - oldTime > CRT_delay);
int following = follow ? ((Process*)Panel_getSelected(panel))->pid : -1;
if (recalculate)
oldTime = newTime;
if (doRefresh) {
@ -451,7 +452,7 @@ int main(int argc, char** argv) {
ProcessList_sort(pl);
refreshTimeout = 1;
}
ProcessList_rebuildPanel(pl, true, follow, userOnly, userId, filtering, incFilter.buffer);
ProcessList_rebuildPanel(pl, true, following, userOnly, userId, filtering, incFilter.buffer);
}
doRefresh = true;