~ubuntu-branches/ubuntu/quantal/qgis/quantal

« back to all changes in this revision

Viewing changes to plugins/grass/qgsgrassselect.h

  • Committer: Bazaar Package Importer
  • Author(s): Steve Halasz
  • Date: 2004-12-21 09:46:27 UTC
  • Revision ID: james.westby@ubuntu.com-20041221094627-r9lb6mlz2o3yp8gn
Tags: upstream-0.6.0
ImportĀ upstreamĀ versionĀ 0.6.0

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/***************************************************************************
 
2
    qgsgrassselect.h  -  Select GRASS layer dialog
 
3
                             -------------------
 
4
    begin                : March, 2004
 
5
    copyright            : (C) 2004 by Radim Blazek
 
6
    email                : blazek@itc.it
 
7
 ***************************************************************************/
 
8
/***************************************************************************
 
9
 *                                                                         *
 
10
 *   This program is free software; you can redistribute it and/or modify  *
 
11
 *   it under the terms of the GNU General Public License as published by  *
 
12
 *   the Free Software Foundation; either version 2 of the License, or     *
 
13
 *   (at your option) any later version.                                   *
 
14
 *                                                                         *
 
15
 ***************************************************************************/
 
16
#ifndef QGSGRASSSELECT_H
 
17
#define QGSGRASSSELECT_H
 
18
#include "qgsgrassselectbase.h"
 
19
/*! \class QgsGrassSelect
 
20
 * \brief Dialog to select GRASS layer.
 
21
 *
 
22
 */
 
23
class QgsGrassSelect: public QgsGrassSelectBase
 
24
{
 
25
public:
 
26
    //! Constructor
 
27
    //QgsGrassSelect(QWidget *parent = 0, int type = VECTOR );
 
28
    QgsGrassSelect(int type = VECTOR );
 
29
    //! Destructor
 
30
    ~QgsGrassSelect();
 
31
 
 
32
    enum TYPE { VECTOR, RASTER, GROUP }; // GROUP = group of rasters, used in selectedType
 
33
 
 
34
    //! OK 
 
35
    void accept (void);
 
36
 
 
37
    //! Cancel
 
38
    void reject (void);
 
39
    
 
40
    //! Open dialog for Gisdbase
 
41
    void getGisdbase(void);
 
42
 
 
43
    //! Reset combobox of locations for current Gisdbase
 
44
    void setLocations (void );
 
45
    
 
46
    //! Reset combobox of mapsets for current Location
 
47
    void setMapsets (void );
 
48
 
 
49
    //! Reset combobox of maps for current Gisdbase + Location
 
50
    void setMaps (void );
 
51
 
 
52
    //! Reset combobox of layers for current Gisdbase + Location + Map
 
53
    void setLayers (void );
 
54
 
 
55
    QString  gisdbase;
 
56
    QString  location;
 
57
    QString  mapset;
 
58
    QString  map;
 
59
    QString  layer;
 
60
    int      selectedType;  // RASTER or GROUP
 
61
 
 
62
private:
 
63
    int type; // map type (mapset element)
 
64
    static bool first; // called first time
 
65
    static QString lastGisdbase; // Last selected values
 
66
    static QString lastLocation;
 
67
    static QString lastMapset;
 
68
    static QString lastVectorMap;
 
69
    static QString lastRasterMap;
 
70
    static QString lastLayer; // vector layer
 
71
 
 
72
    void restorePosition(void);
 
73
    void saveWindowLocation(void);
 
74
};
 
75
 
 
76
 
 
77
#endif // QGSGRASSSELECT_H