diff --git a/src/hotkey/Makefile b/src/hotkey/Makefile index 3765d51bd..40017de53 100644 --- a/src/hotkey/Makefile +++ b/src/hotkey/Makefile @@ -9,5 +9,5 @@ plugindir := ${plugindir}/${GENERAL_PLUGIN_DIR} LD = ${CXX} CFLAGS += ${PLUGIN_CFLAGS} -CPPFLAGS += ${PLUGIN_CPPFLAGS} ${GTK_CFLAGS} ${GLIB_CFLAGS} -I../.. -I.. -LIBS += ${GLIB_LIBS} ${GTK_LIBS} -lX11 -laudgui +CPPFLAGS += ${PLUGIN_CPPFLAGS} ${GTK_CFLAGS} -I../.. -I.. +LIBS += ${GTK_LIBS} -lX11 -laudgui diff --git a/src/hotkey/grab.cc b/src/hotkey/grab.cc index febb96b34..51bdb51b5 100644 --- a/src/hotkey/grab.cc +++ b/src/hotkey/grab.cc @@ -396,12 +396,10 @@ static GdkFilterReturn gdk_filter(GdkXEvent * xevent, GdkEvent * event, return GDK_FILTER_CONTINUE; } -gboolean setup_filter() +void setup_filter() { gdk_window_add_filter(gdk_screen_get_root_window(gdk_screen_get_default()), gdk_filter, nullptr); - - return true; } void release_filter() diff --git a/src/hotkey/grab.h b/src/hotkey/grab.h index 47935dbbd..33ff5449d 100644 --- a/src/hotkey/grab.h +++ b/src/hotkey/grab.h @@ -1,11 +1,9 @@ #ifndef _GRAB_H_INCLUDED_ #define _GRAB_H_INCLUDED_ -#include - void grab_keys(); void ungrab_keys(); -gboolean setup_filter(); +void setup_filter(); void release_filter(); #endif diff --git a/src/hotkey/meson.build b/src/hotkey/meson.build index 148111250..ba6eaf5d4 100644 --- a/src/hotkey/meson.build +++ b/src/hotkey/meson.build @@ -16,7 +16,7 @@ hotkey_sources = [ if have_hotkey shared_module('hotkey', hotkey_sources, - dependencies: [audacious_dep, audgui_dep, gtk_dep, glib_dep, gdk_x11_dep, x11_dep], + dependencies: [audacious_dep, audgui_dep, gtk_dep, gdk_x11_dep, x11_dep], name_prefix: '', install: true, install_dir: general_plugin_dir diff --git a/src/hotkey/plugin.cc b/src/hotkey/plugin.cc index b8ccb3871..f3e3e5fa7 100644 --- a/src/hotkey/plugin.cc +++ b/src/hotkey/plugin.cc @@ -111,7 +111,7 @@ bool GlobalHotkeys::init() } /* handle keys */ -gboolean handle_keyevent(EVENT event) +bool handle_keyevent(EVENT event) { int current_volume, old_volume; static int volume_static = 0; diff --git a/src/hotkey/plugin.h b/src/hotkey/plugin.h index d7dbbfd60..24b06dadc 100644 --- a/src/hotkey/plugin.h +++ b/src/hotkey/plugin.h @@ -1,8 +1,6 @@ #ifndef _PLUGIN_H_INCLUDED_ #define _PLUGIN_H_INCLUDED_ -#include - #define TYPE_KEY 0 #define TYPE_MOUSE 1 @@ -49,6 +47,6 @@ typedef struct void load_config(); void save_config(); PluginConfig * get_config(); -gboolean handle_keyevent(EVENT event); +bool handle_keyevent(EVENT event); #endif