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

Fix Save for external ressource dialog RelativeStorage config parameter #45072

Merged
merged 2 commits into from
Sep 17, 2021

Conversation

troopa81
Copy link
Contributor

Fixes #44799 : When clicking on "ok" button, mRelativeGroupBox is not visible because its parent is not visible anymore. This PR changes the condition so it works all the time

@github-actions github-actions bot added this to the 3.22.0 milestone Sep 15, 2021
@troopa81 troopa81 added the Bug Either a bug report, or a bug fix. Let's hope for the latter! label Sep 15, 2021
@domi4484
Copy link
Contributor

cfg.insert( QStringLiteral( "StorageMode" ), mStorageModeGroupBox->isVisible() ?
here isVisible is also used as condition. Is that not a little dangerous to? would it maybe be better to use the combo box index instead?
btw. thank you for the fix!

@troopa81
Copy link
Contributor Author

here isVisible is also used as condition. Is that not a little dangerous to? would it maybe be better to use the combo box index instead?

Yes, you're right. Done

@nyalldawson
Copy link
Collaborator

@troopa81

here isVisible is also used as condition. Is that not a little dangerous to? would it maybe be better to use the combo box index instead?

Just to expand on this -- we've had issues when people have used isVisible() for this kind of thing before because that will always be FALSE when the dialog is saving properties as a result of it being closed!

@nyalldawson nyalldawson merged commit 770efa3 into qgis:master Sep 17, 2021
@nyalldawson
Copy link
Collaborator

(it'd be valuable to do a scan on other uses of isVisible throughout the codebase to see if other widget properties are using this too!)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Either a bug report, or a bug fix. Let's hope for the latter!
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Regression attachment widget can't set "Relative paths"
3 participants