summaryrefslogtreecommitdiff
Unidiff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/unsupported/mail2/attachdiag.cpp68
-rw-r--r--noncore/unsupported/mail2/attachdiag.h26
-rw-r--r--noncore/unsupported/mail2/mail.pro2
3 files changed, 0 insertions, 96 deletions
diff --git a/noncore/unsupported/mail2/attachdiag.cpp b/noncore/unsupported/mail2/attachdiag.cpp
deleted file mode 100644
index 446cfe5..0000000
--- a/noncore/unsupported/mail2/attachdiag.cpp
+++ b/dev/null
@@ -1,68 +0,0 @@
1#include <qmessagebox.h>
2#include <qpushbutton.h>
3#include <qlistbox.h>
4#include <qlayout.h>
5
6#include <qpe/applnk.h>
7#include <qpe/fileselector.h>
8#include <qpe/resource.h>
9
10#include <stdlib.h>
11
12#include "attachdiag.h"
13
14AttachDiag::AttachDiag(QWidget* parent = 0, const char* name = 0, bool modal, WFlags fl = 0)
15 : QDialog(parent, name, modal, fl)
16{
17 setCaption(tr("Attach File"));
18
19 QGridLayout *layout = new QGridLayout(this);
20 layout->setSpacing(3);
21 layout->setMargin(4);
22
23 _fileSelector = new FileSelector("*", this, "FileSelector");
24 _fileSelector->setCloseVisible(false);
25 _fileSelector->setNewVisible(false);
26
27 layout->addMultiCellWidget(_fileSelector, 0, 0, 0, 1);
28
29 QPushButton *attachButton = new QPushButton(this);
30 attachButton->setText(tr("Ok"));
31 attachButton->setIconSet(Resource::loadPixmap("enter"));
32
33 layout->addWidget(attachButton, 1, 0);
34
35 QPushButton *cancelButton = new QPushButton(this);
36 cancelButton->setText(tr("Cancel"));
37 cancelButton->setIconSet(Resource::loadPixmap("editdelete"));
38
39 layout->addWidget(cancelButton, 1, 1);
40
41 connect(attachButton, SIGNAL(clicked()), SLOT(accept()));
42 connect(cancelButton, SIGNAL(clicked()), SLOT(close()));
43
44 if (_fileSelector->fileCount() == 0) {
45 attachButton->setEnabled(false);
46 _fileSelector->setEnabled(false);
47 }
48}
49
50DocLnk AttachDiag::selectedFile()
51{
52 return *_fileSelector->selected();
53}
54
55DocLnk AttachDiag::getFile(QWidget *parent)
56{
57 AttachDiag attach(parent, 0, true);
58 attach.showMaximized();
59 attach.show();
60
61 if (QDialog::Accepted == attach.exec()) {
62 return attach.selectedFile();
63 }
64
65 return DocLnk();
66 }
67
68
diff --git a/noncore/unsupported/mail2/attachdiag.h b/noncore/unsupported/mail2/attachdiag.h
deleted file mode 100644
index 88686bc..0000000
--- a/noncore/unsupported/mail2/attachdiag.h
+++ b/dev/null
@@ -1,26 +0,0 @@
1#ifndef ATTACHDIAG_H
2#define ATTACHDIAG_H
3
4#include <qdialog.h>
5
6class DocLnk;
7class FileSelector;
8
9class AttachDiag : public QDialog
10{
11 Q_OBJECT
12
13public:
14 DocLnk selectedFile();
15 static DocLnk getFile(QWidget *parent);
16
17protected:
18 AttachDiag(QWidget *parent = 0, const char* name = 0, bool modal = false, WFlags fl = 0);
19
20private:
21 FileSelector *_fileSelector;
22
23};
24
25#endif
26
diff --git a/noncore/unsupported/mail2/mail.pro b/noncore/unsupported/mail2/mail.pro
index cd21d4a..c1b7a4f 100644
--- a/noncore/unsupported/mail2/mail.pro
+++ b/noncore/unsupported/mail2/mail.pro
@@ -1,46 +1,44 @@
1 TEMPLATE = app 1 TEMPLATE = app
2 CONFIG = qt warn_on debug 2 CONFIG = qt warn_on debug
3 #CONFIG = qt warn_on release 3 #CONFIG = qt warn_on release
4 HEADERS = accounteditor.h \ 4 HEADERS = accounteditor.h \
5 addresspicker.h \ 5 addresspicker.h \
6 attachdiag.h \
7 composer.h \ 6 composer.h \
8 composerbase.h \ 7 composerbase.h \
9 configdiag.h \ 8 configdiag.h \
10 folderwidget.h \ 9 folderwidget.h \
11 listviewplus.h \ 10 listviewplus.h \
12 mailtable.h \ 11 mailtable.h \
13 mainwindow.h \ 12 mainwindow.h \
14 mainwindowbase.h \ 13 mainwindowbase.h \
15 opendiag.h \ 14 opendiag.h \
16 rename.h \ 15 rename.h \
17 searchdiag.h \ 16 searchdiag.h \
18 viewmail.h \ 17 viewmail.h \
19 viewmailbase.h 18 viewmailbase.h
20 SOURCES = accounteditor.cpp \ 19 SOURCES = accounteditor.cpp \
21 addresspicker.cpp \ 20 addresspicker.cpp \
22 attachdiag.cpp \
23 composer.cpp \ 21 composer.cpp \
24 composerbase.cpp \ 22 composerbase.cpp \
25 configdiag.cpp \ 23 configdiag.cpp \
26 folderwidget.cpp \ 24 folderwidget.cpp \
27 listviewplus.cpp \ 25 listviewplus.cpp \
28 mailtable.cpp \ 26 mailtable.cpp \
29 main.cpp \ 27 main.cpp \
30 mainwindow.cpp \ 28 mainwindow.cpp \
31 mainwindowbase.cpp \ 29 mainwindowbase.cpp \
32 opendiag.cpp \ 30 opendiag.cpp \
33 rename.cpp \ 31 rename.cpp \
34 searchdiag.cpp \ 32 searchdiag.cpp \
35 viewmail.cpp \ 33 viewmail.cpp \
36 viewmailbase.cpp 34 viewmailbase.cpp
37 INTERFACES = accounteditorbase.ui \ 35 INTERFACES = accounteditorbase.ui \
38 addresspickerbase.ui \ 36 addresspickerbase.ui \
39 configdiagbase.ui \ 37 configdiagbase.ui \
40 opendiagbase.ui \ 38 opendiagbase.ui \
41 renamebase.ui \ 39 renamebase.ui \
42 searchdiagbase.ui 40 searchdiagbase.ui
43 INCLUDEPATH += $(OPIEDIR)/include libmail 41 INCLUDEPATH += $(OPIEDIR)/include libmail
44 LIBS += -lmail -lqpe -lopie 42 LIBS += -lmail -lqpe -lopie
45 TARGET = mail 43 TARGET = mail
46 DESTDIR = $(OPIEDIR)/bin 44 DESTDIR = $(OPIEDIR)/bin