As reported by Coverity, the return string of WMGetTextFieldText is
malloced so it needs to be freed.
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
As pointed by Coverity, the string returned by 'WMGetTextFieldText' is
allocated dynamically, so it must be freed when not needed anymore.
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
The functions that create the different configuration panels were taking
the screen structure as argument, but it turns out that none of them
actually need it.
We just remove the argument to make code simpler and easier to maintain.
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
Instead of defining 2 separate data arrays, use a array of struct
to make it less bug prone (no dependancy on order of elements).
Took opportunity to de-CamelCase the variable name;
Took opportunity to add appropriate const qualifier.
Instead of defining 2 separate data arrays, use a array of struct
to make it less bug prone (no dependancy on order of elements).
Took opportunity to de-CamelCase the variable name;
Took opportunity to add appropriate const qualifier.
When first using the wmdrawer panel of WPrefs the settings
ClipAutoexpandDelay
ClipAutocollapseDelay
ClipAutoraiseDelay
ClipAutolowerDelay
are not yet saved in the user's config file and 'value' ends up
being undefined in showData() leading to a crash in adjustButtonSelectionBasedOnValue().
This patch is a workaround to make it possible to choose the config values for the
first time using WPrefs.