Apply suggestions from code review

Co-authored-by: Yaya-Cout <yaya.cout@free.fr>
This commit is contained in:
devdl11
2022-04-26 15:26:34 +02:00
committed by GitHub
parent 18ff283580
commit 0e49d23faa
19 changed files with 17 additions and 25 deletions

View File

@@ -57,4 +57,4 @@ public:
}
#endif
#endif

View File

@@ -150,4 +150,4 @@ namespace STM32 {
extern void rcc_deinit();
extern void hal_deinit();
extern void systick_deinit();
}
}

View File

@@ -17,4 +17,4 @@ void Bootloader::AboutMenu::setup() {
m_columns[2] = ColumnBinder(&m_default_columns[2]);
m_columns[3] = ColumnBinder(&m_default_columns[3]);
m_columns[4] = ColumnBinder(&m_default_columns[4]);
}
}

View File

@@ -14,4 +14,4 @@ namespace Bootloader {
}
#endif
#endif

View File

@@ -19,4 +19,4 @@ void Bootloader::CrashMenu::post_open() {
for (;;) {
// Infinite loop
}
}
}

View File

@@ -16,4 +16,4 @@ namespace Bootloader {
};
}
#endif
#endif

View File

@@ -34,4 +34,4 @@ void Bootloader::DfuMenu::post_open() {
} while (!Ion::USB::isEnumerated());
Ion::USB::DFU(true, (void *)m_data);
}
}
}

View File

@@ -141,4 +141,4 @@ void Bootloader::HomeMenu::setup() {
m_columns[3] = ColumnBinder(&m_default_columns[0]);
m_columns[4] = ColumnBinder(&m_default_columns[1]);
}
}

View File

@@ -38,4 +38,4 @@ void Bootloader::InstallerMenu::setup() {
m_columns[0] = ColumnBinder(&m_default_columns[0]);
m_columns[1] = ColumnBinder(&m_default_columns[1]);
m_columns[2] = ColumnBinder(&m_default_columns[2]);
}
}

View File

@@ -17,4 +17,4 @@ namespace Bootloader {
};
}
#endif
#endif

View File

@@ -36,4 +36,4 @@ void Bootloader::SlotRecoveryMenu::post_open() {
} while (!Ion::USB::isEnumerated());
Ion::USB::DFU(true, (void *)m_data);
}
}
}

View File

@@ -16,4 +16,4 @@ namespace Bootloader {
};
}
#endif
#endif

View File

@@ -32,4 +32,4 @@ void Bootloader::WarningMenu::setup() {
m_columns[3] = ColumnBinder(&m_default_columns[3]);
m_columns[4] = ColumnBinder(&m_default_columns[4]);
m_columns[5] = ColumnBinder(&m_default_columns[5]);
}
}

View File

@@ -14,4 +14,4 @@ namespace Bootloader {
};
}
#endif
#endif

View File

@@ -123,4 +123,4 @@ namespace Bootloader {
};
}
#endif // _BOOTLOADER_MENU_H_
#endif // _BOOTLOADER_MENU_H_

View File

@@ -1,4 +1,3 @@
#include <assert.h>
#include <ion.h>
#include <ion/timing.h>

View File

@@ -16,4 +16,4 @@ public:
}
#endif
#endif

View File

@@ -5,14 +5,7 @@ namespace Bootloader {
class Messages {
public:
// TODO: Remove it when this fork will be updated
#ifdef UPSILON_VERSION
constexpr static const char * mainTitle = "Upsilon Calculator";
#elif defined OMEGA_VERSION
constexpr static const char * mainTitle = "Omega Calculator";
#else
constexpr static const char * mainTitle = "NumWorks Calculator";
#endif
// home menu
constexpr static const char * homeTitle = "Select a slot";

View File

@@ -11,7 +11,7 @@
__attribute__ ((noreturn)) void ion_main(int argc, const char * const argv[]) {
// Clear the screen
Ion::Display::pushRectUniform(KDRect(0,0,320,240), KDColorWhite);
Ion::Display::pushRectUniform(KDRect(0,0,320,240), KDColorBlack);
// Initialize the backlight
Ion::Backlight::init();