Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Backport release-3_40] WMS Ignore layer extent settings for default value #59848

Merged
merged 2 commits into from
Dec 12, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ information for an HTTP Server for WMS, etc.
#include "qgsnewhttpconnection.h"
%End
public:

enum ConnectionType /BaseType=IntEnum/
{
ConnectionWfs,
Expand Down
1 change: 1 addition & 0 deletions python/gui/auto_generated/qgsnewhttpconnection.sip.in
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ information for an HTTP Server for WMS, etc.
#include "qgsnewhttpconnection.h"
%End
public:

enum ConnectionType
{
ConnectionWfs,
Expand Down
4 changes: 4 additions & 0 deletions src/gui/qgsnewhttpconnection.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,8 @@
#include <QRegularExpressionValidator>
#include <QUrlQuery>

const QgsSettingsEntryBool *QgsNewHttpConnection::settingsIgnoreReportedLayerExtentsDefault = new QgsSettingsEntryBool( QStringLiteral( "ignore-reported-layer-extents-default" ), sTreeHttpConnectionDialog, false );

QgsNewHttpConnection::QgsNewHttpConnection( QWidget *parent, ConnectionTypes types, const QString &serviceName, const QString &connectionName, QgsNewHttpConnection::Flags flags, Qt::WindowFlags fl )
: QDialog( parent, fl )
, mTypes( types )
Expand Down Expand Up @@ -154,6 +156,8 @@ QgsNewHttpConnection::QgsNewHttpConnection( QWidget *parent, ConnectionTypes typ
}
}

cbxWmsIgnoreReportedLayerExtents->setChecked( settingsIgnoreReportedLayerExtentsDefault->value() );

if ( !( flags & FlagShowTestConnection ) )
{
mTestConnectionButton->hide();
Expand Down
8 changes: 8 additions & 0 deletions src/gui/qgsnewhttpconnection.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,10 @@
#include "ui_qgsnewhttpconnectionbase.h"
#include "qgsguiutils.h"
#include "qgis_gui.h"
#include "qgssettingstree.h"

class QgsAuthSettingsWidget;
class QgsSettingsEntryBool;

/**
* \ingroup gui
Expand All @@ -35,6 +37,12 @@ class GUI_EXPORT QgsNewHttpConnection : public QDialog, private Ui::QgsNewHttpCo
Q_OBJECT

public:
#ifndef SIP_RUN
static inline QgsSettingsTreeNode *sTreeHttpConnectionDialog = QgsSettingsTree::sTreeConnections->createChildNode( QStringLiteral( "http-connection-dialog" ) );

static const QgsSettingsEntryBool *settingsIgnoreReportedLayerExtentsDefault;
#endif

/**
* Available connection types for configuring in the dialog.
*/
Expand Down
Loading