momijizukamori: Grey tabby cat with paws on keyboard and mouse. The text reads 'code cat is on the job', lolcats-style (CODE CAT)
Cocoa ([personal profile] momijizukamori) wrote in [site community profile] dw_dev_training2012-11-15 03:51 pm

Account settings + the navstrip

I am usually a styles person, and I've been working on wrangling Bug 4729, which deals with custom navstrip coloring, and doing it in a way that's reasonable and easy to use. I've mostly got that one under control, but there's a second bug - Bug 630 - that's pretty closely linked, and I'd love to squash both of them, but 630 gets into... weird account settings stuff. I looked at the code for displaying/not displaying the navstrip, and it's got stuff like '$LJ::USE_CONTROL_STRIP' which... I assume is a something somewhere, but it's not a perl module. I'm also not sure where the Perl-side code for rendering the navstrip is :S

As part of that, I'd like to add a 'Never show custom navstrip colors' for people who only want their selected default (the entire navstrip is kind of an accessibility issue, so I think that setting is necessary). The problem is that the custom navstrip color stuff is part of core2 and gets printed in the layout layer CSS, and I really have no idea how to go about moving it out of core2/the layout layers.

Help, anyone?
geekosaur: orange tabby with head canted 90 degrees, giving impression of "maybe it'll make more sense if I look at it this way?" (Default)

[personal profile] geekosaur 2012-11-16 12:44 am (UTC)(link)
It's a package variable living in the LJ package.
2@haral:110299 Z$ find . -type f -print0 | xargs -0 grep USE_CONTROL_STRIP
./cgi-bin/DW/Hooks/NavStrip.pm:    return undef unless $LJ::USE_CONTROL_STRIP;
./cgi-bin/LJ/S2.pm:    return 0 unless $LJ::USE_CONTROL_STRIP;
./cgi-bin/LJ/S2.pm:    return "" unless $LJ::USE_CONTROL_STRIP;
./cgi-bin/LJ/Widget/NavStripChooser.pm:    return 1 if $LJ::USE_CONTROL_STRIP;
./etc/config.pl:    $USE_CONTROL_STRIP = 1;

Note that last match; it's a master configuration setting, and as such may control a bit more than you expect.