From 365d71264ff16b5941047968274365365b2c4e56 Mon Sep 17 00:00:00 2001 From: Nick O'Leary Date: Thu, 16 Jun 2016 00:08:53 +0100 Subject: [PATCH] Add index to editableList callback signature --- editor/js/ui/editableList.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/editor/js/ui/editableList.js b/editor/js/ui/editableList.js index dee5ec068..f6243f5be 100644 --- a/editor/js/ui/editableList.js +++ b/editor/js/ui/editableList.js @@ -17,8 +17,7 @@ /** * options: - * - addButton : boolean|string - text for add label, default 'tab' - * - addable : boolean (true) - whether to show the add button + * - addButton : boolean|string - text for add label, default 'add' * - height : number|'auto' * - resize : function - called when list as a whole is resized * - resizeItem : function(item) - called to resize individual item @@ -128,7 +127,7 @@ if (this.options.resizeItem) { var that = this; this.element.children().each(function(i) { - that.options.resizeItem($(this).find(".red-ui-editableList-item-content")); + that.options.resizeItem($(this).find(".red-ui-editableList-item-content"),i); }); } },