~ubuntu-branches/ubuntu/precise/grass/precise

« back to all changes in this revision

Viewing changes to imagery/i.ortho.photo/photo.2image/driver.c

  • Committer: Bazaar Package Importer
  • Author(s): Francesco Paolo Lovergine
  • Date: 2011-04-13 17:08:41 UTC
  • mfrom: (8.1.7 sid)
  • Revision ID: james.westby@ubuntu.com-20110413170841-ss1t9bic0d0uq0gz
Tags: 6.4.1-1
* New upstream version.
* Now build-dep on libjpeg-dev and current libreadline6-dev.
* Removed patch swig: obsolete.
* Policy bumped to 3.9.2, without changes.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
#include "globals.h"
2
 
 
3
 
static int use = 1;
4
 
static int really_quit(void);
5
 
static int dont_stop(void);
6
 
static int stop(void);
7
 
 
8
 
int driver(void)
9
 
{
10
 
    static Objects objects[] = {
11
 
        MENU("QUIT", really_quit, &use),
12
 
        MENU("ZOOM", zoom, &use),
13
 
        MENU("PLOT CELL", plotcell, &use),
14
 
        MENU("CAMERA", drawcam, &use),
15
 
        MENU("ANALYZE", analyze, &use),
16
 
        INFO("  Input method -> ", &use),
17
 
        OPTION("KEYBOARD", 2, &from_keyboard),
18
 
        OPTION("CAMERA FILE", 2, &from_screen),
19
 
        OTHER(mark, &use),
20
 
        {0}
21
 
    };
22
 
 
23
 
    Input_pointer(objects);
24
 
    Menu_msg("");
25
 
 
26
 
    return 0;
27
 
}
28
 
 
29
 
static int really_quit(void)
30
 
{
31
 
    static Objects objects[] = {
32
 
        INFO("really quit? ", &use),
33
 
        MENU("NO", dont_stop, &use),
34
 
        MENU("YES", stop, &use),
35
 
        {0}
36
 
    };
37
 
    if (Input_pointer(objects) < 0)
38
 
        return -1;
39
 
    return 0;                   /* don't quit */
40
 
}
41
 
 
42
 
static int dont_stop(void)
43
 
{
44
 
    return 1;
45
 
}
46
 
 
47
 
static int stop(void)
48
 
{
49
 
    return -1;
50
 
}