50 #include "TypeQtWidget.hh"
52 TypeQtWidgetPlugin::TypeQtWidgetPlugin():
57 bool TypeQtWidgetPlugin::registerType() {
68 widgets_[
object->id()] = object;
70 QString
name = QString(tr(
"New Widget %1.lgt").arg( object->
id() ));
74 object->setName( f.fileName() );
76 object->enablePicking(
true);
79 emit emptyObjectAdded (object->
id() );
86 passMouseEvents(_event);
89 void TypeQtWidgetPlugin::passMouseEvents(QMouseEvent *_event)
91 for(std::map<int,QtWidgetObject*>::iterator iter = widgets_.begin(); iter != widgets_.end(); ++iter)
92 iter->second->mouseEvent(_event);
100 #if QT_VERSION < 0x050000
DLLEXPORT void setTypeIcon(DataType _id, QString _icon)
Set an Icon for a given DataType.
void slotMouseEvent(QMouseEvent *_event)
Mouse Event from main application ( Picking Mode )
QString name()
Return a name for the plugin.
DLLEXPORT DataType addDataType(QString _name, QString _readableName)
Adds a datatype and returns the id for the new type.
void objectDeleted(int _id)
An object was deleted.
int addEmpty()
Create an empty object.