26 lines
693 B
C
26 lines
693 B
C
#include <curses.h>
|
|
#include <dirent.h>
|
|
#include <unistd.h>
|
|
#include "defines.h"
|
|
|
|
|
|
extern unsigned int file_modifiers;
|
|
|
|
void user_interactions(char *input, unsigned int *status, unsigned int *settings) {
|
|
if (*input == 'q') {
|
|
*status ^= STATUS_QUIT_PROGRAM;
|
|
} else if (*input == *"KEY_BACKSPACE") {
|
|
file_modifiers ^= FILE_MODIFIERS_HIDDEN_FILES;
|
|
} else if (*input == 'a') {
|
|
file_modifiers ^= FILE_MODIFIERS_HIDDEN_FILES;
|
|
} else if (*input == 'o') {
|
|
file_modifiers ^= FILE_MODIFIERS_SORT_BITMASK;
|
|
} else if (*input == 'e') {
|
|
file_modifiers ^= FILE_MODIFIERS_SORT_ALPHABETIC;
|
|
} else if (*input == 'u') {
|
|
|
|
} else {
|
|
}
|
|
*status |= (STATUS_RUN_BACKEND | STATUS_UPDATE_SCREEN_0);
|
|
}
|