summaryrefslogtreecommitdiff
path: root/noncore/apps/qashmoney/transferdialog.cpp
authormickeyl <mickeyl>2004-11-04 10:33:04 (UTC)
committer mickeyl <mickeyl>2004-11-04 10:33:04 (UTC)
commit7855b19ce0241a7b7b4fc72e3a8ddd9bf73b0a77 (patch) (side-by-side diff)
treee76604c6af3da9c19b69dcdcf8105d58bac63f71 /noncore/apps/qashmoney/transferdialog.cpp
parentcd2d50799e087fad5b56df9d7fe9aa572a313e64 (diff)
downloadopie-7855b19ce0241a7b7b4fc72e3a8ddd9bf73b0a77.zip
opie-7855b19ce0241a7b7b4fc72e3a8ddd9bf73b0a77.tar.gz
opie-7855b19ce0241a7b7b4fc72e3a8ddd9bf73b0a77.tar.bz2
opie-qashmoney is now unsupported
Diffstat (limited to 'noncore/apps/qashmoney/transferdialog.cpp') (more/less context) (ignore whitespace changes)
-rwxr-xr-xnoncore/apps/qashmoney/transferdialog.cpp112
1 files changed, 0 insertions, 112 deletions
diff --git a/noncore/apps/qashmoney/transferdialog.cpp b/noncore/apps/qashmoney/transferdialog.cpp
deleted file mode 100755
index 7a12fbf..0000000
--- a/noncore/apps/qashmoney/transferdialog.cpp
+++ b/dev/null
@@ -1,112 +0,0 @@
-#include "transferdialog.h"
-#include "datepicker.h"
-#include "calculator.h"
-
-
-extern Preferences *preferences;
-extern Account *account;
-
-TransferDialog::TransferDialog ( QWidget *parent, int fromaccountid, int toaccountid ) : QDialog ( parent, 0, TRUE )
- {
- dateedited = FALSE;
- setCaption ( "Transfer" );
-
- fromaccountlabel = new QLabel ( "From account:", this );
- QFont f = this->font();
- f.setWeight ( QFont::Bold );
- fromaccountlabel->setFont ( f );
- fromaccount = new QLabel ( account->getAccountName ( fromaccountid ), this );
-
- toaccountlabel = new QLabel ( "To Account:", this );
- toaccountlabel->setFont ( f );
- toaccount = new QLabel ( account->getAccountName ( toaccountid ), this );
-
- datelabel = new QLabel ( "Date", this );
-
- datebox = new QHBox ( this );
- datebox->setSpacing ( 2 );
- date = new QLineEdit ( datebox );
- date->setAlignment ( Qt::AlignRight );
- date->setDisabled ( TRUE );
- datebutton = new QPushButton ( datebox );
- datebutton->setPixmap ( QPixmap ( "/opt/QtPalmtop/pics/date.png" ) );
- connect ( datebutton, SIGNAL ( released() ), this, SLOT ( showCalendar() ) );
-
- amounttlabel = new QLabel ( "Amount", this );
-
- amountbox = new QHBox ( this );
- amountbox->setSpacing ( 2 );
- amount = new QLineEdit ( amountbox );
- amount->setAlignment ( Qt::AlignRight );
- calculatorbutton = new QPushButton( amountbox );
- calculatorbutton->setPixmap ( QPixmap ( "/opt/QtPalmtop/pics/kcalc.png" ) );
- connect ( calculatorbutton, SIGNAL ( released() ), this, SLOT ( showCalculator() ) );
-
- clearedcheckbox = new QCheckBox ( "Cleared", this );
-
- layout = new QVBoxLayout ( this, 4, 2 );
- layout->addWidget ( fromaccountlabel, Qt::AlignLeft );
- layout->addWidget ( fromaccount, Qt::AlignLeft );
- layout->addWidget ( toaccountlabel, Qt::AlignLeft );
- layout->addWidget ( toaccount, Qt::AlignLeft );
- layout->addSpacing ( 5 );
- layout->addWidget ( datelabel, Qt::AlignLeft );
- layout->addWidget ( datebox, Qt::AlignLeft );
- layout->addWidget ( amounttlabel, Qt::AlignLeft );
- layout->addWidget ( amountbox, Qt::AlignLeft );
- layout->addWidget ( clearedcheckbox, Qt::AlignLeft );
- }
-
-bool TransferDialog::getDateEdited ()
- {
- return dateedited;
- }
-
-void TransferDialog::showCalendar ()
- {
- QDate newDate = QDate::currentDate ();
- DatePicker *dp = new DatePicker ( newDate );
- if ( dp->exec () == QDialog::Accepted )
- {
- // Set date integers
- year = dp->getYear();
- month = dp->getMonth();
- day = dp->getDay();
-
- // Set dateedited to TRUE
- // This tells the accountdisplay object that the user edited an account
- // and did change the date
- dateedited = TRUE;
-
- // Display date with our selected format
- date->setText ( preferences->getDate ( year, month, day ) );
- }
- }
-
-int TransferDialog::getDay ()
- {
- return day;
- }
-
-int TransferDialog::getMonth ()
- {
- return month;
- }
-
-int TransferDialog::getYear ()
- {
- return year;
- }
-
-void TransferDialog::showCalculator ()
- {
- Calculator *calculator = new Calculator ( this );
- if ( calculator->exec () == QDialog::Accepted )
- amount->setText ( calculator->display->text() );
- }
-
-
-
-
-
-