1 /** 2 * 3 * $Id: ProtocolsP.h,v 1.1 2004/08/28 19:23:25 dannybackx Exp $ 4 * 5 * Copyright (C) 1995 Free Software Foundation, Inc. 6 * Copyright (C) 1995-2000 LessTif Development Team 7 * 8 * This file is part of the GNU LessTif Library. 9 * 10 * This library is free software; you can redistribute it and/or 11 * modify it under the terms of the GNU Library General Public 12 * License as published by the Free Software Foundation; either 13 * version 2 of the License, or (at your option) any later version. 14 * 15 * This library is distributed in the hope that it will be useful, 16 * but WITHOUT ANY WARRANTY; without even the implied warranty of 17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 18 * Library General Public License for more details. 19 * 20 * You should have received a copy of the GNU Library General Public 21 * License along with this library; if not, write to the Free 22 * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 23 * 24 **/ 25 #ifndef _XM_PROTOCOLS_P_H 26 #define _XM_PROTOCOLS_P_H 27 28 #include <Xm/Protocols.h> 29 #include <Xm/ExtObjectP.h> 30 31 #ifdef __cplusplus 32 extern "C" { 33 #endif 34 35 #ifndef XmIsProtocol 36 #define XmIsProtocol(w) XtIsSubclass(w, xmProtocolObjectClass) 37 #endif 38 39 typedef struct _XmProtocolClassPart { 40 XtPointer extension; 41 } XmProtocolClassPart; 42 43 typedef struct _XmProtocolClassRec { 44 ObjectClassPart object_class; 45 XmExtClassPart ext_class; 46 XmProtocolClassPart protocol_class; 47 } XmProtocolClassRec, *XmProtocolObjectClass; 48 49 typedef struct _XmProtocolPart { 50 XtCallbackRec pre_hook, post_hook; 51 XtCallbackList callbacks; 52 Atom atom; 53 Boolean active; 54 } XmProtocolPart, *XmProtocolPartPtr; 55 56 typedef struct _XmProtocolRec { 57 ObjectPart object; 58 XmExtPart ext; 59 XmProtocolPart protocol; 60 } XmProtocolRec, *XmProtocol, **XmProtocolList; 61 62 XMLIBEXPORT extern XmProtocolClassRec xmProtocolClassRec; 63 XMLIBEXPORT extern WidgetClass xmProtocolObjectClass; 64 65 typedef struct _XmProtocolMgrRec { 66 Atom property; 67 XmProtocolList protocols; 68 Cardinal num_protocols; 69 Cardinal max_protocols; 70 } XmProtocolMgrRec, *XmProtocolMgr, **XmProtocolMgrList; 71 72 typedef struct _XmAllProtocolsMgrRec { 73 XmProtocolMgrList protocol_mgrs; 74 Cardinal num_protocol_mgrs; 75 Cardinal max_protocol_mgrs; 76 Widget shell; 77 } XmAllProtocolsMgrRec, *XmAllProtocolsMgr; 78 79 XMLIBEXPORT extern void _XmInstallProtocols(Widget w); 80 81 #ifdef __cplusplus 82 } 83 #endif 84 85 #endif /* _XM_PROTOCOLSP_H */ 86