2 * CDE - Common Desktop Environment
4 * Copyright (c) 1993-2012, The Open Group. All rights reserved.
6 * These libraries and programs are free software; you can
7 * redistribute them and/or modify them under the terms of the GNU
8 * Lesser General Public License as published by the Free Software
9 * Foundation; either version 2 of the License, or (at your option)
12 * These libraries and programs are distributed in the hope that
13 * they will be useful, but WITHOUT ANY WARRANTY; without even the
14 * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
15 * PURPOSE. See the GNU Lesser General Public License for more
18 * You should have received a copy of the GNU Lesser General Public
19 * License along with these librararies and programs; if not, write
20 * to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
21 * Floor, Boston, MA 02110-1301 USA
23 /* $XConsortium: DtDND.h /main/3 1995/11/06 09:40:32 rswiston $ */
25 * (c) Copyright 1993, 1994 Hewlett-Packard Company *
26 * (c) Copyright 1993, 1994 International Business Machines Corp. *
27 * (c) Copyright 1993, 1994 Sun Microsystems, Inc. *
28 * (c) Copyright 1993, 1994 Novell, Inc. *
47 typedef void (*DNDCallback) (BaseUI *, char **value, int *len, DNDProtocol);
51 friend void TransferCB(Widget, XtPointer, XtPointer);
52 friend void ConvertCB(Widget, XtPointer, XtPointer);
53 friend void DragFinishCB(Widget, XtPointer, XtPointer);
54 friend void DropOnRootCB(Widget, XtPointer, XtPointer);
55 friend void AnimateCB(Widget, XtPointer, XtPointer);
56 friend void DragMotionHandler(Widget, XtPointer, XEvent *, Boolean *);
58 static void TransferCB(Widget, XtPointer, XtPointer);
59 static void ConvertCB(Widget, XtPointer, XtPointer);
60 static void DragFinishCB(Widget, XtPointer, XtPointer);
61 static void DropOnRootCB(Widget, XtPointer, XtPointer);
62 static void AnimateCB(Widget, XtPointer, XtPointer);
63 static void DragMotionHandler(Widget, XtPointer, XEvent *, Boolean *);
67 static boolean FirstTime;
68 static boolean DoingDrag;
69 static XtCallbackRec transferCBRec[];
70 static XtCallbackRec convertCBRec[];
71 static XtCallbackRec dragFinishCBRec[];
72 static XtCallbackRec dropOnRootCBRec[];
73 static XtCallbackRec animateCBRec[];
88 unsigned char stringDirection;
89 Pixel textSelectColor;
92 unsigned char alignment;
93 Boolean showSelectedPixmap;
95 int string_border_width;
97 int p_w, p_h, s_w, s_h;
99 boolean can_drop_on_root;
103 void GetDragPixmaps();
105 void StartDrag(XEvent *);
109 DtDND(MotifUI *obj, DNDCallback dndCB, boolean can_drop_on_root = false);
111 void UpdateActivity(boolean);