-
Notifications
You must be signed in to change notification settings - Fork 12
Made "Feedback" inherit from parent if empty #10
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?
Made "Feedback" inherit from parent if empty #10
Conversation
Not fully there but shows the principle
|
Also, not sure but I think the pairing may need updating once the parent is changed as I think the messages are cached. Let me know what you think - I'm happy to potter on with this bit if it seems useful! |
|
Oh, this is a fantastic idea! Will review the changes when I get some time... |
Added getRawFeedback() to ToyWidget which returns the actual feedback
value for that widget (whereas getFeedback() returns the value that
will be actioned (with wildcards etc processed, or the parent’s if
relevant),
When grid is created tell each widget which row, column and index it is
(zero based)
Added wildcard processing:
{r} will be replaced with the (zero based) row of the widget
{r1} will be replaced with the (one based) row of the widget
{c} will be replaced with the (zero based) column of the widget
{c1} will be replaced with the (one based) column of the widget
{n} will be replaced with the (zero based) index of the widget
{n1} will be replaced with the (one based) index of the widget
I also made the default feedback value of a widget /XX/{n1} for
testing.. begs the question what it should be.
A few things todo/to consider
- Extend the above to work with all OSC fields - extract the wildcard
code so it can be re-used
- Consider default values - maybe default so that Grid has the default
(/XXX/{n}), make the placeholderText on the field in the edit box into
the parent’s value
- Is there a way to also inherit colours etc? Don’t think these would
use any wildcards but would be useful. To complicate matters it would
be good to be able to edit these on a per-row. Well, actually it would
be great if all of this could be per grid, per row or per cell…
- Would be nice to also have an “offset” which can be modified. This
would mean the user can somehow have up/down buttons which modify a
base value - then we could have the wildcards of {oc}, {or}, {on} etc
where these are the cell/column/num plus an offset. We would probably
want a different offset for each one. This would allow the user to
cycle through presets/palletes etc in an eos scenario
…nto inherit-message-from-parent # Conflicts: # OSCWidgets.xcodeproj/project.pbxproj # OSCWidgets/ToyGrid.cpp # OSCWidgets/ToyWidget.h
Added an up/down button to the grids. This should probably be optional
but I’m still unsure about best way to adjust grid. The wildcards now
include {pn}, {pc}, {pr} where p is the page number.
I’ve only tested this with Activity and Button widgets, I also haven’t
done anything about persistence.
I would still quite like to be able to inherit per row - this could be
via the edit menu, so you edit activity, or a row, or a widget. The
widget would take it’s value, or the row’s value, or the table’s value.
There is a question though about how to inherit values such as check
boxes (the “local” field for example) where blank does not mean empty..
Hmm, let me know what you think anyway
- Should now work on all widgets - Should now work on all applicable fields - Should now be persistent
|
Not sure if you've seen my various commits but I think I have got this feature pretty much there (if you like it!) A couple of notes/bugs/todos..
I have only done basic testing, so there probably are some bugs! Let me know any thoughts.. |
|
Oh, for reference these are the wildcards I wonder if the default should be the 1 based option, as this is probably more logical to the user, and there could be an {x0} for each one which sets it to 0 based? |
Not fully there but shows the principle..
Only does the FeedbackPath for now, basically if that’s empty then it pulls the value from the Grid (which is now enabled). Couple of issues though..