diff options
author | Christian Göttsche <cgzones@googlemail.com> | 2021-12-16 16:09:32 +0100 |
---|---|---|
committer | cgzones <cgzones@googlemail.com> | 2021-12-17 14:45:15 +0100 |
commit | 5b78ad2d53b751e8b07d67ab8070e47f77036b84 (patch) | |
tree | 70def1b55be92e6e23e629b831a98ea8ac78889a /ScreensPanel.c | |
parent | 1ef8c0e12f29606cb5bfb77d9bce78ae5e6bbb0e (diff) |
Set correct default sorting direction
Respect the field option defaultSortDesc for the default screen sort
direction, e.g. for CPU%.
Diffstat (limited to 'ScreensPanel.c')
-rw-r--r-- | ScreensPanel.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ScreensPanel.c b/ScreensPanel.c index 8d49127c..45c6ba8b 100644 --- a/ScreensPanel.c +++ b/ScreensPanel.c @@ -149,7 +149,7 @@ static void addNewScreen(Panel* super) { ScreensPanel* const this = (ScreensPanel*) super; const char* name = "New"; - ScreenSettings* ss = Settings_newScreen(this->settings, name, "PID Command"); + ScreenSettings* ss = Settings_newScreen(this->settings, &(const ScreenDefaults){ .name = name, .columns = "PID Command", .sortKey = "PID" }); ScreenListItem* item = ScreenListItem_new(name, ss); int idx = Panel_getSelectedIndex(super); Panel_insert(super, idx + 1, (Object*) item); |