summaryrefslogtreecommitdiff
path: root/listbox_darwin.go
diff options
context:
space:
mode:
Diffstat (limited to 'listbox_darwin.go')
-rw-r--r--listbox_darwin.go5
1 files changed, 5 insertions, 0 deletions
diff --git a/listbox_darwin.go b/listbox_darwin.go
index e663e78..9575af6 100644
--- a/listbox_darwin.go
+++ b/listbox_darwin.go
@@ -223,6 +223,7 @@ var (
_setHeaderView = sel_getUid("setHeaderView:")
_selectedRowIndexes = sel_getUid("selectedRowIndexes")
_count = sel_getUid("count")
+ _numberOfRows = sel_getUid("numberOfRows")
)
func makeListbox(parentWindow C.id, alternate bool) C.id {
@@ -294,3 +295,7 @@ func deleteListbox(listbox C.id, index int) {
array := listboxArray(listbox)
deleteListboxArray(array, index)
}
+
+func listboxLen(listbox C.id) int {
+ return int(C.objc_msgSend_intret_noargs(listboxInScrollView(listbox), _numberOfRows))
+}