summaryrefslogtreecommitdiff
path: root/combobox.go
diff options
context:
space:
mode:
Diffstat (limited to 'combobox.go')
-rw-r--r--combobox.go8
1 files changed, 8 insertions, 0 deletions
diff --git a/combobox.go b/combobox.go
index 2f70fa8..255bcf0 100644
--- a/combobox.go
+++ b/combobox.go
@@ -110,3 +110,11 @@ func (c *Combobox) setRect(x int, y int, width int, height int) error {
return c.sysData.setRect(x, y, width, height)
}
+
+func (c *Combobox) preferredSize() (width int, height int, err error) {
+ c.lock.Lock()
+ defer c.lock.Unlock()
+
+ width, height = c.sysData.preferredSize()
+ return
+}