PowerToys icon indicating copy to clipboard operation
PowerToys copied to clipboard

[File Locksmith] Add infobar when not running as admin

Open HydroH opened this issue 2 years ago • 1 comments

Summary of the Pull Request

PR Checklist

  • [x] Closes: #21805
  • [ ] Communication: I've discussed this with core contributors already. If work hasn't been agreed, this work might be rejected
  • [ ] Tests: Added/updated and all pass
  • [x] Localization: All end user facing strings can be localized
  • [ ] Dev docs: Added/updated
  • [ ] New binaries: Added on the required places
  • [ ] Documentation updated: If checked, please file a pull request on our docs repo and link it here: #xxx

Detailed Description of the Pull Request / Additional comments

Validation Steps Performed

HydroH avatar Jan 17 '24 04:01 HydroH

Would be extra nice to have a "Restart as admin" button somewhere here :⁠-⁠)

It exists in the ui. At the top where the reload button is.

htcfreek avatar Jan 17 '24 17:01 htcfreek

Thanks for opening the PR. I've tried running the PR in both Debug and release, but both are crashing for me when trying to start File Locksmith.

I can replicate this problem when running from a clean build at the first time, but it does not crash in subsequent runs. Did a couple of tests, crash happens as long as a Infobar is present. Seems to be related to this issue: https://github.com/microsoft/microsoft-ui-xaml/issues/7143

HydroH avatar Jan 24 '24 14:01 HydroH

Thanks for opening the PR. I've tried running the PR in both Debug and release, but both are crashing for me when trying to start File Locksmith.

I can replicate this problem when running from a clean build at the first time, but it does not crash in subsequent runs. Did a couple of tests, crash happens as long as a Infobar is present. Seems to be related to this issue: microsoft/microsoft-ui-xaml#7143

Thank for looking into it. Seems related, although we're not using the mentioned flags: IncludeNativeLibrariesForSelfExtract or PublishSingleFile

Definitely can't bring it in if it's causing crashes, though. Regarding the change itself, can you please share some screenshots? I'm thinking this will look a bit big in the UI.

jaimecbernardo avatar Jan 25 '24 10:01 jaimecbernardo

Thanks for opening the PR. I've tried running the PR in both Debug and release, but both are crashing for me when trying to start File Locksmith.

I can replicate this problem when running from a clean build at the first time, but it does not crash in subsequent runs. Did a couple of tests, crash happens as long as a Infobar is present. Seems to be related to this issue: microsoft/microsoft-ui-xaml#7143

Thank for looking into it. Seems related, although we're not using the mentioned flags: IncludeNativeLibrariesForSelfExtract or PublishSingleFile

Definitely can't bring it in if it's causing crashes, though. Regarding the change itself, can you please share some screenshots? I'm thinking this will look a bit big in the UI.

This is how it looks currently. image

Maybe putting the restart as admin button in the infobar would be better? image

HydroH avatar Jan 26 '24 02:01 HydroH

@HydroH Yes. Please move the button. But then we should use a text instead of a symbol, I think.

htcfreek avatar Jan 26 '24 05:01 htcfreek

@HydroH Yes. Please move the button. But then we should use a text instead of a symbol, I think.

Sorry for responding late, I was on a holiday. This is what it looks like now. image

But I think this PR is blocked by the infobar issue at the moment.

HydroH avatar Feb 17 '24 07:02 HydroH

I know it's kinda late, but I think a Popup control might be even better: you can connect it to the existing restart-as-admin button. And it's just as intrusive as an info bar.

Jay-o-Way avatar Feb 18 '24 22:02 Jay-o-Way