MCPcopy
hub / github.com/lxn/walk / insertItemAt

Method insertItemAt

combobox.go:269–278  ·  view source on GitHub ↗
(index int)

Source from the content-addressed store, hash-verified

267}
268
269func (cb *ComboBox) insertItemAt(index int) error {
270 str := cb.itemString(index)
271 lp := uintptr(unsafe.Pointer(syscall.StringToUTF16Ptr(str)))
272
273 if win.CB_ERR == cb.SendMessage(win.CB_INSERTSTRING, uintptr(index), lp) {
274 return newError("SendMessage(CB_INSERTSTRING)")
275 }
276
277 return nil
278}
279
280func (cb *ComboBox) removeItem(index int) error {
281 if win.CB_ERR == cb.SendMessage(win.CB_DELETESTRING, uintptr(index), 0) {

Callers 2

resetItemsMethod · 0.95
attachModelMethod · 0.95

Calls 3

itemStringMethod · 0.95
newErrorFunction · 0.85
SendMessageMethod · 0.65

Tested by

no test coverage detected