diff --git a/.clang-format b/.clang-format index 6a2af9ee..ad9757ab 100644 --- a/.clang-format +++ b/.clang-format @@ -41,7 +41,7 @@ IncludeIsMainRegex: '(Test)?$' IndentCaseLabels: false IndentPPDirectives: None IndentWidth: 4 -IndentWrappedFunctionNames: false +IndentWrappedFunctionNames: true JavaScriptQuotes: Leave JavaScriptWrapImports: true KeepEmptyLinesAtTheStartOfBlocks: false diff --git a/applications/accessor/helpers/wiegand.h b/applications/accessor/helpers/wiegand.h index fed9fa14..2822d95a 100644 --- a/applications/accessor/helpers/wiegand.h +++ b/applications/accessor/helpers/wiegand.h @@ -15,8 +15,10 @@ public: private: static bool DoWiegandConversion(); - static unsigned long - GetCardId(volatile unsigned long* codehigh, volatile unsigned long* codelow, char bitlength); + static unsigned long GetCardId( + volatile unsigned long* codehigh, + volatile unsigned long* codelow, + char bitlength); static volatile unsigned long _cardTempHigh; static volatile unsigned long _cardTemp; diff --git a/applications/irda/irda-app-file-parser.cpp b/applications/irda/irda-app-file-parser.cpp index fb3442b2..07c104b8 100644 --- a/applications/irda/irda-app-file-parser.cpp +++ b/applications/irda/irda-app-file-parser.cpp @@ -11,7 +11,7 @@ std::unique_ptr IrdaAppFileParser::read_mess } std::unique_ptr -IrdaAppFileParser::parse_message(const std::string& str) const { + IrdaAppFileParser::parse_message(const std::string& str) const { char protocol_name[32]; uint32_t address; uint32_t command; diff --git a/applications/irda/irda-app-remote-manager.cpp b/applications/irda/irda-app-remote-manager.cpp index d2fe627b..4ae6c00c 100644 --- a/applications/irda/irda-app-remote-manager.cpp +++ b/applications/irda/irda-app-remote-manager.cpp @@ -21,7 +21,7 @@ static bool find_string(const std::vector& strings, const std::stri } static std::string -find_vacant_name(const std::vector& strings, const std::string& name) { + find_vacant_name(const std::vector& strings, const std::string& name) { // if suggested name is occupied, try another one (name2, name3, etc) if(find_string(strings, name)) { int i = 1; diff --git a/applications/menu/menu_item.c b/applications/menu/menu_item.c index 8c1a39a1..b3c4af96 100644 --- a/applications/menu/menu_item.c +++ b/applications/menu/menu_item.c @@ -37,8 +37,11 @@ MenuItem* menu_item_alloc_menu(const char* label, Icon* icon) { return menu_item; } -MenuItem* -menu_item_alloc_function(const char* label, Icon* icon, MenuItemCallback callback, void* context) { +MenuItem* menu_item_alloc_function( + const char* label, + Icon* icon, + MenuItemCallback callback, + void* context) { MenuItem* menu_item = menu_item_alloc(); menu_item->type = MenuItemTypeFunction; diff --git a/applications/menu/menu_item.h b/applications/menu/menu_item.h index 989cdcc8..ebfaed94 100644 --- a/applications/menu/menu_item.h +++ b/applications/menu/menu_item.h @@ -16,8 +16,11 @@ ARRAY_DEF(MenuItemArray, MenuItem*, M_PTR_OPLIST); MenuItem* menu_item_alloc_menu(const char* label, Icon* icon); -MenuItem* -menu_item_alloc_function(const char* label, Icon* icon, MenuItemCallback callback, void* context); +MenuItem* menu_item_alloc_function( + const char* label, + Icon* icon, + MenuItemCallback callback, + void* context); void menu_item_release(MenuItem* menu_item); diff --git a/applications/sd-card-test/sd-card-test.cpp b/applications/sd-card-test/sd-card-test.cpp index 55b26938..47613e4e 100644 --- a/applications/sd-card-test/sd-card-test.cpp +++ b/applications/sd-card-test/sd-card-test.cpp @@ -71,7 +71,7 @@ public: void free_benchmark_data(); void write_benchmark(); uint32_t - write_benchmark_internal(const uint32_t size, const uint32_t tcount, bool silent = false); + write_benchmark_internal(const uint32_t size, const uint32_t tcount, bool silent = false); void read_benchmark(); uint32_t read_benchmark_internal( diff --git a/applications/sd-filesystem/sd-filesystem-api.c b/applications/sd-filesystem/sd-filesystem-api.c index 6b6c9fb9..a4c52949 100644 --- a/applications/sd-filesystem/sd-filesystem-api.c +++ b/applications/sd-filesystem/sd-filesystem-api.c @@ -473,7 +473,7 @@ bool fs_dir_rewind(File* file) { // Get info about file/dir FS_Error -fs_common_info(const char* path, FileInfo* fileinfo, char* name, const uint16_t name_length) { + fs_common_info(const char* path, FileInfo* fileinfo, char* name, const uint16_t name_length) { SDFileInfo _fileinfo; SDError fresult = _fs_status(fs_info); diff --git a/applications/sd-filesystem/sd-filesystem.h b/applications/sd-filesystem/sd-filesystem.h index 3a4da79c..b9bb9ca2 100644 --- a/applications/sd-filesystem/sd-filesystem.h +++ b/applications/sd-filesystem/sd-filesystem.h @@ -132,7 +132,7 @@ bool fs_dir_rewind(File* file); /* common api */ FS_Error -fs_common_info(const char* path, FileInfo* fileinfo, char* name, const uint16_t name_length); + fs_common_info(const char* path, FileInfo* fileinfo, char* name, const uint16_t name_length); FS_Error fs_common_remove(const char* path); FS_Error fs_common_rename(const char* old_path, const char* new_path); FS_Error fs_common_set_attr(const char* path, uint8_t attr, uint8_t mask); diff --git a/applications/tests/irda_decoder/irda_decoder_test.c b/applications/tests/irda_decoder/irda_decoder_test.c index f3ba40b7..ff5ca5db 100644 --- a/applications/tests/irda_decoder/irda_decoder_test.c +++ b/applications/tests/irda_decoder/irda_decoder_test.c @@ -18,8 +18,9 @@ static void test_teardown(void) { irda_free_decoder(decoder); } -static void -compare_message_results(const IrdaMessage* message_decoded, const IrdaMessage* message_expected) { +static void compare_message_results( + const IrdaMessage* message_decoded, + const IrdaMessage* message_expected) { mu_check(message_decoded->protocol == message_expected->protocol); mu_check(message_decoded->command == message_expected->command); mu_check(message_decoded->address == message_expected->address); diff --git a/core/api-hal/api-spi.h b/core/api-hal/api-spi.h index 131cc13c..8640d0d3 100644 --- a/core/api-hal/api-spi.h +++ b/core/api-hal/api-spi.h @@ -31,7 +31,7 @@ bool spi_xfer( Blocking verison: */ static inline bool -spi_xfer_block(SPI_HandleTypeDef* spi, uint8_t* tx_data, uint8_t* rx_data, size_t len) { + spi_xfer_block(SPI_HandleTypeDef* spi, uint8_t* tx_data, uint8_t* rx_data, size_t len) { semaphoreInfo s; osSemaphore block = createSemaphoreStatic(s); if(!spi_xfer(spi, tx_data, rx_data, len, RELEASE_SEMAPHORE, (void*)block)) {