#include "pivariantedit_plugin.h"

#include "pivariant_edit.h"

#include <QtCore/QtPlugin>


PIVariantEditPlugin::PIVariantEditPlugin(QObject * parent): QObject(parent) {
	m_initialized = m_designer = false;
}


void PIVariantEditPlugin::initialize(QDesignerFormEditorInterface * /* core */) {
	m_designer = true;
	if (m_initialized) return;

	// Add extension registrations, etc. here

	m_initialized = true;
}


bool PIVariantEditPlugin::isInitialized() const {
	return m_initialized;
}


QWidget * PIVariantEditPlugin::createWidget(QWidget * parent) {
	return new PIVariantEdit(parent);
}


QString PIVariantEditPlugin::name() const {
	return QLatin1String("PIVariantEdit");
}


QString PIVariantEditPlugin::group() const {
	return QLatin1String("Input Widgets");
}


QIcon PIVariantEditPlugin::icon() const {
	return QIcon(":/icons/widgets/pivariantedit.png");
}


QString PIVariantEditPlugin::toolTip() const {
	return QLatin1String(""); // QLatin1String("Widget for display any math graphics with grid and navigation");
}


QString PIVariantEditPlugin::whatsThis() const {
	return QLatin1String("");
}


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


QString PIVariantEditPlugin::domXml() const {
	return QLatin1String("<widget class=\"PIVariantEdit\" name=\"pivariantEdit\">\n</widget>\n");
}


QString PIVariantEditPlugin::includeFile() const {
	return QLatin1String("pivariant_edit.h");
}
