Converting in-panel widget to off-panel widget

623
4
Jump to solution
08-25-2017 01:42 AM
sitsit
by
New Contributor III

I developed a simple in-panel widget that enable the user to zoom to desired scale (it's a NumberTextBox dijit), but now I want to convert it to off-panel widget. The question is: how can I do it? I searched an example of off-panel widget, but I was not able to find it. Can someone give me a link or point me in the right direction?

Thanks,

Marco

0 Kudos
1 Solution

Accepted Solutions
RobertScheitlin__GISP
MVP Esteemed Contributor

Marco,

  There are several otb off panel widgets that you can use as examples in the WAB stemApp. Look at the ScaleBar widget for example as your starting point.

View solution in original post

4 Replies
RobertScheitlin__GISP
MVP Esteemed Contributor

Marco,

  There are several otb off panel widgets that you can use as examples in the WAB stemApp. Look at the ScaleBar widget for example as your starting point.

sitsit
by
New Contributor III

Thanks, Robert.

I managed to do it. Almost. I created a TextBox (I wasn't able to create a NumberTextBox: I don't know why), but when I use the numeric pad to input a scale, the map pan in the direction of the arrows. Is there a way to prevent this behaviour?

Thanks again,

Marco

0 Kudos
RobertScheitlin__GISP
MVP Esteemed Contributor

Marco,

  Sure just use

this.map.disableKeyboardNavigation();
sitsit
by
New Contributor III

Wonderful!

Thanks again!

0 Kudos