diff options
Diffstat (limited to 'kexi/formeditor')
-rw-r--r-- | kexi/formeditor/commands.cpp | 24 | ||||
-rw-r--r-- | kexi/formeditor/connectiondialog.cpp | 12 | ||||
-rw-r--r-- | kexi/formeditor/factories/containerfactory.cpp | 12 | ||||
-rw-r--r-- | kexi/formeditor/factories/containerfactory.h | 6 | ||||
-rw-r--r-- | kexi/formeditor/factories/stdwidgetfactory.cpp | 12 | ||||
-rw-r--r-- | kexi/formeditor/form.cpp | 4 | ||||
-rw-r--r-- | kexi/formeditor/formIO.cpp | 24 | ||||
-rw-r--r-- | kexi/formeditor/formmanager.cpp | 20 | ||||
-rw-r--r-- | kexi/formeditor/kfdpixmapedit.cpp | 2 | ||||
-rw-r--r-- | kexi/formeditor/objecttreeview.cpp | 4 | ||||
-rw-r--r-- | kexi/formeditor/objecttreeview.h | 2 | ||||
-rw-r--r-- | kexi/formeditor/richtextdialog.cpp | 8 | ||||
-rw-r--r-- | kexi/formeditor/spring.cpp | 14 | ||||
-rw-r--r-- | kexi/formeditor/tdevelop_plugin/kfd_kdev_part.cpp | 4 | ||||
-rw-r--r-- | kexi/formeditor/test/kfd_part.cpp | 6 | ||||
-rw-r--r-- | kexi/formeditor/utils.cpp | 22 | ||||
-rw-r--r-- | kexi/formeditor/utils.h | 10 | ||||
-rw-r--r-- | kexi/formeditor/widgetfactory.cpp | 14 | ||||
-rw-r--r-- | kexi/formeditor/widgetlibrary.cpp | 6 | ||||
-rw-r--r-- | kexi/formeditor/widgetpropertyset.cpp | 16 | ||||
-rw-r--r-- | kexi/formeditor/widgetwithsubpropertiesinterface.cpp | 12 |
21 files changed, 117 insertions, 117 deletions
diff --git a/kexi/formeditor/commands.cpp b/kexi/formeditor/commands.cpp index c9bad809..241a1291 100644 --- a/kexi/formeditor/commands.cpp +++ b/kexi/formeditor/commands.cpp @@ -127,7 +127,7 @@ PropertyCommand::unexecute() WidgetWithSubpropertiesInterface* subpropIface = dynamic_cast<WidgetWithSubpropertiesInterface*>(widg); TQWidget *subWidget = (subpropIface && subpropIface->subwidget()) ? subpropIface->subwidget() : widg; - if (-1!=subWidget->tqmetaObject()->findProperty( m_property, true )) + if (-1!=subWidget->metaObject()->findProperty( m_property, true )) subWidget->setProperty(m_property, it.data()); } @@ -438,7 +438,7 @@ AdjustSizeCommand::execute() if(item && !item->tqchildren()->isEmpty()) { // container TQSize s; if(item->container() && item->container()->tqlayout()) - s = w->tqsizeHint(); + s = w->sizeHint(); else s = getSizeFromChildren(item); // minimum size for containers @@ -457,9 +457,9 @@ AdjustSizeCommand::execute() else if(item && item->container()) // empty container w->resize(item->container()->form()->gridSize() * 5, item->container()->form()->gridSize() * 5); // basic size else { - TQSize tqsizeHint(w->tqsizeHint()); - if (tqsizeHint.isValid()) - w->resize(tqsizeHint); + TQSize sizeHint(w->sizeHint()); + if (sizeHint.isValid()) + w->resize(sizeHint); } } break; @@ -755,7 +755,7 @@ InsertWidgetCommand::execute() // if the insertRect is invalid (ie only one point), we use widget' size hint if(( (m_insertRect.width() < 21) && (m_insertRect.height() < 21))) { - TQSize s = w->tqsizeHint(); + TQSize s = w->sizeHint(); if(s.isEmpty()) s = TQSize(20, 20); // Minimum size to avoid creating a (0,0) widget @@ -912,7 +912,7 @@ CreateLayoutCommand::execute() container->setSelectedWidget(0, false); w->move(m_pos.begin().data().topLeft()); // we move the tqlayout at the position of the topleft widget - // tqsizeHint of these widgets depends on tqgeometry, so give them appropriate tqgeometry + // sizeHint of these widgets depends on tqgeometry, so give them appropriate tqgeometry if(m_type == Container::HFlow) w->resize( TQSize(700, 20) ); else if(m_type == Container::VFlow) @@ -938,7 +938,7 @@ CreateLayoutCommand::execute() ((TQSplitter*)w)->setOrientation(Qt::Vertical); else if(tree->container()) { tree->container()->setLayout((Container::LayoutType)m_type); - w->resize(tree->container()->tqlayout()->tqsizeHint()); // the tqlayout doesn't have its own size + w->resize(tree->container()->tqlayout()->sizeHint()); // the tqlayout doesn't have its own size } container->setSelectedWidget(w, false); @@ -1249,13 +1249,13 @@ PasteWidgetCommand::fixPos(TQDomElement &el, Container *container) int rh = h.text().toInt(); TQRect r(rx, ry, rw, rh); - TQWidget *w = m_form->widget()->tqchildAt(r.x() + 6, r.y() + 6, false); + TQWidget *w = m_form->widget()->childAt(r.x() + 6, r.y() + 6, false); if(!w) return; while((w->tqgeometry() == r) && (w != 0))// there is already a widget there, with the same size { - w = m_form->widget()->tqchildAt(w->x() + 16, w->y() + 16, false); + w = m_form->widget()->childAt(w->x() + 16, w->y() + 16, false); r.moveBy(10,10); } @@ -1300,11 +1300,11 @@ PasteWidgetCommand::moveWidgetBy(TQDomElement &el, Container *container, const T TQRect r(rx + p.x(), ry + p.y(), rw, rh); kdDebug() << "Moving widget by " << p << " from " << rx << " " << ry << " to " << r.topLeft() << endl; - TQWidget *w = m_form->widget()->tqchildAt(r.x() + 6, r.y() + 6, false); + TQWidget *w = m_form->widget()->childAt(r.x() + 6, r.y() + 6, false); while(w && (w->tqgeometry() == r))// there is already a widget there, with the same size { - w = m_form->widget()->tqchildAt(w->x() + 16, w->y() + 16, false); + w = m_form->widget()->childAt(w->x() + 16, w->y() + 16, false); r.moveBy(10,10); } diff --git a/kexi/formeditor/connectiondialog.cpp b/kexi/formeditor/connectiondialog.cpp index f683ce74..38b6e08e 100644 --- a/kexi/formeditor/connectiondialog.cpp +++ b/kexi/formeditor/connectiondialog.cpp @@ -60,10 +60,10 @@ ConnectionDialog::ConnectionDialog(TQWidget *parent) m_pixmapLabel = new TQLabel(details); m_pixmapLabel->setFixedWidth( int(IconSize(KIcon::Desktop) * 1.5) ); - m_pixmapLabel->tqsetAlignment(AlignHCenter | AlignTop); + m_pixmapLabel->setAlignment(AlignHCenter | AlignTop); m_textLabel = new TQLabel(details); - m_textLabel->tqsetAlignment(AlignLeft | AlignTop); + m_textLabel->setAlignment(AlignLeft | AlignTop); //setStatusOk(); // And the KexiTableView //////// @@ -289,7 +289,7 @@ ConnectionDialog::updateSlotList(KexiTableItem *item) TQString signalArg(signal); signalArg = signalArg.remove( TQRegExp(".*[(]|[)]") ); - TQStrList slotList = tree->widget()->tqmetaObject()->slotNames(true); + TQStrList slotList = tree->widget()->metaObject()->slotNames(true); TQStrListIterator it(slotList); for(; it.current() != 0; ++it) { @@ -297,7 +297,7 @@ ConnectionDialog::updateSlotList(KexiTableItem *item) TQString slotArg(*it); slotArg = slotArg.remove( TQRegExp(".*[(]|[)]") ); - if(!signalArg.tqstartsWith(slotArg, true) && (!signal.isEmpty())) // args not compatible + if(!signalArg.startsWith(slotArg, true) && (!signal.isEmpty())) // args not compatible continue; KexiTableItem *item = m_slotsColumnData->createItem(); //new KexiTableItem(2); @@ -315,7 +315,7 @@ ConnectionDialog::updateSignalList(KexiTableItem *item) return; m_signalsColumnData->deleteAllRows(); - TQStrList signalList = tree->widget()->tqmetaObject()->signalNames(true); + TQStrList signalList = tree->widget()->metaObject()->signalNames(true); TQStrListIterator it(signalList); for(; it.current() != 0; ++it) { @@ -346,7 +346,7 @@ ConnectionDialog::checkConnection(KexiTableItem *item) TQString slot = (*item)[4].toString(); slot = slot.remove( TQRegExp(".*[(]|[)]") ); - if(!signal.tqstartsWith(slot, true)) + if(!signal.startsWith(slot, true)) { setStatusError( i18n("The signal/slot arguments are not compatible."), item); return; diff --git a/kexi/formeditor/factories/containerfactory.cpp b/kexi/formeditor/factories/containerfactory.cpp index acc72c24..2e30d5f4 100644 --- a/kexi/formeditor/factories/containerfactory.cpp +++ b/kexi/formeditor/factories/containerfactory.cpp @@ -73,7 +73,7 @@ ContainerWidget::~ContainerWidget() { } -TQSize ContainerWidget::tqsizeHint() const +TQSize ContainerWidget::sizeHint() const { return TQSize(30,30); //default } @@ -125,7 +125,7 @@ KFDTabWidget::~KFDTabWidget() } TQSize -KFDTabWidget::tqsizeHint() const +KFDTabWidget::sizeHint() const { TQSize s(30,30); // default min size for(int i=0; i < count(); i++) @@ -218,10 +218,10 @@ VFlow::paintEvent(TQPaintEvent *) } TQSize -VFlow::tqsizeHint() const +VFlow::sizeHint() const { if(tqlayout()) - return tqlayout()->tqsizeHint(); + return tqlayout()->sizeHint(); else return TQSize(700, 50); // default } @@ -318,7 +318,7 @@ SubForm::SubForm(TQWidget *parent, const char *name) : TQScrollView(parent, name), m_form(0), m_widget(0) { setFrameStyle(TQFrame::WinPanel | TQFrame::Sunken); - viewport()->setPaletteBackgroundColor(tqcolorGroup().mid()); + viewport()->setPaletteBackgroundColor(colorGroup().mid()); } void @@ -860,7 +860,7 @@ void ContainerFactory::renameTabPage() #if TDE_VERSION < KDE_MAKE_VERSION(3,1,9) TQLineEdit::Normal, #endif - tab->tabLabel(w), &ok, w->tqtopLevelWidget()); + tab->tabLabel(w), &ok, w->topLevelWidget()); if(ok) tab->changeTab(w, name); } diff --git a/kexi/formeditor/factories/containerfactory.h b/kexi/formeditor/factories/containerfactory.h index b88b437f..6f013e9c 100644 --- a/kexi/formeditor/factories/containerfactory.h +++ b/kexi/formeditor/factories/containerfactory.h @@ -126,7 +126,7 @@ class KFORMEDITOR_EXPORT VFlow : public TQFrame virtual ~VFlow(){;} void setPreviewMode() {m_preview = true;} virtual void paintEvent(TQPaintEvent *ev); - virtual TQSize tqsizeHint() const; + virtual TQSize sizeHint() const; protected: bool m_preview; @@ -144,7 +144,7 @@ class KFORMEDITOR_EXPORT ContainerWidget : public TQWidget ContainerWidget(TQWidget *parent, const char *name); virtual ~ContainerWidget(); - virtual TQSize tqsizeHint() const; + virtual TQSize sizeHint() const; //! Used to emit handleDragMoveEvent() signal needed to control dragging over the container's surface virtual void dragMoveEvent( TQDragMoveEvent *e ); @@ -170,7 +170,7 @@ class KFORMEDITOR_EXPORT KFDTabWidget : public KFormDesigner::TabWidget KFDTabWidget(TQWidget *parent, const char *name); virtual ~KFDTabWidget(); - virtual TQSize tqsizeHint() const; + virtual TQSize sizeHint() const; //! Used to emit handleDragMoveEvent() signal needed to control dragging over the container's surface virtual void dragMoveEvent( TQDragMoveEvent *e ); diff --git a/kexi/formeditor/factories/stdwidgetfactory.cpp b/kexi/formeditor/factories/stdwidgetfactory.cpp index 24827e13..afc37086 100644 --- a/kexi/formeditor/factories/stdwidgetfactory.cpp +++ b/kexi/formeditor/factories/stdwidgetfactory.cpp @@ -431,13 +431,13 @@ StdWidgetFactory::createWidget(const TQCString &c, TQWidget *p, const char *n, w = new KProgress(p, n); else if(c == "KDateWidget") - w = new KDateWidget(TQDate::tqcurrentDate(), p, n); + w = new KDateWidget(TQDate::currentDate(), p, n); else if(c == "KTimeWidget") w = new KTimeWidget(TQTime::currentTime(), p, n); else if(c == "KDateTimeWidget") - w = new KDateTimeWidget(TQDateTime::tqcurrentDateTime(), p, n); + w = new KDateTimeWidget(TQDateTime::currentDateTime(), p, n); else if(c == "Line") w = new Line(options & WidgetFactory::VerticalOrientation ? Qt::Vertical : Qt::Horizontal, p, n); @@ -605,13 +605,13 @@ StdWidgetFactory::changeText(const TQString &text) else changeProperty("text", text, m_container->form()); - /* By-hand method not needed as tqsizeHint() can do that for us + /* By-hand method not needed as sizeHint() can do that for us TQFontMetrics fm = w->fontMetrics(); TQSize s(fm.width( text ), fm.height()); int width; if(n == TQLABEL_OBJECT_NAME_STRING) // labels are resized to fit the text { - w->resize(w->tqsizeHint()); + w->resize(w->sizeHint()); WidgetFactory::m_editor->resize(w->size()); return; } @@ -624,7 +624,7 @@ StdWidgetFactory::changeText(const TQString &text) width = w->style().sizeFromContents( TQStyle::CT_RadioButton, w, s).width(); else return; - int width = w->tqsizeHint().width();*/ + int width = w->sizeHint().width();*/ #if 0 //not needed here, size hint is used on creation in InsertWidgetCommand::execute() if(w->width() < width) @@ -956,7 +956,7 @@ StdWidgetFactory::editText() } if(classname == TQLABEL_OBJECT_NAME_STRING) - widget()->resize(widget()->tqsizeHint()); + widget()->resize(widget()->sizeHint()); } void diff --git a/kexi/formeditor/form.cpp b/kexi/formeditor/form.cpp index b5b20936..237c7ec8 100644 --- a/kexi/formeditor/form.cpp +++ b/kexi/formeditor/form.cpp @@ -364,10 +364,10 @@ Form::changeName(const TQCString &oldname, const TQCString &newname) return; if(!d->topTree->rename(oldname, newname)) // rename failed { - KMessageBox::sorry(widget()->tqtopLevelWidget(), + KMessageBox::sorry(widget()->topLevelWidget(), i18n("Renaming widget \"%1\" to \"%2\" failed.").tqarg(TQString(oldname)).tqarg(TQString(newname))); //moved to WidgetPropertySet::slotChangeProperty() -// KMessageBox::sorry(widget()->tqtopLevelWidget(), +// KMessageBox::sorry(widget()->topLevelWidget(), // i18n("A widget with this name already exists. " // "Please choose another name or rename existing widget.")); kdDebug() << "Form::changeName() : ERROR : A widget named " << newname << " already exists" << endl; diff --git a/kexi/formeditor/formIO.cpp b/kexi/formeditor/formIO.cpp index 2759fe98..24347c40 100644 --- a/kexi/formeditor/formIO.cpp +++ b/kexi/formeditor/formIO.cpp @@ -406,10 +406,10 @@ FormIO::savePropertyValue(TQDomElement &parentNode, TQDomDocument &parent, const WidgetWithSubpropertiesInterface* subpropIface = dynamic_cast<WidgetWithSubpropertiesInterface*>(w); TQWidget *subwidget = w; bool addSubwidgetFlag = false; - int propertyId = w->tqmetaObject()->findProperty(name, true); + int propertyId = w->metaObject()->findProperty(name, true); if (propertyId == -1 && subpropIface && subpropIface->subwidget()) { // try property from subwidget subwidget = subpropIface->subwidget(); - propertyId = subpropIface->subwidget()->tqmetaObject()->findProperty(name, true); + propertyId = subpropIface->subwidget()->metaObject()->findProperty(name, true); addSubwidgetFlag = true; } if(propertyId == -1) @@ -420,7 +420,7 @@ FormIO::savePropertyValue(TQDomElement &parentNode, TQDomDocument &parent, const return; } - const TQMetaProperty *meta = subwidget->tqmetaObject()->property(propertyId, true); + const TQMetaProperty *meta = subwidget->metaObject()->property(propertyId, true); if (!meta->stored( subwidget )) //not storable return; TQDomElement propertyE = parent.createElement("property"); @@ -880,8 +880,8 @@ FormIO::readPropertyValue(TQDomNode node, TQObject *obj, const TQString &name) { WidgetWithSubpropertiesInterface* subpropIface = dynamic_cast<WidgetWithSubpropertiesInterface*>(obj); TQObject *subobject = (subpropIface && subpropIface->subwidget()) ? TQT_TQOBJECT(subpropIface->subwidget()) : obj; - const int count = subobject->tqmetaObject()->findProperty(name.latin1(), true); - const TQMetaProperty *meta = count!=-1 ? subobject->tqmetaObject()->property(count, true) : 0; + const int count = subobject->metaObject()->findProperty(name.latin1(), true); + const TQMetaProperty *meta = count!=-1 ? subobject->metaObject()->property(count, true) : 0; if (meta) { if (meta->isSetType()) { @@ -968,7 +968,7 @@ FormIO::saveWidget(ObjectTreeItem *item, TQDomElement &parent, TQDomDocument &do // - needed when subproperties are defined after subwidget creation, and subwidget is created after setting "dataSource" // (this is the case for KexiDBAutoField) //! @todo more properties like "dataSource" may needed here... -// if (-1 != item->widget()->tqmetaObject()->findProperty("dataSource")) +// if (-1 != item->widget()->metaObject()->findProperty("dataSource")) // savePropertyValue(tclass, domDoc, "dataSource", item->widget()->property("dataSource"), item->widget()); // We don't want to save the tqgeometry if the widget is inside a tqlayout (so parent.tagName() == "grid" for example) @@ -1261,7 +1261,7 @@ FormIO::loadWidget(Container *container, const TQDomElement &el, TQWidget *paren = dynamic_cast<KFormDesigner::WidgetWithSubpropertiesInterface*>(w); TQWidget *subwidget = (subpropIface && subpropIface->subwidget()) ? subpropIface->subwidget() : w; for(TQValueList<TQCString>::ConstIterator it = list.constBegin(); it != endIt; ++it) { - if(subwidget->tqmetaObject()->findProperty(*it, true) != -1) + if(subwidget->metaObject()->findProperty(*it, true) != -1) item->addModifiedProperty(*it, subwidget->property(*it)); } @@ -1376,9 +1376,9 @@ FormIO::readChildNodes(ObjectTreeItem *item, Container *container, const TQDomEl } } // If the object doesn't have this property, we let the Factory handle it (maybe a special property) - else if(subwidget->tqmetaObject()->findProperty(name.latin1(), true) == -1) + else if(subwidget->metaObject()->findProperty(name.latin1(), true) == -1) { - if(w->className() == TQString::tqfromLatin1("CustomWidget")) + if(w->className() == TQString::fromLatin1("CustomWidget")) item->storeUnknownProperty(node); else { bool read = container->form()->library()->readSpecialProperty( @@ -1400,8 +1400,8 @@ FormIO::readChildNodes(ObjectTreeItem *item, Container *container, const TQDomEl val = r; } subwidget->setProperty(name.latin1(), val); -// int count = w->tqmetaObject()->findProperty(name, true); -// const TQMetaProperty *meta = w->tqmetaObject()->property(count, true); +// int count = w->metaObject()->findProperty(name, true); +// const TQMetaProperty *meta = w->metaObject()->property(count, true); // if(meta && meta->isEnumType()) { // val = w->property(name.latin1()); //update: we want a numeric value of enum // } @@ -1460,7 +1460,7 @@ FormIO::readChildNodes(ObjectTreeItem *item, Container *container, const TQDomEl readChildNodes(item, container, node, w); } else {// unknown tag, we let the Factory handle it - if(w->className() == TQString::tqfromLatin1("CustomWidget")) + if(w->className() == TQString::fromLatin1("CustomWidget")) item->storeUnknownProperty(node); else { bool read = container->form()->library()->readSpecialProperty( diff --git a/kexi/formeditor/formmanager.cpp b/kexi/formeditor/formmanager.cpp index a2ed0dac..5fb76ca8 100644 --- a/kexi/formeditor/formmanager.cpp +++ b/kexi/formeditor/formmanager.cpp @@ -227,7 +227,7 @@ FormManager::createActions(WidgetLibrary *lib, KActionCollection* collection, KX m_style->setEditable(false); KGlobal::config()->setGroup("General"); - TQString currentStyle = TQString::tqfromLatin1(kapp->tqstyle().name()).lower(); + TQString currentStyle = TQString::fromLatin1(kapp->tqstyle().name()).lower(); const TQStringList styles = TQStyleFactory::keys(); m_style->setItems(styles); m_style->setCurrentItem(0); @@ -790,7 +790,7 @@ FormManager::createSignalMenu(TQWidget *w) m_sigSlotMenu = new KPopupMenu(); m_sigSlotMenu->insertTitle(SmallIcon("connection"), i18n("Signals")); - TQStrList list = w->tqmetaObject()->signalNames(true); + TQStrList list = w->metaObject()->signalNames(true); TQStrListIterator it(list); for(; it.current() != 0; ++it) m_sigSlotMenu->insertItem(*it); @@ -813,14 +813,14 @@ FormManager::createSlotMenu(TQWidget *w) TQString signalArg( m_connection->signal().remove( TQRegExp(".*[(]|[)]") ) ); - TQStrList list = w->tqmetaObject()->slotNames(true); + TQStrList list = w->metaObject()->slotNames(true); TQStrListIterator it(list); for(; it.current() != 0; ++it) { // we add the slot only if it is compatible with the signal TQString slotArg(*it); slotArg = slotArg.remove( TQRegExp(".*[(]|[)]") ); - if(!signalArg.tqstartsWith(slotArg, true)) // args not compatible + if(!signalArg.startsWith(slotArg, true)) // args not compatible continue; m_sigSlotMenu->insertItem(*it); @@ -937,7 +937,7 @@ FormManager::createContextMenu(TQWidget *w, Container *container, bool popupAtCu // We create the signals menu KPopupMenu *sigMenu = new KPopupMenu(); - TQStrList list = w->tqmetaObject()->signalNames(true); + TQStrList list = w->metaObject()->signalNames(true); TQStrListIterator it(list); for(; it.current() != 0; ++it) sigMenu->insertItem(*it); @@ -1115,7 +1115,7 @@ FormManager::createLayout(int layoutType) kdDebug() << "comparing widget " << w->name() << " whose parent is " << w->parentWidget()->name() << " insteaed of " << parent->name() << endl; if(w->parentWidget() != parent) { - KMessageBox::sorry(m_active->widget()->tqtopLevelWidget(), i18n("<b>Cannot create the tqlayout.</b>\n" + KMessageBox::sorry(m_active->widget()->topLevelWidget(), i18n("<b>Cannot create the tqlayout.</b>\n" "All selected widgets must have the same parent.")); kdDebug() << "FormManager::createLayout() widgets don't have the same parent widget" << endl; return; @@ -1188,7 +1188,7 @@ FormManager::editTabOrder() { if(!activeForm() || !activeForm()->objectTree()) return; - TQWidget *topLevel = m_active->widget()->tqtopLevelWidget(); + TQWidget *topLevel = m_active->widget()->topLevelWidget(); TabStopDialog dlg(topLevel); //const bool oldAutoTabStops = m_active->autoTabStops(); if (dlg.exec(m_active) == TQDialog::Accepted) { @@ -1222,7 +1222,7 @@ FormManager::editFormPixmapCollection() if(!activeForm() || !activeForm()->objectTree()) return; - PixmapCollectionEditor dialog(activeForm()->pixmapCollection(), activeForm()->widget()->tqtopLevelWidget()); + PixmapCollectionEditor dialog(activeForm()->pixmapCollection(), activeForm()->widget()->topLevelWidget()); dialog.exec(); } @@ -1234,7 +1234,7 @@ FormManager::editConnections() if(!activeForm() || !activeForm()->objectTree()) return; - ConnectionDialog dialog(activeForm()->widget()->tqtopLevelWidget()); + ConnectionDialog dialog(activeForm()->widget()->topLevelWidget()); dialog.exec(activeForm()); } @@ -1493,7 +1493,7 @@ FormManager::emitWidgetSelected( KFormDesigner::Form* form, bool multiple ) WidgetList *wlist = form->selectedWidgets(); bool fontEnabled = false; for (WidgetListIterator it(*wlist); it.current(); ++it) { - if (-1 != it.current()->tqmetaObject()->findProperty("font", true)) { + if (-1 != it.current()->metaObject()->findProperty("font", true)) { fontEnabled = true; break; } diff --git a/kexi/formeditor/kfdpixmapedit.cpp b/kexi/formeditor/kfdpixmapedit.cpp index db9a726e..64e65f1e 100644 --- a/kexi/formeditor/kfdpixmapedit.cpp +++ b/kexi/formeditor/kfdpixmapedit.cpp @@ -48,7 +48,7 @@ KFDPixmapEdit::selectPixmap() ObjectTreeItem *item = m_manager->activeForm()->objectTree()->lookup(m_manager->activeForm()->selectedWidget()->name()); TQString name = item ? item->pixmapName(property()->name()) : ""; - PixmapCollectionChooser dialog( m_manager->activeForm()->pixmapCollection(), name, tqtopLevelWidget() ); + PixmapCollectionChooser dialog( m_manager->activeForm()->pixmapCollection(), name, topLevelWidget() ); if(dialog.exec() == TQDialog::Accepted) { setValue(dialog.pixmap(), true); item->setPixmapName(property()->name(), dialog.pixmapName()); diff --git a/kexi/formeditor/objecttreeview.cpp b/kexi/formeditor/objecttreeview.cpp index 049df3a5..ba48214b 100644 --- a/kexi/formeditor/objecttreeview.cpp +++ b/kexi/formeditor/objecttreeview.cpp @@ -191,10 +191,10 @@ ObjectTreeView::~ObjectTreeView() } TQSize -ObjectTreeView::tqsizeHint() const +ObjectTreeView::sizeHint() const { return TQSize( TQFontMetrics(font()).width(columnText(0)+columnText(1)+" "), - KListView::tqsizeHint().height()); + KListView::sizeHint().height()); } TQString diff --git a/kexi/formeditor/objecttreeview.h b/kexi/formeditor/objecttreeview.h index b625c0ad..2ddf867c 100644 --- a/kexi/formeditor/objecttreeview.h +++ b/kexi/formeditor/objecttreeview.h @@ -73,7 +73,7 @@ class KFORMEDITOR_EXPORT ObjectTreeView : public KListView ObjectTreeView(TQWidget *parent=0, const char *name=0, bool tabStop = false); virtual ~ObjectTreeView(); - virtual TQSize tqsizeHint() const; + virtual TQSize sizeHint() const; /*! Sets \a form as the current Form in the list. The list will automatically be filled with an item for each widget in the Form, and selection will be synced. diff --git a/kexi/formeditor/richtextdialog.cpp b/kexi/formeditor/richtextdialog.cpp index 168102b0..e3b73975 100644 --- a/kexi/formeditor/richtextdialog.cpp +++ b/kexi/formeditor/richtextdialog.cpp @@ -146,10 +146,10 @@ RichTextDialog::buttonToggled(int id) if(!isOn) break; switch(id) { - case TBLeft: m_edit->tqsetAlignment(TQt::AlignLeft); break; - case TBCenter: m_edit->tqsetAlignment(TQt::AlignCenter); break; - case TBRight: m_edit->tqsetAlignment(TQt::AlignRight); break; - case TBJustify: m_edit->tqsetAlignment(TQt::AlignJustify); break; + case TBLeft: m_edit->setAlignment(TQt::AlignLeft); break; + case TBCenter: m_edit->setAlignment(TQt::AlignCenter); break; + case TBRight: m_edit->setAlignment(TQt::AlignRight); break; + case TBJustify: m_edit->setAlignment(TQt::AlignJustify); break; default: break; } } diff --git a/kexi/formeditor/spring.cpp b/kexi/formeditor/spring.cpp index 1ec9a2b4..074b8810 100644 --- a/kexi/formeditor/spring.cpp +++ b/kexi/formeditor/spring.cpp @@ -54,18 +54,18 @@ Spring::SizeType Spring::sizeType() const { if(m_orient ==Qt::Vertical) - return (SizeType)tqsizePolicy().verData(); + return (SizeType)sizePolicy().verData(); else - return (SizeType)tqsizePolicy().horData(); + return (SizeType)sizePolicy().horData(); } void Spring::setSizeType(SizeType size) { if(m_orient ==Qt::Vertical) - tqsetSizePolicy(TQSizePolicy::Minimum, (TQSizePolicy::SizeType)size); + setSizePolicy(TQSizePolicy::Minimum, (TQSizePolicy::SizeType)size); else - tqsetSizePolicy( (TQSizePolicy::SizeType)size, TQSizePolicy::Minimum); + setSizePolicy( (TQSizePolicy::SizeType)size, TQSizePolicy::Minimum); } void @@ -144,10 +144,10 @@ Spring::saveSpring(KFormDesigner::ObjectTreeItem *item, TQDomElement &parentNode if(parentNode.tagName() == "widget") KFormDesigner::FormIO::savePropertyValue(tclass, domDoc, "geometry", item->widget()->property("geometry"), item->widget()); - if(!item->widget()->tqsizeHint().isValid()) - KFormDesigner::FormIO::savePropertyValue(tclass, domDoc, "tqsizeHint", item->widget()->property("size"), item->widget()); + if(!item->widget()->sizeHint().isValid()) + KFormDesigner::FormIO::savePropertyValue(tclass, domDoc, "sizeHint", item->widget()->property("size"), item->widget()); else - KFormDesigner::FormIO::savePropertyValue(tclass, domDoc, "tqsizeHint", item->widget()->property("tqsizeHint"), item->widget()); + KFormDesigner::FormIO::savePropertyValue(tclass, domDoc, "sizeHint", item->widget()->property("sizeHint"), item->widget()); KFormDesigner::FormIO::savePropertyValue(tclass, domDoc, "orientation", item->widget()->property("orientation"), item->widget()); KFormDesigner::FormIO::savePropertyValue(tclass, domDoc, "sizeType", item->widget()->property("sizeType"), item->widget()); diff --git a/kexi/formeditor/tdevelop_plugin/kfd_kdev_part.cpp b/kexi/formeditor/tdevelop_plugin/kfd_kdev_part.cpp index 0cfe0483..09549ddc 100644 --- a/kexi/formeditor/tdevelop_plugin/kfd_kdev_part.cpp +++ b/kexi/formeditor/tdevelop_plugin/kfd_kdev_part.cpp @@ -276,7 +276,7 @@ void KFormDesignerKDevPart::open() { m_openingFile = true; - KURL url = KFileDialog::getOpenURL("::kformdesigner", i18n("*.ui|TQt Designer UI Files"), m_workspace->tqtopLevelWidget()); + KURL url = KFileDialog::getOpenURL("::kformdesigner", i18n("*.ui|TQt Designer UI Files"), m_workspace->topLevelWidget()); if(!url.isEmpty()) ReadWritePart::openURL(url); m_openingFile = false; @@ -321,7 +321,7 @@ KFormDesignerKDevPart::saveAs() bool KFormDesignerKDevPart::closeForm(Form *form) { - int res = KMessageBox::warningYesNoCancel( m_workspace->tqtopLevelWidget(), + int res = KMessageBox::warningYesNoCancel( m_workspace->topLevelWidget(), i18n( "The form \"%1\" has been modified.\n" "Do you want to save your changes or discard them?" ).tqarg( form->objectTree()->name() ), i18n( "Close Form" ), KStdGuiItem::save(), KStdGuiItem::discard() ); diff --git a/kexi/formeditor/test/kfd_part.cpp b/kexi/formeditor/test/kfd_part.cpp index cd51817a..386bdabf 100644 --- a/kexi/formeditor/test/kfd_part.cpp +++ b/kexi/formeditor/test/kfd_part.cpp @@ -296,7 +296,7 @@ void KFormDesignerPart::open() { m_openingFile = true; - KURL url = KFileDialog::getOpenURL("::kformdesigner", i18n("*.ui|TQt Designer UI Files"), m_workspace->tqtopLevelWidget()); + KURL url = KFileDialog::getOpenURL("::kformdesigner", i18n("*.ui|TQt Designer UI Files"), m_workspace->topLevelWidget()); if(!url.isEmpty()) ReadWritePart::openURL(url); m_openingFile = false; @@ -332,7 +332,7 @@ void KFormDesignerPart::saveAs() { KURL url = KFileDialog::getSaveURL("::kformdesigner", i18n("*.ui|TQt Designer UI Files"), - m_workspace->tqtopLevelWidget()); + m_workspace->topLevelWidget()); if(url.isEmpty()) return; else @@ -342,7 +342,7 @@ KFormDesignerPart::saveAs() bool KFormDesignerPart::closeForm(Form *form) { - int res = KMessageBox::questionYesNoCancel( m_workspace->tqtopLevelWidget(), + int res = KMessageBox::questionYesNoCancel( m_workspace->topLevelWidget(), i18n( "The form \"%1\" has been modified.\n" "Do you want to save your changes or discard them?" ).tqarg( form->objectTree()->name() ), i18n( "Close Form" ), KStdGuiItem::save(), KStdGuiItem::discard() ); diff --git a/kexi/formeditor/utils.cpp b/kexi/formeditor/utils.cpp index 6ce4bcae..85e93204 100644 --- a/kexi/formeditor/utils.cpp +++ b/kexi/formeditor/utils.cpp @@ -119,9 +119,9 @@ KFormDesigner::getSizeFromChildren(TQWidget *w, const char *inheritClass) // ----------------- -HorWidgetList::HorWidgetList(TQWidget *tqtopLevelWidget) +HorWidgetList::HorWidgetList(TQWidget *topLevelWidget) : WidgetList() - , m_tqtopLevelWidget(tqtopLevelWidget) + , m_topLevelWidget(topLevelWidget) { } @@ -133,14 +133,14 @@ int HorWidgetList::compareItems(TQPtrCollection::Item item1, TQPtrCollection::It { TQWidget *w1 = TQT_TQWIDGET(item1); TQWidget *w2 = TQT_TQWIDGET(item2); - return w1->mapTo(m_tqtopLevelWidget, TQPoint(0,0)).x() - w2->mapTo(m_tqtopLevelWidget, TQPoint(0,0)).x(); + return w1->mapTo(m_topLevelWidget, TQPoint(0,0)).x() - w2->mapTo(m_topLevelWidget, TQPoint(0,0)).x(); } // ----------------- -VerWidgetList::VerWidgetList(TQWidget *tqtopLevelWidget) +VerWidgetList::VerWidgetList(TQWidget *topLevelWidget) : WidgetList() - , m_tqtopLevelWidget(tqtopLevelWidget) + , m_topLevelWidget(topLevelWidget) { } @@ -157,9 +157,9 @@ int VerWidgetList::compareItems(TQPtrCollection::Item item1, TQPtrCollection::It TQObject *page1 = 0; TabWidget *tw1 = KFormDesigner::findParent<KFormDesigner::TabWidget>(w1, "KFormDesigner::TabWidget", page1); if (tw1) // special case - y1 = w1->mapTo(m_tqtopLevelWidget, TQPoint(0,0)).y() + tw1->tabBarHeight() -2 -2; + y1 = w1->mapTo(m_topLevelWidget, TQPoint(0,0)).y() + tw1->tabBarHeight() -2 -2; else - y1 = w1->mapTo(m_tqtopLevelWidget, TQPoint(0,0)).y(); + y1 = w1->mapTo(m_topLevelWidget, TQPoint(0,0)).y(); TQObject *page2 = 0; TabWidget *tw2 = KFormDesigner::findParent<KFormDesigner::TabWidget>(w2, "KFormDesigner::TabWidget", page2); @@ -169,16 +169,16 @@ int VerWidgetList::compareItems(TQPtrCollection::Item item1, TQPtrCollection::It } if (tw2) // special case - y2 = w2->mapTo(m_tqtopLevelWidget, TQPoint(0,0)).y() + tw2->tabBarHeight() -2 -2; + y2 = w2->mapTo(m_topLevelWidget, TQPoint(0,0)).y() + tw2->tabBarHeight() -2 -2; else - y2 = w2->mapTo(m_tqtopLevelWidget, TQPoint(0,0)).y(); + y2 = w2->mapTo(m_topLevelWidget, TQPoint(0,0)).y(); kdDebug() << w1->name() << ": " << y1 << " " << " | " << w2->name() << ": " << y2 << endl; - //kdDebug() << w1->name() << ": " << w1->mapTo(m_tqtopLevelWidget, TQPoint(0,0)) << " " << w1->y() - //<< " | " << w2->name() << ":" /*<< w2->mapFrom(m_tqtopLevelWidget, TQPoint(0,w2->y()))*/ << " " << w2->y() << endl; + //kdDebug() << w1->name() << ": " << w1->mapTo(m_topLevelWidget, TQPoint(0,0)) << " " << w1->y() + //<< " | " << w2->name() << ":" /*<< w2->mapFrom(m_topLevelWidget, TQPoint(0,w2->y()))*/ << " " << w2->y() << endl; return y1 - y2; } diff --git a/kexi/formeditor/utils.h b/kexi/formeditor/utils.h index 3d078401..5107b45c 100644 --- a/kexi/formeditor/utils.h +++ b/kexi/formeditor/utils.h @@ -71,22 +71,22 @@ typedef TQPtrListIterator<TQWidget> WidgetListIterator; class HorWidgetList : public WidgetList { public: - HorWidgetList(TQWidget *tqtopLevelWidget); + HorWidgetList(TQWidget *topLevelWidget); virtual ~HorWidgetList(); protected: virtual int compareItems(TQPtrCollection::Item item1, TQPtrCollection::Item item2); - TQWidget *m_tqtopLevelWidget; + TQWidget *m_topLevelWidget; }; //! @short A helper for sorting widgets vertically class VerWidgetList : public WidgetList { public: - VerWidgetList(TQWidget *tqtopLevelWidget); + VerWidgetList(TQWidget *topLevelWidget); virtual ~VerWidgetList(); protected: virtual int compareItems(TQPtrCollection::Item item1, TQPtrCollection::Item item2); - TQWidget *m_tqtopLevelWidget; + TQWidget *m_topLevelWidget; }; /*! This function is used to remove all the child widgets from a list, and @@ -105,7 +105,7 @@ KFORMEDITOR_EXPORT void removeRecursiveEventFilter(TQObject *object, TQObject *c KFORMEDITOR_EXPORT void setRecursiveCursor(TQWidget *w, Form *form); -/*! \return the size of \a w tqchildren. This can be used eg to get widget's tqsizeHint. */ +/*! \return the size of \a w tqchildren. This can be used eg to get widget's sizeHint. */ KFORMEDITOR_EXPORT TQSize getSizeFromChildren(TQWidget *widget, const char *inheritClass=TQWIDGET_OBJECT_NAME_STRING); } diff --git a/kexi/formeditor/widgetfactory.cpp b/kexi/formeditor/widgetfactory.cpp index 178e2b74..61688ac6 100644 --- a/kexi/formeditor/widgetfactory.cpp +++ b/kexi/formeditor/widgetfactory.cpp @@ -190,7 +190,7 @@ WidgetFactory::createEditor(const TQCString &classname, const TQString &text, if (multiLine) { KTextEdit *textedit = new KTextEdit(text, TQString(), w->parentWidget()); textedit->setTextFormat(TQt::PlainText); - textedit->tqsetAlignment(align); + textedit->setAlignment(align); if (dynamic_cast<TQTextEdit*>(w)) { textedit->setWordWrap(dynamic_cast<TQTextEdit*>(w)->wordWrap()); textedit->setWrapPolicy(dynamic_cast<TQTextEdit*>(w)->wrapPolicy()); @@ -203,7 +203,7 @@ WidgetFactory::createEditor(const TQCString &classname, const TQString &text, textedit->setBackgroundMode(w->backgroundMode()); else textedit->setBackgroundMode(background); -// textedit->setPaletteBackgroundColor(textedit->tqcolorGroup().color( TQColorGroup::Base )); +// textedit->setPaletteBackgroundColor(textedit->colorGroup().color( TQColorGroup::Base )); textedit->setPaletteBackgroundColor(w->paletteBackgroundColor()); for(int i =0; i <= textedit->paragraphs(); i++) textedit->setParagraphBackgroundColor(i, w->paletteBackgroundColor()); @@ -229,7 +229,7 @@ WidgetFactory::createEditor(const TQCString &classname, const TQString &text, } else { KLineEdit *editor = new KLineEdit(text, w->parentWidget()); - editor->tqsetAlignment(align); + editor->setAlignment(align); editor->setPalette(w->palette()); editor->setFont(w->font()); editor->setGeometry(tqgeometry); @@ -253,7 +253,7 @@ WidgetFactory::createEditor(const TQCString &classname, const TQString &text, //copy properties if available WidgetWithSubpropertiesInterface* subpropIface = dynamic_cast<WidgetWithSubpropertiesInterface*>(w); TQWidget *subwidget = (subpropIface && subpropIface->subwidget()) ? subpropIface->subwidget() : w; - if (-1!=m_editor->tqmetaObject()->findProperty("margin", true) && -1!=subwidget->tqmetaObject()->findProperty("margin", true)) + if (-1!=m_editor->metaObject()->findProperty("margin", true) && -1!=subwidget->metaObject()->findProperty("margin", true)) m_editor->setProperty("margin", subwidget->property("margin")); //#endif //js m_handles = new ResizeHandleSet(w, container->form(), true); @@ -314,7 +314,7 @@ WidgetFactory::disableFilter(TQWidget *w, Container *container) bool WidgetFactory::editList(TQWidget *w, TQStringList &list) { - KDialogBase dialog(w->tqtopLevelWidget(), "stringlist_dialog", true, i18n("Edit List of Items"), + KDialogBase dialog(w->topLevelWidget(), "stringlist_dialog", true, i18n("Edit List of Items"), KDialogBase::Ok|KDialogBase::Cancel, KDialogBase::Ok, false); KEditListBox *edit = new KEditListBox(i18n("Contents of %1").tqarg(w->name()), &dialog, "editlist"); @@ -345,7 +345,7 @@ WidgetFactory::editRichText(TQWidget *w, TQString &text) void WidgetFactory::editListView(TQListView *listview) { - EditListViewDialog dlg(((TQWidget*)listview)->tqtopLevelWidget()); + EditListViewDialog dlg(((TQWidget*)listview)->topLevelWidget()); //dlg.exec(listview); } @@ -376,7 +376,7 @@ WidgetFactory::eventFilter(TQObject *obj, TQEvent *ev) if(obj != (TQObject *)w) return false; - TQWidget *focus = w->tqtopLevelWidget()->tqfocusWidget(); + TQWidget *focus = w->topLevelWidget()->focusWidget(); if(focus && w != focus && !w->child(focus->name(), focus->className())) resetEditor(); } diff --git a/kexi/formeditor/widgetlibrary.cpp b/kexi/formeditor/widgetlibrary.cpp index c9f9bd9b..9a680db5 100644 --- a/kexi/formeditor/widgetlibrary.cpp +++ b/kexi/formeditor/widgetlibrary.cpp @@ -81,8 +81,8 @@ class WidgetLibraryPrivate advancedProperties.insert("backgroundMode", (char*)1);//this is rather useless advancedProperties.insert("tqlayout", (char*)1);// too large risk to break things // by providing this in propeditor - advancedProperties.insert("tqminimumSize", (char*)1); - advancedProperties.insert("tqmaximumSize", (char*)1); + advancedProperties.insert("minimumSize", (char*)1); + advancedProperties.insert("maximumSize", (char*)1); #ifdef KEXI_NO_UNFINISHED /*! @todo reenable */ advancedProperties.insert("paletteBackgroundPixmap", (char*)1); @@ -532,7 +532,7 @@ WidgetLibrary::iconName(const TQCString &classname) if(wi) return wi->pixmap(); - return TQString::tqfromLatin1("unknown_widget"); + return TQString::fromLatin1("unknown_widget"); } bool diff --git a/kexi/formeditor/widgetpropertyset.cpp b/kexi/formeditor/widgetpropertyset.cpp index d06a5c2e..5ed8f96d 100644 --- a/kexi/formeditor/widgetpropertyset.cpp +++ b/kexi/formeditor/widgetpropertyset.cpp @@ -287,7 +287,7 @@ WidgetPropertySet::createPropertiesForWidget(TQWidget *w) return; } - TQStrList pList = w->tqmetaObject()->propertyNames(true); + TQStrList pList = w->metaObject()->propertyNames(true); TQStrListIterator it(pList); // add subproperties if available @@ -309,7 +309,7 @@ WidgetPropertySet::createPropertiesForWidget(TQWidget *w) const TQMetaProperty *subMeta = // special case - subproperty subpropIface ? subpropIface->findMetaSubproperty(it.current()) : 0; const TQMetaProperty *meta = subMeta ? subMeta - : w->tqmetaObject()->property( w->tqmetaObject()->findProperty(*it, true), true); + : w->metaObject()->property( w->metaObject()->findProperty(*it, true), true); if (!meta) continue; const char* propertyName = meta->name(); @@ -393,7 +393,7 @@ WidgetPropertySet::createPropertiesForWidget(TQWidget *w) /*! let's forget it for now, until we have new complete events editor if (m_manager->lib()->advancedPropertiesVisible()) { // add the signals property - TQStrList strlist = w->tqmetaObject()->signalNames(true); + TQStrList strlist = w->metaObject()->signalNames(true); TQStrListIterator strIt(strlist); TQStringList list; for(; strIt.current() != 0; ++strIt) @@ -621,7 +621,7 @@ WidgetPropertySet::createPropertyCommandsInDesignMode(TQWidget* widget, else { WidgetWithSubpropertiesInterface* subpropIface = dynamic_cast<WidgetWithSubpropertiesInterface*>(widget); TQWidget *subwidget = (subpropIface && subpropIface->subwidget()) ? subpropIface->subwidget() : widget; - if (-1 != subwidget->tqmetaObject()->findProperty(it.key(), true) && subwidget->property(it.key())!=it.data()) { + if (-1 != subwidget->metaObject()->findProperty(it.key(), true) && subwidget->property(it.key())!=it.data()) { ObjectTreeItem *tree = KFormDesigner::FormManager::self()->activeForm()->objectTree()->lookup(widget->name()); if (tree) tree->addModifiedProperty(it.key(), subwidget->property(it.key())); @@ -865,8 +865,8 @@ WidgetPropertySet::saveAlignProperty(const TQString &property) WidgetWithSubpropertiesInterface* subpropIface = dynamic_cast<WidgetWithSubpropertiesInterface*>( (TQWidget*)d->widgets.first() ); TQWidget *subwidget = (subpropIface && subpropIface->subwidget()) ? subpropIface->subwidget() : (TQWidget*)d->widgets.first(); - int count = subwidget->tqmetaObject()->findProperty("tqalignment", true); - const TQMetaProperty *meta = subwidget->tqmetaObject()->property(count, true); + int count = subwidget->metaObject()->findProperty("tqalignment", true); + const TQMetaProperty *meta = subwidget->metaObject()->property(count, true); subwidget->setProperty("tqalignment", meta->keysToValue(list)); ObjectTreeItem *tree = KFormDesigner::FormManager::self()->activeForm()->objectTree()->lookup( @@ -1000,8 +1000,8 @@ WidgetPropertySet::initPropertiesDescription() d->propCaption["enabled"] = i18n("Enabled"); d->propCaption["geometry"] = i18n("Geometry"); d->propCaption["sizePolicy"] = i18n("Size Policy"); - d->propCaption["tqminimumSize"] = i18n("Minimum Size"); - d->propCaption["tqmaximumSize"] = i18n("Maximum Size"); + d->propCaption["minimumSize"] = i18n("Minimum Size"); + d->propCaption["maximumSize"] = i18n("Maximum Size"); d->propCaption["font"] = i18n("Font"); d->propCaption["cursor"] = i18n("Cursor"); d->propCaption["paletteForegroundColor"] = i18n("Foreground Color"); diff --git a/kexi/formeditor/widgetwithsubpropertiesinterface.cpp b/kexi/formeditor/widgetwithsubpropertiesinterface.cpp index aa84f831..362214a1 100644 --- a/kexi/formeditor/widgetwithsubpropertiesinterface.cpp +++ b/kexi/formeditor/widgetwithsubpropertiesinterface.cpp @@ -41,11 +41,11 @@ void WidgetWithSubpropertiesInterface::setSubwidget(TQWidget *widget) TQAsciiDict<char> addedSubproperies(1024); if (m_subwidget) { //remember properties in the subwidget that are not present in the parent - for( TQMetaObject *tqmetaObject = m_subwidget->tqmetaObject(); tqmetaObject; tqmetaObject = tqmetaObject->tqsuperClass()) { - const int numProperties = tqmetaObject->numProperties(); + for( TQMetaObject *metaObject = m_subwidget->metaObject(); metaObject; metaObject = metaObject->superClass()) { + const int numProperties = metaObject->numProperties(); for (int i = 0; i < numProperties; i++) { - const char *propertyName = tqmetaObject->property( i )->name(); - if (dynamic_cast<TQObject*>(this)->tqmetaObject()->findProperty( propertyName, true )==-1 + const char *propertyName = metaObject->property( i )->name(); + if (dynamic_cast<TQObject*>(this)->metaObject()->findProperty( propertyName, true )==-1 && !addedSubproperies.find( propertyName ) ) { m_subproperies.append( propertyName ); @@ -73,10 +73,10 @@ const TQMetaProperty *WidgetWithSubpropertiesInterface::findMetaSubproperty(cons if (!m_subwidget || m_subproperies.find(name) == m_subproperies.constEnd()) { return 0; } - const int index = m_subwidget->tqmetaObject()->findProperty( name, true ); + const int index = m_subwidget->metaObject()->findProperty( name, true ); if (index==-1) return 0; - return m_subwidget->tqmetaObject()->property( index, true ); + return m_subwidget->metaObject()->property( index, true ); } TQVariant WidgetWithSubpropertiesInterface::subproperty( const char * name, bool &ok ) const |