'Add the script file to s3.scripts, called when an agent
builds the widget'

def _load_script(self):

    if self.script_loaded:
        return
    s3 = current.response.s3
    scripts = s3.scripts
    path = self.get_script_path(debug=s3.debug)
    if path:
        appname = current.request.application
        script = ('/%s/static/scripts/%s' % (appname, path))
        if (script not in scripts):
            scripts.append(script)
    self.script_loaded = True
