~pac72/ubuntu/lucid/ddd/devel

« back to all changes in this revision

Viewing changes to ddd/mmtest.C

  • Committer: Bazaar Package Importer
  • Author(s): Daniel Schepler
  • Date: 2004-07-22 03:49:37 UTC
  • mfrom: (1.2.1 upstream) (2.1.1 warty)
  • Revision ID: james.westby@ubuntu.com-20040722034937-cysl08t1jvba4jrx
Tags: 1:3.3.9-3
USERINFO has been renamed to USERINFO.txt; adjust debian/rules code
to match, to get correct information on the About DDD dialog.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
// $Id: mmtest.C,v 1.8 1999/08/19 11:28:44 andreas Exp $ -*- C++ -*-
2
 
//
3
 
 
4
 
// Copyright (C) 1996 Technische Universitaet Braunschweig, Germany.
5
 
// Written by Andreas Zeller <zeller@gnu.org>.
6
 
// 
7
 
// This file is part of DDD.
8
 
// 
9
 
// DDD is free software; you can redistribute it and/or
10
 
// modify it under the terms of the GNU General Public
11
 
// License as published by the Free Software Foundation; either
12
 
// version 2 of the License, or (at your option) any later version.
13
 
// 
14
 
// DDD is distributed in the hope that it will be useful,
15
 
// but WITHOUT ANY WARRANTY; without even the implied warranty of
16
 
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
17
 
// See the GNU General Public License for more details.
18
 
// 
19
 
// You should have received a copy of the GNU General Public
20
 
// License along with DDD -- see the file COPYING.
21
 
// If not, write to the Free Software Foundation, Inc.,
22
 
// 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
23
 
// 
24
 
// DDD is the data display debugger.
25
 
// For details, see the DDD World-Wide-Web page, 
26
 
// `http://www.gnu.org/software/ddd/',
27
 
// or send a mail to the DDD developers <ddd@gnu.org>.
28
 
 
29
 
char mmtest_rcsid[] = 
30
 
    "$Id: mmtest.C,v 1.8 1999/08/19 11:28:44 andreas Exp $";
31
 
 
32
 
#ifdef __GNUG__
33
 
#pragma implementation
34
 
#endif
35
 
 
36
 
#include <stdlib.h>
37
 
#include "MakeMenu.h"
38
 
 
39
 
#ifndef EXIT_SUCCESS
40
 
#define EXIT_SUCCESS 0
41
 
#endif
42
 
 
43
 
#ifndef EXIT_FAILURE
44
 
#define EXIT_FAILURE 1
45
 
#endif
46
 
 
47
 
static MMDesc type_menu[] =
48
 
{
49
 
    { "dbx", MMPush },
50
 
    { "gdb", MMPush },
51
 
    MMEnd
52
 
};
53
 
 
54
 
static MMDesc onoff_menu[] =
55
 
{
56
 
    { "on",  MMToggle },
57
 
    { "off", MMToggle },
58
 
    MMEnd
59
 
};
60
 
 
61
 
static MMDesc items[] = 
62
 
{
63
 
    { "groupIconify",        MMToggle },
64
 
    { "debuggerType",        MMOptionMenu, MMNoCB, type_menu },
65
 
    { "globalTabCompletion", MMToggle },
66
 
    { "suppressWarnings",    MMRadioPanel, MMNoCB, onoff_menu },
67
 
    { "saveHistoryOnExit",   MMToggle },
68
 
    MMEnd
69
 
};
70
 
 
71
 
int main(int argc, char *argv[])
72
 
{
73
 
    XtAppContext app_context;
74
 
 
75
 
    // Initialize it all
76
 
    Widget toplevel = XtAppInitialize(&app_context, "Mmtest",
77
 
        XtPointer(0), 0, &argc, argv, XtPointer(0), XtPointer(0), 0);
78
 
 
79
 
    Widget panel = MMcreatePanel(toplevel, "panel", items);
80
 
    MMadjustPanel(items);
81
 
    (void) panel;
82
 
 
83
 
    XtRealizeWidget(toplevel);
84
 
    XtAppMainLoop(app_context);
85
 
 
86
 
    return EXIT_SUCCESS;
87
 
}
88