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

FEATURE REQUEST - Surface ID of pressed button as variable #2690

Open
2 tasks done
obcocav opened this issue Jan 7, 2024 · 3 comments
Open
2 tasks done

FEATURE REQUEST - Surface ID of pressed button as variable #2690

obcocav opened this issue Jan 7, 2024 · 3 comments
Labels
area/backend Something in the core of companion area/internal Related to an internal action or function of Companion. Enhancement New feature or request

Comments

@obcocav
Copy link

obcocav commented Jan 7, 2024

Is this a feature relevant to companion itself, and not a module?

  • I believe this to be a feature for companion, not a module

Is there an existing issue for this?

  • I have searched the existing issues

Describe the feature

It would be HUGE for us to be able to have the Surface ID of a button press available as a variable. Use case is that we could have a single menu page show the proper page/layout depending on where and which Streamdeck it is viewed on. We have XLs and Regular Streamdecks in different locations and have a different layout depending on which you are using. As it is I have to keep up two different but almost identical pages and have separate menu page for the smaller decks. Using this feature I could have one menu page that selected the page to show based on which surface the button was pressed on! Thanks for all yall do!

Usecases

No response

@Julusian
Copy link
Member

Julusian commented Jan 7, 2024

I think this is related to or perhaps a duplicate of #1909

@Julusian Julusian added Enhancement New feature or request area/backend Something in the core of companion area/module-api Module related area/internal Related to an internal action or function of Companion. and removed area/module-api Module related labels Jan 7, 2024
@obcocav
Copy link
Author

obcocav commented Jan 10, 2024

@Julusian . Maybe so. I read through that issue and I'm not necessarily seeing the relation but I'm not the sharpest knife in the drawer. Basically I just want to be able to see which surface ID a button press came from. if button is pressed on surface A (15 key deck) then go to page B (designed for 15 key). If it is pressed on Surface C then go to page D.

@Julusian
Copy link
Member

Its the same root problem of 'temporary' variables which have different values depending on what action or feedback made the parseVariables call

While this is simple to solve for the internal actions, the way parseVariables calls come from modules mean that we don't know what action the parse is for. We could have just told the module to execute 10 actions and received 5 calls to parse a string. Or the parse could be a few seconds after we told it to execute the action.

Supporting this in modules is simple, but it requires changes in every module. But before we push for that it needs some UX so that users can know what to expect each field to support. This is half done, I did #2583 as groundwork for this.

There is already some groundwork in place for all of this, modules using variables in feedbacks need to do be doing calls in the same 'correct' way so that the feedback will be rechecked when the variables change.
And a couple of internal feedbacks are able to use $(this:page) and similar feedbacks, as this was needed to get the resizable grid finished (well technically it could have been done another way, but it would have been a big mess in the code)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/backend Something in the core of companion area/internal Related to an internal action or function of Companion. Enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants