summaryrefslogtreecommitdiffabout
path: root/kmicromail/selectsmtp.cpp
Unidiff
Diffstat (limited to 'kmicromail/selectsmtp.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--kmicromail/selectsmtp.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/kmicromail/selectsmtp.cpp b/kmicromail/selectsmtp.cpp
index 10b6d79..ead723c 100644
--- a/kmicromail/selectsmtp.cpp
+++ b/kmicromail/selectsmtp.cpp
@@ -1,64 +1,64 @@
1#include "selectsmtp.h" 1#include "selectsmtp.h"
2#include <libmailwrapper/mailwrapper.h> 2#include <libmailwrapper/mailwrapper.h>
3 3
4#include <qcombobox.h> 4#include <qcombobox.h>
5#include <qcheckbox.h> 5#include <qcheckbox.h>
6#include <qmessagebox.h> 6#include <qmessagebox.h>
7#include <qpushbutton.h> 7#include <qpushbutton.h>
8#include <qlineedit.h> 8#include <qlineedit.h>
9#include <qlabel.h> 9#include <qlabel.h>
10#include <qtabwidget.h> 10#include <qtabwidget.h>
11#include <qlistview.h> 11#include <q3listview.h>
12#include <klocale.h> 12#include <klocale.h>
13selectsmtp::selectsmtp(QWidget* parent, const char* name, bool modal, WFlags fl) 13selectsmtp::selectsmtp(QWidget* parent, const char* name, bool modal, Qt::WFlags fl)
14 : selectstoreui(parent,name,modal,fl) 14 : selectstoreui(parent,name,modal,fl)
15{ 15{
16 //m_smtpList.setAutoDelete(false); 16 //m_smtpList.setAutoDelete(false);
17 m_smtpList = 0; 17 m_smtpList = 0;
18 //headlabel->setText(i18n("<center>Select SMTP account to use</center>")); 18 //headlabel->setText(i18n("<center>Select SMTP account to use</center>"));
19 headlabel->hide(); 19 headlabel->hide();
20 folderSelection->hide(); 20 folderSelection->hide();
21 folderLabel->hide(); 21 folderLabel->hide();
22 //accountlabel->setText(i18n("SMTP\nAccount:")); 22 //accountlabel->setText(i18n("SMTP\nAccount:"));
23 Line1->hide(); 23 Line1->hide();
24 newFoldersel->hide(); 24 newFoldersel->hide();
25 newFolderedit->hide(); 25 newFolderedit->hide();
26 newFolderLabel->hide(); 26 newFolderLabel->hide();
27 Line2->hide(); 27 Line2->hide();
28 selMove->hide(); 28 selMove->hide();
29 m_current_smtp = 0; 29 m_current_smtp = 0;
30 setCaption(i18n("Select SMTP Account")); 30 setCaption(i18n("Select SMTP Account"));
31} 31}
32 32
33selectsmtp::~selectsmtp() 33selectsmtp::~selectsmtp()
34{ 34{
35} 35}
36 36
37void selectsmtp::slotAccountselected(int which) 37void selectsmtp::slotAccountselected(int which)
38{ 38{
39 if (!m_smtpList || (unsigned)which>=m_smtpList->count() || which < 0) { 39 if (!m_smtpList || (unsigned)which>=m_smtpList->count() || which < 0) {
40 m_current_smtp = 0; 40 m_current_smtp = 0;
41 return; 41 return;
42 } 42 }
43 m_current_smtp = m_smtpList->at(which); 43 m_current_smtp = m_smtpList->at(which);
44} 44}
45 45
46void selectsmtp::setSelectionlist(QList<SMTPaccount>*list) 46void selectsmtp::setSelectionlist(QList<SMTPaccount>*list)
47{ 47{
48 m_smtpList = list; 48 m_smtpList = list;
49 accountSelection->clear(); 49 accountSelection->clear();
50 if (!m_smtpList || m_smtpList->count()==0) { 50 if (!m_smtpList || m_smtpList->count()==0) {
51 accountSelection->setEnabled(false); 51 accountSelection->setEnabled(false);
52 return; 52 return;
53 } 53 }
54 accountSelection->setEnabled(true); 54 accountSelection->setEnabled(true);
55 for (unsigned i = 0; m_smtpList!=0 && i < m_smtpList->count(); ++i) { 55 for (unsigned i = 0; m_smtpList!=0 && i < m_smtpList->count(); ++i) {
56 accountSelection->insertItem( m_smtpList->at(i)->getAccountName()); 56 accountSelection->insertItem( m_smtpList->at(i)->getAccountName());
57 } 57 }
58 m_current_smtp = m_smtpList->at(0); 58 m_current_smtp = m_smtpList->at(0);
59} 59}
60 60
61SMTPaccount*selectsmtp::selected_smtp() 61SMTPaccount*selectsmtp::selected_smtp()
62{ 62{
63 return m_current_smtp; 63 return m_current_smtp;
64} 64}