Show scrollbars for attribute form as identify results

This commit is contained in:
Nyall Dawson 2016-06-09 13:28:56 +10:00
parent b44f62a1c2
commit ce7d79e495
2 changed files with 4 additions and 1 deletions

View File

@ -59,6 +59,7 @@ QgsAttributeDialog *QgsFeatureAction::newDialog( bool cloneFeature )
context.setDistanceArea( myDa );
context.setVectorLayerTools( QgisApp::instance()->vectorLayerTools() );
context.setFormMode( QgsAttributeEditorContext::StandaloneDialog );
QgsAttributeDialog *dialog = new QgsAttributeDialog( mLayer, f, cloneFeature, nullptr, true, context );

View File

@ -108,8 +108,10 @@ void QgsAttributeDialog::init( QgsVectorLayer* layer, QgsFeature* feature, const
layout()->setMargin( 0 );
mTrackedVectorLayerTools.setVectorLayerTools( trackedContext.vectorLayerTools() );
trackedContext.setVectorLayerTools( &mTrackedVectorLayerTools );
if ( showDialogButtons )
trackedContext.setFormMode( QgsAttributeEditorContext::StandaloneDialog );
mAttributeForm = new QgsAttributeForm( layer, *feature, trackedContext, this, !showDialogButtons );
mAttributeForm = new QgsAttributeForm( layer, *feature, trackedContext, this );
mAttributeForm->disconnectButtonBox();
layout()->addWidget( mAttributeForm );
QDialogButtonBox* buttonBox = mAttributeForm->findChild<QDialogButtonBox*>();