Rename KStandard for enhanced compatibility with KDE4

pull/1/head
Timothy Pearson 12 years ago
parent a6421d953b
commit da4097d57f

@ -199,7 +199,7 @@ TDEAboutData* KLinkStatusPart::createAboutData()
about->addCredit("Mathieu Kooiman", 0, " quanta@map-is.nl"); about->addCredit("Mathieu Kooiman", 0, " quanta@map-is.nl");
about->addCredit("Jens Herden", 0, "jens@tdewebdev.org"); about->addCredit("Jens Herden", 0, "jens@tdewebdev.org");
TDEGlobal::dirs()->addResourceType("appicon", KStandardDirs::kde_default("data") + "klinkstatuspart/pics/"); TDEGlobal::dirs()->addResourceType("appicon", TDEStandardDirs::kde_default("data") + "klinkstatuspart/pics/");
return about; return about;
} }

@ -128,7 +128,7 @@ TQString KNewStuffGeneric::downloadDestination( KNS::Entry *entry )
{ {
TQString file = destinationPath(entry); TQString file = destinationPath(entry);
if ( KStandardDirs::exists( file ) ) { if ( TDEStandardDirs::exists( file ) ) {
int result = KMessageBox::warningContinueCancel( parentWidget(), int result = KMessageBox::warningContinueCancel( parentWidget(),
i18n("The file '%1' already exists. Do you want to override it?") i18n("The file '%1' already exists. Do you want to override it?")
.arg( file ), .arg( file ),

@ -39,7 +39,7 @@ HTMLEnhancer::HTMLEnhancer(KafkaDocument *_wkafkapart)
{ {
m_showIconForScripts = true; m_showIconForScripts = true;
m_wkafkapart = _wkafkapart; m_wkafkapart = _wkafkapart;
m_stddirs = new KStandardDirs(); m_stddirs = new TDEStandardDirs();
} }
HTMLEnhancer::~HTMLEnhancer() HTMLEnhancer::~HTMLEnhancer()

@ -25,7 +25,7 @@
class TDEConfig; class TDEConfig;
class Node; class Node;
class KafkaDocument; class KafkaDocument;
class KStandardDirs; class TDEStandardDirs;
/** /**
* This class takes care of the following tasks for [X]HTML DTDs : * This class takes care of the following tasks for [X]HTML DTDs :
@ -99,7 +99,7 @@ private:
KURL m_baseURL; KURL m_baseURL;
bool m_showIconForScripts; bool m_showIconForScripts;
KafkaDocument *m_wkafkapart; KafkaDocument *m_wkafkapart;
KStandardDirs *m_stddirs; TDEStandardDirs *m_stddirs;
}; };
#endif #endif

@ -95,7 +95,7 @@ TQString ab = i18n("Ident all");
mainEnhancer = new HTMLEnhancer(this); mainEnhancer = new HTMLEnhancer(this);
domNodeProps.setAutoDelete(false); domNodeProps.setAutoDelete(false);
KStandardDirs *m_stddirs = new KStandardDirs(); TDEStandardDirs *m_stddirs = new TDEStandardDirs();
TQFile file( m_stddirs->findResource("data", "kafkapart/entities" )/**locate("appdata","chars") */); TQFile file( m_stddirs->findResource("data", "kafkapart/entities" )/**locate("appdata","chars") */);
delete m_stddirs; delete m_stddirs;
TQString tmp; TQString tmp;

@ -101,7 +101,7 @@ bool QuantaPlugin::load()
TQString loc = location(); TQString loc = location();
if(loc.isEmpty()) if(loc.isEmpty())
{ {
KStandardDirs *dirs = QuantaCommon::pluginDirs("lib"); TDEStandardDirs *dirs = QuantaCommon::pluginDirs("lib");
loc = dirs->findResource("lib", fileName()); loc = dirs->findResource("lib", fileName());
delete dirs; delete dirs;
} }
@ -267,7 +267,7 @@ bool QuantaPlugin::validatePluginInfo(const TQString & /*a_name*/,
{ {
if (valid) if (valid)
{ {
KStandardDirs *dirs = QuantaCommon::pluginDirs("lib"); TDEStandardDirs *dirs = QuantaCommon::pluginDirs("lib");
if(dirs->findResource("lib", a_fileName).isNull()) if(dirs->findResource("lib", a_fileName).isNull())
valid = false; valid = false;
delete dirs; delete dirs;

@ -336,7 +336,7 @@ See the operations in order to get a picture what's here." name="QuantaDoc" stat
<UML:Operation stereotype="" package="" xmi.id="347" type=TQSTRING_OBJECT_NAME_STRING abstract="0" documentation="" name="makeRxCompatible" static="0" scope="200" > <UML:Operation stereotype="" package="" xmi.id="347" type=TQSTRING_OBJECT_NAME_STRING abstract="0" documentation="" name="makeRxCompatible" static="0" scope="200" >
<UML:Parameter stereotype="" package="" xmi.id="348" value="" type="const QString" abstract="0" documentation="" name="s" static="0" scope="200" /> <UML:Parameter stereotype="" package="" xmi.id="348" value="" type="const QString" abstract="0" documentation="" name="s" static="0" scope="200" />
</UML:Operation> </UML:Operation>
<UML:Operation stereotype="" package="" xmi.id="349" type="KStandardDirs *" abstract="0" documentation="" name="pluginDirs" static="0" scope="200" > <UML:Operation stereotype="" package="" xmi.id="349" type="TDEStandardDirs *" abstract="0" documentation="" name="pluginDirs" static="0" scope="200" >
<UML:Parameter stereotype="" package="" xmi.id="350" value="" type="const char *" abstract="0" documentation="" name="type" static="0" scope="200" /> <UML:Parameter stereotype="" package="" xmi.id="350" value="" type="const char *" abstract="0" documentation="" name="type" static="0" scope="200" />
</UML:Operation> </UML:Operation>
<UML:Operation stereotype="" package="" xmi.id="351" type=TQSTRING_OBJECT_NAME_STRING abstract="0" documentation="" name="qUrl" static="0" scope="200" > <UML:Operation stereotype="" package="" xmi.id="351" type=TQSTRING_OBJECT_NAME_STRING abstract="0" documentation="" name="qUrl" static="0" scope="200" >

@ -2268,7 +2268,7 @@ void Document::checkDirtyStatus()
{ {
DirtyDlg *dlg = new DirtyDlg(url().path(), m_tempFileName, false, this); DirtyDlg *dlg = new DirtyDlg(url().path(), m_tempFileName, false, this);
DirtyDialog *w = static_cast<DirtyDialog*>(dlg->mainWidget()); DirtyDialog *w = static_cast<DirtyDialog*>(dlg->mainWidget());
TQString kompareStr = KStandardDirs::findExe("kompare"); TQString kompareStr = TDEStandardDirs::findExe("kompare");
if (kompareStr.isEmpty()) if (kompareStr.isEmpty())
{ {
w->buttonCompare->setEnabled(false); w->buttonCompare->setEnabled(false);

@ -1177,7 +1177,7 @@ void QuantaInit::recoverCrashed(TQStringList& recoveredFileNameList)
w->warningLabel = 0L; w->warningLabel = 0L;
w->setMinimumHeight(320); w->setMinimumHeight(320);
dlg->adjustSize(); dlg->adjustSize();
if (KStandardDirs::findExe("kompare").isEmpty() || isUntitledDocument) if (TDEStandardDirs::findExe("kompare").isEmpty() || isUntitledDocument)
{ {
w->buttonCompare->setEnabled(false); w->buttonCompare->setEnabled(false);
w->buttonLoad->setChecked(true); w->buttonLoad->setChecked(true);
@ -1469,7 +1469,7 @@ void QuantaInit::checkRuntimeDependencies()
dependency = *it; dependency = *it;
if (dependency.type == Dependency::Executable) if (dependency.type == Dependency::Executable)
{ {
if (KStandardDirs::findExe(dependency.execName).isNull()) if (TDEStandardDirs::findExe(dependency.execName).isNull())
errorStr += TQString(stdErrorMsg).arg(dependency.name).arg(dependency.url).arg(dependency.description); errorStr += TQString(stdErrorMsg).arg(dependency.name).arg(dependency.url).arg(dependency.description);
} else } else

@ -287,12 +287,12 @@ int eCol){
return pos; return pos;
} }
/** Returns a pointer to a KStandardDirs object usable for plugin searchup. type /** Returns a pointer to a TDEStandardDirs object usable for plugin searchup. type
is the plugin binary type (exe or lib). The returned pointer must be deleted by is the plugin binary type (exe or lib). The returned pointer must be deleted by
the caller!! */ the caller!! */
KStandardDirs* QuantaCommon::pluginDirs(const char *type) TDEStandardDirs* QuantaCommon::pluginDirs(const char *type)
{ {
KStandardDirs *dirs = new KStandardDirs(); TDEStandardDirs *dirs = new TDEStandardDirs();
dirs->addKDEDefaults(); dirs->addKDEDefaults();
for (uint i = 0; i < qConfig.pluginSearchPaths.count(); i++) for (uint i = 0; i < qConfig.pluginSearchPaths.count(); i++)
{ {

@ -31,7 +31,7 @@
class TQString; class TQString;
class DCOPReply; class DCOPReply;
class KURL; class KURL;
class KStandardDirs; class TDEStandardDirs;
class TQWidget; class TQWidget;
class Tag; class Tag;
@ -148,9 +148,9 @@ quotation setting*/
/** Returns 0 if the (line,col) is inside the area specified by the other arguments, /** Returns 0 if the (line,col) is inside the area specified by the other arguments,
-1 if it is before the area and 1 if it is after. */ -1 if it is before the area and 1 if it is after. */
static int isBetween(int line, int col, int bLine, int bCol, int eLine, int eCol); static int isBetween(int line, int col, int bLine, int bCol, int eLine, int eCol);
/** Returns a pointer to a KStandardDirs object usable for plugin searchup. type is the plugin binary type (exe or lib). The returned /** Returns a pointer to a TDEStandardDirs object usable for plugin searchup. type is the plugin binary type (exe or lib). The returned
pointer must be deleted by the caller!! */ pointer must be deleted by the caller!! */
static KStandardDirs* pluginDirs(const char *type); static TDEStandardDirs* pluginDirs(const char *type);
/** Return true, if the url has the mimetype starting with type. */ /** Return true, if the url has the mimetype starting with type. */
static bool checkMimeGroup(const KURL& url, const TQString& type); static bool checkMimeGroup(const KURL& url, const TQString& type);

Loading…
Cancel
Save