[FL-1489] IRDA: move to FileWorker (#594)
* [FL-1489] IRDA: move to FileWorker, fixes * Use FileWorker * Use file_select to select remotes * Fix some crashes * Add RAW parsing restrictions * Remove excess scene (LearnDoneAfter) * Move all file system logic to standalone object
This commit is contained in:
@@ -163,8 +163,55 @@ bool file_worker_file_select(
|
||||
const char* extension,
|
||||
char* result,
|
||||
uint8_t result_size,
|
||||
char* selected_filename);
|
||||
const char* selected_filename);
|
||||
|
||||
/**
|
||||
* @brief Reads data from a file until separator or EOF is found.
|
||||
* The separator is included in the result.
|
||||
*
|
||||
* @param file_worker FileWorker instance
|
||||
* @param str_result
|
||||
* @param file_buf
|
||||
* @param file_buf_cnt
|
||||
* @param max_length
|
||||
* @param separator
|
||||
* @return true on success
|
||||
*/
|
||||
bool file_worker_read_until_buffered(FileWorker* file_worker, string_t str_result, char* file_buf, size_t* file_buf_cnt, size_t max_length, char separator);
|
||||
|
||||
/**
|
||||
* @brief Check whether file exist or not
|
||||
*
|
||||
* @param file_worker FileWorker instance
|
||||
* @param filename
|
||||
* @param exist - flag to show file exist
|
||||
* @return true on success
|
||||
*/
|
||||
bool file_worker_is_file_exist(
|
||||
FileWorker* file_worker,
|
||||
const char* filename,
|
||||
bool* exist);
|
||||
|
||||
/**
|
||||
* @brief Rename file or directory
|
||||
*
|
||||
* @param file_worker FileWorker instance
|
||||
* @param old_filename
|
||||
* @param new_filename
|
||||
* @return true on success
|
||||
*/
|
||||
bool file_worker_rename(FileWorker* file_worker,
|
||||
const char* old_path,
|
||||
const char* new_path);
|
||||
|
||||
/**
|
||||
* @brief Check errors
|
||||
*
|
||||
* @param file_worker FileWorker instance
|
||||
* @return true on success
|
||||
*/
|
||||
bool file_worker_check_errors(FileWorker* file_worker);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user