|
|
@ -234,11 +234,11 @@ TQString KCardDialog::getCardPath(const TQString &carddir, int index)
|
|
|
|
KCardDialog::init();
|
|
|
|
KCardDialog::init();
|
|
|
|
|
|
|
|
|
|
|
|
TQString entry = carddir + TQString::number(index);
|
|
|
|
TQString entry = carddir + TQString::number(index);
|
|
|
|
if (KStandardDirs::exists(entry + TQString::fromLatin1(".png")))
|
|
|
|
if (TDEStandardDirs::exists(entry + TQString::fromLatin1(".png")))
|
|
|
|
return entry + TQString::fromLatin1(".png");
|
|
|
|
return entry + TQString::fromLatin1(".png");
|
|
|
|
|
|
|
|
|
|
|
|
// rather theoretical
|
|
|
|
// rather theoretical
|
|
|
|
if (KStandardDirs::exists(entry + TQString::fromLatin1(".xpm")))
|
|
|
|
if (TDEStandardDirs::exists(entry + TQString::fromLatin1(".xpm")))
|
|
|
|
return entry + TQString::fromLatin1(".xpm");
|
|
|
|
return entry + TQString::fromLatin1(".xpm");
|
|
|
|
|
|
|
|
|
|
|
|
return TQString();
|
|
|
|
return TQString();
|
|
|
@ -562,11 +562,11 @@ void KCardDialog::slotCardClicked(TQIconViewItem *item)
|
|
|
|
TQString KCardDialog::getDeckName(const TQString &desktop)
|
|
|
|
TQString KCardDialog::getDeckName(const TQString &desktop)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
TQString entry = desktop.left(desktop.length() - strlen(".desktop"));
|
|
|
|
TQString entry = desktop.left(desktop.length() - strlen(".desktop"));
|
|
|
|
if (KStandardDirs::exists(entry + TQString::fromLatin1(".png")))
|
|
|
|
if (TDEStandardDirs::exists(entry + TQString::fromLatin1(".png")))
|
|
|
|
return entry + TQString::fromLatin1(".png");
|
|
|
|
return entry + TQString::fromLatin1(".png");
|
|
|
|
|
|
|
|
|
|
|
|
// rather theoretical
|
|
|
|
// rather theoretical
|
|
|
|
if (KStandardDirs::exists(entry + TQString::fromLatin1(".xpm")))
|
|
|
|
if (TDEStandardDirs::exists(entry + TQString::fromLatin1(".xpm")))
|
|
|
|
return entry + TQString::fromLatin1(".xpm");
|
|
|
|
return entry + TQString::fromLatin1(".xpm");
|
|
|
|
return TQString();
|
|
|
|
return TQString();
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -799,7 +799,7 @@ void KCardDialog::init()
|
|
|
|
static bool _inited = false;
|
|
|
|
static bool _inited = false;
|
|
|
|
if (_inited)
|
|
|
|
if (_inited)
|
|
|
|
return;
|
|
|
|
return;
|
|
|
|
TDEGlobal::dirs()->addResourceType("cards", KStandardDirs::kde_default("data") + TQString::fromLatin1("carddecks/"));
|
|
|
|
TDEGlobal::dirs()->addResourceType("cards", TDEStandardDirs::kde_default("data") + TQString::fromLatin1("carddecks/"));
|
|
|
|
|
|
|
|
|
|
|
|
TDEGlobal::locale()->insertCatalogue("libtdegames");
|
|
|
|
TDEGlobal::locale()->insertCatalogue("libtdegames");
|
|
|
|
_inited = true;
|
|
|
|
_inited = true;
|
|
|
|