widgets/designerplugins.cpp

Wed, 22 Jun 2022 21:46:38 +0300

author
Teemu Piippo <teemu.s.piippo@gmail.com>
date
Wed, 22 Jun 2022 21:46:38 +0300
changeset 254
b7b29cb82360
parent 253
8b994c917f69
child 256
c6f5de03dc0f
permissions
-rw-r--r--

Rename Vec3Editor to VectorInput

#include "designerplugins.h"
#include "vec3editor.h"
#include "matrixeditor.h"

LDForgeWidgetCollection::LDForgeWidgetCollection(QObject* parent) :
	QObject{parent}
{
	this->interfaces.append(new Vec3EditorPlugin{this});
	this->interfaces.append(new MatrixEditorPlugin{this});
}

QList<QDesignerCustomWidgetInterface*> LDForgeWidgetCollection::customWidgets() const
{
	return this->interfaces;
}

QString Vec3EditorPlugin::name() const
{
	return "VectorInput";
}

QString Vec3EditorPlugin::group() const
{
	return "LDForge";
}

QString Vec3EditorPlugin::toolTip() const
{
	return "";
}

QString Vec3EditorPlugin::whatsThis() const
{
	return "";
}

QString Vec3EditorPlugin::includeFile() const
{
	return "vec3editor.h";
}

QIcon Vec3EditorPlugin::icon() const
{
	return {};
}

bool Vec3EditorPlugin::isContainer() const
{
	return false;
}

QWidget* Vec3EditorPlugin::createWidget(QWidget* parent)
{
	return new VectorInput{{0, 0, 0}, parent};
}

QString MatrixEditorPlugin::name() const
{
	return "MatrixEditor";
}

QString MatrixEditorPlugin::group() const
{
	return "LDForge";
}

QString MatrixEditorPlugin::toolTip() const
{
	return "";
}

QString MatrixEditorPlugin::whatsThis() const
{
	return "";
}

QString MatrixEditorPlugin::includeFile() const
{
	return "matrixeditor.h";
}

QIcon MatrixEditorPlugin::icon() const
{
	return {};
}

bool MatrixEditorPlugin::isContainer() const
{
	return false;
}

QWidget* MatrixEditorPlugin::createWidget(QWidget* parent)
{
	return new MatrixEditor{parent};
}

mercurial