author | alwin <alwin> | 2004-02-19 13:42:40 (UTC) |
---|---|---|
committer | alwin <alwin> | 2004-02-19 13:42:40 (UTC) |
commit | c2eb77f6b8933b02bd8bd59ec7325da0bfc956cb (patch) (side-by-side diff) | |
tree | 41cd0ca977bcec1f8bc3ad44f128d73324724388 | |
parent | 51992ef09a92db868234936484fcc3aec0d2d4ad (diff) | |
download | opie-c2eb77f6b8933b02bd8bd59ec7325da0bfc956cb.zip opie-c2eb77f6b8933b02bd8bd59ec7325da0bfc956cb.tar.gz opie-c2eb77f6b8933b02bd8bd59ec7325da0bfc956cb.tar.bz2 |
use stuff from libopie2
ToDo: after merge pim-classes to opie2, do the same with it.
-rw-r--r-- | noncore/net/mail/composemail.cpp | 4 | ||||
-rw-r--r-- | noncore/net/mail/libmailwrapper/libmailwrapper.control | 4 | ||||
-rw-r--r-- | noncore/net/mail/libmailwrapper/mhwrapper.cpp | 2 | ||||
-rw-r--r-- | noncore/net/mail/mail.pro | 4 | ||||
-rw-r--r-- | noncore/net/mail/main.cpp | 2 | ||||
-rw-r--r-- | noncore/net/mail/opie-mail.control | 4 | ||||
-rw-r--r-- | noncore/net/mail/taskbarapplet/mailapplet.cpp | 4 | ||||
-rw-r--r-- | noncore/net/mail/taskbarapplet/opie-mailapplet.control | 4 | ||||
-rw-r--r-- | noncore/net/mail/taskbarapplet/taskbarapplet.pro | 2 | ||||
-rw-r--r-- | noncore/net/mail/viewmail.cpp | 4 |
10 files changed, 17 insertions, 17 deletions
diff --git a/noncore/net/mail/composemail.cpp b/noncore/net/mail/composemail.cpp index abcc3f6..6708779 100644 --- a/noncore/net/mail/composemail.cpp +++ b/noncore/net/mail/composemail.cpp @@ -1,27 +1,27 @@ #include <qt.h> -#include <opie/ofiledialog.h> +#include <opie2/ofiledialog.h> #include <qpe/resource.h> #include <qpe/config.h> #include <qpe/global.h> #include <qpe/contact.h> #include "composemail.h" #include <libmailwrapper/smtpwrapper.h> ComposeMail::ComposeMail( Settings *s, QWidget *parent, const char *name, bool modal, WFlags flags ) : ComposeMailUI( parent, name, modal, flags ) { settings = s; QString vfilename = Global::applicationFileName("addressbook", "businesscard.vcf"); Contact c; if (QFile::exists(vfilename)) { c = Contact::readVCard( vfilename )[0]; } QStringList mails = c.emailList(); QString defmail = c.defaultEmail(); @@ -142,49 +142,49 @@ void ComposeMail::fillValues( int current ) if ( smtp->getUseBCC() ) { bccLine->setText( smtp->getBCC() ); } replyLine->clear(); if ( smtp->getUseReply() ) { replyLine->setText( smtp->getReply() ); } sigMultiLine->setText( smtp->getSignature() ); #endif } 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() { - DocLnk lnk = OFileDialog::getOpenFileName( 1, "/" ); + DocLnk lnk = Opie::OFileDialog::getOpenFileName( 1, "/" ); if ( !lnk.name().isEmpty() ) { Attachment *att = new Attachment( lnk ); (void) new AttachViewItem( attList, att ); } } void ComposeMail::removeAttachment() { if ( !attList->currentItem() ) { QMessageBox::information( this, tr( "Error" ), tr( "<p>Please select a File.</p>" ), tr( "Ok" ) ); } else { attList->takeItem( attList->currentItem() ); } } void ComposeMail::accept() { if ( checkBoxLater->isChecked() ) { qDebug( "Send later" ); } #if 0 diff --git a/noncore/net/mail/libmailwrapper/libmailwrapper.control b/noncore/net/mail/libmailwrapper/libmailwrapper.control index 0e9e3ed..8b319c8 100644 --- a/noncore/net/mail/libmailwrapper/libmailwrapper.control +++ b/noncore/net/mail/libmailwrapper/libmailwrapper.control @@ -1,10 +1,10 @@ Package: libmailwrapper Files: lib/libmailwrapper.so* Priority: optional Section: libs Maintainer: Rajko Albrecht <alwin@handhelds.org>, Juergen Graf <jgf@handhelds.org>, Maximilian Reiß <harlekin@handhelds.org> Architecture: arm -Version: 0.4-$SUB_VERSION -Depends: task-opie-minimal, libopie1, libetpan +Version: 0.5-$SUB_VERSION +Depends: task-opie-minimal, libopiecore2, libopieui2, libetpan (>= 0.33pre) Description: wrapper lib needed by Opie's mailer License: LGPL diff --git a/noncore/net/mail/libmailwrapper/mhwrapper.cpp b/noncore/net/mail/libmailwrapper/mhwrapper.cpp index 5090f4a..dfc00d8 100644 --- a/noncore/net/mail/libmailwrapper/mhwrapper.cpp +++ b/noncore/net/mail/libmailwrapper/mhwrapper.cpp @@ -1,33 +1,33 @@ #include "mhwrapper.h" #include "mailtypes.h" #include "mailwrapper.h" #include <libetpan/libetpan.h> #include <qdir.h> #include <qmessagebox.h> #include <stdlib.h> #include <qpe/global.h> -#include <opie/oprocess.h> +#include <opie2/oprocess.h> const QString MHwrapper::wrapperType="MH"; MHwrapper::MHwrapper(const QString & mbox_dir,const QString&mbox_name) : Genericwrapper(),MHPath(mbox_dir),MHName(mbox_name) { if (MHPath.length()>0) { if (MHPath[MHPath.length()-1]=='/') { MHPath=MHPath.left(MHPath.length()-1); } qDebug(MHPath); QDir dir(MHPath); if (!dir.exists()) { dir.mkdir(MHPath); } init_storage(); } } void MHwrapper::init_storage() { int r; QString pre = MHPath; if (!m_storage) { diff --git a/noncore/net/mail/mail.pro b/noncore/net/mail/mail.pro index 184b5b3..d3d2ab1 100644 --- a/noncore/net/mail/mail.pro +++ b/noncore/net/mail/mail.pro @@ -30,32 +30,32 @@ SOURCES = main.cpp \ settingsdialog.cpp \ statuswidget.cpp \ newmaildir.cpp \ selectstore.cpp \ selectsmtp.cpp INTERFACES = editaccountsui.ui \ selectmailtypeui.ui \ imapconfigui.ui \ pop3configui.ui \ nntpconfigui.ui \ smtpconfigui.ui \ addresspickerui.ui \ composemailui.ui \ settingsdialogui.ui \ statuswidgetui.ui \ newmaildirui.ui \ selectstoreui.ui INCLUDEPATH += $(OPIEDIR)/include CONFTEST = $$system( echo $CONFIG_TARGET_MACOSX ) contains( CONFTEST, y ){ - LIBS += -lqpe -lopie -lmailwrapper -liconv + LIBS += -lqpe -lopieui2 -lopiecore2 -lopie -lmailwrapper -liconv }else{ - LIBS += -lqpe -lopie -lmailwrapper + LIBS += -lqpe -lopieui2 -lopiecore2 -lopie -lmailwrapper } TARGET = opiemail include ( $(OPIEDIR)/include.pro ) diff --git a/noncore/net/mail/main.cpp b/noncore/net/mail/main.cpp index 3bfcb4a..54ac7fb 100644 --- a/noncore/net/mail/main.cpp +++ b/noncore/net/mail/main.cpp @@ -1,5 +1,5 @@ -#include <opie/oapplicationfactory.h> +#include <opie2/oapplicationfactory.h> #include "opiemail.h" OPIE_EXPORT_APP( OApplicationFactory<OpieMail> ) diff --git a/noncore/net/mail/opie-mail.control b/noncore/net/mail/opie-mail.control index 0e11c4a..5f25414 100644 --- a/noncore/net/mail/opie-mail.control +++ b/noncore/net/mail/opie-mail.control @@ -1,10 +1,10 @@ Package: opie-mail Files: plugins/application/libopiemail.so* bin/opiemail apps/1Pim/mail.desktop pics/mail/*.png Priority: optional Section: opie/pim Maintainer: Rajko Albrecht <alwin@handhelds.org>, Juergen Graf <jgf@handhelds.org>, Maximilian Reiß <harlekin@handhelds.org> Architecture: arm -Version: 0.4-$SUB_VERSION -Depends: task-opie-minimal, libopie1, libmailwrapper +Version: 0.5-$SUB_VERSION +Depends: task-opie-minimal, libopie1, libopiecore2, libopieui2, libmailwrapper (>= 0.4) Description: Opie's mail and news client (POP3, IMAP and NNTP) License: LGPL diff --git a/noncore/net/mail/taskbarapplet/mailapplet.cpp b/noncore/net/mail/taskbarapplet/mailapplet.cpp index a0805ba..de32007 100644 --- a/noncore/net/mail/taskbarapplet/mailapplet.cpp +++ b/noncore/net/mail/taskbarapplet/mailapplet.cpp @@ -1,33 +1,33 @@ #include <qpainter.h> #include <qtimer.h> #include <qpe/qcopenvelope_qws.h> #include <qpe/resource.h> #include <qpe/config.h> #include <qpe/applnk.h> -#include <opie/odevice.h> +#include <opie2/odevice.h> #include <libmailwrapper/settings.h> #include "mailapplet.h" using namespace Opie; MailApplet::MailApplet( QWidget *parent ) : QWidget( parent ) { m_config = new Config( "mail" ); m_config->setGroup( "Applet" ); setFixedWidth( AppLnk::smallIconSize() ); setFixedHeight( AppLnk::smallIconSize() ); hide(); m_newMails = 0; m_statusMail = 0l; if ( !m_config->readBoolEntry( "Disabled", false ) ) { // delay 5 sec until the whole mail backend gets started .-) QTimer::singleShot( 5000, this, SLOT( startup() ) ); @@ -95,49 +95,49 @@ void MailApplet::slotCheck() { m_intervalTimer->changeInterval( newIntervalMs ); m_intervalMs = newIntervalMs; } if (m_statusMail == 0) { return; } folderStat stat; m_statusMail->check_current_stat( stat ); int newMailsOld = m_newMails; m_newMails = stat.message_unseen; qDebug( QString( "test %1" ).arg( m_newMails ) ); if ( m_newMails > 0 && newMailsOld != m_newMails ) { ODevice *device = ODevice::inst(); if ( isHidden() ) show(); if ( m_config->readBoolEntry( "BlinkLed", true ) ) { if ( !device->ledList().isEmpty() ) { OLed led = ( device->ledList().contains( Led_Mail ) ) ? Led_Mail : device->ledList()[0]; device->setLedState( led, device->ledStateList( led ).contains( Led_BlinkSlow ) ? Led_BlinkSlow : Led_On ); } } if ( m_config->readBoolEntry( "PlaySound", false ) ) - device->alarmSound(); + device->playAlarmSound(); Config cfg( "mail" ); cfg.setGroup( "Status" ); cfg.writeEntry( "newMails", m_newMails ); QCopEnvelope env( "QPE/Pim", "newMails(int)" ); env << m_newMails; repaint( true ); } else { ODevice *device = ODevice::inst(); if ( !isHidden() ) hide(); if ( !device->ledList().isEmpty() ) { OLed led = ( device->ledList().contains( Led_Mail ) ) ? Led_Mail : device->ledList()[0]; device->setLedState( led, Led_Off ); } if ( newMailsOld != m_newMails ) { Config cfg( "mail" ); cfg.setGroup( "Status" ); cfg.writeEntry( "newMails", m_newMails ); QCopEnvelope env( "QPE/Pim", "newMails(int)" ); env << m_newMails; } diff --git a/noncore/net/mail/taskbarapplet/opie-mailapplet.control b/noncore/net/mail/taskbarapplet/opie-mailapplet.control index 84adc7b..f9822a5 100644 --- a/noncore/net/mail/taskbarapplet/opie-mailapplet.control +++ b/noncore/net/mail/taskbarapplet/opie-mailapplet.control @@ -1,10 +1,10 @@ Package: opie-mailapplet Files: plugins/applets/libmailapplet.so* Priority: optional Section: opie/applets Maintainer: Rajko Albrecht <alwin@handhelds.org>, Juergen Graf <jgf@handhelds.org>, Maximilian Reiß <harlekin@handhelds.org> Architecture: arm -Version: 0.4-$SUB_VERSION -Depends: task-opie-minimal, libopie1, opie-mail +Version: 0.5-$SUB_VERSION +Depends: task-opie-minimal, libopiecore2, opie-mail Description: A Biff-like mailchecker License: LGPL diff --git a/noncore/net/mail/taskbarapplet/taskbarapplet.pro b/noncore/net/mail/taskbarapplet/taskbarapplet.pro index c54e87f..e4ac6d1 100644 --- a/noncore/net/mail/taskbarapplet/taskbarapplet.pro +++ b/noncore/net/mail/taskbarapplet/taskbarapplet.pro @@ -1,12 +1,12 @@ TEMPLATE = lib CONFIG += qt plugin warn_on release HEADERS += mailapplet.h \ mailappletimpl.h SOURCES += mailapplet.cpp \ mailappletimpl.cpp INCLUDEPATH += $(OPIEDIR)/include $(OPIEDIR)/noncore/net/mail -LIBS += -lmailwrapper -lqpe -lopie +LIBS += -lmailwrapper -lqpe -lopiecore2 TARGET = mailapplet DESTDIR += $(OPIEDIR)/plugins/applets/ include ( $(OPIEDIR)/include.pro ) diff --git a/noncore/net/mail/viewmail.cpp b/noncore/net/mail/viewmail.cpp index 9ca6383..99965d4 100644 --- a/noncore/net/mail/viewmail.cpp +++ b/noncore/net/mail/viewmail.cpp @@ -1,36 +1,36 @@ #include <qtextbrowser.h> #include <qmessagebox.h> #include <qtextstream.h> #include <qaction.h> #include <qpopupmenu.h> #include <qfile.h> #include <qapplication.h> #include <qvaluelist.h> #include <qpe/config.h> -#include <opie/ofiledialog.h> +#include <opie2/ofiledialog.h> #include <libmailwrapper/settings.h> #include "composemail.h" #include "viewmail.h" #include <libmailwrapper/abstractmail.h> #include "accountview.h" #include <libmailwrapper/mailtypes.h> AttachItem::AttachItem(QListView * parent,QListViewItem *after, const QString&mime,const QString&desc,const QString&file, const QString&fsize,int num,const QValueList<int>&path) : QListViewItem(parent,after),_partNum(num) { _path=path; setText(0, mime); setText(1, desc); setText(2, file); setText(3, fsize); } AttachItem::AttachItem(QListViewItem * parent,QListViewItem *after, const QString&mime,const QString&desc,const QString&file, const QString&fsize,int num,const QValueList<int>&path) : QListViewItem(parent,after),_partNum(num) { _path=path; @@ -177,49 +177,49 @@ void ViewMail::slotShowHtml( bool state ) { void ViewMail::slotItemClicked( QListViewItem * item , const QPoint & point, int ) { if (!item ) return; if ( ( ( AttachItem* )item )->Partnumber() == -1 ) { setText(); return; } QPopupMenu *menu = new QPopupMenu(); int ret=0; if ( item->text( 0 ).left( 5 ) == "text/" || item->text(0)=="message/rfc822" ) { menu->insertItem( tr( "Show Text" ), 1 ); } menu->insertItem( tr( "Save Attachment" ), 0 ); menu->insertSeparator(1); ret = menu->exec( point, 0 ); switch(ret) { case 0: { MimeTypes types; types.insert( "all", "*" ); - QString str = OFileDialog::getSaveFileName( 1, + QString str = Opie::OFileDialog::getSaveFileName( 1, "/", item->text( 2 ) , types, 0 ); if( !str.isEmpty() ) { encodedString*content = m_recMail.Wrapper()->fetchDecodedPart( m_recMail, m_body.Parts()[ ( ( AttachItem* )item )->Partnumber() ] ); if (content) { QFile output(str); output.open(IO_WriteOnly); output.writeBlock(content->Content(),content->Length()); output.close(); delete content; } } } break ; case 1: if ( ( ( AttachItem* )item )->Partnumber() == -1 ) { setText(); } else { if ( m_recMail.Wrapper() != 0l ) { // make sure that there is a wrapper , even after delete or simular actions browser->setText( m_recMail.Wrapper()->fetchTextPart( m_recMail, m_body.Parts()[ ( ( AttachItem* )item )->Partnumber() ] ) ); } } break; |