
/*
 * Header.h -- for Black Hole. Contains general includes and defines all in
 * one lump so I can precompile it.
 * $Revision: 1.2
 */

#include <workbench/startup.h>
#include <workbench/workbench.h>
#include <dos/dos.h>
#include <dos/dosasl.h>
#include <dos/exall.h>
#include <dos/dosextens.h>
#include <exec/lists.h>
#include <libraries/gadtools.h>
#include <graphics/view.h>
#include <graphics/gfxmacros.h>

#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <ctype.h>

#include <clib/gadtools_protos.h>
#include <clib/graphics_protos.h>
#include <clib/intuition_protos.h>
#include <clib/exec_protos.h>
#include <clib/alib_protos.h>
#include <clib/icon_protos.h>
#include <clib/wb_protos.h>
#include <clib/dos_protos.h>

#define Local static
#define Prototype extern

/* Niceness */
#define unless(x) if (!(x))
#define until(x) while (!(x))
#define repeat do

/* defines for set_current */
#define SET_NEWFILE 1
#define SET_START 2
#define SET_EXIT_DIR 3

/* defines for gadgets */
#define GAD_QUIT    1
#define GAD_ABOUT   2
#define GAD_LIMIT   3
#define GAD_CONFIRM 4
#define GAD_IGNORE  5
#define GAD_UNSNAP  6
#define GAD_SNAP    7
#define GAD_SAVE    8
#define GAD_USE     9
#define GAD_CANCEL  10

/* Structure to hold preferences */
struct HolePrefs
{
    BOOL ignore_prot;
    BOOL confirm;
    ULONG deletelimit;
    LONG CurrentX;
    LONG CurrentY;
};

/* Structure used to hold files waiting for deletion */
struct HoleArg
{
    struct Node node;
    struct WBArg wbarg;
    char *truncname;	    /* truncated name for confirmation */
    struct HolePrefs prefs; /* prefs at the time that icon is dropped on appicon */
};

/* Structure holding everything you ever wanted to know about the control panel */
struct HolePanel
{
    struct Window *window;
    struct HolePrefs prefs; /* Preferences according to current gadget selections */
    /* Next 3 fields are the gadgets that have to be read. */
    struct Gadget *gad_ignore_prot; /* Ignore protection gadget's address */
    struct Gadget *gad_confirm;     /* ditto for confirm gadget. */
    struct Gadget *gad_limit;	    /* ditto for delete limit */
};

