fix(SystemBars): get correct style on handleOnConfigurationChanged#8295
fix(SystemBars): get correct style on handleOnConfigurationChanged#8295theproducer merged 13 commits intomainfrom
Conversation
| String style = getConfig().getString("style"); | ||
|
|
||
| if (style == null) { | ||
| style = STYLE_DEFAULT; | ||
| } | ||
|
|
||
| return style; |
There was a problem hiding this comment.
Why are you changing the getConfig().getString("style", STYLE_DEFAULT) with all this?
This is how the getConfig().getString("style", STYLE_DEFAULT) is supposed to work internally, if getConfig().getString("style") is null it would return the STYLE_DEFAULT as it's the default value passed.
Is it not working as expected?
There was a problem hiding this comment.
No, sorry, this was just debug stuff that didn't get fully removed.
| if (getConfig().getConfigJSON().has("hidden")) { | ||
| return getConfig().getBoolean("hidden", false); | ||
| } | ||
|
|
||
| return false; |
There was a problem hiding this comment.
Same here, why are you replacing the getConfig().getBoolean("hidden", false) with this?
It's supposed to return false if the config doesn't include hidden, so you shouldn't need to check.
If it's not working like that it should be reported and fixed.
If it's working like that, not sure why all this extra code is being added.
|
You removed the |
|
The only concern about this approach is, what if the user change the style programmatically? i.e. called |
fixes: #8294