/*
 * DWN - Desktop Window Manager
 * retoor <retoor@molodetz.nl>
 * Application launcher with .desktop file support
 */

#ifndef DWN_APPLAUNCHER_H
#define DWN_APPLAUNCHER_H

#include <stdbool.h>

#define MAX_APPS 512
#define MAX_RECENT_APPS 10

typedef struct {
    char name[128];
    char exec[512];
    char icon[128];
    char desktop_id[256];
    bool terminal;
    bool hidden;
} AppEntry;

typedef struct {
    AppEntry apps[MAX_APPS];
    int app_count;
    char recent[MAX_RECENT_APPS][256];
    int recent_count;
} AppLauncherState;

void applauncher_init(void);

void applauncher_cleanup(void);

void applauncher_refresh(void);

void applauncher_show(void);

void applauncher_launch(const char *desktop_id);

#endif
