[Script] WME Street View Availability (0.8.1)

Discussion for the unofficial, community-developed addons, extensions and scripts built for the Waze Map Editor.

The official index of these tools is the Community Plugins, Extensions and Tools wiki page.

Moderators: Unholy, bextein, Glodenox, JustinS83

Forum rules
Discussion for the unofficial, community-developed addons, extensions and scripts built for the Waze Map Editor.

DO NOT START a new thread unless it is about a new idea. Keep discussion of existing tools within the main thread for that tool.

The official index of these tools is the Community Plugins, Extensions and Tools wiki page.

Re: [Script] WME Street View Availability (0.8.0)

Postby iainhouse » Tue Aug 20, 2019 11:08 pm

Glodenox wrote:The script now restores the last used width of the Street View panorama

Hey there. I'm having a little problem with this latest feature - or at least how it interacts with a new feature in WME FixUI. It seems we've both been working on the same problem from different angles! :lol:

The problem is really down to bad design by the WME Devs. As initially loaded, the relative widths of the map and GSV panels are controlled by CSS classes setting the widths to 50%/50%. But, as soon as you drag the handle, WME adds inline CSS to the elements themselves setting width/drag handle positions in fixed pixel values.

My script will alter the default % values in the CSS classes to change the default split position. If you drag the handle, that position gets overridden by the dragged-to position set in the inline CSS.

It looks like you are restoring the previous position by storing the inline CSS values and restoring them on reload - but you are doing this even if the handle hasn't been dragged and is therefore still at the default position and controlled by the CSS classes.

That's where it's interfering with WME FixUI. I think your script is looking for the inline CSS, not seeing any, then assuming the position is at 50% and setting/storing the corresponding inline CSS settings - even though FixUI has altered that default.

Perhaps you could change your code to not store/set a permission if no inline CSS setting is found? Or maybe look at the % position set in on these 3 CSS classes:
  • #editor-container #map.street-view-mode #waze-map-container {width}
  • #editor-container #map.street-view-mode #street-view-drag-handle {left}
  • #editor-container #map.street-view-mode #street-view-container {width}
[ img ][ img ][ img ]
UK AdminsUK WikiWaze FAQWMEFU Script :ugeek:
I want to go to a commune in Vermont and deal with no unit of time shorter than a season
iainhouse
Country Manager
Country Manager
 
Posts: 10034
Joined: Mon Jul 23, 2012 5:16 pm
Location: on the road from London to insanity, with Waze HQ in the driving seat
Has thanked: 2604 times
Been thanked: 8167 times

Re: [Script] WME Street View Availability (0.8.0)

Postby Glodenox » Wed Aug 21, 2019 1:06 am

I haven't got FixUI running at the moment, I'll do some testing tomorrow to make sure that what I'm saying below is actually right.

The script should not adjust the size if it was never dragged (the trigger is an adjustment to the style attribute where the width is set to something other than the empty string), so FixUI's new default should still work as long as the user never adjusted it themselves. The idea of the feature in this userscript is exactly to make any adjustment by the user the new default from then on, so I don't think it's possible to make this function somehow work together with the FixUI default any further than that.

The only thing I can do is provide an option to disable this feature in the settings tab. That way people can decide for themselves whether they want to always have the width restored each time they open the Street View panorama. Because right now people are simply forced to accept this feature if they install this script, which admittedly isn't ideal. I was already thinking about doing something like that, but I just wanted to get the feature out of the door already.
Script Writing Community Coordinator
[ img ][ img ]
Glodenox
Waze Global Champs
Waze Global Champs
 
Posts: 1029
Joined: Tue Aug 11, 2015 9:04 pm
Location: Belgium
Has thanked: 497 times
Been thanked: 1180 times

Re: [Script] WME Street View Availability (0.8.0)

Postby G_W1Z » Thu Sep 26, 2019 10:43 am

After the WME update this week, roads with available SV are not lighting up blue.
G_W1Z
Pennsylvania LAM (USA:NOR)
Waze Etiquette | Pennsylvania Editing
A Phoenix out of the ashes...
iPhone XS | Apple Car Play
[ img ][ img ][ img ]
G_W1Z
Area Manager
Area Manager
 
Posts: 428
Joined: Sun Jan 25, 2015 5:05 pm
Location: Pennsylvania, USA (NOR)
Has thanked: 840 times
Been thanked: 101 times

Re: [Script] WME Street View Availability (0.8.1)

Postby Glodenox » Thu Sep 26, 2019 4:10 pm

Version 0.8.1 has just been released to fix the issue with the new layer menu breaking the script. I still need to work on adding a toggle to choose whether to save the Street View window width though.
Script Writing Community Coordinator
[ img ][ img ]
Glodenox
Waze Global Champs
Waze Global Champs
 
Posts: 1029
Joined: Tue Aug 11, 2015 9:04 pm
Location: Belgium
Has thanked: 497 times
Been thanked: 1180 times

Previous

Return to Addons, Extensions, and Scripts

Who is online

Users browsing this forum: RichardPyne, sikemever