#pragma once

#include "core/editorcallback.h"
#include "core/functional.h"

class CallbackSimple : public kku::EditorCallback
{
public:

    struct Init
    {
        kku::lambda run;
        kku::predicate is_enabled;
    };

    explicit CallbackSimple(Init&& init, Metadata&& metadata);

    virtual bool isEnabled() const override;
    virtual void run() const override;

    virtual Metadata getMetadata() const override;

private:
    const kku::lambda _run;
    const kku::predicate _is_enabled;
    const Metadata _metadata;
};
