From 3ed629ae12e33ac8a9c744e79135a4100d16b036 Mon Sep 17 00:00:00 2001 From: Timothy Pearson Date: Fri, 16 Dec 2011 09:58:03 -0600 Subject: Revert "Rename a number of old tq methods that are no longer tq specific" This reverts commit 650c190e4a29a2a17fd46b32ce78b956b9816215. --- kipi-plugins/cdarchiving/cdarchiving.cpp | 70 ++++++++++++------------- kipi-plugins/cdarchiving/cdarchivingdialog.cpp | 26 ++++----- kipi-plugins/cdarchiving/plugin_cdarchiving.cpp | 14 ++--- 3 files changed, 55 insertions(+), 55 deletions(-) (limited to 'kipi-plugins/cdarchiving') diff --git a/kipi-plugins/cdarchiving/cdarchiving.cpp b/kipi-plugins/cdarchiving/cdarchiving.cpp index 0a17245..6019187 100644 --- a/kipi-plugins/cdarchiving/cdarchiving.cpp +++ b/kipi-plugins/cdarchiving/cdarchiving.cpp @@ -36,8 +36,8 @@ extern "C" #include #include #include -#include -#include +#include +#include #include // Include files for KDE @@ -464,7 +464,7 @@ void CDArchiving::slotK3bDone(KProcess*) d->action = KIPICDArchivingPlugin::Error; d->starting = false; d->success = false; - d->message = i18n("Cannot remove temporary folder '%1'.").arg(m_tmpFolder); + d->message = i18n("Cannot remove temporary folder '%1'.").tqarg(m_tmpFolder); TQApplication::sendEvent(m_parent, new TQCustomEvent(TQEvent::User, d)); usleep(1000); } @@ -494,7 +494,7 @@ bool CDArchiving::buildHTMLInterface (void) d->action = KIPICDArchivingPlugin::Error; d->starting = false; d->success = false; - d->message = i18n("Cannot remove folder '%1'.").arg(MainTPath); + d->message = i18n("Cannot remove folder '%1'.").tqarg(MainTPath); TQApplication::sendEvent(m_parent, new TQCustomEvent(TQEvent::User, d)); usleep(1000); return false; @@ -507,7 +507,7 @@ bool CDArchiving::buildHTMLInterface (void) d->action = KIPICDArchivingPlugin::Error; d->starting = false; d->success = false; - d->message = i18n("Could not create folder '%1'.").arg(MainTPath); + d->message = i18n("Could not create folder '%1'.").tqarg(MainTPath); TQApplication::sendEvent(m_parent, new TQCustomEvent(TQEvent::User, d)); usleep(1000); return false; @@ -528,7 +528,7 @@ bool CDArchiving::buildHTMLInterface (void) dir = KGlobal::dirs()->findResourceDir("kipi_data", "up.png"); dir = dir + "up.png"; srcURL = dir; - destURL = MainTPath + TQString::fromLatin1("/up.png"); + destURL = MainTPath + TQString::tqfromLatin1("/up.png"); KIO::file_copy(srcURL, destURL, -1, true, false, false); //clear the temporary list for unique names @@ -556,7 +556,7 @@ bool CDArchiving::buildHTMLInterface (void) d->action = KIPICDArchivingPlugin::Error; d->starting = false; d->success = false; - d->message = i18n("Could not create folder '%1'.").arg(SubTPath); + d->message = i18n("Could not create folder '%1'.").tqarg(SubTPath); TQApplication::sendEvent(m_parent, new TQCustomEvent(TQEvent::User, d)); usleep(1000); return false; @@ -586,7 +586,7 @@ bool CDArchiving::buildHTMLInterface (void) d->action = KIPICDArchivingPlugin::Error; d->starting = false; d->success = false; - d->message = i18n("Cannot remove folder '%1'.").arg(MainTPath); + d->message = i18n("Cannot remove folder '%1'.").tqarg(MainTPath); TQApplication::sendEvent(m_parent, new TQCustomEvent(TQEvent::User, d)); usleep(1000); return false; @@ -623,7 +623,7 @@ bool CDArchiving::buildHTMLInterface (void) d->action = KIPICDArchivingPlugin::Error; d->starting = false; d->success = false; - d->message = i18n("Could not open file '%1'.").arg(MainUrl.path(+1)); + d->message = i18n("Could not open file '%1'.").tqarg(MainUrl.path(+1)); TQApplication::sendEvent(m_parent, new TQCustomEvent(TQEvent::User, d)); usleep(1000); return false; @@ -649,7 +649,7 @@ bool CDArchiving::createDirectory(TQDir thumb_dir, TQString imgGalleryDir, TQStr d->starting = false; d->success = false; d->message = i18n("Could not create folder '%1' in '%2'.") - .arg(dirName).arg(imgGalleryDir); + .tqarg(dirName).tqarg(imgGalleryDir); TQApplication::sendEvent(m_parent, new TQCustomEvent(TQEvent::User, d)); usleep(1000); return false; @@ -678,7 +678,7 @@ void CDArchiving::createHead(TQTextStream& stream) stream << "" << endl; stream << "" << endl; - stream << "formatDate(TQDate::currentDate()) + stream << "formatDate(TQDate::tqcurrentDate()) + "\">" << endl; stream << "" << m_mainTitle << "" << endl; createCSSSection(stream); @@ -736,7 +736,7 @@ void CDArchiving::createBody(TQTextStream& stream, int numOfImages = images.count(); const TQString imgGalleryDir = targetURL.directory(); - const TQString today(KGlobal::locale()->formatDate(TQDate::currentDate())); + const TQString today(KGlobal::locale()->formatDate(TQDate::tqcurrentDate())); stream << "\n" << endl; @@ -952,7 +952,7 @@ void CDArchiving::createBody(TQTextStream& stream, dir = dir + "valid-html401.png"; KURL srcURL(dir); - KURL destURL(imgGalleryDir + TQString::fromLatin1("/thumbs/valid-html401.png")); + KURL destURL(imgGalleryDir + TQString::tqfromLatin1("/thumbs/valid-html401.png")); KIO::file_copy(srcURL, destURL, -1, true, false, false); stream << "

