panel: Add outputs option for per-output configuration#356
Conversation
3ebfb21 to
1c42542
Compare
1c42542 to
d7bdf58
Compare
src/panel/panel.cpp
Outdated
| public: | ||
| std::map<WayfireOutput*, std::unique_ptr<WayfirePanel>> panels; | ||
| std::map<std::string, WayfireOutput*> outputs; | ||
| WfOption<std::string> *panel_outputs; |
There was a problem hiding this comment.
Having this dynamically allocated seems really weird, if you need to load an option at runtime, you can use .load_option(<option name>)
There was a problem hiding this comment.
Sounds like this might work.
There was a problem hiding this comment.
Well this sounded good but I was not able to get load_option() working to help here. Maybe I am using it wrong.
d7bdf58 to
062b869
Compare
|
Sorry, I've read through it. I currently don't know where I stand on the conversation but wonder why you're specifically avoiding doing this in shell-app. |
@trigg Thanks for looking. It is not the case that I set out with the intent to only touch panel.cpp, it's just the way the patch turned out. After I had it working, I noticed the only thing I had in wf-shell-app.hpp was moving the monitors list from private to public, and I never used it, in favor of the more convenient std::map that I'd installed. I will have another look to see if using the existing monitors list is doable and get rid of the extra std::map though, if that's what you're expecting. |
062b869 to
52e4fe9
Compare
|
Before suggested changes: 2 files changed, 102 insertions(+), 2 deletions(-) Ca ne fait rien. 😀 EDIT: Adjusted to use std::find_if instead of a loop for checking if panel exists. |
678d6be to
b930855
Compare
This adds a new option named 'outputs' that is a list of output names on which a panel instance should be rendered. The default value is '*' wildcard, which means all outputs.
b930855 to
aeea5d7
Compare
35b67d5 to
b0576d5
Compare
735f409 to
97718e0
Compare
97718e0 to
105e581
Compare
trigg
left a comment
There was a problem hiding this comment.
My read through looks like the loops can be merged. Otherwise very happy with this, and if you're sure of yourself just merge this :)
Thanks to trigg for realizing this simplification.
This adds a new option named 'outputs' that is a list of output names on which a panel instance should be rendered. The default value is '*' wildcard, which means all outputs.