Skip to content
Permalink
Browse files

Remove include "qgsapplication.h" from qgswkbptr.h

qgswkbptr.h is included indirectly by a large number of source files.
So this commit does the following:
  - remove #include "qgsapplication.h" from qgswkbptr.h, and copy-paste the swap_endian
    function where it's used.
  - add the missing #include "qgsapplication.h" in other files

The rationale for this change is:
  - qgswkbptr.h doesn't really needs QgsApplication, since it only used swap_endian.
    We don't need to add a fake dependency on QgsApplication on every (indirect) "includers"
    of qgswkbptr.h
 - qgsapplication.h depends on qgsconfig.h which itself changes quite often (on every git op
   at least). Before this change, a 'git commit' would trigger a rebuild of about 3500 files.
   With this change we're down to ~700.
  • Loading branch information
peppsac committed Jan 22, 2019
1 parent 1cd7bde commit f1760ee56b8bdd1564b48626595f768c0911b604
Showing with 142 additions and 23 deletions.
  1. +1 −0 python/core/auto_generated/geometry/qgsabstractgeometry.sip.in
  2. +1 −0 python/core/auto_generated/geometry/qgswkbptr.sip.in
  3. +1 −0 python/core/auto_generated/qgsabstractcontentcache.sip.in
  4. +0 −1 python/core/auto_generated/qgsapplication.sip.in
  5. +1 −0 src/analysis/processing/qgsalgorithmbuffer.h
  6. +1 −0 src/analysis/processing/qgsalgorithmcentroid.h
  7. +1 −0 src/analysis/processing/qgsalgorithmclip.h
  8. +1 −0 src/analysis/processing/qgsalgorithmconvexhull.h
  9. +1 −0 src/analysis/processing/qgsalgorithmdifference.h
  10. +1 −0 src/analysis/processing/qgsalgorithmdissolve.h
  11. +1 −0 src/analysis/processing/qgsalgorithmextractbylocation.h
  12. +1 −0 src/analysis/processing/qgsalgorithmextractvertices.h
  13. +1 −0 src/analysis/processing/qgsalgorithmintersection.h
  14. +1 −0 src/analysis/processing/qgsalgorithmlineintersection.h
  15. +1 −0 src/analysis/processing/qgsalgorithmloadlayer.h
  16. +1 −0 src/analysis/processing/qgsalgorithmmeancoordinates.h
  17. +1 −0 src/analysis/processing/qgsalgorithmmergevector.h
  18. +1 −0 src/analysis/processing/qgsalgorithmmultiparttosinglepart.h
  19. +1 −0 src/analysis/processing/qgsalgorithmnetworkanalysisbase.h
  20. +1 −0 src/analysis/processing/qgsalgorithmpointonsurface.h
  21. +1 −0 src/analysis/processing/qgsalgorithmpromotetomultipart.h
  22. +1 −0 src/analysis/processing/qgsalgorithmsimplify.h
  23. +1 −0 src/analysis/processing/qgsalgorithmsymmetricaldifference.h
  24. +1 −0 src/analysis/processing/qgsalgorithmunion.h
  25. +1 −0 src/app/3d/qgs3dmapcanvasdockwidget.cpp
  26. +1 −0 src/app/3d/qgslightswidget.cpp
  27. +1 −0 src/app/3d/qgsrulebased3drendererwidget.cpp
  28. +1 −0 src/app/3d/qgsvectorlayer3drendererwidget.cpp
  29. +1 −0 src/app/browser/qgsinbuiltdataitemproviders.cpp
  30. +1 −0 src/app/qgisapp.h
  31. +1 −0 src/app/qgsattributesformproperties.cpp
  32. +1 −0 src/app/qgsattributetypedialog.cpp
  33. +1 −0 src/app/qgsclipboard.cpp
  34. +1 −0 src/app/qgsgeometryvalidationdock.cpp
  35. +1 −0 src/app/qgsgeometryvalidationmodel.cpp
  36. +1 −0 src/app/qgshandlebadlayers.cpp
  37. +1 −0 src/app/qgslayertreeviewembeddedindicator.cpp
  38. +1 −0 src/app/qgslayertreeviewindicatorprovider.cpp
  39. +1 −0 src/app/qgsmapcanvasdockwidget.cpp
  40. +1 −0 src/app/qgsmaplayerstylecategoriesmodel.cpp
  41. +1 −0 src/app/qgsmapsavedialog.cpp
  42. +1 −0 src/app/qgsmaptoolselect.cpp
  43. +1 −1 src/app/qgssnappinglayertreemodel.cpp
  44. +1 −0 src/app/qgssourcefieldsproperties.cpp
  45. +1 −0 src/app/qgsstatisticalsummarydockwidget.cpp
  46. +1 −0 src/core/annotations/qgsannotationmanager.cpp
  47. +1 −0 src/core/effects/qgseffectstack.cpp
  48. +1 −0 src/core/effects/qgspainteffectregistry.cpp
  49. +1 −0 src/core/expression/qgsexpressionfunction.cpp
  50. +1 −0 src/core/fieldformatter/qgsdatetimefieldformatter.cpp
  51. +1 −0 src/core/fieldformatter/qgsrangefieldformatter.cpp
  52. +1 −0 src/core/fieldformatter/qgsvaluerelationfieldformatter.cpp
  53. +2 −1 src/core/geometry/qgsabstractgeometry.h
  54. +1 −0 src/core/geometry/qgswkbptr.cpp
  55. +14 −2 src/core/geometry/qgswkbptr.h
  56. +1 −0 src/core/layertree/qgslayertreemodel.cpp
  57. +1 −0 src/core/layout/qgslayoutitem.h
  58. +1 −0 src/core/layout/qgslayoutitemmap.cpp
  59. +1 −0 src/core/layout/qgslayoutmultiframe.h
  60. +1 −0 src/core/processing/models/qgsprocessingmodelalgorithm.cpp
  61. +1 −0 src/core/processing/qgsprocessingparameters.cpp
  62. +2 −0 src/core/qgsabstractcontentcache.h
  63. +0 −17 src/core/qgsapplication.h
  64. +1 −0 src/core/qgseditformconfig.cpp
  65. +1 −0 src/core/qgsfeaturefiltermodel.cpp
  66. +1 −0 src/core/qgsgml.cpp
  67. +1 −0 src/core/qgsjsonutils.cpp
  68. +1 −0 src/core/qgslayerdefinition.cpp
  69. +1 −0 src/core/qgsproject.cpp
  70. +1 −0 src/core/qgsproxyprogresstask.cpp
  71. +1 −0 src/core/qgssnappingconfig.cpp
  72. +1 −0 src/core/symbology/qgscategorizedsymbolrenderer.cpp
  73. +1 −0 src/core/symbology/qgsfillsymbollayer.cpp
  74. +1 −0 src/core/symbology/qgsrenderer.cpp
  75. +1 −0 src/core/symbology/qgssymbol.cpp
  76. +1 −0 src/gui/attributetable/qgsfeaturelistmodel.cpp
  77. +1 −0 src/gui/editorwidgets/core/qgseditorwidgetregistry.cpp
  78. +1 −0 src/gui/editorwidgets/core/qgssearchwidgetwrapper.cpp
  79. +1 −0 src/gui/editorwidgets/qgsbinarywidgetwrapper.cpp
  80. +1 −0 src/gui/editorwidgets/qgsdatetimeeditwrapper.cpp
  81. +1 −0 src/gui/editorwidgets/qgsdefaultsearchwidgetwrapper.cpp
  82. +1 −0 src/gui/editorwidgets/qgsexternalresourcewidgetwrapper.cpp
  83. +1 −0 src/gui/editorwidgets/qgsrangewidgetwrapper.cpp
  84. +1 −0 src/gui/editorwidgets/qgsrelationreferencesearchwidgetwrapper.cpp
  85. +1 −0 src/gui/editorwidgets/qgstexteditwrapper.cpp
  86. +1 −0 src/gui/editorwidgets/qgsuniquevaluewidgetwrapper.cpp
  87. +1 −0 src/gui/editorwidgets/qgsvaluerelationsearchwidgetwrapper.cpp
  88. +1 −0 src/gui/ogr/qgsvectorlayersaveasdialog.cpp
  89. +1 −0 src/gui/processing/qgsprocessingalgorithmdialogbase.cpp
  90. +1 −0 src/gui/processing/qgsprocessingmodelerparameterwidget.cpp
  91. +1 −0 src/gui/processing/qgsprocessingwidgetwrapperimpl.cpp
  92. +1 −0 src/gui/qgsattributeform.cpp
  93. +1 −0 src/gui/qgsbrowserdockwidget_p.cpp
  94. +1 −0 src/gui/qgsfeaturelistcombobox.cpp
  95. +1 −0 src/gui/qgsfeatureselectiondlg.cpp
  96. +1 −0 src/gui/qgsfontbutton.cpp
  97. +1 −1 src/gui/qgsmaplayerstylemanagerwidget.cpp
  98. +1 −0 src/gui/qgsmaptip.cpp
  99. +1 −0 src/gui/qgsmaptoolcapture.cpp
  100. +1 −0 src/gui/qgsmaptoolzoom.cpp
  101. +1 −0 src/gui/qgsquerybuilder.cpp
  102. +1 −0 src/gui/qgssymbolbutton.cpp
  103. +1 −0 src/gui/qgstextpreview.cpp
  104. +1 −0 src/gui/raster/qgsrendererrasterpropertieswidget.cpp
  105. +1 −0 src/gui/symbology/qgsinvertedpolygonrendererwidget.cpp
  106. +1 −0 src/gui/symbology/qgspointclusterrendererwidget.cpp
  107. +1 −0 src/gui/symbology/qgspointdisplacementrendererwidget.cpp
  108. +1 −0 src/plugins/coordinate_capture/coordinatecapturemaptool.cpp
  109. +1 −0 src/plugins/evis/idtool/eviseventidtool.cpp
  110. +1 −0 src/plugins/geometry_checker/qgsgeometrycheckersetuptab.cpp
  111. +1 −0 src/plugins/offline_editing/offline_editing_plugin_gui.cpp
  112. +1 −0 src/providers/arcgisrest/qgsafsprovider.cpp
  113. +1 −0 src/providers/arcgisrest/qgsamsprovider.cpp
  114. +1 −0 src/providers/arcgisrest/qgsarcgisrestutils.cpp
  115. +1 −0 src/providers/db2/qgsdb2dataitems.cpp
  116. +1 −0 src/providers/db2/qgsdb2provider.cpp
  117. +1 −0 src/providers/mdal/qgsmdalprovider.cpp
  118. +1 −0 src/providers/mssql/qgsmssqldataitems.cpp
  119. +1 −0 src/providers/ogr/qgsgeopackagedataitems.cpp
  120. +1 −0 src/providers/ogr/qgsogrdbtablemodel.cpp
  121. +1 −0 src/providers/spatialite/qgsspatialitedataitems.cpp
  122. +1 −0 src/providers/virtual/qgsvirtuallayerprovider.cpp
  123. +1 −0 src/providers/wcs/qgswcscapabilities.cpp
  124. +3 −0 src/server/qgis_map_serv.cpp
  125. +1 −0 src/server/qgsserver.cpp
  126. +1 −0 src/server/qgsserverparameters.cpp
  127. +1 −0 src/server/services/wms/qgsmaprendererjobproxy.cpp
