// This file was generated by qtwaylandscanner
// source file is xdg-foreign-unstable-v2.xml

#ifndef QT_WAYLAND_XDG_FOREIGN_UNSTABLE_V2
#define QT_WAYLAND_XDG_FOREIGN_UNSTABLE_V2

#include "wayland-xdg-foreign-unstable-v2-client-protocol.h"
#include <QByteArray>
#include <QString>

struct wl_registry;

QT_BEGIN_NAMESPACE
QT_WARNING_PUSH
QT_WARNING_DISABLE_GCC("-Wmissing-field-initializers")
QT_WARNING_DISABLE_CLANG("-Wmissing-field-initializers")

namespace QtWayland {
    class  zxdg_exporter_v2
    {
    public:
        zxdg_exporter_v2(struct ::wl_registry *registry, uint32_t id, int version);
        zxdg_exporter_v2(struct ::zxdg_exporter_v2 *object);
        zxdg_exporter_v2();

        virtual ~zxdg_exporter_v2();

        void init(struct ::wl_registry *registry, uint32_t id, int version);
        void init(struct ::zxdg_exporter_v2 *object);

        struct ::zxdg_exporter_v2 *object() { return m_zxdg_exporter_v2; }
        const struct ::zxdg_exporter_v2 *object() const { return m_zxdg_exporter_v2; }
        static zxdg_exporter_v2 *fromObject(struct ::zxdg_exporter_v2 *object);

        bool isInitialized() const;

        uint32_t version() const;
        static const struct ::wl_interface *interface();

        enum error {
            error_invalid_surface = 0, // surface is not an xdg_toplevel
        };

        void destroy();
        struct ::zxdg_exported_v2 *export_toplevel(struct ::wl_surface *surface);

    private:
        struct ::zxdg_exporter_v2 *m_zxdg_exporter_v2;
    };

    class  zxdg_importer_v2
    {
    public:
        zxdg_importer_v2(struct ::wl_registry *registry, uint32_t id, int version);
        zxdg_importer_v2(struct ::zxdg_importer_v2 *object);
        zxdg_importer_v2();

        virtual ~zxdg_importer_v2();

        void init(struct ::wl_registry *registry, uint32_t id, int version);
        void init(struct ::zxdg_importer_v2 *object);

        struct ::zxdg_importer_v2 *object() { return m_zxdg_importer_v2; }
        const struct ::zxdg_importer_v2 *object() const { return m_zxdg_importer_v2; }
        static zxdg_importer_v2 *fromObject(struct ::zxdg_importer_v2 *object);

        bool isInitialized() const;

        uint32_t version() const;
        static const struct ::wl_interface *interface();

        void destroy();
        struct ::zxdg_imported_v2 *import_toplevel(const QString &handle);

    private:
        struct ::zxdg_importer_v2 *m_zxdg_importer_v2;
    };

    class  zxdg_exported_v2
    {
    public:
        zxdg_exported_v2(struct ::wl_registry *registry, uint32_t id, int version);
        zxdg_exported_v2(struct ::zxdg_exported_v2 *object);
        zxdg_exported_v2();

        virtual ~zxdg_exported_v2();

        void init(struct ::wl_registry *registry, uint32_t id, int version);
        void init(struct ::zxdg_exported_v2 *object);

        struct ::zxdg_exported_v2 *object() { return m_zxdg_exported_v2; }
        const struct ::zxdg_exported_v2 *object() const { return m_zxdg_exported_v2; }
        static zxdg_exported_v2 *fromObject(struct ::zxdg_exported_v2 *object);

        bool isInitialized() const;

        uint32_t version() const;
        static const struct ::wl_interface *interface();

        void destroy();

    protected:
        virtual void zxdg_exported_v2_handle(const QString &handle);

    private:
        void init_listener();
        static const struct zxdg_exported_v2_listener m_zxdg_exported_v2_listener;
        static void handle_handle(
            void *data,
            struct ::zxdg_exported_v2 *object,
            const char *handle);
        struct ::zxdg_exported_v2 *m_zxdg_exported_v2;
    };

    class  zxdg_imported_v2
    {
    public:
        zxdg_imported_v2(struct ::wl_registry *registry, uint32_t id, int version);
        zxdg_imported_v2(struct ::zxdg_imported_v2 *object);
        zxdg_imported_v2();

        virtual ~zxdg_imported_v2();

        void init(struct ::wl_registry *registry, uint32_t id, int version);
        void init(struct ::zxdg_imported_v2 *object);

        struct ::zxdg_imported_v2 *object() { return m_zxdg_imported_v2; }
        const struct ::zxdg_imported_v2 *object() const { return m_zxdg_imported_v2; }
        static zxdg_imported_v2 *fromObject(struct ::zxdg_imported_v2 *object);

        bool isInitialized() const;

        uint32_t version() const;
        static const struct ::wl_interface *interface();

        enum error {
            error_invalid_surface = 0, // surface is not an xdg_toplevel
        };

        void destroy();
        void set_parent_of(struct ::wl_surface *surface);

    protected:
        virtual void zxdg_imported_v2_destroyed();

    private:
        void init_listener();
        static const struct zxdg_imported_v2_listener m_zxdg_imported_v2_listener;
        static void handle_destroyed(
            void *data,
            struct ::zxdg_imported_v2 *object);
        struct ::zxdg_imported_v2 *m_zxdg_imported_v2;
    };
}

QT_WARNING_POP
QT_END_NAMESPACE

#endif
