|
|
|
@ -60,8 +60,8 @@ KWMailMergeDataBase::KWMailMergeDataBase( KWDocument *doc_ )
|
|
|
|
|
TQStringList KWMailMergeDataBase::availablePlugins()
|
|
|
|
|
{
|
|
|
|
|
TQStringList tmp;
|
|
|
|
|
KTrader::OfferList pluginOffers=KTrader::self()->query(TQString::fromLatin1("KWord/MailMergePlugin"),TQString());
|
|
|
|
|
for (KTrader::OfferList::Iterator it=pluginOffers.begin();*it;++it)
|
|
|
|
|
TDETrader::OfferList pluginOffers=TDETrader::self()->query(TQString::fromLatin1("KWord/MailMergePlugin"),TQString());
|
|
|
|
|
for (TDETrader::OfferList::Iterator it=pluginOffers.begin();*it;++it)
|
|
|
|
|
{
|
|
|
|
|
tmp.append((*it)->property("X-TDE-InternalName").toString());
|
|
|
|
|
kdDebug()<<"Found mail merge plugin: "<< (*it)->name()<<endl;
|
|
|
|
@ -79,7 +79,7 @@ bool KWMailMergeDataBase::loadPlugin(const TQString &name,const TQString &comman
|
|
|
|
|
if (rejectdcopcall)return false;
|
|
|
|
|
TQString constrain=TQString("[X-TDE-InternalName] =='"+name+"'");
|
|
|
|
|
kdDebug()<<constrain<<endl;
|
|
|
|
|
KTrader::OfferList pluginOffers=KTrader::self()->query(TQString::fromLatin1("KWord/MailMergePlugin"),constrain);
|
|
|
|
|
TDETrader::OfferList pluginOffers=TDETrader::self()->query(TQString::fromLatin1("KWord/MailMergePlugin"),constrain);
|
|
|
|
|
KService::Ptr it=pluginOffers.first();
|
|
|
|
|
|
|
|
|
|
TQVariant verProp=it->property("X-TDE-PluginVersion");
|
|
|
|
@ -118,10 +118,10 @@ KWMailMergeDataSource *KWMailMergeDataBase::openPluginFor(int type,int &version)
|
|
|
|
|
KWMailMergeDataSource *ret=0;
|
|
|
|
|
TQString constrain=TQString("'%1' in [X-TDE-Capabilities]").arg(((type==KWSLCreate)?KWSLCreate_text:KWSLOpen_text));
|
|
|
|
|
kdDebug()<<constrain<<endl;
|
|
|
|
|
KTrader::OfferList pluginOffers=KTrader::self()->query(TQString::fromLatin1("KWord/MailMergePlugin"),constrain);
|
|
|
|
|
TDETrader::OfferList pluginOffers=TDETrader::self()->query(TQString::fromLatin1("KWord/MailMergePlugin"),constrain);
|
|
|
|
|
|
|
|
|
|
//Only for debugging
|
|
|
|
|
for (KTrader::OfferList::Iterator it=pluginOffers.begin();*it;++it)
|
|
|
|
|
for (TDETrader::OfferList::Iterator it=pluginOffers.begin();*it;++it)
|
|
|
|
|
{
|
|
|
|
|
kdDebug()<<"Found mail merge plugin: "<< (*it)->name()<<endl;
|
|
|
|
|
}
|
|
|
|
@ -324,7 +324,7 @@ int KWMailMergeDataBase::version() {
|
|
|
|
|
*
|
|
|
|
|
******************************************************************/
|
|
|
|
|
|
|
|
|
|
KWMailMergeChoosePluginDialog::KWMailMergeChoosePluginDialog( KTrader::OfferList offers )
|
|
|
|
|
KWMailMergeChoosePluginDialog::KWMailMergeChoosePluginDialog( TDETrader::OfferList offers )
|
|
|
|
|
: KDialogBase( Plain, i18n( "Mail Merge Setup" ), Ok | Cancel, Ok,
|
|
|
|
|
/*parent*/ 0, "", true ), pluginOffers( offers )
|
|
|
|
|
{
|
|
|
|
@ -341,7 +341,7 @@ KWMailMergeChoosePluginDialog::KWMailMergeChoosePluginDialog( KTrader::OfferList
|
|
|
|
|
descriptionLabel->setFrameShadow( TQFrame::Sunken );
|
|
|
|
|
|
|
|
|
|
TQSize old_sizeHint;
|
|
|
|
|
for ( KTrader::OfferList::Iterator it = pluginOffers.begin(); *it; ++it )
|
|
|
|
|
for ( TDETrader::OfferList::Iterator it = pluginOffers.begin(); *it; ++it )
|
|
|
|
|
{
|
|
|
|
|
chooser->insertItem( (*it)->name() );
|
|
|
|
|
old_sizeHint = descriptionLabel->sizeHint();
|
|
|
|
|