]> git.mdlowis.com Git - proto/labwc.git/commitdiff
Fix some header includes detected by clangd
authorHiroaki Yamamoto <hrak1529@gmail.com>
Sun, 21 Apr 2024 19:58:57 +0000 (04:58 +0900)
committerGitHub <noreply@github.com>
Sun, 21 Apr 2024 19:58:57 +0000 (21:58 +0200)
There were some missing headers like <stddef.h> for `NULL`, <wayland-util.h>
for `wl_link` and <stdbool.h> for `true`/`false`.

Also this commit fixes that `labwc.h` and `ime.h` included each other.

include/action.h
include/button/common.h
include/common/scaled_scene_buffer.h
include/config/default-bindings.h
include/config/touch.h
include/labwc.h
include/window-rules.h
src/debug.c
src/input/keyboard.c
src/seat.c

index 76dd54f82f64490201f6eca28225644d99c90fbe..799c15cedc93df0a57db322282d5aaba3708ebf6 100644 (file)
@@ -2,6 +2,7 @@
 #ifndef LABWC_ACTION_H
 #define LABWC_ACTION_H
 
+#include <stdbool.h>
 #include <wayland-util.h>
 
 struct view;
index 686f3e90ba8c7edcfa9e71461a62e06a90697dd6..b3b5039cab2f736d25a08e91afbf6b0e459bce05 100644 (file)
@@ -2,6 +2,8 @@
 #ifndef LABWC_BUTTON_COMMON_H
 #define LABWC_BUTTON_COMMON_H
 
+#include <stddef.h>
+
 /**
  * button_filename() - Get full filename for button.
  * @name: The name of the button (for example 'iconify.xbm').
index d0d96920c3599c47e9338f19b9118f54a96e7b41..db59cca1f2137392e30cab47a1b6e5a21838e311 100644 (file)
@@ -2,11 +2,11 @@
 #ifndef LABWC_SCALED_SCENE_BUFFER_H
 #define LABWC_SCALED_SCENE_BUFFER_H
 
+#include <wayland-server-core.h>
+
 #define LAB_SCALED_BUFFER_MAX_CACHE 2
 
-struct wl_list;
 struct wlr_buffer;
-struct wl_listener;
 struct wlr_scene_tree;
 struct lab_data_buffer;
 struct scaled_scene_buffer;
index 553fb32e065e56055acfbe25bb0974ff898c267a..535ee25ab529b8c559045610a9d3b80187d524c8 100644 (file)
@@ -2,6 +2,8 @@
 #ifndef LABWC_DEFAULT_BINDINGS_H
 #define LABWC_DEFAULT_BINDINGS_H
 
+#include <stddef.h>
+
 static struct key_combos {
        const char *binding, *action;
        struct {
index 96423f9338c7ec06e3b8148404a2da93ebae1cfe..e9880820857209b417287736a4242a07107b6b3b 100644 (file)
@@ -3,6 +3,7 @@
 #define LABWC_TOUCH_CONFIG_H
 
 #include <stdint.h>
+#include <wayland-util.h>
 
 struct touch_config_entry {
        char *device_name;
index e0790727b665190809a003a238c7ac8eec759231..c281c5cdb5c187e980781b237814a5364c7033af 100644 (file)
@@ -46,7 +46,6 @@
 #include "config/keybind.h"
 #include "config/rcxml.h"
 #include "input/cursor.h"
-#include "input/ime.h"
 #include "overlay.h"
 #include "regions.h"
 #include "session-lock.h"
index 3bbc3b9781e506d45ac8bf66e5c7756feea6fc68..17c5dca3789c5df4b25611a7c85a9580e3f180e8 100644 (file)
@@ -2,6 +2,9 @@
 #ifndef LABWC_WINDOW_RULES_H
 #define LABWC_WINDOW_RULES_H
 
+#include <stdbool.h>
+#include <wayland-util.h>
+
 enum window_rule_event {
        LAB_WINDOW_RULE_EVENT_ON_FIRST_MAP = 0,
 };
index 3a1a17615d8bcc40362a6baf158140ead8b74456..75f2f794671e0b604238136c19bc4b04ac45dadd 100644 (file)
@@ -4,6 +4,7 @@
 #include "common/graphic-helpers.h"
 #include "common/scene-helpers.h"
 #include "debug.h"
+#include "input/ime.h"
 #include "labwc.h"
 #include "node.h"
 #include "ssd.h"
index d0db6cb139c3646fc8853dff988971b6657fe882..59761681476403906795d3c204665fd7a29b528f 100644 (file)
@@ -7,6 +7,7 @@
 #include <wlr/interfaces/wlr_keyboard.h>
 #include "action.h"
 #include "idle.h"
+#include "input/ime.h"
 #include "input/keyboard.h"
 #include "input/key-state.h"
 #include "labwc.h"
index e504c6d72201f8e600f5bffc9ac5e6a58381f235..6fbeb595e2ce868b88eac6d846cbedf99ca977b8 100644 (file)
@@ -9,6 +9,7 @@
 #include <wlr/types/wlr_touch.h>
 #include <wlr/util/log.h>
 #include "common/mem.h"
+#include "input/ime.h"
 #include "input/tablet.h"
 #include "input/tablet_pad.h"
 #include "input/input.h"