Alternative approach to f9fcee9

Which should also work when QgsAttributeDialog is called with ownsFeature=false