More in this section
Forums / Developing with Sitefinity / How do I find out the exposed javascript methods for a given control for use in the widget designer?

How do I find out the exposed javascript methods for a given control for use in the widget designer?

The forums are in read-only mode. In case that you want to directly contact the Progress Sitefinity team use the support center. In our Google Plus group you can find more than one thousand Sitefinity developers discussing different topics. For the Stack Overflow threads don’t forget to use the “Sitefinity” tag.
2 posts, 1 answered
  1. Liquid
    Liquid avatar
    3 posts
    Registered:
    05 Apr 2013
    12 Jan 2016
    Link to this post

    Currently I am using a FlatSelector in my widget designer for selecting a single item. Everything is working as expected but my question is how do I determine the javascript functions are exposed to the widgetdesigner.js for a given control?

    My FlatSelector for example has a method set_selectedKeys and get_selectedKeys. I am using get_selectedKeys in my javascript applyChanges to get the value and using set_selectedKeys with an array in the refreshUI function. The only reason I know about these methods is from a blog that used get_selectedKeys and I assumed there was a set_selectedKeys and trial and error.

    How do I find out which functions are available? Currently I am looking at the prototype of the object with:

            console.log(JSON.stringify(this._videoSelector, censor(this._videoSelector)));

    There has got to be a better way/documentation? Trick?

  2. Liquid
    Liquid avatar
    3 posts
    Registered:
    05 Apr 2013
    28 Feb 2016
    Link to this post
    My solution was to extract the javascript files from the binary and look at them. That is all.
    Answered
2 posts, 1 answered