[Script] WME Keep My Layers

Hey all, thanks very much for the feedback. I haven’t been able to take a look at them yet since it’s been a busy last few days and I also wanted to finish writing WME Road Selector Highlights (just released!). I will address (and hopefully resolve) these bugs in the next few days. Thanks for your patience!

@bz2012: I think something was changed to Beta too because I had also suddenly experienced a similar issue with the button disappearing. I thought I fixed it with the last minor update release, but it’s possible that I didn’t catch the actual issue. Would you check that your version is up-to-date?

‘up to date?’

Yep. Tried updating again and it shows last update 28 hrs. 0.2.1

Tater TOT!

Very nice!

My button is missing :smiley:

I would like to propose the name be changed to “Keep my Taters”

Kidding (:

Nice Script!

I’ve rushed the release of version 0.3 as there was an uncomfortable amount of compatibility issues in version 0.2.x. Much of this stemmed from differences in how browsers and Grease/TamperMonkey handle security and permissions. This new update brings several significant improvements in usability and performance:

  • Now compatible with both recent versions of Chrome and Firefox
  • URL interception for beta/production editors (and language-specific WME) is now implemented as soon as DOM is available. Practically, this means that the lag-time between opening a PL and redirection to the correct editor is as low as 50-100ms. For the best experience, you should set WME KeepMyLayers at the top of your installed userscript run stack. In TamperMonkey, you do this by making sure that KMLayers has the circled number 1 next to it. If you sort by numbers,you will be able to drag the script to the top (first). In GreaseMonkey, you right click on the script and select the option to run first ahead of others.
  • Layer interception also occurs early before WME has the chance to see the layers set with &layers. Thus, there is practically no time load time cost for initial layer removal.
  • KMLayers now also saves the setting for showing res places and closed URs/MPs. There is a second slower layer resetting process that that begins as soon as the Waze map variable is available. Since some of the processing occurs before the onload() event trigger, it only requires a couple more hundreds of milliseconds to complete with no other competition.
  • toggling between your reset layers and the original layers from the PL is now working. If any layers had to be hidden from the PL, the eye icon will activate allowing you to toggle between the two states.
  • beta toggler has been made more robust. I could not replicate the bug using this version, so hopefully whatever caused it has now been addressed.
  • unfortunately there is an error in the console that doesn’t seem to bother KMLayers much at all, bul . Since I’m not sure what’s the source, a minor release may be made in the soon to patch it.
  • apologies, but due to the latest optimization a made to url/layer interception, you will have to set all yoir preferences again.

Anyhoo, since it’s about 3am here now, I’ll just end my post here bc I’m starting to drift off to sleep. ^_*

Lol you can guess right about where I was starting to fade in my last update post. Anyway, the bug has been found and squashed in the latest update – 0.3.1. Hopefully no more new updates will be required. Re the overlap of the beta toggler with panel swap-- in the spirit of parsimony, I did not make any modifications to address that situation. The panel swap button works just fine when overlapping the beta toggler. When you want to use the beta toggle, simply deselect the map feature and panel swap will disappear.

Lastly, I realize the above update post is long and wordy, so I want to highlight one important point. To experience the fastest load times, you must set KeepMyLayers to run before all other scripts. See previous post (second bullet) for help on how to do this.

Hi

Thanks for the update
however i can’t click save on the following dialog (attached), i click cancel then it gone. the dialog that i am talking about pop up after the information about the update

So nothing happens when you click save? Weird. Try opening it again and the n click save. Does that work?

Feature request: would it be possible for KML to ignore certain layers? For example, a lot of the time, I keep validator off since I find the highlights a little annoying and mostly know what to look for. However, there are times where I want validator turned on across multiple refreshes (mainly when I’m testing a localization script) and KML keeps defaulting it to off since that’s how I have it saved. It would be nice if I could tell KML to let it stay to it’s last setting (on or off) and not force it one way or another.

BTW, awesome script! It is very useful to have when following PLs with those pesky layers in them

I’ll see what i can whip up

Woohoo! Another update! This update to version 0.4 brings you the following new beta features and bug-fixes:

  • Thanks to rickzabel’s help, the bug that caused part of the URL to repeat itself ad infinitum has been found and squashed
  • Double-click on the beta/prod toggle to quickly disable/enable
  • Press Alt-key once while hovering the cursor over any PL within the WME window to switch it to the alternative editor (i.e., beta or prod)
  • Within the preference pane, you can now add additional sets of layers to accommodate various editing contexts
  • Double-click on the WME Layer menu icon for easy access to the KMLayers preference pane

1 Like

I’m really liking the context profiles already, and I haven’t even tried it yet. Good work

Sent from Android using Tapatalk

Thank You, Thank You, Thank You…

How I have longed for this Script.
Love the fact that i can now set layer preferences for when I’m working with URs (which in Brooklyn, NY is Most of the Time)

Great Work…

sorry late reply. that message only show up once the script updated to 0.3.1

thanks for the new update 0.4

Not sure what you did to effect the change, but now KML is working for me in Firefox 43.0.4 on my MacBook Pro running El Capitan, the latest Mac OS. As far as I can tell, all my other scripts are unaffected.
Thanks!

Nope. To quick on the trigger. Worked for a couple of test passes and now back to not responding. Guess I’ll have to do some more testing.

Sorry all. In my haste to push an update while I had some free time, I accidentally introduced a silly logic error that prevented the layers check. This has been fixed, as well as the save button issue reported by Andy. The alt-key switch has been disabled for now since it seemed to conflict with WME Toolbox’s features.

Oops! – I have another apology. I didn’t know that changing the script name on GreasyFork would prevent users from receiving auto-updates. I’ve since changed it back from “WME KeepMyLayers i[/i]” to the original name, “WME KeepMyLayers.” However, if you are one of the few who had updated/installed during the time it was named “WME KeepMyLayers (Beta),” you’ll have to manually force an update one more time. I will refrain from renaming the script from now on, so auto-updating should work as expected. Sorry about that!

currently using 0.4.2.2
Can not figure out how to get it to allow me to run a WME and a beta session simultaneously in different tabs and switch a newly opened tab between beta and WME.

If I am using beta, it seems I must disable WMEKmL before I can open a new tab in WME.
likewise, if I am using WME, I must disable WMEKmL before I can open a new tab in beta.

In either of these cases, it seems to have lost the saved settings.

Also, the ‘toggle’ seems to disappear.
Maybe I just don’t know the proper magic words and arcane gestures?

Yep… I could not use editor profiles, as they kept converting to beta link (which does not work)… and then Toggle disappeared… so I had to disable script :frowning:

What do you mean the editor profiles keep getting converted to beta link?? :-o The script doesn’t run on the editor profile page. Would you describe what you’re doing in greater detail? Perhaps provide a link to the path of the editor profile page that it is replacing with the beta link?