after patching #954906: Make user settings non persistent variables, I noticed a glitch with the enable button for "hide_on_init".
orginal code that sets the javascript settings:

'icon' => ($settings[$user->uid]['hide_on_init']) ? base_path() ."$path/images/auto_hide_icon_enabled.png" : base_path() ."$path/images/auto_hide_icon.png",

needs changed to:

'icon' => base_path() ."$path/images/auto_hide_icon.png",

Reason:
- the $settings[$user->uid]['hide_on_init'] does not exist. So when using the original code without #954906, if would always use the latter path.
- the first path in the original condition is not needed since the javascript replaces ".png" with "_enabled.png" if the setting to hide_on_init is true

Comments

recrit’s picture

Status: Active » Needs review
StatusFileSize
new946 bytes

attached patch makes the changes stated in the issue