diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-06-30 00:15:53 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-06-30 00:15:53 +0000 |
commit | 0aaa8e3fc8f8a1481333b564f0922277c8d8ad59 (patch) | |
tree | b95c0ca86c4876dd139af376b9f4afd8917cf0cd /src/progs/pickit2v2/base/pickit2v2_prog.cpp | |
parent | b79a2c28534cf09987eeeba3077fff9236df182a (diff) | |
download | piklab-0aaa8e3fc8f8a1481333b564f0922277c8d8ad59.tar.gz piklab-0aaa8e3fc8f8a1481333b564f0922277c8d8ad59.zip |
TQt4 port piklab
This enables compilation under both Qt3 and Qt4
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/piklab@1238822 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'src/progs/pickit2v2/base/pickit2v2_prog.cpp')
-rw-r--r-- | src/progs/pickit2v2/base/pickit2v2_prog.cpp | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/src/progs/pickit2v2/base/pickit2v2_prog.cpp b/src/progs/pickit2v2/base/pickit2v2_prog.cpp index 3a44bca..b75cc56 100644 --- a/src/progs/pickit2v2/base/pickit2v2_prog.cpp +++ b/src/progs/pickit2v2/base/pickit2v2_prog.cpp @@ -40,7 +40,7 @@ bool Pickit2V2::Base::identifyDevice() if ( !_targetSelfPowered ) { if ( !hardware().setVddVoltage(vdd, 0.85)) return false; } - QString message = i18n("Unknown device"); + TQString message = i18n("Unknown device"); for (uint i=0; FAMILY_DATA[i].architecture!=Pic::Architecture::Nb_Types; i++) { const FamilyData &fdata = FAMILY_DATA[i]; if ( fdata.readDevIdScript==0 ) { @@ -59,8 +59,8 @@ bool Pickit2V2::Base::identifyDevice() if ( !hardware().executeScript(fdata.progExitScript) ) return false; uint rawId = (data[2]<<8) + data[1]; if (fdata.progMemShift) rawId >>= 1; - log(Log::DebugLevel::Normal, QString("Read id for family %1: %2").arg(fdata.architecture.key()).arg(toHexLabelAbs(rawId))); - QMap<QString, Device::IdData> ids; + log(Log::DebugLevel::Normal, TQString("Read id for family %1: %2").tqarg(fdata.architecture.key()).tqarg(toHexLabelAbs(rawId))); + TQMap<TQString, Device::IdData> ids; ::Group::Base::ConstIterator it; for (it=group().begin(); it!=group().end(); ++it) { const Pic::Data *data = static_cast<const Pic::Data *>(it.data().data); @@ -69,9 +69,9 @@ bool Pickit2V2::Base::identifyDevice() if ( data->matchId(rawId, idata) ) ids[it.key()] = idata; } if ( ids.count()!=0 ) { - log(Log::LineType::Information, i18n("Read id: %1").arg(device()->idNames(ids).join("; "))); - if ( ids.contains(device()->name()) ) return true; - message = i18n("Read id does not match the specified device name \"%1\".").arg(device()->name()); + log(Log::LineType::Information, i18n("Read id: %1").tqarg(device()->idNames(ids).join("; "))); + if ( ids.tqcontains(device()->name()) ) return true; + message = i18n("Read id does not match the specified device name \"%1\".").tqarg(device()->name()); break; } } @@ -79,7 +79,7 @@ bool Pickit2V2::Base::identifyDevice() logUserAbort(); return false; } - log(Log::LineType::Information, i18n("Continue with the specified device name: \"%1\"...").arg(device()->name())); + log(Log::LineType::Information, i18n("Continue with the specified device name: \"%1\"...").tqarg(device()->name())); return true; } @@ -92,13 +92,13 @@ bool Pickit2V2::Base::setTarget() bool Pickit2V2::Base::selfTest(bool ask) { ushort status; - if ( !hardware().readStatus(status) ) return false; - QString error; + if ( !hardware().readtqStatus(status) ) return false; + TQString error; if ( status & VppError ) error += i18n("Vpp voltage level error; "); if ( status & VddError ) error += i18n("Vdd voltage level error; "); if ( error.isEmpty() ) return true; - log(Log::LineType::Warning, i18n("Self-test failed: %1").arg(error)); - if ( ask && !askContinue(i18n("Self-test failed (%1). Do you want to continue anyway?").arg(error)) ) { + log(Log::LineType::Warning, i18n("Self-test failed: %1").tqarg(error)); + if ( ask && !askContinue(i18n("Self-test failed (%1). Do you want to continue anyway?").tqarg(error)) ) { logUserAbort(); return false; } |