// This file was generated by qtwaylandscanner
// source file is xdg-toplevel-tag-v1.xml

#include "qwayland-xdg-toplevel-tag-v1.h"

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

namespace QtWayland {

static inline void *wlRegistryBind(struct ::wl_registry *registry, uint32_t name, const struct ::wl_interface *interface, uint32_t version)
{
    const uint32_t bindOpCode = 0;
    return (void *) wl_proxy_marshal_constructor_versioned((struct wl_proxy *) registry,
    bindOpCode, interface, version, name, interface->name, version, nullptr);
}

    xdg_toplevel_tag_manager_v1::xdg_toplevel_tag_manager_v1(struct ::wl_registry *registry, uint32_t id, int version)
    {
        init(registry, id, version);
    }

    xdg_toplevel_tag_manager_v1::xdg_toplevel_tag_manager_v1(struct ::xdg_toplevel_tag_manager_v1 *obj)
        : m_xdg_toplevel_tag_manager_v1(obj)
    {
    }

    xdg_toplevel_tag_manager_v1::xdg_toplevel_tag_manager_v1()
        : m_xdg_toplevel_tag_manager_v1(nullptr)
    {
    }

    xdg_toplevel_tag_manager_v1::~xdg_toplevel_tag_manager_v1()
    {
    }

    void xdg_toplevel_tag_manager_v1::init(struct ::wl_registry *registry, uint32_t id, int version)
    {
        m_xdg_toplevel_tag_manager_v1 = static_cast<struct ::xdg_toplevel_tag_manager_v1 *>(wlRegistryBind(registry, id, &xdg_toplevel_tag_manager_v1_interface, version));
    }

    void xdg_toplevel_tag_manager_v1::init(struct ::xdg_toplevel_tag_manager_v1 *obj)
    {
        m_xdg_toplevel_tag_manager_v1 = obj;
    }

    xdg_toplevel_tag_manager_v1 *xdg_toplevel_tag_manager_v1::fromObject(struct ::xdg_toplevel_tag_manager_v1 *object)
    {
        return static_cast<xdg_toplevel_tag_manager_v1 *>(xdg_toplevel_tag_manager_v1_get_user_data(object));
    }

    bool xdg_toplevel_tag_manager_v1::isInitialized() const
    {
        return m_xdg_toplevel_tag_manager_v1 != nullptr;
    }

    uint32_t xdg_toplevel_tag_manager_v1::version() const
    {
        return wl_proxy_get_version(reinterpret_cast<wl_proxy*>(m_xdg_toplevel_tag_manager_v1));
    }

    const struct wl_interface *xdg_toplevel_tag_manager_v1::interface()
    {
        return &::xdg_toplevel_tag_manager_v1_interface;
    }

    void xdg_toplevel_tag_manager_v1::destroy()
    {
        ::xdg_toplevel_tag_manager_v1_destroy(
            m_xdg_toplevel_tag_manager_v1);
        m_xdg_toplevel_tag_manager_v1 = nullptr;
    }

    void xdg_toplevel_tag_manager_v1::set_toplevel_tag(struct ::xdg_toplevel *toplevel, const QString &tag)
    {
        ::xdg_toplevel_tag_manager_v1_set_toplevel_tag(
            m_xdg_toplevel_tag_manager_v1,
            toplevel,
            tag.toUtf8().constData());
    }

    void xdg_toplevel_tag_manager_v1::set_toplevel_description(struct ::xdg_toplevel *toplevel, const QString &description)
    {
        ::xdg_toplevel_tag_manager_v1_set_toplevel_description(
            m_xdg_toplevel_tag_manager_v1,
            toplevel,
            description.toUtf8().constData());
    }
}

QT_WARNING_POP
QT_END_NAMESPACE
