mirror of
https://gittea.dev/nova/th.git
synced 2025-10-21 10:20:15 -04:00
Compare commits
2 Commits
0b98e8eb68
...
23ff0b07ec
Author | SHA1 | Date | |
---|---|---|---|
![]() |
23ff0b07ec | ||
![]() |
c2d88f4909 |
@@ -188,14 +188,6 @@ int strcmp_offset(char *in0, char *in1, char offset){
|
||||
void quit_program(){
|
||||
status = STATUS_QUIT_PROGRAM;
|
||||
}
|
||||
void toggle_selection(){
|
||||
pthread_mutex_lock(&mutex_selection);
|
||||
pthread_mutex_lock(&mutex_mid);
|
||||
mid_content[selected_file_current].status ^= FILE_STATUS_SELECTED;
|
||||
status |= (STATUS_UPDATE_SCREEN_MASK);
|
||||
pthread_mutex_unlock(&mutex_mid);
|
||||
pthread_mutex_unlock(&mutex_selection);
|
||||
}
|
||||
void select_all(){
|
||||
pthread_mutex_lock(&mutex_selection);
|
||||
pthread_mutex_lock(&mutex_mid);
|
||||
@@ -313,6 +305,15 @@ void toggle_hidden_files(){
|
||||
file_modifiers ^= FILE_MODIFIERS_HIDDEN_FILES;
|
||||
status |= (STATUS_RUN_BACKEND | STATUS_UPDATE_SCREEN_MASK | STATUS_RELOAD_DIRECTORY);
|
||||
}
|
||||
void toggle_selection(){
|
||||
pthread_mutex_lock(&mutex_selection);
|
||||
pthread_mutex_lock(&mutex_mid);
|
||||
mid_content[selected_file_current].status ^= FILE_STATUS_SELECTED;
|
||||
status |= (STATUS_UPDATE_SCREEN_MASK);
|
||||
pthread_mutex_unlock(&mutex_mid);
|
||||
pthread_mutex_unlock(&mutex_selection);
|
||||
move_down(1);
|
||||
}
|
||||
void jump_bottom(){
|
||||
pthread_mutex_lock(&mutex_selection);
|
||||
selected_file_current = 0 - 1;
|
||||
@@ -386,7 +387,9 @@ void rename_hovered(){
|
||||
mvwin(win_b, terminal_height-6, 0);
|
||||
wresize(win_b, 5, terminal_width/3); /*the div3 just looks cool*/
|
||||
|
||||
pthread_mutex_unlock(&mutex_btm);
|
||||
render_pass();
|
||||
pthread_mutex_lock(&mutex_btm);
|
||||
|
||||
unsigned long local_height;
|
||||
local_height = getmaxy(win_b);
|
||||
@@ -408,6 +411,7 @@ void rename_hovered(){
|
||||
};
|
||||
btm_buffer = cmd;
|
||||
}
|
||||
pthread_mutex_unlock(&mutex_btm);
|
||||
|
||||
status |= (STATUS_RUN_BACKEND | STATUS_UPDATE_SCREEN_MASK | STATUS_RELOAD_DIRECTORY | STATUS_UPDATE_SCREEN_RELOAD_FULL);
|
||||
|
||||
@@ -548,6 +552,7 @@ void makefile(){
|
||||
fclose(fp);
|
||||
}
|
||||
free(str);
|
||||
pthread_mutex_unlock(&mutex_btm);
|
||||
status |= (STATUS_RUN_BACKEND | STATUS_UPDATE_SCREEN_MASK | STATUS_RELOAD_DIRECTORY | STATUS_UPDATE_SCREEN_RELOAD_FULL);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user