" << endl; @@ -961,7 +961,7 @@ void CDArchiving::createBody(TQTextStream& stream, << "\" height=\"31\" width=\"88\" title=\"" << Temp << "\" />" << endl; Temp = i18n("Album archive created with " - "%2 on %3").arg(m_hostURL).arg(m_hostName).arg(today); + "%2 on %3").tqarg(m_hostURL).tqarg(m_hostName).tqarg(today); stream << Temp << endl; stream << "

" << endl; @@ -974,7 +974,7 @@ void CDArchiving::createBody(TQTextStream& stream, void CDArchiving::createBodyMainPage(TQTextStream& stream, KURL& url) { TQString Temp; - const TQString today(KGlobal::locale()->formatDate(TQDate::currentDate())); + const TQString today(KGlobal::locale()->formatDate(TQDate::tqcurrentDate())); Temp = m_mainTitle; stream << "\n

" << Temp << "

\n" << endl; @@ -992,7 +992,7 @@ void CDArchiving::createBodyMainPage(TQTextStream& stream, KURL& url) dir = dir + "valid-html401.png"; KURL srcURL(dir); - KURL destURL(url.directory() + TQString::fromLatin1("/valid-html401.png")); + KURL destURL(url.directory() + TQString::tqfromLatin1("/valid-html401.png")); KIO::file_copy(srcURL, destURL, -1, true, false, false); stream << "

" << endl; @@ -1001,7 +1001,7 @@ void CDArchiving::createBodyMainPage(TQTextStream& stream, KURL& url) << Temp << "\" />" << endl; Temp = i18n("Album archive created with " - "%2 on %3").arg(m_hostURL).arg(m_hostName).arg(today); + "%2 on %3").tqarg(m_hostURL).tqarg(m_hostName).tqarg(today); stream << Temp << endl; stream << "

