summaryrefslogtreecommitdiffstats
path: root/kmail/newfolderdialog.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'kmail/newfolderdialog.cpp')
-rw-r--r--kmail/newfolderdialog.cpp80
1 files changed, 40 insertions, 40 deletions
diff --git a/kmail/newfolderdialog.cpp b/kmail/newfolderdialog.cpp
index 35bb461b..78294e5f 100644
--- a/kmail/newfolderdialog.cpp
+++ b/kmail/newfolderdialog.cpp
@@ -26,15 +26,15 @@
** your version.
*******************************************************************************/
-#include <qvariant.h>
-#include <qpushbutton.h>
-#include <qlabel.h>
-#include <qlineedit.h>
-#include <qcombobox.h>
-#include <qlayout.h>
-#include <qtooltip.h>
-#include <qwhatsthis.h>
-#include <qregexp.h>
+#include <tqvariant.h>
+#include <tqpushbutton.h>
+#include <tqlabel.h>
+#include <tqlineedit.h>
+#include <tqcombobox.h>
+#include <tqlayout.h>
+#include <tqtooltip.h>
+#include <tqwhatsthis.h>
+#include <tqregexp.h>
#include <klocale.h>
#include <kdialogbase.h>
@@ -54,7 +54,7 @@
using namespace KMail;
-NewFolderDialog::NewFolderDialog( QWidget* parent, KMFolder *folder )
+NewFolderDialog::NewFolderDialog( TQWidget* parent, KMFolder *folder )
: KDialogBase( parent, "new_folder_dialog", false, i18n( "New Folder" ),
KDialogBase::Ok|KDialogBase::Cancel,
KDialogBase::Ok, true ),
@@ -64,37 +64,37 @@ NewFolderDialog::NewFolderDialog( QWidget* parent, KMFolder *folder )
if ( mFolder ) {
setCaption( i18n("New Subfolder of %1").arg( mFolder->prettyURL() ) );
}
- QWidget* privateLayoutWidget = new QWidget( this, "mTopLevelLayout" );
- privateLayoutWidget->setGeometry( QRect( 10, 10, 260, 80 ) );
+ TQWidget* privateLayoutWidget = new TQWidget( this, "mTopLevelLayout" );
+ privateLayoutWidget->setGeometry( TQRect( 10, 10, 260, 80 ) );
setMainWidget( privateLayoutWidget );
- mTopLevelLayout = new QVBoxLayout( privateLayoutWidget, 0, spacingHint(),
+ mTopLevelLayout = new TQVBoxLayout( privateLayoutWidget, 0, spacingHint(),
"mTopLevelLayout");
- mNameHBox = new QHBoxLayout( 0, 0, 6, "mNameHBox");
+ mNameHBox = new TQHBoxLayout( 0, 0, 6, "mNameHBox");
- mNameLabel = new QLabel( privateLayoutWidget, "mNameLabel" );
+ mNameLabel = new TQLabel( privateLayoutWidget, "mNameLabel" );
mNameLabel->setText( i18n( "&Name:" ) );
mNameHBox->addWidget( mNameLabel );
- mNameLineEdit = new QLineEdit( privateLayoutWidget, "mNameLineEdit" );
+ mNameLineEdit = new TQLineEdit( privateLayoutWidget, "mNameLineEdit" );
mNameLabel->setBuddy( mNameLineEdit );
- QWhatsThis::add( mNameLineEdit, i18n( "Enter a name for the new folder." ) );
+ TQWhatsThis::add( mNameLineEdit, i18n( "Enter a name for the new folder." ) );
mNameLineEdit->setFocus();
mNameHBox->addWidget( mNameLineEdit );
mTopLevelLayout->addLayout( mNameHBox );
- connect( mNameLineEdit, SIGNAL( textChanged ( const QString & ) ), this, SLOT( slotFolderNameChanged( const QString & ) ) );
+ connect( mNameLineEdit, TQT_SIGNAL( textChanged ( const TQString & ) ), this, TQT_SLOT( slotFolderNameChanged( const TQString & ) ) );
if ( !mFolder ||
( mFolder->folderType() != KMFolderTypeImap &&
mFolder->folderType() != KMFolderTypeCachedImap ) ) {
- mFormatHBox = new QHBoxLayout( 0, 0, 6, "mFormatHBox");
- mMailboxFormatLabel = new QLabel( privateLayoutWidget, "mMailboxFormatLabel" );
+ mFormatHBox = new TQHBoxLayout( 0, 0, 6, "mFormatHBox");
+ mMailboxFormatLabel = new TQLabel( privateLayoutWidget, "mMailboxFormatLabel" );
mMailboxFormatLabel->setText( i18n( "Mailbox &format:" ) );
mFormatHBox->addWidget( mMailboxFormatLabel );
- mFormatComboBox = new QComboBox( false, privateLayoutWidget, "mFormatComboBox" );
+ mFormatComboBox = new TQComboBox( false, privateLayoutWidget, "mFormatComboBox" );
mMailboxFormatLabel->setBuddy( mFormatComboBox );
- QWhatsThis::add( mFormatComboBox, i18n( "Select whether you want to store the messages in this folder as one file per message (maildir) or as one big file (mbox). KMail uses maildir by default and this only needs to be changed in rare circumstances. If you are unsure, leave this option as-is." ) );
+ TQWhatsThis::add( mFormatComboBox, i18n( "Select whether you want to store the messages in this folder as one file per message (maildir) or as one big file (mbox). KMail uses maildir by default and this only needs to be changed in rare circumstances. If you are unsure, leave this option as-is." ) );
mFormatComboBox->insertItem("mbox", 0);
mFormatComboBox->insertItem("maildir", 1);
@@ -113,15 +113,15 @@ NewFolderDialog::NewFolderDialog( QWidget* parent, KMFolder *folder )
// --- contents -----
if ( kmkernel->iCalIface().isEnabled() ) {
- mContentsHBox = new QHBoxLayout( 0, 0, 6, "mContentsHBox");
+ mContentsHBox = new TQHBoxLayout( 0, 0, 6, "mContentsHBox");
- mContentsLabel = new QLabel( privateLayoutWidget, "mContentsLabel" );
+ mContentsLabel = new TQLabel( privateLayoutWidget, "mContentsLabel" );
mContentsLabel->setText( i18n( "Folder &contains:" ) );
mContentsHBox->addWidget( mContentsLabel );
- mContentsComboBox = new QComboBox( false, privateLayoutWidget, "mContentsComboBox" );
+ mContentsComboBox = new TQComboBox( false, privateLayoutWidget, "mContentsComboBox" );
mContentsLabel->setBuddy( mContentsComboBox );
- QWhatsThis::add( mContentsComboBox, i18n( "Select whether you want the new folder to be used for mail storage of for storage of groupware items such as tasks or notes. The default is mail. If you are unsure, leave this option as-is." ) );
+ TQWhatsThis::add( mContentsComboBox, i18n( "Select whether you want the new folder to be used for mail storage of for storage of groupware items such as tasks or notes. The default is mail. If you are unsure, leave this option as-is." ) );
mContentsComboBox->insertItem( i18n( "Mail" ) );
mContentsComboBox->insertItem( i18n( "Calendar" ) );
mContentsComboBox->insertItem( i18n( "Contacts" ) );
@@ -138,7 +138,7 @@ NewFolderDialog::NewFolderDialog( QWidget* parent, KMFolder *folder )
( mFolder->folderType() == KMFolderTypeImap ||
mFolder->folderType() == KMFolderTypeCachedImap ) ) {
bool rootFolder = false;
- QStringList namespaces;
+ TQStringList namespaces;
if ( mFolder->folderType() == KMFolderTypeImap ) {
ImapAccountBase* ai = static_cast<KMFolderImap*>(mFolder->storage())->account();
if ( mFolder->storage() == ai->rootFolder() ) {
@@ -154,15 +154,15 @@ NewFolderDialog::NewFolderDialog( QWidget* parent, KMFolder *folder )
}
}
if ( rootFolder && namespaces.count() > 1 ) {
- mNamespacesHBox = new QHBoxLayout( 0, 0, 6, "mNamespaceHBox");
+ mNamespacesHBox = new TQHBoxLayout( 0, 0, 6, "mNamespaceHBox");
- mNamespacesLabel = new QLabel( privateLayoutWidget, "mNamespacesLabel" );
+ mNamespacesLabel = new TQLabel( privateLayoutWidget, "mNamespacesLabel" );
mNamespacesLabel->setText( i18n( "Namespace for &folder:" ) );
mNamespacesHBox->addWidget( mNamespacesLabel );
- mNamespacesComboBox = new QComboBox( false, privateLayoutWidget, "mNamespacesComboBox" );
+ mNamespacesComboBox = new TQComboBox( false, privateLayoutWidget, "mNamespacesComboBox" );
mNamespacesLabel->setBuddy( mNamespacesComboBox );
- QWhatsThis::add( mNamespacesComboBox, i18n( "Select the personal namespace the folder should be created in." ) );
+ TQWhatsThis::add( mNamespacesComboBox, i18n( "Select the personal namespace the folder should be created in." ) );
mNamespacesComboBox->insertStringList( namespaces );
mNamespacesHBox->addWidget( mNamespacesComboBox );
mTopLevelLayout->addLayout( mNamespacesHBox );
@@ -171,19 +171,19 @@ NewFolderDialog::NewFolderDialog( QWidget* parent, KMFolder *folder )
}
}
- resize( QSize(282, 108).expandedTo(minimumSizeHint()) );
+ resize( TQSize(282, 108).expandedTo(minimumSizeHint()) );
clearWState( WState_Polished );
slotFolderNameChanged( mNameLineEdit->text());
}
-void NewFolderDialog::slotFolderNameChanged( const QString & _text)
+void NewFolderDialog::slotFolderNameChanged( const TQString & _text)
{
enableButtonOK( !_text.isEmpty() );
}
void NewFolderDialog::slotOk()
{
- const QString fldName = mNameLineEdit->text();
+ const TQString fldName = mNameLineEdit->text();
if ( fldName.isEmpty() ) {
KMessageBox::error( this, i18n("Please specify a name for the new folder."),
i18n( "No Name Specified" ) );
@@ -209,7 +209,7 @@ void NewFolderDialog::slotOk()
if ( mFolder &&
( mFolder->folderType() == KMFolderTypeImap ||
mFolder->folderType() == KMFolderTypeCachedImap ) ) {
- QString delimiter;
+ TQString delimiter;
if ( mFolder->folderType() == KMFolderTypeImap ) {
KMAcctImap* ai = static_cast<KMFolderImap*>( mFolder->storage() )->account();
if ( ai )
@@ -237,13 +237,13 @@ void NewFolderDialog::slotOk()
&& ( selectedFolderDir == mFolder->parent() )
&& ( mFolder->storage()->name() == fldName ) ) ) )
{
- const QString message = i18n( "<qt>Failed to create folder <b>%1</b>, folder already exists.</qt>" ).arg(fldName);
+ const TQString message = i18n( "<qt>Failed to create folder <b>%1</b>, folder already exists.</qt>" ).arg(fldName);
KMessageBox::error( this, message );
return;
}
/* Ok, obvious errors caught, let's try creating it for real. */
- const QString message = i18n( "<qt>Failed to create folder <b>%1</b>."
+ const TQString message = i18n( "<qt>Failed to create folder <b>%1</b>."
"</qt> " ).arg(fldName);
bool success = false;
KMFolder *newFolder = 0;
@@ -255,7 +255,7 @@ void NewFolderDialog::slotOk()
if (anAccount->makeConnection() == ImapAccountBase::Connected) {
newFolder = kmkernel->imapFolderMgr()->createFolder( fldName, false, KMFolderTypeImap, selectedFolderDir );
if ( newFolder ) {
- QString imapPath, parent;
+ TQString imapPath, parent;
if ( mNamespacesComboBox ) {
// create folder with namespace
parent = anAccount->addPathToNamespace( mNamespacesComboBox->currentText() );
@@ -265,7 +265,7 @@ void NewFolderDialog::slotOk()
}
KMFolderImap* newStorage = static_cast<KMFolderImap*>( newFolder->storage() );
selectedStorage->createFolder(fldName, parent); // create it on the server
- newStorage->initializeFrom( selectedStorage, imapPath, QString::null );
+ newStorage->initializeFrom( selectedStorage, imapPath, TQString::null );
static_cast<KMFolderImap*>(mFolder->storage())->setAccount( selectedStorage->account() );
success = true;
}
@@ -278,7 +278,7 @@ void NewFolderDialog::slotOk()
newStorage->initializeFrom( selectedStorage );
if ( mNamespacesComboBox ) {
// create folder with namespace
- QString path = selectedStorage->account()->createImapPath(
+ TQString path = selectedStorage->account()->createImapPath(
mNamespacesComboBox->currentText(), fldName );
newStorage->setImapPathForCreation( path );
}