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

Save as native file dialog pops when enabling auto-save on a temp sketch #994

Closed
3 tasks done
kittaakos opened this issue May 19, 2022 · 1 comment · Fixed by #1351
Closed
3 tasks done

Save as native file dialog pops when enabling auto-save on a temp sketch #994

kittaakos opened this issue May 19, 2022 · 1 comment · Fixed by #1351
Assignees
Labels
conclusion: resolved Issue was resolved topic: code Related to content of the project itself type: imperfection Perceived defect in any part of project

Comments

@kittaakos
Copy link
Contributor

Describe the problem

When I disable the auto-save, then enable it in a temp sketch, then the native save as file dialog pops. I think it should not.

A temp sketch is a sketch that is not saved to directories#user location.

To reproduce

  • Open a new sketch but do not touch it!
  • Open settings and make sure auto-save is disabled.
  • Enter one space to the end of the file.
  • Open settings and enable auto-save.
  • Hit OK.
  • Native file dialog pops.

Expected behavior

It should not. IDE2 should know it's a temp sketch and should not prompt the save as dialog.

Problem: by default, Theia saves the editor when this setting/preference is changed, and the new auto-save value "is enabled".

Arduino IDE version

Version: 2.0.0-rc6-nightly-20220519 Date: 2022-05-19T03:30:29.656Z CLI Version: 0.21.0 [10107d24] Copyright © 2022 Arduino SA

Operating system

macOS

Operating system version

12.3.1 (21E258)

Additional context

No response

Issue checklist

  • I searched for previous reports in the issue tracker
  • I verified the problem still occurs when using the latest nightly build
  • My report contains all necessary details
@kittaakos kittaakos added type: imperfection Perceived defect in any part of project topic: code Related to content of the project itself labels May 19, 2022
@per1234
Copy link
Contributor

per1234 commented May 27, 2022

Since I see from this that the appearance of the dialog at all at this time is not intended, I decided it was not worth creating a separate issue, but I discovered that the behavior was worsened by 522a5c6.

At this step:

  • Native file dialog pops.

you now get seven "Save sketch folder as..." dialogs. I get this on my Windows 10 and Ubuntu 20.04 machines.

With the builds for b8c718c and previous, I only get one of those dialogs.

I checked other operations that result in an expected "Save sketch folder as..." dialog, and only got the expected single dialog, so I think the multiple dialogs issue is isolated to this specific operation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
conclusion: resolved Issue was resolved topic: code Related to content of the project itself type: imperfection Perceived defect in any part of project
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants