mirror of
https://github.com/xzeldon/htop.git
synced 2024-12-23 22:55:46 +00:00
Highlight moving meters in a different color.
This commit is contained in:
parent
f187be9296
commit
3cfbcb72c8
@ -54,6 +54,7 @@ static HandlerResult ColumnsPanel_eventHandler(Panel* super, int ch) {
|
||||
{
|
||||
if (selected < size - 1) {
|
||||
this->moving = !(this->moving);
|
||||
Panel_setSelectionColor(super, this->moving ? CRT_colors[PANEL_SELECTION_FOLLOW] : CRT_colors[PANEL_SELECTION_FOCUS]);
|
||||
((ListItem*)Panel_getSelected(super))->moving = this->moving;
|
||||
result = HANDLED;
|
||||
}
|
||||
|
@ -9,6 +9,7 @@ in the source distribution for its full text.
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <assert.h>
|
||||
#include "CRT.h"
|
||||
|
||||
/*{
|
||||
#include "Panel.h"
|
||||
@ -51,8 +52,10 @@ void MetersPanel_setMoving(MetersPanel* this, bool moving) {
|
||||
this->moving = moving;
|
||||
((ListItem*)Panel_getSelected(super))->moving = moving;
|
||||
if (!moving) {
|
||||
Panel_setSelectionColor(super, CRT_colors[PANEL_SELECTION_FOCUS]);
|
||||
Panel_setDefaultBar(super);
|
||||
} else {
|
||||
Panel_setSelectionColor(super, CRT_colors[PANEL_SELECTION_FOLLOW]);
|
||||
super->currentBar = Meters_movingBar;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user