static WidgetDataBaseItem *createCustomWidgetItem(const QDesignerCustomWidgetInterface *c, const QDesignerCustomWidgetData &data) { WidgetDataBaseItem *item = new WidgetDataBaseItem(c->name(), c->group()); item->setContainer(c->isContainer()); item->setCustom(true); item->setIcon(c->icon()); item->setIncludeFile(c->includeFile()); item->setToolTip(c->toolTip()); item->setWhatsThis(c->whatsThis()); item->setPluginPath(data.pluginPath()); item->setAddPageMethod(data.xmlAddPageMethod()); item->setExtends(data.xmlExtends()); return item; }
WidgetDataBaseItem *WidgetDataBaseItem::clone(const QDesignerWidgetDataBaseItemInterface *item) { WidgetDataBaseItem *rc = new WidgetDataBaseItem(item->name(), item->group()); rc->setToolTip(item->toolTip()); rc->setWhatsThis(item->whatsThis()); rc->setIncludeFile(item->includeFile()); rc->setIcon(item->icon()); rc->setCompat(item->isCompat()); rc->setContainer(item->isContainer()); rc->setCustom(item->isCustom() ); rc->setPluginPath(item->pluginPath()); rc->setPromoted(item->isPromoted()); rc->setExtends(item->extends()); rc->setDefaultPropertyValues(item->defaultPropertyValues()); // container page method, fake slots and signals ignored here.y return rc; }