Hello everyone,
I would like to access QgisApp::instance() (src/app/qgisapp.cpp) from a provider like QgsOgrProvider::extent() (src/core/providers/ogr/qgsogrprovider.cpp. Yet I cannot include "qgisapp.h" into the provider. When looking for this information I found some inactivating preprocessor code block comments like this one (qgswfsdataitems.cpp): #if 0 // TODO: how to emit message from provider (which does not know about QgisApp) QgisApp::instance()->messageBar()->pushMessage( tr( "Cannot copy style" ), errorMsg, Qgis::MessageLevel::Critical, messageTimeout() ); #endif Does anybody know what is the idea to access the current QgisApp::instance() from outside the QgisApp realm? Best regards, Tobias -- ZAE Bayern Dipl.-Ing. Tobias Schmetzer Systementwicklung | Systems Engineering Bereich Energiespeicherung | Division Energy Storage Walther-Meißner-Straße 6 85748 Garching Tel.: +49 89 329442-65 Fax: +49 89 329442-12 Mobil | Cell: +49 151 56964756 tobias.schmet...@zae-bayern.de https://www.zae-bayern.de ZAE Bayern Bayerisches Zentrum für Angewandte Energieforschung e. V. | Bavarian Center for Applied Energy Research Vorstand | Board: Dr. Andreas Hauer (Vorsitzender | Chairman), Dr. Hans-Peter Ebert Sitz | Registered Office: Würzburg Registergericht | Register Court: Amtsgericht Würzburg Registernummer | Register Number: VR 1386 Hinweise zum Datenschutz unter https://www.zae-bayern.de/datenschutz
_______________________________________________ QGIS-Developer mailing list QGIS-Developer@lists.osgeo.org List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer