[Script] WME MagicWand

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

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 MagicWand

Postby a525ao37 » Mon Nov 09, 2015 4:51 pm

Thank you for useful script, often using
a525ao37
Waze Local Champs
Waze Local Champs
 
Posts: 7
Joined: Fri Jul 03, 2015 5:04 pm
Location: Ivanovo, Russia
Has thanked: 5 times
Been thanked: 6 times

Re: [Script] WME MagicWand

Postby AlanOfTheBerg » Thu Nov 20, 2014 5:36 pm

In Chrome/Win7 Tampermonkey, once the Magic Wand creates a landmark, there are no geometry handles so I cannot change the shape.

EDIT: I found that when the "resize landmark" option is checked, the geometry nodes disappear. And now I re-read the notes that found this is a known situation. Why is it this way?
AlanOfTheBerg
Waze Global Champs
Waze Global Champs
 
Posts: 23615
Joined: Sat Aug 28, 2010 8:48 pm
Location: US Country Manager - Oregon, USA
Has thanked: 1128 times
Been thanked: 4829 times

Re: [Script] WME MagicWand

Postby AlanOfTheBerg » Thu Nov 20, 2014 10:38 pm

wasd42 wrote:That is a restriction set by OpenLayers library (mapping framework used by Waze Editor). I'll try to figure something out, maybe a custom control. Thank you.

Perhaps you could put the option as a button on the tab when the Place is selected, instead of on the Magic Wand tab, and then when a Place is selected, I can choose to click the Resize button to do the change, rather than having to go back to the Magic Wand tab?
AlanOfTheBerg
Waze Global Champs
Waze Global Champs
 
Posts: 23615
Joined: Sat Aug 28, 2010 8:48 pm
Location: US Country Manager - Oregon, USA
Has thanked: 1128 times
Been thanked: 4829 times

Re: [Script] WME MagicWand

Postby alexletov » Wed Nov 04, 2015 9:58 pm

Hello, to quick fix this issue you can replace
Code: Select all
var userTabs = getElId('user-tabs');

with
Code: Select all
var userTabs = getElId('user-info');

in source code.

It should work with new WME.
alexletov
Waze Local Champs
Waze Local Champs
 
Posts: 17
Joined: Wed Aug 06, 2014 10:20 am
Location: Saint-Petersburg
Has thanked: 13 times
Been thanked: 11 times

Re: [Script] WME MagicWand

Postby ArgiCZ » Fri Nov 06, 2015 12:12 am

works well, thanks mate :)
ArgiCZ
Area Manager
Area Manager
 
Posts: 122
Joined: Sun May 03, 2015 9:16 pm
Has thanked: 41 times
Been thanked: 52 times

Re: [Script] WME MagicWand

Postby aureozb » Tue Sep 27, 2016 5:26 pm

Hello,

i have a big problem here, the first thing that appears wen i open the wme: unable fo find appropriate control element, script is broken

what should i do ?
aureozb
Beta tester
Beta tester
 
Posts: 85
Joined: Sat Dec 19, 2015 11:34 am
Location: Luanda, Angola
Has thanked: 101 times
Been thanked: 21 times

Re: [Script] WME MagicWand

Postby aureozb » Tue Sep 27, 2016 6:03 pm

kentsmith9 wrote:
aureozb wrote:Hello,

i have a big problem here, the first thing that appears wen i open the wme: unable fo find appropriate control element, script is broken

what should i do ?

How funny. I just did a search for this error and didn't see anything. I then restarted my computer and still saw the error. I narrowed the error down to this script and then here is another report of the problem. :lol:

I just disabled it for now and the error goes away while it is being investigated.


But now i can´t move any places :|
aureozb
Beta tester
Beta tester
 
Posts: 85
Joined: Sat Dec 19, 2015 11:34 am
Location: Luanda, Angola
Has thanked: 101 times
Been thanked: 21 times

Re: [Script] WME MagicWand

Postby aureozb » Thu Sep 29, 2016 6:20 pm

TheGridExe wrote:
JustinS83 wrote:I tried looking into this. The control that this script uses to add in its additional Place modifications no longer exist in WME. Disable the script until it is brought back.

Since the WME update it is no longer possible to move a Place, and that control is what this script was relying on finding.

but I want to move places!


me too, what kind of person want us to work in map but don't move places ?
aureozb
Beta tester
Beta tester
 
Posts: 85
Joined: Sat Dec 19, 2015 11:34 am
Location: Luanda, Angola
Has thanked: 101 times
Been thanked: 21 times

Re: [Script] WME MagicWand

Postby aureozb » Wed Feb 22, 2017 9:02 am

DauserShenkt wrote:
wasd42 wrote:Hello, everyone!

Waze.map.getControlsByClass(/.*geometryediting.*/i) to find a ModifyFeature control

Any ideas where to find it? :)


WMECH old code with same control type
Code: Select all
// add current city in to drop-down list
function initCityList() {
  var locationInfo = Waze.map.getControlsByClass('Waze.Control.LocationInfo')[0];
  if (locationInfo === null || locationInfo.location === null)
    return;

  var cityName = locationInfo.location.city;
  var thisCity = null;
  for (var city in Waze.model.cities.objects) {
    var cityObj = Waze.model.cities.get(city);
    if (cityObj.name == cityName) {
      thisCity = cityObj.id;
      break;
    }
  }
  if (thisCity === null)
    return;


Latest WMECH latest code for same function
Code: Select all
// add current city in to drop-down list
function initCityList() {
  var thisCity = Waze.model.segments.topCityID;
  if (thisCity === null) return;
  var thisName = Waze.model.cities.get(thisCity).attributes.name;

  var selectCity = getId('_selectCity');
  var cityOption = document.createElement('option');
  var cityText = document.createTextNode(thisName);
  cityOption.appendChild(cityText);
  cityOption.setAttribute('value',thisCity);
  selectCity.appendChild(cityOption);
  console.info("WME Highlights: Init City list: " + thisName);


Hope this helps.


i don't understand, can you please be more specific ?

Many thanks in advance
aureozb
Beta tester
Beta tester
 
Posts: 85
Joined: Sat Dec 19, 2015 11:34 am
Location: Luanda, Angola
Has thanked: 101 times
Been thanked: 21 times

Re: [Script] WME MagicWand

Postby aureozb » Thu Dec 07, 2017 1:43 pm

WazingArch wrote:Hello, I am using this script mainly to geometrically edit places - simplify, ortogonize and rotate places.

It seems that the rotation tool doesn't work any more. Also I noticed that when the script is enabled it disables Toolbox's feature "Select in area place or map comment".


should be because of the wme update
aureozb
Beta tester
Beta tester
 
Posts: 85
Joined: Sat Dec 19, 2015 11:34 am
Location: Luanda, Angola
Has thanked: 101 times
Been thanked: 21 times

Next

Return to Addons, Extensions, and Scripts

Who is online

Users browsing this forum: Google Feedfetcher