summaryrefslogtreecommitdiffstats
path: root/kmymoney2/converter
diff options
context:
space:
mode:
authorTimothy Pearson <kb9vqf@pearsoncomputing.net>2013-01-24 13:21:28 -0600
committerTimothy Pearson <kb9vqf@pearsoncomputing.net>2013-01-24 13:21:28 -0600
commit6c1d52c8248adb9189c944a28efde52330e99b66 (patch)
tree842df8de70813d5097e5d7ffe04577c4077381d9 /kmymoney2/converter
parent4b12aca2f1e0304a1cb35df621e9a993dd4d81f7 (diff)
downloadkmymoney-6c1d52c8248adb9189c944a28efde52330e99b66.tar.gz
kmymoney-6c1d52c8248adb9189c944a28efde52330e99b66.zip
Rename KGlobal, KProcess, and KClipboard to avoid conflicts with KDE4
Diffstat (limited to 'kmymoney2/converter')
-rw-r--r--kmymoney2/converter/mymoneyqifprofile.cpp14
-rw-r--r--kmymoney2/converter/mymoneyqifreader.cpp18
-rw-r--r--kmymoney2/converter/mymoneyqifreader.h6
-rw-r--r--kmymoney2/converter/mymoneystatementreader.cpp2
-rw-r--r--kmymoney2/converter/webpricequote.cpp52
-rw-r--r--kmymoney2/converter/webpricequote.h12
6 files changed, 52 insertions, 52 deletions
diff --git a/kmymoney2/converter/mymoneyqifprofile.cpp b/kmymoney2/converter/mymoneyqifprofile.cpp
index 77bbe07..079716d 100644
--- a/kmymoney2/converter/mymoneyqifprofile.cpp
+++ b/kmymoney2/converter/mymoneyqifprofile.cpp
@@ -164,14 +164,14 @@ void MyMoneyQifProfile::clear(void)
m_decimal['Q'] =
m_decimal['T'] =
m_decimal['O'] =
- m_decimal['I'] = KGlobal::locale()->monetaryDecimalSymbol()[0];
+ m_decimal['I'] = TDEGlobal::locale()->monetaryDecimalSymbol()[0];
m_thousands.clear();
m_thousands['$'] =
m_thousands['Q'] =
m_thousands['T'] =
m_thousands['O'] =
- m_thousands['I'] = KGlobal::locale()->monetaryThousandsSeparator()[0];
+ m_thousands['I'] = TDEGlobal::locale()->monetaryThousandsSeparator()[0];
m_openingBalanceText = "Opening Balance";
m_voidMark = "VOID ";
@@ -186,7 +186,7 @@ void MyMoneyQifProfile::clear(void)
void MyMoneyQifProfile::loadProfile(const TQString& name)
{
- KConfig* config = KGlobal::config();
+ KConfig* config = TDEGlobal::config();
config->setGroup(name);
clear();
@@ -232,7 +232,7 @@ void MyMoneyQifProfile::loadProfile(const TQString& name)
void MyMoneyQifProfile::saveProfile(void)
{
if(m_isDirty == true) {
- KConfig* config = KGlobal::config();
+ KConfig* config = TDEGlobal::config();
config->setGroup(m_profileName);
config->writeEntry("Description", m_profileDescription);
@@ -418,7 +418,7 @@ TQString MyMoneyQifProfile::date(const TQDate& datein) const
if(delim)
buffer += delim;
if(maskLen == 3)
- buffer += KGlobal::locale()->calendar()->monthName(datein.month(), datein.year(), true);
+ buffer += TDEGlobal::locale()->calendar()->monthName(datein.month(), datein.year(), true);
else
buffer += TQString::number(datein.month()).rightJustify(2, '0');
break;
@@ -466,7 +466,7 @@ const TQDate MyMoneyQifProfile::date(const TQString& datein) const
TQStringList monthNames = TQStringList::split(",", "jan,feb,mar,apr,may,jun,jul,aug,sep,oct,nov,dec");
int j;
for(j = 1; j <= 12; ++j) {
- if((KGlobal::locale()->calendar()->monthName(j, 2000, true).lower() == scannedParts[d->m_partPos['m']].lower())
+ if((TDEGlobal::locale()->calendar()->monthName(j, 2000, true).lower() == scannedParts[d->m_partPos['m']].lower())
|| (monthNames[j-1] == scannedParts[d->m_partPos['m']].lower())) {
mon = j;
break;
@@ -590,7 +590,7 @@ const TQDate MyMoneyQifProfile::date(const TQString& datein) const
msg = "Invalid numeric character in month string";
} else {
for(j = 1; j <= 12; ++j) {
- if(KGlobal::locale()->calendar()->monthName(j, 2000, true).lower() == formatParts[i].lower()) {
+ if(TDEGlobal::locale()->calendar()->monthName(j, 2000, true).lower() == formatParts[i].lower()) {
mon = j;
ok = true;
break;
diff --git a/kmymoney2/converter/mymoneyqifreader.cpp b/kmymoney2/converter/mymoneyqifreader.cpp
index 8764e03..bcb9091 100644
--- a/kmymoney2/converter/mymoneyqifreader.cpp
+++ b/kmymoney2/converter/mymoneyqifreader.cpp
@@ -250,10 +250,10 @@ MyMoneyQifReader::MyMoneyQifReader() :
m_warnedSecurity = false;
m_warnedPrice = false;
- connect(&m_filter, TQT_SIGNAL(wroteStdin(KProcess*)), this, TQT_SLOT(slotSendDataToFilter()));
- connect(&m_filter, TQT_SIGNAL(receivedStdout(KProcess*, char*, int)), this, TQT_SLOT(slotReceivedDataFromFilter(KProcess*, char*, int)));
- connect(&m_filter, TQT_SIGNAL(processExited(KProcess*)), this, TQT_SLOT(slotImportFinished()));
- connect(&m_filter, TQT_SIGNAL(receivedStderr(KProcess*, char*, int)), this, TQT_SLOT(slotReceivedErrorFromFilter(KProcess*, char*, int)));
+ connect(&m_filter, TQT_SIGNAL(wroteStdin(TDEProcess*)), this, TQT_SLOT(slotSendDataToFilter()));
+ connect(&m_filter, TQT_SIGNAL(receivedStdout(TDEProcess*, char*, int)), this, TQT_SLOT(slotReceivedDataFromFilter(TDEProcess*, char*, int)));
+ connect(&m_filter, TQT_SIGNAL(processExited(TDEProcess*)), this, TQT_SLOT(slotImportFinished()));
+ connect(&m_filter, TQT_SIGNAL(receivedStderr(TDEProcess*, char*, int)), this, TQT_SLOT(slotReceivedErrorFromFilter(TDEProcess*, char*, int)));
}
MyMoneyQifReader::~MyMoneyQifReader()
@@ -297,14 +297,14 @@ void MyMoneyQifReader::slotSendDataToFilter(void)
}
}
-void MyMoneyQifReader::slotReceivedErrorFromFilter(KProcess* /* proc */, char *buff, int len)
+void MyMoneyQifReader::slotReceivedErrorFromFilter(TDEProcess* /* proc */, char *buff, int len)
{
TQByteArray data;
data.duplicate(buff, len);
tqWarning("%s",static_cast<const char*>(data));
}
-void MyMoneyQifReader::slotReceivedDataFromFilter(KProcess* /* proc */, char *buff, int len)
+void MyMoneyQifReader::slotReceivedDataFromFilter(TDEProcess* /* proc */, char *buff, int len)
{
m_pos += len;
// signalProgress(m_pos, 0);
@@ -437,7 +437,7 @@ bool MyMoneyQifReader::startImport(void)
}
m_entryType = EntryUnknown;
- if(m_filter.start(KProcess::NotifyOnExit, KProcess::All)) {
+ if(m_filter.start(TDEProcess::NotifyOnExit, TDEProcess::All)) {
m_filter.resume();
signalProgress(0, m_file->size(), i18n("Reading QIF ..."));
slotSendDataToFilter();
@@ -459,7 +459,7 @@ bool MyMoneyQifReader::finishImport(void)
m_file = 0;
// remove the Don't ask again entries
- KConfig* config = KGlobal::config();
+ KConfig* config = TDEGlobal::config();
config->setGroup(TQString::fromLatin1("Notification Messages"));
TQStringList::ConstIterator it;
@@ -479,7 +479,7 @@ bool MyMoneyQifReader::finishImport(void)
m_file = 0;
// remove the Don't ask again entries
- KConfig* config = KGlobal::config();
+ KConfig* config = TDEGlobal::config();
config->setGroup(TQString::fromLatin1("Notification Messages"));
TQStringList::ConstIterator it;
diff --git a/kmymoney2/converter/mymoneyqifreader.h b/kmymoney2/converter/mymoneyqifreader.h
index dfde437..e2f6638 100644
--- a/kmymoney2/converter/mymoneyqifreader.h
+++ b/kmymoney2/converter/mymoneyqifreader.h
@@ -337,8 +337,8 @@ signals:
private slots:
void slotSendDataToFilter(void);
- void slotReceivedDataFromFilter(KProcess* /* proc */, char *buff, int len);
- void slotReceivedErrorFromFilter(KProcess* /* proc */, char *buff, int len);
+ void slotReceivedDataFromFilter(TDEProcess* /* proc */, char *buff, int len);
+ void slotReceivedErrorFromFilter(TDEProcess* /* proc */, char *buff, int len);
// void slotReceivedDataFromFilter(void);
// void slotReceivedErrorFromFilter(void);
void slotProcessData(void);
@@ -356,7 +356,7 @@ private:
/// \internal d-pointer instance.
Private* const d;
- KProcess m_filter;
+ TDEProcess m_filter;
TQString m_filename;
KURL m_url;
MyMoneyQifProfile m_qifProfile;
diff --git a/kmymoney2/converter/mymoneystatementreader.cpp b/kmymoney2/converter/mymoneystatementreader.cpp
index 8d26a1b..a242f41 100644
--- a/kmymoney2/converter/mymoneystatementreader.cpp
+++ b/kmymoney2/converter/mymoneystatementreader.cpp
@@ -401,7 +401,7 @@ bool MyMoneyStatementReader::import(const MyMoneyStatement& s, TQStringList& mes
messages += TQString();
// remove the Don't ask again entries
- KConfig* config = KGlobal::config();
+ KConfig* config = TDEGlobal::config();
config->setGroup(TQString::fromLatin1("Notification Messages"));
TQStringList::ConstIterator it;
diff --git a/kmymoney2/converter/webpricequote.cpp b/kmymoney2/converter/webpricequote.cpp
index a5a9087..ba9cdc4 100644
--- a/kmymoney2/converter/webpricequote.cpp
+++ b/kmymoney2/converter/webpricequote.cpp
@@ -56,7 +56,7 @@ WebPriceQuote::WebPriceQuote( TQObject* _parent, const char* _name ):
TQObject( _parent, _name )
{
m_financeQuoteScriptPath =
- KGlobal::dirs()->findResource("appdata", TQString("misc/financequote.pl"));
+ TDEGlobal::dirs()->findResource("appdata", TQString("misc/financequote.pl"));
connect(&m_filter,TQT_SIGNAL(processExited(const TQString&)),this,TQT_SLOT(slotParseQuote(const TQString&)));
}
@@ -141,11 +141,11 @@ bool WebPriceQuote::launchNative( const TQString& _symbol, const TQString& _id,
// if we're running non-interactive, we'll need to block.
// otherwise, just let us know when it's done.
- KProcess::RunMode mode = KProcess::NotifyOnExit;
+ TDEProcess::RunMode mode = TDEProcess::NotifyOnExit;
if ( ! kapp )
- mode = KProcess::Block;
+ mode = TDEProcess::Block;
- if(m_filter.start(mode, KProcess::All))
+ if(m_filter.start(mode, TDEProcess::All))
{
result = true;
m_filter.resume();
@@ -272,18 +272,18 @@ bool WebPriceQuote::launchFinanceQuote ( const TQString& _symbol, const TQString
m_filter.clearArguments();
- m_filter << "perl" << m_financeQuoteScriptPath << FTQSource << KProcess::quote(_symbol);
+ m_filter << "perl" << m_financeQuoteScriptPath << FTQSource << TDEProcess::quote(_symbol);
m_filter.setUseShell(true);
m_filter.setSymbol(m_symbol);
emit status(TQString("Executing %1 %2 %3...").arg(m_financeQuoteScriptPath).arg(FTQSource).arg(_symbol));
// if we're running non-interactive, we'll need to block.
// otherwise, just let us know when it's done.
- KProcess::RunMode mode = KProcess::NotifyOnExit;
+ TDEProcess::RunMode mode = TDEProcess::NotifyOnExit;
if ( ! kapp )
- mode = KProcess::Block;
+ mode = TDEProcess::Block;
- if(m_filter.start(mode, KProcess::All))
+ if(m_filter.start(mode, TDEProcess::All))
{
result = true;
m_filter.resume();
@@ -598,7 +598,7 @@ TQStringList WebPriceQuote::quoteSources (const _quoteSystemE _system) {
TQStringList WebPriceQuote::quoteSourcesNative()
{
- KConfig *kconfig = KGlobal::config();
+ KConfig *kconfig = TDEGlobal::config();
TQStringList groups = kconfig->groupList();
TQStringList::Iterator it;
@@ -656,7 +656,7 @@ TQStringList WebPriceQuote::quoteSourcesFinanceQuote()
if (m_financeQuoteSources.empty()) { // run the process one time only
FinanceQuoteProcess getList;
m_financeQuoteScriptPath =
- KGlobal::dirs()->findResource("appdata", TQString("misc/financequote.pl"));
+ TDEGlobal::dirs()->findResource("appdata", TQString("misc/financequote.pl"));
getList.launch( m_financeQuoteScriptPath );
while (!getList.isFinished()) {
tqApp->processEvents();
@@ -683,7 +683,7 @@ WebPriceQuoteSource::WebPriceQuoteSource(const TQString& name, const TQString& u
WebPriceQuoteSource::WebPriceQuoteSource(const TQString& name)
{
m_name = name;
- KConfig *kconfig = KGlobal::config();
+ KConfig *kconfig = TDEGlobal::config();
kconfig->setGroup(TQString("Online-Quote-Source-%1").arg(m_name));
m_sym = kconfig->readEntry("SymbolRegex");
m_date = kconfig->readEntry("DateRegex");
@@ -695,7 +695,7 @@ WebPriceQuoteSource::WebPriceQuoteSource(const TQString& name)
void WebPriceQuoteSource::write(void) const
{
- KConfig *kconfig = KGlobal::config();
+ KConfig *kconfig = TDEGlobal::config();
kconfig->setGroup(TQString("Online-Quote-Source-%1").arg(m_name));
kconfig->writeEntry("URL", m_url);
kconfig->writeEntry("PriceRegex", m_price);
@@ -717,21 +717,21 @@ void WebPriceQuoteSource::rename(const TQString& name)
void WebPriceQuoteSource::remove(void) const
{
- KConfig *kconfig = KGlobal::config();
+ KConfig *kconfig = TDEGlobal::config();
kconfig->deleteGroup(TQString("Online-Quote-Source-%1").arg(m_name));
}
//
-// Helper class to babysit the KProcess used for running the local script in that case
+// Helper class to babysit the TDEProcess used for running the local script in that case
//
WebPriceQuoteProcess::WebPriceQuoteProcess(void)
{
- connect(this, TQT_SIGNAL(receivedStdout(KProcess*, char*, int)), this, TQT_SLOT(slotReceivedDataFromFilter(KProcess*, char*, int)));
- connect(this, TQT_SIGNAL(processExited(KProcess*)), this, TQT_SLOT(slotProcessExited(KProcess*)));
+ connect(this, TQT_SIGNAL(receivedStdout(TDEProcess*, char*, int)), this, TQT_SLOT(slotReceivedDataFromFilter(TDEProcess*, char*, int)));
+ connect(this, TQT_SIGNAL(processExited(TDEProcess*)), this, TQT_SLOT(slotProcessExited(TDEProcess*)));
}
-void WebPriceQuoteProcess::slotReceivedDataFromFilter(KProcess* /*_process*/, char* _pcbuffer, int _nbufferlen)
+void WebPriceQuoteProcess::slotReceivedDataFromFilter(TDEProcess* /*_process*/, char* _pcbuffer, int _nbufferlen)
{
TQByteArray data;
data.duplicate(_pcbuffer, _nbufferlen);
@@ -740,7 +740,7 @@ void WebPriceQuoteProcess::slotReceivedDataFromFilter(KProcess* /*_process*/, ch
m_string += TQString(data);
}
-void WebPriceQuoteProcess::slotProcessExited(KProcess*)
+void WebPriceQuoteProcess::slotProcessExited(TDEProcess*)
{
// kdDebug(2) << "WebPriceQuoteProcess::slotProcessExited()" << endl;
emit processExited(m_string);
@@ -748,7 +748,7 @@ void WebPriceQuoteProcess::slotProcessExited(KProcess*)
}
//
-// Helper class to babysit the KProcess used for running the Finance Quote sources script
+// Helper class to babysit the TDEProcess used for running the Finance Quote sources script
//
FinanceQuoteProcess::FinanceQuoteProcess(void)
@@ -809,11 +809,11 @@ FinanceQuoteProcess::FinanceQuoteProcess(void)
m_fqNames["yahoo_europe"] = "Yahoo Europe";
m_fqNames["yahoo_nz"] = "Yahoo New Zealand";
m_fqNames["zifunds"] = "Zuerich Investments";
- connect(this, TQT_SIGNAL(receivedStdout(KProcess*, char*, int)), this, TQT_SLOT(slotReceivedDataFromFilter(KProcess*, char*, int)));
- connect(this, TQT_SIGNAL(processExited(KProcess*)), this, TQT_SLOT(slotProcessExited(KProcess*)));
+ connect(this, TQT_SIGNAL(receivedStdout(TDEProcess*, char*, int)), this, TQT_SLOT(slotReceivedDataFromFilter(TDEProcess*, char*, int)));
+ connect(this, TQT_SIGNAL(processExited(TDEProcess*)), this, TQT_SLOT(slotProcessExited(TDEProcess*)));
}
-void FinanceQuoteProcess::slotReceivedDataFromFilter(KProcess* /*_process*/, char* _pcbuffer, int _nbufferlen)
+void FinanceQuoteProcess::slotReceivedDataFromFilter(TDEProcess* /*_process*/, char* _pcbuffer, int _nbufferlen)
{
TQByteArray data;
data.duplicate(_pcbuffer, _nbufferlen);
@@ -822,7 +822,7 @@ void FinanceQuoteProcess::slotReceivedDataFromFilter(KProcess* /*_process*/, cha
m_string += TQString(data);
}
-void FinanceQuoteProcess::slotProcessExited(KProcess*)
+void FinanceQuoteProcess::slotProcessExited(TDEProcess*)
{
// kdDebug(2) << "WebPriceQuoteProcess::slotProcessExited()" << endl;
m_isDone = true;
@@ -833,7 +833,7 @@ void FinanceQuoteProcess::launch (const TQString& scriptPath) {
arguments.append(TQCString("perl"));
arguments.append (TQCString(scriptPath));
arguments.append (TQCString("-l"));
- if (!start(KProcess::NotifyOnExit, KProcess::Stdout)) tqFatal ("Unable to start FQ script");
+ if (!start(TDEProcess::NotifyOnExit, TDEProcess::Stdout)) tqFatal ("Unable to start FQ script");
return;
}
@@ -950,8 +950,8 @@ TQDate MyMoneyDateFormat::convertString(const TQString& _in, bool _strict, unsig
unsigned i = 1;
while ( i <= 12 )
{
- if(KGlobal::locale()->calendar()->monthName(i, 2000, true).lower() == *it_scanned
- || KGlobal::locale()->calendar()->monthName(i, 2000, false).lower() == *it_scanned)
+ if(TDEGlobal::locale()->calendar()->monthName(i, 2000, true).lower() == *it_scanned
+ || TDEGlobal::locale()->calendar()->monthName(i, 2000, false).lower() == *it_scanned)
month = i;
++i;
}
diff --git a/kmymoney2/converter/webpricequote.h b/kmymoney2/converter/webpricequote.h
index 08a1aec..a9ec149 100644
--- a/kmymoney2/converter/webpricequote.h
+++ b/kmymoney2/converter/webpricequote.h
@@ -45,7 +45,7 @@ of a local script being used to fetch the quote.
@author Thomas Baumgart <thb@net-bembel.de> & Ace Jones <acejones@users.sourceforge.net>
*/
-class WebPriceQuoteProcess: public KProcess
+class WebPriceQuoteProcess: public TDEProcess
{
Q_OBJECT
@@ -54,8 +54,8 @@ public:
void setSymbol(const TQString& _symbol) { m_symbol = _symbol; m_string.truncate(0); }
public slots:
- void slotReceivedDataFromFilter(KProcess*, char*, int);
- void slotProcessExited(KProcess*);
+ void slotReceivedDataFromFilter(TDEProcess*, char*, int);
+ void slotProcessExited(TDEProcess*);
signals:
void processExited(const TQString&);
@@ -73,7 +73,7 @@ by the Finance::Quote package, and more user-friendly names.
@author Thomas Baumgart <thb@net-bembel.de> & Ace Jones <acejones@users.sourceforge.net>, Tony B<tonybloom@users.sourceforge.net>
*/
-class FinanceQuoteProcess: public KProcess
+class FinanceQuoteProcess: public TDEProcess
{
Q_OBJECT
@@ -86,8 +86,8 @@ class FinanceQuoteProcess: public KProcess
const TQString niceName(const TQString& crypticName);
public slots:
- void slotReceivedDataFromFilter(KProcess*, char*, int);
- void slotProcessExited(KProcess*);
+ void slotReceivedDataFromFilter(TDEProcess*, char*, int);
+ void slotProcessExited(TDEProcess*);
private:
bool m_isDone;