#ifndef _DESKTOP_H
#define _DESKTOP_H

#include <glib.h>

#define SCREEN_WIDTH 320
#define SCREEN_HEIGHT 480
#define TITLEBAR_HEIGHT 16
#define TASKBAR_HEIGHT 26
#define MENU_HEIGHT 24
#define LAUNCHER_HEIGHT TASKBAR_HEIGHT

// LAUNCHER_INPUT_HEIGHT is the height of nxhwr/nxkbd(ex_large)
// this value should match that of "NX_INPUT_HEIGHT" in "microwin/config.xxx"
// this value is used by "Application/Desktop/src/launcher.c"
#define LAUNCHER_INPUT_HEIGHT 131

// These definitions should be used by applications to determine the size of
// their application windows.
#define WINDOW_WIDTH SCREEN_WIDTH
#define WINDOW_HEIGHT (SCREEN_HEIGHT - TASKBAR_HEIGHT - TITLEBAR_HEIGHT)

gint desktop_get_folder_count();
gint desktop_get_program_count(gint folder_index);
void desktop_copy_folder(gint source_folder_index, gint target_folder_index);
void desktop_copy_program(gint folder_index, gint source_program_index, gint target_program_index);
gint desktop_new_folder(const gchar *name);
gint desktop_new_program(gint folder_index, const gchar *name);
void desktop_rename_folder(gint index, const gchar *name);
void desktop_delete_folder(gint index);
void desktop_delete_program(gint folder_index, gint program_index);
gint desktop_move_program(gint folder_index, gint program_index, gint new_folder_index);
void desktop_rename_program(gint folder_index, gint program_index, const gchar *long_name);

gint desktop_get_folder_index(const gchar *folder_name);
gint desktop_get_program_index(gint folder_index, const gchar *name);

gint desktop_install_program(const gchar *executable_name, const gchar *folder_name,
							 const gchar *display_name, const gchar *large_icon,
							 const gchar *small_icon);
gint desktop_uninstall_program(const gchar *executable_name);

GSList *desktop_get_hotkey_codes();
GSList *desktop_get_hotkey_programs(gchar code);
void desktop_set_hotkey_programs(gchar code, GSList *program_list);

#endif /* _DESKTOP_H */
