summaryrefslogtreecommitdiff
path: root/noncore/apps/checkbook/checkbook.cpp
Side-by-side diff
Diffstat (limited to 'noncore/apps/checkbook/checkbook.cpp') (more/less context) (show whitespace changes)
-rw-r--r--noncore/apps/checkbook/checkbook.cpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/noncore/apps/checkbook/checkbook.cpp b/noncore/apps/checkbook/checkbook.cpp
index a42c824..a5492e4 100644
--- a/noncore/apps/checkbook/checkbook.cpp
+++ b/noncore/apps/checkbook/checkbook.cpp
@@ -474,26 +474,25 @@ void Checkbook::slotStartingBalanceChanged( const QString &newbalance )
// --- slotNewTran ------------------------------------------------------------
void Checkbook::slotNewTran()
{
TranInfo *traninfo = new TranInfo( info->getNextNumber() );
if( !_dLastNew.isNull() )
traninfo->setDate(_dLastNew);
Transaction *currtran = new Transaction( this, true, info->name(),
traninfo,
_pCfg );
- currtran->showMaximized();
- if ( currtran->exec() == QDialog::Accepted )
+ if ( QPEApplication::execDialog( currtran ) == QDialog::Accepted )
{
// Add to transaction list
info->addTransaction( traninfo );
// Add to transaction table
float amount;
QString stramount;
amount = (traninfo->withdrawal() ? -1 : 1)*traninfo->amount();
stramount.sprintf( "%s%.2f", _pCfg->getCurrencySymbol().latin1(), amount );
( void ) new CBListItem( traninfo, tranTable, traninfo->getIdStr(), traninfo->datestr(false),
traninfo->number(), traninfo->datestr(true), traninfo->desc(),
stramount );
@@ -521,26 +520,25 @@ void Checkbook::slotNewTran()
// --- slotEditTran -----------------------------------------------------------
void Checkbook::slotEditTran()
{
QListViewItem *curritem = tranTable->currentItem();
if ( !curritem )
return;
TranInfo *traninfo=info->findTransaction( curritem->text(COL_ID) );
Transaction *currtran = new Transaction( this, false, info->name(),
traninfo,
_pCfg );
- currtran->showMaximized();
- if ( currtran->exec() == QDialog::Accepted )
+ if ( QPEApplication::execDialog( currtran ) == QDialog::Accepted )
{
curritem->setText( COL_NUM, traninfo->number() );
curritem->setText( COL_SORTDATE, traninfo->datestr(false) );
curritem->setText( COL_DATE, traninfo->datestr(true) );
curritem->setText( COL_DESC, traninfo->desc() );
float amount = traninfo->amount();
if ( traninfo->withdrawal() )
{
amount *= -1;
}
QString stramount;