File:  [OS/2 SDKs] / os232sdk / toolkt20 / c / samples / template / main.h
Revision 1.1.1.1 (vendor branch): download - view: text, annotated - select for diffs
Thu Aug 9 12:26:31 2018 UTC (7 years, 9 months ago) by root
Branches: msft, MAIN
CVS tags: os2sdk-1990, HEAD
Microsoft OS/2 SDK 2.0 05-30-1990

/*==============================================================*\
 *
 *  Main.h - Sample PM application main header file
 *      Created 1989, 1990 Microsoft Corp.
 *
 *--------------------------------------------------------------
 *
 *  This header file contains the application wide constants
 *  and structure definitions.
 *
\*==============================================================*/

#define IDR_MAIN       1      /* resource identifier */

/*--------------------------------------------------------------*\
 *  Standard Dialog box ids
\*--------------------------------------------------------------*/
#define FILEOPEN        2000
#define FILESAVE        2001

#define MSGBOXID        1001
#define OBJECTID        1002


/*--------------------------------------------------------------*\
 *  Menu item ids
\*--------------------------------------------------------------*/
#define IDM_FILE                            1000
#define IDM_FILENEW                         1100
#define IDM_FILEOPEN                        1200
#define IDM_FILESAVE                        1300
#define IDM_FILESAVEAS                      1400
#define IDM_FILEPRINT                       1500
#define IDM_FILEPAGESETUP                   1600
#define IDM_FILEPRINTSETUP                  1700
#define IDM_FILEEXIT                        1800

#define IDM_EDIT                            2000
#define IDM_EDITUNDO                        2100
#define IDM_EDITCUT                         2200
#define IDM_EDITCOPY                        2300
#define IDM_EDITPASTE                       2400
#define IDM_EDITCLEAR                       2500

#define IDM_HELP                            9000
#define IDM_HELPHELPFORHELP                 9100
#define IDM_HELPEXTENDED                    9200
#define IDM_HELPKEYS                        9300
#define IDM_HELPINDEX                       9400
#define IDM_HELPTUTORIAL                    9500
#define IDM_HELPABOUT                       9600

/*--------------------------------------------------------------*\
 *  Dialog item ids
\*--------------------------------------------------------------*/
#define ID_OK               1
#define ID_CANCEL           2

/*--------------------------------------------------------------*\
 *  Stringtable ids
\*--------------------------------------------------------------*/
#define IDS_FILEOPENEXT             1
#define IDS_APPNAME                 2
#define IDS_HELPLIBRARYNAME         3
#define IDS_OPENDLGTITLE            4
#define IDS_OPENDLGBUTTON           5
#define IDS_HELPWINDOWTITLE         6
#define IDS_SAVEDLGTITLE            7
#define IDS_SAVEDLGBUTTON           8
#define IDS_UNTITLED                9
#define IDS_TITLEBARSEPARATOR      10
#define IDS_PRINTSETUPTITLE        11
#define IDS_PAGESETUPTITLE         12
#define IDS_PRINTTITLE             13
#define IDS_OBJECTCLASS            14

/*--------------------------------------------------------------*\
 *  Messagetable ids
\*--------------------------------------------------------------*/
#define IDMSG_INITFAILED                1
#define IDMSG_MAINWINCREATEFAILED       2
#define IDMSG_CANNOTOPENINPUTFILE       3
#define IDMSG_CANNOTOPENOUTPUTFILE      4
#define IDMSG_CANNOTRUNPAGESETUP        5
#define IDMSG_CANNOTRUNPRINTSETUP       6
#define IDMSG_CANNOTRUNPRINT            7
#define IDMSG_CANNOTRUNCOLOR            8
#define IDMSG_CANNOTGETHPS              9
#define IDMSG_HELPLOADERROR            10
#define IDMSG_CANNOTLOADSTRING         11
#define IDMSG_CANNOTOPENPRINTER        12
#define IDMSG_HELPDISPLAYERROR         13
#define IDMSG_CANNOTLOADEXITLIST       14
#define IDMSG_PRINTINITFAILED          15
#define IDMSG_OVERWRITEFILE            16
#define IDMSG_PRINTERROR               17
#define IDMSG_UNDOFAILED               18
#define IDMSG_CANNOTGETFILEINFO        19
#define IDMSG_CANNOTALLOCATEMEMORY     20
#define IDMSG_CANNOTREADFILE           21
#define IDMSG_CANNOTWRITETOFILE        22
#define IDMSG_CANNOTLOADFONTS          23
#define IDMSG_CANNOTGETPAGEINFO        24

/*--------------------------------------------------------------*\
 *  Ids of messages used between threads
\*--------------------------------------------------------------*/
#define TM_THREADINITFAILED         WM_USER+300


/*--------------------------------------------------------------*\
 *  Other constants
\*--------------------------------------------------------------*/
#define MESSAGELEN          50    /* maximum length for messages */
#define TITLESEPARATORLEN   4

/* return values for initialization routines */
#define RETURN_SUCCESS      0   /* successful return in DosExit */
#define RETURN_ERROR        1   /* error return in DosExit */
#define BEEP_WARN_FREQ      60  /* frequency of warning beep */
#define BEEP_WARN_DUR      100  /* duration of warning beep */



/* ----------------------------------------------------------------
 * Included in the sample template is code for that creates a
 *  second thread that can be used for background processing.
 *  To use this thread, enable the BACKGROUND_THREAD constant.
 *  This will enable the routines that create and destroy the
 *  background processing thread.  The routines for the thread
 *  itself are located in the thrd.c file.
 * ----------------------------------------------------------------*/

/*
#define BACKGROUND_THREAD
*/

#define BACKGROUND_THREAD

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.