Skip to content

Commit

Permalink
Consolidate all QgsException subclasses in the same header
Browse files Browse the repository at this point in the history
  • Loading branch information
nyalldawson committed Jun 23, 2017
1 parent 4ea8536 commit cbc9e03
Show file tree
Hide file tree
Showing 75 changed files with 114 additions and 153 deletions.
2 changes: 1 addition & 1 deletion python/core/core.sip
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

%ModuleCode

#include "qgsprocessingexception.h"
#include "qgsexception.h"

QString getTraceback()
{
Expand Down
4 changes: 2 additions & 2 deletions python/core/qgsexception.sip
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
%Exception QgsCsException(SIP_Exception) /PyName=QgsCsException/
{
%TypeHeaderCode
#include <qgscsexception.h>
#include <qgsexception.h>
%End
%RaiseCode
SIP_BLOCK_THREADS
Expand All @@ -13,7 +13,7 @@
%Exception QgsProcessingException(SIP_Exception) /PyName=QgsProcessingException/
{
%TypeHeaderCode
#include <qgsprocessingexception.h>
#include <qgsexception.h>
%End
%RaiseCode
SIP_BLOCK_THREADS
Expand Down
2 changes: 1 addition & 1 deletion src/app/composer/qgscomposermapwidget.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
#include "qgsmapthemecollection.h"
#include "qgsmapthemes.h"
#include "qgsguiutils.h"
#include "qgscsexception.h"
#include "qgsexception.h"

#include <QMessageBox>

Expand Down
2 changes: 1 addition & 1 deletion src/app/gps/qgsgpsmarker.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
#include "qgsgpsmarker.h"
#include "qgscoordinatetransform.h"
#include "qgsmapcanvas.h"
#include "qgscsexception.h"
#include "qgsexception.h"

QgsGpsMarker::QgsGpsMarker( QgsMapCanvas *mapCanvas )
: QgsMapCanvasItem( mapCanvas )
Expand Down
2 changes: 1 addition & 1 deletion src/app/qgsdecorationlayoutextent.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
#include "qgscomposition.h"
#include "qgscomposermap.h"
#include "qgsgeometry.h"
#include "qgscsexception.h"
#include "qgsexception.h"
#include "qgslinesymbollayer.h"
#include "qgscomposer.h"
#include "qgisapp.h"
Expand Down
2 changes: 1 addition & 1 deletion src/app/qgsdecorationnortharrow.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ email : tim@linfiniti.com
#include "qgisapp.h"
#include "qgsbearingutils.h"
#include "qgscoordinatetransform.h"
#include "qgscsexception.h"
#include "qgsexception.h"
#include "qgslogger.h"
#include "qgsmaplayer.h"
#include "qgsproject.h"
Expand Down
2 changes: 1 addition & 1 deletion src/app/qgsmapcanvasdockwidget.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
***************************************************************************/
#include "qgsmapcanvasdockwidget.h"
#include "qgsmapcanvas.h"
#include "qgscsexception.h"
#include "qgsexception.h"
#include "qgsprojectionselectiondialog.h"
#include "qgsscalecombobox.h"
#include "qgsdoublespinbox.h"
Expand Down
2 changes: 1 addition & 1 deletion src/app/qgsmaptooladdfeature.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
#include "qgsmaptooladdfeature.h"
#include "qgsapplication.h"
#include "qgsattributedialog.h"
#include "qgscsexception.h"
#include "qgsexception.h"
#include "qgscurvepolygon.h"
#include "qgsfields.h"
#include "qgsgeometry.h"
Expand Down
2 changes: 1 addition & 1 deletion src/app/qgsmaptoolannotation.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
#include "qgssvgannotationdialog.h"
#include "qgssvgannotation.h"
#include "qgsproject.h"
#include "qgscsexception.h"
#include "qgsexception.h"
#include "qgsannotationmanager.h"
#include <QDialog>
#include <QMouseEvent>
Expand Down
2 changes: 1 addition & 1 deletion src/app/qgsmaptoolfeatureaction.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
#include "qgsmessageviewer.h"
#include "qgsactionmanager.h"
#include "qgscoordinatereferencesystem.h"
#include "qgscsexception.h"
#include "qgsexception.h"
#include "qgsvectordataprovider.h"
#include "qgsvectorlayer.h"
#include "qgsproject.h"
Expand Down
2 changes: 1 addition & 1 deletion src/app/qgsmaptoolselectutils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ email : jpalmer at linz dot govt dot nz
#include "qgsgeometry.h"
#include "qgsrenderer.h"
#include "qgsrubberband.h"
#include "qgscsexception.h"
#include "qgsexception.h"
#include "qgslogger.h"
#include "qgis.h"

Expand Down
2 changes: 1 addition & 1 deletion src/app/qgsmaptoolshowhidelabels.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
#include "qgsmaptoolshowhidelabels.h"

#include "qgsapplication.h"
#include "qgscsexception.h"
#include "qgsexception.h"
#include "qgsfeatureiterator.h"
#include "qgsmapcanvas.h"
#include "qgsvectorlayer.h"
Expand Down
2 changes: 1 addition & 1 deletion src/app/qgsmeasuretool.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
#include "qgsvectorlayer.h"
#include "qgssnappingutils.h"
#include "qgstolerance.h"
#include "qgscsexception.h"
#include "qgsexception.h"
#include "qgsmeasuredialog.h"
#include "qgsmeasuretool.h"
#include "qgscursors.h"
Expand Down
2 changes: 0 additions & 2 deletions src/core/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -738,7 +738,6 @@ SET(QGIS_CORE_HDRS
qgscoordinatetransform.h
qgscoordinateutils.h
qgscrscache.h
qgscsexception.h
qgsdartmeasurement.h
qgsdatadefinedsizelegend.h
qgsdataitem.h
Expand Down Expand Up @@ -899,7 +898,6 @@ SET(QGIS_CORE_HDRS
processing/qgsnativealgorithms.h
processing/qgsprocessingalgorithm.h
processing/qgsprocessingcontext.h
processing/qgsprocessingexception.h
processing/qgsprocessingmodelalgorithm.h
processing/qgsprocessingoutputs.h
processing/qgsprocessingparameters.h
Expand Down
2 changes: 1 addition & 1 deletion src/core/composer/qgscomposerattributetablev2.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
#include "qgsproject.h"
#include "qgsrelationmanager.h"
#include "qgsgeometry.h"
#include "qgscsexception.h"
#include "qgsexception.h"
#include "qgsmapsettings.h"

//QgsComposerAttributeTableCompareV2
Expand Down
2 changes: 1 addition & 1 deletion src/core/composer/qgscomposermapgrid.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
#include "qgslogger.h"
#include "qgsfontutils.h"
#include "qgsexpressioncontext.h"
#include "qgscsexception.h"
#include "qgsexception.h"
#include "qgssettings.h"

#include <QPainter>
Expand Down
2 changes: 1 addition & 1 deletion src/core/composer/qgscomposermapoverview.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
#include "qgspathresolver.h"
#include "qgsreadwritecontext.h"
#include "qgscomposerutils.h"
#include "qgscsexception.h"
#include "qgsexception.h"

#include <QPainter>

Expand Down
2 changes: 1 addition & 1 deletion src/core/expression/qgsexpressionfunction.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
#include "qgsexpressionsorter.h"
#include "qgssymbollayerutils.h"
#include "qgsstyle.h"
#include "qgscsexception.h"
#include "qgsexception.h"
#include "qgsmessagelog.h"
#include "qgsrasterlayer.h"
#include "qgsvectorlayer.h"
Expand Down
2 changes: 1 addition & 1 deletion src/core/processing/qgsprocessingalgorithm.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
#include "qgsrectangle.h"
#include "qgsprocessingcontext.h"
#include "qgsprocessingutils.h"
#include "qgsprocessingexception.h"
#include "qgsexception.h"
#include "qgsmessagelog.h"
#include "qgsprocessingfeedback.h"

Expand Down
2 changes: 1 addition & 1 deletion src/core/processing/qgsprocessingcontext.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
#include "qgsexpressioncontext.h"
#include "qgsfeaturerequest.h"
#include "qgsmaplayerlistutils.h"
#include "qgsprocessingexception.h"
#include "qgsexception.h"

/**
* \class QgsProcessingContext
Expand Down
40 changes: 0 additions & 40 deletions src/core/processing/qgsprocessingexception.h

This file was deleted.

2 changes: 1 addition & 1 deletion src/core/processing/qgsprocessingmodelalgorithm.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
#include "qgsprocessingregistry.h"
#include "qgsprocessingfeedback.h"
#include "qgsxmlutils.h"
#include "qgsprocessingexception.h"
#include "qgsexception.h"
#include <QFile>
#include <QTextStream>

Expand Down
2 changes: 1 addition & 1 deletion src/core/processing/qgsprocessingutils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
#include "qgsprocessingutils.h"
#include "qgsproject.h"
#include "qgssettings.h"
#include "qgscsexception.h"
#include "qgsexception.h"
#include "qgsprocessingcontext.h"
#include "qgsvectorlayerexporter.h"
#include "qgsvectorfilewriter.h"
Expand Down
2 changes: 1 addition & 1 deletion src/core/providers/memory/qgsmemoryfeatureiterator.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
#include "qgsspatialindex.h"
#include "qgsmessagelog.h"
#include "qgsproject.h"
#include "qgscsexception.h"
#include "qgsexception.h"

///@cond PRIVATE

Expand Down
2 changes: 1 addition & 1 deletion src/core/qgscachedfeatureiterator.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@

#include "qgscachedfeatureiterator.h"
#include "qgsvectorlayercache.h"
#include "qgscsexception.h"
#include "qgsexception.h"

QgsCachedFeatureIterator::QgsCachedFeatureIterator( QgsVectorLayerCache *vlCache, const QgsFeatureRequest &featureRequest )
: QgsAbstractFeatureIterator( featureRequest )
Expand Down
2 changes: 1 addition & 1 deletion src/core/qgscoordinatetransform.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
#include "qgslogger.h"
#include "qgspointxy.h"
#include "qgsrectangle.h"
#include "qgscsexception.h"
#include "qgsexception.h"

//qt includes
#include <QDomNode>
Expand Down
2 changes: 1 addition & 1 deletion src/core/qgscoordinateutils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
#include "qgscoordinatetransform.h"
#include "qgsproject.h"
#include "qgis.h"
#include "qgscsexception.h"
#include "qgsexception.h"

///@cond NOT_STABLE_API

Expand Down
32 changes: 0 additions & 32 deletions src/core/qgscsexception.h

This file was deleted.

2 changes: 1 addition & 1 deletion src/core/qgsdistancearea.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
#include "qgspolygon.h"
#include "qgssurface.h"
#include "qgsunittypes.h"
#include "qgscsexception.h"
#include "qgsexception.h"

// MSVC compiler doesn't have defined M_PI in math.h
#ifndef M_PI
Expand Down
Loading

0 comments on commit cbc9e03

Please sign in to comment.