home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
OS/2 Shareware BBS: 10 Tools
/
10-Tools.zip
/
zfamily.zip
/
zfamily
/
ZDTFUNCS
/
SAMPLE
/
DTEINF.H
< prev
next >
Wrap
Text File
|
1993-09-20
|
4KB
|
142 lines
/*
** /----------------------------------------------------------------------\
** | IBM Z Family Reusable Libraries/2 (5641-504) |
** |----------------------------------------------------------------------|
** | (C) Copyright International Business Machines Corporation 1993, 1994 |
** |----------------------------------------------------------------------|
** | DISCLAIMER OF WARRANTIES |
** | ------------------------ |
** | The following code is sample code created by IBM Corporation. |
** | Such a code is provided to you solely for the purpose of assisting |
** | you in the development of your applications. The code is provided |
** | "AS IS", without warranty of any kind. IBM shall not be liable for |
** | any damages arising out of your use of the following code, even if |
** | they have been advised of the possibility of such damages. | *
** \----------------------------------------------------------------------/
**
** Header : DTEINF.H
** Author : Dario de Judicibus (DEJUDICI at ROMEPPC)
** Created : 15 Jul 1992
** Updated : 01 Sep 1993
** Version : 4.12
** Content : Header file for the sample program for ZDTFUNCS.DLL functions
**
*/
#define INCL_PM
#define INCL_GPIBITMAPS
#include <os2.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <ctype.h>
#include <process.h>
#include <dteinf.rch>
#define WM_FAILEDVALIDATE (WM_USER+0)
/*
** Variables to support example code
*/
EXTERN ULONG hittest ;
EXTERN BOOL tf ;
EXTERN HWND hAWnd ;
EXTERN HWND hPtr ;
EXTERN HWND hMenu ;
EXTERN POINTL point ;
EXTERN PSWP swp ;
EXTERN PQMSG pQmsg ;
EXTERN POWNERITEM poi ;
EXTERN USHORT keycode ;
EXTERN USHORT charcode ;
EXTERN ULONG ControlID ;
EXTERN USHORT HelpCmd ;
EXTERN USHORT CmdSource ;
EXTERN USHORT SysCmd ;
EXTERN USHORT FirstValue ;
EXTERN USHORT LastValue ;
EXTERN LONG MenuID ;
EXTERN SHORT previous_width ;
EXTERN SHORT previous_height ;
EXTERN SHORT current_width ;
EXTERN SHORT current_height ;
/*
** These structures are used to add the program name to the task list
*/
EXTERN HSWITCH hSwitch ;
EXTERN SWCNTRL Swctl ;
EXTERN CHAR szAppName[20]; // Class name of application
EXTERN HAB hAB ; // Handle to the Anchor Block
EXTERN HMQ hMQ ; // Handle to the Message Queue
EXTERN HWND hWndFrame ; // Handle to the Window Frame
EXTERN HWND hWndClient ; // Handle to the Client Window
typedef _Packed struct
{
ULONG ChkDteDay ;
ULONG ChkDteMonth ;
ULONG ChkDteYear ;
ULONG ChkDteWeekOfYear ;
CHAR ChkDteWeekday[33] ;
CHAR ChkDteMonthName[33] ;
LONG ChkDteLeapYear ;
ULONG ChkDteDayInYear ;
ULONG ChkDteJulianDate ;
CHAR ChkDteLangTbl[32][4] ;
CHAR ChkDteLangId[5] ;
}
CHKDTEStruct ;
#define OFFSET_CHKDTE 0
typedef _Packed struct
{
ULONG TmeZonUCTHours ;
ULONG TmeZonUCTMinutes ;
ULONG TmeZonUCTSeconds ;
ULONG TmeZonLocalHours ;
ULONG TmeZonLocalMinutes ;
ULONG TmeZonLocalSeconds ;
ULONG TmeZonOffset ;
HPS hps ;
HBITMAP hbmp ;
BOOL fromField ;
BOOL fromSlider ;
}
TMEZONStruct ;
#define OFFSET_TMEZON 1*sizeof(char *)
/*
** Function prototypes
*/
VOID zzzDrawButtonBitmap ( HPS, HWND, HBITMAP, ULONG ) ;
USHORT tstCheckNumber ( PSZ, LONG *, LONG, LONG ) ;
INT cwCenter ( HWND, HWND ) ;
INT cwSetInitDlgStatus ( HWND ) ;
INT cwFreeDlgMemory ( HWND ) ;
INT cwRegisterClass ( VOID ) ;
HWND cwCreateWindow ( HWND, ULONG, PCH, PCH, ULONG, INT, INT, INT, INT, \
PHWND, ULONG, USHORT ) ;
MRESULT EXPENTRY UDDateWndProc ( HWND, ULONG, MPARAM, MPARAM ) ;
MRESULT EXPENTRY UDEditWndProc ( HWND, ULONG, MPARAM, MPARAM ) ;
#pragma linkage (WndProc, system)
MRESULT EXPENTRY WndProc ( HWND, ULONG, MPARAM, MPARAM ) ;
#pragma linkage (CHKDTEMsgProc, system)
MRESULT EXPENTRY CHKDTEMsgProc ( HWND, ULONG, MPARAM, MPARAM ) ;
#pragma linkage (TMEZONMsgProc, system)
MRESULT EXPENTRY TMEZONMsgProc ( HWND, ULONG, MPARAM, MPARAM ) ;