// This file was generated by qtwaylandscanner
// source file is wlr-output-management-unstable-v1.xml

#ifndef QT_WAYLAND_WLR_OUTPUT_MANAGEMENT_UNSTABLE_V1
#define QT_WAYLAND_WLR_OUTPUT_MANAGEMENT_UNSTABLE_V1

#include "wayland-wlr-output-management-unstable-v1-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  zwlr_output_manager_v1
    {
    public:
        zwlr_output_manager_v1(struct ::wl_registry *registry, uint32_t id, int version);
        zwlr_output_manager_v1(struct ::zwlr_output_manager_v1 *object);
        zwlr_output_manager_v1();

        virtual ~zwlr_output_manager_v1();

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

        struct ::zwlr_output_manager_v1 *object() { return m_zwlr_output_manager_v1; }
        const struct ::zwlr_output_manager_v1 *object() const { return m_zwlr_output_manager_v1; }
        static zwlr_output_manager_v1 *fromObject(struct ::zwlr_output_manager_v1 *object);

        bool isInitialized() const;

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

        struct ::zwlr_output_configuration_v1 *create_configuration(uint32_t serial);
        void stop();

    protected:
        virtual void zwlr_output_manager_v1_head(struct ::zwlr_output_head_v1 *head);
        virtual void zwlr_output_manager_v1_done(uint32_t serial);
        virtual void zwlr_output_manager_v1_finished();

    private:
        void init_listener();
        static const struct zwlr_output_manager_v1_listener m_zwlr_output_manager_v1_listener;
        static void handle_head(
            void *data,
            struct ::zwlr_output_manager_v1 *object,
            struct ::zwlr_output_head_v1 *head);
        static void handle_done(
            void *data,
            struct ::zwlr_output_manager_v1 *object,
            uint32_t serial);
        static void handle_finished(
            void *data,
            struct ::zwlr_output_manager_v1 *object);
        struct ::zwlr_output_manager_v1 *m_zwlr_output_manager_v1;
    };

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

        virtual ~zwlr_output_head_v1();

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

        struct ::zwlr_output_head_v1 *object() { return m_zwlr_output_head_v1; }
        const struct ::zwlr_output_head_v1 *object() const { return m_zwlr_output_head_v1; }
        static zwlr_output_head_v1 *fromObject(struct ::zwlr_output_head_v1 *object);

        bool isInitialized() const;

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

        enum adaptive_sync_state {
            adaptive_sync_state_disabled = 0, // adaptive sync is disabled
            adaptive_sync_state_enabled = 1, // adaptive sync is enabled
        };

        void release();

    protected:
        virtual void zwlr_output_head_v1_name(const QString &name);
        virtual void zwlr_output_head_v1_description(const QString &description);
        virtual void zwlr_output_head_v1_physical_size(int32_t width, int32_t height);
        virtual void zwlr_output_head_v1_mode(struct ::zwlr_output_mode_v1 *mode);
        virtual void zwlr_output_head_v1_enabled(int32_t enabled);
        virtual void zwlr_output_head_v1_current_mode(struct ::zwlr_output_mode_v1 *mode);
        virtual void zwlr_output_head_v1_position(int32_t x, int32_t y);
        virtual void zwlr_output_head_v1_transform(int32_t transform);
        virtual void zwlr_output_head_v1_scale(wl_fixed_t scale);
        virtual void zwlr_output_head_v1_finished();
        virtual void zwlr_output_head_v1_make(const QString &make);
        virtual void zwlr_output_head_v1_model(const QString &model);
        virtual void zwlr_output_head_v1_serial_number(const QString &serial_number);
        virtual void zwlr_output_head_v1_adaptive_sync(uint32_t state);

    private:
        void init_listener();
        static const struct zwlr_output_head_v1_listener m_zwlr_output_head_v1_listener;
        static void handle_name(
            void *data,
            struct ::zwlr_output_head_v1 *object,
            const char *name);
        static void handle_description(
            void *data,
            struct ::zwlr_output_head_v1 *object,
            const char *description);
        static void handle_physical_size(
            void *data,
            struct ::zwlr_output_head_v1 *object,
            int32_t width,
            int32_t height);
        static void handle_mode(
            void *data,
            struct ::zwlr_output_head_v1 *object,
            struct ::zwlr_output_mode_v1 *mode);
        static void handle_enabled(
            void *data,
            struct ::zwlr_output_head_v1 *object,
            int32_t enabled);
        static void handle_current_mode(
            void *data,
            struct ::zwlr_output_head_v1 *object,
            struct ::zwlr_output_mode_v1 *mode);
        static void handle_position(
            void *data,
            struct ::zwlr_output_head_v1 *object,
            int32_t x,
            int32_t y);
        static void handle_transform(
            void *data,
            struct ::zwlr_output_head_v1 *object,
            int32_t transform);
        static void handle_scale(
            void *data,
            struct ::zwlr_output_head_v1 *object,
            wl_fixed_t scale);
        static void handle_finished(
            void *data,
            struct ::zwlr_output_head_v1 *object);
        static void handle_make(
            void *data,
            struct ::zwlr_output_head_v1 *object,
            const char *make);
        static void handle_model(
            void *data,
            struct ::zwlr_output_head_v1 *object,
            const char *model);
        static void handle_serial_number(
            void *data,
            struct ::zwlr_output_head_v1 *object,
            const char *serial_number);
        static void handle_adaptive_sync(
            void *data,
            struct ::zwlr_output_head_v1 *object,
            uint32_t state);
        struct ::zwlr_output_head_v1 *m_zwlr_output_head_v1;
    };

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

        virtual ~zwlr_output_mode_v1();

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

        struct ::zwlr_output_mode_v1 *object() { return m_zwlr_output_mode_v1; }
        const struct ::zwlr_output_mode_v1 *object() const { return m_zwlr_output_mode_v1; }
        static zwlr_output_mode_v1 *fromObject(struct ::zwlr_output_mode_v1 *object);

        bool isInitialized() const;

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

        void release();

    protected:
        virtual void zwlr_output_mode_v1_size(int32_t width, int32_t height);
        virtual void zwlr_output_mode_v1_refresh(int32_t refresh);
        virtual void zwlr_output_mode_v1_preferred();
        virtual void zwlr_output_mode_v1_finished();

    private:
        void init_listener();
        static const struct zwlr_output_mode_v1_listener m_zwlr_output_mode_v1_listener;
        static void handle_size(
            void *data,
            struct ::zwlr_output_mode_v1 *object,
            int32_t width,
            int32_t height);
        static void handle_refresh(
            void *data,
            struct ::zwlr_output_mode_v1 *object,
            int32_t refresh);
        static void handle_preferred(
            void *data,
            struct ::zwlr_output_mode_v1 *object);
        static void handle_finished(
            void *data,
            struct ::zwlr_output_mode_v1 *object);
        struct ::zwlr_output_mode_v1 *m_zwlr_output_mode_v1;
    };

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

        virtual ~zwlr_output_configuration_v1();

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

        struct ::zwlr_output_configuration_v1 *object() { return m_zwlr_output_configuration_v1; }
        const struct ::zwlr_output_configuration_v1 *object() const { return m_zwlr_output_configuration_v1; }
        static zwlr_output_configuration_v1 *fromObject(struct ::zwlr_output_configuration_v1 *object);

        bool isInitialized() const;

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

        enum error {
            error_already_configured_head = 1, // head has been configured twice
            error_unconfigured_head = 2, // head has not been configured
            error_already_used = 3, // request sent after configuration has been applied or tested
        };

        struct ::zwlr_output_configuration_head_v1 *enable_head(struct ::zwlr_output_head_v1 *head);
        void disable_head(struct ::zwlr_output_head_v1 *head);
        void apply();
        void test();
        void destroy();

    protected:
        virtual void zwlr_output_configuration_v1_succeeded();
        virtual void zwlr_output_configuration_v1_failed();
        virtual void zwlr_output_configuration_v1_cancelled();

    private:
        void init_listener();
        static const struct zwlr_output_configuration_v1_listener m_zwlr_output_configuration_v1_listener;
        static void handle_succeeded(
            void *data,
            struct ::zwlr_output_configuration_v1 *object);
        static void handle_failed(
            void *data,
            struct ::zwlr_output_configuration_v1 *object);
        static void handle_cancelled(
            void *data,
            struct ::zwlr_output_configuration_v1 *object);
        struct ::zwlr_output_configuration_v1 *m_zwlr_output_configuration_v1;
    };

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

        virtual ~zwlr_output_configuration_head_v1();

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

        struct ::zwlr_output_configuration_head_v1 *object() { return m_zwlr_output_configuration_head_v1; }
        const struct ::zwlr_output_configuration_head_v1 *object() const { return m_zwlr_output_configuration_head_v1; }
        static zwlr_output_configuration_head_v1 *fromObject(struct ::zwlr_output_configuration_head_v1 *object);

        bool isInitialized() const;

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

        enum error {
            error_already_set = 1, // property has already been set
            error_invalid_mode = 2, // mode doesn't belong to head
            error_invalid_custom_mode = 3, // mode is invalid
            error_invalid_transform = 4, // transform value outside enum
            error_invalid_scale = 5, // scale negative or zero
            error_invalid_adaptive_sync_state = 6, // invalid enum value used in the set_adaptive_sync request
        };

        void set_mode(struct ::zwlr_output_mode_v1 *mode);
        void set_custom_mode(int32_t width, int32_t height, int32_t refresh);
        void set_position(int32_t x, int32_t y);
        void set_transform(int32_t transform);
        void set_scale(wl_fixed_t scale);
        void set_adaptive_sync(uint32_t state);

    private:
        struct ::zwlr_output_configuration_head_v1 *m_zwlr_output_configuration_head_v1;
    };
}

QT_WARNING_POP
QT_END_NAMESPACE

#endif