@@ -11,6 +11,7 @@




typedef QVector< QgsPoint > QgsPointSequence;
typedef QVector< QVector< QgsPoint > > QgsRingSequence;
typedef QVector< QVector< QVector< QgsPoint > > > QgsCoordinateSequence;
@@ -38,6 +38,7 @@ class QgsConstWkbPtr




public:
QgsConstWkbPtr( const unsigned char *p /Array/, int size /ArraySize/ );

@@ -9,6 +9,7 @@




class QgsAbstractContentCacheEntry
{
%Docstring
@@ -503,7 +503,6 @@ Gets application icon
Returns whether this machine uses big or little endian
%End


static QString reportStyleSheet();
%Docstring
Returns a standard css style sheet for reports.
@@ -22,6 +22,7 @@

#include "qgis.h"
#include "qgsprocessingalgorithm.h"
#include "qgsapplication.h"

///@cond PRIVATE

@@ -22,6 +22,7 @@

#include "qgis.h"
#include "qgsprocessingalgorithm.h"
#include "qgsapplication.h"

///@cond PRIVATE

@@ -22,6 +22,7 @@

#include "qgis.h"
#include "qgsprocessingalgorithm.h"
#include "qgsapplication.h"

///@cond PRIVATE

@@ -22,6 +22,7 @@

#include "qgis.h"
#include "qgsprocessingalgorithm.h"
#include "qgsapplication.h"

///@cond PRIVATE

@@ -19,6 +19,7 @@
#define SIP_NO_FILE

#include "qgsprocessingalgorithm.h"
#include "qgsapplication.h"

///@cond PRIVATE

@@ -22,6 +22,7 @@

#include "qgis.h"
#include "qgsprocessingalgorithm.h"
#include "qgsapplication.h"

///@cond PRIVATE

@@ -22,6 +22,7 @@

#include "qgis.h"
#include "qgsprocessingalgorithm.h"
#include "qgsapplication.h"

///@cond PRIVATE

@@ -22,6 +22,7 @@

#include "qgis.h"
#include "qgsprocessingalgorithm.h"
#include "qgsapplication.h"

///@cond PRIVATE

@@ -19,6 +19,7 @@
#define SIP_NO_FILE

#include "qgsprocessingalgorithm.h"
#include "qgsapplication.h"

///@cond PRIVATE

@@ -22,6 +22,7 @@

#include "qgis.h"
#include "qgsprocessingalgorithm.h"
#include "qgsapplication.h"

///@cond PRIVATE

@@ -22,6 +22,7 @@

#include "qgis.h"
#include "qgsprocessingalgorithm.h"
#include "qgsapplication.h"

///@cond PRIVATE

@@ -22,6 +22,7 @@

#include "qgis.h"
#include "qgsprocessingalgorithm.h"
#include "qgsapplication.h"

///@cond PRIVATE

@@ -22,6 +22,7 @@

#include "qgis.h"
#include "qgsprocessingalgorithm.h"
#include "qgsapplication.h"

///@cond PRIVATE

@@ -22,6 +22,7 @@

#include "qgis.h"
#include "qgsprocessingalgorithm.h"
#include "qgsapplication.h"

///@cond PRIVATE

@@ -26,6 +26,7 @@
#include "qgsgraph.h"
#include "qgsgraphbuilder.h"
#include "qgsvectorlayerdirector.h"
#include "qgsapplication.h"

///@cond PRIVATE

@@ -22,6 +22,7 @@

#include "qgis.h"
#include "qgsprocessingalgorithm.h"
#include "qgsapplication.h"

///@cond PRIVATE

@@ -22,6 +22,7 @@

#include "qgis.h"
#include "qgsprocessingalgorithm.h"
#include "qgsapplication.h"

///@cond PRIVATE

@@ -23,6 +23,7 @@
#include "qgis.h"
#include "qgsprocessingalgorithm.h"
#include "qgsmaptopixelgeometrysimplifier.h"
#include "qgsapplication.h"

///@cond PRIVATE

@@ -19,6 +19,7 @@
#define SIP_NO_FILE

#include "qgsprocessingalgorithm.h"
#include "qgsapplication.h"

///@cond PRIVATE

@@ -20,6 +20,7 @@
#define SIP_NO_FILE

#include "qgsprocessingalgorithm.h"
#include "qgsapplication.h"

///@cond PRIVATE

@@ -29,6 +29,7 @@
#include "qgscameracontroller.h"
#include "qgsmapcanvas.h"
#include "qgsmessagebar.h"
#include "qgsapplication.h"

#include "qgs3danimationsettings.h"
#include "qgs3danimationwidget.h"
@@ -16,6 +16,7 @@
#include "qgslightswidget.h"

#include "qgs3dmapsettings.h"
#include "qgsapplication.h"

#include <QMessageBox>

@@ -21,6 +21,7 @@
#include "qgsrulebased3drenderer.h"
#include "qgsvectorlayer.h"
#include "qgssymbol3dwidget.h"
#include "qgsapplication.h"

#include <QAction>
#include <QClipboard>
@@ -21,6 +21,7 @@
#include "qgssymbol3dwidget.h"
#include "qgsvectorlayer.h"
#include "qgsvectorlayer3drenderer.h"
#include "qgsapplication.h"

#include <QBoxLayout>
#include <QCheckBox>
@@ -32,6 +32,7 @@
#include "qgsnewvectorlayerdialog.h"
#include "qgsnewgeopackagelayerdialog.h"
#include "qgsfileutils.h"
#include "qgsapplication.h"
#include <QMenu>
#include <QInputDialog>
#include <QMessageBox>
@@ -103,6 +103,7 @@ class QgsStatusBar;
class QgsGeometryValidationService;
class QgsGeometryValidationDock;
class QgsGeometryValidationModel;
class QgsUserProfileManager;
class QgsUserProfileManagerWidgetFactory;
class Qgs3DMapCanvasDockWidget;
class QgsHandleBadLayersHandler;
@@ -20,6 +20,7 @@
#include "qgisapp.h"
#include "qgsfieldcombobox.h"
#include "qgsqmlwidgetwrapper.h"
#include "qgsapplication.h"

QgsAttributesFormProperties::QgsAttributesFormProperties( QgsVectorLayer *layer, QWidget *parent )
: QWidget( parent )
@@ -28,6 +28,7 @@
#include "qgseditorwidgetfactory.h"
#include "qgseditorwidgetregistry.h"
#include "qgsgui.h"
#include "qgsapplication.h"

#include <QTableWidgetItem>
#include <QFile>
@@ -39,6 +39,7 @@
#include "qgisapp.h"
#include "qgsmapcanvas.h"
#include "qgsproject.h"
#include "qgsapplication.h"

QgsClipboard::QgsClipboard()
{
@@ -29,6 +29,7 @@ email : matthias@opengis.ch
#include "qgsgeometryoptions.h"
#include "qgsgeometrycheckfactory.h"
#include "qgisapp.h"
#include "qgsapplication.h"


QgsGeometryValidationDock::QgsGeometryValidationDock( const QString &title, QgsMapCanvas *mapCanvas, QgisApp *parent, Qt::WindowFlags flags )
@@ -18,6 +18,7 @@ email : matthias@opengis.ch
#include "qgsvectorlayer.h"
#include "qgssinglegeometrycheck.h"
#include "qgsfeatureid.h"
#include "qgsapplication.h"

#include <QIcon>

@@ -27,6 +27,7 @@
#include "qgsmessagebar.h"
#include "qgssettings.h"
#include "qgslayertreeregistrybridge.h"
#include "qgsapplication.h"

#include <QDomDocument>
#include <QDomElement>
@@ -17,6 +17,7 @@
#include "qgslayertree.h"
#include "qgslayertreemodel.h"
#include "qgslayertreeview.h"
#include "qgsapplication.h"

QgsLayerTreeViewEmbeddedIndicatorProvider::QgsLayerTreeViewEmbeddedIndicatorProvider( QgsLayerTreeView *view )
: QObject( view )
@@ -22,6 +22,7 @@
#include "qgsvectorlayer.h"
#include "qgsrasterlayer.h"
#include "qgisapp.h"
#include "qgsapplication.h"

QgsLayerTreeViewIndicatorProvider::QgsLayerTreeViewIndicatorProvider( QgsLayerTreeView *view )
: QObject( view )
@@ -29,6 +29,7 @@
#include "qgsvertexmarker.h"
#include "qgsrubberband.h"
#include "qgsvectorlayer.h"
#include "qgsapplication.h"
#include <QMessageBox>
#include <QMenu>
#include <QToolBar>
@@ -14,6 +14,7 @@
***************************************************************************/

#include "qgsmaplayerstylecategoriesmodel.h"
#include "qgsapplication.h"

QgsMapLayerStyleCategoriesModel::QgsMapLayerStyleCategoriesModel( QObject *parent )
: QAbstractListModel( parent )
@@ -40,6 +40,7 @@
#include "qgssettings.h"
#include "qgsmapcanvas.h"
#include "qgsmessagebar.h"
#include "qgsapplication.h"


Q_GUI_EXPORT extern int qt_defaultDpiX();
@@ -22,6 +22,7 @@
#include "qgsgeometry.h"
#include "qgspointxy.h"
#include "qgis.h"
#include "qgsapplication.h"

#include <QMouseEvent>
#include <QRect>
@@ -24,7 +24,7 @@
#include "qgsproject.h"
#include "qgssnappingconfig.h"
#include "qgsvectorlayer.h"

#include "qgsapplication.h"

QgsSnappingLayerDelegate::QgsSnappingLayerDelegate( QgsMapCanvas *canvas, QObject *parent )
: QItemDelegate( parent )
@@ -17,6 +17,7 @@
#include "qgssourcefieldsproperties.h"
#include "qgsvectorlayer.h"
#include "qgsproject.h"
#include "qgsapplication.h"

QgsSourceFieldsProperties::QgsSourceFieldsProperties( QgsVectorLayer *layer, QWidget *parent )
: QWidget( parent )
@@ -23,6 +23,7 @@
#include "qgsvectorlayer.h"
#include "qgsfeedback.h"
#include "qgsvectorlayerutils.h"
#include "qgsapplication.h"

#include <QTableWidget>
#include <QAction>
@@ -17,6 +17,7 @@
#include "qgsproject.h"
#include "qgsannotation.h"
#include "qgsannotationregistry.h"
#include "qgsapplication.h"

QgsAnnotationManager::QgsAnnotationManager( QgsProject *project )
: QObject( project )
@@ -18,6 +18,7 @@
#include "qgseffectstack.h"
#include "qgspainteffectregistry.h"
#include "qgsrendercontext.h"
#include "qgsapplication.h"
#include <QPicture>

QgsEffectStack::QgsEffectStack( const QgsEffectStack &other )
@@ -20,6 +20,7 @@
#include "qgsgloweffect.h"
#include "qgstransformeffect.h"
#include "qgscoloreffect.h"
#include "qgsapplication.h"

QgsPaintEffectAbstractMetadata::QgsPaintEffectAbstractMetadata( const QString &name, const QString &visibleName )
: mName( name )
@@ -51,6 +51,7 @@
#include "sqlite3.h"
#include "qgstransaction.h"
#include "qgsthreadingutils.h"
#include "qgsapplication.h"

const QString QgsExpressionFunction::helpText() const
{

0 comments on commit f1760ee

Please sign in to comment.
You can’t perform that action at this time.