Added the Stack Overflow link for Mac OS X Listbox insertion autoselection and fixed deletion autoselection as well.
This commit is contained in:
parent
be56293e9c
commit
6a06292081
|
@ -38,9 +38,9 @@ id makeListboxArray(void)
|
||||||
ac = [NSArrayController new];
|
ac = [NSArrayController new];
|
||||||
[ac setAutomaticallyRearrangesObjects:NO];
|
[ac setAutomaticallyRearrangesObjects:NO];
|
||||||
// we don't want Cocoa to change the selection when items are inserted
|
// we don't want Cocoa to change the selection when items are inserted
|
||||||
// found via TODO_get_Stack_Overflow_link; not sure how I missed it the first time
|
// found via http://stackoverflow.com/a/5765318/3408572; not sure how I missed it the first time
|
||||||
[ac setSelectsInsertedObjects:NO];
|
[ac setSelectsInsertedObjects:NO]; // for insertions
|
||||||
// TODO figure out how to inhibit this behavior on delete
|
[ac setAvoidsEmptySelection:NO]; // for deletions
|
||||||
return ac;
|
return ac;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue