summaryrefslogtreecommitdiffstats
path: root/DisplayOptionsPanel.c
diff options
context:
space:
mode:
Diffstat (limited to 'DisplayOptionsPanel.c')
-rw-r--r--DisplayOptionsPanel.c24
1 files changed, 15 insertions, 9 deletions
diff --git a/DisplayOptionsPanel.c b/DisplayOptionsPanel.c
index 9d00b52d..64fd303c 100644
--- a/DisplayOptionsPanel.c
+++ b/DisplayOptionsPanel.c
@@ -1,18 +1,24 @@
/*
htop - DisplayOptionsPanel.c
(C) 2004-2011 Hisham H. Muhammad
-Released under the GNU GPL, see the COPYING file
+Released under the GNU GPLv2, see the COPYING file
in the source distribution for its full text.
*/
+#include "config.h" // IWYU pragma: keep
+
#include "DisplayOptionsPanel.h"
+#include <stdbool.h>
+#include <stdlib.h>
+
#include "CheckItem.h"
#include "CRT.h"
-
-#include <assert.h>
-#include <stdlib.h>
-#include <string.h>
+#include "FunctionBar.h"
+#include "Header.h"
+#include "Object.h"
+#include "ProvideCurses.h"
+#include "XUtils.h"
static const char* const DisplayOptionsFunctions[] = {" ", " ", " ", " ", " ", " ", " ", " ", " ", "Done ", NULL};
@@ -43,16 +49,16 @@ static HandlerResult DisplayOptionsPanel_eventHandler(Panel* super, int ch) {
if (result == HANDLED) {
this->settings->changed = true;
- const Header* header = this->scr->header;
- Header_calculateHeight((Header*) header);
- Header_reinit((Header*) header);
+ Header* header = this->scr->header;
+ Header_calculateHeight(header);
+ Header_reinit(header);
Header_draw(header);
ScreenManager_resize(this->scr, this->scr->x1, header->height, this->scr->x2, this->scr->y2);
}
return result;
}
-PanelClass DisplayOptionsPanel_class = {
+const PanelClass DisplayOptionsPanel_class = {
.super = {
.extends = Class(Panel),
.delete = DisplayOptionsPanel_delete