diff options
author | portix <none@none> | 2013-01-26 13:51:41 +0100 |
---|---|---|
committer | portix <none@none> | 2013-01-26 13:51:41 +0100 |
commit | 9c7bc22f85a7a794f2dfd1ef385157aea758a1eb (patch) | |
tree | e132962e85343025a66dddc74f038935f3b73c93 /src | |
parent | 83da4f3b781fd56d0c88db99c8cc64c86ba6309f (diff) | |
download | dwb-9c7bc22f85a7a794f2dfd1ef385157aea758a1eb.zip |
Regression: remove tabs.iterate
Diffstat (limited to 'src')
-rw-r--r-- | src/scripts.c | 18 |
1 files changed, 0 insertions, 18 deletions
diff --git a/src/scripts.c b/src/scripts.c index a4311d8a..f3989656 100644 --- a/src/scripts.c +++ b/src/scripts.c @@ -338,23 +338,6 @@ tabs_length(JSContextRef ctx, JSObjectRef this, JSStringRef name, JSValueRef* ex return JSValueMakeNumber(ctx, g_list_length(dwb.state.views)); }/*}}}*/ -static JSValueRef -tabs_iterate(JSContextRef ctx, JSObjectRef function, JSObjectRef thisObject, size_t argc, const JSValueRef argv[], JSValueRef* exc) -{ - JSObjectRef callback; - if (argc == 0 || (callback = js_value_to_function(ctx, argv[0], exc)) == NULL) - return UNDEFINED; - int i=0; - for (GList *l = dwb.state.views; l; l=l->next) - { - JSValueRef args[] = { VIEW(l)->script_wv, JSValueMakeNumber(ctx, i++) }; - JSValueRef ret = JSObjectCallAsFunction(ctx, callback, callback, 2, args, exc); - if (JSValueToBoolean(ctx, ret)) - break; - } - return UNDEFINED; -} - /* tabs_get_nth {{{*/ static JSValueRef tabs_get_nth(JSContextRef ctx, JSObjectRef function, JSObjectRef thisObject, size_t argc, const JSValueRef argv[], JSValueRef* exc) @@ -2574,7 +2557,6 @@ create_global_object() JSStaticFunction tab_functions[] = { { "nth", tabs_get_nth, kJSDefaultAttributes }, - { "iterate", tabs_iterate, kJSDefaultAttributes }, { 0, 0, 0 }, }; JSStaticValue tab_values[] = { |