summaryrefslogtreecommitdiffabout
Side-by-side diff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--bin/kdepim/WhatsNew.txt13
-rw-r--r--kmicromail/composemail.cpp21
-rw-r--r--kmicromail/composemail.h1
-rw-r--r--kmicromail/composemailui.ui74
-rw-r--r--kmicromail/editaccounts.cpp19
-rw-r--r--kmicromail/editaccounts.h1
-rw-r--r--kmicromail/libmailwrapper/settings.cpp46
-rw-r--r--kmicromail/libmailwrapper/settings.h6
-rw-r--r--kmicromail/main.cpp2
-rw-r--r--kmicromail/mainwindow.cpp2
-rw-r--r--kmicromail/smtpconfigui.ui97
11 files changed, 191 insertions, 91 deletions
diff --git a/bin/kdepim/WhatsNew.txt b/bin/kdepim/WhatsNew.txt
index 3dbbbb6..031c7f2 100644
--- a/bin/kdepim/WhatsNew.txt
+++ b/bin/kdepim/WhatsNew.txt
@@ -3,32 +3,45 @@ Info about the changes in new versions of KDE-Pim/Pi
********** VERSION 2.0.2 ************
KO/Pi:
Fixed the layout problem of the day label buttons
of the agenda view introduced in version 2.0.1.
Added WhatsThis support for the todo view and the list view.
Added a quite useful feature to the montview.
Just click on the week numbers on the left.
And in the top right corner of month view/agenda view
there is now a "week number quick selector".
(Click on the black triangle).
Made the quite difficult timezone change in KO/Pi easy.
+OM/Pi:
+Fixed too small icons on desktop.
+Fixed non visible icons in mainwindow on Z with fastload enabled.
+Added signature file setting to smtp account config.
+And the signature can be edited and saved in the edit mail dialog.
+That does mean:
+Simply edit the signature for the selected smtp account in the
+edit new mail dialog and press the "save signature" button there.
+Then the signature is saved to the file specified in the smtp account settings.
+If there is no file specified, it is saved automatically to the file
+kdepim/apps/kopiemail/<accountname>.sig.
+
+
********** VERSION 2.0.1 ************
Oooops ... I forgot to test on the Zaurus 5500 ...
Fixed many problems of new (english) strings (and german translations)
introduced in the latest versions, where the text was not fitting on the
240x320 display of the Zaurus 5500.
KO/Pi:
Added a popup menu ( press pen and hold to get popup ) to the agenda view
with many useful items (add event/todo, show next week, two weeks, month, journal).
Added items to the todolist popup menu for:
Display all opened, all closed or all todos flat.
The "flat" view makes is possible to sort all todos after ,e.g., prio or date.
diff --git a/kmicromail/composemail.cpp b/kmicromail/composemail.cpp
index 976e309..ed8a2ee 100644
--- a/kmicromail/composemail.cpp
+++ b/kmicromail/composemail.cpp
@@ -136,50 +136,59 @@ ComposeMail::ComposeMail( Settings *sett, QWidget *parent, const char *name, boo
#ifndef DESKTOP_VERSION
QPEApplication::setStylusOperation( message, QPEApplication::RightOnHold );
QPEApplication::setStylusOperation( senderNameEdit, QPEApplication::RightOnHold );
QPEApplication::setStylusOperation( subjectLine, QPEApplication::RightOnHold );
#endif
message->setFont ( KOPrefs::instance()->mComposeFont );
message->setWordWrap (QMultiLineEdit::WidgetWidth);
if ( smtpAccounts.count() > 0 ) {
fillValues( smtpAccountBox->currentItem() );
} else {
QMessageBox::information( 0, i18n( "Problem" ),
i18n( "Please create an\nSMTP account first.\nThe SMTP is needed\nfor sending mail.\n" ),
i18n( "Ok" ) );
return;
}
connect( smtpAccountBox, SIGNAL( activated(int) ), SLOT( fillValues(int) ) );
-
+ connect( SaveSigButton, SIGNAL( clicked() ), SLOT( saveSig()) );
+ if ( smtpAccountBox->count())
+ fillValues(0);
}
void ComposeMail::fillSettings()
{
if ( QApplication::desktop()->width() < 320 )
fromBox->setMaximumWidth( 100 );
QStringList mailList = QStringList::split(";",KOPrefs::instance()->mEmail);
QStringList::ConstIterator sit = mailList.begin();
int pref = 0;
for (;sit!=mailList.end();++sit) {
fromBox->insertItem((*sit));
}
senderNameEdit->setText(KOPrefs::instance()->mName);
}
-
-
+void ComposeMail::saveSig()
+{
+ if ( smtpAccountBox->count()) {
+ int cur = smtpAccountBox->currentItem ();
+ SMTPaccount *smtp = smtpAccounts.at( cur );
+ if ( smtp )
+ smtp->setSignature( sigMultiLine->text());
+ }
+}
void ComposeMail::saveAsDraft()
{
Opie::Core::OSmartPointer<Mail> mail= new Mail();
mail->setMail(fromBox->currentText());
mail->setTo( toLine->text() );
mail->setName(senderNameEdit->text());
mail->setCC( ccLine->text() );
mail->setBCC( bccLine->text() );
mail->setReply( replyLine->text() );
mail->setSubject( subjectLine->text() );
if (!m_replyid.isEmpty()) {
QStringList ids;
ids.append(m_replyid);
mail->setInreply(ids);
}
@@ -325,50 +334,52 @@ void ComposeMail::pickAddressCC()
mPickLineEdit = ccLine;
pickAddress( );
}
void ComposeMail::pickAddressBCC()
{
mPickLineEdit = bccLine;
pickAddress( );
}
void ComposeMail::pickAddressReply()
{
mPickLineEdit = replyLine;
pickAddress( );
}
-void ComposeMail::fillValues( int )
+void ComposeMail::fillValues( int current )
{
#if 0
SMTPaccount *smtp = smtpAccounts.at( current );
ccLine->clear();
if ( smtp->getUseCC() ) {
ccLine->setText( smtp->getCC() );
}
bccLine->clear();
if ( smtp->getUseBCC() ) {
bccLine->setText( smtp->getBCC() );
}
replyLine->clear();
if ( smtp->getUseReply() ) {
replyLine->setText( smtp->getReply() );
}
- sigMultiLine->setText( smtp->getSignature() );
#endif
+ SMTPaccount *smtp = smtpAccounts.at( current );
+ if ( smtp )
+ sigMultiLine->setText( smtp->getSignature() );
}
void ComposeMail::slotAdjustColumns()
{
int currPage = tabWidget->currentPageIndex();
tabWidget->showPage( attachTab );
attList->setColumnWidth( 0, attList->visibleWidth() - 80 );
attList->setColumnWidth( 1, 80 );
tabWidget->setCurrentPage( currPage );
}
void ComposeMail::addAttachment()
{
QString lnk = KFileDialog::getOpenFileName( "", "Add Attachment", this );
diff --git a/kmicromail/composemail.h b/kmicromail/composemail.h
index a7fa41c..966ac3e 100644
--- a/kmicromail/composemail.h
+++ b/kmicromail/composemail.h
@@ -55,32 +55,33 @@ protected slots:
void accept();
void reject();
private slots:
void fillValues( int current );
void fillSettings();
void pickAddress();
void pickAddressTo();
void pickAddressCC();
void pickAddressBCC();
void pickAddressReply();
void saveAsDraft();
void addAttachment();
void removeAttachment();
void clearStatus();
void setStatus( QString );
+ void saveSig();
protected:
QLineEdit* mPickLineEdit;
Opie::Core::OSmartPointer<Mail> mMail;
Settings *settings;
QList<SMTPaccount> smtpAccounts;
QString m_replyid;
QString mEncoding;
bool warnAttach;
};
class AttachViewItem : public QListViewItem
{
public:
AttachViewItem( QListView *parent, Attachment *att );
Attachment *getAttachment() { return attachment; }
diff --git a/kmicromail/composemailui.ui b/kmicromail/composemailui.ui
index 610907c..23f47d3 100644
--- a/kmicromail/composemailui.ui
+++ b/kmicromail/composemailui.ui
@@ -1,32 +1,32 @@
<!DOCTYPE UI><UI>
<class>ComposeMailUI</class>
<include location="local">tr.h</include>
<widget>
<class>QDialog</class>
<property stdset="1">
<name>name</name>
<cstring>ComposeMailUI</cstring>
</property>
<property stdset="1">
<name>geometry</name>
<rect>
<x>0</x>
<y>0</y>
- <width>579</width>
- <height>476</height>
+ <width>275</width>
+ <height>382</height>
</rect>
</property>
<property stdset="1">
<name>sizePolicy</name>
<sizepolicy>
<hsizetype>7</hsizetype>
<vsizetype>7</vsizetype>
</sizepolicy>
</property>
<property stdset="1">
<name>caption</name>
<string>Compose Message</string>
</property>
<property>
<name>layoutMargin</name>
</property>
@@ -318,129 +318,119 @@
</widget>
</vbox>
</widget>
<widget>
<class>QWidget</class>
<property stdset="1">
<name>name</name>
<cstring>optionsTab</cstring>
</property>
<attribute>
<name>title</name>
<string>Options</string>
</attribute>
<grid>
<property stdset="1">
<name>margin</name>
- <number>3</number>
+ <number>2</number>
</property>
<property stdset="1">
<name>spacing</name>
- <number>3</number>
+ <number>2</number>
</property>
- <widget row="3" column="0" >
- <class>QPushButton</class>
- <property stdset="1">
- <name>name</name>
- <cstring>replyButton</cstring>
- </property>
- <property stdset="1">
- <name>text</name>
- <string>Reply-To</string>
- </property>
- </widget>
- <widget row="2" column="0" >
+ <widget row="1" column="0" >
<class>QPushButton</class>
<property stdset="1">
<name>name</name>
<cstring>bccButton</cstring>
</property>
<property stdset="1">
<name>text</name>
<string>BCC</string>
</property>
</widget>
- <widget row="1" column="1" >
+ <widget row="0" column="1" >
<class>QLineEdit</class>
<property stdset="1">
<name>name</name>
<cstring>ccLine</cstring>
</property>
</widget>
- <widget row="2" column="1" >
+ <widget row="1" column="1" >
<class>QLineEdit</class>
<property stdset="1">
<name>name</name>
<cstring>bccLine</cstring>
</property>
</widget>
- <widget row="3" column="1" >
+ <widget row="2" column="1" >
<class>QLineEdit</class>
<property stdset="1">
<name>name</name>
<cstring>replyLine</cstring>
</property>
</widget>
- <widget row="6" column="0" rowspan="1" colspan="2" >
+ <widget row="4" column="0" rowspan="1" colspan="2" >
<class>QMultiLineEdit</class>
<property stdset="1">
<name>name</name>
<cstring>sigMultiLine</cstring>
</property>
</widget>
- <widget row="5" column="0" >
- <class>QLabel</class>
+ <widget row="0" column="0" >
+ <class>QPushButton</class>
<property stdset="1">
<name>name</name>
- <cstring>sigLabel</cstring>
+ <cstring>ccButton</cstring>
</property>
<property stdset="1">
<name>text</name>
- <string>Signature</string>
+ <string>CC</string>
</property>
</widget>
- <spacer row="4" column="0" >
- <property>
+ <widget row="3" column="1" >
+ <class>QPushButton</class>
+ <property stdset="1">
<name>name</name>
- <cstring>Spacer3</cstring>
+ <cstring>SaveSigButton</cstring>
</property>
<property stdset="1">
- <name>orientation</name>
- <enum>Vertical</enum>
+ <name>text</name>
+ <string>Save signature</string>
</property>
+ </widget>
+ <widget row="2" column="0" >
+ <class>QPushButton</class>
<property stdset="1">
- <name>sizeType</name>
- <enum>Expanding</enum>
+ <name>name</name>
+ <cstring>replyButton</cstring>
</property>
- <property>
- <name>sizeHint</name>
- <size>
- <width>20</width>
- <height>20</height>
- </size>
+ <property stdset="1">
+ <name>text</name>
+ <string>Reply-To</string>
</property>
- </spacer>
- <widget row="1" column="0" >
- <class>QPushButton</class>
+ </widget>
+ <widget row="3" column="0" >
+ <class>QLabel</class>
<property stdset="1">
<name>name</name>
- <cstring>ccButton</cstring>
+ <cstring>sigLabel</cstring>
</property>
<property stdset="1">
<name>text</name>
- <string>CC</string>
+ <string>Signature</string>
</property>
</widget>
</grid>
</widget>
<widget>
<class>QWidget</class>
<property stdset="1">
<name>name</name>
<cstring>attachTab</cstring>
</property>
<attribute>
<name>title</name>
<string>Attachment</string>
</attribute>
<grid>
<property stdset="1">
diff --git a/kmicromail/editaccounts.cpp b/kmicromail/editaccounts.cpp
index 48c3963..8253c91 100644
--- a/kmicromail/editaccounts.cpp
+++ b/kmicromail/editaccounts.cpp
@@ -6,32 +6,33 @@
/* OPIE */
#include <qpe/qpeapplication.h>
/* QT */
#include <qstringlist.h>
#include <qcombobox.h>
#include <qcheckbox.h>
#include <qmessagebox.h>
#include <qpushbutton.h>
#include <qlineedit.h>
#include <qlabel.h>
#include <qtabwidget.h>
#include <qlistview.h>
#include <qspinbox.h>
#include <klocale.h>
+#include <kfiledialog.h>
#include <libmailwrapper/nntpwrapper.h>
using namespace Opie::Core;
AccountListItem::AccountListItem( QListView *parent, Account *a)
: QListViewItem( parent )
{
account = a;
setText( 0, account->getAccountName() );
QString ttext = "";
switch (account->getType()) {
case MAILLIB::A_NNTP:
ttext="NNTP";
break;
case MAILLIB::A_POP3:
@@ -466,80 +467,94 @@ void POP3config::accept()
QDialog::accept();
}
/**
* SMTPconfig
*/
SMTPconfig::SMTPconfig( SMTPaccount *account, QWidget *parent, const char *name, bool modal, WFlags flags )
: SMTPconfigUI( parent, name, modal, flags )
{
data = account;
connect( loginBox, SIGNAL( toggled(bool) ), userLine, SLOT( setEnabled(bool) ) );
connect( loginBox, SIGNAL( toggled(bool) ), passLine, SLOT( setEnabled(bool) ) );
fillValues();
-
+ QIconSet icon;
+ //icon = SmallIcon("fileexport");
+ icon = SmallIcon("fileopen");
+ SignaturButton->setText("");
+ SignaturButton->setIconSet (icon ) ;
+ SignaturButton->setMaximumSize ( SignaturButton->sizeHint().height()+4,SignaturButton->sizeHint().height()) ;
+ connect( SignaturButton, SIGNAL( clicked() ), this, SLOT( chooseSig() ) );
connect( ComboBox1, SIGNAL( activated(int) ), SLOT( slotConnectionToggle(int) ) );
ComboBox1->insertItem( "Only if available", 0 );
ComboBox1->insertItem( "Always, Negotiated", 1 );
ComboBox1->insertItem( "Connect on secure port", 2 );
ComboBox1->insertItem( "Run command instead", 3 );
CommandEdit->hide();
ComboBox1->setCurrentItem( data->ConnectionType() );
}
-
+void SMTPconfig::chooseSig()
+{
+ QString lnk = KFileDialog::getOpenFileName( "", "Choose Signatur File", this );
+ if ( !lnk.isEmpty() ) {
+ SignaturEdit->setText( lnk );
+ }
+}
void SMTPconfig::slotConnectionToggle( int index )
{
// 2 is ssl connection
if ( index == 2 )
{
portLine->setText( SMTP_SSL_PORT );
}
else if ( index == 3 )
{
portLine->setText( SMTP_PORT );
CommandEdit->show();
}
else
{
portLine->setText( SMTP_PORT );
}
}
void SMTPconfig::fillValues()
{
accountLine->setText( data->getAccountName() );
serverLine->setText( data->getServer() );
portLine->setText( data->getPort() );
ComboBox1->setCurrentItem( data->ConnectionType() );
loginBox->setChecked( data->getLogin() );
userLine->setText( data->getUser() );
passLine->setText( data->getPassword() );
+ SignaturEdit->setText( data->getSigFile() );
}
void SMTPconfig::accept()
{
data->setAccountName( accountLine->text() );
data->setServer( serverLine->text() );
data->setPort( portLine->text() );
data->setConnectionType( ComboBox1->currentItem() );
data->setLogin( loginBox->isChecked() );
data->setUser( userLine->text() );
data->setPassword( passLine->text() );
+ data->setSigFile( SignaturEdit->text() );
QDialog::accept();
}
/**
* NNTPconfig
*/
NNTPconfig::NNTPconfig( NNTPaccount *account, QWidget *parent, const char *name, bool modal, WFlags flags )
: NNTPconfigUI( parent, name, modal, flags )
{
data = account;
connect( loginBox, SIGNAL( toggled(bool) ), userLine, SLOT( setEnabled(bool) ) );
connect( loginBox, SIGNAL( toggled(bool) ), passLine, SLOT( setEnabled(bool) ) );
connect( GetNGButton, SIGNAL( clicked() ), this, SLOT( slotGetNG() ) );
diff --git a/kmicromail/editaccounts.h b/kmicromail/editaccounts.h
index 6cf842e..465780c 100644
--- a/kmicromail/editaccounts.h
+++ b/kmicromail/editaccounts.h
@@ -108,32 +108,33 @@ private:
};
class SMTPconfig : public SMTPconfigUI
{
Q_OBJECT
public:
SMTPconfig( SMTPaccount *account, QWidget *parent = 0, const char *name = 0, bool modal = 0, WFlags flags = 0 );
public slots:
void fillValues();
protected slots:
void slotConnectionToggle( int index );
void accept();
+ void chooseSig();
private:
SMTPaccount *data;
};
class NNTPconfig : public NNTPconfigUI
{
Q_OBJECT
public:
NNTPconfig( NNTPaccount *account, QWidget *parent = 0, const char *name = 0, bool modal = 0, WFlags flags = 0 );
public slots:
void fillValues();
diff --git a/kmicromail/libmailwrapper/settings.cpp b/kmicromail/libmailwrapper/settings.cpp
index 19093b1..8f909f9 100644
--- a/kmicromail/libmailwrapper/settings.cpp
+++ b/kmicromail/libmailwrapper/settings.cpp
@@ -1,19 +1,23 @@
#include <stdlib.h>
#include <qdir.h>
+#include <qtextcodec.h>
+#include <qtextstream.h>
+#include <qfile.h>
+
//#include <opie2/odebug.h>
#include <kconfig.h>
#include <kstandarddirs.h>
#include "settings.h"
//#include "defines.h"
#define IMAP_PORT "143"
#define IMAP_SSL_PORT "993"
#define SMTP_PORT "25"
#define SMTP_SSL_PORT "465"
#define POP3_PORT "110"
#define POP3_SSL_PORT "995"
#define NNTP_PORT "119"
#define NNTP_SSL_PORT "563"
@@ -353,76 +357,116 @@ SMTPaccount::SMTPaccount()
type = MAILLIB::A_SMTP;
port = SMTP_PORT;
}
SMTPaccount::SMTPaccount( QString filename )
: Account()
{
file = filename;
accountName = "New SMTP Account";
ssl = false;
connectionType = 1;
login = false;
type = MAILLIB::A_SMTP;
port = SMTP_PORT;
}
+QString SMTPaccount::getSignature()
+{
+ QFileInfo fi ( signature );
+ if ( ! fi.exists() )
+ return QString();
+
+ QFile file( signature );
+ if (!file.open( IO_ReadOnly ) ) {
+ return QString();
+
+ }
+ QTextStream ts( &file );
+ ts.setCodec( QTextCodec::codecForName("utf8") );
+ QString text = ts.read();
+ file.close();
+
+ return text;
+
+}
+void SMTPaccount::setSignature( QString b )
+{
+
+ QFileInfo fi ( signature );
+ if ( ! fi.exists() ) {
+ QString filedir( locateLocal("data", "kopiemail" ) );
+ signature = filedir+ "/" + getAccountName() +".sig";
+ qDebug("new sig %s ", signature.latin1());
+ save();
+ }
+ QFile fileIn( signature );
+ if (!fileIn.open( IO_WriteOnly ) ) {
+ qDebug("OM: Cannot write signature file %s ", signature.latin1() );
+ return ;
+ }
+ QTextStream tsIn( &fileIn );
+ tsIn.setCodec( QTextCodec::codecForName("utf8") );
+ tsIn << b ;
+ fileIn.close();
+}
QString SMTPaccount::getUniqueFileName()
{
int num = 0;
QString unique;
QDir dir( locateLocal("data", "kopiemail" ) );
QStringList imap = dir.entryList( "smtp-*" );
do {
unique.setNum( num++ );
} while ( imap.contains( "smtp-" + unique ) > 0 );
return unique;
}
void SMTPaccount::read()
{
KConfig *conf = new KConfig( getFileName() );
conf->setGroup( "SMTP Account" );
accountName = conf->readEntry( "Account" );
server = conf->readEntry( "Server" );
port = conf->readEntry( "Port" );
ssl = conf->readBoolEntry( "SSL" );
connectionType = conf->readNumEntry( "ConnectionType" );
login = conf->readBoolEntry( "Login" );
user = conf->readEntry( "User" );
- //password = conf->readEntryCrypt( "Password" );
+ signature = conf->readEntry( "SigFile" );
setPasswordList( conf->readListEntry( "FolderHistory"));
delete conf;
}
void SMTPaccount::save()
{
Settings::checkDirectory();
KConfig *conf = new KConfig( getFileName() );
conf->setGroup( "SMTP Account" );
conf->writeEntry( "Account", accountName );
conf->writeEntry( "Server", server );
conf->writeEntry( "Port", port );
conf->writeEntry( "SSL", ssl );
conf->writeEntry( "ConnectionType", connectionType );
conf->writeEntry( "Login", login );
conf->writeEntry( "User", user );
+ conf->writeEntry( "SigFile", signature );
//conf->writeEntryCrypt( "Password", password );
conf->writeEntry( "FolderHistory",getPasswordList() );
conf->sync();
delete conf;
}
QString SMTPaccount::getFileName()
{
return locateLocal("data", "kopiemail" ) +"/smtp-" + file;
}
NNTPaccount::NNTPaccount()
: Account()
{
file = NNTPaccount::getUniqueFileName();
diff --git a/kmicromail/libmailwrapper/settings.h b/kmicromail/libmailwrapper/settings.h
index c996fe0..a6e95fe 100644
--- a/kmicromail/libmailwrapper/settings.h
+++ b/kmicromail/libmailwrapper/settings.h
@@ -114,32 +114,38 @@ private:
class SMTPaccount : public Account
{
public:
SMTPaccount();
SMTPaccount( QString filename );
static QString getUniqueFileName();
virtual void read();
virtual void save();
virtual QString getFileName();
void setLogin( bool b ) { login = b; }
bool getLogin() { return login; }
+ void setSigFile( QString b ) { signature = b; }
+ QString getSigFile() { return signature; }
+
+ QString getSignature();
+ void setSignature( QString b );
+
private:
QString file, name, mail, org, cc, bcc, reply, signature;
bool useCC, useBCC, useReply, login;
};
class NNTPaccount : public Account
{
public:
NNTPaccount();
NNTPaccount( QString filename );
static QString getUniqueFileName();
virtual void read();
diff --git a/kmicromail/main.cpp b/kmicromail/main.cpp
index 006390c..1789da0 100644
--- a/kmicromail/main.cpp
+++ b/kmicromail/main.cpp
@@ -28,33 +28,33 @@ int main( int argc, char **argv ) {
QPEApplication a( argc, argv );
a.setKeepRunning ();
#else
QApplication a( argc, argv );
QApplication::setStyle( new QPlatinumStyle ());
#endif
a.setFont( KOPrefs::instance()->mAppFont );
KGlobal::setAppName( "kopiemail" );
QString fileName ;
#ifndef DESKTOP_VERSION
fileName = getenv("QPEDIR");
if ( QApplication::desktop()->width() > 320 )
KGlobal::iconLoader()->setIconPath( fileName +"/pics/kdepim/kopiemail/icons22/");
else
KGlobal::iconLoader()->setIconPath( fileName +"/pics/kdepim/kopiemail/");
#else
- fileName = qApp->applicationDirPath () + "/kdepim/kopiemail/";
+ fileName = qApp->applicationDirPath () + "/kdepim/kopiemail/icons22/";
KGlobal::iconLoader()->setIconPath(QDir::convertSeparators(fileName));
#endif
KStandardDirs::setAppDir( QDir::convertSeparators(locateLocal("data", "kopiemail")));
KPimGlobalPrefs::instance()->setGlobalConfig();
OpieMail mw;
#ifndef DESKTOP_VERSION
//qDebug("CONNECT ");
QObject::connect( &a, SIGNAL (appMessage ( const QCString &, const QByteArray & )),&mw, SLOT(message( const QCString&, const QByteArray& )));
// QObject::connect(&a, SIGNAL (appMessage ( const QCString &, const QByteArray & )), ExternalAppHandler::instance(), SLOT (appMessage ( const QCString &, const QByteArray & )));
a.showMainWidget(&mw );
#else
a.setMainWidget(&mw );
mw.show();
//m.resize( 800, 600 );
QObject::connect(&a, SIGNAL(lastWindowClosed()), &a, SLOT(quit()));
#endif
diff --git a/kmicromail/mainwindow.cpp b/kmicromail/mainwindow.cpp
index 0794e00..4c58909 100644
--- a/kmicromail/mainwindow.cpp
+++ b/kmicromail/mainwindow.cpp
@@ -222,32 +222,34 @@ MainWindow::MainWindow( QWidget *parent, const char *name, WFlags flags )
closeMail->addTo(mailMenu);
QPopupMenu* helpMenu = new QPopupMenu( menuBar );
menuBar->insertItem( i18n( "Help" ), helpMenu );
QAction* li = new QAction(i18n("About"), QPixmap(), 0, 0, this);
connect( li, SIGNAL( activated() ), SLOT( showAbout()) );
li->addTo(helpMenu);
li = new QAction(i18n("Licence"),QPixmap(), 0, 0, this);
connect( li, SIGNAL( activated() ), SLOT( showLicence()) );
li->addTo(helpMenu);
li = new QAction(i18n("LibEtPan Licence"), QPixmap(), 0, 0, this);
connect( li, SIGNAL( activated() ), SLOT( showEtpanLicence()) );
li->addTo(helpMenu);
connect( codecMenu, SIGNAL( activated(int) ), this, SLOT( slotSetCodec( int )) );
slotSetCodec( KOPrefs::instance()->mCurrentCodec );
+ menuBar->setMaximumWidth( menuBar->sizeHint().width());
+ //menuBar->setMaximumSize( menuBar->sizeHint());
#ifdef DESKTOP_VERSION
resize ( 640, 480 );
#endif
}
MainWindow::~MainWindow()
{
}
void MainWindow::setInfoFields(QListViewItem* item )
{
if ( item == 0) {
if ( subLE ) subLE->setText("");
if ( fromLE ) fromLE->setText("");
if ( toLE ) toLE->setText("");
return;
diff --git a/kmicromail/smtpconfigui.ui b/kmicromail/smtpconfigui.ui
index ae0a49a..aae6f12 100644
--- a/kmicromail/smtpconfigui.ui
+++ b/kmicromail/smtpconfigui.ui
@@ -1,94 +1,76 @@
<!DOCTYPE UI><UI>
<class>SMTPconfigUI</class>
<include location="local">tr.h</include>
<widget>
<class>QDialog</class>
<property stdset="1">
<name>name</name>
<cstring>SMTPconfigUI</cstring>
</property>
<property stdset="1">
<name>geometry</name>
<rect>
<x>0</x>
<y>0</y>
- <width>331</width>
- <height>426</height>
+ <width>266</width>
+ <height>365</height>
</rect>
</property>
<property stdset="1">
<name>caption</name>
<string>Configure SMTP</string>
</property>
<property>
<name>layoutMargin</name>
</property>
<property>
<name>layoutSpacing</name>
</property>
<vbox>
<property stdset="1">
<name>margin</name>
- <number>3</number>
+ <number>5</number>
</property>
<property stdset="1">
<name>spacing</name>
- <number>3</number>
+ <number>2</number>
</property>
<widget>
<class>QLabel</class>
<property stdset="1">
<name>name</name>
<cstring>accountLabel</cstring>
</property>
<property stdset="1">
<name>text</name>
<string>Account</string>
</property>
</widget>
<widget>
<class>QLineEdit</class>
<property stdset="1">
<name>name</name>
<cstring>accountLine</cstring>
</property>
<property>
<name>toolTip</name>
<string>Name of the Account</string>
</property>
</widget>
<widget>
- <class>Line</class>
- <property stdset="1">
- <name>name</name>
- <cstring>line1</cstring>
- </property>
- <property stdset="1">
- <name>sizePolicy</name>
- <sizepolicy>
- <hsizetype>1</hsizetype>
- <vsizetype>0</vsizetype>
- </sizepolicy>
- </property>
- <property stdset="1">
- <name>orientation</name>
- <enum>Horizontal</enum>
- </property>
- </widget>
- <widget>
<class>QLayoutWidget</class>
<property stdset="1">
<name>name</name>
<cstring>Layout20</cstring>
</property>
<hbox>
<property stdset="1">
<name>margin</name>
<number>0</number>
</property>
<property stdset="1">
<name>spacing</name>
<number>6</number>
</property>
<widget>
<class>QLayoutWidget</class>
@@ -187,50 +169,32 @@
<name>name</name>
<cstring>ComboBox1</cstring>
</property>
</widget>
<widget>
<class>QLineEdit</class>
<property stdset="1">
<name>name</name>
<cstring>CommandEdit</cstring>
</property>
<property stdset="1">
<name>text</name>
<string>ssh $SERVER exec</string>
</property>
</widget>
<widget>
- <class>Line</class>
- <property stdset="1">
- <name>name</name>
- <cstring>line2</cstring>
- </property>
- <property stdset="1">
- <name>sizePolicy</name>
- <sizepolicy>
- <hsizetype>1</hsizetype>
- <vsizetype>0</vsizetype>
- </sizepolicy>
- </property>
- <property stdset="1">
- <name>orientation</name>
- <enum>Horizontal</enum>
- </property>
- </widget>
- <widget>
<class>QCheckBox</class>
<property stdset="1">
<name>name</name>
<cstring>loginBox</cstring>
</property>
<property stdset="1">
<name>text</name>
<string>Use Login</string>
</property>
</widget>
<widget>
<class>QLayoutWidget</class>
<property stdset="1">
<name>name</name>
<cstring>Layout17</cstring>
</property>
@@ -314,32 +278,85 @@
<name>name</name>
<cstring>passLine</cstring>
</property>
<property stdset="1">
<name>enabled</name>
<bool>false</bool>
</property>
<property stdset="1">
<name>echoMode</name>
<enum>Password</enum>
</property>
</widget>
</vbox>
</widget>
</hbox>
</widget>
+ <widget>
+ <class>QLayoutWidget</class>
+ <property stdset="1">
+ <name>name</name>
+ <cstring>Layout7</cstring>
+ </property>
+ <hbox>
+ <property stdset="1">
+ <name>margin</name>
+ <number>0</number>
+ </property>
+ <property stdset="1">
+ <name>spacing</name>
+ <number>6</number>
+ </property>
+ <widget>
+ <class>QLabel</class>
+ <property stdset="1">
+ <name>name</name>
+ <cstring>TextLabel1_2</cstring>
+ </property>
+ <property stdset="1">
+ <name>text</name>
+ <string>Signatur File</string>
+ </property>
+ </widget>
+ <widget>
+ <class>QLineEdit</class>
+ <property stdset="1">
+ <name>name</name>
+ <cstring>SignaturEdit</cstring>
+ </property>
+ </widget>
+ <widget>
+ <class>QPushButton</class>
+ <property stdset="1">
+ <name>name</name>
+ <cstring>SignaturButton</cstring>
+ </property>
+ <property stdset="1">
+ <name>sizePolicy</name>
+ <sizepolicy>
+ <hsizetype>1</hsizetype>
+ <vsizetype>1</vsizetype>
+ </sizepolicy>
+ </property>
+ <property stdset="1">
+ <name>text</name>
+ <string>F</string>
+ </property>
+ </widget>
+ </hbox>
+ </widget>
<spacer>
<property>
<name>name</name>
<cstring>spacer</cstring>
</property>
<property stdset="1">
<name>orientation</name>
<enum>Vertical</enum>
</property>
<property stdset="1">
<name>sizeType</name>
<enum>Expanding</enum>
</property>
<property>
<name>sizeHint</name>
<size>