diff --git a/engine/src/flutter/shell/platform/linux/fl_accessible_node.h b/engine/src/flutter/shell/platform/linux/fl_accessible_node.h index ff38ad49c6..d9c0f9ec1e 100644 --- a/engine/src/flutter/shell/platform/linux/fl_accessible_node.h +++ b/engine/src/flutter/shell/platform/linux/fl_accessible_node.h @@ -5,16 +5,19 @@ #ifndef FLUTTER_SHELL_PLATFORM_LINUX_FL_ACCESSIBLE_NODE_H_ #define FLUTTER_SHELL_PLATFORM_LINUX_FL_ACCESSIBLE_NODE_H_ -#include +#include +#include #include "flutter/shell/platform/embedder/embedder.h" #include "flutter/shell/platform/linux/public/flutter_linux/fl_engine.h" G_BEGIN_DECLS -// ATK doesn't have the g_autoptr macros, so add them manually. +// ATK g_autoptr macros weren't added until 2.37. Add them manually. // https://gitlab.gnome.org/GNOME/atk/-/issues/10 +#if !ATK_CHECK_VERSION(2, 37, 0) G_DEFINE_AUTOPTR_CLEANUP_FUNC(AtkObject, g_object_unref) +#endif #define FL_TYPE_ACCESSIBLE_NODE fl_accessible_node_get_type() G_DECLARE_DERIVABLE_TYPE(FlAccessibleNode,