Skip to content

feat(Group/Drawer): add dynamic drawer hiding modules based on module's class #4014

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

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

piwonskp
Copy link

@piwonskp piwonskp commented Mar 30, 2025

Closes #4008

Add `always-visible-class` to config.
Update the drawer on `hide_group`.
…stantly on module update using dynamic signal handling.

Improve performance - manage the visibility of updated module only instead of iterating over all modules on `hide_group`.
@@ -95,6 +95,7 @@ auto AModule::update() -> void {
if (config_["on-update"].isString()) {
pid_.push_back(util::command::forkExec(config_["on-update"].asString()));
}
signal_updated.emit(this);
Copy link
Author

@piwonskp piwonskp Apr 2, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It means that every module will emit an update signal.

An alternative solution is to wrap (before calling group->addWidget(module)) only the modules belonging to groups in a class that emits update signals, or limit it to those in dynamic drawers. This would limit signal emitting to dynamic-drawers and minimize the performance overhead on other modules to the bare minimum.

Depends on whether other modules could also benefit from update signaling.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Group/Drawer][Feature] Dynamic hiding of drawer modules based on a class
1 participant