@pymethod int|PyCTreeCtrl|SetItemText|Changes the text of a list view item or subitem.
| 590 | |
| 591 | // @pymethod int|PyCTreeCtrl|SetItemText|Changes the text of a list view item or subitem. |
| 592 | PyObject *PyCTreeCtrl_SetItemText( PyObject *self, PyObject *args ) |
| 593 | { |
| 594 | CTreeCtrl *pList = GetTreeCtrl(self); |
| 595 | if (!pList) return NULL; |
| 596 | HTREEITEM item; |
| 597 | TCHAR *text; |
| 598 | PyObject *obtext; |
| 599 | if (!PyArg_ParseTuple( args, "iO:SetItemText", |
| 600 | &item, // @pyparm HTREEITEM|item||The item whose text is to be retrieved. |
| 601 | &obtext)) // @pyparm string|text||String that contains the new item text. |
| 602 | |
| 603 | return NULL; |
| 604 | if (!PyWinObject_AsTCHAR(obtext, &text, FALSE)) |
| 605 | return NULL; |
| 606 | GUI_BGN_SAVE; |
| 607 | BOOL ok = pList->SetItemText(item, text); |
| 608 | GUI_END_SAVE; |
| 609 | PyWinObject_FreeTCHAR(text); |
| 610 | if (!ok) |
| 611 | RETURN_ERR("SetItemText failed"); |
| 612 | RETURN_NONE; |
| 613 | } |
| 614 | |
| 615 | // @pymethod object|PyCTreeCtrl|GetItemData|Retrieves the application-specific value associated with an item. |
| 616 | PyObject *PyCTreeCtrl_GetItemData( PyObject *self, PyObject *args ) |
nothing calls this directly
no test coverage detected