" << endl; stream << "\n\n" << endl; @@ -1023,12 +1023,12 @@ bool CDArchiving::createHtml( const KIPI::ImageCollection& album, // Create the "thumbs" subdirectory - TQDir thumb_dir( imgGalleryDir + TQString::fromLatin1("/thumbs/")); + TQDir thumb_dir( imgGalleryDir + TQString::tqfromLatin1("/thumbs/")); if (createDirectory(thumb_dir, imgGalleryDir, "thumbs") == false) return false; - TQDir pages_dir( imgGalleryDir + TQString::fromLatin1("/pages/")); + TQDir pages_dir( imgGalleryDir + TQString::tqfromLatin1("/pages/")); if (createDirectory(pages_dir, imgGalleryDir, "pages") == false) return false; @@ -1053,7 +1053,7 @@ bool CDArchiving::createHtml( const KIPI::ImageCollection& album, d->action = KIPICDArchivingPlugin::Error; d->starting = false; d->success = false; - d->message = i18n("Could not open file '%1'.").arg(targetURL.path(+1)); + d->message = i18n("Could not open file '%1'.").tqarg(targetURL.path(+1)); TQApplication::sendEvent(m_parent, new TQCustomEvent(TQEvent::User, d)); usleep(1000); return false; @@ -1073,8 +1073,8 @@ bool CDArchiving::createPage(const TQString& imgGalleryDir, const TQString& comment) { - const TQDir pagesDir(imgGalleryDir + TQString::fromLatin1("/pages/")); - const TQDir thumbsDir(imgGalleryDir + TQString::fromLatin1("/thumbs/")); + const TQDir pagesDir(imgGalleryDir + TQString::tqfromLatin1("/pages/")); + const TQDir thumbsDir(imgGalleryDir + TQString::tqfromLatin1("/thumbs/")); const TQFileInfo fi (imgURL.fileName()); const TQString imgName = uniqueImgName + "." + fi.extension(FALSE); kdDebug( 51000 ) << "CreatePage: FileName: " << imgURL.fileName() << endl; @@ -1086,21 +1086,21 @@ bool CDArchiving::createPage(const TQString& imgGalleryDir, // Html pages filenames const TQString pageFilename = pagesDir.path() + - TQString::fromLatin1("/") + + TQString::tqfromLatin1("/") + webifyFileName(uniqueImgName)+ - TQString::fromLatin1(".htm"); + TQString::tqfromLatin1(".htm"); const TQString nextPageFilename = webifyFileName(nextUniqueImgName) + - TQString::fromLatin1(".htm"); + TQString::tqfromLatin1(".htm"); const TQString prevPageFilename = webifyFileName(prevUniqueImgName) + - TQString::fromLatin1(".htm"); + TQString::tqfromLatin1(".htm"); // Thumbs filenames - const TQString prevThumb = TQString::fromLatin1("../thumbs/") + + const TQString prevThumb = TQString::tqfromLatin1("../thumbs/") + webifyFileName(prevUniqueImgName) + extension(m_imageFormat); - const TQString nextThumb = TQString::fromLatin1("../thumbs/") + + const TQString nextThumb = TQString::tqfromLatin1("../thumbs/") + webifyFileName(nextUniqueImgName) + extension(m_imageFormat); @@ -1122,7 +1122,7 @@ bool CDArchiving::createPage(const TQString& imgGalleryDir, << m_hostName << " [" << m_hostURL << "]\">" << endl; stream << "formatDate(TQDate::currentDate()) + << KGlobal::locale()->formatDate(TQDate::tqcurrentDate()) << "\">" << endl; stream << "" << m_mainTitle << " : "<< imgName/*imgURL.fileName()*/ <<"" << endl; @@ -1239,13 +1239,13 @@ bool CDArchiving::createPage(const TQString& imgGalleryDir, // Footer TQString valid = i18n("Valid HTML 4.01."); - const TQString today(KGlobal::locale()->formatDate(TQDate::currentDate())); + const TQString today(KGlobal::locale()->formatDate(TQDate::tqcurrentDate())); stream << "

\""" << endl; valid = i18n("Image gallery created with " - "%2 on %3").arg(m_hostURL).arg(m_hostName).arg(today); + "%2 on %3").tqarg(m_hostURL).tqarg(m_hostName).tqarg(today); stream << valid << "
" << endl; @@ -1270,7 +1270,7 @@ int CDArchiving::createThumb( const TQString& imgName, const TQString& sourceDir // Create the thumbnails for the HTML interface. const TQString ImageNameFormat = webifyFileName(uniqueFileName) + extension(imageFormat); - const TQString thumbDir = imgGalleryDir + TQString::fromLatin1("/thumbs/"); + const TQString thumbDir = imgGalleryDir + TQString::tqfromLatin1("/thumbs/"); int extent = m_thumbnailsSize; m_imgWidth = 120; // Setting the size of the images is @@ -1580,7 +1580,7 @@ bool CDArchiving::BuildK3bXMLprojectfile (TQString HTMLinterfaceFolder, TQString d->action = KIPICDArchivingPlugin::Progress; d->starting = true; d->success = false; - d->message = i18n("Adding Album '%1' into project...").arg( (*it).name() ); + d->message = i18n("Adding Album '%1' into project...").tqarg( (*it).name() ); TQApplication::sendEvent(m_parent, new TQCustomEvent(TQEvent::User, d)); usleep(1000); addCollectionToK3bXMLProjectFile( *it, &stream); @@ -1847,7 +1847,7 @@ TQString CDArchiving::EscapeSgmlText(const TQTextCodec* codec, for (uint i = 0 ; i < strIn.length() ; ++i) { ch=strIn[i]; - switch (ch.unicode()) + switch (ch.tqunicode()) { case 38: // & { @@ -1889,7 +1889,7 @@ TQString CDArchiving::EscapeSgmlText(const TQTextCodec* codec, { if (!codec->canEncode(ch)) { - strReturn += TQString("&#%1;").arg(ch.unicode()); + strReturn += TQString("&#%1;").tqarg(ch.tqunicode()); break; } } diff --git a/kipi-plugins/cdarchiving/cdarchivingdialog.cpp b/kipi-plugins/cdarchiving/cdarchivingdialog.cpp index 4e9f435..5121432 100644 --- a/kipi-plugins/cdarchiving/cdarchivingdialog.cpp +++ b/kipi-plugins/cdarchiving/cdarchivingdialog.cpp @@ -33,7 +33,7 @@ #include #include #include -#include +#include #include #include #include @@ -140,21 +140,21 @@ void CDArchivingDialog::setupSelection(void) page_setupSelection = addPage(i18n("Selection"), i18n("Album Selection"), BarIcon("folder_image", KIcon::SizeMedium)); - TQVBoxLayout *layout = new TQVBoxLayout(page_setupSelection, 0, spacingHint() ); + TQVBoxLayout *tqlayout = new TQVBoxLayout(page_setupSelection, 0, spacingHint() ); m_imageCollectionSelector = new KIPI::ImageCollectionSelector(page_setupSelection, m_interface); - layout->addWidget(m_imageCollectionSelector); + tqlayout->addWidget(m_imageCollectionSelector); //--------------------------------------------- TQGroupBox * groupBox3 = new TQGroupBox( 2, Qt::Horizontal, i18n("Target Media Information"), page_setupSelection ); - groupBox3->layout()->setSpacing( 6 ); - groupBox3->layout()->setMargin( 11 ); + groupBox3->tqlayout()->setSpacing( 6 ); + groupBox3->tqlayout()->setMargin( 11 ); TQWhatsThis::add( groupBox3, i18n("

Information about the backup medium.") ); m_mediaSize = new TQLabel( groupBox3 ); - m_mediaSize->setAlignment( int( TQLabel::WordBreak | TQLabel::AlignVCenter ) ); + m_mediaSize->tqsetAlignment( int( TQLabel::WordBreak | TQLabel::AlignVCenter ) ); m_mediaFormat = new TQComboBox(false, groupBox3); m_mediaFormat->insertItem(i18n("CD (650Mb)")); @@ -165,7 +165,7 @@ void CDArchivingDialog::setupSelection(void) mediaFormatActived(m_mediaFormat->currentText()); TQWhatsThis::add( m_mediaFormat, i18n("

Select here the backup media format.")); - layout->addWidget( groupBox3 ); + tqlayout->addWidget( groupBox3 ); //--------------------------------------------- @@ -539,11 +539,11 @@ void CDArchivingDialog::setupBurning(void) TQGroupBox * groupBoxAdvancedOptions = new TQGroupBox( i18n("Advanced Burning Options"), page_burning ); groupBoxAdvancedOptions->setColumnLayout(0, Qt::Vertical ); - groupBoxAdvancedOptions->layout()->setSpacing( 6 ); - groupBoxAdvancedOptions->layout()->setMargin( 11 ); + groupBoxAdvancedOptions->tqlayout()->setSpacing( 6 ); + groupBoxAdvancedOptions->tqlayout()->setMargin( 11 ); - TQVBoxLayout * groupBoxAOLayout = new TQVBoxLayout( groupBoxAdvancedOptions->layout() ); - groupBoxAOLayout->setAlignment( TQt::AlignTop ); + TQVBoxLayout * groupBoxAOLayout = new TQVBoxLayout( groupBoxAdvancedOptions->tqlayout() ); + groupBoxAOLayout->tqsetAlignment( TQt::AlignTop ); m_burnOnTheFly = new TQCheckBox( i18n("Media burning On-The-Fly"), groupBoxAdvancedOptions); m_burnOnTheFly->setChecked( false ); @@ -621,8 +621,8 @@ void CDArchivingDialog::ShowMediaCapacity(void) Color = ""; m_mediaSize->setText( i18n("Total size: ") + Color + - i18n("%1 / %2").arg(KIO::convertSizeFromKB(TargetMediaSize)) - .arg(KIO::convertSizeFromKB (MaxMediaSize)) ); + i18n("%1 / %2").tqarg(KIO::convertSizeFromKB(TargetMediaSize)) + .tqarg(KIO::convertSizeFromKB (MaxMediaSize)) ); } void CDArchivingDialog::slotOk() diff --git a/kipi-plugins/cdarchiving/plugin_cdarchiving.cpp b/kipi-plugins/cdarchiving/plugin_cdarchiving.cpp index 5d70cc9..0bab4a2 100644 --- a/kipi-plugins/cdarchiving/plugin_cdarchiving.cpp +++ b/kipi-plugins/cdarchiving/plugin_cdarchiving.cpp @@ -157,7 +157,7 @@ void Plugin_CDArchiving::customEvent(TQCustomEvent *event) case(KIPICDArchivingPlugin::BuildAlbumHTMLPage): { - text = i18n("Making HTML pages for Album '%1'...").arg(d->albumName); + text = i18n("Making HTML pages for Album '%1'...").tqarg(d->albumName); break; } @@ -169,7 +169,7 @@ void Plugin_CDArchiving::customEvent(TQCustomEvent *event) case(KIPICDArchivingPlugin::ResizeImages): { - text = i18n("Creating thumbnail for '%1'...").arg(d->fileName); + text = i18n("Creating thumbnail for '%1'...").tqarg(d->fileName); break; } @@ -211,14 +211,14 @@ void Plugin_CDArchiving::customEvent(TQCustomEvent *event) case(KIPICDArchivingPlugin::BuildAlbumHTMLPage): { ++m_current; - text = i18n("HTML page creation for Album '%1' completed.").arg(d->albumName); + text = i18n("HTML page creation for Album '%1' completed.").tqarg(d->albumName); break; } case(KIPICDArchivingPlugin::ResizeImages): { ++m_current; - text = i18n("Creating thumbnail for '%1' done.").arg(d->fileName); + text = i18n("Creating thumbnail for '%1' done.").tqarg(d->fileName); break; } @@ -250,7 +250,7 @@ void Plugin_CDArchiving::customEvent(TQCustomEvent *event) { case(KIPICDArchivingPlugin::ResizeImages): { - text = i18n("Failed to create thumbnail for '%1'").arg(d->fileName); + text = i18n("Failed to create thumbnail for '%1'").tqarg(d->fileName); m_progressDlg->addedAction(text, KIPI::WarningMessage); m_progressDlg->setProgress(m_current, m_total); break; @@ -260,7 +260,7 @@ void Plugin_CDArchiving::customEvent(TQCustomEvent *event) { ++m_current; text = i18n("Failed to create HTML interface: %1") - .arg(d->message); + .tqarg(d->message); m_progressDlg->addedAction(text, KIPI::ErrorMessage); m_progressDlg->setProgress(m_current, m_total); slotCancel(); @@ -271,7 +271,7 @@ void Plugin_CDArchiving::customEvent(TQCustomEvent *event) case(KIPICDArchivingPlugin::BuildAlbumHTMLPage): { text = i18n("Failed to create HTML pages for Album '%1'") - .arg(d->albumName); + .tqarg(d->albumName); m_progressDlg->addedAction(text, KIPI::ErrorMessage); m_progressDlg->setProgress(m_current, m_total); slotCancel(); -- cgit v1.2.3