[9XR-PRO] Warnings removed

This commit is contained in:
Bertrand Songis
2016-11-14 22:53:59 +01:00
parent 06e7e258e8
commit 8e77430cb1
4 changed files with 10 additions and 6 deletions
+1 -1
View File
@@ -213,7 +213,7 @@ int8_t checkIncDecGen(event_t event, int8_t i_val, int8_t i_min, int8_t i_max);
#define CHECK_INCDEC_GENVAR(event, var, min, max) \
var = checkIncDecGen(event, var, min, max)
#if defined(CPUARM)
#if defined(PCBTARANIS)
#define CURSOR_ON_LINE() (menuHorizontalPosition < 0)
#else
#define CURSOR_ON_LINE() (0)
+1 -1
View File
@@ -775,7 +775,7 @@ void menuModelTelemetryFrsky(event_t event)
}
}
#else
if (attr && menuHorizontalPosition<0) {
if (attr && CURSOR_ON_LINE()) {
lcdDrawSolidFilledRect(TELEM_COL2-1, y-1, LCD_W-TELEM_COL2+1, FH+1);
}
lcdDrawNumber(TELEM_COL2, y, -10+g_model.frsky.varioMin, ((CURSOR_ON_LINE() || menuHorizontalPosition==0) ? attr : 0)|LEFT);
-2
View File
@@ -92,8 +92,6 @@ inline void TELEMETRY_RESET()
#endif
}
bool checkScreenshot(QString test);
class OpenTxTest : public testing::Test
{
protected: // You should make the members protected s.t. they can be
+8 -2
View File
@@ -83,11 +83,17 @@ bool checkScreenshot(const QString & test)
QImage buffer(LCD_W, LCD_H, QImage::Format_RGB32);
QPainter p(&buffer);
doPaint(p);
QString filename(QString("%1_%2x%3.png").arg(test).arg(LCD_W).arg(LCD_H));
QImage reference(TESTS_PATH "/tests/" + filename);
return buffer == reference;
if (buffer == reference) {
return true;
}
else {
QString filename(QString("%1_%2x%3.png").arg(test).arg(LCD_W).arg(LCD_H));
buffer.save("/tmp/" + filename);
return false;
}
}
#if defined(COLORLCD)