Clean up the unneeded (and now broken) needsinbox stuff.

svn path=/branches/proko2/kdepim/; revision=338914
wilder-work
David Faure 22 years ago
parent 5358a3520b
commit 7b5410181e
  1. 16
      accountcombobox.cpp
  2. 5
      accountcombobox.h
  3. 6
      configuredialog.cpp

@ -35,8 +35,8 @@
using namespace KMail;
AccountComboBox::AccountComboBox( bool needsInbox, QWidget* parent, const char* name )
: QComboBox( parent, name ), mNeedsInbox( needsInbox )
AccountComboBox::AccountComboBox( QWidget* parent, const char* name )
: QComboBox( parent, name )
{
connect( kmkernel->acctMgr(), SIGNAL( accountAdded( KMAccount* ) ),
this, SLOT( slotRefreshAccounts() ) );
@ -98,17 +98,7 @@ QValueList<KMAccount *> KMail::AccountComboBox::applicableAccounts() const
for( KMAccount *a = kmkernel->acctMgr()->first(); a;
a = kmkernel->acctMgr()->next() ) {
if ( a && a->type() != "local" ) { //// ## proko2 hack. Need a list of allowed account types as ctor param
disconnect( a, SIGNAL( finishedCheck( bool, CheckStatus ) ),
this, SLOT( slotRefreshAccounts() ) );
bool ok = true;
if ( mNeedsInbox && !a->hasInbox() ) {
// no inbox? maybe there'll be one on the next sync
kdDebug() << k_funcinfo << "No INBOX in " << a->name() << " yet, waiting for sync" << endl;
connect( a, SIGNAL( finishedCheck( bool, CheckStatus ) ),
this, SLOT( slotRefreshAccounts() ) );
} else {
lst.append( a );
}
lst.append( a );
}
}
return lst;

@ -42,8 +42,7 @@ class AccountComboBox : public QComboBox
Q_OBJECT
public:
/// @param needsInbox if true,
AccountComboBox( bool needsInbox, QWidget* parent, const char* name = 0 );
AccountComboBox( QWidget* parent, const char* name = 0 );
void setCurrentAccount( KMAccount* account );
KMAccount* currentAccount() const;
@ -52,8 +51,6 @@ private slots:
void slotRefreshAccounts();
private:
QValueList<KMAccount *> applicableAccounts() const;
bool mNeedsInbox;
};

@ -4120,7 +4120,7 @@ MiscPageGroupwareTab::MiscPageGroupwareTab( QWidget* parent, const char* name )
// Second possibility in the widgetstack: a combo showing the list of accounts
// This is used with the kolab xml storage since the groupware folders
// are always under the inbox.
mAccountCombo = new KMail::AccountComboBox( true /*needs inbox*/, mBox );
mAccountCombo = new KMail::AccountComboBox( mBox );
mFolderComboStack->addWidget( mAccountCombo, 1 );
QToolTip::add( mAccountCombo, toolTip );
QWhatsThis::add( mAccountCombo, whatsThis );
@ -4270,8 +4270,8 @@ void MiscPage::GroupwareTab::save() {
// Inbox folder of the selected account
KMAccount* acct = mAccountCombo->currentAccount();
if ( acct ) {
folderId = QString( ".%1.directory/INBOX" ).arg( acct->id() );
GlobalSettings::setTheIMAPResourceAccount( acct->id() );
folderId = QString( ".%1.directory/INBOX" ).arg( acct->id() );
GlobalSettings::setTheIMAPResourceAccount( acct->id() );
}
}

Loading…
Cancel
Save