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
Provide a way for skins to specify default values for ConfigKeys. #387
Conversation
bool bPersist = m_pContext->selectAttributeBool(keyElement, "persist", false); | ||
|
||
return controlFromConfigKey(key, bPersist, created); | ||
ControlObject* co = controlFromConfigKey(key, bPersist, created); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wonder if this works. Isn't *created just an indicator that the Co is crated by the skin. You need to know if the key exists in the mixxx.cfg.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
oh, I thought when a configkey was persisted it would set created to false. Yeah I guess it doesn't work then.
That should work. Unfortunately sometimes the default value is processed before the pushbutton has iNoStates set. Not sure whose bug that is yet. |
I'd like to revive this patch -- for new users installing Mixxx, the library does not appear if the default is not explicitly set. This makes the first-run experience very bad. (You can try it, remove the show_library setting from mixxx.cfg and you'll see it defaults to False) |
c57dace
to
c12ca20
Compare
There is an issue with the default value of COs setDefaultValue(). Setting the Inital/default value should be done in ControlDoublePrivate::initialize() The other issue is that defining the default value in a '' iss misplaces. |
how is that different from the current use of "defaultvalue"?
I can't understand this.
this region does not work. I don't think it does anything at all, actually. I will see if I can figure out why |
how about this instead: #534 |
Because of the confusion described in the linked bug.
Every CO already has a default value, defaults to 0, accessed by the child co "XXX_set_default".
A merge of both would be nice. |
no I meant I can't interpret the words you have written: "iss misplaces" |
sorry. |
obsolete |
Default show_coverart to true.