quickshell/src/window/init.cpp
2024-11-05 04:15:17 -08:00

25 lines
534 B
C++

#include <qqml.h>
#include <qstring.h>
#include "../core/plugin.hpp"
namespace {
class WindowPlugin: public QuickshellPlugin {
// _Window has to be registered before wayland or x11 modules, otherwise module overlays
// will apply in the wrong order.
QString name() override { return "window"; }
void registerTypes() override {
qmlRegisterModuleImport(
"Quickshell",
QQmlModuleImportModuleAny,
"Quickshell._Window",
QQmlModuleImportLatest
);
}
};
QS_REGISTER_PLUGIN(WindowPlugin);
} // namespace