diff options
author | portix <portix@gmx.net> | 2012-11-02 10:40:29 +0100 |
---|---|---|
committer | portix <portix@gmx.net> | 2012-11-02 10:40:29 +0100 |
commit | d2ca0500bfbee25d107e83dfadacffb7ae7635b3 (patch) | |
tree | e920d28fe1535b57c63d1939b10b2c50095003c2 /src | |
parent | 6ae8d205fa646b0b860bd23b7b23762f970b2435 (diff) | |
download | dwb-d2ca0500bfbee25d107e83dfadacffb7ae7635b3.zip |
Create own this object for all scripts
Diffstat (limited to 'src')
-rw-r--r-- | src/scripts.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/scripts.c b/src/scripts.c index dd0ae0db..1b2a7ecf 100644 --- a/src/scripts.c +++ b/src/scripts.c @@ -1969,7 +1969,9 @@ static void apply_scripts() { for (GSList *l = m_script_list; l; l=l->next) { JSObjectRef o = JSObjectMake(m_global_context, NULL, NULL); - JSObjectCallAsFunction(m_global_context, l->data, o, 0, NULL, NULL); + JSObjectRef apply = js_get_object_property(m_global_context, l->data, "apply"); + JSValueRef argv[] = {o}; + JSObjectCallAsFunction(m_global_context, apply, l->data, 1, argv, NULL); } g_slist_free(m_script_list); m_script_list = NULL; |