diff options
Diffstat (limited to 'kmymoney2/dialogs/knewloanwizard.cpp')
-rw-r--r-- | kmymoney2/dialogs/knewloanwizard.cpp | 232 |
1 files changed, 116 insertions, 116 deletions
diff --git a/kmymoney2/dialogs/knewloanwizard.cpp b/kmymoney2/dialogs/knewloanwizard.cpp index 28c48ef..e56dbf9 100644 --- a/kmymoney2/dialogs/knewloanwizard.cpp +++ b/kmymoney2/dialogs/knewloanwizard.cpp @@ -25,9 +25,9 @@ // ---------------------------------------------------------------------------- // QT Includes -#include <qradiobutton.h> -#include <qcheckbox.h> -#include <qlabel.h> +#include <tqradiobutton.h> +#include <tqcheckbox.h> +#include <tqlabel.h> // ---------------------------------------------------------------------------- // KDE Includes @@ -59,38 +59,38 @@ #include "../kmymoney2.h" -KNewLoanWizard::KNewLoanWizard(QWidget *parent, const char *name ) : - KNewLoanWizardDecl(parent, name, true) +KNewLoanWizard::KNewLoanWizard(TQWidget *tqparent, const char *name ) : + KNewLoanWizardDecl(tqparent, name, true) { - connect(m_borrowButton, SIGNAL(clicked()), this, SLOT(slotLiabilityLoan())); - connect(m_lendButton, SIGNAL(clicked()), this, SLOT(slotAssetLoan())); + connect(m_borrowButton, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotLiabilityLoan())); + connect(m_lendButton, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotAssetLoan())); - connect(m_nameEdit, SIGNAL(textChanged(const QString&)), this, SLOT(slotCheckPageFinished())); - // connect(m_payeeEdit, SIGNAL(newPayee(const QString&)), this, SLOT(slotNewPayee(const QString&))); - connect(m_payeeEdit, SIGNAL(createItem(const QString&, QString&)), this, SIGNAL(createPayee(const QString&, QString&))); + connect(m_nameEdit, TQT_SIGNAL(textChanged(const TQString&)), this, TQT_SLOT(slotCheckPageFinished())); + // connect(m_payeeEdit, TQT_SIGNAL(newPayee(const TQString&)), this, TQT_SLOT(slotNewPayee(const TQString&))); + connect(m_payeeEdit, TQT_SIGNAL(createItem(const TQString&, TQString&)), this, TQT_SIGNAL(createPayee(const TQString&, TQString&))); - connect(m_previousPaymentButton, SIGNAL(clicked()), this, SLOT(slotPaymentsMade())); - connect(m_noPreviousPaymentButton, SIGNAL(clicked()), this, SLOT(slotNoPaymentsMade())); + connect(m_previousPaymentButton, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotPaymentsMade())); + connect(m_noPreviousPaymentButton, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotNoPaymentsMade())); - connect(m_allPaymentsButton, SIGNAL(clicked()), this, SLOT(slotRecordAllPayments())); - connect(m_thisYearPaymentButton, SIGNAL(clicked()), this, SLOT(slotRecordThisYearsPayments())); + connect(m_allPaymentsButton, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotRecordAllPayments())); + connect(m_thisYearPaymentButton, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotRecordThisYearsPayments())); - connect(m_firstDueDateEdit, SIGNAL(dateChanged(const QDate&)), this, SLOT(slotCheckPageFinished())); + connect(m_firstDueDateEdit, TQT_SIGNAL(dateChanged(const TQDate&)), this, TQT_SLOT(slotCheckPageFinished())); - connect(m_interestOnPaymentButton, SIGNAL(clicked()), this, SLOT(slotInterestOnPayment())); - connect(m_interestOnReceptionButton, SIGNAL(clicked()), this, SLOT(slotInterestOnReception())); + connect(m_interestOnPaymentButton, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotInterestOnPayment())); + connect(m_interestOnReceptionButton, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotInterestOnReception())); - connect(m_loanAmountEdit, SIGNAL(textChanged(const QString&)), this, SLOT(slotCheckPageFinished())); + connect(m_loanAmountEdit, TQT_SIGNAL(textChanged(const TQString&)), this, TQT_SLOT(slotCheckPageFinished())); - connect(m_interestAccountEdit, SIGNAL(stateChanged()), this, SLOT(slotCheckPageFinished())); + connect(m_interestAccountEdit, TQT_SIGNAL(stateChanged()), this, TQT_SLOT(slotCheckPageFinished())); - connect(m_nextDueDateEdit, SIGNAL(dateChanged(const QDate&)), this, SLOT(slotCheckPageFinished())); - connect(m_paymentAccountEdit, SIGNAL(stateChanged()), this, SLOT(slotCheckPageFinished())); + connect(m_nextDueDateEdit, TQT_SIGNAL(dateChanged(const TQDate&)), this, TQT_SLOT(slotCheckPageFinished())); + connect(m_paymentAccountEdit, TQT_SIGNAL(stateChanged()), this, TQT_SLOT(slotCheckPageFinished())); - connect(m_assetAccountEdit, SIGNAL(stateChanged()), this, SLOT(slotCheckPageFinished())); - connect(m_dontCreatePayoutCheckBox, SIGNAL(clicked()), this, SLOT(slotCheckPageFinished())); + connect(m_assetAccountEdit, TQT_SIGNAL(stateChanged()), this, TQT_SLOT(slotCheckPageFinished())); + connect(m_dontCreatePayoutCheckBox, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotCheckPageFinished())); - connect(MyMoneyFile::instance(), SIGNAL(dataChanged()), this, SLOT(slotReloadEditWidgets())); + connect(MyMoneyFile::instance(), TQT_SIGNAL(dataChanged()), this, TQT_SLOT(slotReloadEditWidgets())); loadComboBoxes(); @@ -111,7 +111,7 @@ KNewLoanWizard::KNewLoanWizard(QWidget *parent, const char *name ) : m_interestFrequencyAmountEdit->setValue(1); m_interestFrequencyUnitEdit->setCurrentItem(static_cast<int>(MyMoneyAccountLoan::changeYearly)); m_paymentFrequencyUnitEdit->setCurrentItem(i18n(MyMoneySchedule::occurenceToString(MyMoneySchedule::OCCUR_MONTHLY))); - m_firstDueDateEdit->loadDate(QDate(QDate::currentDate().year(),QDate::currentDate().month(),30)); + m_firstDueDateEdit->loadDate(TQDate(TQDate::tqcurrentDate().year(),TQDate::tqcurrentDate().month(),30)); m_paymentAccountEdit->removeButtons(); m_assetAccountEdit->removeButtons(); @@ -120,25 +120,25 @@ KNewLoanWizard::KNewLoanWizard(QWidget *parent, const char *name ) : // load button icons KIconLoader* il = KGlobal::iconLoader(); KGuiItem createCategoryButtenItem( i18n( "&Create..." ), - QIconSet(il->loadIcon("filenew", KIcon::Small, KIcon::SizeSmall)), + TQIconSet(il->loadIcon("filenew", KIcon::Small, KIcon::SizeSmall)), i18n("Create a new category"), i18n("Use this to open the new account editor")); m_createCategoryButton->setGuiItem(createCategoryButtenItem); - connect(m_createCategoryButton, SIGNAL(clicked()), this, SLOT(slotCreateCategory())); + connect(m_createCategoryButton, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotCreateCategory())); KGuiItem additionalFeeButtenItem( i18n( "&Additional fees..." ), - 0, //QIconSet(il->loadIcon("filenew", KIcon::Small, KIcon::SizeSmall)), + 0, //TQIconSet(il->loadIcon("filenew", KIcon::Small, KIcon::SizeSmall)), i18n("Enter additional fees"), i18n("Use this to add any additional fees other than principal and interest contained in your periodical payments.")); m_additionalFeeButton->setGuiItem(additionalFeeButtenItem); - connect(m_additionalFeeButton, SIGNAL(clicked()), this, SLOT(slotAdditionalFees())); + connect(m_additionalFeeButton, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotAdditionalFees())); KGuiItem createAssetButtenItem( i18n( "&Create..." ), - QIconSet(il->loadIcon("filenew", KIcon::Small, KIcon::SizeSmall)), + TQIconSet(il->loadIcon("filenew", KIcon::Small, KIcon::SizeSmall)), i18n("Create a new asset account"), i18n("Use this to create a new account to which the initial payment should be made")); m_createNewAssetButton->setGuiItem(createAssetButtenItem); - connect(m_createNewAssetButton, SIGNAL(clicked()), kmymoney2, SLOT(slotAccountNew())); + connect(m_createNewAssetButton, TQT_SIGNAL(clicked()), kmymoney2, TQT_SLOT(slotAccountNew())); // enable the finish button on the last page setFinishEnabled(m_summaryPage, true); @@ -170,35 +170,35 @@ KNewLoanWizard::~KNewLoanWizard() void KNewLoanWizard::resetCalculator(void) { - m_loanAmount1->setText(QString()); - m_interestRate1->setText(QString()); - m_duration1->setText(QString()); - m_payment1->setText(QString()); - m_balloon1->setText(QString()); - - m_loanAmount2->setText(QString()); - m_interestRate2->setText(QString()); - m_duration2->setText(QString()); - m_payment2->setText(QString()); - m_balloon2->setText(QString()); - - m_loanAmount3->setText(QString()); - m_interestRate3->setText(QString()); - m_duration3->setText(QString()); - m_payment3->setText(QString()); - m_balloon3->setText(QString()); - - m_loanAmount4->setText(QString()); - m_interestRate4->setText(QString()); - m_duration4->setText(QString()); - m_payment4->setText(QString()); - m_balloon4->setText(QString()); - - m_loanAmount5->setText(QString()); - m_interestRate5->setText(QString()); - m_duration5->setText(QString()); - m_payment5->setText(QString()); - m_balloon5->setText(QString()); + m_loanAmount1->setText(TQString()); + m_interestRate1->setText(TQString()); + m_duration1->setText(TQString()); + m_payment1->setText(TQString()); + m_balloon1->setText(TQString()); + + m_loanAmount2->setText(TQString()); + m_interestRate2->setText(TQString()); + m_duration2->setText(TQString()); + m_payment2->setText(TQString()); + m_balloon2->setText(TQString()); + + m_loanAmount3->setText(TQString()); + m_interestRate3->setText(TQString()); + m_duration3->setText(TQString()); + m_payment3->setText(TQString()); + m_balloon3->setText(TQString()); + + m_loanAmount4->setText(TQString()); + m_interestRate4->setText(TQString()); + m_duration4->setText(TQString()); + m_payment4->setText(TQString()); + m_balloon4->setText(TQString()); + + m_loanAmount5->setText(TQString()); + m_interestRate5->setText(TQString()); + m_duration5->setText(TQString()); + m_payment5->setText(TQString()); + m_balloon5->setText(TQString()); m_additionalCost->setText(MyMoneyMoney(0).formatMoney(m_account.fraction(MyMoneyFile::instance()->security(m_account.currencyId())))); } @@ -229,14 +229,14 @@ void KNewLoanWizard::slotNoPaymentsMade(void) void KNewLoanWizard::slotRecordAllPayments(void) { m_firstPaymentLabel->setText( - QString("\n") + + TQString("\n") + i18n("Please enter the date, the first payment for this loan was/is due.")); m_firstPaymentNote->setText( i18n("Note: Consult the loan contract for details of the first due date. " "Keep in mind, that the first due date usually differs from the date " "the contract was signed")); m_balanceLabel->setText( - QString("\n") + + TQString("\n") + i18n("Please enter the original loan amount in the field below or leave it " "empty to be calculated.")); } @@ -244,13 +244,13 @@ void KNewLoanWizard::slotRecordAllPayments(void) void KNewLoanWizard::slotRecordThisYearsPayments(void) { m_firstPaymentLabel->setText( - QString("\n") + + TQString("\n") + i18n("Please enter the date, the first payment for this loan was/is due this year.")); m_firstPaymentNote->setText( i18n("Note: You can easily figure out the date of the first payment " "if you consult the last statement of last year.")); m_balanceLabel->setText( - QString("\n") + + TQString("\n") + i18n("Please enter the remaining loan amount of last years final " "statement in the field below. You should not leave this field empty.")); } @@ -306,9 +306,9 @@ void KNewLoanWizard::slotCheckPageFinished(void) void KNewLoanWizard::updateLoanAmount(void) { - QString txt; + TQString txt; if(m_loanAmountEdit->lineedit()->text().isEmpty()) { - txt = QString("<") + i18n("calculate") + QString(">"); + txt = TQString("<") + i18n("calculate") + TQString(">"); } else { txt = m_loanAmountEdit->value().formatMoney(m_account.fraction(MyMoneyFile::instance()->security(m_account.currencyId()))); } @@ -321,11 +321,11 @@ void KNewLoanWizard::updateLoanAmount(void) void KNewLoanWizard::updateInterestRate(void) { - QString txt; + TQString txt; if(m_interestRateEdit->lineedit()->text().isEmpty()) { - txt = QString("<") + i18n("calculate") + QString(">"); + txt = TQString("<") + i18n("calculate") + TQString(">"); } else { - txt = m_interestRateEdit->value().formatMoney("", 3) + QString("%"); + txt = m_interestRateEdit->value().formatMoney("", 3) + TQString("%"); } m_interestRate1->setText(txt); m_interestRate2->setText(txt); @@ -336,11 +336,11 @@ void KNewLoanWizard::updateInterestRate(void) void KNewLoanWizard::updateDuration(void) { - QString txt; + TQString txt; if(m_durationValueEdit->value() == 0) { - txt = QString("<") + i18n("calculate") + QString(">"); + txt = TQString("<") + i18n("calculate") + TQString(">"); } else { - txt = QString().sprintf("%d ", m_durationValueEdit->value()) + txt = TQString().sprintf("%d ", m_durationValueEdit->value()) + m_durationUnitEdit->currentText(); } m_duration1->setText(txt); @@ -352,9 +352,9 @@ void KNewLoanWizard::updateDuration(void) void KNewLoanWizard::updatePayment(void) { - QString txt; + TQString txt; if(m_paymentEdit->lineedit()->text().isEmpty()) { - txt = QString("<") + i18n("calculate") + QString(">"); + txt = TQString("<") + i18n("calculate") + TQString(">"); } else { txt = m_paymentEdit->value().formatMoney(m_account.fraction(MyMoneyFile::instance()->security(m_account.currencyId()))); } @@ -368,9 +368,9 @@ void KNewLoanWizard::updatePayment(void) void KNewLoanWizard::updateFinalPayment(void) { - QString txt; + TQString txt; if(m_finalPaymentEdit->lineedit()->text().isEmpty()) { - txt = QString("<") + i18n("calculate") + QString(">"); + txt = TQString("<") + i18n("calculate") + TQString(">"); } else { txt = m_finalPaymentEdit->value().formatMoney(m_account.fraction(MyMoneyFile::instance()->security(m_account.currencyId()))); } @@ -390,12 +390,12 @@ void KNewLoanWizard::updateLoanInfo(void) updateFinalPayment(); updatePeriodicPayment(); - QString txt; + TQString txt; int fraction = m_account.fraction(MyMoneyFile::instance()->security(m_account.currencyId())); m_loanAmount6->setText(m_loanAmountEdit->value().formatMoney(fraction)); - m_interestRate6->setText(m_interestRateEdit->value().formatMoney("", 3) + QString("%")); - txt = QString().sprintf("%d ", m_durationValueEdit->value()) + m_interestRate6->setText(m_interestRateEdit->value().formatMoney("", 3) + TQString("%")); + txt = TQString().sprintf("%d ", m_durationValueEdit->value()) + m_durationUnitEdit->currentText(); m_duration6->setText(txt); m_payment6->setText(m_paymentEdit->value().formatMoney(fraction)); @@ -439,7 +439,7 @@ void KNewLoanWizard::updateSummary(void) // Payment try { - QStringList sel = m_interestAccountEdit->selectedItems(); + TQStringList sel = m_interestAccountEdit->selectedItems(); if(sel.count() != 1) throw new MYMONEYEXCEPTION("Need a single selected interest category"); MyMoneyAccount acc = MyMoneyFile::instance()->account(sel.first()); @@ -453,7 +453,7 @@ void KNewLoanWizard::updateSummary(void) m_summaryNextPayment->setText(KGlobal::locale()->formatDate(m_nextDueDateEdit->date(), true)); try { - QStringList sel = m_paymentAccountEdit->selectedItems(); + TQStringList sel = m_paymentAccountEdit->selectedItems(); if(sel.count() != 1) throw new MYMONEYEXCEPTION("Need a single selected payment account"); MyMoneyAccount acc = MyMoneyFile::instance()->account(sel.first()); @@ -467,7 +467,7 @@ void KNewLoanWizard::updateSummary(void) void KNewLoanWizard::next() { bool dontLeavePage = false; - QString errMsg = i18n( + TQString errMsg = i18n( "The loan wizard is unable to calculate two different values for your loan " "at the same time. " "Please enter a value for the %1 on this page or backup to the page where the " @@ -510,7 +510,7 @@ void KNewLoanWizard::next() if(m_loanAmountEdit->lineedit()->text().isEmpty() && m_interestRateEdit->lineedit()->text().isEmpty()) { dontLeavePage = true; - KMessageBox::error(0, errMsg.arg(i18n("interest rate")), i18n("Calculation error")); + KMessageBox::error(0, errMsg.tqarg(i18n("interest rate")), i18n("Calculation error")); } else updateInterestRate(); @@ -519,7 +519,7 @@ void KNewLoanWizard::next() || m_interestRateEdit->lineedit()->text().isEmpty()) && m_durationValueEdit->value() == 0) { dontLeavePage = true; - KMessageBox::error(0, errMsg.arg(i18n("term")), i18n("Calculation error")); + KMessageBox::error(0, errMsg.tqarg(i18n("term")), i18n("Calculation error")); } else updateDuration(); @@ -529,7 +529,7 @@ void KNewLoanWizard::next() || m_durationValueEdit->value() == 0) && m_paymentEdit->lineedit()->text().isEmpty()) { dontLeavePage = true; - KMessageBox::error(0, errMsg.arg(i18n("principal and interest")), i18n("Calculation error")); + KMessageBox::error(0, errMsg.tqarg(i18n("principal and interest")), i18n("Calculation error")); } else updatePayment(); @@ -557,7 +557,7 @@ void KNewLoanWizard::next() if(m_assetAccountPage) setAppropriate(m_assetAccountPage, true); } else { - QDate nextPayment(QDate::currentDate().year(), 1, m_firstDueDateEdit->date().day()); + TQDate nextPayment(TQDate::tqcurrentDate().year(), 1, m_firstDueDateEdit->date().day()); m_nextDueDateEdit->setDate(nextPayment); if(m_assetAccountPage) setAppropriate(m_assetAccountPage, false); @@ -626,7 +626,7 @@ void KNewLoanWizard::loadComboBoxes(void) m_paymentFrequencyUnitEdit->insertItem(i18n(MyMoneySchedule::occurenceToString(MyMoneySchedule::OCCUR_MONTHLY))); m_paymentFrequencyUnitEdit->insertItem(i18n(MyMoneySchedule::occurenceToString(MyMoneySchedule::OCCUR_EVERYEIGHTWEEKS))); m_paymentFrequencyUnitEdit->insertItem(i18n(MyMoneySchedule::occurenceToString(MyMoneySchedule::OCCUR_EVERYOTHERMONTH))); - m_paymentFrequencyUnitEdit->insertItem(i18n(MyMoneySchedule::occurenceToString(MyMoneySchedule::OCCUR_QUARTERLY))); + m_paymentFrequencyUnitEdit->insertItem(i18n(MyMoneySchedule::occurenceToString(MyMoneySchedule::OCCUR_TQUARTERLY))); m_paymentFrequencyUnitEdit->insertItem(i18n(MyMoneySchedule::occurenceToString(MyMoneySchedule::OCCUR_EVERYFOURMONTHS))); m_paymentFrequencyUnitEdit->insertItem(i18n(MyMoneySchedule::occurenceToString(MyMoneySchedule::OCCUR_TWICEYEARLY))); m_paymentFrequencyUnitEdit->insertItem(i18n(MyMoneySchedule::occurenceToString(MyMoneySchedule::OCCUR_YEARLY))); @@ -654,7 +654,7 @@ int KNewLoanWizard::calculateLoan(void) MyMoneyFinancialCalculator calc; long double val; int PF; - QString result; + TQString result; // FIXME: for now, we only support interest calculation at the end of the period calc.setBep(); @@ -709,14 +709,14 @@ int KNewLoanWizard::calculateLoan(void) val = calc.presentValue(); m_loanAmountEdit->loadText(MyMoneyMoney(static_cast<double>(val)).abs().formatMoney(fraction)); result = i18n("KMyMoney has calculated the amount of the loan as %1.") - .arg(m_loanAmountEdit->lineedit()->text()); + .tqarg(m_loanAmountEdit->lineedit()->text()); } else if(m_interestRateEdit->lineedit()->text().isEmpty()) { // calculate the interest rate out of the other information val = calc.interestRate(); m_interestRateEdit->loadText(MyMoneyMoney(static_cast<double>(val)).abs().formatMoney("", 3)); result = i18n("KMyMoney has calculated the interest rate to %1%.") - .arg(m_interestRateEdit->lineedit()->text()); + .tqarg(m_interestRateEdit->lineedit()->text()); } else if(m_paymentEdit->lineedit()->text().isEmpty()) { // calculate the periodical amount of the payment out of the other information @@ -729,7 +729,7 @@ int KNewLoanWizard::calculateLoan(void) calc.setPmt(val); result = i18n("KMyMoney has calculated a periodic payment of %1 to cover principal and interest.") - .arg(m_paymentEdit->lineedit()->text()); + .tqarg(m_paymentEdit->lineedit()->text()); val = calc.futureValue(); if((m_borrowButton->isChecked() && val < 0 && fabsl(val) >= fabsl(calc.payment())) @@ -739,9 +739,9 @@ int KNewLoanWizard::calculateLoan(void) val = calc.futureValue(); MyMoneyMoney refVal(static_cast<double>(val)); m_finalPaymentEdit->loadText(refVal.abs().formatMoney(fraction)); - result += QString(" "); + result += TQString(" "); result += i18n("The number of payments has been decremented and the final payment has been modified to %1.") - .arg(m_finalPaymentEdit->lineedit()->text()); + .tqarg(m_finalPaymentEdit->lineedit()->text()); } else if((m_borrowButton->isChecked() && val < 0 && fabsl(val) < fabsl(calc.payment())) || (m_lendButton->isChecked() && val > 0 && fabs(val) < fabs(calc.payment()))) { m_finalPaymentEdit->loadText(MyMoneyMoney(0,1).formatMoney(fraction)); @@ -749,7 +749,7 @@ int KNewLoanWizard::calculateLoan(void) MyMoneyMoney refVal(static_cast<double>(val)); m_finalPaymentEdit->loadText(refVal.abs().formatMoney(fraction)); result += i18n("The final payment has been modified to %1.") - .arg(m_finalPaymentEdit->lineedit()->text()); + .tqarg(m_finalPaymentEdit->lineedit()->text()); } } else if(m_durationValueEdit->value() == 0) { @@ -761,7 +761,7 @@ int KNewLoanWizard::calculateLoan(void) // if the number of payments has a fractional part, then we // round it to the smallest integer and calculate the balloon payment result = i18n("KMyMoney has calculated the term of your loan as %1. ") - .arg(updateTermWidgets(floorl(val))); + .tqarg(updateTermWidgets(floorl(val))); if(val != floorl(val)) { calc.setNpp(floorl(val)); @@ -769,7 +769,7 @@ int KNewLoanWizard::calculateLoan(void) MyMoneyMoney refVal(static_cast<double>(val)); m_finalPaymentEdit->loadText(refVal.abs().formatMoney(fraction)); result += i18n("The final payment has been modified to %1.") - .arg(m_finalPaymentEdit->lineedit()->text()); + .tqarg(m_finalPaymentEdit->lineedit()->text()); } } else { @@ -800,7 +800,7 @@ int KNewLoanWizard::calculateLoan(void) MyMoneyMoney refVal(static_cast<double>(val)); result = i18n("KMyMoney has calculated a final payment of %1 for this loan.") - .arg(refVal.abs().formatMoney(fraction)); + .tqarg(refVal.abs().formatMoney(fraction)); if(!m_finalPaymentEdit->lineedit()->text().isEmpty()) { if((m_finalPaymentEdit->value().abs() - refVal.abs()).abs().toDouble() > 1) { @@ -827,11 +827,11 @@ int KNewLoanWizard::calculateLoan(void) return 1; } -QString KNewLoanWizard::updateTermWidgets(const long double val) +TQString KNewLoanWizard::updateTermWidgets(const long double val) { long long vl = static_cast<long long>(floorl(val)); - QString valString; + TQString valString; MyMoneySchedule::occurenceE unit; unit = MyMoneySchedule::stringToOccurence(m_paymentFrequencyUnitEdit->currentText()); @@ -874,12 +874,12 @@ void KNewLoanWizard::slotCreateCategory(void) acc.setParentAccountId(base.id()); KNewAccountDlg* dlg = new KNewAccountDlg(acc, true, true); - if(dlg->exec() == QDialog::Accepted) { + if(dlg->exec() == TQDialog::Accepted) { acc = dlg->account(); MyMoneyFileTransaction ft; try { - QString id; + TQString id; id = file->createCategory(base, acc.name()); if(id.isEmpty()) throw new MYMONEYEXCEPTION("failure while creating the account hierarchy"); @@ -889,7 +889,7 @@ void KNewLoanWizard::slotCreateCategory(void) m_interestAccountEdit->setSelected(id); } catch (MyMoneyException *e) { - KMessageBox::information(this, i18n("Unable to add account: %1").arg(e->what())); + KMessageBox::information(this, i18n("Unable to add account: %1").tqarg(e->what())); delete e; } } @@ -921,17 +921,17 @@ void KNewLoanWizard::loadAccountList(void) void KNewLoanWizard::slotAdditionalFees(void) { - // KMessageBox::information(0, QString("Not yet implemented ... if you want to help, contact kmymoney2-developer@lists.sourceforge.net"), QString("Development notice")); + // KMessageBox::information(0, TQString("Not yet implemented ... if you want to help, contact kmymoney2-developer@lists.sourceforge.net"), TQString("Development notice")); MyMoneyAccount account("Phony-ID", MyMoneyAccount()); - QMap<QString, MyMoneyMoney> priceInfo; + TQMap<TQString, MyMoneyMoney> priceInfo; KSplitTransactionDlg* dlg = new KSplitTransactionDlg(m_transaction, m_split, account, false, !m_borrowButton->isChecked(), MyMoneyMoney(0), priceInfo); - connect(dlg, SIGNAL(newCategory(MyMoneyAccount&)), this, SIGNAL(newCategory(MyMoneyAccount&))); + connect(dlg, TQT_SIGNAL(newCategory(MyMoneyAccount&)), this, TQT_SIGNAL(newCategory(MyMoneyAccount&))); - if(dlg->exec() == QDialog::Accepted) { + if(dlg->exec() == TQDialog::Accepted) { m_transaction = dlg->transaction(); // sum up the additional fees - QValueList<MyMoneySplit>::ConstIterator it; + TQValueList<MyMoneySplit>::ConstIterator it; MyMoneyMoney fees; for(it = m_transaction.splits().begin(); it != m_transaction.splits().end(); ++it) { @@ -980,7 +980,7 @@ MyMoneyTransaction KNewLoanWizard::transaction() const sInterest.setAction(MyMoneySplit::ActionInterest); // payee - QString payeeId = m_payeeEdit->selectedItem(); + TQString payeeId = m_payeeEdit->selectedItem(); sPayment.setPayeeId(payeeId); sAmortization.setPayeeId(payeeId); @@ -994,7 +994,7 @@ MyMoneyTransaction KNewLoanWizard::transaction() const t.addSplit(sInterest); // copy the splits from the other costs and update the payment split - QValueList<MyMoneySplit>::ConstIterator it; + TQValueList<MyMoneySplit>::ConstIterator it; for(it = m_transaction.splits().begin(); it != m_transaction.splits().end(); ++it) { if((*it).accountId() != account.id()) { MyMoneySplit sp = (*it); @@ -1014,8 +1014,8 @@ MyMoneySchedule KNewLoanWizard::schedule(void) const MyMoneySchedule::TYPE_LOANPAYMENT, MyMoneySchedule::stringToOccurence(m_paymentFrequencyUnitEdit->currentText()), 1, MyMoneySchedule::STYPE_OTHER, - QDate(), - QDate(), + TQDate(), + TQDate(), false, false); @@ -1032,7 +1032,7 @@ void KNewLoanWizard::slotReloadEditWidgets(void) loadAccountList(); // reload payee widget - QString payeeId = m_payeeEdit->selectedItem(); + TQString payeeId = m_payeeEdit->selectedItem(); m_payeeEdit->loadPayees(MyMoneyFile::instance()->payeeList()); @@ -1069,18 +1069,18 @@ int KNewLoanWizard::term(void) const return factor; } -QString KNewLoanWizard::initialPaymentAccount(void) const +TQString KNewLoanWizard::initialPaymentAccount(void) const { if(m_dontCreatePayoutCheckBox->isChecked()) { - return QString(); + return TQString(); } return m_assetAccountEdit->selectedItems().first(); } -QDate KNewLoanWizard::initialPaymentDate(void) const +TQDate KNewLoanWizard::initialPaymentDate(void) const { if(m_dontCreatePayoutCheckBox->isChecked()) { - return QDate(); + return TQDate(); } return m_paymentDate->date(); } |