~ubuntu-branches/ubuntu/wily/qgis/wily

« back to all changes in this revision

Viewing changes to src/plugins/evis/evis.h

  • Committer: Bazaar Package Importer
  • Author(s): Johan Van de Wauw
  • Date: 2010-07-11 20:23:24 UTC
  • mfrom: (3.1.4 squeeze)
  • Revision ID: james.westby@ubuntu.com-20100711202324-5ktghxa7hracohmr
Tags: 1.4.0+12730-3ubuntu1
* Merge from Debian unstable (LP: #540941).
* Fix compilation issues with QT 4.7
* Add build-depends on libqt4-webkit-dev 

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*
 
2
** File: evis.h
 
3
** Author: Peter J. Ersts ( ersts at amnh.org )
 
4
** Creation Date: 2007-03-06
 
5
**
 
6
** Copyright ( c ) 2007, American Museum of Natural History. All rights reserved.
 
7
**
 
8
** This library/program is free software; you can redistribute it
 
9
** and/or modify it under the terms of the GNU Library General Public
 
10
** License as published by the Free Software Foundation; either
 
11
** version 2 of the License, or ( at your option ) any later version.
 
12
**
 
13
** This library/program is distributed in the hope that it will be useful,
 
14
** but WITHOUT ANY WARRANTY; without even the implied warranty of
 
15
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 
16
** Library General Public License for more details.
 
17
**
 
18
** This work was made possible through a grant by the the John D. and
 
19
** Catherine T. MacArthur Foundation. Additionally, this program was prepared by
 
20
** the American Museum of Natural History under award No. NA05SEC46391002
 
21
** from the National Oceanic and Atmospheric Administration, U.S. Department
 
22
** of Commerce.  The statements, findings, conclusions, and recommendations
 
23
** are those of the author( s ) and do not necessarily reflect the views of the
 
24
** National Oceanic and Atmospheric Administration or the Department of Commerce.
 
25
**
 
26
**/
 
27
 
 
28
//This file was created using the plugin generator distributed with QGIS evis.h
 
29
//is based on and a modification of the default plugin.h file which carried the
 
30
//following header
 
31
/***************************************************************************
 
32
                          plugin.h
 
33
 Functions:
 
34
                             -------------------
 
35
    begin                : Jan 21, 2004
 
36
    copyright            : ( C ) 2004 by Tim Sutton
 
37
    email                : tim at linfiniti.com
 
38
 ***************************************************************************/
 
39
 
 
40
/***************************************************************************
 
41
 *                                                                         *
 
42
 *   This program is free software; you can redistribute it and/or modify  *
 
43
 *   it under the terms of the GNU General Public License as published by  *
 
44
 *   the Free Software Foundation; either version 2 of the License, or     *
 
45
 *   ( at your option ) any later version.                                   *
 
46
 *                                                                         *
 
47
 ***************************************************************************/
 
48
 
 
49
/***************************************************************************
 
50
 *   QGIS Programming conventions:
 
51
 *
 
52
 *   mVariableName - a class level member variable
 
53
 *   sVariableName - a static class level member variable
 
54
 *   variableName( ) - accessor for a class member ( no 'get' in front of name )
 
55
 *   setVariableName( ) - mutator for a class member ( prefix with 'set' )
 
56
 *
 
57
 *   Additional useful conventions:
 
58
 *
 
59
 *   theVariableName - a method parameter ( prefix with 'the' )
 
60
 *   myVariableName - a locally declared variable within a method ( 'my' prefix )
 
61
 *
 
62
 *   DO: Use mixed case variable names - myVariableName
 
63
 *   DON'T: separate variable names using underscores: my_variable_name ( NO! )
 
64
 *
 
65
 * **************************************************************************/
 
66
/*  $Id: $ */
 
67
#ifndef eVis_H
 
68
#define eVis_H
 
69
 
 
70
#include <QTemporaryFile>
 
71
 
 
72
#include <QObject>
 
73
 
 
74
#include <qgisplugin.h>
 
75
#include <qgisinterface.h>
 
76
 
 
77
//forward declarations
 
78
class QAction;
 
79
class QToolBar;
 
80
class eVisEventIdTool;
 
81
 
 
82
/**
 
83
* \class eVis
 
84
* \brief eVis plugin for QGIS
 
85
* This plugin allows for generic database connectivity and also provides a browser in which
 
86
* users can load and view photos referenced as attributes for a feature. The browser also
 
87
* has the ability to interact with the map canvas and display an arrow point in the direction
 
88
* in which a photograph was taken
 
89
*/
 
90
class eVis: public QObject, public QgisPlugin
 
91
{
 
92
    Q_OBJECT;
 
93
  public:
 
94
 
 
95
    //! Constructor
 
96
    eVis( QgisInterface * theInterface );
 
97
 
 
98
    //! Destructor */
 
99
    ~eVis( );
 
100
 
 
101
  public slots:
 
102
    //! init the gui
 
103
    virtual void initGui( );
 
104
 
 
105
    //! Main button actions
 
106
    void launchDatabaseConnection( );
 
107
    void launchEventIdTool( );
 
108
    void launchEventBrowser( );
 
109
 
 
110
    //! unload the plugin
 
111
    void unload( );
 
112
 
 
113
    //! show the help document
 
114
    void help( );
 
115
 
 
116
    //! Add a vector layer given vectorLayerPath, baseName, providerKey ( "ogr" or "postgres" );
 
117
    void drawVectorLayer( QString, QString, QString );
 
118
 
 
119
  private:
 
120
 
 
121
    QgisInterface *mQGisIface;
 
122
 
 
123
    QAction* mDatabaseConnectionActionPointer;
 
124
 
 
125
    QAction* mEventIdToolActionPointer;
 
126
 
 
127
    QAction* mEventBrowserActionPointer;
 
128
 
 
129
    eVisEventIdTool* mIdTool;
 
130
 
 
131
    //! List of pointers to temporary files, files are created by database queries */
 
132
    QList<QTemporaryFile*> mTemporaryFileList;
 
133
};
 
134
#endif //eVis_H