mirror of https://github.com/xzeldon/htop.git
'Follow' only if element is found in search
This commit is contained in:
parent
f80e577c59
commit
ef879b4a22
|
@ -83,14 +83,14 @@ static HandlerResult MainPanel_eventHandler(Panel* super, int ch) {
|
||||||
result = HANDLED;
|
result = HANDLED;
|
||||||
} else if (ch != ERR && this->inc->active) {
|
} else if (ch != ERR && this->inc->active) {
|
||||||
bool filterChanged = IncSet_handleKey(this->inc, ch, super, (IncMode_GetPanelValue) MainPanel_getValue, NULL);
|
bool filterChanged = IncSet_handleKey(this->inc, ch, super, (IncMode_GetPanelValue) MainPanel_getValue, NULL);
|
||||||
if (this->inc->found) {
|
|
||||||
reaction |= Action_follow(this->state);
|
|
||||||
}
|
|
||||||
if (filterChanged) {
|
if (filterChanged) {
|
||||||
this->state->pl->incFilter = IncSet_filter(this->inc);
|
this->state->pl->incFilter = IncSet_filter(this->inc);
|
||||||
reaction = HTOP_REFRESH | HTOP_REDRAW_BAR;
|
reaction = HTOP_REFRESH | HTOP_REDRAW_BAR;
|
||||||
}
|
}
|
||||||
reaction |= HTOP_KEEP_FOLLOWING;
|
if (this->inc->found) {
|
||||||
|
reaction |= Action_follow(this->state);
|
||||||
|
reaction |= HTOP_KEEP_FOLLOWING;
|
||||||
|
}
|
||||||
result = HANDLED;
|
result = HANDLED;
|
||||||
} else if (ch == 27) {
|
} else if (ch == 27) {
|
||||||
return HANDLED;
|
return HANDLED;
|
||||||
|
|
Loading…
Reference in New Issue