From 69fae1b9775621d29d241188fc40de2a95241806 Mon Sep 17 00:00:00 2001 From: Richard von Lehe Date: Sat, 28 Mar 2015 23:27:07 -0500 Subject: [PATCH] Fix misspelling in function name --- .../generators/flight/uavobjectgeneratorflight.cpp | 10 +++++----- .../generators/gcs/uavobjectgeneratorgcs.cpp | 6 +++--- ground/uavobjgenerator/generators/generator_io.cpp | 2 +- ground/uavobjgenerator/generators/generator_io.h | 2 +- .../generators/java/uavobjectgeneratorjava.cpp | 4 ++-- .../generators/python/uavobjectgeneratorpython.cpp | 2 +- .../wireshark/uavobjectgeneratorwireshark.cpp | 4 ++-- 7 files changed, 15 insertions(+), 15 deletions(-) diff --git a/ground/uavobjgenerator/generators/flight/uavobjectgeneratorflight.cpp b/ground/uavobjgenerator/generators/flight/uavobjectgeneratorflight.cpp index 1cc41bbf7..289831003 100644 --- a/ground/uavobjgenerator/generators/flight/uavobjectgeneratorflight.cpp +++ b/ground/uavobjgenerator/generators/flight/uavobjectgeneratorflight.cpp @@ -68,7 +68,7 @@ bool UAVObjectGeneratorFlight::generate(UAVObjectParser *parser, QString templat // Write the flight object inialization files flightInitTemplate.replace(QString("$(OBJINC)"), objInc); flightInitTemplate.replace(QString("$(OBJINIT)"), flightObjInit); - bool res = writeFileIfDiffrent(flightOutputPath.absolutePath() + "/uavobjectsinit.c", + bool res = writeFileIfDifferent(flightOutputPath.absolutePath() + "/uavobjectsinit.c", flightInitTemplate); if (!res) { cout << "Error: Could not write flight object init file" << endl; @@ -77,7 +77,7 @@ bool UAVObjectGeneratorFlight::generate(UAVObjectParser *parser, QString templat // Write the flight object initialization header flightInitIncludeTemplate.replace(QString("$(SIZECALCULATION)"), QString().setNum(sizeCalc)); - res = writeFileIfDiffrent(flightOutputPath.absolutePath() + "/uavobjectsinit.h", + res = writeFileIfDifferent(flightOutputPath.absolutePath() + "/uavobjectsinit.h", flightInitIncludeTemplate); if (!res) { cout << "Error: Could not write flight object init header file" << endl; @@ -87,7 +87,7 @@ bool UAVObjectGeneratorFlight::generate(UAVObjectParser *parser, QString templat // Write the flight object Makefile flightMakeTemplate.replace(QString("$(UAVOBJFILENAMES)"), objFileNames); flightMakeTemplate.replace(QString("$(UAVOBJNAMES)"), objNames); - res = writeFileIfDiffrent(flightOutputPath.absolutePath() + "/Makefile.inc", + res = writeFileIfDifferent(flightOutputPath.absolutePath() + "/Makefile.inc", flightMakeTemplate); if (!res) { cout << "Error: Could not write flight Makefile" << endl; @@ -394,13 +394,13 @@ bool UAVObjectGeneratorFlight::process_object(ObjectInfo *info) outInclude.replace(QString("$(SETGETFIELDSEXTERN)"), setgetfieldsextern); // Write the flight code - bool res = writeFileIfDiffrent(flightOutputPath.absolutePath() + "/" + info->namelc + ".c", outCode); + bool res = writeFileIfDifferent(flightOutputPath.absolutePath() + "/" + info->namelc + ".c", outCode); if (!res) { cout << "Error: Could not write flight code files" << endl; return false; } - res = writeFileIfDiffrent(flightOutputPath.absolutePath() + "/" + info->namelc + ".h", outInclude); + res = writeFileIfDifferent(flightOutputPath.absolutePath() + "/" + info->namelc + ".h", outInclude); if (!res) { cout << "Error: Could not write flight include files" << endl; return false; diff --git a/ground/uavobjgenerator/generators/gcs/uavobjectgeneratorgcs.cpp b/ground/uavobjgenerator/generators/gcs/uavobjectgeneratorgcs.cpp index 1279e8e4f..bfb05a36c 100644 --- a/ground/uavobjgenerator/generators/gcs/uavobjectgeneratorgcs.cpp +++ b/ground/uavobjgenerator/generators/gcs/uavobjectgeneratorgcs.cpp @@ -62,7 +62,7 @@ bool UAVObjectGeneratorGCS::generate(UAVObjectParser *parser, QString templatepa // Write the gcs object inialization files gcsInitTemplate.replace(QString("$(OBJINC)"), objInc); gcsInitTemplate.replace(QString("$(OBJINIT)"), gcsObjInit); - bool res = writeFileIfDiffrent(gcsOutputPath.absolutePath() + "/uavobjectsinit.cpp", gcsInitTemplate); + bool res = writeFileIfDifferent(gcsOutputPath.absolutePath() + "/uavobjectsinit.cpp", gcsInitTemplate); if (!res) { cout << "Error: Could not write output files" << endl; return false; @@ -371,12 +371,12 @@ bool UAVObjectGeneratorGCS::process_object(ObjectInfo *info) outCode.replace(QString("$(INITFIELDS)"), initfields); // Write the GCS code - bool res = writeFileIfDiffrent(gcsOutputPath.absolutePath() + "/" + info->namelc + ".cpp", outCode); + bool res = writeFileIfDifferent(gcsOutputPath.absolutePath() + "/" + info->namelc + ".cpp", outCode); if (!res) { cout << "Error: Could not write gcs output files" << endl; return false; } - res = writeFileIfDiffrent(gcsOutputPath.absolutePath() + "/" + info->namelc + ".h", outInclude); + res = writeFileIfDifferent(gcsOutputPath.absolutePath() + "/" + info->namelc + ".h", outInclude); if (!res) { cout << "Error: Could not write gcs output files" << endl; return false; diff --git a/ground/uavobjgenerator/generators/generator_io.cpp b/ground/uavobjgenerator/generators/generator_io.cpp index 67afdd05a..fa352e277 100644 --- a/ground/uavobjgenerator/generators/generator_io.cpp +++ b/ground/uavobjgenerator/generators/generator_io.cpp @@ -75,7 +75,7 @@ bool writeFile(QString name, QString & str) /** * Write contents of string to file if the content changes */ -bool writeFileIfDiffrent(QString name, QString & str) +bool writeFileIfDifferent(QString name, QString & str) { if (str == readFile(name, false)) { return true; diff --git a/ground/uavobjgenerator/generators/generator_io.h b/ground/uavobjgenerator/generators/generator_io.h index 8d4500bf4..8987696fe 100644 --- a/ground/uavobjgenerator/generators/generator_io.h +++ b/ground/uavobjgenerator/generators/generator_io.h @@ -37,6 +37,6 @@ QString readFile(QString name); QString readFile(QString name); bool writeFile(QString name, QString & str); -bool writeFileIfDiffrent(QString name, QString & str); +bool writeFileIfDifferent(QString name, QString & str); #endif diff --git a/ground/uavobjgenerator/generators/java/uavobjectgeneratorjava.cpp b/ground/uavobjgenerator/generators/java/uavobjectgeneratorjava.cpp index a4e97457d..bbd788c1f 100644 --- a/ground/uavobjgenerator/generators/java/uavobjectgeneratorjava.cpp +++ b/ground/uavobjgenerator/generators/java/uavobjectgeneratorjava.cpp @@ -62,7 +62,7 @@ bool UAVObjectGeneratorJava::generate(UAVObjectParser *parser, QString templatep // Write the gcs object inialization files javaInitTemplate.replace(QString("$(OBJINC)"), objInc); javaInitTemplate.replace(QString("$(OBJINIT)"), javaObjInit); - bool res = writeFileIfDiffrent(javaOutputPath.absolutePath() + "/UAVObjectsInitialize.java", javaInitTemplate); + bool res = writeFileIfDifferent(javaOutputPath.absolutePath() + "/UAVObjectsInitialize.java", javaInitTemplate); if (!res) { cout << "Error: Could not write output files" << endl; return false; @@ -238,7 +238,7 @@ bool UAVObjectGeneratorJava::process_object(ObjectInfo *info) outCode.replace(QString("$(INITFIELDS)"), initfields); // Write the java code - bool res = writeFileIfDiffrent(javaOutputPath.absolutePath() + "/" + info->name + ".java", outCode); + bool res = writeFileIfDifferent(javaOutputPath.absolutePath() + "/" + info->name + ".java", outCode); if (!res) { cout << "Error: Could not write gcs output files" << endl; return false; diff --git a/ground/uavobjgenerator/generators/python/uavobjectgeneratorpython.cpp b/ground/uavobjgenerator/generators/python/uavobjectgeneratorpython.cpp index f1ee41143..2703e59cc 100644 --- a/ground/uavobjgenerator/generators/python/uavobjectgeneratorpython.cpp +++ b/ground/uavobjgenerator/generators/python/uavobjectgeneratorpython.cpp @@ -110,7 +110,7 @@ bool UAVObjectGeneratorPython::process_object(ObjectInfo *info) outCode.replace(QString("$(DATAFIELDINIT)"), fields); // Write the Python code - bool res = writeFileIfDiffrent(pythonOutputPath.absolutePath() + "/" + info->namelc + ".py", outCode); + bool res = writeFileIfDifferent(pythonOutputPath.absolutePath() + "/" + info->namelc + ".py", outCode); if (!res) { cout << "Error: Could not write Python output files" << endl; return false; diff --git a/ground/uavobjgenerator/generators/wireshark/uavobjectgeneratorwireshark.cpp b/ground/uavobjgenerator/generators/wireshark/uavobjectgeneratorwireshark.cpp index 8a095f342..c06c9df46 100644 --- a/ground/uavobjgenerator/generators/wireshark/uavobjectgeneratorwireshark.cpp +++ b/ground/uavobjgenerator/generators/wireshark/uavobjectgeneratorwireshark.cpp @@ -93,7 +93,7 @@ bool UAVObjectGeneratorWireshark::generate(UAVObjectParser *parser, QString temp /* Write the uavobject dissector's Makefile.common */ wiresharkMakeTemplate.replace(QString("$(UAVOBJFILENAMES)"), objFileNames); - bool res = writeFileIfDiffrent(uavobjectsOutputPath.absolutePath() + "/Makefile.common", + bool res = writeFileIfDifferent(uavobjectsOutputPath.absolutePath() + "/Makefile.common", wiresharkMakeTemplate); if (!res) { cout << "Error: Could not write wireshark Makefile" << endl; @@ -279,7 +279,7 @@ bool UAVObjectGeneratorWireshark::process_object(ObjectInfo *info, QDir outputpa outCode.replace(QString("$(HEADERFIELDS)"), headerfields); // Write the flight code - bool res = writeFileIfDiffrent(outputpath.absolutePath() + "/packet-op-uavobjects-" + info->namelc + ".c", outCode); + bool res = writeFileIfDifferent(outputpath.absolutePath() + "/packet-op-uavobjects-" + info->namelc + ".c", outCode); if (!res) { cout << "Error: Could not write wireshark code files" << endl; return false;