/
qgsproviderextentcalcevent.h
58 lines (40 loc) · 2.05 KB
/
qgsproviderextentcalcevent.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
/***************************************************************************
qgsproviderextentcalcevent.h - Notification that the exact extent
of a layer has been calculated.
-------------------
begin : Feb 1, 2005
copyright : (C) 2005 by Brendan Morley
email : morb at ozemail dot com dot au
***************************************************************************/
/***************************************************************************
* *
* This program is free software; you can redistribute it and/or modify *
* it under the terms of the GNU General Public License as published by *
* the Free Software Foundation; either version 2 of the License, or *
* (at your option) any later version. *
* *
***************************************************************************/
#ifndef QGSPROVIDEREXTENTCALCEVENT_H
#define QGSPROVIDEREXTENTCALCEVENT_H
#include <QEvent>
class QgsRectangle;
/** \ingroup core
* A custom event that is designed to be fired when a layer extent has been fully calculated.
\author Brendan Morley
\date March 2005
This custom QEvent is designed to be fired when the full extent of a layer has been calculated.
It was initially included in QGIS to help the QgsPostgresProvider provide the asynchronous
calculation of PostgreSQL layer extents.
Events are used instead of Qt signals/slots as events can be received asynchronously,
which makes for better mutlithreading behaviour and less opportunity for programmer mishap.
*/
// TODO: Add the pg table this is a extent OF.
class CORE_EXPORT QgsProviderExtentCalcEvent : public QEvent
{
public:
QgsProviderExtentCalcEvent( QgsRectangle* layerExtent );
QgsRectangle* layerExtent() const;
private:
QgsRectangle* le;
};
#endif