[4] | 1 | /* $Id: dde_proc.h,v 1.1 1999-05-24 20:19:10 ktk Exp $ */
|
---|
| 2 |
|
---|
| 3 | /***************************************************************************
|
---|
| 4 | * Copyright 1995, Technion, Israel Institute of Technology
|
---|
| 5 | * Electrical Eng, Software Lab.
|
---|
| 6 | * Author: Michael Veksler.
|
---|
| 7 | ***************************************************************************
|
---|
| 8 | * File: dde_proc.h
|
---|
| 9 | * Purpose : DDE signals and processes functionality for DDE
|
---|
| 10 | ***************************************************************************
|
---|
| 11 | */
|
---|
| 12 | #ifndef __WINE_DDE_PROC_H
|
---|
| 13 | #define __WINE_DDE_PROC_H
|
---|
| 14 |
|
---|
| 15 | #ifdef CONFIG_IPC
|
---|
| 16 |
|
---|
| 17 | #include <setjmp.h>
|
---|
| 18 | #include "windef.h"
|
---|
| 19 | #include "windows.h"
|
---|
| 20 | #define DDE_PROCS 64
|
---|
| 21 | #define DDE_WINDOWS 64
|
---|
| 22 | struct _dde_proc {
|
---|
| 23 | int msg; /* message queue for this process */
|
---|
| 24 | int shmid; /* first shared memory block id. */
|
---|
| 25 | int sem; /* semaphore for fragment allocation */
|
---|
| 26 | int pid;
|
---|
| 27 | } ;
|
---|
| 28 | typedef struct _dde_proc *dde_proc;
|
---|
| 29 |
|
---|
| 30 | extern sigjmp_buf env_wait_x;
|
---|
| 31 | enum stop_wait_op { /* The action to be taken upon SIGUSR2 */
|
---|
| 32 | CONT, /* Don't do anything */
|
---|
| 33 | STOP_WAIT_ACK, /* Use siglongjmp to stop wait_ack() */
|
---|
| 34 | STOP_WAIT_X /* siglongjmp to stop MSG_WaitXEvent() */
|
---|
| 35 | };
|
---|
| 36 |
|
---|
| 37 | typedef struct {
|
---|
| 38 | WORD proc_idx; /* index into wine's process table */
|
---|
| 39 | HWND16 wnd; /* Window on the local proccess */
|
---|
| 40 | } WND_DATA;
|
---|
| 41 | extern enum stop_wait_op stop_wait_op;
|
---|
| 42 | extern int had_SIGUSR2;
|
---|
| 43 |
|
---|
| 44 | extern int curr_proc_idx;
|
---|
| 45 | void stop_wait(int a); /* signal handler for SIGUSR2
|
---|
| 46 | (interrupts "select" system call) */
|
---|
| 47 | void dde_proc_init(dde_proc proc); /* init proc array */
|
---|
| 48 | void dde_proc_done(dde_proc proc); /* delete a proc entry */
|
---|
| 49 | void dde_proc_refresh(dde_proc proc); /* delete entry, if old junk */
|
---|
| 50 | void dde_proc_add(dde_proc proc); /* Add current proc to proc array */
|
---|
| 51 | void dde_msg_setup(int *msg_ptr);
|
---|
| 52 | int dde_reschedule();
|
---|
| 53 | void dde_wnd_setup(); /* setup Data structure of DDE windows */
|
---|
| 54 |
|
---|
| 55 | /* Send ack. to hnd indicating that posted/sent msg. got to destination*/
|
---|
| 56 | void dde_proc_send_ack(HWND16 wnd, BOOL val);
|
---|
| 57 | BOOL DDE_PostMessage( MSG16 *msg);
|
---|
| 58 | BOOL DDE_SendMessage( MSG16 *msg);
|
---|
| 59 | int DDE_GetRemoteMessage();
|
---|
| 60 | void DDE_DestroyWindow(HWND16 hwnd); /* delete DDE info regarding hwnd */
|
---|
| 61 | void DDE_TestDDE(HWND16 hwnd); /* do we have dde handling in the window ?*/
|
---|
| 62 |
|
---|
| 63 | #endif /* CONFIG_IPC */
|
---|
| 64 |
|
---|
| 65 | #endif /* __WINE_DDE_PROC_H */
|
---|