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

wlr-taskbar: allow sorting by app_id #1932

Merged
merged 1 commit into from
Apr 3, 2023

Conversation

ldelossa
Copy link
Contributor

some users (maybe only myself) may want to sort the task bar by app_id which then places occurrences of the same task next to each other.

there is an alternative method to do this, making TaskBar's tasks_ vector public, and having each Task find itself in tbar_->tasks_ and setting their button in the right place, but it "feels" better to have TaskBar decide to place where its Task(s) should be within itself.

Signed-off-by: Louis DeLosSantos louis.delos@gmail.com

@@ -40,6 +40,8 @@ class Task {
FULLSCREEN = (1 << 3),
INVALID = (1 << 4)
};
// made public so TaskBar can reorder based on configuration.
Gtk::Button button_;
Copy link
Owner

Choose a reason for hiding this comment

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

button_ really need to be public?
If yes please remove the _ :)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Button on this Task class needs to be public or else TaskBar class cannot access it to sort and move the button.

There is an alternative way which I mention in the PR comments, but I thought this was cleaner.

Ill remove the underscore as well, missed that.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

updated.

@ldelossa ldelossa force-pushed the wlr-taskbar-sort-app-id branch 2 times, most recently from 498e7f1 to 9bcb08c Compare January 28, 2023 17:04
@ldelossa
Copy link
Contributor Author

@Alexays fixed linting errors.

@ldelossa
Copy link
Contributor Author

@Alexays do you think this is OK to merge ?

@Alexays
Copy link
Owner

Alexays commented Mar 1, 2023

Sorry again for the delay, your branch seems broken, can you rebase it on master?

some users (maybe only myself) may want to sort the task bar by app_id
which then places occurrences of the same task next to each other.

Signed-off-by: Louis DeLosSantos <louis.delos@gmail.com>
@ldelossa
Copy link
Contributor Author

ldelossa commented Mar 1, 2023

@Alexays no worries at all, rebased.

@Alexays Alexays merged commit ef99b02 into Alexays:master Apr 3, 2023
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.

2 participants