Select to view content in your preferred language

Custom widget with custom popup

4281
10
11-10-2015 06:19 PM
AndrewTerwiel
Frequent Contributor

I'm trying to assign a custom popup to the map.infowindow in a custom widget, but when I do this I receive a console error saying "cannot read property 'toScreen' of undefined at p.show". Here is my code:

_customPopup: new Popup({
  fillSymbol: this._sfsParcel,
  highlight: true,
  lineSymbol: this._slsRoad,
  markerSymbol: this._smsPoint
}, domConstruct.create("div")),


postCreate: function () {
  this.inherited(arguments);
  this._config = this.config;
  this.map = this.map;
  this.map.infoWindow = this._customPopup;
},

    

Does anyone see what could be wrong here?

0 Kudos
10 Replies
RobertScheitlin__GISP
MVP Emeritus

Andrew,

   Strange but at least it works for you for now.

0 Kudos