Skip to content

Commit 98e9d72

Browse files
gtkui: fix scriptable insert position bug, align with cocoaui -[ScriptableNodeEditorViewController insertionIndex]
1 parent 820b0e2 commit 98e9d72

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

plugins/gtkui/scriptable/gtkScriptableListEditViewController.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -328,7 +328,7 @@ _insertion_index (gtkScriptableListEditViewController_t *self) {
328328
int cnt = scriptableItemNumChildren (self->scriptable);
329329
int index = _get_selected_index (self);
330330
if (cnt == 0) {
331-
return -1;
331+
return 0;
332332
}
333333
else if (index < 0) {
334334
index = cnt;

0 commit comments

Comments
 (0)