summaryrefslogtreecommitdiffstats
path: root/kmymoney2/dialogs/kfindtransactiondlg.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'kmymoney2/dialogs/kfindtransactiondlg.cpp')
-rw-r--r--kmymoney2/dialogs/kfindtransactiondlg.cpp236
1 files changed, 118 insertions, 118 deletions
diff --git a/kmymoney2/dialogs/kfindtransactiondlg.cpp b/kmymoney2/dialogs/kfindtransactiondlg.cpp
index f122ba2..a1d5214 100644
--- a/kmymoney2/dialogs/kfindtransactiondlg.cpp
+++ b/kmymoney2/dialogs/kfindtransactiondlg.cpp
@@ -17,12 +17,12 @@
// ----------------------------------------------------------------------------
// QT Includes
-#include <qlabel.h>
-#include <qradiobutton.h>
-#include <qcheckbox.h>
-#include <qtimer.h>
-#include <qtabwidget.h>
-#include <qlayout.h>
+#include <tqlabel.h>
+#include <tqradiobutton.h>
+#include <tqcheckbox.h>
+#include <tqtimer.h>
+#include <tqtabwidget.h>
+#include <tqlayout.h>
// ----------------------------------------------------------------------------
// KDE Includes
@@ -56,15 +56,15 @@
#include "ksortoptiondlg.h"
-KFindTransactionDlg::KFindTransactionDlg(QWidget *parent, const char *name) :
- KFindTransactionDlgDecl(parent, name, false),
+KFindTransactionDlg::KFindTransactionDlg(TQWidget *tqparent, const char *name) :
+ KFindTransactionDlgDecl(tqparent, name, false),
m_needReload(false)
{
m_register->installEventFilter(this);
m_tabWidget->setTabEnabled(m_resultPage, false);
// 'cause we don't have a separate setupTextPage
- connect(m_textEdit, SIGNAL(textChanged(const QString&)), this, SLOT(slotUpdateSelections()));
+ connect(m_textEdit, TQT_SIGNAL(textChanged(const TQString&)), this, TQT_SLOT(slotUpdateSelections()));
setupAccountsPage();
setupCategoriesPage();
@@ -74,16 +74,16 @@ KFindTransactionDlg::KFindTransactionDlg(QWidget *parent, const char *name) :
setupDetailsPage();
// We don't need to add the default into the list (see ::slotShowHelp() why)
- // m_helpAnchor[m_textTab] = QString("details.search");
- m_helpAnchor[m_accountTab] = QString("details.search.account");
- m_helpAnchor[m_dateTab] = QString("details.search.date");
- m_helpAnchor[m_amountTab] = QString("details.search.amount");
- m_helpAnchor[m_categoryTab] = QString("details.search.category");
- m_helpAnchor[m_payeeTab] = QString("details.search.payee");
- m_helpAnchor[m_detailsTab] = QString("details.search.details");
+ // m_helpAnchor[m_textTab] = TQString("details.search");
+ m_helpAnchor[m_accountTab] = TQString("details.search.account");
+ m_helpAnchor[m_dateTab] = TQString("details.search.date");
+ m_helpAnchor[m_amountTab] = TQString("details.search.amount");
+ m_helpAnchor[m_categoryTab] = TQString("details.search.category");
+ m_helpAnchor[m_payeeTab] = TQString("details.search.payee");
+ m_helpAnchor[m_detailsTab] = TQString("details.search.details");
// setup the register
- QValueList<KMyMoneyRegister::Column> cols;
+ TQValueList<KMyMoneyRegister::Column> cols;
cols << KMyMoneyRegister::DateColumn;
cols << KMyMoneyRegister::AccountColumn;
cols << KMyMoneyRegister::DetailColumn;
@@ -91,26 +91,26 @@ KFindTransactionDlg::KFindTransactionDlg(QWidget *parent, const char *name) :
cols << KMyMoneyRegister::PaymentColumn;
cols << KMyMoneyRegister::DepositColumn;
m_register->setupRegister(MyMoneyAccount(), cols);
- m_register->setSelectionMode(QTable::Single);
+ m_register->setSelectionMode(TQTable::Single);
- connect(m_register, SIGNAL(editTransaction()), this, SLOT(slotSelectTransaction()));
- connect(m_register, SIGNAL(headerClicked()), this, SLOT(slotSortOptions()));
+ connect(m_register, TQT_SIGNAL(editTransaction()), this, TQT_SLOT(slotSelectTransaction()));
+ connect(m_register, TQT_SIGNAL(headerClicked()), this, TQT_SLOT(slotSortOptions()));
slotUpdateSelections();
// setup the connections
- connect(m_searchButton, SIGNAL(clicked()), this, SLOT(slotSearch()));
- connect(m_resetButton, SIGNAL(clicked()), this, SLOT(slotReset()));
- connect(m_resetButton, SIGNAL(clicked()), m_accountsView, SLOT(slotSelectAllAccounts()));
- connect(m_resetButton, SIGNAL(clicked()), m_categoriesView, SLOT(slotSelectAllAccounts()));
- connect(m_closeButton, SIGNAL(clicked()), this, SLOT(deleteLater()));
- connect(m_helpButton, SIGNAL(clicked()), this, SLOT(slotShowHelp()));
+ connect(m_searchButton, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotSearch()));
+ connect(m_resetButton, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotReset()));
+ connect(m_resetButton, TQT_SIGNAL(clicked()), m_accountsView, TQT_SLOT(slotSelectAllAccounts()));
+ connect(m_resetButton, TQT_SIGNAL(clicked()), m_categoriesView, TQT_SLOT(slotSelectAllAccounts()));
+ connect(m_closeButton, TQT_SIGNAL(clicked()), this, TQT_SLOT(deleteLater()));
+ connect(m_helpButton, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotShowHelp()));
// only allow searches when a selection has been made
- connect(this, SIGNAL(selectionEmpty(bool)), m_searchButton, SLOT(setDisabled(bool)));
+ connect(this, TQT_SIGNAL(selectionEmpty(bool)), m_searchButton, TQT_SLOT(setDisabled(bool)));
// get signal about engine changes
- connect(MyMoneyFile::instance(), SIGNAL(dataChanged()), this, SLOT(slotRefreshView()));
+ connect(MyMoneyFile::instance(), TQT_SIGNAL(dataChanged()), this, TQT_SLOT(slotRefreshView()));
slotUpdateSelections();
@@ -119,7 +119,7 @@ KFindTransactionDlg::KFindTransactionDlg(QWidget *parent, const char *name) :
void KFindTransactionDlg::slotReset(void)
{
- m_textEdit->setText(QString());
+ m_textEdit->setText(TQString());
m_regExp->setChecked(false);
m_caseSensitive->setChecked(false);
m_textNegate->setCurrentItem(0);
@@ -127,9 +127,9 @@ void KFindTransactionDlg::slotReset(void)
m_amountEdit->setEnabled(true);
m_amountFromEdit->setEnabled(false);
m_amountToEdit->setEnabled(false);
- m_amountEdit->loadText(QString());
- m_amountFromEdit->loadText(QString());
- m_amountToEdit->loadText(QString());
+ m_amountEdit->loadText(TQString());
+ m_amountFromEdit->loadText(TQString());
+ m_amountToEdit->loadText(TQString());
m_amountButton->setChecked(true);
m_amountRangeButton->setChecked(false);
@@ -143,9 +143,9 @@ void KFindTransactionDlg::slotReset(void)
m_nrEdit->setEnabled(true);
m_nrFromEdit->setEnabled(false);
m_nrToEdit->setEnabled(false);
- m_nrEdit->setText(QString());
- m_nrFromEdit->setText(QString());
- m_nrToEdit->setText(QString());
+ m_nrEdit->setText(TQString());
+ m_nrFromEdit->setText(TQString());
+ m_nrToEdit->setText(TQString());
m_nrButton->setChecked(true);
m_nrRangeButton->setChecked(false);
@@ -160,14 +160,14 @@ void KFindTransactionDlg::slotReset(void)
void KFindTransactionDlg::slotUpdateSelections(void)
{
- QString txt;
+ TQString txt;
// Text tab
if(!m_textEdit->text().isEmpty()) {
if(!txt.isEmpty())
txt += ", ";
txt += i18n("Text");
- m_regExp->setEnabled(QRegExp(m_textEdit->text()).isValid());
+ m_regExp->setEnabled(TQRegExp(m_textEdit->text()).isValid());
} else
m_regExp->setEnabled(false);
@@ -241,13 +241,13 @@ void KFindTransactionDlg::slotUpdateSelections(void)
m_selectedCriteria->setText(i18n("Current selections: ") + txt);
}
-bool KFindTransactionDlg::allItemsSelected(const QListViewItem *item) const
+bool KFindTransactionDlg::allItemsSelected(const TQListViewItem *item) const
{
- QListViewItem* it_v;
+ TQListViewItem* it_v;
for(it_v = item->firstChild(); it_v != 0; it_v = it_v->nextSibling()) {
if(it_v->rtti() == 1) {
- QCheckListItem* it_c = static_cast<QCheckListItem*>(it_v);
+ TQCheckListItem* it_c = static_cast<TQCheckListItem*>(it_v);
if(!(it_c->isOn() && allItemsSelected(it_v)))
return false;
}
@@ -255,14 +255,14 @@ bool KFindTransactionDlg::allItemsSelected(const QListViewItem *item) const
return true;
}
-bool KFindTransactionDlg::allItemsSelected(const QListView* view) const
+bool KFindTransactionDlg::allItemsSelected(const TQListView* view) const
{
- QListViewItem* it_v;
+ TQListViewItem* it_v;
for(it_v = view->firstChild(); it_v != 0; it_v = it_v->nextSibling()) {
if(it_v->rtti() == 1) {
- QCheckListItem* it_c = static_cast<QCheckListItem*>(it_v);
- if(it_c->type() == QCheckListItem::CheckBox) {
+ TQCheckListItem* it_c = static_cast<TQCheckListItem*>(it_v);
+ if(it_c->type() == TQCheckListItem::CheckBox) {
if(!(it_c->isOn() && allItemsSelected(it_v)))
return false;
} else {
@@ -276,23 +276,23 @@ bool KFindTransactionDlg::allItemsSelected(const QListView* view) const
void KFindTransactionDlg::setupAccountsPage(void)
{
- m_accountsView->setSelectionMode(QListView::Multi);
+ m_accountsView->setSelectionMode(TQListView::Multi);
AccountSet accountSet;
accountSet.addAccountGroup(MyMoneyAccount::Asset);
accountSet.addAccountGroup(MyMoneyAccount::Liability);
//set the accountset to show closed account if the settings say so
accountSet.setHideClosedAccounts(KMyMoneyGlobalSettings::hideClosedAccounts());
accountSet.load(m_accountsView);
- connect(m_accountsView, SIGNAL(stateChanged()), this, SLOT(slotUpdateSelections()));
+ connect(m_accountsView, TQT_SIGNAL(stateChanged()), this, TQT_SLOT(slotUpdateSelections()));
}
-void KFindTransactionDlg::selectAllItems(QListView* view, const bool state)
+void KFindTransactionDlg::selectAllItems(TQListView* view, const bool state)
{
- QListViewItem* it_v;
+ TQListViewItem* it_v;
for(it_v = view->firstChild(); it_v != 0; it_v = it_v->nextSibling()) {
- QCheckListItem* it_c = static_cast<QCheckListItem*>(it_v);
- if(it_c->type() == QCheckListItem::CheckBox) {
+ TQCheckListItem* it_c = static_cast<TQCheckListItem*>(it_v);
+ if(it_c->type() == TQCheckListItem::CheckBox) {
it_c->setOn(state);
}
selectAllSubItems(it_v, state);
@@ -301,13 +301,13 @@ void KFindTransactionDlg::selectAllItems(QListView* view, const bool state)
slotUpdateSelections();
}
-void KFindTransactionDlg::selectItems(QListView* view, const QStringList& list, const bool state)
+void KFindTransactionDlg::selectItems(TQListView* view, const TQStringList& list, const bool state)
{
- QListViewItem* it_v;
+ TQListViewItem* it_v;
for(it_v = view->firstChild(); it_v != 0; it_v = it_v->nextSibling()) {
KMyMoneyCheckListItem* it_c = static_cast<KMyMoneyCheckListItem*>(it_v);
- if(it_c->type() == QCheckListItem::CheckBox && list.contains(it_c->id())) {
+ if(it_c->type() == TQCheckListItem::CheckBox && list.tqcontains(it_c->id())) {
it_c->setOn(state);
}
selectSubItems(it_v, list, state);
@@ -318,31 +318,31 @@ void KFindTransactionDlg::selectItems(QListView* view, const QStringList& list,
void KFindTransactionDlg::setupCategoriesPage(void)
{
- m_categoriesView->setSelectionMode(QListView::Multi);
+ m_categoriesView->setSelectionMode(TQListView::Multi);
AccountSet categorySet;
categorySet.addAccountGroup(MyMoneyAccount::Income);
categorySet.addAccountGroup(MyMoneyAccount::Expense);
categorySet.load(m_categoriesView);
- connect(m_categoriesView, SIGNAL(stateChanged()), this, SLOT(slotUpdateSelections()));
+ connect(m_categoriesView, TQT_SIGNAL(stateChanged()), this, TQT_SLOT(slotUpdateSelections()));
}
-void KFindTransactionDlg::selectAllSubItems(QListViewItem* item, const bool state)
+void KFindTransactionDlg::selectAllSubItems(TQListViewItem* item, const bool state)
{
- QListViewItem* it_v;
+ TQListViewItem* it_v;
for(it_v = item->firstChild(); it_v != 0; it_v = it_v->nextSibling()) {
- static_cast<QCheckListItem*>(it_v)->setOn(state);
+ static_cast<TQCheckListItem*>(it_v)->setOn(state);
selectAllSubItems(it_v, state);
}
}
-void KFindTransactionDlg::selectSubItems(QListViewItem* item, const QStringList& list, const bool state)
+void KFindTransactionDlg::selectSubItems(TQListViewItem* item, const TQStringList& list, const bool state)
{
- QListViewItem* it_v;
+ TQListViewItem* it_v;
for(it_v = item->firstChild(); it_v != 0; it_v = it_v->nextSibling()) {
KMyMoneyCheckListItem* it_c = static_cast<KMyMoneyCheckListItem*>(it_v);
- if(list.contains(it_c->id()))
+ if(list.tqcontains(it_c->id()))
it_c->setOn(state);
selectSubItems(it_v, list, state);
}
@@ -355,9 +355,9 @@ void KFindTransactionDlg::setupDatePage(void)
MyMoneyTransactionFilter::translateDateRange(static_cast<MyMoneyTransactionFilter::dateOptionE>(i), m_startDates[i], m_endDates[i]);
}
- connect(m_dateRange, SIGNAL(itemSelected(int)), this, SLOT(slotDateRangeChanged(int)));
- connect(m_fromDate, SIGNAL(dateChanged(const QDate&)), this, SLOT(slotDateChanged()));
- connect(m_toDate, SIGNAL(dateChanged(const QDate&)), this, SLOT(slotDateChanged()));
+ connect(m_dateRange, TQT_SIGNAL(itemSelected(int)), this, TQT_SLOT(slotDateRangeChanged(int)));
+ connect(m_fromDate, TQT_SIGNAL(dateChanged(const TQDate&)), this, TQT_SLOT(slotDateChanged()));
+ connect(m_toDate, TQT_SIGNAL(dateChanged(const TQDate&)), this, TQT_SLOT(slotDateChanged()));
slotDateRangeChanged(MyMoneyTransactionFilter::allDates);
}
@@ -367,8 +367,8 @@ void KFindTransactionDlg::slotDateRangeChanged(int idx)
switch(idx) {
case MyMoneyTransactionFilter::allDates:
case MyMoneyTransactionFilter::userDefined:
- m_fromDate->loadDate(QDate());
- m_toDate->loadDate(QDate());
+ m_fromDate->loadDate(TQDate());
+ m_toDate->loadDate(TQDate());
break;
default:
m_fromDate->loadDate(m_startDates[idx]);
@@ -399,12 +399,12 @@ void KFindTransactionDlg::slotDateChanged(void)
void KFindTransactionDlg::setupAmountPage(void)
{
- connect(m_amountButton, SIGNAL(clicked()), this, SLOT(slotAmountSelected()));
- connect(m_amountRangeButton, SIGNAL(clicked()), this, SLOT(slotAmountRangeSelected()));
+ connect(m_amountButton, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotAmountSelected()));
+ connect(m_amountRangeButton, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotAmountRangeSelected()));
- connect(m_amountEdit, SIGNAL(textChanged(const QString&)), this, SLOT(slotUpdateSelections()));
- connect(m_amountFromEdit, SIGNAL(textChanged(const QString&)), this, SLOT(slotUpdateSelections()));
- connect(m_amountToEdit, SIGNAL(textChanged(const QString&)), this, SLOT(slotUpdateSelections()));
+ connect(m_amountEdit, TQT_SIGNAL(textChanged(const TQString&)), this, TQT_SLOT(slotUpdateSelections()));
+ connect(m_amountFromEdit, TQT_SIGNAL(textChanged(const TQString&)), this, TQT_SLOT(slotUpdateSelections()));
+ connect(m_amountToEdit, TQT_SIGNAL(textChanged(const TQString&)), this, TQT_SLOT(slotUpdateSelections()));
m_amountButton->setChecked(true);
slotAmountSelected();
@@ -428,28 +428,28 @@ void KFindTransactionDlg::slotAmountRangeSelected(void)
void KFindTransactionDlg::setupPayeesPage(void)
{
- m_payeesView->setSelectionMode(QListView::Single);
+ m_payeesView->setSelectionMode(TQListView::Single);
m_payeesView->header()->hide();
loadPayees();
m_emptyPayeesButton->setChecked(false);
- connect(m_allPayeesButton, SIGNAL(clicked()), this, SLOT(slotSelectAllPayees()));
- connect(m_clearPayeesButton, SIGNAL(clicked()), this, SLOT(slotDeselectAllPayees()));
- connect(m_emptyPayeesButton, SIGNAL(stateChanged(int)), this, SLOT(slotUpdateSelections()));
+ connect(m_allPayeesButton, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotSelectAllPayees()));
+ connect(m_clearPayeesButton, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotDeselectAllPayees()));
+ connect(m_emptyPayeesButton, TQT_SIGNAL(stateChanged(int)), this, TQT_SLOT(slotUpdateSelections()));
}
void KFindTransactionDlg::loadPayees(void)
{
MyMoneyFile* file = MyMoneyFile::instance();
- QValueList<MyMoneyPayee> list;
- QValueList<MyMoneyPayee>::Iterator it_l;
+ TQValueList<MyMoneyPayee> list;
+ TQValueList<MyMoneyPayee>::Iterator it_l;
list = file->payeeList();
// load view
for(it_l = list.begin(); it_l != list.end(); ++it_l) {
- KMyMoneyCheckListItem* item = new KMyMoneyCheckListItem(m_payeesView, (*it_l).name(), QString(), (*it_l).id());
- connect(item, SIGNAL(stateChanged(bool)), this, SLOT(slotUpdateSelections()));
+ KMyMoneyCheckListItem* item = new KMyMoneyCheckListItem(m_payeesView, (*it_l).name(), TQString(), (*it_l).id());
+ connect(item, TQT_SIGNAL(stateChanged(bool)), this, TQT_SLOT(slotUpdateSelections()));
item->setOn(true);
}
}
@@ -465,15 +465,15 @@ void KFindTransactionDlg::slotDeselectAllPayees(void)
void KFindTransactionDlg::setupDetailsPage(void)
{
- connect(m_typeBox, SIGNAL(activated(int)), this, SLOT(slotUpdateSelections()));
- connect(m_stateBox, SIGNAL(activated(int)), this, SLOT(slotUpdateSelections()));
- connect(m_validityBox, SIGNAL(activated(int)), this, SLOT(slotUpdateSelections()));
+ connect(m_typeBox, TQT_SIGNAL(activated(int)), this, TQT_SLOT(slotUpdateSelections()));
+ connect(m_stateBox, TQT_SIGNAL(activated(int)), this, TQT_SLOT(slotUpdateSelections()));
+ connect(m_validityBox, TQT_SIGNAL(activated(int)), this, TQT_SLOT(slotUpdateSelections()));
- connect(m_nrButton, SIGNAL(clicked()), this, SLOT(slotNrSelected()));
- connect(m_nrRangeButton, SIGNAL(clicked()), this, SLOT(slotNrRangeSelected()));
- connect(m_nrEdit, SIGNAL(textChanged(const QString&)), this, SLOT(slotUpdateSelections()));
- connect(m_nrFromEdit, SIGNAL(textChanged(const QString&)), this, SLOT(slotUpdateSelections()));
- connect(m_nrToEdit, SIGNAL(textChanged(const QString&)), this, SLOT(slotUpdateSelections()));
+ connect(m_nrButton, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotNrSelected()));
+ connect(m_nrRangeButton, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotNrRangeSelected()));
+ connect(m_nrEdit, TQT_SIGNAL(textChanged(const TQString&)), this, TQT_SLOT(slotUpdateSelections()));
+ connect(m_nrFromEdit, TQT_SIGNAL(textChanged(const TQString&)), this, TQT_SLOT(slotUpdateSelections()));
+ connect(m_nrToEdit, TQT_SIGNAL(textChanged(const TQString&)), this, TQT_SLOT(slotUpdateSelections()));
m_nrButton->setChecked(true);
slotNrSelected();
@@ -495,7 +495,7 @@ void KFindTransactionDlg::slotNrRangeSelected(void)
slotUpdateSelections();
}
-void KFindTransactionDlg::addItemToFilter(const opTypeE op, const QString& id)
+void KFindTransactionDlg::addItemToFilter(const opTypeE op, const TQString& id)
{
switch(op) {
case addAccountToFilter:
@@ -510,14 +510,14 @@ void KFindTransactionDlg::addItemToFilter(const opTypeE op, const QString& id)
}
}
-void KFindTransactionDlg::scanCheckListItems(const QListViewItem* item, const opTypeE op)
+void KFindTransactionDlg::scanCheckListItems(const TQListViewItem* item, const opTypeE op)
{
- QListViewItem* it_v;
+ TQListViewItem* it_v;
for(it_v = item->firstChild(); it_v != 0; it_v = it_v->nextSibling()) {
if(it_v->rtti() == 1) {
KMyMoneyCheckListItem* it_c = static_cast<KMyMoneyCheckListItem*>(it_v);
- if(it_c->type() == QCheckListItem::CheckBox) {
+ if(it_c->type() == TQCheckListItem::CheckBox) {
if(it_c->isOn())
addItemToFilter(op, (*it_c).id());
}
@@ -526,14 +526,14 @@ void KFindTransactionDlg::scanCheckListItems(const QListViewItem* item, const op
}
}
-void KFindTransactionDlg::scanCheckListItems(const QListView* view, const opTypeE op)
+void KFindTransactionDlg::scanCheckListItems(const TQListView* view, const opTypeE op)
{
- QListViewItem* it_v;
+ TQListViewItem* it_v;
for(it_v = view->firstChild(); it_v != 0; it_v = it_v->nextSibling()) {
if(it_v->rtti() == 1) {
KMyMoneyCheckListItem* it_c = static_cast<KMyMoneyCheckListItem*>(it_v);
- if(it_c->type() == QCheckListItem::CheckBox) {
+ if(it_c->type() == TQCheckListItem::CheckBox) {
if(it_c->isOn())
addItemToFilter(op, (*it_c).id());
}
@@ -548,27 +548,27 @@ void KFindTransactionDlg::setupFilter(void)
// Text tab
if(!m_textEdit->text().isEmpty()) {
- QRegExp exp(m_textEdit->text(), m_caseSensitive->isChecked(), !m_regExp->isChecked());
+ TQRegExp exp(m_textEdit->text(), m_caseSensitive->isChecked(), !m_regExp->isChecked());
m_filter.setTextFilter(exp, m_textNegate->currentItem() != 0);
}
// Account tab
if(!m_accountsView->allItemsSelected()) {
// retrieve a list of selected accounts
- QStringList list;
+ TQStringList list;
m_accountsView->selectedItems(list);
// if we're not in expert mode, we need to make sure
// that all stock accounts for the selected investment
// account are also selected
if(!KMyMoneyGlobalSettings::expertMode()) {
- QStringList missing;
- QStringList::const_iterator it_a, it_b;
+ TQStringList missing;
+ TQStringList::const_iterator it_a, it_b;
for(it_a = list.begin(); it_a != list.end(); ++it_a) {
MyMoneyAccount acc = MyMoneyFile::instance()->account(*it_a);
if(acc.accountType() == MyMoneyAccount::Investment) {
for(it_b = acc.accountList().begin(); it_b != acc.accountList().end(); ++it_b) {
- if(!list.contains(*it_b)) {
+ if(!list.tqcontains(*it_b)) {
missing.append(*it_b);
}
}
@@ -608,7 +608,7 @@ void KFindTransactionDlg::setupFilter(void)
// Payees tab
if(m_emptyPayeesButton->isChecked()) {
- m_filter.addPayee(QString());
+ m_filter.addPayee(TQString());
} else if(!allItemsSelected(m_payeesView)) {
scanCheckListItems(m_payeesView, addPayeeToFilter);
@@ -674,8 +674,8 @@ void KFindTransactionDlg::loadView(void)
MyMoneyFile::instance()->transactionList(m_transactionList, m_filter);
// create the elements for the register
- QValueList<QPair<MyMoneyTransaction, MyMoneySplit> >::const_iterator it;
- QMap<QString, int>uniqueMap;
+ TQValueList<TQPair<MyMoneyTransaction, MyMoneySplit> >::const_iterator it;
+ TQMap<TQString, int>uniqueMap;
MyMoneyMoney deposit, payment;
int splitCount = 0;
@@ -714,15 +714,15 @@ void KFindTransactionDlg::loadView(void)
#if KMM_DEBUG
m_foundText->setText(i18n("Found %1 matching transactions (D %2 / P %3 = %4)")
- .arg(splitCount).arg(deposit.formatMoney("", 2)).arg(payment.formatMoney("", 2)).arg((deposit-payment).formatMoney("", 2)));
+ .tqarg(splitCount).tqarg(deposit.formatMoney("", 2)).tqarg(payment.formatMoney("", 2)).tqarg((deposit-payment).formatMoney("", 2)));
#else
- m_foundText->setText(i18n("Found %1 matching transactions") .arg(splitCount));
+ m_foundText->setText(i18n("Found %1 matching transactions") .tqarg(splitCount));
#endif
m_tabWidget->setTabEnabled(m_resultPage, true);
m_tabWidget->setCurrentPage(m_tabWidget->indexOf(m_resultPage));
- QTimer::singleShot(10, this, SLOT(slotRightSize()));
+ TQTimer::singleShot(10, this, TQT_SLOT(slotRightSize()));
}
void KFindTransactionDlg::slotRightSize(void)
@@ -730,7 +730,7 @@ void KFindTransactionDlg::slotRightSize(void)
m_register->updateContents();
}
-void KFindTransactionDlg::resizeEvent(QResizeEvent* ev)
+void KFindTransactionDlg::resizeEvent(TQResizeEvent* ev)
{
// Columns
// 1 = Date
@@ -775,7 +775,7 @@ void KFindTransactionDlg::resizeEvent(QResizeEvent* ev)
void KFindTransactionDlg::slotSelectTransaction(void)
{
- QValueList<KMyMoneyRegister::RegisterItem*> list = m_register->selectedItems();
+ TQValueList<KMyMoneyRegister::RegisterItem*> list = m_register->selectedItems();
if(!list.isEmpty()) {
KMyMoneyRegister::Transaction* t = dynamic_cast<KMyMoneyRegister::Transaction*>(list[0]);
if(t) {
@@ -785,21 +785,21 @@ void KFindTransactionDlg::slotSelectTransaction(void)
}
}
-bool KFindTransactionDlg::eventFilter(QObject* o, QEvent* e)
+bool KFindTransactionDlg::eventFilter(TQObject* o, TQEvent* e)
{
bool rc = false;
if(o->isWidgetType()) {
- if(e->type() == QEvent::KeyPress) {
- const QWidget* w = dynamic_cast<const QWidget*>(o);
- QKeyEvent *k = static_cast<QKeyEvent *> (e);
+ if(e->type() == TQEvent::KeyPress) {
+ const TQWidget* w = dynamic_cast<const TQWidget*>(o);
+ TQKeyEvent *k = TQT_TQKEYEVENT (e);
if(w == m_register) {
switch(k->key()) {
default:
break;
- case Qt::Key_Return:
- case Qt::Key_Enter:
+ case TQt::Key_Return:
+ case TQt::Key_Enter:
rc = true;
slotSelectTransaction();
break;
@@ -812,9 +812,9 @@ bool KFindTransactionDlg::eventFilter(QObject* o, QEvent* e)
void KFindTransactionDlg::slotShowHelp(void)
{
- QString anchor = m_helpAnchor[m_criteriaTab->currentPage()];
+ TQString anchor = m_helpAnchor[m_criteriaTab->currentPage()];
if(anchor.isEmpty())
- anchor = QString("details.search");
+ anchor = TQString("details.search");
kapp->invokeHelp(anchor);
}
@@ -823,11 +823,11 @@ void KFindTransactionDlg::slotSortOptions(void)
{
KSortOptionDlg* dlg = new KSortOptionDlg(this);
- dlg->setSortOption(KMyMoneyGlobalSettings::sortSearchView(), QString());
+ dlg->setSortOption(KMyMoneyGlobalSettings::sortSearchView(), TQString());
dlg->hideDefaultButton();
- if(dlg->exec() == QDialog::Accepted) {
- QString sortOrder = dlg->sortOption();
+ if(dlg->exec() == TQDialog::Accepted) {
+ TQString sortOrder = dlg->sortOption();
if(sortOrder != KMyMoneyGlobalSettings::sortSearchView()) {
KMyMoneyGlobalSettings::setSortSearchView(sortOrder);
slotRefreshView();