Rename KStandard for enhanced compatibility with KDE4

pull/1/head
Timothy Pearson 12 years ago
parent 44ff5a3c79
commit 31fde11959

@ -46,7 +46,7 @@ TQString KBabel::Defaults::Spellcheck::ignoreURL()
{ {
TQString _ignoreURL; TQString _ignoreURL;
KStandardDirs * dirs = TDEGlobal::dirs(); TDEStandardDirs * dirs = TDEGlobal::dirs();
if(dirs) if(dirs)
{ {
_ignoreURL = dirs->saveLocation("appdata"); _ignoreURL = dirs->saveLocation("appdata");
@ -113,7 +113,7 @@ TQString KBabel::Defaults::CatalogManager::ignoreURL()
{ {
TQString _ignoreURL; TQString _ignoreURL;
KStandardDirs * dirs = TDEGlobal::dirs(); TDEStandardDirs * dirs = TDEGlobal::dirs();
if(dirs) if(dirs)
{ {
_ignoreURL = dirs->saveLocation("appdata"); _ignoreURL = dirs->saveLocation("appdata");

@ -1158,7 +1158,7 @@ KDBSearchEngine::readSettings (TDEConfigBase * config)
lang = config->readEntry ("Language", defaultLang); lang = config->readEntry ("Language", defaultLang);
TQString defaultDir; TQString defaultDir;
KStandardDirs *dirs = TDEGlobal::dirs (); TDEStandardDirs *dirs = TDEGlobal::dirs ();
if (dirs) if (dirs)
{ {
defaultDir = dirs->saveLocation ("data"); defaultDir = dirs->saveLocation ("data");

@ -85,7 +85,7 @@ dbpw->ignoreLE->setText("&.:");
dbpw->autoAddCB_2->setChecked(true); dbpw->autoAddCB_2->setChecked(true);
TQString defaultDir; TQString defaultDir;
KStandardDirs * dirs = TDEGlobal::dirs(); TDEStandardDirs * dirs = TDEGlobal::dirs();
if(dirs) if(dirs)
{ {
defaultDir = dirs->saveLocation("data"); defaultDir = dirs->saveLocation("data");

@ -322,7 +322,7 @@ void KDBSearchEngine2::readSettings(TDEConfigBase *config)
{ {
/*TQString defaultDir; /*TQString defaultDir;
KStandardDirs * dirs = TDEGlobal::dirs(); TDEStandardDirs * dirs = TDEGlobal::dirs();
if(dirs) if(dirs)
{ {
defaultDir = dirs->saveLocation("data"); defaultDir = dirs->saveLocation("data");

@ -53,7 +53,7 @@ emit restoreNow();
void KDB2PreferencesWidget::standard() void KDB2PreferencesWidget::standard()
{ {
TQString defaultDir; TQString defaultDir;
KStandardDirs * dirs = TDEGlobal::dirs(); TDEStandardDirs * dirs = TDEGlobal::dirs();
if(dirs) if(dirs)
{ {
defaultDir = dirs->saveLocation("data"); defaultDir = dirs->saveLocation("data");

@ -53,11 +53,11 @@ bool MailSender::send(const TQString &fromName,const TQString &fromEmail,const T
bool needHeaders = true; bool needHeaders = true;
TQString command = KStandardDirs::findExe(TQString::fromLatin1("sendmail"), TQString command = TDEStandardDirs::findExe(TQString::fromLatin1("sendmail"),
TQString::fromLatin1("/sbin:/usr/sbin:/usr/lib")); TQString::fromLatin1("/sbin:/usr/sbin:/usr/lib"));
if (!command.isNull()) command += TQString::fromLatin1(" -oi -t"); if (!command.isNull()) command += TQString::fromLatin1(" -oi -t");
else { else {
command = KStandardDirs::findExe(TQString::fromLatin1("mail")); command = TDEStandardDirs::findExe(TQString::fromLatin1("mail"));
if (command.isNull()) return false; // give up if (command.isNull()) return false; // give up
command.append(TQString::fromLatin1(" -s ")); command.append(TQString::fromLatin1(" -s "));

@ -48,8 +48,8 @@ $lastdir = '.';
'`TDEGlobal\' undeclared \(first use this function\)' => "kglobal", '`TDEGlobal\' undeclared \(first use this function\)' => "kglobal",
'implicit declaration of function `int locate\(\.\.\.\)' => "kstddirs", 'implicit declaration of function `int locate\(\.\.\.\)' => "kstddirs",
'`locate\' undeclared \(first use this function\)' => "kstddirs", '`locate\' undeclared \(first use this function\)' => "kstddirs",
'no matching function for call to `KStandardDirs' => "kstddirs", 'no matching function for call to `TDEStandardDirs' => "kstddirs",
'no method `KStandardDirs::' => "kstddirs", 'no method `TDEStandardDirs::' => "kstddirs",
'variable `class QFile \S*\' has initializer but incomplete type' => "qfile", 'variable `class QFile \S*\' has initializer but incomplete type' => "qfile",
'implicit declaration of function `int ICON\(\.\.\.\)' => "kiconloader", 'implicit declaration of function `int ICON\(\.\.\.\)' => "kiconloader",
'`QMessageBox\' undeclared \(first use this function\)' => "qmessagebox", '`QMessageBox\' undeclared \(first use this function\)' => "qmessagebox",

@ -115,7 +115,7 @@ SvnHelper::SvnHelper():TDEApplication() {
TDEIO::NetAccess::synchronousRun( job, 0 ); TDEIO::NetAccess::synchronousRun( job, 0 );
if ( diffresult.count() > 0 ) { if ( diffresult.count() > 0 ) {
//check kompare is available //check kompare is available
if ( !KStandardDirs::findExe( "kompare" ).isNull() ) { if ( !TDEStandardDirs::findExe( "kompare" ).isNull() ) {
KTempFile *tmp = new KTempFile; KTempFile *tmp = new KTempFile;
tmp->setAutoDelete(true); tmp->setAutoDelete(true);
TQTextStream *stream = tmp->textStream(); TQTextStream *stream = tmp->textStream();

@ -67,7 +67,7 @@ bool AlignToolBar::hasWidgetSmallerY(const UMLWidget* widget1, const UMLWidget*
} }
void AlignToolBar::loadPixmaps() { void AlignToolBar::loadPixmaps() {
KStandardDirs* dirs = TDEGlobal::dirs(); TDEStandardDirs* dirs = TDEGlobal::dirs();
TQString dataDir = dirs->findResourceDir( "data", "umbrello/pics/object.png" ); TQString dataDir = dirs->findResourceDir( "data", "umbrello/pics/object.png" );
dataDir += "/umbrello/pics/"; dataDir += "/umbrello/pics/";

@ -469,7 +469,7 @@ void CodeGenerationPolicy::setDefaults( TDEConfig * config, bool emitUpdateSigna
path = config -> readPathEntry("headingsDirectory"); path = config -> readPathEntry("headingsDirectory");
if(path.isEmpty()) { if(path.isEmpty()) {
KStandardDirs stddirs; TDEStandardDirs stddirs;
path = stddirs.findDirs("data","umbrello/headings").first(); path = stddirs.findDirs("data","umbrello/headings").first();
} }
setHeadingFileDir ( path ); setHeadingFileDir ( path );

@ -21,7 +21,7 @@ KStartupLogo::KStartupLogo(TQWidget * parent, const char *name)
: TQWidget(parent,name, TQt::WStyle_NoBorder | TQt::WStyle_Customize | TQt::WDestructiveClose ) : TQWidget(parent,name, TQt::WStyle_NoBorder | TQt::WStyle_Customize | TQt::WDestructiveClose )
,m_bReadyToHide(false) { ,m_bReadyToHide(false) {
//pm.load(locate("appdata", "pics/startlogo.png")); //pm.load(locate("appdata", "pics/startlogo.png"));
KStandardDirs * dirs = TDEGlobal::dirs(); TDEStandardDirs * dirs = TDEGlobal::dirs();
TQString dataDir = dirs -> findResourceDir("data", "umbrello/pics/object.png"); TQString dataDir = dirs -> findResourceDir("data", "umbrello/pics/object.png");
dataDir += "/umbrello/pics/"; dataDir += "/umbrello/pics/";
TQPixmap pm(dataDir + "startlogo.png"); TQPixmap pm(dataDir + "startlogo.png");

@ -826,7 +826,7 @@ void ListPopupMenu::setupMenu(Menu_Type type, UMLView* view) {
m_pShow = 0; m_pShow = 0;
m_pColor = 0; m_pColor = 0;
KStandardDirs* dirs = TDEGlobal::dirs(); TDEStandardDirs* dirs = TDEGlobal::dirs();
TQString dataDir = dirs->findResourceDir("data", "umbrello/pics/object.png"); TQString dataDir = dirs->findResourceDir("data", "umbrello/pics/object.png");
dataDir += "/umbrello/pics/"; dataDir += "/umbrello/pics/";
m_pixmap[pm_Class] .load(dataDir+"class.png", "PNG"); m_pixmap[pm_Class] .load(dataDir+"class.png", "PNG");

@ -681,7 +681,7 @@ void RefactoringAssistant::movableDropEvent (TQListViewItem* parentItem, TQListV
void RefactoringAssistant::loadPixmaps() void RefactoringAssistant::loadPixmaps()
{ {
KStandardDirs *dirs = TDEGlobal::dirs(); TDEStandardDirs *dirs = TDEGlobal::dirs();
TQString dataDir = dirs -> findResourceDir( "data", "umbrello/pics/object.png" ); TQString dataDir = dirs -> findResourceDir( "data", "umbrello/pics/object.png" );
dataDir += "/umbrello/pics/"; dataDir += "/umbrello/pics/";

@ -1753,7 +1753,7 @@ TQPixmap & UMLListView::getPixmap(Uml::Icon_Type type) {
} }
void UMLListView::loadPixmaps() { void UMLListView::loadPixmaps() {
KStandardDirs * dirs = TDEGlobal::dirs(); TDEStandardDirs * dirs = TDEGlobal::dirs();
TQString dataDir = dirs -> findResourceDir("data", "umbrello/pics/object.png"); TQString dataDir = dirs -> findResourceDir("data", "umbrello/pics/object.png");
dataDir += "/umbrello/pics/"; dataDir += "/umbrello/pics/";

@ -289,7 +289,7 @@ void WorkToolBar::loadPixmaps() {
{ tbb_Initial_Activity, i18n("Initial Activity"), "initial_state.png" }, { tbb_Initial_Activity, i18n("Initial Activity"), "initial_state.png" },
{ tbb_Coll_Message, i18n("Message"), "message-asynchronous.png" } { tbb_Coll_Message, i18n("Message"), "message-asynchronous.png" }
}; };
KStandardDirs * dirs = TDEGlobal::dirs(); TDEStandardDirs * dirs = TDEGlobal::dirs();
TQString dataDir = dirs->findResourceDir( "data", "umbrello/pics/object.png" ); TQString dataDir = dirs->findResourceDir( "data", "umbrello/pics/object.png" );
dataDir += "/umbrello/pics/"; dataDir += "/umbrello/pics/";
const size_t n_buttonInfos = sizeof(buttonInfo) / sizeof(ButtonInfo); const size_t n_buttonInfos = sizeof(buttonInfo) / sizeof(ButtonInfo);

Loading…
Cancel
Save