OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-old/] [gcc-4.2.2/] [gcc/] [testsuite/] [gcc.c-torture/] [compile/] [980816-1.c] - Blame information for rev 832

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 149 jeremybenn
typedef unsigned int size_t;
2
typedef void *XtPointer;
3
 
4
typedef struct _WidgetRec *Widget;
5
typedef struct _WidgetClassRec *WidgetClass;
6
 
7
extern WidgetClass commandWidgetClass;
8
 
9
typedef void (*XtCallbackProc)(
10
    Widget               ,
11
    XtPointer            ,
12
    XtPointer
13
);
14
 
15
extern const  char XtStrings[];
16
 
17
 
18
typedef struct
19
{
20
        char                    *Name,
21
                                *Label;
22
        XtCallbackProc          Callback;
23
        XtPointer               ClientData;
24
        Widget                  W;
25
} DialogButtonType, *DialogButtonTypePtr;
26
 
27
 
28
Widget AddButtons(Widget Parent, Widget Top,
29
        DialogButtonTypePtr Buttons, size_t Count)
30
{
31
        int             i;
32
 
33
        for (i = 0; i < Count; i++)
34
        {
35
                if (!Buttons[i].Label)
36
                        continue;
37
                Buttons[i].W  = XtVaCreateManagedWidget(Buttons[i].Name,
38
                        commandWidgetClass,
39
                        Parent,
40
                        ((char*)&XtStrings[429]) , Buttons[i].Label,
41
                        "fromHoriz" , i ? Buttons[i-1].W : ((void *)0) ,
42
                        "fromVert" , Top,
43
                        "resizable" , 1 ,
44
                        ((void *)0) );
45
 
46
                XtAddCallback(((char*)&XtStrings[136]),
47
                                 Buttons[i].Callback, Buttons[i].ClientData);
48
        }
49
        return(Buttons[Count-1].W);
50
}
51
 

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.