Naming and coding style convention, new linter tool. (#945)
* Makefile, Scripts: new linter * About: remove ID from IC * Firmware: remove double define for DIVC/DIVR * Scripts: check folder names too. Docker: replace syntax check with make lint. * Reformat Sources and Migrate to new file naming convention * Docker: symlink clang-format-12 to clang-format * Add coding style guide
This commit is contained in:
+4
-4
@@ -1,7 +1,7 @@
|
||||
#include "lfrfid-app-scene-delete-confirm.h"
|
||||
#include "../view/elements/button-element.h"
|
||||
#include "../view/elements/icon-element.h"
|
||||
#include "../view/elements/string-element.h"
|
||||
#include "lfrfid_app_scene_delete_confirm.h"
|
||||
#include "../view/elements/button_element.h"
|
||||
#include "../view/elements/icon_element.h"
|
||||
#include "../view/elements/string_element.h"
|
||||
|
||||
void LfRfidAppSceneDeleteConfirm::on_enter(LfRfidApp* app, bool need_restore) {
|
||||
string_init(string_data);
|
||||
+1
-1
@@ -1,5 +1,5 @@
|
||||
#pragma once
|
||||
#include "../lfrfid-app.h"
|
||||
#include "../lfrfid_app.h"
|
||||
|
||||
class LfRfidAppSceneDeleteConfirm : public GenericScene<LfRfidApp> {
|
||||
public:
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
#include "lfrfid-app-scene-delete-success.h"
|
||||
#include "lfrfid_app_scene_delete_success.h"
|
||||
|
||||
void LfRfidAppSceneDeleteSuccess::on_enter(LfRfidApp* app, bool need_restore) {
|
||||
auto popup = app->view_controller.get<PopupVM>();
|
||||
+1
-1
@@ -1,5 +1,5 @@
|
||||
#pragma once
|
||||
#include "../lfrfid-app.h"
|
||||
#include "../lfrfid_app.h"
|
||||
|
||||
class LfRfidAppSceneDeleteSuccess : public GenericScene<LfRfidApp> {
|
||||
public:
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
#include "lfrfid-app-scene-emulate.h"
|
||||
#include "lfrfid_app_scene_emulate.h"
|
||||
|
||||
void LfRfidAppSceneEmulate::on_enter(LfRfidApp* app, bool need_restore) {
|
||||
string_init(data_string);
|
||||
+1
-1
@@ -1,5 +1,5 @@
|
||||
#pragma once
|
||||
#include "../lfrfid-app.h"
|
||||
#include "../lfrfid_app.h"
|
||||
|
||||
class LfRfidAppSceneEmulate : public GenericScene<LfRfidApp> {
|
||||
public:
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
#include "lfrfid-app-scene-read.h"
|
||||
#include "lfrfid_app_scene_read.h"
|
||||
|
||||
void LfRfidAppSceneRead::on_enter(LfRfidApp* app, bool need_restore) {
|
||||
auto popup = app->view_controller.get<PopupVM>();
|
||||
+1
-1
@@ -1,5 +1,5 @@
|
||||
#pragma once
|
||||
#include "../lfrfid-app.h"
|
||||
#include "../lfrfid_app.h"
|
||||
|
||||
class LfRfidAppSceneRead : public GenericScene<LfRfidApp> {
|
||||
public:
|
||||
+4
-4
@@ -1,7 +1,7 @@
|
||||
#include "lfrfid-app-scene-read-success.h"
|
||||
#include "../view/elements/button-element.h"
|
||||
#include "../view/elements/icon-element.h"
|
||||
#include "../view/elements/string-element.h"
|
||||
#include "lfrfid_app_scene_read_success.h"
|
||||
#include "../view/elements/button_element.h"
|
||||
#include "../view/elements/icon_element.h"
|
||||
#include "../view/elements/string_element.h"
|
||||
|
||||
void LfRfidAppSceneReadSuccess::on_enter(LfRfidApp* app, bool need_restore) {
|
||||
string_init(string[0]);
|
||||
+1
-1
@@ -1,5 +1,5 @@
|
||||
#pragma once
|
||||
#include "../lfrfid-app.h"
|
||||
#include "../lfrfid_app.h"
|
||||
|
||||
class LfRfidAppSceneReadSuccess : public GenericScene<LfRfidApp> {
|
||||
public:
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
#include "lfrfid-app-scene-readed-menu.h"
|
||||
#include "lfrfid_app_scene_readed_menu.h"
|
||||
|
||||
typedef enum {
|
||||
SubmenuWrite,
|
||||
+1
-1
@@ -1,5 +1,5 @@
|
||||
#pragma once
|
||||
#include "../lfrfid-app.h"
|
||||
#include "../lfrfid_app.h"
|
||||
|
||||
class LfRfidAppSceneReadedMenu : public GenericScene<LfRfidApp> {
|
||||
public:
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
#include "lfrfid-app-scene-save-data.h"
|
||||
#include "lfrfid_app_scene_save_data.h"
|
||||
|
||||
static void print_buffer(const uint8_t* buffer) {
|
||||
for(uint8_t i = 0; i < LFRFID_KEY_SIZE; i++) {
|
||||
+1
-1
@@ -1,5 +1,5 @@
|
||||
#pragma once
|
||||
#include "../lfrfid-app.h"
|
||||
#include "../lfrfid_app.h"
|
||||
|
||||
class LfRfidAppSceneSaveData : public GenericScene<LfRfidApp> {
|
||||
public:
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
#include "lfrfid-app-scene-save-name.h"
|
||||
#include "lfrfid_app_scene_save_name.h"
|
||||
#include <lib/toolbox/random_name.h>
|
||||
|
||||
void LfRfidAppSceneSaveName::on_enter(LfRfidApp* app, bool need_restore) {
|
||||
+1
-1
@@ -1,5 +1,5 @@
|
||||
#pragma once
|
||||
#include "../lfrfid-app.h"
|
||||
#include "../lfrfid_app.h"
|
||||
|
||||
class LfRfidAppSceneSaveName : public GenericScene<LfRfidApp> {
|
||||
public:
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
#include "lfrfid-app-scene-save-success.h"
|
||||
#include "lfrfid_app_scene_save_success.h"
|
||||
|
||||
void LfRfidAppSceneSaveSuccess::on_enter(LfRfidApp* app, bool need_restore) {
|
||||
auto popup = app->view_controller.get<PopupVM>();
|
||||
+1
-1
@@ -1,5 +1,5 @@
|
||||
#pragma once
|
||||
#include "../lfrfid-app.h"
|
||||
#include "../lfrfid_app.h"
|
||||
|
||||
class LfRfidAppSceneSaveSuccess : public GenericScene<LfRfidApp> {
|
||||
public:
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
#include "lfrfid-app-scene-save-type.h"
|
||||
#include "lfrfid_app_scene_save_type.h"
|
||||
|
||||
void LfRfidAppSceneSaveType::on_enter(LfRfidApp* app, bool need_restore) {
|
||||
auto submenu = app->view_controller.get<SubmenuVM>();
|
||||
+1
-1
@@ -1,5 +1,5 @@
|
||||
#pragma once
|
||||
#include "../lfrfid-app.h"
|
||||
#include "../lfrfid_app.h"
|
||||
|
||||
class LfRfidAppSceneSaveType : public GenericScene<LfRfidApp> {
|
||||
public:
|
||||
+4
-4
@@ -1,7 +1,7 @@
|
||||
#include "lfrfid-app-scene-saved-info.h"
|
||||
#include "../view/elements/button-element.h"
|
||||
#include "../view/elements/icon-element.h"
|
||||
#include "../view/elements/string-element.h"
|
||||
#include "lfrfid_app_scene_saved_info.h"
|
||||
#include "../view/elements/button_element.h"
|
||||
#include "../view/elements/icon_element.h"
|
||||
#include "../view/elements/string_element.h"
|
||||
|
||||
void LfRfidAppSceneSavedInfo::on_enter(LfRfidApp* app, bool need_restore) {
|
||||
string_init(string_data);
|
||||
+1
-1
@@ -1,5 +1,5 @@
|
||||
#pragma once
|
||||
#include "../lfrfid-app.h"
|
||||
#include "../lfrfid_app.h"
|
||||
|
||||
class LfRfidAppSceneSavedInfo : public GenericScene<LfRfidApp> {
|
||||
public:
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
#include "lfrfid-app-scene-saved-key-menu.h"
|
||||
#include "lfrfid_app_scene_saved_key_menu.h"
|
||||
|
||||
typedef enum {
|
||||
SubmenuEmulate,
|
||||
+1
-1
@@ -1,5 +1,5 @@
|
||||
#pragma once
|
||||
#include "../lfrfid-app.h"
|
||||
#include "../lfrfid_app.h"
|
||||
|
||||
class LfRfidAppSceneSavedKeyMenu : public GenericScene<LfRfidApp> {
|
||||
public:
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
#include "lfrfid-app-scene-select-key.h"
|
||||
#include "lfrfid_app_scene_select_key.h"
|
||||
|
||||
void LfRfidAppSceneSelectKey::on_enter(LfRfidApp* app, bool need_restore) {
|
||||
if(app->load_key_from_file_select(need_restore)) {
|
||||
+1
-1
@@ -1,5 +1,5 @@
|
||||
#pragma once
|
||||
#include "../lfrfid-app.h"
|
||||
#include "../lfrfid_app.h"
|
||||
|
||||
class LfRfidAppSceneSelectKey : public GenericScene<LfRfidApp> {
|
||||
public:
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
#include "lfrfid-app-scene-start.h"
|
||||
#include "lfrfid_app_scene_start.h"
|
||||
|
||||
typedef enum {
|
||||
SubmenuRead,
|
||||
+1
-1
@@ -1,5 +1,5 @@
|
||||
#pragma once
|
||||
#include "../lfrfid-app.h"
|
||||
#include "../lfrfid_app.h"
|
||||
|
||||
class LfRfidAppSceneStart : public GenericScene<LfRfidApp> {
|
||||
public:
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
#include "lfrfid-app-scene-write.h"
|
||||
#include "lfrfid_app_scene_write.h"
|
||||
|
||||
void LfRfidAppSceneWrite::on_enter(LfRfidApp* app, bool need_restore) {
|
||||
card_not_supported = false;
|
||||
+1
-1
@@ -1,5 +1,5 @@
|
||||
#pragma once
|
||||
#include "../lfrfid-app.h"
|
||||
#include "../lfrfid_app.h"
|
||||
|
||||
class LfRfidAppSceneWrite : public GenericScene<LfRfidApp> {
|
||||
public:
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
#include "lfrfid-app-scene-write-success.h"
|
||||
#include "lfrfid_app_scene_write_success.h"
|
||||
|
||||
void LfRfidAppSceneWriteSuccess::on_enter(LfRfidApp* app, bool need_restore) {
|
||||
auto popup = app->view_controller.get<PopupVM>();
|
||||
+1
-1
@@ -1,5 +1,5 @@
|
||||
#pragma once
|
||||
#include "../lfrfid-app.h"
|
||||
#include "../lfrfid_app.h"
|
||||
|
||||
class LfRfidAppSceneWriteSuccess : public GenericScene<LfRfidApp> {
|
||||
public:
|
||||
Reference in New Issue
Block a user