moved code here. still needs to update gh

This commit is contained in:
klein panic
2025-02-24 15:18:44 -05:00
parent 9ca9f577a4
commit 2726432fe1
106 changed files with 4816 additions and 0 deletions

6
mpvd/include/audio.h Normal file
View File

@@ -0,0 +1,6 @@
#ifndef AUDIO_H
#define AUDIO_H
void play_audio(const char *file_path);
#endif

10
mpvd/include/dir.h Normal file
View File

@@ -0,0 +1,10 @@
#ifndef DIR_H
#define DIR_H
#define MAX_PATH_LEN 512 // Declare MAX_PATH_LEN for use across files
char* get_music_directory();
char** load_songs(int *count, const char *music_dir);
void navigate_directory(const char *dir, char **songs, int *song_count); // Declare navigate_directory
#endif

14
mpvd/include/ui.h Normal file
View File

@@ -0,0 +1,14 @@
#ifndef UI_H
#define UI_H
#include <ncurses.h>
void init_ncurses();
void end_ncurses();
void display_songs(WINDOW *win, char **songs, int song_count, int selected);
void display_controls(WINDOW *control_win, int is_playing);
// Update handle_input to accept current_directory
void handle_input(int ch, char **songs, int *selected_song, int *song_count, WINDOW *song_win, WINDOW *control_win, int *is_playing, char *current_directory);
#endif