qlcplus
qlcplus copied to clipboard
Refresh Cue List Widget on Addition or Removal of a Step from Chaser
trafficstars
- Currently adding or removing a widget is not reflected in the cue list widget unless the project is saved and reopened
- Also apparent cause of crash at https://www.qlcplus.org/forum/viewtopic.php?t=17147, as the cue list would attempt to access a non-existent index
- This PR reloads the chaser cue list if a function is added or removed from the linked chaser, allowing updates to be seen in real time and preventing the crash
coverage: 32.014% (-0.05%) from 32.065% when pulling 9805f86cc6914dbdc339aea53e2dbdaa3c286a37 on lilyCalla:cuelist-refresh into 01fdda185ed1c008e0605669ec29dac4963511aa on mcallegari:master.
Love your work @lilyCalla
Looks good, thanks 👍
Actually, I overlooked these changes.
- first signals should be using past form, so in chaser.h/cpp it's
stepsListChanged, notstepListChange - also, a signal to update the UI was already present: https://github.com/mcallegari/qlcplus/blob/master/qmlui/virtualconsole/vccuelist.h#L198
I think the only change needed in vccuelist.cpp is this:
connect(function, SIGNAL(stepsListChanged(quint32)),
this, SIGNAL(stepsListChanged()));
Please try that and re-submit a new PR. Thanks
Nevermind, I sorted this myself.