void KexiDataSourcePage::slotGotoSelected()
{
    const QString partClass(m_formDataSourceCombo->selectedPartClass());
    if (partClass == "org.kexi-project.table" || partClass == "org.kexi-project.query") {
        if (m_formDataSourceCombo->isSelectionValid())
            emit jumpToObjectRequested(partClass, m_formDataSourceCombo->selectedName());
    }
}
void KexiFormPart::setupCustomPropertyPanelTabs(QTabWidget *tab)
{
    if (!d->dataSourcePage) {
        d->dataSourcePage = new KexiDataSourcePage(0);
        d->dataSourcePage->setObjectName("dataSourcePage");
        connect(d->dataSourcePage,
                SIGNAL(jumpToObjectRequested(QString,QString)),
                KexiMainWindowIface::global()->thisWidget(),
                SLOT(highlightObject(QString,QString)));
        connect(d->dataSourcePage,
                SIGNAL(formDataSourceChanged(QString,QString)),
                KexiFormManager::self(),
                SLOT(setFormDataSource(QString,QString)));
        connect(d->dataSourcePage,
                SIGNAL(dataSourceFieldOrExpressionChanged(QString,QString,KDbField::Type)),
                KexiFormManager::self(),
                SLOT(setDataSourceFieldOrExpression(QString,QString,KDbField::Type)));
#ifdef KEXI_AUTOFIELD_FORM_WIDGET_SUPPORT
        connect(d->dataSourcePage,
                SIGNAL(insertAutoFields(QString,QString,QStringList)),
                KexiFormManager::self(),
                SLOT(insertAutoFields(QString,QString,QStringList)));
#endif
    }

    KexiProject *prj = KexiMainWindowIface::global()->project();
    d->dataSourcePage->setProject(prj);

    tab->addTab(d->dataSourcePage, koIcon("server-database"), QString());
    tab->setTabToolTip(tab->indexOf(d->dataSourcePage), xi18n("Data Source"));

    if (!d->widgetTreeWidget) {
        d->widgetTreeWidget = new QWidget;
        QVBoxLayout *lyr = new QVBoxLayout(d->widgetTreeWidget);
        lyr->setContentsMargins(2, 2, 2, 2);
        d->widgetTree = new KFormDesigner::WidgetTreeWidget;
        d->widgetTree->setObjectName("KexiFormPart:WidgetTreeWidget");
        lyr->addWidget(d->widgetTree);
    }
    tab->addTab(d->widgetTreeWidget, koIcon("widgets"), QString());
    tab->setTabToolTip(tab->indexOf(d->widgetTreeWidget), xi18n("Widgets"));
}