-
Notifications
You must be signed in to change notification settings - Fork 899
feat: Add option to disable CloudProviders sidebar integration #9233
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
base: master
Are you sure you want to change the base?
feat: Add option to disable CloudProviders sidebar integration #9233
Conversation
Adds a new setting in General preferences to control whether synchronized folders appear in the file manager sidebar via CloudProviders on Linux. Changes: - Add 'showCloudProvidersInFileManager' config setting (defaults to true) - Add checkbox in General Settings UI (Linux only) - Check setting during CloudProviderManager initialization - Skip DBus registration when disabled The setting requires application restart to take effect. Signed-off-by: eriolloan <15250783+eriolloan@users.noreply.github.com>
3d821a7 to
cc8a441
Compare
| OCC::ConfigFile cfg; | ||
| if (!cfg.showCloudProvidersInFileManager()) { | ||
| qCInfo(lcNextcloudCloudProviderIntegration) << "CloudProviders disabled by user setting"; | ||
| return; | ||
| } | ||
|
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it makes more sense to move this logic to application.cpp, do the check before calling ownCloudGui::setupCloudProviders:
desktop/src/gui/application.cpp
Line 408 in a514416
| _gui->setupCloudProviders(); |
| void GeneralSettings::slotToggleCloudProviders(bool checked) | ||
| { | ||
| ConfigFile cfgFile; | ||
| cfgFile.setShowCloudProvidersInFileManager(checked); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
beyond changing the config file, you need to call here ownCloudGui::setupCloudProviders (I could be wrong, maybe another function), so the change will take effect without restarting the client.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks I'll look into it tomorrow
Moves the setting check from CloudProviderManager constructor to Application startup, following the suggestion to check before calling setupCloudProviders rather than inside the manager itself. This keeps the initialization logic cleaner and more consistent with how other optional components are handled. Signed-off-by: eriolloan <15250783+eriolloan@users.noreply.github.com>
|
Thanks for the review! I've moved the check to application.cpp. Regarding making the toggle take effect without restart - I looked into this and ran into a few complications. Tell me if I'm mistaken but it looks like :
Is keeping the restart requirement acceptable for now? The tooltip does mention it's needed. |
Thanks for the PR. We discussed your changes in the team and I am afraid I didn't realize the implications of your changes when I first reviewed it. So we would like to propose the following:
I think you can leave this as it is now.
Given that now it would require to change the config file by hand, then items 2 and 3 are not a concern anymore. I hope this proposal is OK with you :) |
|
Thanks for discussing this with the team! I'm happy to make the changes you suggest. Before I do though, I'd like to share some context on why I thought a UI option would be valuable: The problem affects several user groups:
There are existing reports of this issue: issue #3361 (from 2021, still open) and I found myself in a combination of some of these situations, prompting the PR. That said, I fully understand the concern about UI clutter for a niche feature. |
|
Hello there, We hope that the review process is going smooth and is helpful for you. We want to ensure your pull request is reviewed to your satisfaction. If you have a moment, our community management team would very much appreciate your feedback on your experience with this PR review process. Your feedback is valuable to us as we continuously strive to improve our community developer experience. Please take a moment to complete our short survey by clicking on the following link: https://cloud.nextcloud.com/apps/forms/s/i9Ago4EQRZ7TWxjfmeEpPkf6 Thank you for contributing to Nextcloud and we hope to hear from you soon! (If you believe you should not receive this message, you can add yourself to the blocklist.) |
Summary
Adds a new user setting to optionally disable CloudProviders D-Bus integration on Linux, allowing users to hide synchronized folders from the file manager sidebar while keeping sync functionality intact.
Changes
Implementation details
showCloudProvidersInFileManager(defaults totrue)#ifndef Q_OS_LINUX)CloudProviderManagerconstructor when disabledTesting
Screenshot
Related issues
Fixes #1982