summaryrefslogtreecommitdiff
authorzecke <zecke>2004-03-14 13:22:42 (UTC)
committer zecke <zecke>2004-03-14 13:22:42 (UTC)
commit0f7217afa7cdcb108dd2afba0ff6b42c97ab6f44 (patch) (side-by-side diff)
treef6a68afa76a9be4099c3de7a286caeadd250c966
parentd9d68663164078b8dbdbfe70d291291b9fd5aacf (diff)
downloadopie-0f7217afa7cdcb108dd2afba0ff6b42c97ab6f44.zip
opie-0f7217afa7cdcb108dd2afba0ff6b42c97ab6f44.tar.gz
opie-0f7217afa7cdcb108dd2afba0ff6b42c97ab6f44.tar.bz2
Convert net to ODP and QtAUX
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/net/linphone/main.cpp4
-rw-r--r--noncore/net/mail/accountitem.cpp5
-rw-r--r--noncore/net/mail/accountitem.h56
-rw-r--r--noncore/net/mail/accountview.cpp1
-rw-r--r--noncore/net/mail/accountview.h4
-rw-r--r--noncore/net/mail/composemail.cpp8
-rw-r--r--noncore/net/mail/composemail.h2
-rw-r--r--noncore/net/mail/libmailwrapper/abstractmail.cpp3
-rw-r--r--noncore/net/mail/libmailwrapper/abstractmail.h12
-rw-r--r--noncore/net/mail/libmailwrapper/generatemail.cpp5
-rw-r--r--noncore/net/mail/libmailwrapper/generatemail.h4
-rw-r--r--noncore/net/mail/libmailwrapper/genericwrapper.cpp3
-rw-r--r--noncore/net/mail/libmailwrapper/genericwrapper.h4
-rw-r--r--noncore/net/mail/libmailwrapper/imapwrapper.cpp5
-rw-r--r--noncore/net/mail/libmailwrapper/imapwrapper.h12
-rw-r--r--noncore/net/mail/libmailwrapper/mailtypes.cpp5
-rw-r--r--noncore/net/mail/libmailwrapper/mailtypes.h4
-rw-r--r--noncore/net/mail/libmailwrapper/mailwrapper.cpp3
-rw-r--r--noncore/net/mail/libmailwrapper/mailwrapper.h6
-rw-r--r--noncore/net/mail/libmailwrapper/mboxwrapper.cpp5
-rw-r--r--noncore/net/mail/libmailwrapper/mboxwrapper.h8
-rw-r--r--noncore/net/mail/libmailwrapper/mhwrapper.cpp13
-rw-r--r--noncore/net/mail/libmailwrapper/mhwrapper.h20
-rw-r--r--noncore/net/mail/libmailwrapper/nntpwrapper.cpp7
-rw-r--r--noncore/net/mail/libmailwrapper/nntpwrapper.h6
-rw-r--r--noncore/net/mail/libmailwrapper/pop3wrapper.cpp7
-rw-r--r--noncore/net/mail/libmailwrapper/pop3wrapper.h6
-rw-r--r--noncore/net/mail/libmailwrapper/smtpwrapper.cpp3
-rw-r--r--noncore/net/mail/libmailwrapper/smtpwrapper.h4
-rw-r--r--noncore/net/mail/libmailwrapper/storemail.cpp3
-rw-r--r--noncore/net/mail/libmailwrapper/storemail.h2
-rw-r--r--noncore/net/mail/mail.pro2
-rw-r--r--noncore/net/mail/main.cpp2
-rw-r--r--noncore/net/mail/taskbarapplet/mailapplet.cpp2
-rw-r--r--noncore/net/mail/viewmail.cpp3
-rw-r--r--noncore/net/mail/viewmailbase.cpp2
-rw-r--r--noncore/net/opieftp/main.cpp2
-rw-r--r--noncore/net/opieirc/config.in2
-rw-r--r--noncore/net/opieirc/ircsettings.cpp6
-rw-r--r--noncore/net/opieirc/ircsettings.h16
-rw-r--r--noncore/net/opieirc/main.cpp3
-rw-r--r--noncore/net/opieirc/opieirc.pro2
-rw-r--r--noncore/net/opietooth/applet/bluezapplet.cpp2
-rw-r--r--noncore/net/opietooth/lib/device.cc12
-rw-r--r--noncore/net/opietooth/lib/device.h12
-rw-r--r--noncore/net/opietooth/lib/manager.cc22
-rw-r--r--noncore/net/opietooth/lib/manager.h26
-rw-r--r--noncore/net/opietooth/lib/startdunconnection.cpp6
-rw-r--r--noncore/net/opietooth/lib/startdunconnection.h8
-rw-r--r--noncore/net/opietooth/lib/startpanconnection.cpp10
-rw-r--r--noncore/net/opietooth/lib/startpanconnection.h8
-rw-r--r--noncore/net/opietooth/manager/main.cpp4
-rw-r--r--noncore/net/opietooth/manager/obexdialog.cpp7
-rw-r--r--noncore/net/opietooth/manager/obexdialog.h2
-rw-r--r--noncore/net/opietooth/manager/pppdialog.cpp6
-rw-r--r--noncore/net/opietooth/manager/pppdialog.h4
-rw-r--r--noncore/net/ubrowser/main.cpp4
-rw-r--r--noncore/net/wellenreiter/gui/configwindow.cpp6
-rw-r--r--noncore/net/wellenreiter/gui/main.cpp3
-rw-r--r--noncore/net/wellenreiter/gui/mainwindow.cpp5
-rw-r--r--noncore/net/wellenreiter/gui/packetview.cpp3
-rw-r--r--noncore/net/wellenreiter/gui/packetview.h6
-rw-r--r--noncore/net/wellenreiter/gui/scanlist.cpp6
-rw-r--r--noncore/net/wellenreiter/gui/scanlist.h26
-rw-r--r--noncore/net/wellenreiter/gui/statwindow.cpp3
-rw-r--r--noncore/net/wellenreiter/gui/statwindow.h4
-rw-r--r--noncore/net/wellenreiter/gui/wellenreiter.cpp10
-rw-r--r--noncore/net/wellenreiter/gui/wellenreiter.h56
-rw-r--r--noncore/net/wellenreiter/gui/wellenreiterbase.cpp3
-rw-r--r--noncore/net/wellenreiter/gui/wellenreiterbase.h2
70 files changed, 310 insertions, 228 deletions
diff --git a/noncore/net/linphone/main.cpp b/noncore/net/linphone/main.cpp
index 9146fee..6368708 100644
--- a/noncore/net/linphone/main.cpp
+++ b/noncore/net/linphone/main.cpp
@@ -9,14 +9,16 @@
/***************************************************************************
* *
* This program is free software; you can redistribute it and/or modify *
* it under the terms of the GNU General Public License as published by *
* the Free Software Foundation; either version 2 of the License, or *
* (at your option) any later version. *
* *
***************************************************************************/
-#include <opie/oapplicationfactory.h>
+#include <opie2/oapplicationfactory.h>
#include "mainwindow.h"
+
+using namespace Opie::Core;
OPIE_EXPORT_APP( OApplicationFactory<MainWindow> )
diff --git a/noncore/net/mail/accountitem.cpp b/noncore/net/mail/accountitem.cpp
index 9a09c18..e4bb6c5 100644
--- a/noncore/net/mail/accountitem.cpp
+++ b/noncore/net/mail/accountitem.cpp
@@ -10,16 +10,17 @@
#include <libmailwrapper/abstractmail.h>
#include <libmailwrapper/mailwrapper.h>
#include <qpe/qpeapplication.h>
/* QT */
#include <qpopupmenu.h>
#include <qmessagebox.h>
+using namespace Opie::Core;
#define SETPIX(x) if (!account->getOffline()) {setPixmap( 0,x);} else {setPixmap( 0, PIXMAP_OFFLINE );}
/**
* POP3 Account stuff
*/
POP3viewItem::POP3viewItem( POP3account *a, AccountView *parent )
: AccountViewItem( parent )
{
account = a;
@@ -44,17 +45,17 @@ POP3viewItem::~POP3viewItem()
delete wrapper;
}
AbstractMail *POP3viewItem::getWrapper()
{
return wrapper;
}
-void POP3viewItem::refresh(QValueList<Opie::OSmartPointer<RecMail> > & )
+void POP3viewItem::refresh(QValueList<Opie::Core::OSmartPointer<RecMail> > & )
{
refresh();
}
void POP3viewItem::refresh()
{
if (account->getOffline()) return;
QValueList<FolderP> *folders = wrapper->listFolders();
@@ -1037,17 +1038,17 @@ AccountViewItem::AccountViewItem( QListViewItem *parent)
}
AccountViewItem::AccountViewItem( QListViewItem *parent , QListViewItem*after )
:QListViewItem( parent,after ),folder(0)
{
init();
}
-AccountViewItem::AccountViewItem( const Opie::OSmartPointer<Folder>&folderInit,QListViewItem *parent , QListViewItem*after )
+AccountViewItem::AccountViewItem( const Opie::Core::OSmartPointer<Folder>&folderInit,QListViewItem *parent , QListViewItem*after )
:QListViewItem( parent,after ),folder(folderInit)
{
init();
}
void AccountViewItem::init()
{
m_Backlink = 0;
diff --git a/noncore/net/mail/accountitem.h b/noncore/net/mail/accountitem.h
index 276eae0..6cdb260 100644
--- a/noncore/net/mail/accountitem.h
+++ b/noncore/net/mail/accountitem.h
@@ -19,82 +19,82 @@ class Folder;
class AccountViewItem : public QListViewItem
{
public:
AccountViewItem( AccountView *parent );
AccountViewItem( QListViewItem *parent);
AccountViewItem( QListViewItem *parent , QListViewItem*after );
- AccountViewItem( const Opie::OSmartPointer<Folder>&folderInit,QListViewItem *parent , QListViewItem*after );
+ AccountViewItem( const Opie::Core::OSmartPointer<Folder>&folderInit,QListViewItem *parent , QListViewItem*after );
virtual ~AccountViewItem();
- virtual void refresh(QValueList<Opie::OSmartPointer<RecMail> >&)=0;
- virtual RecBody fetchBody(const Opie::OSmartPointer<RecMail>&)=0;
+ virtual void refresh(QValueList<Opie::Core::OSmartPointer<RecMail> >&)=0;
+ virtual RecBody fetchBody(const Opie::Core::OSmartPointer<RecMail>&)=0;
virtual QPopupMenu * getContextMenu(){return 0;};
virtual void contextMenuSelected(int){}
virtual AccountView*accountView();
virtual bool matchName(const QString&name)const;
virtual bool isDraftfolder();
protected:
AccountViewItem*findSubItem(const QString&path,AccountViewItem*start=0);
virtual void init();
virtual void removeChilds();
- virtual void deleteAllMail(AbstractMail*wrapper,const Opie::OSmartPointer<Folder>&f);
+ virtual void deleteAllMail(AbstractMail*wrapper,const Opie::Core::OSmartPointer<Folder>&f);
static const QString contextName;
AccountView*m_Backlink;
- Opie::OSmartPointer<Folder> folder;
+ Opie::Core::OSmartPointer<Folder> folder;
};
class POP3viewItem : public AccountViewItem
{
public:
POP3viewItem( POP3account *a, AccountView *parent );
virtual ~POP3viewItem();
- virtual void refresh(QValueList<Opie::OSmartPointer<RecMail> >&target );
- virtual RecBody fetchBody( const Opie::OSmartPointer<RecMail> &mail );
+ virtual void refresh(QValueList<Opie::Core::OSmartPointer<RecMail> >&target );
+ virtual RecBody fetchBody( const Opie::Core::OSmartPointer<RecMail> &mail );
AbstractMail *getWrapper();
virtual QPopupMenu * getContextMenu();
virtual void contextMenuSelected(int);
protected:
POP3account *account;
virtual void refresh();
AbstractMail *wrapper;
void disconnect();
void setOnOffline();
};
class POP3folderItem : public AccountViewItem
{
public:
- POP3folderItem( const Opie::OSmartPointer<Folder>&folder, POP3viewItem *parent , QListViewItem*after );
+ POP3folderItem( const Opie::Core::OSmartPointer<Folder>&folder, POP3viewItem *parent , QListViewItem*after );
virtual ~POP3folderItem();
- virtual void refresh(QValueList<Opie::OSmartPointer<RecMail> >&);
- virtual RecBody fetchBody(const Opie::OSmartPointer<RecMail>&);
+ virtual void refresh(QValueList<Opie::Core::OSmartPointer<RecMail> >&);
+ virtual RecBody fetchBody(const Opie::Core::OSmartPointer<RecMail>&);
virtual QPopupMenu * getContextMenu();
virtual void contextMenuSelected(int);
protected:
void downloadMails();
POP3viewItem *pop3;
};
class NNTPviewItem : public AccountViewItem
{
public:
NNTPviewItem( NNTPaccount *a, AccountView *parent );
virtual ~NNTPviewItem();
- virtual void refresh(QValueList<Opie::OSmartPointer<RecMail> >&target );
- virtual RecBody fetchBody( const Opie::OSmartPointer<RecMail> &mail );
+ virtual void refresh(QValueList<Opie::Core::OSmartPointer<RecMail> >&target );
+ virtual RecBody fetchBody( const Opie::Core::OSmartPointer<RecMail> &mail );
AbstractMail *getWrapper();
virtual QPopupMenu * getContextMenu();
virtual void contextMenuSelected(int);
protected:
NNTPaccount *account;
virtual void refresh();
AbstractMail *wrapper;
@@ -102,38 +102,38 @@ protected:
void setOnOffline();
void subscribeGroups();
};
class NNTPfolderItem : public AccountViewItem
{
public:
- NNTPfolderItem(const Opie::OSmartPointer<Folder>&folder, NNTPviewItem *parent , QListViewItem*after );
+ NNTPfolderItem(const Opie::Core::OSmartPointer<Folder>&folder, NNTPviewItem *parent , QListViewItem*after );
virtual ~NNTPfolderItem();
- virtual void refresh(QValueList<Opie::OSmartPointer<RecMail> >&);
- virtual RecBody fetchBody(const Opie::OSmartPointer<RecMail>&);
+ virtual void refresh(QValueList<Opie::Core::OSmartPointer<RecMail> >&);
+ virtual RecBody fetchBody(const Opie::Core::OSmartPointer<RecMail>&);
virtual QPopupMenu * getContextMenu();
virtual void contextMenuSelected(int);
protected:
void downloadMails();
NNTPviewItem *nntp;
};
class IMAPviewItem : public AccountViewItem
{
friend class IMAPfolderItem;
public:
IMAPviewItem( IMAPaccount *a, AccountView *parent );
virtual ~IMAPviewItem();
- virtual void refresh(QValueList<Opie::OSmartPointer<RecMail> >&);
- virtual RecBody fetchBody(const Opie::OSmartPointer<RecMail>&);
+ virtual void refresh(QValueList<Opie::Core::OSmartPointer<RecMail> >&);
+ virtual RecBody fetchBody(const Opie::Core::OSmartPointer<RecMail>&);
AbstractMail *getWrapper();
virtual QPopupMenu * getContextMenu();
virtual void contextMenuSelected(int);
const QStringList&subFolders();
virtual void refreshFolders(bool force=false);
bool offline();
protected:
@@ -142,21 +142,21 @@ protected:
AbstractMail *wrapper;
QStringList currentFolders;
};
class IMAPfolderItem : public AccountViewItem
{
public:
- IMAPfolderItem( const Opie::OSmartPointer<Folder>&folder, IMAPviewItem *parent , QListViewItem*after );
- IMAPfolderItem( const Opie::OSmartPointer<Folder>&folder, IMAPfolderItem *parent , QListViewItem*after, IMAPviewItem *master );
+ IMAPfolderItem( const Opie::Core::OSmartPointer<Folder>&folder, IMAPviewItem *parent , QListViewItem*after );
+ IMAPfolderItem( const Opie::Core::OSmartPointer<Folder>&folder, IMAPfolderItem *parent , QListViewItem*after, IMAPviewItem *master );
virtual ~IMAPfolderItem();
- virtual void refresh(QValueList<Opie::OSmartPointer<RecMail> >&);
- virtual RecBody fetchBody(const Opie::OSmartPointer<RecMail>&);
+ virtual void refresh(QValueList<Opie::Core::OSmartPointer<RecMail> >&);
+ virtual RecBody fetchBody(const Opie::Core::OSmartPointer<RecMail>&);
virtual QPopupMenu * getContextMenu();
virtual void contextMenuSelected(int);
virtual const QString& Delemiter()const;
protected:
virtual void createNewFolder();
virtual void deleteFolder();
virtual void downloadMails();
IMAPviewItem *imap;
@@ -164,18 +164,18 @@ protected:
class MHviewItem : public AccountViewItem
{
friend class MHfolderItem;
public:
MHviewItem( const QString&aMboxPath, AccountView *parent );
virtual ~MHviewItem();
- virtual void refresh(QValueList<Opie::OSmartPointer<RecMail> >&target );
- virtual RecBody fetchBody( const Opie::OSmartPointer<RecMail> &mail );
+ virtual void refresh(QValueList<Opie::Core::OSmartPointer<RecMail> >&target );
+ virtual RecBody fetchBody( const Opie::Core::OSmartPointer<RecMail> &mail );
AbstractMail *getWrapper();
virtual QPopupMenu * getContextMenu();
virtual void contextMenuSelected(int);
QStringList subFolders();
virtual void refresh(bool force=false);
protected:
void downloadMails();
@@ -184,24 +184,24 @@ protected:
AbstractMail *wrapper;
QStringList currentFolders;
};
class MHfolderItem : public AccountViewItem
{
public:
- MHfolderItem( const Opie::OSmartPointer<Folder>&folder, MHviewItem *parent , QListViewItem*after );
- MHfolderItem( const Opie::OSmartPointer<Folder>&folder, MHfolderItem *parent, QListViewItem*after, MHviewItem*master);
+ MHfolderItem( const Opie::Core::OSmartPointer<Folder>&folder, MHviewItem *parent , QListViewItem*after );
+ MHfolderItem( const Opie::Core::OSmartPointer<Folder>&folder, MHfolderItem *parent, QListViewItem*after, MHviewItem*master);
virtual ~MHfolderItem();
- virtual void refresh(QValueList<Opie::OSmartPointer<RecMail> >&);
- virtual RecBody fetchBody(const Opie::OSmartPointer<RecMail>&);
+ virtual void refresh(QValueList<Opie::Core::OSmartPointer<RecMail> >&);
+ virtual RecBody fetchBody(const Opie::Core::OSmartPointer<RecMail>&);
virtual QPopupMenu * getContextMenu();
virtual void contextMenuSelected(int);
- virtual const Opie::OSmartPointer<Folder>&getFolder()const;
+ virtual const Opie::Core::OSmartPointer<Folder>&getFolder()const;
virtual bool isDraftfolder();
protected:
void downloadMails();
virtual void createFolder();
virtual void deleteFolder();
void initName();
MHviewItem *mbox;
diff --git a/noncore/net/mail/accountview.cpp b/noncore/net/mail/accountview.cpp
index 26107ff..811e57a 100644
--- a/noncore/net/mail/accountview.cpp
+++ b/noncore/net/mail/accountview.cpp
@@ -9,16 +9,17 @@
#include <libmailwrapper/mailtypes.h>
#include <libmailwrapper/abstractmail.h>
#include <qpe/qpeapplication.h>
/* QT */
#include <qmessagebox.h>
#include <qpopupmenu.h>
+using namespace Opie::Core;
AccountView::AccountView( QWidget *parent, const char *name, WFlags flags )
: QListView( parent, name, flags )
{
connect( this, SIGNAL( selectionChanged(QListViewItem*) ),
SLOT( refresh(QListViewItem*) ) );
connect( this, SIGNAL( mouseButtonPressed(int,QListViewItem*,const QPoint&,int) ),this,
SLOT( slotHold(int,QListViewItem*,const QPoint&,int) ) );
setSorting(0);
diff --git a/noncore/net/mail/accountview.h b/noncore/net/mail/accountview.h
index d236058..b082b1f 100644
--- a/noncore/net/mail/accountview.h
+++ b/noncore/net/mail/accountview.h
@@ -16,18 +16,18 @@ class MHviewItem;
class AccountView : public QListView
{
Q_OBJECT
public:
AccountView( QWidget *parent = 0, const char *name = 0, WFlags flags = 0 );
virtual ~AccountView();
virtual void populate( QList<Account> list );
- virtual RecBody fetchBody(const Opie::OSmartPointer<RecMail>&aMail);
- virtual void downloadMails(const Opie::OSmartPointer<Folder>&fromFolder,AbstractMail*fromWrapper);
+ virtual RecBody fetchBody(const Opie::Core::OSmartPointer<RecMail>&aMail);
+ virtual void downloadMails(const Opie::Core::OSmartPointer<Folder>&fromFolder,AbstractMail*fromWrapper);
virtual bool currentisDraft();
public slots:
virtual void refreshAll();
virtual void refresh(QListViewItem *item);
virtual void refreshCurrent();
virtual void slotHold(int, QListViewItem *,const QPoint&,int);
virtual void slotContextMenu(int id);
diff --git a/noncore/net/mail/composemail.cpp b/noncore/net/mail/composemail.cpp
index 74ccc7b..5bc2883 100644
--- a/noncore/net/mail/composemail.cpp
+++ b/noncore/net/mail/composemail.cpp
@@ -8,16 +8,18 @@
#include "composemail.h"
#include <libmailwrapper/smtpwrapper.h>
#include <libmailwrapper/storemail.h>
#include <libmailwrapper/abstractmail.h>
#include <libmailwrapper/mailtypes.h>
+using namespace Opie::Core;
+using namespace Opie::Ui;
ComposeMail::ComposeMail( Settings *s, QWidget *parent, const char *name, bool modal, WFlags flags )
: ComposeMailUI( parent, name, modal, flags )
{
settings = s;
m_replyid = "";
QString vfilename = Global::applicationFileName("addressbook",
"businesscard.vcf");
@@ -155,17 +157,17 @@ void ComposeMail::slotAdjustColumns()
attList->setColumnWidth( 0, attList->visibleWidth() - 80 );
attList->setColumnWidth( 1, 80 );
tabWidget->setCurrentPage( currPage );
}
void ComposeMail::addAttachment()
{
- DocLnk lnk = Opie::OFileDialog::getOpenFileName( 1, "/" );
+ DocLnk lnk = OFileDialog::getOpenFileName( 1, "/" );
if ( !lnk.name().isEmpty() ) {
Attachment *att = new Attachment( lnk );
(void) new AttachViewItem( attList, att );
}
}
void ComposeMail::removeAttachment()
{
@@ -183,17 +185,17 @@ void ComposeMail::accept()
if ( checkBoxLater->isChecked() ) {
qDebug( "Send later" );
}
#if 0
qDebug( "Sending Mail with " +
smtpAccounts.at( smtpAccountBox->currentItem() )->getAccountName() );
#endif
- Opie::OSmartPointer<Mail> mail=new Mail;
+ Opie::Core::OSmartPointer<Mail> mail=new Mail;
SMTPaccount *smtp = smtpAccounts.at( smtpAccountBox->currentItem() );
mail->setMail(fromBox->currentText());
if ( !toLine->text().isEmpty() ) {
mail->setTo( toLine->text() );
} else {
QMessageBox::warning(0,tr("Sending mail"),
@@ -231,17 +233,17 @@ void ComposeMail::accept()
void ComposeMail::reject()
{
int yesno = QMessageBox::warning(0,tr("Store message"),
tr("Store message into drafts?"),
tr("Yes"),
tr("No"),QString::null,0,1);
if (yesno == 0) {
- Opie::OSmartPointer<Mail> mail=new Mail();
+ 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()) {
diff --git a/noncore/net/mail/composemail.h b/noncore/net/mail/composemail.h
index c12eb30..4693927 100644
--- a/noncore/net/mail/composemail.h
+++ b/noncore/net/mail/composemail.h
@@ -32,17 +32,17 @@ class RecMail;
class ComposeMail : public ComposeMailUI
{
Q_OBJECT
public:
ComposeMail( Settings *s, QWidget *parent = 0, const char *name = 0, bool modal = false, WFlags flags = 0 );
virtual ~ComposeMail();
- void reEditMail(const Opie::OSmartPointer<RecMail>&current);
+ void reEditMail(const Opie::Core::OSmartPointer<RecMail>&current);
public slots:
void slotAdjustColumns();
void setTo( const QString & to );
void setSubject( const QString & subject );
void setInReplyTo( const QString & messageId );
void setMessage( const QString & text );
diff --git a/noncore/net/mail/libmailwrapper/abstractmail.cpp b/noncore/net/mail/libmailwrapper/abstractmail.cpp
index 68a7a4d..6bebb7b 100644
--- a/noncore/net/mail/libmailwrapper/abstractmail.cpp
+++ b/noncore/net/mail/libmailwrapper/abstractmail.cpp
@@ -6,16 +6,17 @@
#include "mailtypes.h"
#include <qfile.h>
#include <qtextstream.h>
#include <stdlib.h>
#include <libetpan/mailmime_content.h>
#include <libetpan/mailmime.h>
+using namespace Opie::Core;
AbstractMail* AbstractMail::getWrapper(IMAPaccount *a)
{
return new IMAPwrapper(a);
}
AbstractMail* AbstractMail::getWrapper(POP3account *a)
{
return new POP3wrapper(a);
@@ -124,17 +125,17 @@ QString AbstractMail::defaultLocalfolder()
}
QString AbstractMail::draftFolder()
{
return QString("Drafts");
}
/* temporary - will be removed when implemented in all classes */
-void AbstractMail::deleteMails(const QString &,const QValueList<Opie::OSmartPointer<RecMail> > &)
+void AbstractMail::deleteMails(const QString &,const QValueList<Opie::Core::OSmartPointer<RecMail> > &)
{
}
void AbstractMail::mvcpAllMails(const FolderP&fromFolder,
const QString&targetFolder,AbstractMail*targetWrapper,bool moveit)
{
QValueList<RecMailP> t;
listMessages(fromFolder->getName(),t);
diff --git a/noncore/net/mail/libmailwrapper/abstractmail.h b/noncore/net/mail/libmailwrapper/abstractmail.h
index b03d757..2d55c83 100644
--- a/noncore/net/mail/libmailwrapper/abstractmail.h
+++ b/noncore/net/mail/libmailwrapper/abstractmail.h
@@ -16,43 +16,43 @@ class encodedString;
struct folderStat;
class AbstractMail:public QObject
{
Q_OBJECT
public:
AbstractMail(){};
virtual ~AbstractMail(){}
- virtual QValueList<Opie::OSmartPointer<Folder> >* listFolders()=0;
+ virtual QValueList<Opie::Core::OSmartPointer<Folder> >* listFolders()=0;
virtual void listMessages(const QString & mailbox,QValueList<RecMailP>&target )=0;
virtual void statusFolder(folderStat&target_stat,const QString & mailbox="INBOX")=0;
virtual RecBody fetchBody(const RecMailP&mail)=0;
virtual QString fetchTextPart(const RecMailP&mail,const RecPart&part)=0;
virtual encodedString* fetchDecodedPart(const RecMailP&mail,const RecPart&part)=0;
virtual encodedString* fetchRawPart(const RecMailP&mail,const RecPart&part)=0;
virtual encodedString* fetchRawBody(const RecMailP&mail)=0;
virtual void deleteMail(const RecMailP&mail)=0;
virtual void answeredMail(const RecMailP&mail)=0;
- virtual int deleteAllMail(const Opie::OSmartPointer<Folder>&)=0;
- virtual void deleteMails(const QString & FolderName,const QValueList<Opie::OSmartPointer<RecMail> >&target);
- virtual int deleteMbox(const Opie::OSmartPointer<Folder>&)=0;
+ virtual int deleteAllMail(const Opie::Core::OSmartPointer<Folder>&)=0;
+ virtual void deleteMails(const QString & FolderName,const QValueList<Opie::Core::OSmartPointer<RecMail> >&target);
+ virtual int deleteMbox(const Opie::Core::OSmartPointer<Folder>&)=0;
virtual void storeMessage(const char*msg,size_t length, const QString&folder)=0;
- virtual void mvcpAllMails(const Opie::OSmartPointer<Folder>&fromFolder,
+ virtual void mvcpAllMails(const Opie::Core::OSmartPointer<Folder>&fromFolder,
const QString&targetFolder,AbstractMail*targetWrapper,bool moveit);
virtual void mvcpMail(const RecMailP&mail,const QString&targetFolder,AbstractMail*targetWrapper,bool moveit);
virtual void cleanMimeCache(){};
/* mail box methods */
/* parameter is the box to create.
* if the implementing subclass has prefixes,
* them has to be appended automatic.
*/
- virtual int createMbox(const QString&,const Opie::OSmartPointer<Folder>&parentfolder=0,
+ virtual int createMbox(const QString&,const Opie::Core::OSmartPointer<Folder>&parentfolder=0,
const QString& delemiter="/",bool getsubfolder=false);
virtual void logout()=0;
static AbstractMail* getWrapper(IMAPaccount *a);
static AbstractMail* getWrapper(POP3account *a);
static AbstractMail* getWrapper(NNTPaccount *a);
/* mbox only! */
static AbstractMail* getWrapper(const QString&a,const QString&name="Local Folders");
diff --git a/noncore/net/mail/libmailwrapper/generatemail.cpp b/noncore/net/mail/libmailwrapper/generatemail.cpp
index cb7ccc0..cb58d82 100644
--- a/noncore/net/mail/libmailwrapper/generatemail.cpp
+++ b/noncore/net/mail/libmailwrapper/generatemail.cpp
@@ -1,15 +1,16 @@
#include "generatemail.h"
#include "mailwrapper.h"
#include <libetpan/libetpan.h>
#include <qt.h>
+using namespace Opie::Core;
const char* Generatemail::USER_AGENT="OpieMail v0.6";
Generatemail::Generatemail()
{
}
Generatemail::~Generatemail()
{
@@ -274,17 +275,17 @@ err_free:
return NULL; // Error :(
}
mailimf_mailbox *Generatemail::newMailbox(const QString&name, const QString&mail ) {
return mailimf_mailbox_new( strdup( name.latin1() ),
strdup( mail.latin1() ) );
}
-mailimf_fields *Generatemail::createImfFields(const Opie::OSmartPointer<Mail>&mail )
+mailimf_fields *Generatemail::createImfFields(const Opie::Core::OSmartPointer<Mail>&mail )
{
mailimf_fields *fields = NULL;
mailimf_field *xmailer = NULL;
mailimf_mailbox *sender=0,*fromBox=0;
mailimf_mailbox_list *from=0;
mailimf_address_list *to=0, *cc=0, *bcc=0, *reply=0;
clist*in_reply_to = 0;
char *subject = strdup( mail->getSubject().latin1() );
@@ -394,17 +395,17 @@ mailimf_fields *Generatemail::createImfFields(const Opie::OSmartPointer<Mail>&ma
if (subject) {
free( subject );
}
}
}
return fields;
}
-mailmime *Generatemail::createMimeMail(const Opie::OSmartPointer<Mail> &mail ) {
+mailmime *Generatemail::createMimeMail(const Opie::Core::OSmartPointer<Mail> &mail ) {
mailmime *message, *txtPart;
mailimf_fields *fields;
int err;
fields = createImfFields( mail );
if ( fields == NULL )
goto err_free;
diff --git a/noncore/net/mail/libmailwrapper/generatemail.h b/noncore/net/mail/libmailwrapper/generatemail.h
index c246a2a..a767b61 100644
--- a/noncore/net/mail/libmailwrapper/generatemail.h
+++ b/noncore/net/mail/libmailwrapper/generatemail.h
@@ -31,16 +31,16 @@ protected:
static char *getFrom( mailmime *mail );
static char *getFrom( mailimf_field *ffrom);
static mailimf_field *getField( mailimf_fields *fields, int type );
mailimf_address_list *parseAddresses(const QString&addr );
void addFileParts( mailmime *message,const QList<Attachment>&files );
mailmime *buildFilePart(const QString&filename,const QString&mimetype,const QString&content);
mailmime *buildTxtPart(const QString&str );
mailimf_mailbox *newMailbox(const QString&name,const QString&mail );
- mailimf_fields *createImfFields(const Opie::OSmartPointer<Mail> &mail );
- mailmime *createMimeMail(const Opie::OSmartPointer<Mail>&mail );
+ mailimf_fields *createImfFields(const Opie::Core::OSmartPointer<Mail> &mail );
+ mailmime *createMimeMail(const Opie::Core::OSmartPointer<Mail>&mail );
clist *createRcptList( mailimf_fields *fields );
static const char* USER_AGENT;
};
#endif
diff --git a/noncore/net/mail/libmailwrapper/genericwrapper.cpp b/noncore/net/mail/libmailwrapper/genericwrapper.cpp
index ee2c8cd..f428415 100644
--- a/noncore/net/mail/libmailwrapper/genericwrapper.cpp
+++ b/noncore/net/mail/libmailwrapper/genericwrapper.cpp
@@ -1,12 +1,13 @@
#include "genericwrapper.h"
#include <libetpan/libetpan.h>
#include "mailtypes.h"
+using namespace Opie::Core;
Genericwrapper::Genericwrapper()
: AbstractMail()
{
bodyCache.clear();
m_storage = 0;
m_folder = 0;
}
@@ -382,17 +383,17 @@ QStringList Genericwrapper::parseInreplies(mailimf_in_reply_to * in_replies)
}
if (h.length()>0) {
res.append(h);
}
}
return res;
}
-void Genericwrapper::parseList(QValueList<Opie::OSmartPointer<RecMail> > &target,mailsession*session,const QString&mailbox,bool mbox_as_to)
+void Genericwrapper::parseList(QValueList<Opie::Core::OSmartPointer<RecMail> > &target,mailsession*session,const QString&mailbox,bool mbox_as_to)
{
int r;
mailmessage_list * env_list = 0;
r = mailsession_get_messages_list(session,&env_list);
if (r != MAIL_NO_ERROR) {
qDebug("Error message list");
return;
}
diff --git a/noncore/net/mail/libmailwrapper/genericwrapper.h b/noncore/net/mail/libmailwrapper/genericwrapper.h
index f9968d1..f5b9504 100644
--- a/noncore/net/mail/libmailwrapper/genericwrapper.h
+++ b/noncore/net/mail/libmailwrapper/genericwrapper.h
@@ -33,33 +33,33 @@ class Genericwrapper : public AbstractMail
public:
Genericwrapper();
virtual ~Genericwrapper();
virtual encodedString* fetchDecodedPart(const RecMailP&mail,const RecPart&part);
virtual encodedString* fetchRawPart(const RecMailP&mail,const RecPart&part);
virtual QString fetchTextPart(const RecMailP&mail,const RecPart&part);
virtual void cleanMimeCache();
- virtual int deleteMbox(const Opie::OSmartPointer<Folder>&){return 1;}
+ virtual int deleteMbox(const Opie::Core::OSmartPointer<Folder>&){return 1;}
virtual void logout(){};
virtual void storeMessage(const char*msg,size_t length, const QString&folder){};
protected:
RecBody parseMail( mailmessage * msg );
QString parseMailboxList( mailimf_mailbox_list *list );
QString parseMailbox( mailimf_mailbox *box );
QString parseGroup( mailimf_group *group );
QString parseAddressList( mailimf_address_list *list );
QString parseDateTime( mailimf_date_time *date );
void traverseBody(RecBody&target,mailmessage*message,mailmime*mime,QValueList<int>recList,unsigned int current_rek=0,int current_count=1);
static void fillSingleBody(RecPart&target,mailmessage*message,mailmime*mime);
static void fillParameters(RecPart&target,clist*parameters);
static QString getencoding(mailmime_mechanism*aEnc);
- virtual void parseList(QValueList<Opie::OSmartPointer<RecMail> > &target,mailsession*session,const QString&mailbox,bool mbox_as_to=false);
+ virtual void parseList(QValueList<Opie::Core::OSmartPointer<RecMail> > &target,mailsession*session,const QString&mailbox,bool mbox_as_to=false);
QStringList parseInreplies(mailimf_in_reply_to * in_replies);
QString msgTempName;
unsigned int last_msg_id;
QMap<QString,encodedString*> bodyCache;
mailstorage * m_storage;
mailfolder*m_folder;
};
diff --git a/noncore/net/mail/libmailwrapper/imapwrapper.cpp b/noncore/net/mail/libmailwrapper/imapwrapper.cpp
index 071e734..56e7df9 100644
--- a/noncore/net/mail/libmailwrapper/imapwrapper.cpp
+++ b/noncore/net/mail/libmailwrapper/imapwrapper.cpp
@@ -1,16 +1,17 @@
#include <stdlib.h>
#include <libetpan/libetpan.h>
#include <qpe/global.h>
#include "imapwrapper.h"
#include "mailtypes.h"
#include "logindialog.h"
+using namespace Opie::Core;
IMAPwrapper::IMAPwrapper( IMAPaccount *a )
: AbstractMail()
{
account = a;
m_imap = 0;
m_Lastmbox = "";
}
@@ -200,17 +201,17 @@ void IMAPwrapper::logout()
if (!m_imap) return;
err = mailimap_logout( m_imap );
err = mailimap_close( m_imap );
mailimap_free( m_imap );
m_imap = 0;
m_Lastmbox = "";
}
-void IMAPwrapper::listMessages(const QString&mailbox,QValueList<Opie::OSmartPointer<RecMail> > &target )
+void IMAPwrapper::listMessages(const QString&mailbox,QValueList<Opie::Core::OSmartPointer<RecMail> > &target )
{
int err = MAILIMAP_NO_ERROR;
clist *result = 0;
clistcell *current;
mailimap_fetch_type *fetchType = 0;
mailimap_set *set = 0;
login();
@@ -261,17 +262,17 @@ void IMAPwrapper::listMessages(const QString&mailbox,QValueList<Opie::OSmartPoin
}
Global::statusMessage(tr("Mailbox has %1 mails").arg(target.count()));
} else {
Global::statusMessage(tr("Error fetching headers: %1").arg(m_imap->imap_response));
}
if (result) mailimap_fetch_list_free(result);
}
-QValueList<Opie::OSmartPointer<Folder> >* IMAPwrapper::listFolders()
+QValueList<Opie::Core::OSmartPointer<Folder> >* IMAPwrapper::listFolders()
{
const char *path, *mask;
int err = MAILIMAP_NO_ERROR;
clist *result = 0;
clistcell *current = 0;
clistcell*cur_flag = 0;
mailimap_mbx_list_flags*bflags = 0;
diff --git a/noncore/net/mail/libmailwrapper/imapwrapper.h b/noncore/net/mail/libmailwrapper/imapwrapper.h
index 3bd5967..7448acb 100644
--- a/noncore/net/mail/libmailwrapper/imapwrapper.h
+++ b/noncore/net/mail/libmailwrapper/imapwrapper.h
@@ -18,37 +18,37 @@ struct mailimap_msg_att;
class encodedString;
class IMAPwrapper : public AbstractMail
{
Q_OBJECT
public:
IMAPwrapper( IMAPaccount *a );
virtual ~IMAPwrapper();
- virtual QValueList<Opie::OSmartPointer<Folder> >* listFolders();
- virtual void listMessages(const QString & mailbox,QValueList<Opie::OSmartPointer<RecMail> >&target );
+ virtual QValueList<Opie::Core::OSmartPointer<Folder> >* listFolders();
+ virtual void listMessages(const QString & mailbox,QValueList<Opie::Core::OSmartPointer<RecMail> >&target );
virtual void statusFolder(folderStat&target_stat,const QString & mailbox="INBOX");
virtual void deleteMail(const RecMailP&mail);
virtual void answeredMail(const RecMailP&mail);
- virtual int deleteAllMail(const Opie::OSmartPointer<Folder>&folder);
+ virtual int deleteAllMail(const Opie::Core::OSmartPointer<Folder>&folder);
virtual void storeMessage(const char*msg,size_t length, const QString&folder);
- virtual void mvcpAllMails(const Opie::OSmartPointer<Folder>&fromFolder,
+ virtual void mvcpAllMails(const Opie::Core::OSmartPointer<Folder>&fromFolder,
const QString&targetFolder,AbstractMail*targetWrapper,bool moveit);
virtual void mvcpMail(const RecMailP&mail,const QString&targetFolder,AbstractMail*targetWrapper,bool moveit);
virtual RecBody fetchBody(const RecMailP&mail);
virtual QString fetchTextPart(const RecMailP&mail,const RecPart&part);
virtual encodedString* fetchDecodedPart(const RecMailP&mail,const RecPart&part);
virtual encodedString* fetchRawPart(const RecMailP&mail,const RecPart&part);
virtual encodedString* fetchRawBody(const RecMailP&mail);
- virtual int createMbox(const QString&,const Opie::OSmartPointer<Folder>&parentfolder=0,
+ virtual int createMbox(const QString&,const Opie::Core::OSmartPointer<Folder>&parentfolder=0,
const QString& delemiter="/",bool getsubfolder=false);
- virtual int deleteMbox(const Opie::OSmartPointer<Folder>&folder);
+ virtual int deleteMbox(const Opie::Core::OSmartPointer<Folder>&folder);
static void imap_progress( size_t current, size_t maximum );
virtual void logout();
virtual MAILLIB::ATYPE getType()const;
virtual const QString&getName()const;
protected:
diff --git a/noncore/net/mail/libmailwrapper/mailtypes.cpp b/noncore/net/mail/libmailwrapper/mailtypes.cpp
index 7dd7e58..fd91fe5 100644
--- a/noncore/net/mail/libmailwrapper/mailtypes.cpp
+++ b/noncore/net/mail/libmailwrapper/mailtypes.cpp
@@ -1,19 +1,20 @@
#include "mailtypes.h"
#include <stdlib.h>
+using namespace Opie::Core;
RecMail::RecMail()
- :Opie::ORefCount(),subject(""),date(""),from(""),mbox(""),msg_id(""),msg_number(0),msg_size(0),msg_flags(7)
+ :Opie::Core::ORefCount(),subject(""),date(""),from(""),mbox(""),msg_id(""),msg_number(0),msg_size(0),msg_flags(7)
{
init();
}
RecMail::RecMail(const RecMail&old)
- :Opie::ORefCount(),subject(""),date(""),from(""),mbox(""),msg_id(""),msg_number(0),msg_flags(7)
+ :Opie::Core::ORefCount(),subject(""),date(""),from(""),mbox(""),msg_id(""),msg_number(0),msg_flags(7)
{
init();
copy_old(old);
qDebug("Copy constructor RecMail");
}
RecMail::~RecMail()
{
diff --git a/noncore/net/mail/libmailwrapper/mailtypes.h b/noncore/net/mail/libmailwrapper/mailtypes.h
index dc10de6..941556a 100644
--- a/noncore/net/mail/libmailwrapper/mailtypes.h
+++ b/noncore/net/mail/libmailwrapper/mailtypes.h
@@ -24,17 +24,17 @@ class AbstractMail;
But: not from the point of view of the device.
Mailbodies can be real large. So we request them when
needed from the mail-wrapper class direct from the server itself
(imap) or from a file-based cache (pop3?)
So there is no interface "const QString&body()" but you should
make a request to the mailwrapper with this class as parameter to
get the body. Same words for the attachments.
*/
-class RecMail:public Opie::ORefCount
+class RecMail:public Opie::Core::ORefCount
{
public:
RecMail();
RecMail(const RecMail&old);
virtual ~RecMail();
const unsigned int getNumber()const{return msg_number;}
void setNumber(unsigned int number){msg_number=number;}
@@ -76,17 +76,17 @@ protected:
unsigned int msg_number,msg_size;
QBitArray msg_flags;
QStringList to,cc,bcc,in_reply_to,references;
AbstractMail*wrapper;
void init();
void copy_old(const RecMail&old);
};
-typedef Opie::OSmartPointer<RecMail> RecMailP;
+typedef Opie::Core::OSmartPointer<RecMail> RecMailP;
typedef QMap<QString,QString> part_plist_t;
class RecPart
{
protected:
QString m_type,m_subtype,m_identifier,m_encoding,m_description;
unsigned int m_lines,m_size;
part_plist_t m_Parameters;
diff --git a/noncore/net/mail/libmailwrapper/mailwrapper.cpp b/noncore/net/mail/libmailwrapper/mailwrapper.cpp
index 9bf2fd3..eddc0b9 100644
--- a/noncore/net/mail/libmailwrapper/mailwrapper.cpp
+++ b/noncore/net/mail/libmailwrapper/mailwrapper.cpp
@@ -16,16 +16,17 @@
#define UTF16SHIFT 10
#define UTF16BASE 0x10000UL
#define UTF16HIGHSTART 0xD800UL
#define UTF16HIGHEND 0xDBFFUL
#define UTF16LOSTART 0xDC00UL
#define UTF16LOEND 0xDFFFUL
+using namespace Opie::Core;
Attachment::Attachment( DocLnk lnk )
{
doc = lnk;
size = QFileInfo( doc.file() ).size();
}
Folder::Folder(const QString&tmp_name, const QString&sep )
{
@@ -150,17 +151,17 @@ QString IMAPFolder::decodeFolderName( const QString &name )
++srcPtr;
}
}
return QString::fromUtf8( dst.data() );
}
Mail::Mail()
- :Opie::ORefCount(),name(""), mail(""), to(""), cc(""), bcc(""), reply(""), subject(""), message("")
+ :Opie::Core::ORefCount(),name(""), mail(""), to(""), cc(""), bcc(""), reply(""), subject(""), message("")
{
}
MHFolder::MHFolder(const QString&disp_name,const QString&mbox)
: Folder( disp_name,"/" )
{
separator = "/";
name = mbox;
diff --git a/noncore/net/mail/libmailwrapper/mailwrapper.h b/noncore/net/mail/libmailwrapper/mailwrapper.h
index 6bf0078..542de03 100644
--- a/noncore/net/mail/libmailwrapper/mailwrapper.h
+++ b/noncore/net/mail/libmailwrapper/mailwrapper.h
@@ -23,17 +23,17 @@ public:
DocLnk getDocLnk() { return doc; }
protected:
DocLnk doc;
int size;
};
-class Mail:public Opie::ORefCount
+class Mail:public Opie::Core::ORefCount
{
public:
Mail();
/* Possible that this destructor must not be declared virtual
* 'cause it seems that it will never have some child classes.
* in this case this object will not get a virtual table -> memory and
* speed will be a little bit better?
*/
@@ -61,33 +61,33 @@ public:
const QStringList&Inreply()const{return m_in_reply_to;}
private:
QList<Attachment> attList;
QString name, mail, to, cc, bcc, reply, subject, message;
QStringList m_in_reply_to;
};
-class Folder:public Opie::ORefCount
+class Folder:public Opie::Core::ORefCount
{
public:
Folder( const QString&init_name,const QString&sep );
virtual ~Folder();
const QString&getDisplayName()const { return nameDisplay; }
const QString&getName()const { return name; }
const QString&getPrefix()const{return prefix; }
virtual bool may_select()const{return true;}
virtual bool no_inferior()const{return true;}
const QString&Separator()const;
protected:
QString nameDisplay, name, separator,prefix;
};
-typedef Opie::OSmartPointer<Folder> FolderP;
+typedef Opie::Core::OSmartPointer<Folder> FolderP;
class MHFolder : public Folder
{
public:
MHFolder(const QString&disp_name,const QString&mbox);
virtual ~MHFolder();
};
diff --git a/noncore/net/mail/libmailwrapper/mboxwrapper.cpp b/noncore/net/mail/libmailwrapper/mboxwrapper.cpp
index 5e6b714..4aee0be 100644
--- a/noncore/net/mail/libmailwrapper/mboxwrapper.cpp
+++ b/noncore/net/mail/libmailwrapper/mboxwrapper.cpp
@@ -1,16 +1,17 @@
#include "mboxwrapper.h"
#include "mailtypes.h"
#include "mailwrapper.h"
#include <libetpan/libetpan.h>
#include <qdir.h>
#include <stdlib.h>
#include <qpe/global.h>
+using namespace Opie::Core;
MBOXwrapper::MBOXwrapper(const QString & mbox_dir,const QString&mbox_name)
: Genericwrapper(),MBOXPath(mbox_dir),MBOXName(mbox_name)
{
QDir dir(MBOXPath);
if (!dir.exists()) {
dir.mkdir(MBOXPath);
}
}
@@ -39,19 +40,19 @@ void MBOXwrapper::listMessages(const QString & mailbox, QValueList<RecMailP> &ta
parseList(target,folder->fld_session,mailbox);
mailfolder_disconnect(folder);
mailfolder_free(folder);
mailstorage_free(storage);
Global::statusMessage(tr("Mailbox has %1 mail(s)").arg(target.count()));
}
-QValueList<Opie::OSmartPointer<Folder> >* MBOXwrapper::listFolders()
+QValueList<Opie::Core::OSmartPointer<Folder> >* MBOXwrapper::listFolders()
{
- QValueList<Opie::OSmartPointer<Folder> >* folders = new QValueList<Opie::OSmartPointer<Folder> >();
+ QValueList<Opie::Core::OSmartPointer<Folder> >* folders = new QValueList<Opie::Core::OSmartPointer<Folder> >();
QDir dir(MBOXPath);
if (!dir.exists()) return folders;
dir.setFilter(QDir::Files|QDir::Writable|QDir::Readable);
QStringList entries = dir.entryList();
QStringList::ConstIterator it = entries.begin();
for (;it!=entries.end();++it) {
FolderP inb=new Folder(*it,"/");
folders->append(inb);
diff --git a/noncore/net/mail/libmailwrapper/mboxwrapper.h b/noncore/net/mail/libmailwrapper/mboxwrapper.h
index 33eeb1e..a2ecfee 100644
--- a/noncore/net/mail/libmailwrapper/mboxwrapper.h
+++ b/noncore/net/mail/libmailwrapper/mboxwrapper.h
@@ -11,34 +11,34 @@ class MBOXwrapper : public Genericwrapper
{
Q_OBJECT
public:
MBOXwrapper(const QString & dir,const QString&name);
virtual ~MBOXwrapper();
virtual void listMessages(const QString & mailbox, QValueList<RecMailP>&target );
- virtual QValueList<Opie::OSmartPointer<Folder> >* listFolders();
+ virtual QValueList<Opie::Core::OSmartPointer<Folder> >* listFolders();
virtual void statusFolder(folderStat&target_stat,const QString & mailbox="INBOX");
virtual void deleteMail(const RecMailP&mail);
virtual void answeredMail(const RecMailP&mail);
- virtual int createMbox(const QString&folder,const Opie::OSmartPointer<Folder>&f=0,
+ virtual int createMbox(const QString&folder,const Opie::Core::OSmartPointer<Folder>&f=0,
const QString&d="",bool s=false);
- virtual int deleteMbox(const Opie::OSmartPointer<Folder>&);
+ virtual int deleteMbox(const Opie::Core::OSmartPointer<Folder>&);
virtual void storeMessage(const char*msg,size_t length, const QString&folder);
virtual RecBody fetchBody( const RecMailP &mail );
static void mbox_progress( size_t current, size_t maximum );
virtual encodedString* fetchRawBody(const RecMailP&mail);
virtual void deleteMails(const QString & FolderName,const QValueList<RecMailP> &target);
- virtual int deleteAllMail(const Opie::OSmartPointer<Folder>&);
+ virtual int deleteAllMail(const Opie::Core::OSmartPointer<Folder>&);
virtual MAILLIB::ATYPE getType()const;
virtual const QString&getName()const;
protected:
static void deleteMails(mailmbox_folder*f,const QValueList<RecMailP> &target);
QString MBOXPath;
QString MBOXName;
};
diff --git a/noncore/net/mail/libmailwrapper/mhwrapper.cpp b/noncore/net/mail/libmailwrapper/mhwrapper.cpp
index 0b00a2e..21e24a0 100644
--- a/noncore/net/mail/libmailwrapper/mhwrapper.cpp
+++ b/noncore/net/mail/libmailwrapper/mhwrapper.cpp
@@ -3,16 +3,19 @@
#include "mailwrapper.h"
#include <libetpan/libetpan.h>
#include <qdir.h>
#include <qmessagebox.h>
#include <stdlib.h>
#include <qpe/global.h>
#include <opie2/oprocess.h>
+using namespace Opie::Core;
+using namespace Opie::Core;
+using namespace Opie::Core;
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);
@@ -55,35 +58,35 @@ void MHwrapper::clean_storage()
}
}
MHwrapper::~MHwrapper()
{
clean_storage();
}
-void MHwrapper::listMessages(const QString & mailbox, QValueList<Opie::OSmartPointer<RecMail> > &target )
+void MHwrapper::listMessages(const QString & mailbox, QValueList<Opie::Core::OSmartPointer<RecMail> > &target )
{
init_storage();
if (!m_storage) {
return;
}
QString f = buildPath(mailbox);
int r = mailsession_select_folder(m_storage->sto_session,(char*)f.latin1());
if (r!=MAIL_NO_ERROR) {
qDebug("listMessages: error selecting folder!");
return;
}
parseList(target,m_storage->sto_session,f);
Global::statusMessage(tr("Mailbox has %1 mail(s)").arg(target.count()));
}
-QValueList<Opie::OSmartPointer<Folder> >* MHwrapper::listFolders()
+QValueList<Opie::Core::OSmartPointer<Folder> >* MHwrapper::listFolders()
{
- QValueList<Opie::OSmartPointer<Folder> >* folders = new QValueList<Opie::OSmartPointer<Folder> >();
+ QValueList<Opie::Core::OSmartPointer<Folder> >* folders = new QValueList<Opie::Core::OSmartPointer<Folder> >();
/* this is needed! */
if (m_storage) mailstorage_disconnect(m_storage);
init_storage();
if (!m_storage) {
return folders;
}
mail_list*flist = 0;
clistcell*current=0;
@@ -312,19 +315,19 @@ int MHwrapper::deleteMbox(const FolderP&tfolder)
}
QString cmd = "rm -rf "+tfolder->getName();
QStringList command;
command << "/bin/sh";
command << "-c";
command << cmd.latin1();
OProcess *process = new OProcess();
- connect(process, SIGNAL(processExited(OProcess*)),
+ connect(process, SIGNAL(processExited(Opie::Core::OProcess*)),
this, SLOT( processEnded(OProcess*)));
- connect(process, SIGNAL( receivedStderr(OProcess*,char*,int)),
+ connect(process, SIGNAL( receivedStderr(Opie::Core::OProcess*,char*,int)),
this, SLOT( oprocessStderr(OProcess*,char*,int)));
*process << command;
removeMboxfailed = false;
if(!process->start(OProcess::Block, OProcess::All) ) {
qDebug("could not start process");
return 0;
}
diff --git a/noncore/net/mail/libmailwrapper/mhwrapper.h b/noncore/net/mail/libmailwrapper/mhwrapper.h
index 208cf2f..1245507 100644
--- a/noncore/net/mail/libmailwrapper/mhwrapper.h
+++ b/noncore/net/mail/libmailwrapper/mhwrapper.h
@@ -3,54 +3,54 @@
#include "maildefines.h"
#include "genericwrapper.h"
#include <qstring.h>
class encodedString;
struct mailmbox_folder;
-class OProcess;
+namespace Opie {namespace Core {class Opie::Core::OProcess;}}
class MHwrapper : public Genericwrapper
{
Q_OBJECT
public:
MHwrapper(const QString & dir,const QString&name);
virtual ~MHwrapper();
- virtual void listMessages(const QString & mailbox, QValueList<Opie::OSmartPointer<RecMail> > &target );
- virtual QValueList<Opie::OSmartPointer<Folder> >* listFolders();
+ virtual void listMessages(const QString & mailbox, QValueList<Opie::Core::OSmartPointer<RecMail> > &target );
+ virtual QValueList<Opie::Core::OSmartPointer<Folder> >* listFolders();
virtual void statusFolder(folderStat&target_stat,const QString & mailbox="INBOX");
virtual void deleteMail(const RecMailP&mail);
virtual void answeredMail(const RecMailP&mail);
virtual void mvcpMail(const RecMailP&mail,const QString&targetFolder,AbstractMail*targetWrapper,bool moveit);
- virtual void mvcpAllMails(const Opie::OSmartPointer<Folder>&fromFolder,
+ virtual void mvcpAllMails(const Opie::Core::OSmartPointer<Folder>&fromFolder,
const QString&targetFolder,AbstractMail*targetWrapper,bool moveit);
- virtual int createMbox(const QString&folder,const Opie::OSmartPointer<Folder>&f=0,
+ virtual int createMbox(const QString&folder,const Opie::Core::OSmartPointer<Folder>&f=0,
const QString&d="",bool s=false);
- virtual int deleteMbox(const Opie::OSmartPointer<Folder>&);
+ virtual int deleteMbox(const Opie::Core::OSmartPointer<Folder>&);
virtual void storeMessage(const char*msg,size_t length, const QString&folder);
virtual RecBody fetchBody( const RecMailP &mail );
static void mbox_progress( size_t current, size_t maximum );
virtual encodedString* fetchRawBody(const RecMailP&mail);
- virtual void deleteMails(const QString & FolderName,const QValueList<Opie::OSmartPointer<RecMail> > &target);
- virtual int deleteAllMail(const Opie::OSmartPointer<Folder>&);
+ virtual void deleteMails(const QString & FolderName,const QValueList<Opie::Core::OSmartPointer<RecMail> > &target);
+ virtual int deleteAllMail(const Opie::Core::OSmartPointer<Folder>&);
virtual MAILLIB::ATYPE getType()const;
virtual const QString&getName()const;
public slots:
/* for deleting maildirs we are using a system call */
- virtual void oprocessStderr(OProcess*, char *buffer, int );
- virtual void processEnded(OProcess *);
+ virtual void oprocessStderr(Opie::Core::OProcess*, char *buffer, int );
+ virtual void processEnded(Opie::Core::OProcess *);
protected:
QString buildPath(const QString&p);
QString MHPath;
QString MHName;
void init_storage();
void clean_storage();
diff --git a/noncore/net/mail/libmailwrapper/nntpwrapper.cpp b/noncore/net/mail/libmailwrapper/nntpwrapper.cpp
index c0b3eec..9de958d 100644
--- a/noncore/net/mail/libmailwrapper/nntpwrapper.cpp
+++ b/noncore/net/mail/libmailwrapper/nntpwrapper.cpp
@@ -6,16 +6,17 @@
#include <stdlib.h>
#include <libetpan/libetpan.h>
#define HARD_MSG_SIZE_LIMIT 5242880
+using namespace Opie::Core;
NNTPwrapper::NNTPwrapper( NNTPaccount *a )
: Genericwrapper() {
account = a;
m_nntp = NULL;
msgTempName = a->getFileName()+"_msg_cache";
last_msg_id = 0;
}
@@ -91,17 +92,17 @@ RecBody NNTPwrapper::fetchBody( const RecMailP &mail ) {
mailmessage_free(mailmsg);
if (message)
free(message);
return body;
}
-void NNTPwrapper::listMessages(const QString & which, QValueList<Opie::OSmartPointer<RecMail> > &target )
+void NNTPwrapper::listMessages(const QString & which, QValueList<Opie::Core::OSmartPointer<RecMail> > &target )
{
login();
if (!m_nntp)
return;
uint32_t res_messages,res_recent,res_unseen;
mailsession_status_folder(m_nntp->sto_session,(char*)which.latin1(),&res_messages,&res_recent,&res_unseen);
parseList(target,m_nntp->sto_session,which,true);
}
@@ -183,19 +184,19 @@ void NNTPwrapper::logout()
{
int err = NEWSNNTP_NO_ERROR;
if ( m_nntp == NULL )
return;
mailstorage_free(m_nntp);
m_nntp = 0;
}
-QValueList<Opie::OSmartPointer<Folder> >* NNTPwrapper::listFolders() {
+QValueList<Opie::Core::OSmartPointer<Folder> >* NNTPwrapper::listFolders() {
- QValueList<Opie::OSmartPointer<Folder> >* folders = new QValueList<Opie::OSmartPointer<Folder> >();
+ QValueList<Opie::Core::OSmartPointer<Folder> >* folders = new QValueList<Opie::Core::OSmartPointer<Folder> >();
QStringList groups;
if (account) {
groups = account->getGroups();
}
for ( QStringList::Iterator it = groups.begin(); it != groups.end(); ++it ) {
folders->append(new Folder((*it),"."));
}
return folders;
diff --git a/noncore/net/mail/libmailwrapper/nntpwrapper.h b/noncore/net/mail/libmailwrapper/nntpwrapper.h
index a7e4b95..a87a8e8 100644
--- a/noncore/net/mail/libmailwrapper/nntpwrapper.h
+++ b/noncore/net/mail/libmailwrapper/nntpwrapper.h
@@ -15,25 +15,25 @@ class NNTPwrapper : public Genericwrapper
Q_OBJECT
public:
NNTPwrapper( NNTPaccount *a );
virtual ~NNTPwrapper();
/* mailbox will be ignored */
- virtual void listMessages(const QString & mailbox, QValueList<Opie::OSmartPointer<RecMail> > &target );
+ virtual void listMessages(const QString & mailbox, QValueList<Opie::Core::OSmartPointer<RecMail> > &target );
/* should only get the subscribed one */
- virtual QValueList<Opie::OSmartPointer<Folder> >* listFolders();
+ virtual QValueList<Opie::Core::OSmartPointer<Folder> >* listFolders();
/* mailbox will be ignored */
virtual void statusFolder(folderStat&target_stat,const QString & mailbox="INBOX");
QStringList listAllNewsgroups(const QString&mask = QString::null);
virtual void deleteMail(const RecMailP&mail);
virtual void answeredMail(const RecMailP&mail);
- virtual int deleteAllMail(const Opie::OSmartPointer<Folder>&);
+ virtual int deleteAllMail(const Opie::Core::OSmartPointer<Folder>&);
virtual RecBody fetchBody( const RecMailP &mail );
virtual encodedString* fetchRawBody(const RecMailP&mail);
virtual void logout();
virtual MAILLIB::ATYPE getType()const;
virtual const QString&getName()const;
static void nntp_progress( size_t current, size_t maximum );
diff --git a/noncore/net/mail/libmailwrapper/pop3wrapper.cpp b/noncore/net/mail/libmailwrapper/pop3wrapper.cpp
index 6737d6c..f5694fe 100644
--- a/noncore/net/mail/libmailwrapper/pop3wrapper.cpp
+++ b/noncore/net/mail/libmailwrapper/pop3wrapper.cpp
@@ -5,16 +5,17 @@
#include <libetpan/libetpan.h>
#include <qpe/global.h>
#include <qfile.h>
//#include <qstring.h>
/* we don't fetch messages larger than 5 MB */
#define HARD_MSG_SIZE_LIMIT 5242880
+using namespace Opie::Core;
POP3wrapper::POP3wrapper( POP3account *a )
: Genericwrapper() {
account = a;
m_pop3 = NULL;
msgTempName = a->getFileName()+"_msg_cache";
last_msg_id = 0;
}
@@ -88,17 +89,17 @@ RecBody POP3wrapper::fetchBody( const RecMailP &mail ) {
if (mailmsg)
mailmessage_free(mailmsg);
if (message)
free(message);
return body;
}
-void POP3wrapper::listMessages(const QString &, QValueList<Opie::OSmartPointer<RecMail> > &target )
+void POP3wrapper::listMessages(const QString &, QValueList<Opie::Core::OSmartPointer<RecMail> > &target )
{
login();
if (!m_pop3)
return;
uint32_t res_messages,res_recent,res_unseen;
mailsession_status_folder(m_pop3->sto_session,"INBOX",&res_messages,&res_recent,&res_unseen);
parseList(target,m_pop3->sto_session,"INBOX");
Global::statusMessage( tr("Mailbox contains %1 mail(s)").arg(res_messages));
@@ -171,18 +172,18 @@ void POP3wrapper::logout()
{
if ( m_pop3 == NULL )
return;
mailstorage_free(m_pop3);
m_pop3 = 0;
}
-QValueList<Opie::OSmartPointer<Folder> >* POP3wrapper::listFolders() {
- QValueList<Opie::OSmartPointer<Folder> >* folders = new QValueList<FolderP>();
+QValueList<Opie::Core::OSmartPointer<Folder> >* POP3wrapper::listFolders() {
+ QValueList<Opie::Core::OSmartPointer<Folder> >* folders = new QValueList<FolderP>();
FolderP inb=new Folder("INBOX","/");
folders->append(inb);
return folders;
}
void POP3wrapper::deleteMail(const RecMailP&mail) {
login();
if (!m_pop3)
diff --git a/noncore/net/mail/libmailwrapper/pop3wrapper.h b/noncore/net/mail/libmailwrapper/pop3wrapper.h
index 31eb6f1..c46b941 100644
--- a/noncore/net/mail/libmailwrapper/pop3wrapper.h
+++ b/noncore/net/mail/libmailwrapper/pop3wrapper.h
@@ -12,24 +12,24 @@ struct mailfolder;
class POP3wrapper : public Genericwrapper
{
Q_OBJECT
public:
POP3wrapper( POP3account *a );
virtual ~POP3wrapper();
/* mailbox will be ignored */
- virtual void listMessages(const QString & mailbox, QValueList<Opie::OSmartPointer<RecMail> > &target );
- virtual QValueList<Opie::OSmartPointer<Folder> >* listFolders();
+ virtual void listMessages(const QString & mailbox, QValueList<Opie::Core::OSmartPointer<RecMail> > &target );
+ virtual QValueList<Opie::Core::OSmartPointer<Folder> >* listFolders();
/* mailbox will be ignored */
virtual void statusFolder(folderStat&target_stat,const QString & mailbox="INBOX");
virtual void deleteMail(const RecMailP&mail);
virtual void answeredMail(const RecMailP&mail);
- virtual int deleteAllMail(const Opie::OSmartPointer<Folder>&);
+ virtual int deleteAllMail(const Opie::Core::OSmartPointer<Folder>&);
virtual RecBody fetchBody( const RecMailP &mail );
virtual encodedString* fetchRawBody(const RecMailP&mail);
virtual void logout();
virtual MAILLIB::ATYPE getType()const;
virtual const QString&getName()const;
static void pop3_progress( size_t current, size_t maximum );
diff --git a/noncore/net/mail/libmailwrapper/smtpwrapper.cpp b/noncore/net/mail/libmailwrapper/smtpwrapper.cpp
index 86673aa..e2cea7a 100644
--- a/noncore/net/mail/libmailwrapper/smtpwrapper.cpp
+++ b/noncore/net/mail/libmailwrapper/smtpwrapper.cpp
@@ -8,16 +8,17 @@
#include <qt.h>
#include <qpe/config.h>
#include <qpe/qcopenvelope_qws.h>
#include <libetpan/libetpan.h>
+using namespace Opie::Core;
progressMailSend*SMTPwrapper::sendProgress = 0;
SMTPwrapper::SMTPwrapper(SMTPaccount * aSmtp )
: Generatemail()
{
m_SmtpAccount = aSmtp;
Config cfg( "mail" );
cfg.setGroup( "Status" );
@@ -307,17 +308,17 @@ int SMTPwrapper::smtpSend(char*from,clist*rcpts,const char*data,size_t size )
storeFailedMail(data,size,failuretext);
} else {
qDebug( "Mail sent." );
storeMail(data,size,"Sent");
}
return result;
}
-void SMTPwrapper::sendMail(const Opie::OSmartPointer<Mail>&mail,bool later )
+void SMTPwrapper::sendMail(const Opie::Core::OSmartPointer<Mail>&mail,bool later )
{
mailmime * mimeMail;
mimeMail = createMimeMail(mail );
if ( mimeMail == NULL ) {
qDebug( "sendMail: error creating mime mail" );
} else {
sendProgress = new progressMailSend();
diff --git a/noncore/net/mail/libmailwrapper/smtpwrapper.h b/noncore/net/mail/libmailwrapper/smtpwrapper.h
index 71ae35c..6c5bbe8 100644
--- a/noncore/net/mail/libmailwrapper/smtpwrapper.h
+++ b/noncore/net/mail/libmailwrapper/smtpwrapper.h
@@ -18,17 +18,17 @@ class AbstractMail;
class SMTPwrapper : public Generatemail
{
Q_OBJECT
public:
SMTPwrapper(SMTPaccount * aSmtp);
virtual ~SMTPwrapper();
- void sendMail(const Opie::OSmartPointer<Mail>& mail,bool later=false );
+ void sendMail(const Opie::Core::OSmartPointer<Mail>& mail,bool later=false );
bool flushOutbox();
static progressMailSend*sendProgress;
signals:
void queuedMails( int );
protected:
@@ -45,17 +45,17 @@ protected:
static void storeMail(const char*mail, size_t length, const QString&box);
static QString mailsmtpError( int err );
static void progress( size_t current, size_t maximum );
int smtpSend(char*from,clist*rcpts,const char*data,size_t size);
void storeMail(mailmime*mail, const QString&box);
- int sendQueuedMail(AbstractMail*wrap,const Opie::OSmartPointer<RecMail>&which);
+ int sendQueuedMail(AbstractMail*wrap,const Opie::Core::OSmartPointer<RecMail>&which);
void storeFailedMail(const char*data,unsigned int size, const char*failuremessage);
int m_queuedMail;
protected slots:
void emitQCop( int queued );
};
diff --git a/noncore/net/mail/libmailwrapper/storemail.cpp b/noncore/net/mail/libmailwrapper/storemail.cpp
index 595e7fc..914a11d 100644
--- a/noncore/net/mail/libmailwrapper/storemail.cpp
+++ b/noncore/net/mail/libmailwrapper/storemail.cpp
@@ -4,16 +4,17 @@
#include "abstractmail.h"
#include <libetpan/libetpan.h>
#include <qstring.h>
#include <stdlib.h>
+using namespace Opie::Core;
Storemail::Storemail(Account*aAccount,const QString&aFolder)
: Generatemail()
{
wrapper = 0;
m_Account = aAccount;
m_tfolder = aFolder;
wrapper = AbstractMail::getWrapper(m_Account);
if (wrapper) {
@@ -44,17 +45,17 @@ Storemail::Storemail(const QString&aFolder)
wrapper->createMbox(m_tfolder);
}
}
Storemail::~Storemail()
{
}
-int Storemail::storeMail(const Opie::OSmartPointer<Mail>&mail)
+int Storemail::storeMail(const Opie::Core::OSmartPointer<Mail>&mail)
{
if (!wrapper) return 0;
int ret = 1;
mailmime * mimeMail = 0;
mimeMail = createMimeMail(mail );
if ( mimeMail == NULL ) {
qDebug( "storeMail: error creating mime mail" );
diff --git a/noncore/net/mail/libmailwrapper/storemail.h b/noncore/net/mail/libmailwrapper/storemail.h
index 80c7431..4433de0 100644
--- a/noncore/net/mail/libmailwrapper/storemail.h
+++ b/noncore/net/mail/libmailwrapper/storemail.h
@@ -13,17 +13,17 @@ class Storemail : public Generatemail
{
Q_OBJECT
public:
Storemail(Account*aAccount,const QString&aFolder);
Storemail(const QString&dir,const QString&aFolder);
Storemail(const QString&aFolder);
virtual ~Storemail();
- int storeMail(const Opie::OSmartPointer<Mail>&mail);
+ int storeMail(const Opie::Core::OSmartPointer<Mail>&mail);
protected:
Account* m_Account;
QString m_tfolder;
AbstractMail*wrapper;
};
#endif
diff --git a/noncore/net/mail/mail.pro b/noncore/net/mail/mail.pro
index 005a839..926cdbd 100644
--- a/noncore/net/mail/mail.pro
+++ b/noncore/net/mail/mail.pro
@@ -47,17 +47,17 @@ INTERFACES = editaccountsui.ui \
composemailui.ui \
settingsdialogui.ui \
statuswidgetui.ui \
newmaildirui.ui \
selectstoreui.ui \
nntpgroupsui.ui
-INCLUDEPATH += $(OPIEDIR)/include
+INCLUDEPATH += $(OPIEDIR)/include /usr/local/include
CONFTEST = $$system( echo $CONFIG_TARGET_MACOSX )
contains( CONFTEST, y ){
LIBS += -lqpe -lopieui2 -lopiecore2 -lopiepim2 -lopiedb2 -lmailwrapper -liconv
}else{
LIBS += -lqpe -lopieui2 -lopiecore2 -lopiepim2 -lopiedb2 -lmailwrapper
}
diff --git a/noncore/net/mail/main.cpp b/noncore/net/mail/main.cpp
index 54ac7fb..4942083 100644
--- a/noncore/net/mail/main.cpp
+++ b/noncore/net/mail/main.cpp
@@ -1,5 +1,7 @@
#include <opie2/oapplicationfactory.h>
#include "opiemail.h"
+using namespace Opie::Core;
+using namespace Opie::Core;
OPIE_EXPORT_APP( OApplicationFactory<OpieMail> )
diff --git a/noncore/net/mail/taskbarapplet/mailapplet.cpp b/noncore/net/mail/taskbarapplet/mailapplet.cpp
index de32007..f672a36 100644
--- a/noncore/net/mail/taskbarapplet/mailapplet.cpp
+++ b/noncore/net/mail/taskbarapplet/mailapplet.cpp
@@ -7,17 +7,17 @@
#include <qpe/applnk.h>
#include <opie2/odevice.h>
#include <libmailwrapper/settings.h>
#include "mailapplet.h"
-using namespace Opie;
+using namespace Opie::Core;
MailApplet::MailApplet( QWidget *parent )
: QWidget( parent ) {
m_config = new Config( "mail" );
m_config->setGroup( "Applet" );
setFixedWidth( AppLnk::smallIconSize() );
diff --git a/noncore/net/mail/viewmail.cpp b/noncore/net/mail/viewmail.cpp
index 894a386..f00d2cb 100644
--- a/noncore/net/mail/viewmail.cpp
+++ b/noncore/net/mail/viewmail.cpp
@@ -13,16 +13,17 @@
/* QT */
#include <qtextbrowser.h>
#include <qmessagebox.h>
#include <qtextstream.h>
#include <qaction.h>
#include <qpopupmenu.h>
#include <qfile.h>
+using namespace Opie::Ui;
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);
@@ -215,17 +216,17 @@ void ViewMail::slotItemClicked( QListViewItem * item , const QPoint & point, int
ret = menu->exec( point, 0 );
switch(ret)
{
case 0:
{
MimeTypes types;
types.insert( "all", "*" );
- QString str = Opie::OFileDialog::getSaveFileName( 1,
+ QString str = 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);
diff --git a/noncore/net/mail/viewmailbase.cpp b/noncore/net/mail/viewmailbase.cpp
index c2bf08c..cbb98cc 100644
--- a/noncore/net/mail/viewmailbase.cpp
+++ b/noncore/net/mail/viewmailbase.cpp
@@ -1,15 +1,15 @@
#include <qtextbrowser.h>
#include <qlistview.h>
#include <qaction.h>
#include <qlabel.h>
#include <qvbox.h>
-#include <qpe/qpetoolbar.h>
+#include <qtoolbar.h>
#include <qmenubar.h>
#include <qpe/resource.h>
#include "viewmailbase.h"
//#include "opendiag.h"
ViewMailBase::ViewMailBase(QWidget *parent, const char *name, WFlags fl)
: QMainWindow(parent, name, fl)
diff --git a/noncore/net/opieftp/main.cpp b/noncore/net/opieftp/main.cpp
index d9da4b2..330ca52 100644
--- a/noncore/net/opieftp/main.cpp
+++ b/noncore/net/opieftp/main.cpp
@@ -1,16 +1,18 @@
/***************************************************************************
+
main.cpp - description
-------------------
begin : March 10, 2002
copyright : (C) 2002 by llornkcor
email : ljp@llornkcor.com
* This program is free software; you can redistribute it and/or modify *
* it under the terms of the GNU General Public License as published by *
* the Free Software Foundation; either version 2 of the License, or *
* (at your option) any later version. *
***************************************************************************/
#include <opie2/oapplicationfactory.h>
#include "opieftp.h"
+using namespace Opie::Core;
OPIE_EXPORT_APP( OApplicationFactory<OpieFtp> )
diff --git a/noncore/net/opieirc/config.in b/noncore/net/opieirc/config.in
index 7c6949d..38fa347 100644
--- a/noncore/net/opieirc/config.in
+++ b/noncore/net/opieirc/config.in
@@ -1,4 +1,4 @@
config OPIEIRC
boolean "opie-irc (chat via your favorite IRC server)"
default "y"
- depends ( LIBQPE || LIBQPE-X11 ) && LIBOPIE
+ depends ( LIBQPE || LIBQPE-X11 ) && LIBOPIEUI2 && LIBQTAUX
diff --git a/noncore/net/opieirc/ircsettings.cpp b/noncore/net/opieirc/ircsettings.cpp
index f69d2c4..13fcc24 100644
--- a/noncore/net/opieirc/ircsettings.cpp
+++ b/noncore/net/opieirc/ircsettings.cpp
@@ -1,21 +1,23 @@
#include "ircsettings.h"
#include "irctab.h"
/* OPIE */
-#include <opie/ocolorbutton.h>
-#include <opie/otabwidget.h>
+#include <opie2/ocolorbutton.h>
+#include <opie2/otabwidget.h>
#include <qpe/qpeapplication.h>
/* QT */
#include <qvalidator.h>
#include <qwhatsthis.h>
+using namespace Opie;
+using namespace Opie::Ui;
IRCSettings::IRCSettings(QWidget* parent, const char* name, bool modal, WFlags) : QDialog(parent, name, modal, WStyle_ContextHelp)
{
setCaption(tr("Settings") );
m_config = new Config("OpieIRC");
m_config->setGroup("OpieIRC");
QHBoxLayout *l = new QHBoxLayout(this, 2, 2);
OTabWidget *tw = new OTabWidget(this);
l->addWidget(tw);
diff --git a/noncore/net/opieirc/ircsettings.h b/noncore/net/opieirc/ircsettings.h
index cb8d896..56e667b 100644
--- a/noncore/net/opieirc/ircsettings.h
+++ b/noncore/net/opieirc/ircsettings.h
@@ -20,30 +20,32 @@
#ifndef __IRCSETTINGS_H
#define __IRCSETTINGS_H
#include <qpe/config.h>
#include <qdialog.h>
#include <qlineedit.h>
+namespace Opie {
class OColorButton;
+}
class IRCSettings : public QDialog {
Q_OBJECT
public:
IRCSettings(QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags f = 0);
~IRCSettings();
protected slots:
void accept();
protected:
Config *m_config;
- OColorButton *m_background;
- OColorButton *m_text;
- OColorButton *m_error;
- OColorButton *m_self;
- OColorButton *m_server;
- OColorButton *m_other;
- OColorButton *m_notification;
+ Opie::OColorButton *m_background;
+ Opie::OColorButton *m_text;
+ Opie::OColorButton *m_error;
+ Opie::OColorButton *m_self;
+ Opie::OColorButton *m_server;
+ Opie::OColorButton *m_other;
+ Opie::OColorButton *m_notification;
QLineEdit *m_lines;
};
#endif /* __IRCSETTINGS_H */
diff --git a/noncore/net/opieirc/main.cpp b/noncore/net/opieirc/main.cpp
index da38024..f3cbecc 100644
--- a/noncore/net/opieirc/main.cpp
+++ b/noncore/net/opieirc/main.cpp
@@ -1,6 +1,7 @@
#include "mainwindow.h"
-#include <opie/oapplicationfactory.h>
+#include <opie2/oapplicationfactory.h>
+using namespace Opie::Core;
OPIE_EXPORT_APP( OApplicationFactory<MainWindow> )
diff --git a/noncore/net/opieirc/opieirc.pro b/noncore/net/opieirc/opieirc.pro
index 537f810..9039ff8 100644
--- a/noncore/net/opieirc/opieirc.pro
+++ b/noncore/net/opieirc/opieirc.pro
@@ -13,13 +13,13 @@ SOURCES = ircchannel.cpp ircconnection.cpp \
ircperson.cpp ircserver.cpp \
ircsession.cpp main.cpp mainwindow.cpp \
irctab.cpp ircservertab.cpp \
ircchanneltab.cpp ircchannellist.cpp \
ircserverlist.cpp ircservereditor.cpp \
ircquerytab.cpp ircsettings.cpp ircmisc.cpp
INCLUDEPATH += $(OPIEDIR)/include
DEPENDPATH += $(OPIEDIR)/include
-LIBS += -lqpe -lopie
+LIBS += -lqpe -lopieui2 -lqtaux2
TARGET = opieirc
include ( $(OPIEDIR)/include.pro )
diff --git a/noncore/net/opietooth/applet/bluezapplet.cpp b/noncore/net/opietooth/applet/bluezapplet.cpp
index 817936d..93b2c67 100644
--- a/noncore/net/opietooth/applet/bluezapplet.cpp
+++ b/noncore/net/opietooth/applet/bluezapplet.cpp
@@ -29,17 +29,17 @@
#include "bluezapplet.h"
#include <qapplication.h>
#include <qpe/qcopenvelope_qws.h>
#include <qpe/config.h>
#include <qpe/resource.h>
-#include <opie/odevice.h>
+#include <opie2/odevice.h>
#include <qpoint.h>
#include <qpainter.h>
#include <qlayout.h>
#include <qframe.h>
#include <qpixmap.h>
#include <qstring.h>
#include <qtimer.h>
diff --git a/noncore/net/opietooth/lib/device.cc b/noncore/net/opietooth/lib/device.cc
index bae1c47..d913853 100644
--- a/noncore/net/opietooth/lib/device.cc
+++ b/noncore/net/opietooth/lib/device.cc
@@ -1,17 +1,19 @@
#include <signal.h>
-#include <opie/oprocess.h>
+#include <opie2/oprocess.h>
#include "device.h"
using namespace OpieTooth;
+using namespace Opie::Core;
+using namespace Opie::Core;
namespace {
int parsePid( const QCString& par ){
int id=0;
QString string( par );
QStringList list = QStringList::split( '\n', string );
for( QStringList::Iterator it = list.begin(); it != list.end(); ++it ){
qWarning("parsePID: %s", (*it).latin1() );
if( !(*it).startsWith("CSR") ){
@@ -42,21 +44,21 @@ void Device::attach(){
qWarning("attaching %s %s %s", m_device.latin1(), m_mode.latin1(), m_speed.latin1() );
if(m_process == 0 ){
m_output.resize(0);
qWarning("new process to create" );
m_process = new OProcess();
*m_process << "hciattach";
*m_process << "-p";
*m_process << m_device << m_mode << m_speed;
- connect(m_process, SIGNAL( processExited(OProcess*) ),
+ connect(m_process, SIGNAL( processExited(Opie::Core::OProcess*) ),
this, SLOT( slotExited(OProcess* ) ) );
- connect(m_process, SIGNAL( receivedStdout(OProcess*, char*, int) ),
+ connect(m_process, SIGNAL( receivedStdout(Opie::Core::OProcess*, char*, int) ),
this, SLOT(slotStdOut(OProcess*,char*,int ) ) );
- connect(m_process, SIGNAL(receivedStderr(OProcess*, char*, int ) ),
+ connect(m_process, SIGNAL(receivedStderr(Opie::Core::OProcess*, char*, int ) ),
this, SLOT(slotStdErr(OProcess*,char*,int) ) );
if(!m_process->start(OProcess::NotifyOnExit, OProcess::AllOutput ) ){
qWarning("Could not start" );
delete m_process;
m_process = 0;
}
};
}
@@ -91,17 +93,17 @@ void Device::slotExited( OProcess* proc)
pid = parsePid( m_output );
qWarning("Pid = %d", pid );
// now hciconfig hci0 up ( determine hciX FIXME)
// and call hciconfig hci0 up
// FIXME hardcoded to hci0 now :(
m_hci = new OProcess( );
*m_hci << "hciconfig";
*m_hci << "hci0 up";
- connect(m_hci, SIGNAL( processExited(OProcess*) ),
+ connect(m_hci, SIGNAL( processExited(Opie::Core::OProcess*) ),
this, SLOT( slotExited(OProcess* ) ) );
if(!m_hci->start() ){
qWarning("could not start" );
m_attached = false;
emit device("hci0", false );
}
}else{
qWarning("crass" );
diff --git a/noncore/net/opietooth/lib/device.h b/noncore/net/opietooth/lib/device.h
index ce7fccc..f3339fc 100644
--- a/noncore/net/opietooth/lib/device.h
+++ b/noncore/net/opietooth/lib/device.h
@@ -3,17 +3,17 @@
#define OpieToothDevice_H
#include <qobject.h>
#include <qstring.h>
#include <qvaluelist.h>
#include <sys/types.h>
-class OProcess;
+namespace Opie {namespace Core {class Opie::Core::OProcess;}}
namespace OpieTooth {
/**
* Device takes care of attaching serial
* devices to the blueZ stack.
* After attaching it hciconfig ups it
*/
class Device : public QObject {
@@ -62,26 +62,26 @@ namespace OpieTooth {
/**
* Signals devicename and up status
* @return &device QString, Devicename
* @return up bool, if the device is up or not.
*/
void device(const QString& device, bool up );
private slots:
- virtual void slotExited( OProcess* );
- virtual void slotStdOut(OProcess*, char*, int );
- virtual void slotStdErr(OProcess*, char*, int );
+ virtual void slotExited( Opie::Core::OProcess* );
+ virtual void slotStdOut(Opie::Core::OProcess*, char*, int );
+ virtual void slotStdErr(Opie::Core::OProcess*, char*, int );
private:
class Private;
Private *d;
QString m_device;
bool m_attached:1;
- OProcess* m_hci;
- OProcess* m_process;
+ Opie::Core::OProcess* m_hci;
+ Opie::Core::OProcess* m_process;
QString m_devId;
QString m_mode;
QString m_speed;
pid_t pid;
QCString m_output;
};
};
diff --git a/noncore/net/opietooth/lib/manager.cc b/noncore/net/opietooth/lib/manager.cc
index c89d325..56156a8 100644
--- a/noncore/net/opietooth/lib/manager.cc
+++ b/noncore/net/opietooth/lib/manager.cc
@@ -1,18 +1,20 @@
-#include <opie/oprocess.h>
+#include <opie2/oprocess.h>
#include "parser.h"
#include "manager.h"
using namespace OpieTooth;
+using namespace Opie::Core;
+using namespace Opie::Core;
Manager::Manager( const QString& dev )
: QObject()
{
qWarning("created");
m_device = dev;
m_hcitool = 0;
m_sdp = 0;
}
@@ -37,17 +39,17 @@ void Manager::setDevice( const QString& dev ){
}
void Manager::setDevice( Device* /*dev*/ ){
}
void Manager::isAvailable( const QString& device ){
OProcess* l2ping = new OProcess();
l2ping->setName( device.latin1() );
*l2ping << "l2ping" << "-c1" << device;
- connect(l2ping, SIGNAL(processExited(OProcess* ) ),
+ connect(l2ping, SIGNAL(processExited(Opie::Core::OProcess* ) ),
this, SLOT(slotProcessExited(OProcess*) ) );
if (!l2ping->start() ) {
emit available( device, false );
delete l2ping;
}
}
@@ -55,19 +57,19 @@ void Manager::isAvailable( Device* /*dev*/ ){
}
void Manager::searchDevices( const QString& device ){
qWarning("search devices");
OProcess* hcitool = new OProcess();
hcitool->setName( device.isEmpty() ? "hci0" : device.latin1() );
*hcitool << "hcitool" << "scan";
- connect( hcitool, SIGNAL(processExited(OProcess*) ) ,
+ connect( hcitool, SIGNAL(processExited(Opie::Core::OProcess*) ) ,
this, SLOT(slotHCIExited(OProcess* ) ) );
- connect( hcitool, SIGNAL(receivedStdout(OProcess*, char*, int ) ),
+ connect( hcitool, SIGNAL(receivedStdout(Opie::Core::OProcess*, char*, int ) ),
this, SLOT(slotHCIOut(OProcess*, char*, int ) ) );
if (!hcitool->start(OProcess::NotifyOnExit, OProcess::AllOutput) ) {
qWarning("could not start");
RemoteDevice::ValueList list;
emit foundDevices( device, list );
delete hcitool;
}
}
@@ -102,19 +104,19 @@ void Manager::removeServices( const QStringList& list){
for (it = list.begin(); it != list.end(); ++it )
removeService( (*it) );
}
void Manager::searchServices( const QString& remDevice ){
OProcess *m_sdp =new OProcess();
*m_sdp << "sdptool" << "browse" << remDevice;
m_sdp->setName( remDevice.latin1() );
qWarning("search Services for %s", remDevice.latin1() );
- connect(m_sdp, SIGNAL(processExited(OProcess*) ),
+ connect(m_sdp, SIGNAL(processExited(Opie::Core::OProcess*) ),
this, SLOT(slotSDPExited(OProcess* ) ) );
- connect(m_sdp, SIGNAL(receivedStdout(OProcess*, char*, int ) ),
+ connect(m_sdp, SIGNAL(receivedStdout(Opie::Core::OProcess*, char*, int ) ),
this, SLOT(slotSDPOut(OProcess*, char*, int) ) );
if (!m_sdp->start(OProcess::NotifyOnExit, OProcess::AllOutput) ) {
qWarning("could not start sdptool" );
delete m_sdp;
Services::ValueList list;
emit foundServices( remDevice, list );
}
}
@@ -241,19 +243,19 @@ void Manager::connectTo( const QString& mac) {
}
void Manager::searchConnections() {
qWarning("searching connections?");
OProcess* proc = new OProcess();
m_hcitoolCon = QString::null;
- connect(proc, SIGNAL(processExited(OProcess*) ),
+ connect(proc, SIGNAL(processExited(Opie::Core::OProcess*) ),
this, SLOT(slotConnectionExited( OProcess*) ) );
- connect(proc, SIGNAL(receivedStdout(OProcess*, char*, int) ),
+ connect(proc, SIGNAL(receivedStdout(Opie::Core::OProcess*, char*, int) ),
this, SLOT(slotConnectionOutput(OProcess*, char*, int) ) );
*proc << "hcitool";
*proc << "con";
if (!proc->start(OProcess::NotifyOnExit, OProcess::AllOutput) ) {
ConnectionState::ValueList list;
emit connections( list );
delete proc;
@@ -300,19 +302,19 @@ ConnectionState::ValueList Manager::parseConnections( const QString& out ) {
}
return list2;
}
void Manager::signalStrength( const QString &mac ) {
OProcess* sig_proc = new OProcess();
- connect(sig_proc, SIGNAL(processExited(OProcess*) ),
+ connect(sig_proc, SIGNAL(processExited(Opie::Core::OProcess*) ),
this, SLOT(slotSignalStrengthExited( OProcess*) ) );
- connect(sig_proc, SIGNAL(receivedStdout(OProcess*, char*, int) ),
+ connect(sig_proc, SIGNAL(receivedStdout(Opie::Core::OProcess*, char*, int) ),
this, SLOT(slotSignalStrengthOutput(OProcess*, char*, int) ) );
*sig_proc << "hcitool";
*sig_proc << "lq";
*sig_proc << mac;
sig_proc->setName( mac.latin1() );
if (!sig_proc->start(OProcess::NotifyOnExit, OProcess::AllOutput) ) {
diff --git a/noncore/net/opietooth/lib/manager.h b/noncore/net/opietooth/lib/manager.h
index abc8ba1..9b1c714 100644
--- a/noncore/net/opietooth/lib/manager.h
+++ b/noncore/net/opietooth/lib/manager.h
@@ -6,17 +6,17 @@
#include <qstring.h>
#include <qmap.h>
#include <qvaluelist.h>
#include "connection.h"
#include "remotedevice.h"
#include "services.h"
-class OProcess;
+namespace Opie {namespace Core {class Opie::Core::OProcess;}}
namespace OpieTooth {
class Device;
/** Manager manages a blueZ device (hci0 for example)
* without Manager you can control the things you
* could do from command line in a OO and asynchronus
* way.
*/
class Manager : public QObject {
@@ -137,37 +137,37 @@ namespace OpieTooth {
void addedService( const QString& service, bool added );
void removedService( const QString& service, bool removed );
void foundServices( const QString& device, Services::ValueList );
void foundDevices( const QString& device, RemoteDevice::ValueList );
void connections( ConnectionState::ValueList );
void signalStrength( const QString& mac, const QString& strengh );
private slots:
- void slotProcessExited(OProcess* );
+ void slotProcessExited(Opie::Core::OProcess* );
- void slotSDPExited(OProcess*);
- void slotSDPOut(OProcess*, char*, int);
+ void slotSDPExited(Opie::Core::OProcess*);
+ void slotSDPOut(Opie::Core::OProcess*, char*, int);
- void slotHCIExited(OProcess* );
- void slotHCIOut(OProcess*, char*, int );
+ void slotHCIExited(Opie::Core::OProcess* );
+ void slotHCIOut(Opie::Core::OProcess*, char*, int );
- void slotConnectionExited(OProcess* );
- void slotConnectionOutput(OProcess*, char*, int );
+ void slotConnectionExited(Opie::Core::OProcess* );
+ void slotConnectionOutput(Opie::Core::OProcess*, char*, int );
- void slotSignalStrengthOutput( OProcess*, char*, int );
- void slotSignalStrengthExited( OProcess* );
+ void slotSignalStrengthOutput( Opie::Core::OProcess*, char*, int );
+ void slotSignalStrengthExited( Opie::Core::OProcess* );
private:
Services::ValueList parseSDPOutput( const QString& );
RemoteDevice::ValueList parseHCIOutput( const QString& );
ConnectionState::ValueList parseConnections( const QString& );
- OProcess *m_hcitool;
- OProcess *m_sdp; // not only one
+ Opie::Core::OProcess *m_hcitool;
+ Opie::Core::OProcess *m_sdp; // not only one
QString m_device;
QMap<QString, int> m_signalStrength;
QMap<QString, QString> m_out;
QMap<QString, QString> m_devices;
- QMap<OProcess*, QString> m_signalMac;
+ QMap<Opie::Core::OProcess*, QString> m_signalMac;
QString m_hcitoolCon;
};
};
#endif
diff --git a/noncore/net/opietooth/lib/startdunconnection.cpp b/noncore/net/opietooth/lib/startdunconnection.cpp
index c3850eb..90ef04a 100644
--- a/noncore/net/opietooth/lib/startdunconnection.cpp
+++ b/noncore/net/opietooth/lib/startdunconnection.cpp
@@ -1,14 +1,16 @@
#include "startdunconnection.h"
using namespace OpieTooth;
+using namespace Opie::Core;
+using namespace Opie::Core;
StartDunConnection::StartDunConnection() {
m_dunConnect = 0l;
setConnectionType();
}
StartDunConnection::~StartDunConnection() {
delete m_dunConnect;
}
@@ -34,19 +36,19 @@ void StartDunConnection::setConnectionType() {
StartConnection::ConnectionType StartDunConnection::type() {
return m_connectionType;
}
void StartDunConnection::start() {
m_dunConnect = new OProcess();
*m_dunConnect << "dund" << "--listen" << "--connect" << m_mac;
- connect( m_dunConnect, SIGNAL( processExited(OProcess*) ) ,
+ connect( m_dunConnect, SIGNAL( processExited(Opie::Core::OProcess*) ) ,
this, SLOT( slotExited(OProcess*) ) );
- connect( m_dunConnect, SIGNAL( receivedStdout(OProcess*,char*,int) ),
+ connect( m_dunConnect, SIGNAL( receivedStdout(Opie::Core::OProcess*,char*,int) ),
this, SLOT( slotStdOut(OProcess*,char*,int) ) );
if (!m_dunConnect->start( OProcess::NotifyOnExit, OProcess::AllOutput) ) {
qWarning( "could not start" );
delete m_dunConnect;
}
}
diff --git a/noncore/net/opietooth/lib/startdunconnection.h b/noncore/net/opietooth/lib/startdunconnection.h
index 43a852a..f6107f6 100644
--- a/noncore/net/opietooth/lib/startdunconnection.h
+++ b/noncore/net/opietooth/lib/startdunconnection.h
@@ -1,14 +1,14 @@
#ifndef startdunconnection_h
#define startdunconnection_h
#include <qobject.h>
#include "connection.h"
-#include <opie/oprocess.h>
+#include <opie2/oprocess.h>
namespace OpieTooth {
class StartDunConnection : StartConnection {
Q_OBJECT
public:
@@ -22,19 +22,19 @@ namespace OpieTooth {
void setConnectionType( );
void start();
void stop();
private:
QString m_name;
QString m_mac;
ConnectionType m_connectionType;
- OProcess* m_dunConnect;
+ Opie::Core::OProcess* m_dunConnect;
private slots:
- void slotExited( OProcess* proc );
- void slotStdOut( OProcess* proc, char* chars, int len );
+ void slotExited( Opie::Core::OProcess* proc );
+ void slotStdOut( Opie::Core::OProcess* proc, char* chars, int len );
};
}
#endif
diff --git a/noncore/net/opietooth/lib/startpanconnection.cpp b/noncore/net/opietooth/lib/startpanconnection.cpp
index a42b407..fef35d9 100644
--- a/noncore/net/opietooth/lib/startpanconnection.cpp
+++ b/noncore/net/opietooth/lib/startpanconnection.cpp
@@ -1,14 +1,16 @@
#include "startpanconnection.h"
using namespace OpieTooth;
+using namespace Opie::Core;
+using namespace Opie::Core;
StartPanConnection::StartPanConnection() {
m_panConnect = 0l;
setConnectionType();
}
StartPanConnection::~StartPanConnection() {
delete m_panConnect;
}
@@ -35,19 +37,19 @@ StartConnection::ConnectionType StartPanConnection::type() {
return m_connectionType;
}
void StartPanConnection::start() {
m_panConnect = new OProcess();
qDebug( "IM START " + m_mac );
*m_panConnect << "pand" << "--connect" << m_mac;
- connect( m_panConnect, SIGNAL( processExited(OProcess*) ) ,
+ connect( m_panConnect, SIGNAL( processExited(Opie::Core::OProcess*) ) ,
this, SLOT( slotExited(OProcess*) ) );
- connect( m_panConnect, SIGNAL( receivedStdout(OProcess*,char*,int) ),
+ connect( m_panConnect, SIGNAL( receivedStdout(Opie::Core::OProcess*,char*,int) ),
this, SLOT( slotStdOut(OProcess*,char*,int) ) );
if (!m_panConnect->start( OProcess::NotifyOnExit, OProcess::AllOutput) ) {
qWarning( "could not start" );
delete m_panConnect;
}
}
@@ -65,18 +67,18 @@ void StartPanConnection::stop() {
delete m_panConnect;
m_panConnect = 0l;
}
m_panConnect = new OProcess();
qDebug("IM STOP " + m_mac);
*m_panConnect << "pand" << "--kill" << m_mac;
- connect( m_panConnect, SIGNAL( processExited(OProcess*) ) ,
+ connect( m_panConnect, SIGNAL( processExited(Opie::Core::OProcess*) ) ,
this, SLOT( slotExited(OProcess*) ) );
- connect( m_panConnect, SIGNAL( receivedStdout(OProcess*,char*,int) ),
+ connect( m_panConnect, SIGNAL( receivedStdout(Opie::Core::OProcess*,char*,int) ),
this, SLOT( slotStdOut(OProcess*,char*,int) ) );
if (!m_panConnect->start( OProcess::NotifyOnExit, OProcess::AllOutput) ) {
qWarning( "could not stop" );
delete m_panConnect;
}
}
diff --git a/noncore/net/opietooth/lib/startpanconnection.h b/noncore/net/opietooth/lib/startpanconnection.h
index 7e5bd95..e12dad0 100644
--- a/noncore/net/opietooth/lib/startpanconnection.h
+++ b/noncore/net/opietooth/lib/startpanconnection.h
@@ -1,14 +1,14 @@
#ifndef startpanconnection_h
#define startpanconnection_h
#include <qobject.h>
#include "connection.h"
-#include <opie/oprocess.h>
+#include <opie2/oprocess.h>
namespace OpieTooth {
class StartPanConnection : StartConnection {
Q_OBJECT
public:
@@ -22,19 +22,19 @@ namespace OpieTooth {
void setConnectionType( );
void start();
void stop();
private:
QString m_name;
QString m_mac;
ConnectionType m_connectionType;
- OProcess* m_panConnect;
+ Opie::Core::OProcess* m_panConnect;
private slots:
- void slotExited( OProcess* proc );
- void slotStdOut( OProcess* proc, char* chars, int len );
+ void slotExited( Opie::Core::OProcess* proc );
+ void slotStdOut( Opie::Core::OProcess* proc, char* chars, int len );
};
}
#endif
diff --git a/noncore/net/opietooth/manager/main.cpp b/noncore/net/opietooth/manager/main.cpp
index 82aeebd..a96f128 100644
--- a/noncore/net/opietooth/manager/main.cpp
+++ b/noncore/net/opietooth/manager/main.cpp
@@ -1,9 +1,11 @@
/*
+using namespace Opie::Core;
+using namespace Opie::Core;
* main.cpp
*
* ---------------------
*
* begin : Sun 10 17:20:00 CEST 2002
* copyright : (c) 2002 by Maximilian Reiß
* email : max.reiss@gmx.de
*
@@ -14,12 +16,12 @@
* it under the terms of the GNU General Public License as published by *
* the Free Software Foundation; either version 2 of the License, or *
* (at your option) any later version. *
* *
***************************************************************************/
#include "bluebase.h"
#include <qpe/qpeapplication.h>
-#include <opie/oapplicationfactory.h>
+#include <opie2/oapplicationfactory.h>
OPIE_EXPORT_APP( OApplicationFactory<OpieTooth::BlueBase> )
diff --git a/noncore/net/opietooth/manager/obexdialog.cpp b/noncore/net/opietooth/manager/obexdialog.cpp
index 46a0e3d..1ef862a 100644
--- a/noncore/net/opietooth/manager/obexdialog.cpp
+++ b/noncore/net/opietooth/manager/obexdialog.cpp
@@ -4,21 +4,24 @@
#include <qmultilineedit.h>
#include <qlineedit.h>
#include <qlayout.h>
#include <qlabel.h>
#include <qfileinfo.h>
#include <qpe/resource.h>
-#include <opie/oprocess.h>
-#include <opie/ofiledialog.h>
+#include <opie2/oprocess.h>
+#include <opie2/ofiledialog.h>
using namespace OpieTooth;
+using namespace Opie::Core;
+using namespace Opie::Ui;
+using namespace Opie::Core;
ObexDialog::ObexDialog( QWidget* parent, const char* name, bool modal, WFlags fl, const QString& device )
: QDialog( parent, name, modal, fl ) {
if ( !name )
setName( "ObexDialog" );
setCaption( tr( "beam files " ) ) ;
m_device = device;
diff --git a/noncore/net/opietooth/manager/obexdialog.h b/noncore/net/opietooth/manager/obexdialog.h
index b3d5e6d..d5b5682 100644
--- a/noncore/net/opietooth/manager/obexdialog.h
+++ b/noncore/net/opietooth/manager/obexdialog.h
@@ -1,14 +1,14 @@
#ifndef OBEXDIALOG_H
#define OBEXDIALOG_H
#include <qdialog.h>
-#include <opie/oprocess.h>
+#include <opie2/oprocess.h>
class QVBoxLayout;
class QPushButton;
class QMultiLineEdit;
class QLineEdit;
namespace OpieTooth {
diff --git a/noncore/net/opietooth/manager/pppdialog.cpp b/noncore/net/opietooth/manager/pppdialog.cpp
index 4e58552..870e7fd 100644
--- a/noncore/net/opietooth/manager/pppdialog.cpp
+++ b/noncore/net/opietooth/manager/pppdialog.cpp
@@ -1,19 +1,21 @@
#include "pppdialog.h"
#include <qpushbutton.h>
#include <qmultilineedit.h>
#include <qlineedit.h>
#include <qlayout.h>
#include <qlabel.h>
-#include <opie/oprocess.h>
+#include <opie2/oprocess.h>
using namespace OpieTooth;
+using namespace Opie::Core;
+using namespace Opie::Core;
PPPDialog::PPPDialog( QWidget* parent, const char* name, bool modal, WFlags fl, const QString& device )
: QDialog( parent, name, modal, fl ) {
if ( !name )
setName( "PPPDialog" );
setCaption( tr( "ppp connection " ) ) ;
m_device = device;
@@ -47,17 +49,17 @@ PPPDialog::~PPPDialog() {
}
void PPPDialog::connectToDevice() {
outPut->clear();
// vom popupmenu beziehen
QString connectScript = "/etc/ppp/peers/" + cmdLine->text();
OProcess* pppDial = new OProcess();
*pppDial << "pppd" << m_device << "call" << connectScript;
- connect( pppDial, SIGNAL(receivedStdout(OProcess*,char*,int) ),
+ connect( pppDial, SIGNAL(receivedStdout(Opie::Core::OProcess*,char*,int) ),
this, SLOT(fillOutPut(OProcess*,char*,int) ) );
if (!pppDial->start(OProcess::DontCare, OProcess::AllOutput) ) {
qWarning("could not start");
delete pppDial;
}
}
void PPPDialog::fillOutPut( OProcess* pppDial, char* cha, int len ) {
diff --git a/noncore/net/opietooth/manager/pppdialog.h b/noncore/net/opietooth/manager/pppdialog.h
index bb8b734..05894e2 100644
--- a/noncore/net/opietooth/manager/pppdialog.h
+++ b/noncore/net/opietooth/manager/pppdialog.h
@@ -1,14 +1,14 @@
#ifndef PPPDIALOG_H
#define PPPDIALOG_H
#include <qdialog.h>
-#include <opie/oprocess.h>
+#include <opie2/oprocess.h>
class QVBoxLayout;
class QPushButton;
class QMultiLineEdit;
class QLineEdit;
namespace OpieTooth {
@@ -18,17 +18,17 @@ namespace OpieTooth {
Q_OBJECT
public:
PPPDialog( QWidget* parent = 0, const char* name = 0, bool modal = TRUE, WFlags fl = 0, const QString& device = 0);
~PPPDialog();
private slots:
void connectToDevice();
- void fillOutPut( OProcess* pppDial, char* cha, int len );
+ void fillOutPut( Opie::Core::OProcess* pppDial, char* cha, int len );
protected:
QVBoxLayout* layout;
QLineEdit* cmdLine;
QPushButton* connectButton;
QMultiLineEdit* outPut;
private:
QString m_device;
diff --git a/noncore/net/ubrowser/main.cpp b/noncore/net/ubrowser/main.cpp
index 0488cfd..0736f1f 100644
--- a/noncore/net/ubrowser/main.cpp
+++ b/noncore/net/ubrowser/main.cpp
@@ -13,12 +13,14 @@ Public License for more details.
You should have received a copy of the GNU General Public License along with this program; if not, write to the Free
Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
#include <qpe/qpeapplication.h>
#include "mainview.h"
-#include <opie/oapplicationfactory.h>
+#include <opie2/oapplicationfactory.h>
+
+using namespace Opie::Core;
OPIE_EXPORT_APP( OApplicationFactory<MainView> )
diff --git a/noncore/net/wellenreiter/gui/configwindow.cpp b/noncore/net/wellenreiter/gui/configwindow.cpp
index 95b03d0..da39113 100644
--- a/noncore/net/wellenreiter/gui/configwindow.cpp
+++ b/noncore/net/wellenreiter/gui/configwindow.cpp
@@ -38,16 +38,22 @@ using namespace Opie;
#include <qtabwidget.h>
#include <qtoolbutton.h>
#include <qspinbox.h>
#include <qtextstream.h>
/* POSIX */
#include <assert.h>
+using namespace Opie::Core;
+using namespace Opie::Net;
+using namespace Opie::Core;
+using namespace Opie::Net;
+using namespace Opie::Core;
+using namespace Opie::Net;
WellenreiterConfigWindow* WellenreiterConfigWindow::_instance = 0;
WellenreiterConfigWindow::WellenreiterConfigWindow( QWidget * parent, const char * name, WFlags f )
:WellenreiterConfigBase( parent, name, true, f )
{
_devicetype[ "cisco" ] = DEVTYPE_CISCO;
_devicetype[ "wlan-ng" ] = DEVTYPE_WLAN_NG;
_devicetype[ "hostap" ] = DEVTYPE_HOSTAP;
diff --git a/noncore/net/wellenreiter/gui/main.cpp b/noncore/net/wellenreiter/gui/main.cpp
index 7dcc583..6bbc39b 100644
--- a/noncore/net/wellenreiter/gui/main.cpp
+++ b/noncore/net/wellenreiter/gui/main.cpp
@@ -24,16 +24,19 @@
#include <qmessagebox.h>
#include <qstringlist.h>
#include <errno.h>
#include <signal.h>
#include <string.h>
#include <unistd.h>
+using namespace Opie::Core;
+using namespace Opie::Core;
+using namespace Opie::Core;
int main( int argc, char **argv )
{
#ifdef QWS
OApplication a( argc, argv, "Wellenreiter II" );
#else
QApplication a( argc, argv );
#endif
WellenreiterMainWindow* w = new WellenreiterMainWindow();
diff --git a/noncore/net/wellenreiter/gui/mainwindow.cpp b/noncore/net/wellenreiter/gui/mainwindow.cpp
index 5cc0daf..7add6cd 100644
--- a/noncore/net/wellenreiter/gui/mainwindow.cpp
+++ b/noncore/net/wellenreiter/gui/mainwindow.cpp
@@ -46,16 +46,21 @@ using namespace Opie;
#else
#include "resource.h"
#include <qapplication.h>
#include <qfiledialog.h>
#endif
#include <unistd.h>
+using namespace Opie::Ui;
+using namespace Opie::Net;
+using namespace Opie::Ui;
+using namespace Opie::Net;
+using namespace Opie::Net;
WellenreiterMainWindow::WellenreiterMainWindow( QWidget * parent, const char * name, WFlags f )
:QMainWindow( parent, name, f )
{
cw = new WellenreiterConfigWindow( this );
mw = new Wellenreiter( this );
mw->setConfigWindow( cw );
setCentralWidget( mw );
diff --git a/noncore/net/wellenreiter/gui/packetview.cpp b/noncore/net/wellenreiter/gui/packetview.cpp
index ef5d020..8312e71 100644
--- a/noncore/net/wellenreiter/gui/packetview.cpp
+++ b/noncore/net/wellenreiter/gui/packetview.cpp
@@ -20,16 +20,19 @@
/* QT */
#include <qtextview.h>
#include <qspinbox.h>
#include <qlabel.h>
#include <qlayout.h>
#include <qlist.h>
+using namespace Opie::Net;
+using namespace Opie::Net;
+using namespace Opie::Net;
PacketView::PacketView( QWidget * parent, const char * name, WFlags f )
:QFrame( parent, name, f )
{
_number = new QSpinBox( this );
_number->setPrefix( "Packet # " );
_label = new QLabel( this );
_label->setText( "eth0 2004/03/08 - 00:00:21" );
_list = new QLabel( this );
diff --git a/noncore/net/wellenreiter/gui/packetview.h b/noncore/net/wellenreiter/gui/packetview.h
index b5f2b26..1ac19bb 100644
--- a/noncore/net/wellenreiter/gui/packetview.h
+++ b/noncore/net/wellenreiter/gui/packetview.h
@@ -18,32 +18,32 @@
#include <qlist.h>
#include <qframe.h>
class QString;
class QSpinBox;
class QLabel;
class QTextView;
-class OPacket;
+namespace Opie {namespace Net {class Opie::Net::OPacket;}}
class PacketView: public QFrame
{
public:
PacketView( QWidget * parent = 0, const char * name = "PacketView", WFlags f = 0 );
- void add( OPacket* p );
+ void add( Opie::Net::OPacket* p );
const QString getLog() const;
void clear();
protected:
QSpinBox* _number;
QLabel* _label;
QLabel* _list;
QTextView* _hex;
- QList<OPacket> _packets;
+ QList<Opie::Net::OPacket> _packets;
};
#endif
diff --git a/noncore/net/wellenreiter/gui/scanlist.cpp b/noncore/net/wellenreiter/gui/scanlist.cpp
index 6005818..3b7120a 100644
--- a/noncore/net/wellenreiter/gui/scanlist.cpp
+++ b/noncore/net/wellenreiter/gui/scanlist.cpp
@@ -41,16 +41,22 @@ const int col_channel = 3;
const int col_wep = 4;
const int col_traffic = 5;
const int col_ip = 6;
const int col_manuf = 7;
const int col_firstseen = 8;
const int col_lastseen = 9;
const int col_location = 10;
+using namespace Opie::Net;
+using namespace Opie::Ui;
+using namespace Opie::Net;
+using namespace Opie::Ui;
+using namespace Opie::Ui;
+using namespace Opie::Net;
MScanListView::MScanListView( QWidget* parent, const char* name )
:OListView( parent, name )
{
setFrameShape( QListView::StyledPanel );
setFrameShadow( QListView::Sunken );
addColumn( tr( "Net/Station" ) );
setColumnAlignment( col_essid, AlignLeft || AlignVCenter );
diff --git a/noncore/net/wellenreiter/gui/scanlist.h b/noncore/net/wellenreiter/gui/scanlist.h
index ab870c2..6a80f70 100644
--- a/noncore/net/wellenreiter/gui/scanlist.h
+++ b/noncore/net/wellenreiter/gui/scanlist.h
@@ -23,53 +23,53 @@
#include <opie2/onetutils.h>
/* QT */
#include <qtextstream.h>
class QString;
class MScanListItem;
-class MScanListView: public OListView
+class MScanListView: public Opie::Ui::OListView
{
Q_OBJECT
public:
MScanListView( QWidget* parent = 0, const char* name = 0 );
virtual ~MScanListView();
- virtual OListViewItem* childFactory();
+ virtual Opie::Ui::OListViewItem* childFactory();
virtual void serializeTo( QDataStream& s ) const;
virtual void serializeFrom( QDataStream& s );
public slots:
- void addNewItem( const QString& type, const QString&, const OMacAddress&, bool, int, int, const GpsLocation&, bool = false );
- void addService( const QString& name, const OMacAddress& macaddr, const QString& ip );
+ void addNewItem( const QString& type, const QString&, const Opie::Net::OMacAddress&, bool, int, int, const GpsLocation&, bool = false );
+ void addService( const QString& name, const Opie::Net::OMacAddress& macaddr, const QString& ip );
- void fromDStraffic( const OMacAddress& from, const OMacAddress& to, const OMacAddress& via );
- void toDStraffic( const OMacAddress& from, const OMacAddress& to, const OMacAddress& via );
- void WDStraffic( const OMacAddress& from, const OMacAddress& to, const OMacAddress& viaFrom, const OMacAddress& viaTo );
- void IBSStraffic( const OMacAddress& from, const OMacAddress& to, const OMacAddress& via );
+ void fromDStraffic( const Opie::Net::OMacAddress& from, const Opie::Net::OMacAddress& to, const Opie::Net::OMacAddress& via );
+ void toDStraffic( const Opie::Net::OMacAddress& from, const Opie::Net::OMacAddress& to, const Opie::Net::OMacAddress& via );
+ void WDStraffic( const Opie::Net::OMacAddress& from, const Opie::Net::OMacAddress& to, const Opie::Net::OMacAddress& viaFrom, const Opie::Net::OMacAddress& viaTo );
+ void IBSStraffic( const Opie::Net::OMacAddress& from, const Opie::Net::OMacAddress& to, const Opie::Net::OMacAddress& via );
- void identify( const OMacAddress&, const QString& ipaddr );
+ void identify( const Opie::Net::OMacAddress&, const QString& ipaddr );
void contextMenuRequested( QListViewItem* item, const QPoint&, int );
signals:
void rightButtonClicked(QListViewItem*,const QPoint&,int);
void joinNetwork( const QString&, const QString&, int, const QString& );
protected:
- void addIfNotExisting( MScanListItem* parent, const OMacAddress& addr, const QString& type = "station" );
+ void addIfNotExisting( MScanListItem* parent, const Opie::Net::OMacAddress& addr, const QString& type = "station" );
};
//****************************** MScanListItem ****************************************************************
-class MScanListItem: public OListViewItem
+class MScanListItem: public Opie::Ui::OListViewItem
{
public:
MScanListItem::MScanListItem( QListView* parent,
const QString& type = "unknown",
const QString& essid = "unknown",
const QString& macaddr = "unknown",
bool wep = false,
int channel = 0,
@@ -101,17 +101,17 @@ class MScanListItem: public OListViewItem
int beacons() { return _beacons; };
void setSignal( int signal ) { /* TODO */ };
void receivedBeacon();
void setManufacturer( const QString& manufacturer );
void setLocation( const QString& location );
- virtual OListViewItem* childFactory();
+ virtual Opie::Ui::OListViewItem* childFactory();
virtual void serializeTo( QDataStream& s ) const;
virtual void serializeFrom( QDataStream& s );
private:
QString _type;
QString _essid;
QString _macaddr;
bool _wep;
@@ -120,17 +120,17 @@ class MScanListItem: public OListViewItem
int _beacons;
};
//****************************** MScanListViewFactory ****************************************************************
/*
-class MScanListViewFactory : public OListViewFactory
+class MScanListViewFactory : public Opie::Ui::OListViewFactory
{
public:
virtual QListView* listViewFactory();
virtual QListViewItem* listViewItemFactory( QListView* lv );
virtual QListViewItem* listViewItemFactory( QListViewItem* lvi );
virtual void setColumnText( int depth, QListViewItem* lvi, int column, const QString& text );
virtual void setCustomData( int depth, QListViewItem* lvi, const QString& text );
}
diff --git a/noncore/net/wellenreiter/gui/statwindow.cpp b/noncore/net/wellenreiter/gui/statwindow.cpp
index 48e4847..e3c6bbe 100644
--- a/noncore/net/wellenreiter/gui/statwindow.cpp
+++ b/noncore/net/wellenreiter/gui/statwindow.cpp
@@ -11,16 +11,19 @@
** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
**
**********************************************************************/
#include "statwindow.h"
#include <opie2/olistview.h>
+using namespace Opie::Ui;
+using namespace Opie::Ui;
+using namespace Opie::Ui;
MStatWindow::MStatWindow( QWidget * parent, const char * name, WFlags f )
:QVBox( parent, name, f )
{
table = new OListView( this );
table->addColumn( tr( "Protocol" ) );
table->addColumn( tr( "Count" ) );
table->setItemMargin( 2 );
};
diff --git a/noncore/net/wellenreiter/gui/statwindow.h b/noncore/net/wellenreiter/gui/statwindow.h
index b9057e7..e11247b 100644
--- a/noncore/net/wellenreiter/gui/statwindow.h
+++ b/noncore/net/wellenreiter/gui/statwindow.h
@@ -14,30 +14,30 @@
**********************************************************************/
#ifndef STATWINDOW_H
#define STATWINDOW_H
#include <qvbox.h>
class QString;
-class OListView;
+namespace Opie {namespace Ui {class Opie::Ui::OListView;}}
class MStatWindow: public QVBox
{
Q_OBJECT
public:
MStatWindow( QWidget * parent = 0, const char * name = "MStatWindow", WFlags f = 0 );
void log( QString text );
const QString getLog() const;
void clear();
void updateCounter( const QString&, int );
protected:
- OListView* table;
+ Opie::Ui::OListView* table;
};
#endif
diff --git a/noncore/net/wellenreiter/gui/wellenreiter.cpp b/noncore/net/wellenreiter/gui/wellenreiter.cpp
index ce416e5..e8d9de7 100644
--- a/noncore/net/wellenreiter/gui/wellenreiter.cpp
+++ b/noncore/net/wellenreiter/gui/wellenreiter.cpp
@@ -56,16 +56,22 @@ using namespace Opie;
#include <assert.h>
#include <errno.h>
#include <unistd.h>
#include <string.h>
#include <sys/types.h>
#include <stdlib.h>
+using namespace Opie::Core;
+using namespace Opie::Net;
+using namespace Opie::Net;
+using namespace Opie::Core;
+using namespace Opie::Net;
+using namespace Opie::Core;
Wellenreiter::Wellenreiter( QWidget* parent )
: WellenreiterBase( parent, 0, 0 ),
sniffing( false ), iface( 0 ), configwindow( 0 )
{
logwindow->log( "(i) Wellenreiter has been started." );
//
@@ -441,17 +447,17 @@ void Wellenreiter::receivePacket( OPacket* p )
}
void Wellenreiter::stopClicked()
{
if ( iface )
{
- disconnect( SIGNAL( receivedPacket(OPacket*) ), this, SLOT( receivePacket(OPacket*) ) );
+ disconnect( SIGNAL( receivedPacket(Opie::Net::OPacket*) ), this, SLOT( receivePacket(Opie::Net::OPacket*) ) );
disconnect( SIGNAL( hopped(int) ), this, SLOT( channelHopped(int) ) );
iface->setChannelHopping(); // stop hopping channels
}
else
killTimers();
pcap->close();
sniffing = false;
@@ -606,17 +612,17 @@ void Wellenreiter::startClicked()
{
logwindow->log( QString().sprintf( "(i) Starting channel hopper (d=%d ms)", configwindow->hopInterval->value() ) );
iface->setChannelHopping( configwindow->hopInterval->value() ); //use interval from config window
}
if ( cardtype != DEVTYPE_FILE )
{
// connect socket notifier and start channel hopper
- connect( pcap, SIGNAL( receivedPacket(OPacket*) ), this, SLOT( receivePacket(OPacket*) ) );
+ connect( pcap, SIGNAL( receivedPacket(Opie::Net::OPacket*) ), this, SLOT( receivePacket(Opie::Net::OPacket*) ) );
connect( iface->channelHopper(), SIGNAL( hopped(int) ), this, SLOT( channelHopped(int) ) );
}
else
{
// start timer for reading packets
startTimer( 100 );
}
diff --git a/noncore/net/wellenreiter/gui/wellenreiter.h b/noncore/net/wellenreiter/gui/wellenreiter.h
index d02813b..83299c9 100644
--- a/noncore/net/wellenreiter/gui/wellenreiter.h
+++ b/noncore/net/wellenreiter/gui/wellenreiter.h
@@ -13,31 +13,31 @@
#ifndef WELLENREITER_H
#define WELLENREITER_H
#include "wellenreiterbase.h"
#ifdef QWS
#include <opie2/odevice.h>
-using namespace Opie;
#endif
class QTimerEvent;
class QPixmap;
-class OPacket;
-class OWaveLanManagementPacket;
-class OWaveLanControlPacket;
-class OWaveLanDataPacket;
-class OEthernetPacket;
-class OARPPacket;
-class OMacAddress;
-class OIPPacket;
-class OPacketCapturer;
-class OWirelessNetworkInterface;
+namespace Opie {namespace Net {class Opie::Net::OPacket;}}
+namespace Opie {namespace Net {class Opie::Net::OWaveLanManagementPacket;}}
+namespace Opie {namespace Net {class Opie::Net::OWaveLanControlPacket;}}
+namespace Opie {namespace Net {class Opie::Net::OWaveLanDataPacket;}}
+namespace Opie {namespace Net {class Opie::Net::OEthernetPacket;}}
+namespace Opie {namespace Net {class Opie::Net::OARPPacket;}}
+namespace Opie {namespace Net {class Opie::Net::OMacAddress;}}
+namespace Opie {namespace Net {class Opie::Net::OIPPacket;}}
+namespace Opie {namespace Net {class Opie::Net::OPacket;}}
+namespace Opie {namespace Net {class Opie::Net::OWirelessNetworkInterface;}}
+namespace Opie {namespace Net {class Opie::Net::OPacketCapturer;}}
class PacketView;
class WellenreiterConfigWindow;
class MLogWindow;
class GPS;
class Wellenreiter : public WellenreiterBase {
Q_OBJECT
@@ -57,49 +57,49 @@ class Wellenreiter : public WellenreiterBase {
protected:
virtual void timerEvent( QTimerEvent* );
public slots:
void initialTimer();
void channelHopped(int);
- void receivePacket(OPacket*);
+ void receivePacket(Opie::Net::OPacket*);
void startClicked();
void stopClicked();
void joinNetwork(const QString&,const QString&,int,const QString&);
signals:
void startedSniffing();
void stoppedSniffing();
private:
- void handleManagementFrame( OPacket* p, OWaveLanManagementPacket* );
- void handleManagementFrameBeacon( OPacket* p, OWaveLanManagementPacket* );
- void handleManagementFrameProbeRequest( OPacket* p, OWaveLanManagementPacket* );
- void handleManagementFrameProbeResponse( OPacket* p, OWaveLanManagementPacket* );
- void handleControlFrame( OPacket* p, OWaveLanControlPacket* control );
- void handleWlanData( OPacket* p, OWaveLanDataPacket* data, OMacAddress& from, OMacAddress& to );
- void handleEthernetData( OPacket* p, OEthernetPacket* data, OMacAddress& from, OMacAddress& to );
- void handleARPData( OPacket* p, OARPPacket* arp, OMacAddress& from, OMacAddress& to );
- void handleIPData( OPacket* p, OIPPacket* ip, OMacAddress& from, OMacAddress& to );
- void handleNotification( OPacket* p );
- void doAction( const QString& action, const QString& protocol, OPacket* p );
- QObject* childIfToParse( OPacket* p, const QString& protocol );
- bool checkDumpPacket( OPacket* p );
+ void handleManagementFrame( Opie::Net::OPacket* p, Opie::Net::OWaveLanManagementPacket* );
+ void handleManagementFrameBeacon( Opie::Net::OPacket* p, Opie::Net::OWaveLanManagementPacket* );
+ void handleManagementFrameProbeRequest( Opie::Net::OPacket* p, Opie::Net::OWaveLanManagementPacket* );
+ void handleManagementFrameProbeResponse( Opie::Net::OPacket* p, Opie::Net::OWaveLanManagementPacket* );
+ void handleControlFrame( Opie::Net::OPacket* p, Opie::Net::OWaveLanControlPacket* control );
+ void handleWlanData( Opie::Net::OPacket* p, Opie::Net::OWaveLanDataPacket* data, Opie::Net::OMacAddress& from, Opie::Net::OMacAddress& to );
+ void handleEthernetData( Opie::Net::OPacket* p, Opie::Net::OEthernetPacket* data, Opie::Net::OMacAddress& from, Opie::Net::OMacAddress& to );
+ void handleARPData( Opie::Net::OPacket* p, Opie::Net::OARPPacket* arp, Opie::Net::OMacAddress& from, Opie::Net::OMacAddress& to );
+ void handleIPData( Opie::Net::OPacket* p, Opie::Net::OIPPacket* ip, Opie::Net::OMacAddress& from, Opie::Net::OMacAddress& to );
+ void handleNotification( Opie::Net::OPacket* p );
+ void doAction( const QString& action, const QString& protocol, Opie::Net::OPacket* p );
+ QObject* childIfToParse( Opie::Net::OPacket* p, const QString& protocol );
+ bool checkDumpPacket( Opie::Net::OPacket* p );
private:
#ifdef QWS
- OSystem _system; // Opie Operating System identifier
+ Opie::Core::OSystem _system; // Opie Operating System identifier
#endif
QString dumpname;
- OWirelessNetworkInterface* iface;
- OPacketCapturer* pcap;
+ Opie::Net::OWirelessNetworkInterface* iface;
+ Opie::Net::OPacketCapturer* pcap;
WellenreiterConfigWindow* configwindow;
GPS* gps;
//void readConfig();
//void writeConfig();
};
diff --git a/noncore/net/wellenreiter/gui/wellenreiterbase.cpp b/noncore/net/wellenreiter/gui/wellenreiterbase.cpp
index 3d0595d..f035e89 100644
--- a/noncore/net/wellenreiter/gui/wellenreiterbase.cpp
+++ b/noncore/net/wellenreiter/gui/wellenreiterbase.cpp
@@ -33,16 +33,19 @@ using namespace Opie;
#include <qtabwidget.h>
#endif
/*
* Constructs a WellenreiterBase which is a child of 'parent', with the
* name 'name' and widget flags set to 'f'
*/
+using namespace Opie::Ui;
+using namespace Opie::Ui;
+using namespace Opie::Ui;
WellenreiterBase::WellenreiterBase( QWidget* parent, const char* name, WFlags fl )
: QWidget( parent, name, fl )
{
//ani1 = new QPixmap( Resource::loadPixmap( "wellenreiter/networks_rot0" ) );
//ani2 = new QPixmap( Resource::loadPixmap( "wellenreiter/networks_rot90" ) );
//ani3 = new QPixmap( Resource::loadPixmap( "wellenreiter/networks_rot180" ) );
//ani4 = new QPixmap( Resource::loadPixmap( "wellenreiter/networks_rot270" ) );
diff --git a/noncore/net/wellenreiter/gui/wellenreiterbase.h b/noncore/net/wellenreiter/gui/wellenreiterbase.h
index 126aad2..e40b699 100644
--- a/noncore/net/wellenreiter/gui/wellenreiterbase.h
+++ b/noncore/net/wellenreiter/gui/wellenreiterbase.h
@@ -41,17 +41,17 @@ class WellenreiterBase : public QWidget
{
Q_OBJECT
public:
WellenreiterBase( QWidget* parent = 0, const char* name = 0, WFlags fl = 0 );
~WellenreiterBase();
#ifdef QWS
- OTabWidget* TabWidget;
+ Opie::Ui::OTabWidget* TabWidget;
#else
QTabWidget* TabWidget;
#endif
QWidget* ap;
MScanListView* netview;
MLogWindow* logwindow;
PacketView* hexwindow;
MStatWindow* statwindow;