diff options
author | Timothy Pearson <kb9vqf@pearsoncomputing.net> | 2011-12-15 15:33:27 -0600 |
---|---|---|
committer | Timothy Pearson <kb9vqf@pearsoncomputing.net> | 2011-12-15 15:33:27 -0600 |
commit | 9d6927a7d6a543332f828bffedf65eecf6774c6d (patch) | |
tree | 9f8210096908fddb7d266b477152021c45fa1a00 /src/piklab-prog/cli_interactive.cpp | |
parent | 3534213800bd8d151759df307755f2bbd592dfa1 (diff) | |
download | piklab-9d6927a7d6a543332f828bffedf65eecf6774c6d.tar.gz piklab-9d6927a7d6a543332f828bffedf65eecf6774c6d.zip |
Rename a number of old tq methods that are no longer tq specific
Diffstat (limited to 'src/piklab-prog/cli_interactive.cpp')
-rw-r--r-- | src/piklab-prog/cli_interactive.cpp | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/src/piklab-prog/cli_interactive.cpp b/src/piklab-prog/cli_interactive.cpp index ae485a1..40adb2c 100644 --- a/src/piklab-prog/cli_interactive.cpp +++ b/src/piklab-prog/cli_interactive.cpp @@ -158,11 +158,11 @@ CLI::ExitCode CLI::Interactive::processLine(const TQString &s) if ( !ok ) return errorExit(i18n("Number format not recognized."), ARG_ERROR); PURL::Url dummy; Breakpoint::Data data(dummy, address); - if ( Breakpoint::list().contains(data) ) return okExit(i18n("Breakpoint already set at %1.").tqarg(toHexLabel(address, nbChars(NumberBase::Hex, address)))); + if ( Breakpoint::list().contains(data) ) return okExit(i18n("Breakpoint already set at %1.").arg(toHexLabel(address, nbChars(NumberBase::Hex, address)))); Breakpoint::list().append(data); Breakpoint::list().setAddress(data, address); Breakpoint::list().setState(data, Breakpoint::Active); - return okExit(i18n("Breakpoint set at %1.").tqarg(toHexLabel(address, nbChars(NumberBase::Hex, address)))); + return okExit(i18n("Breakpoint set at %1.").arg(toHexLabel(address, nbChars(NumberBase::Hex, address)))); } return errorExit(i18n("The first argument should be \"e\"."), ARG_ERROR); } @@ -178,7 +178,7 @@ CLI::ExitCode CLI::Interactive::processLine(const TQString &s) } for (uint i=0; i<nb; i++) { Address address = Breakpoint::list().address(Breakpoint::list().data(i)); - log(Log::LineType::Normal, TQString(" #%1: %2").tqarg(i).tqarg(toHexLabel(address, nbc))); + log(Log::LineType::Normal, TQString(" #%1: %2").arg(i).arg(toHexLabel(address, nbc))); } return OK; } @@ -198,7 +198,7 @@ CLI::ExitCode CLI::Interactive::processLine(const TQString &s) Breakpoint::Data data = Breakpoint::list().data(i); Address address = Breakpoint::list().address(data); Breakpoint::list().remove(data); - return okExit(i18n("Breakpoint at %1 removed.").tqarg(toHexLabelAbs(address))); + return okExit(i18n("Breakpoint at %1 removed.").arg(toHexLabelAbs(address))); } if ( words[0]=="raw-com" ) { if ( words.count()!=2 ) return errorExit(i18n("This command needs a commands filename."), ARG_ERROR); @@ -243,10 +243,10 @@ CLI::ExitCode CLI::Interactive::registerList() const Pic::RegistersData &rdata = data.registersData(); log(Log::LineType::Normal, i18n("Special Function Registers:")); TQValueVector<Pic::RegisterNameData> list = Pic::sfrList(data); - for (uint i=0; i<uint(list.count()); i++) log(Log::LineType::Normal, TQString(" %1: %2").tqarg(toHexLabel(list[i].data().address(), rdata.nbCharsAddress())).tqarg(list[i].label())); + for (uint i=0; i<uint(list.count()); i++) log(Log::LineType::Normal, TQString(" %1: %2").arg(toHexLabel(list[i].data().address(), rdata.nbCharsAddress())).arg(list[i].label())); log(Log::LineType::Normal, i18n("General Purpose Registers:")); list = Pic::gprList(data, coff); - for (uint i=0; i<uint(list.count()); i++) log(Log::LineType::Normal, TQString(" %1: %2").tqarg(toHexLabel(list[i].data().address(), rdata.nbCharsAddress())).tqarg(list[i].label())); + for (uint i=0; i<uint(list.count()); i++) log(Log::LineType::Normal, TQString(" %1: %2").arg(toHexLabel(list[i].data().address(), rdata.nbCharsAddress())).arg(list[i].label())); return OK; } @@ -260,7 +260,7 @@ CLI::ExitCode CLI::Interactive::variableList() const Pic::RegistersData &rdata = data.registersData(); TQValueVector<Pic::RegisterNameData> list = Pic::variableList(data, *coff); if ( list.count()==0 ) log(Log::LineType::Normal, i18n("No variable.")); - for (uint i=0; i<uint(list.count()); i++) log(Log::LineType::Normal, TQString(" %1: %2").tqarg(toHexLabel(list[i].data().address(), rdata.nbCharsAddress())).tqarg(list[i].label())); + for (uint i=0; i<uint(list.count()); i++) log(Log::LineType::Normal, TQString(" %1: %2").arg(toHexLabel(list[i].data().address(), rdata.nbCharsAddress())).arg(list[i].label())); return OK; } @@ -292,7 +292,7 @@ CLI::ExitCode CLI::Interactive::executeRegister(const TQString &name, const TQSt bool ok; ulong v = fromAnyLabel(value, &ok); if ( !ok ) return errorExit(i18n("Number format not recognized."), ARG_ERROR); - if ( v>maxValue(NumberBase::Hex, nbChars) ) return errorExit(i18n("The given value is too large (max: %1).").tqarg(toHexLabel(maxValue(NumberBase::Hex, nbChars), nbChars)), ARG_ERROR); + if ( v>maxValue(NumberBase::Hex, nbChars) ) return errorExit(i18n("The given value is too large (max: %1).").arg(toHexLabel(maxValue(NumberBase::Hex, nbChars), nbChars)), ARG_ERROR); Register::TypeData rtd; if ( name.lower()=="w" || name.lower()=="wreg" ) rtd = static_cast<Debugger::PicBase *>(Debugger::manager->debugger())->deviceSpecific()->wregTypeData(); @@ -305,7 +305,7 @@ CLI::ExitCode CLI::Interactive::executeRegister(const TQString &name, const TQSt } if ( value.isEmpty() ) { if ( !Debugger::manager->readRegister(rtd) ) return ARG_ERROR; - return okExit(i18n("%1 = %2").tqarg(name.upper()).tqarg(toHexLabel(Register::list().value(rtd), nbChars))); + return okExit(i18n("%1 = %2").arg(name.upper()).arg(toHexLabel(Register::list().value(rtd), nbChars))); } return (Debugger::manager->writeRegister(rtd, v) ? OK : EXEC_ERROR); } @@ -313,7 +313,7 @@ CLI::ExitCode CLI::Interactive::executeRegister(const TQString &name, const TQSt CLI::ExitCode CLI::Interactive::executeRawCommands(const TQString &filename) { TQFile file(filename); - if ( !file.open(IO_ReadOnly) ) return errorExit(i18n("Could not open filename \"%1\".").tqarg(filename), ARG_ERROR); + if ( !file.open(IO_ReadOnly) ) return errorExit(i18n("Could not open filename \"%1\".").arg(filename), ARG_ERROR); if ( Programmer::manager->programmer()==0 ) { Programmer::manager->createProgrammer(_device); if ( !Programmer::manager->programmer()->simpleConnectHardware() ) return EXEC_ERROR; @@ -330,7 +330,7 @@ CLI::ExitCode CLI::Interactive::executeRawCommands(const TQString &filename) } else { TQString rs; if ( !programmer->hardware()->rawRead(s.length(), rs) ) return EXEC_ERROR; - if ( rs!=s ) log(Log::LineType::Warning, i18n("Read string is different than expected: %1 (%2).").tqarg(rs).tqarg(s)); + if ( rs!=s ) log(Log::LineType::Warning, i18n("Read string is different than expected: %1 (%2).").arg(rs).arg(s)); } } return okExit(i18n("End of command file reached.")); |