mirror of
https://github.com/qgis/QGIS.git
synced 2025-04-15 00:04:00 -04:00
Remove some dialogs geometry size settings
replaced with automatic restoring
This commit is contained in:
parent
a14aac2ede
commit
059277ceca
@ -21,7 +21,6 @@ A generic message view for displaying QGIS messages.
|
|||||||
%End
|
%End
|
||||||
public:
|
public:
|
||||||
QgsMessageViewer( QWidget *parent /TransferThis/ = 0, Qt::WindowFlags fl = QgsGuiUtils::ModalDialogFlags, bool deleteOnClose = true );
|
QgsMessageViewer( QWidget *parent /TransferThis/ = 0, Qt::WindowFlags fl = QgsGuiUtils::ModalDialogFlags, bool deleteOnClose = true );
|
||||||
~QgsMessageViewer();
|
|
||||||
|
|
||||||
virtual void setMessage( const QString &message, MessageType msgType );
|
virtual void setMessage( const QString &message, MessageType msgType );
|
||||||
|
|
||||||
|
@ -31,7 +31,6 @@ Runs the dialog and creates a new memory layer
|
|||||||
%Docstring
|
%Docstring
|
||||||
New dialog constructor.
|
New dialog constructor.
|
||||||
%End
|
%End
|
||||||
~QgsNewMemoryLayerDialog();
|
|
||||||
|
|
||||||
QgsWkbTypes::Type selectedType() const;
|
QgsWkbTypes::Type selectedType() const;
|
||||||
%Docstring
|
%Docstring
|
||||||
|
@ -21,6 +21,7 @@
|
|||||||
#include "qgsfieldexpressionwidget.h"
|
#include "qgsfieldexpressionwidget.h"
|
||||||
#include "qgsdoublespinbox.h"
|
#include "qgsdoublespinbox.h"
|
||||||
#include "qgssettings.h"
|
#include "qgssettings.h"
|
||||||
|
#include "qgsgui.h"
|
||||||
#include "qgslayouttablecolumn.h"
|
#include "qgslayouttablecolumn.h"
|
||||||
|
|
||||||
#include <QCheckBox>
|
#include <QCheckBox>
|
||||||
@ -885,6 +886,8 @@ QgsLayoutAttributeSelectionDialog::QgsLayoutAttributeSelectionDialog( QgsLayoutI
|
|||||||
|
|
||||||
{
|
{
|
||||||
setupUi( this );
|
setupUi( this );
|
||||||
|
QgsGui::enableAutoGeometryRestore( this );
|
||||||
|
|
||||||
connect( mRemoveColumnPushButton, &QPushButton::clicked, this, &QgsLayoutAttributeSelectionDialog::mRemoveColumnPushButton_clicked );
|
connect( mRemoveColumnPushButton, &QPushButton::clicked, this, &QgsLayoutAttributeSelectionDialog::mRemoveColumnPushButton_clicked );
|
||||||
connect( mAddColumnPushButton, &QPushButton::clicked, this, &QgsLayoutAttributeSelectionDialog::mAddColumnPushButton_clicked );
|
connect( mAddColumnPushButton, &QPushButton::clicked, this, &QgsLayoutAttributeSelectionDialog::mAddColumnPushButton_clicked );
|
||||||
connect( mColumnUpPushButton, &QPushButton::clicked, this, &QgsLayoutAttributeSelectionDialog::mColumnUpPushButton_clicked );
|
connect( mColumnUpPushButton, &QPushButton::clicked, this, &QgsLayoutAttributeSelectionDialog::mColumnUpPushButton_clicked );
|
||||||
@ -896,9 +899,6 @@ QgsLayoutAttributeSelectionDialog::QgsLayoutAttributeSelectionDialog( QgsLayoutI
|
|||||||
connect( mSortColumnUpPushButton, &QPushButton::clicked, this, &QgsLayoutAttributeSelectionDialog::mSortColumnUpPushButton_clicked );
|
connect( mSortColumnUpPushButton, &QPushButton::clicked, this, &QgsLayoutAttributeSelectionDialog::mSortColumnUpPushButton_clicked );
|
||||||
connect( mSortColumnDownPushButton, &QPushButton::clicked, this, &QgsLayoutAttributeSelectionDialog::mSortColumnDownPushButton_clicked );
|
connect( mSortColumnDownPushButton, &QPushButton::clicked, this, &QgsLayoutAttributeSelectionDialog::mSortColumnDownPushButton_clicked );
|
||||||
|
|
||||||
QgsSettings settings;
|
|
||||||
restoreGeometry( settings.value( QStringLiteral( "Windows/AttributeSelectionDialog/geometry" ) ).toByteArray() );
|
|
||||||
|
|
||||||
if ( mTable )
|
if ( mTable )
|
||||||
{
|
{
|
||||||
//set up models, views and delegates
|
//set up models, views and delegates
|
||||||
@ -933,12 +933,6 @@ QgsLayoutAttributeSelectionDialog::QgsLayoutAttributeSelectionDialog( QgsLayoutI
|
|||||||
mOrderComboBox->insertItem( 1, tr( "Descending" ) );
|
mOrderComboBox->insertItem( 1, tr( "Descending" ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
QgsLayoutAttributeSelectionDialog::~QgsLayoutAttributeSelectionDialog()
|
|
||||||
{
|
|
||||||
QgsSettings settings;
|
|
||||||
settings.setValue( QStringLiteral( "Windows/AttributeSelectionDialog/geometry" ), saveGeometry() );
|
|
||||||
}
|
|
||||||
|
|
||||||
void QgsLayoutAttributeSelectionDialog::mRemoveColumnPushButton_clicked()
|
void QgsLayoutAttributeSelectionDialog::mRemoveColumnPushButton_clicked()
|
||||||
{
|
{
|
||||||
//remove selected rows from model
|
//remove selected rows from model
|
||||||
|
@ -286,8 +286,6 @@ class QgsLayoutAttributeSelectionDialog: public QDialog, private Ui::QgsLayoutAt
|
|||||||
public:
|
public:
|
||||||
QgsLayoutAttributeSelectionDialog( QgsLayoutItemAttributeTable *table, QgsVectorLayer *vLayer, QWidget *parent = nullptr, Qt::WindowFlags f = nullptr );
|
QgsLayoutAttributeSelectionDialog( QgsLayoutItemAttributeTable *table, QgsVectorLayer *vLayer, QWidget *parent = nullptr, Qt::WindowFlags f = nullptr );
|
||||||
|
|
||||||
~QgsLayoutAttributeSelectionDialog() override;
|
|
||||||
|
|
||||||
private slots:
|
private slots:
|
||||||
void mRemoveColumnPushButton_clicked();
|
void mRemoveColumnPushButton_clicked();
|
||||||
void mAddColumnPushButton_clicked();
|
void mAddColumnPushButton_clicked();
|
||||||
|
@ -19,13 +19,13 @@
|
|||||||
#include "qgsmaplayermodel.h"
|
#include "qgsmaplayermodel.h"
|
||||||
#include "qgsmaplayerproxymodel.h"
|
#include "qgsmaplayerproxymodel.h"
|
||||||
#include "qgssettings.h"
|
#include "qgssettings.h"
|
||||||
|
#include "qgsgui.h"
|
||||||
|
|
||||||
QgsLayoutLegendLayersDialog::QgsLayoutLegendLayersDialog( QWidget *parent )
|
QgsLayoutLegendLayersDialog::QgsLayoutLegendLayersDialog( QWidget *parent )
|
||||||
: QDialog( parent )
|
: QDialog( parent )
|
||||||
{
|
{
|
||||||
setupUi( this );
|
setupUi( this );
|
||||||
QgsSettings settings;
|
QgsGui::enableAutoGeometryRestore( this );
|
||||||
restoreGeometry( settings.value( QStringLiteral( "Windows/LayoutLegendLayers/geometry" ) ).toByteArray() );
|
|
||||||
|
|
||||||
mFilterLineEdit->setShowClearButton( true );
|
mFilterLineEdit->setShowClearButton( true );
|
||||||
mFilterLineEdit->setShowSearchIcon( true );
|
mFilterLineEdit->setShowSearchIcon( true );
|
||||||
@ -41,12 +41,6 @@ QgsLayoutLegendLayersDialog::QgsLayoutLegendLayersDialog( QWidget *parent )
|
|||||||
connect( mCheckBoxVisibleLayers, &QCheckBox::toggled, this, &QgsLayoutLegendLayersDialog::filterVisible );
|
connect( mCheckBoxVisibleLayers, &QCheckBox::toggled, this, &QgsLayoutLegendLayersDialog::filterVisible );
|
||||||
}
|
}
|
||||||
|
|
||||||
QgsLayoutLegendLayersDialog::~QgsLayoutLegendLayersDialog()
|
|
||||||
{
|
|
||||||
QgsSettings settings;
|
|
||||||
settings.setValue( QStringLiteral( "Windows/LayoutLegendLayers/geometry" ), saveGeometry() );
|
|
||||||
}
|
|
||||||
|
|
||||||
void QgsLayoutLegendLayersDialog::setVisibleLayers( const QList<QgsMapLayer *> &layers )
|
void QgsLayoutLegendLayersDialog::setVisibleLayers( const QList<QgsMapLayer *> &layers )
|
||||||
{
|
{
|
||||||
mVisibleLayers = layers;
|
mVisibleLayers = layers;
|
||||||
|
@ -30,7 +30,6 @@ class QgsLayoutLegendLayersDialog: public QDialog, private Ui::QgsLayoutLegendLa
|
|||||||
|
|
||||||
public:
|
public:
|
||||||
QgsLayoutLegendLayersDialog( QWidget *parent = nullptr );
|
QgsLayoutLegendLayersDialog( QWidget *parent = nullptr );
|
||||||
~QgsLayoutLegendLayersDialog() override;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Sets a list of visible \a layers, to use for filtering within the dialog.
|
* Sets a list of visible \a layers, to use for filtering within the dialog.
|
||||||
|
@ -19,6 +19,7 @@
|
|||||||
#include "qgslayouttable.h"
|
#include "qgslayouttable.h"
|
||||||
#include "qgslayout.h"
|
#include "qgslayout.h"
|
||||||
#include "qgssettings.h"
|
#include "qgssettings.h"
|
||||||
|
#include "qgsgui.h"
|
||||||
|
|
||||||
#include <QCheckBox>
|
#include <QCheckBox>
|
||||||
#include <QPushButton>
|
#include <QPushButton>
|
||||||
@ -28,6 +29,8 @@ QgsLayoutTableBackgroundColorsDialog::QgsLayoutTableBackgroundColorsDialog( QgsL
|
|||||||
, mTable( table )
|
, mTable( table )
|
||||||
{
|
{
|
||||||
setupUi( this );
|
setupUi( this );
|
||||||
|
QgsGui::enableAutoGeometryRestore( this );
|
||||||
|
|
||||||
connect( buttonBox, &QDialogButtonBox::accepted, this, &QgsLayoutTableBackgroundColorsDialog::buttonBox_accepted );
|
connect( buttonBox, &QDialogButtonBox::accepted, this, &QgsLayoutTableBackgroundColorsDialog::buttonBox_accepted );
|
||||||
connect( buttonBox, &QDialogButtonBox::rejected, this, &QgsLayoutTableBackgroundColorsDialog::buttonBox_rejected );
|
connect( buttonBox, &QDialogButtonBox::rejected, this, &QgsLayoutTableBackgroundColorsDialog::buttonBox_rejected );
|
||||||
|
|
||||||
@ -53,18 +56,9 @@ QgsLayoutTableBackgroundColorsDialog::QgsLayoutTableBackgroundColorsDialog( QgsL
|
|||||||
|
|
||||||
connect( buttonBox->button( QDialogButtonBox::Apply ), &QAbstractButton::clicked, this, &QgsLayoutTableBackgroundColorsDialog::apply );
|
connect( buttonBox->button( QDialogButtonBox::Apply ), &QAbstractButton::clicked, this, &QgsLayoutTableBackgroundColorsDialog::apply );
|
||||||
|
|
||||||
QgsSettings settings;
|
|
||||||
restoreGeometry( settings.value( QStringLiteral( "Windows/ComposerTableBackgroundColorsDialog/geometry" ) ).toByteArray() );
|
|
||||||
|
|
||||||
setGuiElementValues();
|
setGuiElementValues();
|
||||||
}
|
}
|
||||||
|
|
||||||
QgsLayoutTableBackgroundColorsDialog::~QgsLayoutTableBackgroundColorsDialog()
|
|
||||||
{
|
|
||||||
QgsSettings settings;
|
|
||||||
settings.setValue( QStringLiteral( "Windows/ComposerTableBackgroundColorsDialog/geometry" ), saveGeometry() );
|
|
||||||
}
|
|
||||||
|
|
||||||
void QgsLayoutTableBackgroundColorsDialog::apply()
|
void QgsLayoutTableBackgroundColorsDialog::apply()
|
||||||
{
|
{
|
||||||
if ( !mTable )
|
if ( !mTable )
|
||||||
|
@ -42,8 +42,6 @@ class QgsLayoutTableBackgroundColorsDialog: public QDialog, private Ui::QgsLayou
|
|||||||
*/
|
*/
|
||||||
QgsLayoutTableBackgroundColorsDialog( QgsLayoutTable *table, QWidget *parent = nullptr, Qt::WindowFlags flags = nullptr );
|
QgsLayoutTableBackgroundColorsDialog( QgsLayoutTable *table, QWidget *parent = nullptr, Qt::WindowFlags flags = nullptr );
|
||||||
|
|
||||||
~QgsLayoutTableBackgroundColorsDialog() override;
|
|
||||||
|
|
||||||
private slots:
|
private slots:
|
||||||
|
|
||||||
void apply();
|
void apply();
|
||||||
|
@ -47,6 +47,7 @@ QgsAttributeTypeDialog::QgsAttributeTypeDialog( QgsVectorLayer *vl, int fieldIdx
|
|||||||
, mFieldIdx( fieldIdx )
|
, mFieldIdx( fieldIdx )
|
||||||
{
|
{
|
||||||
setupUi( this );
|
setupUi( this );
|
||||||
|
QgsGui::enableAutoGeometryRestore( this );
|
||||||
|
|
||||||
if ( fieldIdx < 0 )
|
if ( fieldIdx < 0 )
|
||||||
return;
|
return;
|
||||||
@ -88,18 +89,12 @@ QgsAttributeTypeDialog::QgsAttributeTypeDialog( QgsVectorLayer *vl, int fieldIdx
|
|||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
QgsSettings settings;
|
|
||||||
restoreGeometry( settings.value( QStringLiteral( "Windows/QgsAttributeTypeDialog/geometry" ) ).toByteArray() );
|
|
||||||
|
|
||||||
constraintExpressionWidget->setAllowEmptyFieldName( true );
|
constraintExpressionWidget->setAllowEmptyFieldName( true );
|
||||||
constraintExpressionWidget->setLayer( vl );
|
constraintExpressionWidget->setLayer( vl );
|
||||||
}
|
}
|
||||||
|
|
||||||
QgsAttributeTypeDialog::~QgsAttributeTypeDialog()
|
QgsAttributeTypeDialog::~QgsAttributeTypeDialog()
|
||||||
{
|
{
|
||||||
QgsSettings settings;
|
|
||||||
settings.setValue( QStringLiteral( "Windows/QgsAttributeTypeDialog/geometry" ), saveGeometry() );
|
|
||||||
|
|
||||||
qDeleteAll( mEditorConfigWidgets );
|
qDeleteAll( mEditorConfigWidgets );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -21,10 +21,13 @@
|
|||||||
#include "qgsvectordataprovider.h"
|
#include "qgsvectordataprovider.h"
|
||||||
#include "qgsvectorlayer.h"
|
#include "qgsvectorlayer.h"
|
||||||
#include "qgssettings.h"
|
#include "qgssettings.h"
|
||||||
|
#include "qgsgui.h"
|
||||||
|
|
||||||
QgsDelAttrDialog::QgsDelAttrDialog( const QgsVectorLayer *vl )
|
QgsDelAttrDialog::QgsDelAttrDialog( const QgsVectorLayer *vl )
|
||||||
{
|
{
|
||||||
setupUi( this );
|
setupUi( this );
|
||||||
|
QgsGui::enableAutoGeometryRestore( this );
|
||||||
|
|
||||||
if ( vl )
|
if ( vl )
|
||||||
{
|
{
|
||||||
bool canDeleteAttributes = vl->dataProvider()->capabilities() & QgsVectorDataProvider::DeleteAttributes;
|
bool canDeleteAttributes = vl->dataProvider()->capabilities() & QgsVectorDataProvider::DeleteAttributes;
|
||||||
@ -57,15 +60,6 @@ QgsDelAttrDialog::QgsDelAttrDialog( const QgsVectorLayer *vl )
|
|||||||
mEditModeInfo->setVisible( !vl->isEditable() );
|
mEditModeInfo->setVisible( !vl->isEditable() );
|
||||||
mCanDeleteAttributesInfo->setVisible( !canDeleteAttributes );
|
mCanDeleteAttributesInfo->setVisible( !canDeleteAttributes );
|
||||||
}
|
}
|
||||||
|
|
||||||
QgsSettings settings;
|
|
||||||
restoreGeometry( settings.value( QStringLiteral( "Windows/QgsDelAttrDialog/geometry" ) ).toByteArray() );
|
|
||||||
}
|
|
||||||
|
|
||||||
QgsDelAttrDialog::~QgsDelAttrDialog()
|
|
||||||
{
|
|
||||||
QgsSettings settings;
|
|
||||||
settings.setValue( QStringLiteral( "Windows/QgsDelAttrDialog/geometry" ), saveGeometry() );
|
|
||||||
}
|
}
|
||||||
|
|
||||||
QList<int> QgsDelAttrDialog::selectedAttributes()
|
QList<int> QgsDelAttrDialog::selectedAttributes()
|
||||||
|
@ -30,7 +30,7 @@ class APP_EXPORT QgsDelAttrDialog: public QDialog, private Ui::QgsDelAttrDialogB
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
public:
|
public:
|
||||||
QgsDelAttrDialog( const QgsVectorLayer *vl );
|
QgsDelAttrDialog( const QgsVectorLayer *vl );
|
||||||
~QgsDelAttrDialog() override;
|
|
||||||
//! Returns the selected attribute indices
|
//! Returns the selected attribute indices
|
||||||
QList<int> selectedAttributes();
|
QList<int> selectedAttributes();
|
||||||
};
|
};
|
||||||
|
@ -60,6 +60,8 @@ QgsMergeAttributesDialog::QgsMergeAttributesDialog( const QgsFeatureList &featur
|
|||||||
|
|
||||||
{
|
{
|
||||||
setupUi( this );
|
setupUi( this );
|
||||||
|
QgsGui::enableAutoGeometryRestore( this );
|
||||||
|
|
||||||
connect( mFromSelectedPushButton, &QPushButton::clicked, this, &QgsMergeAttributesDialog::mFromSelectedPushButton_clicked );
|
connect( mFromSelectedPushButton, &QPushButton::clicked, this, &QgsMergeAttributesDialog::mFromSelectedPushButton_clicked );
|
||||||
connect( mRemoveFeatureFromSelectionButton, &QPushButton::clicked, this, &QgsMergeAttributesDialog::mRemoveFeatureFromSelectionButton_clicked );
|
connect( mRemoveFeatureFromSelectionButton, &QPushButton::clicked, this, &QgsMergeAttributesDialog::mRemoveFeatureFromSelectionButton_clicked );
|
||||||
createTableWidgetContents();
|
createTableWidgetContents();
|
||||||
@ -75,9 +77,6 @@ QgsMergeAttributesDialog::QgsMergeAttributesDialog( const QgsFeatureList &featur
|
|||||||
mFromSelectedPushButton->setIcon( QgsApplication::getThemeIcon( QStringLiteral( "mActionFromSelectedFeature.svg" ) ) );
|
mFromSelectedPushButton->setIcon( QgsApplication::getThemeIcon( QStringLiteral( "mActionFromSelectedFeature.svg" ) ) );
|
||||||
mRemoveFeatureFromSelectionButton->setIcon( QgsApplication::getThemeIcon( QStringLiteral( "mActionRemoveSelectedFeature.svg" ) ) );
|
mRemoveFeatureFromSelectionButton->setIcon( QgsApplication::getThemeIcon( QStringLiteral( "mActionRemoveSelectedFeature.svg" ) ) );
|
||||||
|
|
||||||
QgsSettings settings;
|
|
||||||
restoreGeometry( settings.value( QStringLiteral( "Windows/MergeAttributes/geometry" ) ).toByteArray() );
|
|
||||||
|
|
||||||
connect( mSkipAllButton, &QAbstractButton::clicked, this, &QgsMergeAttributesDialog::setAllToSkip );
|
connect( mSkipAllButton, &QAbstractButton::clicked, this, &QgsMergeAttributesDialog::setAllToSkip );
|
||||||
connect( mTableWidget, &QTableWidget::cellChanged, this, &QgsMergeAttributesDialog::tableWidgetCellChanged );
|
connect( mTableWidget, &QTableWidget::cellChanged, this, &QgsMergeAttributesDialog::tableWidgetCellChanged );
|
||||||
}
|
}
|
||||||
@ -85,18 +84,14 @@ QgsMergeAttributesDialog::QgsMergeAttributesDialog( const QgsFeatureList &featur
|
|||||||
QgsMergeAttributesDialog::QgsMergeAttributesDialog()
|
QgsMergeAttributesDialog::QgsMergeAttributesDialog()
|
||||||
{
|
{
|
||||||
setupUi( this );
|
setupUi( this );
|
||||||
|
QgsGui::enableAutoGeometryRestore( this );
|
||||||
|
|
||||||
connect( mFromSelectedPushButton, &QPushButton::clicked, this, &QgsMergeAttributesDialog::mFromSelectedPushButton_clicked );
|
connect( mFromSelectedPushButton, &QPushButton::clicked, this, &QgsMergeAttributesDialog::mFromSelectedPushButton_clicked );
|
||||||
connect( mRemoveFeatureFromSelectionButton, &QPushButton::clicked, this, &QgsMergeAttributesDialog::mRemoveFeatureFromSelectionButton_clicked );
|
connect( mRemoveFeatureFromSelectionButton, &QPushButton::clicked, this, &QgsMergeAttributesDialog::mRemoveFeatureFromSelectionButton_clicked );
|
||||||
|
|
||||||
QgsSettings settings;
|
|
||||||
restoreGeometry( settings.value( QStringLiteral( "Windows/MergeAttributes/geometry" ) ).toByteArray() );
|
|
||||||
}
|
}
|
||||||
|
|
||||||
QgsMergeAttributesDialog::~QgsMergeAttributesDialog()
|
QgsMergeAttributesDialog::~QgsMergeAttributesDialog()
|
||||||
{
|
{
|
||||||
QgsSettings settings;
|
|
||||||
settings.setValue( QStringLiteral( "Windows/MergeAttributes/geometry" ), saveGeometry() );
|
|
||||||
|
|
||||||
delete mSelectionRubberBand;
|
delete mSelectionRubberBand;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -21,6 +21,7 @@
|
|||||||
#include "qgslayertreeutils.h"
|
#include "qgslayertreeutils.h"
|
||||||
#include "qgssettings.h"
|
#include "qgssettings.h"
|
||||||
#include "qgsziputils.h"
|
#include "qgsziputils.h"
|
||||||
|
#include "qgsgui.h"
|
||||||
|
|
||||||
#include <QDomDocument>
|
#include <QDomDocument>
|
||||||
#include <QFileDialog>
|
#include <QFileDialog>
|
||||||
@ -48,6 +49,7 @@ QgsProjectLayerGroupDialog::QgsProjectLayerGroupDialog( QWidget *parent, const Q
|
|||||||
, mRootGroup( new QgsLayerTree )
|
, mRootGroup( new QgsLayerTree )
|
||||||
{
|
{
|
||||||
setupUi( this );
|
setupUi( this );
|
||||||
|
QgsGui::enableAutoGeometryRestore( this );
|
||||||
|
|
||||||
QgsEmbeddedLayerTreeModel *model = new QgsEmbeddedLayerTreeModel( mRootGroup, this );
|
QgsEmbeddedLayerTreeModel *model = new QgsEmbeddedLayerTreeModel( mRootGroup, this );
|
||||||
mTreeView->setModel( model );
|
mTreeView->setModel( model );
|
||||||
@ -74,21 +76,13 @@ QgsProjectLayerGroupDialog::QgsProjectLayerGroupDialog( QWidget *parent, const Q
|
|||||||
}
|
}
|
||||||
|
|
||||||
connect( mProjectFileWidget, &QgsFileWidget::fileChanged, this, &QgsProjectLayerGroupDialog::changeProjectFile );
|
connect( mProjectFileWidget, &QgsFileWidget::fileChanged, this, &QgsProjectLayerGroupDialog::changeProjectFile );
|
||||||
|
|
||||||
connect( mButtonBox, &QDialogButtonBox::accepted, this, &QgsProjectLayerGroupDialog::mButtonBox_accepted );
|
connect( mButtonBox, &QDialogButtonBox::accepted, this, &QgsProjectLayerGroupDialog::mButtonBox_accepted );
|
||||||
|
|
||||||
restoreGeometry( settings.value( QStringLiteral( "Windows/EmbedLayer/geometry" ) ).toByteArray() );
|
|
||||||
|
|
||||||
|
|
||||||
connect( mButtonBox, &QDialogButtonBox::rejected, this, &QDialog::reject );
|
connect( mButtonBox, &QDialogButtonBox::rejected, this, &QDialog::reject );
|
||||||
connect( mButtonBox, &QDialogButtonBox::helpRequested, this, &QgsProjectLayerGroupDialog::showHelp );
|
connect( mButtonBox, &QDialogButtonBox::helpRequested, this, &QgsProjectLayerGroupDialog::showHelp );
|
||||||
}
|
}
|
||||||
|
|
||||||
QgsProjectLayerGroupDialog::~QgsProjectLayerGroupDialog()
|
QgsProjectLayerGroupDialog::~QgsProjectLayerGroupDialog()
|
||||||
{
|
{
|
||||||
QgsSettings settings;
|
|
||||||
settings.setValue( QStringLiteral( "Windows/EmbedLayer/geometry" ), saveGeometry() );
|
|
||||||
|
|
||||||
delete mRootGroup;
|
delete mRootGroup;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -21,6 +21,7 @@
|
|||||||
#include "qgssettings.h"
|
#include "qgssettings.h"
|
||||||
#include "qgsmessagebar.h"
|
#include "qgsmessagebar.h"
|
||||||
#include "qgsexpressioncontextutils.h"
|
#include "qgsexpressioncontextutils.h"
|
||||||
|
#include "qgsgui.h"
|
||||||
|
|
||||||
|
|
||||||
QgsSelectByFormDialog::QgsSelectByFormDialog( QgsVectorLayer *layer, const QgsAttributeEditorContext &context, QWidget *parent, Qt::WindowFlags fl )
|
QgsSelectByFormDialog::QgsSelectByFormDialog( QgsVectorLayer *layer, const QgsAttributeEditorContext &context, QWidget *parent, Qt::WindowFlags fl )
|
||||||
@ -44,18 +45,11 @@ QgsSelectByFormDialog::QgsSelectByFormDialog( QgsVectorLayer *layer, const QgsAt
|
|||||||
|
|
||||||
connect( mForm, &QgsAttributeForm::closed, this, &QWidget::close );
|
connect( mForm, &QgsAttributeForm::closed, this, &QWidget::close );
|
||||||
|
|
||||||
QgsSettings settings;
|
QgsGui::enableAutoGeometryRestore( this );
|
||||||
restoreGeometry( settings.value( QStringLiteral( "Windows/SelectByForm/geometry" ) ).toByteArray() );
|
|
||||||
|
|
||||||
setWindowTitle( tr( "Select Features by Value" ) );
|
setWindowTitle( tr( "Select Features by Value" ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
QgsSelectByFormDialog::~QgsSelectByFormDialog()
|
|
||||||
{
|
|
||||||
QgsSettings settings;
|
|
||||||
settings.setValue( QStringLiteral( "Windows/SelectByForm/geometry" ), saveGeometry() );
|
|
||||||
}
|
|
||||||
|
|
||||||
void QgsSelectByFormDialog::setMessageBar( QgsMessageBar *messageBar )
|
void QgsSelectByFormDialog::setMessageBar( QgsMessageBar *messageBar )
|
||||||
{
|
{
|
||||||
mMessageBar = messageBar;
|
mMessageBar = messageBar;
|
||||||
|
@ -49,8 +49,6 @@ class APP_EXPORT QgsSelectByFormDialog : public QDialog
|
|||||||
const QgsAttributeEditorContext &context = QgsAttributeEditorContext(),
|
const QgsAttributeEditorContext &context = QgsAttributeEditorContext(),
|
||||||
QWidget *parent = nullptr, Qt::WindowFlags fl = nullptr );
|
QWidget *parent = nullptr, Qt::WindowFlags fl = nullptr );
|
||||||
|
|
||||||
~QgsSelectByFormDialog() override;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Sets the message bar to display feedback from the form in. This is used in the search/filter
|
* Sets the message bar to display feedback from the form in. This is used in the search/filter
|
||||||
* mode to display the count of selected features.
|
* mode to display the count of selected features.
|
||||||
|
@ -20,6 +20,7 @@
|
|||||||
#include "qgsvectorlayer.h"
|
#include "qgsvectorlayer.h"
|
||||||
#include "qgssettings.h"
|
#include "qgssettings.h"
|
||||||
#include "qgshelp.h"
|
#include "qgshelp.h"
|
||||||
|
#include "qgsgui.h"
|
||||||
#include "qgsmaplayerstylecategoriesmodel.h"
|
#include "qgsmaplayerstylecategoriesmodel.h"
|
||||||
|
|
||||||
QgsVectorLayerSaveStyleDialog::QgsVectorLayerSaveStyleDialog( QgsVectorLayer *layer, QWidget *parent )
|
QgsVectorLayerSaveStyleDialog::QgsVectorLayerSaveStyleDialog( QgsVectorLayer *layer, QWidget *parent )
|
||||||
@ -27,6 +28,8 @@ QgsVectorLayerSaveStyleDialog::QgsVectorLayerSaveStyleDialog( QgsVectorLayer *la
|
|||||||
, mLayer( layer )
|
, mLayer( layer )
|
||||||
{
|
{
|
||||||
setupUi( this );
|
setupUi( this );
|
||||||
|
QgsGui::enableAutoGeometryRestore( this );
|
||||||
|
|
||||||
QgsSettings settings;
|
QgsSettings settings;
|
||||||
|
|
||||||
QString providerName = mLayer->providerType();
|
QString providerName = mLayer->providerType();
|
||||||
@ -81,7 +84,6 @@ QgsVectorLayerSaveStyleDialog::QgsVectorLayerSaveStyleDialog( QgsVectorLayer *la
|
|||||||
mModel->setCategories( lastStyleCategories );
|
mModel->setCategories( lastStyleCategories );
|
||||||
mStyleCategoriesListView->setModel( mModel );
|
mStyleCategoriesListView->setModel( mModel );
|
||||||
|
|
||||||
restoreGeometry( settings.value( QStringLiteral( "Windows/vectorLayerSaveStyle/geometry" ) ).toByteArray() );
|
|
||||||
mStyleCategoriesListView->adjustSize();
|
mStyleCategoriesListView->adjustSize();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -98,12 +100,6 @@ void QgsVectorLayerSaveStyleDialog::updateSaveButtonState()
|
|||||||
( type != QgsVectorLayerProperties::DB && !mFileWidget->filePath().isEmpty() ) );
|
( type != QgsVectorLayerProperties::DB && !mFileWidget->filePath().isEmpty() ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
QgsVectorLayerSaveStyleDialog::~QgsVectorLayerSaveStyleDialog()
|
|
||||||
{
|
|
||||||
QgsSettings settings;
|
|
||||||
settings.setValue( QStringLiteral( "Windows/vectorLayerSaveStyle/geometry" ), saveGeometry() );
|
|
||||||
}
|
|
||||||
|
|
||||||
QgsVectorLayerSaveStyleDialog::SaveToDbSettings QgsVectorLayerSaveStyleDialog::saveToDbSettings() const
|
QgsVectorLayerSaveStyleDialog::SaveToDbSettings QgsVectorLayerSaveStyleDialog::saveToDbSettings() const
|
||||||
{
|
{
|
||||||
SaveToDbSettings settings;
|
SaveToDbSettings settings;
|
||||||
|
@ -40,7 +40,6 @@ class QgsVectorLayerSaveStyleDialog : public QDialog, private Ui::QgsVectorLayer
|
|||||||
};
|
};
|
||||||
|
|
||||||
explicit QgsVectorLayerSaveStyleDialog( QgsVectorLayer *layer, QWidget *parent = nullptr );
|
explicit QgsVectorLayerSaveStyleDialog( QgsVectorLayer *layer, QWidget *parent = nullptr );
|
||||||
~QgsVectorLayerSaveStyleDialog() override;
|
|
||||||
|
|
||||||
SaveToDbSettings saveToDbSettings() const;
|
SaveToDbSettings saveToDbSettings() const;
|
||||||
QString outputFilePath() const;
|
QString outputFilePath() const;
|
||||||
|
@ -23,6 +23,7 @@
|
|||||||
#include "qgsogrhelperfunctions.h"
|
#include "qgsogrhelperfunctions.h"
|
||||||
#include "qgsapplication.h"
|
#include "qgsapplication.h"
|
||||||
#include "qgssettings.h"
|
#include "qgssettings.h"
|
||||||
|
#include "qgsgui.h"
|
||||||
|
|
||||||
#include <ogr_api.h>
|
#include <ogr_api.h>
|
||||||
#include <cpl_error.h>
|
#include <cpl_error.h>
|
||||||
@ -33,13 +34,14 @@ QgsNewOgrConnection::QgsNewOgrConnection( QWidget *parent, const QString &connTy
|
|||||||
, mOriginalConnName( connName )
|
, mOriginalConnName( connName )
|
||||||
{
|
{
|
||||||
setupUi( this );
|
setupUi( this );
|
||||||
|
QgsGui::enableAutoGeometryRestore( this );
|
||||||
|
|
||||||
connect( btnConnect, &QPushButton::clicked, this, &QgsNewOgrConnection::btnConnect_clicked );
|
connect( btnConnect, &QPushButton::clicked, this, &QgsNewOgrConnection::btnConnect_clicked );
|
||||||
Q_NOWARN_DEPRECATED_PUSH
|
Q_NOWARN_DEPRECATED_PUSH
|
||||||
connect( buttonBox, &QDialogButtonBox::helpRequested, this, &QgsNewOgrConnection::showHelp );
|
connect( buttonBox, &QDialogButtonBox::helpRequested, this, &QgsNewOgrConnection::showHelp );
|
||||||
Q_NOWARN_DEPRECATED_POP
|
Q_NOWARN_DEPRECATED_POP
|
||||||
|
|
||||||
QgsSettings settings;
|
QgsSettings settings;
|
||||||
restoreGeometry( settings.value( QStringLiteral( "Windows/OGRDatabaseConnection/geometry" ) ).toByteArray() );
|
|
||||||
|
|
||||||
//add database drivers
|
//add database drivers
|
||||||
QStringList dbDrivers = QgsProviderRegistry::instance()->databaseDrivers().split( ';' );
|
QStringList dbDrivers = QgsProviderRegistry::instance()->databaseDrivers().split( ';' );
|
||||||
@ -80,12 +82,6 @@ QgsNewOgrConnection::QgsNewOgrConnection( QWidget *parent, const QString &connTy
|
|||||||
mAuthSettingsDatabase->showStoreCheckboxes( true );
|
mAuthSettingsDatabase->showStoreCheckboxes( true );
|
||||||
}
|
}
|
||||||
|
|
||||||
QgsNewOgrConnection::~QgsNewOgrConnection()
|
|
||||||
{
|
|
||||||
QgsSettings settings;
|
|
||||||
settings.setValue( QStringLiteral( "Windows/OGRDatabaseConnection/geometry" ), saveGeometry() );
|
|
||||||
}
|
|
||||||
|
|
||||||
void QgsNewOgrConnection::testConnection()
|
void QgsNewOgrConnection::testConnection()
|
||||||
{
|
{
|
||||||
QString uri;
|
QString uri;
|
||||||
|
@ -41,7 +41,6 @@ class GUI_EXPORT QgsNewOgrConnection : public QDialog, private Ui::QgsNewOgrConn
|
|||||||
//! Constructor
|
//! Constructor
|
||||||
QgsNewOgrConnection( QWidget *parent = nullptr, const QString &connType = QString(), const QString &connName = QString(), Qt::WindowFlags fl = QgsGuiUtils::ModalDialogFlags );
|
QgsNewOgrConnection( QWidget *parent = nullptr, const QString &connType = QString(), const QString &connName = QString(), Qt::WindowFlags fl = QgsGuiUtils::ModalDialogFlags );
|
||||||
|
|
||||||
~QgsNewOgrConnection() override;
|
|
||||||
//! Tests the connection using the parameters supplied
|
//! Tests the connection using the parameters supplied
|
||||||
void testConnection();
|
void testConnection();
|
||||||
|
|
||||||
|
@ -20,6 +20,7 @@
|
|||||||
#include "qgssymbollayerutils.h"
|
#include "qgssymbollayerutils.h"
|
||||||
#include "qgsapplication.h"
|
#include "qgsapplication.h"
|
||||||
#include "qgssettings.h"
|
#include "qgssettings.h"
|
||||||
|
#include "qgsgui.h"
|
||||||
|
|
||||||
#include <QPushButton>
|
#include <QPushButton>
|
||||||
#include <QMenu>
|
#include <QMenu>
|
||||||
@ -35,13 +36,12 @@ QgsColorDialog::QgsColorDialog( QWidget *parent, Qt::WindowFlags fl, const QColo
|
|||||||
, mPreviousColor( color )
|
, mPreviousColor( color )
|
||||||
{
|
{
|
||||||
setupUi( this );
|
setupUi( this );
|
||||||
|
QgsGui::enableAutoGeometryRestore( this );
|
||||||
|
|
||||||
connect( mButtonBox, &QDialogButtonBox::accepted, this, &QgsColorDialog::mButtonBox_accepted );
|
connect( mButtonBox, &QDialogButtonBox::accepted, this, &QgsColorDialog::mButtonBox_accepted );
|
||||||
connect( mButtonBox, &QDialogButtonBox::rejected, this, &QgsColorDialog::mButtonBox_rejected );
|
connect( mButtonBox, &QDialogButtonBox::rejected, this, &QgsColorDialog::mButtonBox_rejected );
|
||||||
connect( mButtonBox, &QDialogButtonBox::clicked, this, &QgsColorDialog::mButtonBox_clicked );
|
connect( mButtonBox, &QDialogButtonBox::clicked, this, &QgsColorDialog::mButtonBox_clicked );
|
||||||
|
|
||||||
QgsSettings settings;
|
|
||||||
restoreGeometry( settings.value( QStringLiteral( "Windows/ColorDialog/geometry" ) ).toByteArray() );
|
|
||||||
|
|
||||||
if ( mPreviousColor.isValid() )
|
if ( mPreviousColor.isValid() )
|
||||||
{
|
{
|
||||||
QPushButton *resetButton = new QPushButton( tr( "Reset" ) );
|
QPushButton *resetButton = new QPushButton( tr( "Reset" ) );
|
||||||
@ -110,13 +110,11 @@ QColor QgsColorDialog::getColor( const QColor &initialColor, QWidget *parent, co
|
|||||||
|
|
||||||
void QgsColorDialog::mButtonBox_accepted()
|
void QgsColorDialog::mButtonBox_accepted()
|
||||||
{
|
{
|
||||||
saveSettings();
|
|
||||||
accept();
|
accept();
|
||||||
}
|
}
|
||||||
|
|
||||||
void QgsColorDialog::mButtonBox_rejected()
|
void QgsColorDialog::mButtonBox_rejected()
|
||||||
{
|
{
|
||||||
saveSettings();
|
|
||||||
reject();
|
reject();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -133,12 +131,6 @@ void QgsColorDialog::discardColor()
|
|||||||
mColorWidget->setDiscarded( true );
|
mColorWidget->setDiscarded( true );
|
||||||
}
|
}
|
||||||
|
|
||||||
void QgsColorDialog::saveSettings()
|
|
||||||
{
|
|
||||||
QgsSettings settings;
|
|
||||||
settings.setValue( QStringLiteral( "Windows/ColorDialog/geometry" ), saveGeometry() );
|
|
||||||
}
|
|
||||||
|
|
||||||
void QgsColorDialog::setColor( const QColor &color )
|
void QgsColorDialog::setColor( const QColor &color )
|
||||||
{
|
{
|
||||||
if ( !color.isValid() )
|
if ( !color.isValid() )
|
||||||
@ -159,7 +151,6 @@ void QgsColorDialog::setColor( const QColor &color )
|
|||||||
|
|
||||||
void QgsColorDialog::closeEvent( QCloseEvent *e )
|
void QgsColorDialog::closeEvent( QCloseEvent *e )
|
||||||
{
|
{
|
||||||
saveSettings();
|
|
||||||
QDialog::closeEvent( e );
|
QDialog::closeEvent( e );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -114,11 +114,6 @@ class GUI_EXPORT QgsColorDialog : public QDialog, private Ui::QgsColorDialogBase
|
|||||||
|
|
||||||
bool mAllowOpacity = true;
|
bool mAllowOpacity = true;
|
||||||
|
|
||||||
/**
|
|
||||||
* Saves all dialog and widget settings
|
|
||||||
*/
|
|
||||||
void saveSettings();
|
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // #ifndef QGSCOLORDIALOG_H
|
#endif // #ifndef QGSCOLORDIALOG_H
|
||||||
|
@ -17,11 +17,14 @@
|
|||||||
|
|
||||||
#include "qgsmessageviewer.h"
|
#include "qgsmessageviewer.h"
|
||||||
#include "qgssettings.h"
|
#include "qgssettings.h"
|
||||||
|
#include "qgsgui.h"
|
||||||
|
|
||||||
QgsMessageViewer::QgsMessageViewer( QWidget *parent, Qt::WindowFlags fl, bool deleteOnClose )
|
QgsMessageViewer::QgsMessageViewer( QWidget *parent, Qt::WindowFlags fl, bool deleteOnClose )
|
||||||
: QDialog( parent, fl )
|
: QDialog( parent, fl )
|
||||||
{
|
{
|
||||||
setupUi( this );
|
setupUi( this );
|
||||||
|
QgsGui::enableAutoGeometryRestore( this );
|
||||||
|
|
||||||
connect( checkBox, &QCheckBox::toggled, this, &QgsMessageViewer::checkBox_toggled );
|
connect( checkBox, &QCheckBox::toggled, this, &QgsMessageViewer::checkBox_toggled );
|
||||||
if ( deleteOnClose )
|
if ( deleteOnClose )
|
||||||
{
|
{
|
||||||
@ -31,19 +34,10 @@ QgsMessageViewer::QgsMessageViewer( QWidget *parent, Qt::WindowFlags fl, bool de
|
|||||||
setCheckBoxVisible( false );
|
setCheckBoxVisible( false );
|
||||||
setCheckBoxState( Qt::Unchecked );
|
setCheckBoxState( Qt::Unchecked );
|
||||||
|
|
||||||
QgsSettings settings;
|
|
||||||
restoreGeometry( settings.value( QStringLiteral( "Windows/MessageViewer/geometry" ) ).toByteArray() );
|
|
||||||
|
|
||||||
txtMessage->setTextInteractionFlags( Qt::TextBrowserInteraction );
|
txtMessage->setTextInteractionFlags( Qt::TextBrowserInteraction );
|
||||||
txtMessage->setOpenExternalLinks( true );
|
txtMessage->setOpenExternalLinks( true );
|
||||||
}
|
}
|
||||||
|
|
||||||
QgsMessageViewer::~QgsMessageViewer()
|
|
||||||
{
|
|
||||||
QgsSettings settings;
|
|
||||||
settings.setValue( QStringLiteral( "Windows/MessageViewer/geometry" ), saveGeometry() );
|
|
||||||
}
|
|
||||||
|
|
||||||
void QgsMessageViewer::setMessageAsHtml( const QString &msg )
|
void QgsMessageViewer::setMessageAsHtml( const QString &msg )
|
||||||
{
|
{
|
||||||
txtMessage->setHtml( msg );
|
txtMessage->setHtml( msg );
|
||||||
|
@ -34,7 +34,6 @@ class GUI_EXPORT QgsMessageViewer: public QDialog, public QgsMessageOutput, priv
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
public:
|
public:
|
||||||
QgsMessageViewer( QWidget *parent SIP_TRANSFERTHIS = nullptr, Qt::WindowFlags fl = QgsGuiUtils::ModalDialogFlags, bool deleteOnClose = true );
|
QgsMessageViewer( QWidget *parent SIP_TRANSFERTHIS = nullptr, Qt::WindowFlags fl = QgsGuiUtils::ModalDialogFlags, bool deleteOnClose = true );
|
||||||
~QgsMessageViewer() override;
|
|
||||||
|
|
||||||
void setMessage( const QString &message, MessageType msgType ) override;
|
void setMessage( const QString &message, MessageType msgType ) override;
|
||||||
|
|
||||||
|
@ -24,6 +24,7 @@
|
|||||||
#include "qgsvectorlayer.h"
|
#include "qgsvectorlayer.h"
|
||||||
#include "qgssettings.h"
|
#include "qgssettings.h"
|
||||||
#include "qgsmemoryproviderutils.h"
|
#include "qgsmemoryproviderutils.h"
|
||||||
|
#include "qgsgui.h"
|
||||||
|
|
||||||
#include <QPushButton>
|
#include <QPushButton>
|
||||||
#include <QComboBox>
|
#include <QComboBox>
|
||||||
@ -50,9 +51,7 @@ QgsNewMemoryLayerDialog::QgsNewMemoryLayerDialog( QWidget *parent, Qt::WindowFla
|
|||||||
: QDialog( parent, fl )
|
: QDialog( parent, fl )
|
||||||
{
|
{
|
||||||
setupUi( this );
|
setupUi( this );
|
||||||
|
QgsGui::enableAutoGeometryRestore( this );
|
||||||
QgsSettings settings;
|
|
||||||
restoreGeometry( settings.value( QStringLiteral( "Windows/NewMemoryLayer/geometry" ) ).toByteArray() );
|
|
||||||
|
|
||||||
mGeometryTypeBox->addItem( QgsApplication::getThemeIcon( QStringLiteral( "/mIconTableLayer.svg" ) ), tr( "No geometry" ), QgsWkbTypes::NoGeometry );
|
mGeometryTypeBox->addItem( QgsApplication::getThemeIcon( QStringLiteral( "/mIconTableLayer.svg" ) ), tr( "No geometry" ), QgsWkbTypes::NoGeometry );
|
||||||
mGeometryTypeBox->addItem( QgsApplication::getThemeIcon( QStringLiteral( "/mIconPointLayer.svg" ) ), tr( "Point" ), QgsWkbTypes::Point );
|
mGeometryTypeBox->addItem( QgsApplication::getThemeIcon( QStringLiteral( "/mIconPointLayer.svg" ) ), tr( "Point" ), QgsWkbTypes::Point );
|
||||||
@ -72,12 +71,6 @@ QgsNewMemoryLayerDialog::QgsNewMemoryLayerDialog( QWidget *parent, Qt::WindowFla
|
|||||||
geometryTypeChanged( mGeometryTypeBox->currentIndex() );
|
geometryTypeChanged( mGeometryTypeBox->currentIndex() );
|
||||||
}
|
}
|
||||||
|
|
||||||
QgsNewMemoryLayerDialog::~QgsNewMemoryLayerDialog()
|
|
||||||
{
|
|
||||||
QgsSettings settings;
|
|
||||||
settings.setValue( QStringLiteral( "Windows/NewMemoryLayer/geometry" ), saveGeometry() );
|
|
||||||
}
|
|
||||||
|
|
||||||
QgsWkbTypes::Type QgsNewMemoryLayerDialog::selectedType() const
|
QgsWkbTypes::Type QgsNewMemoryLayerDialog::selectedType() const
|
||||||
{
|
{
|
||||||
QgsWkbTypes::Type geomType = QgsWkbTypes::Unknown;
|
QgsWkbTypes::Type geomType = QgsWkbTypes::Unknown;
|
||||||
|
@ -47,7 +47,6 @@ class GUI_EXPORT QgsNewMemoryLayerDialog: public QDialog, private Ui::QgsNewMemo
|
|||||||
* New dialog constructor.
|
* New dialog constructor.
|
||||||
*/
|
*/
|
||||||
QgsNewMemoryLayerDialog( QWidget *parent SIP_TRANSFERTHIS = nullptr, Qt::WindowFlags fl = QgsGuiUtils::ModalDialogFlags );
|
QgsNewMemoryLayerDialog( QWidget *parent SIP_TRANSFERTHIS = nullptr, Qt::WindowFlags fl = QgsGuiUtils::ModalDialogFlags );
|
||||||
~QgsNewMemoryLayerDialog() override;
|
|
||||||
|
|
||||||
//! Returns the selected geometry type
|
//! Returns the selected geometry type
|
||||||
QgsWkbTypes::Type selectedType() const;
|
QgsWkbTypes::Type selectedType() const;
|
||||||
|
@ -16,6 +16,7 @@
|
|||||||
#include "qgssublayersdialog.h"
|
#include "qgssublayersdialog.h"
|
||||||
#include "qgslogger.h"
|
#include "qgslogger.h"
|
||||||
#include "qgssettings.h"
|
#include "qgssettings.h"
|
||||||
|
#include "qgsgui.h"
|
||||||
|
|
||||||
#include <QTableWidgetItem>
|
#include <QTableWidgetItem>
|
||||||
#include <QPushButton>
|
#include <QPushButton>
|
||||||
@ -47,6 +48,7 @@ QgsSublayersDialog::QgsSublayersDialog( ProviderType providerType, const QString
|
|||||||
, mName( name )
|
, mName( name )
|
||||||
{
|
{
|
||||||
setupUi( this );
|
setupUi( this );
|
||||||
|
QgsGui::enableAutoGeometryRestore( this );
|
||||||
|
|
||||||
if ( providerType == QgsSublayersDialog::Ogr )
|
if ( providerType == QgsSublayersDialog::Ogr )
|
||||||
{
|
{
|
||||||
@ -75,9 +77,6 @@ QgsSublayersDialog::QgsSublayersDialog( ProviderType providerType, const QString
|
|||||||
connect( button, &QAbstractButton::pressed, layersTable, &QTreeView::selectAll );
|
connect( button, &QAbstractButton::pressed, layersTable, &QTreeView::selectAll );
|
||||||
// connect( pbnSelectNone, SIGNAL( pressed() ), SLOT( layersTable->selectNone() ) );
|
// connect( pbnSelectNone, SIGNAL( pressed() ), SLOT( layersTable->selectNone() ) );
|
||||||
|
|
||||||
QgsSettings settings;
|
|
||||||
restoreGeometry( settings.value( "/Windows/" + mName + "SubLayers/geometry" ).toByteArray() );
|
|
||||||
|
|
||||||
// Checkbox about adding sublayers to a group
|
// Checkbox about adding sublayers to a group
|
||||||
mCheckboxAddToGroup = new QCheckBox( tr( "Add layers to a group" ), this );
|
mCheckboxAddToGroup = new QCheckBox( tr( "Add layers to a group" ), this );
|
||||||
buttonBox->addButton( mCheckboxAddToGroup, QDialogButtonBox::ActionRole );
|
buttonBox->addButton( mCheckboxAddToGroup, QDialogButtonBox::ActionRole );
|
||||||
@ -87,7 +86,6 @@ QgsSublayersDialog::QgsSublayersDialog( ProviderType providerType, const QString
|
|||||||
QgsSublayersDialog::~QgsSublayersDialog()
|
QgsSublayersDialog::~QgsSublayersDialog()
|
||||||
{
|
{
|
||||||
QgsSettings settings;
|
QgsSettings settings;
|
||||||
settings.setValue( "/Windows/" + mName + "SubLayers/geometry", saveGeometry() );
|
|
||||||
settings.setValue( "/Windows/" + mName + "SubLayers/headerState",
|
settings.setValue( "/Windows/" + mName + "SubLayers/headerState",
|
||||||
layersTable->header()->saveState() );
|
layersTable->header()->saveState() );
|
||||||
}
|
}
|
||||||
|
@ -18,6 +18,8 @@
|
|||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
#include "qgssubstitutionlistwidget.h"
|
#include "qgssubstitutionlistwidget.h"
|
||||||
|
#include "qgsgui.h"
|
||||||
|
|
||||||
#include <QDialogButtonBox>
|
#include <QDialogButtonBox>
|
||||||
#include <QCheckBox>
|
#include <QCheckBox>
|
||||||
#include <QFileDialog>
|
#include <QFileDialog>
|
||||||
@ -28,6 +30,8 @@ QgsSubstitutionListWidget::QgsSubstitutionListWidget( QWidget *parent )
|
|||||||
: QgsPanelWidget( parent )
|
: QgsPanelWidget( parent )
|
||||||
{
|
{
|
||||||
setupUi( this );
|
setupUi( this );
|
||||||
|
QgsGui::enableAutoGeometryRestore( this );
|
||||||
|
|
||||||
connect( mButtonAdd, &QToolButton::clicked, this, &QgsSubstitutionListWidget::mButtonAdd_clicked );
|
connect( mButtonAdd, &QToolButton::clicked, this, &QgsSubstitutionListWidget::mButtonAdd_clicked );
|
||||||
connect( mButtonRemove, &QToolButton::clicked, this, &QgsSubstitutionListWidget::mButtonRemove_clicked );
|
connect( mButtonRemove, &QToolButton::clicked, this, &QgsSubstitutionListWidget::mButtonRemove_clicked );
|
||||||
connect( mButtonExport, &QToolButton::clicked, this, &QgsSubstitutionListWidget::mButtonExport_clicked );
|
connect( mButtonExport, &QToolButton::clicked, this, &QgsSubstitutionListWidget::mButtonExport_clicked );
|
||||||
|
@ -86,6 +86,7 @@ QgsRendererPropertiesDialog::QgsRendererPropertiesDialog( QgsVectorLayer *layer,
|
|||||||
|
|
||||||
{
|
{
|
||||||
setupUi( this );
|
setupUi( this );
|
||||||
|
QgsGui::enableAutoGeometryRestore( this );
|
||||||
mLayerRenderingGroupBox->setSettingGroup( QStringLiteral( "layerRenderingGroupBox" ) );
|
mLayerRenderingGroupBox->setSettingGroup( QStringLiteral( "layerRenderingGroupBox" ) );
|
||||||
|
|
||||||
// can be embedded in vector layer properties
|
// can be embedded in vector layer properties
|
||||||
|
@ -20,6 +20,7 @@
|
|||||||
#include "qgsgeometrychecker.h"
|
#include "qgsgeometrychecker.h"
|
||||||
#include "qgsfeaturepool.h"
|
#include "qgsfeaturepool.h"
|
||||||
#include "qgssettings.h"
|
#include "qgssettings.h"
|
||||||
|
#include "qgsgui.h"
|
||||||
|
|
||||||
#include <QCloseEvent>
|
#include <QCloseEvent>
|
||||||
#include <QVBoxLayout>
|
#include <QVBoxLayout>
|
||||||
@ -30,9 +31,7 @@ QgsGeometryCheckerDialog::QgsGeometryCheckerDialog( QgisInterface *iface, QWidge
|
|||||||
mIface = iface;
|
mIface = iface;
|
||||||
|
|
||||||
setWindowTitle( tr( "Check Geometries" ) );
|
setWindowTitle( tr( "Check Geometries" ) );
|
||||||
|
QgsGui::enableAutoGeometryRestore( this );
|
||||||
QgsSettings s;
|
|
||||||
restoreGeometry( s.value( QStringLiteral( "/Plugin-GeometryChecker/Window/geometry" ) ).toByteArray() );
|
|
||||||
|
|
||||||
mTabWidget = new QTabWidget();
|
mTabWidget = new QTabWidget();
|
||||||
mButtonBox = new QDialogButtonBox( QDialogButtonBox::Close | QDialogButtonBox::Help, Qt::Horizontal );
|
mButtonBox = new QDialogButtonBox( QDialogButtonBox::Close | QDialogButtonBox::Help, Qt::Horizontal );
|
||||||
@ -52,12 +51,6 @@ QgsGeometryCheckerDialog::QgsGeometryCheckerDialog( QgisInterface *iface, QWidge
|
|||||||
connect( dynamic_cast< QgsGeometryCheckerSetupTab * >( mTabWidget->widget( 0 ) ), &QgsGeometryCheckerSetupTab::checkerFinished, this, &QgsGeometryCheckerDialog::onCheckerFinished );
|
connect( dynamic_cast< QgsGeometryCheckerSetupTab * >( mTabWidget->widget( 0 ) ), &QgsGeometryCheckerSetupTab::checkerFinished, this, &QgsGeometryCheckerDialog::onCheckerFinished );
|
||||||
}
|
}
|
||||||
|
|
||||||
QgsGeometryCheckerDialog::~QgsGeometryCheckerDialog()
|
|
||||||
{
|
|
||||||
QgsSettings s;
|
|
||||||
s.setValue( QStringLiteral( "/Plugin-GeometryChecker/Window/geometry" ), saveGeometry() );
|
|
||||||
}
|
|
||||||
|
|
||||||
void QgsGeometryCheckerDialog::onCheckerStarted( QgsGeometryChecker *checker )
|
void QgsGeometryCheckerDialog::onCheckerStarted( QgsGeometryChecker *checker )
|
||||||
{
|
{
|
||||||
delete mTabWidget->widget( 1 );
|
delete mTabWidget->widget( 1 );
|
||||||
|
@ -34,7 +34,7 @@ class QgsGeometryCheckerDialog : public QDialog
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
public:
|
public:
|
||||||
QgsGeometryCheckerDialog( QgisInterface *iface, QWidget *parent = nullptr );
|
QgsGeometryCheckerDialog( QgisInterface *iface, QWidget *parent = nullptr );
|
||||||
~QgsGeometryCheckerDialog() override;
|
|
||||||
|
|
||||||
private:
|
private:
|
||||||
QgisInterface *mIface = nullptr;
|
QgisInterface *mIface = nullptr;
|
||||||
|
@ -18,17 +18,17 @@
|
|||||||
#include "qgssettings.h"
|
#include "qgssettings.h"
|
||||||
#include "qgsgeorefconfigdialog.h"
|
#include "qgsgeorefconfigdialog.h"
|
||||||
#include "qgis.h"
|
#include "qgis.h"
|
||||||
|
#include "qgsgui.h"
|
||||||
|
|
||||||
QgsGeorefConfigDialog::QgsGeorefConfigDialog( QWidget *parent )
|
QgsGeorefConfigDialog::QgsGeorefConfigDialog( QWidget *parent )
|
||||||
: QDialog( parent )
|
: QDialog( parent )
|
||||||
{
|
{
|
||||||
setupUi( this );
|
setupUi( this );
|
||||||
|
QgsGui::enableAutoGeometryRestore( this );
|
||||||
|
|
||||||
connect( buttonBox, &QDialogButtonBox::accepted, this, &QgsGeorefConfigDialog::buttonBox_accepted );
|
connect( buttonBox, &QDialogButtonBox::accepted, this, &QgsGeorefConfigDialog::buttonBox_accepted );
|
||||||
connect( buttonBox, &QDialogButtonBox::rejected, this, &QgsGeorefConfigDialog::buttonBox_rejected );
|
connect( buttonBox, &QDialogButtonBox::rejected, this, &QgsGeorefConfigDialog::buttonBox_rejected );
|
||||||
|
|
||||||
QgsSettings s;
|
|
||||||
restoreGeometry( s.value( QStringLiteral( "/Plugin-GeoReferencer/ConfigWindow/geometry" ) ).toByteArray() );
|
|
||||||
|
|
||||||
mPaperSizeComboBox->addItem( tr( "A5 (148x210 mm)" ), QSizeF( 148, 210 ) );
|
mPaperSizeComboBox->addItem( tr( "A5 (148x210 mm)" ), QSizeF( 148, 210 ) );
|
||||||
mPaperSizeComboBox->addItem( tr( "A4 (210x297 mm)" ), QSizeF( 210, 297 ) );
|
mPaperSizeComboBox->addItem( tr( "A4 (210x297 mm)" ), QSizeF( 210, 297 ) );
|
||||||
mPaperSizeComboBox->addItem( tr( "A3 (297x420 mm)" ), QSizeF( 297, 420 ) );
|
mPaperSizeComboBox->addItem( tr( "A3 (297x420 mm)" ), QSizeF( 297, 420 ) );
|
||||||
@ -58,12 +58,6 @@ QgsGeorefConfigDialog::QgsGeorefConfigDialog( QWidget *parent )
|
|||||||
readSettings();
|
readSettings();
|
||||||
}
|
}
|
||||||
|
|
||||||
QgsGeorefConfigDialog::~QgsGeorefConfigDialog()
|
|
||||||
{
|
|
||||||
QgsSettings settings;
|
|
||||||
settings.setValue( QStringLiteral( "/Plugin-GeoReferencer/ConfigWindow/geometry" ), saveGeometry() );
|
|
||||||
}
|
|
||||||
|
|
||||||
void QgsGeorefConfigDialog::changeEvent( QEvent *e )
|
void QgsGeorefConfigDialog::changeEvent( QEvent *e )
|
||||||
{
|
{
|
||||||
QDialog::changeEvent( e );
|
QDialog::changeEvent( e );
|
||||||
|
@ -23,7 +23,6 @@ class QgsGeorefConfigDialog : public QDialog, private Ui::QgsGeorefConfigDialogB
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
public:
|
public:
|
||||||
explicit QgsGeorefConfigDialog( QWidget *parent = nullptr );
|
explicit QgsGeorefConfigDialog( QWidget *parent = nullptr );
|
||||||
~QgsGeorefConfigDialog() override;
|
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
void changeEvent( QEvent *e ) override;
|
void changeEvent( QEvent *e ) override;
|
||||||
|
@ -20,6 +20,7 @@
|
|||||||
#include "qgsmapcoordsdialog.h"
|
#include "qgsmapcoordsdialog.h"
|
||||||
#include "qgssettings.h"
|
#include "qgssettings.h"
|
||||||
#include "qgsmapmouseevent.h"
|
#include "qgsmapmouseevent.h"
|
||||||
|
#include "qgsgui.h"
|
||||||
|
|
||||||
QgsMapCoordsDialog::QgsMapCoordsDialog( QgsMapCanvas *qgisCanvas, const QgsPointXY &pixelCoords, QWidget *parent )
|
QgsMapCoordsDialog::QgsMapCoordsDialog( QgsMapCanvas *qgisCanvas, const QgsPointXY &pixelCoords, QWidget *parent )
|
||||||
: QDialog( parent, Qt::Dialog )
|
: QDialog( parent, Qt::Dialog )
|
||||||
@ -27,10 +28,9 @@ QgsMapCoordsDialog::QgsMapCoordsDialog( QgsMapCanvas *qgisCanvas, const QgsPoint
|
|||||||
, mPixelCoords( pixelCoords )
|
, mPixelCoords( pixelCoords )
|
||||||
{
|
{
|
||||||
setupUi( this );
|
setupUi( this );
|
||||||
connect( buttonBox, &QDialogButtonBox::accepted, this, &QgsMapCoordsDialog::buttonBox_accepted );
|
QgsGui::enableAutoGeometryRestore( this );
|
||||||
|
|
||||||
QgsSettings s;
|
connect( buttonBox, &QDialogButtonBox::accepted, this, &QgsMapCoordsDialog::buttonBox_accepted );
|
||||||
restoreGeometry( s.value( QStringLiteral( "/Plugin-GeoReferencer/MapCoordsWindow/geometry" ) ).toByteArray() );
|
|
||||||
|
|
||||||
setAttribute( Qt::WA_DeleteOnClose );
|
setAttribute( Qt::WA_DeleteOnClose );
|
||||||
|
|
||||||
@ -46,7 +46,8 @@ QgsMapCoordsDialog::QgsMapCoordsDialog( QgsMapCanvas *qgisCanvas, const QgsPoint
|
|||||||
mToolEmitPoint = new QgsGeorefMapToolEmitPoint( qgisCanvas );
|
mToolEmitPoint = new QgsGeorefMapToolEmitPoint( qgisCanvas );
|
||||||
mToolEmitPoint->setButton( mPointFromCanvasPushButton );
|
mToolEmitPoint->setButton( mPointFromCanvasPushButton );
|
||||||
|
|
||||||
mMinimizeWindowCheckBox->setChecked( s.value( QStringLiteral( "/Plugin-GeoReferencer/Config/Minimize" ), QStringLiteral( "1" ) ).toBool() );
|
QgsSettings settings;
|
||||||
|
mMinimizeWindowCheckBox->setChecked( settings.value( QStringLiteral( "/Plugin-GeoReferencer/Config/Minimize" ), QStringLiteral( "1" ) ).toBool() );
|
||||||
|
|
||||||
connect( mPointFromCanvasPushButton, &QAbstractButton::clicked, this, &QgsMapCoordsDialog::setToolEmitPoint );
|
connect( mPointFromCanvasPushButton, &QAbstractButton::clicked, this, &QgsMapCoordsDialog::setToolEmitPoint );
|
||||||
|
|
||||||
@ -64,7 +65,6 @@ QgsMapCoordsDialog::~QgsMapCoordsDialog()
|
|||||||
delete mToolEmitPoint;
|
delete mToolEmitPoint;
|
||||||
|
|
||||||
QgsSettings settings;
|
QgsSettings settings;
|
||||||
settings.setValue( QStringLiteral( "/Plugin-GeoReferencer/MapCoordsWindow/geometry" ), saveGeometry() );
|
|
||||||
settings.setValue( QStringLiteral( "/Plugin-GeoReferencer/Config/Minimize" ), mMinimizeWindowCheckBox->isChecked() );
|
settings.setValue( QStringLiteral( "/Plugin-GeoReferencer/Config/Minimize" ), mMinimizeWindowCheckBox->isChecked() );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -27,6 +27,7 @@
|
|||||||
#include "qgsvectorlayer.h"
|
#include "qgsvectorlayer.h"
|
||||||
#include "qgssettings.h"
|
#include "qgssettings.h"
|
||||||
#include "qgsapplication.h"
|
#include "qgsapplication.h"
|
||||||
|
#include "qgsgui.h"
|
||||||
|
|
||||||
#include <QFileDialog>
|
#include <QFileDialog>
|
||||||
#include <QMessageBox>
|
#include <QMessageBox>
|
||||||
@ -99,6 +100,8 @@ QgsOfflineEditingPluginGui::QgsOfflineEditingPluginGui( QWidget *parent, Qt::Win
|
|||||||
: QDialog( parent, fl )
|
: QDialog( parent, fl )
|
||||||
{
|
{
|
||||||
setupUi( this );
|
setupUi( this );
|
||||||
|
QgsGui::enableAutoGeometryRestore( this );
|
||||||
|
|
||||||
connect( mBrowseButton, &QPushButton::clicked, this, &QgsOfflineEditingPluginGui::mBrowseButton_clicked );
|
connect( mBrowseButton, &QPushButton::clicked, this, &QgsOfflineEditingPluginGui::mBrowseButton_clicked );
|
||||||
connect( buttonBox, &QDialogButtonBox::accepted, this, &QgsOfflineEditingPluginGui::buttonBox_accepted );
|
connect( buttonBox, &QDialogButtonBox::accepted, this, &QgsOfflineEditingPluginGui::buttonBox_accepted );
|
||||||
connect( buttonBox, &QDialogButtonBox::rejected, this, &QgsOfflineEditingPluginGui::buttonBox_rejected );
|
connect( buttonBox, &QDialogButtonBox::rejected, this, &QgsOfflineEditingPluginGui::buttonBox_rejected );
|
||||||
@ -122,7 +125,6 @@ QgsOfflineEditingPluginGui::QgsOfflineEditingPluginGui( QWidget *parent, Qt::Win
|
|||||||
QgsOfflineEditingPluginGui::~QgsOfflineEditingPluginGui()
|
QgsOfflineEditingPluginGui::~QgsOfflineEditingPluginGui()
|
||||||
{
|
{
|
||||||
QgsSettings settings;
|
QgsSettings settings;
|
||||||
settings.setValue( QStringLiteral( "OfflineEditing/geometry" ), saveGeometry(), QgsSettings::Section::Plugins );
|
|
||||||
settings.setValue( QStringLiteral( "OfflineEditing/offline_data_path" ), mOfflineDataPath, QgsSettings::Section::Plugins );
|
settings.setValue( QStringLiteral( "OfflineEditing/offline_data_path" ), mOfflineDataPath, QgsSettings::Section::Plugins );
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -246,7 +248,6 @@ void QgsOfflineEditingPluginGui::restoreState()
|
|||||||
{
|
{
|
||||||
QgsSettings settings;
|
QgsSettings settings;
|
||||||
mOfflineDataPath = settings.value( QStringLiteral( "OfflineEditing/offline_data_path" ), QDir::homePath(), QgsSettings::Section::Plugins ).toString();
|
mOfflineDataPath = settings.value( QStringLiteral( "OfflineEditing/offline_data_path" ), QDir::homePath(), QgsSettings::Section::Plugins ).toString();
|
||||||
restoreGeometry( settings.value( QStringLiteral( "OfflineEditing/geometry" ), QgsSettings::Section::Plugins ).toByteArray() );
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void QgsOfflineEditingPluginGui::selectAll()
|
void QgsOfflineEditingPluginGui::selectAll()
|
||||||
|
@ -23,6 +23,7 @@
|
|||||||
#include "qgslogger.h"
|
#include "qgslogger.h"
|
||||||
#include "qgsdockwidget.h"
|
#include "qgsdockwidget.h"
|
||||||
#include "qgssettings.h"
|
#include "qgssettings.h"
|
||||||
|
#include "qgsgui.h"
|
||||||
#include "layertree/qgslayertreeview.h"
|
#include "layertree/qgslayertreeview.h"
|
||||||
|
|
||||||
#include <QMainWindow>
|
#include <QMainWindow>
|
||||||
@ -35,6 +36,7 @@ QgsTileScaleWidget::QgsTileScaleWidget( QgsMapCanvas *mapCanvas, QWidget *parent
|
|||||||
, mMapCanvas( mapCanvas )
|
, mMapCanvas( mapCanvas )
|
||||||
{
|
{
|
||||||
setupUi( this );
|
setupUi( this );
|
||||||
|
QgsGui::enableAutoGeometryRestore( this );
|
||||||
|
|
||||||
connect( mSlider, &QSlider::valueChanged, this, &QgsTileScaleWidget::mSlider_valueChanged );
|
connect( mSlider, &QSlider::valueChanged, this, &QgsTileScaleWidget::mSlider_valueChanged );
|
||||||
connect( mMapCanvas, &QgsMapCanvas::scaleChanged, this, &QgsTileScaleWidget::scaleChanged );
|
connect( mMapCanvas, &QgsMapCanvas::scaleChanged, this, &QgsTileScaleWidget::scaleChanged );
|
||||||
|
@ -37,6 +37,7 @@
|
|||||||
#include "qgswmscapabilities.h"
|
#include "qgswmscapabilities.h"
|
||||||
#include "qgsapplication.h"
|
#include "qgsapplication.h"
|
||||||
#include "qgssettings.h"
|
#include "qgssettings.h"
|
||||||
|
#include "qgsgui.h"
|
||||||
|
|
||||||
#include <QButtonGroup>
|
#include <QButtonGroup>
|
||||||
#include <QFileDialog>
|
#include <QFileDialog>
|
||||||
@ -58,6 +59,8 @@ QgsWMSSourceSelect::QgsWMSSourceSelect( QWidget *parent, Qt::WindowFlags fl, Qgs
|
|||||||
, mDefaultCRS( GEO_EPSG_CRS_AUTHID )
|
, mDefaultCRS( GEO_EPSG_CRS_AUTHID )
|
||||||
{
|
{
|
||||||
setupUi( this );
|
setupUi( this );
|
||||||
|
QgsGui::enableAutoGeometryRestore( this );
|
||||||
|
|
||||||
connect( btnNew, &QPushButton::clicked, this, &QgsWMSSourceSelect::btnNew_clicked );
|
connect( btnNew, &QPushButton::clicked, this, &QgsWMSSourceSelect::btnNew_clicked );
|
||||||
connect( btnEdit, &QPushButton::clicked, this, &QgsWMSSourceSelect::btnEdit_clicked );
|
connect( btnEdit, &QPushButton::clicked, this, &QgsWMSSourceSelect::btnEdit_clicked );
|
||||||
connect( btnDelete, &QPushButton::clicked, this, &QgsWMSSourceSelect::btnDelete_clicked );
|
connect( btnDelete, &QPushButton::clicked, this, &QgsWMSSourceSelect::btnDelete_clicked );
|
||||||
@ -144,17 +147,8 @@ QgsWMSSourceSelect::QgsWMSSourceSelect( QWidget *parent, Qt::WindowFlags fl, Qgs
|
|||||||
// set up the WMS connections we already know about
|
// set up the WMS connections we already know about
|
||||||
populateConnectionList();
|
populateConnectionList();
|
||||||
|
|
||||||
QgsSettings settings;
|
|
||||||
QgsDebugMsg( QStringLiteral( "restoring geometry" ) );
|
|
||||||
restoreGeometry( settings.value( QStringLiteral( "Windows/WMSSourceSelect/geometry" ) ).toByteArray() );
|
|
||||||
}
|
}
|
||||||
|
|
||||||
QgsWMSSourceSelect::~QgsWMSSourceSelect()
|
|
||||||
{
|
|
||||||
QgsSettings settings;
|
|
||||||
QgsDebugMsg( QStringLiteral( "saving geometry" ) );
|
|
||||||
settings.setValue( QStringLiteral( "Windows/WMSSourceSelect/geometry" ), saveGeometry() );
|
|
||||||
}
|
|
||||||
|
|
||||||
void QgsWMSSourceSelect::refresh()
|
void QgsWMSSourceSelect::refresh()
|
||||||
{
|
{
|
||||||
|
@ -51,8 +51,6 @@ class QgsWMSSourceSelect : public QgsAbstractDataSourceWidget, private Ui::QgsWM
|
|||||||
//! Constructor
|
//! Constructor
|
||||||
QgsWMSSourceSelect( QWidget *parent = nullptr, Qt::WindowFlags fl = QgsGuiUtils::ModalDialogFlags, QgsProviderRegistry::WidgetMode widgetMode = QgsProviderRegistry::WidgetMode::None );
|
QgsWMSSourceSelect( QWidget *parent = nullptr, Qt::WindowFlags fl = QgsGuiUtils::ModalDialogFlags, QgsProviderRegistry::WidgetMode widgetMode = QgsProviderRegistry::WidgetMode::None );
|
||||||
|
|
||||||
~QgsWMSSourceSelect() override;
|
|
||||||
|
|
||||||
public slots:
|
public slots:
|
||||||
|
|
||||||
//! Triggered when the provider's connections need to be refreshed
|
//! Triggered when the provider's connections need to be refreshed
|
||||||
|
@ -18,6 +18,7 @@
|
|||||||
#include "qgswmsprovider.h"
|
#include "qgswmsprovider.h"
|
||||||
#include "qgswmtsdimensions.h"
|
#include "qgswmtsdimensions.h"
|
||||||
#include "qgssettings.h"
|
#include "qgssettings.h"
|
||||||
|
#include "qgsgui.h"
|
||||||
|
|
||||||
#include <QComboBox>
|
#include <QComboBox>
|
||||||
|
|
||||||
@ -46,17 +47,7 @@ QgsWmtsDimensions::QgsWmtsDimensions( const QgsWmtsTileLayer &layer, QWidget *pa
|
|||||||
cb->setCurrentIndex( idx < 0 ? 0 : idx );
|
cb->setCurrentIndex( idx < 0 ? 0 : idx );
|
||||||
mDimensions->setCellWidget( i, 4, cb );
|
mDimensions->setCellWidget( i, 4, cb );
|
||||||
}
|
}
|
||||||
|
QgsGui::enableAutoGeometryRestore( this );
|
||||||
QgsSettings settings;
|
|
||||||
QgsDebugMsg( QStringLiteral( "restoring geometry" ) );
|
|
||||||
restoreGeometry( settings.value( QStringLiteral( "Windows/WMTSDimensions/geometry" ) ).toByteArray() );
|
|
||||||
}
|
|
||||||
|
|
||||||
QgsWmtsDimensions::~QgsWmtsDimensions()
|
|
||||||
{
|
|
||||||
QgsSettings settings;
|
|
||||||
QgsDebugMsg( QStringLiteral( "saving geometry" ) );
|
|
||||||
settings.setValue( QStringLiteral( "Windows/WmtsDimensions/geometry" ), saveGeometry() );
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void QgsWmtsDimensions::selectedDimensions( QHash<QString, QString> &selected )
|
void QgsWmtsDimensions::selectedDimensions( QHash<QString, QString> &selected )
|
||||||
|
@ -38,8 +38,6 @@ class QgsWmtsDimensions : public QDialog, private Ui::QgsWmtsDimensionsBase
|
|||||||
//! Constructor
|
//! Constructor
|
||||||
QgsWmtsDimensions( const QgsWmtsTileLayer &layer, QWidget *parent = nullptr, Qt::WindowFlags fl = nullptr );
|
QgsWmtsDimensions( const QgsWmtsTileLayer &layer, QWidget *parent = nullptr, Qt::WindowFlags fl = nullptr );
|
||||||
|
|
||||||
~QgsWmtsDimensions() override;
|
|
||||||
|
|
||||||
void selectedDimensions( QHash<QString, QString> &dims );
|
void selectedDimensions( QHash<QString, QString> &dims );
|
||||||
|
|
||||||
};
|
};
|
||||||
|
@ -15,11 +15,13 @@
|
|||||||
|
|
||||||
#include "qgsxyzconnectiondialog.h"
|
#include "qgsxyzconnectiondialog.h"
|
||||||
#include "qgsxyzconnection.h"
|
#include "qgsxyzconnection.h"
|
||||||
|
#include "qgsgui.h"
|
||||||
|
|
||||||
QgsXyzConnectionDialog::QgsXyzConnectionDialog( QWidget *parent )
|
QgsXyzConnectionDialog::QgsXyzConnectionDialog( QWidget *parent )
|
||||||
: QDialog( parent )
|
: QDialog( parent )
|
||||||
{
|
{
|
||||||
setupUi( this );
|
setupUi( this );
|
||||||
|
QgsGui::enableAutoGeometryRestore( this );
|
||||||
|
|
||||||
// Behavior for min and max zoom checkbox
|
// Behavior for min and max zoom checkbox
|
||||||
connect( mCheckBoxZMin, &QCheckBox::toggled, mSpinZMin, &QSpinBox::setEnabled );
|
connect( mCheckBoxZMin, &QCheckBox::toggled, mSpinZMin, &QSpinBox::setEnabled );
|
||||||
|
Loading…
x
Reference in New Issue
Block a user