MCPcopy Create free account
hub / github.com/mhammond/pywin32 / PyCTreeCtrl_GetImageList

Function PyCTreeCtrl_GetImageList

Pythonwin/win32ctrlTree.cpp:388–406  ·  view source on GitHub ↗

@pymethod |PyCTreeCtrl|GetImageList|Retrieves the current image list.

Source from the content-addressed store, hash-verified

386
387// @pymethod <o PyCImageList>|PyCTreeCtrl|GetImageList|Retrieves the current image list.
388PyObject *PyCTreeCtrl_GetImageList( PyObject *self, PyObject *args )
389{
390 CTreeCtrl *pList;
391 if (!(pList=GetTreeCtrl(self)))
392 return NULL;
393 int nList;
394 // @pyparm int|nImageList||Value specifying which image list to retrieve. It can be one of:
395 // <nl>- commctrl.LVSIL_NORMAL Image list with large icons.
396 // <nl>- commctrl.LVSIL_SMALL Image list with small icons.
397 // <nl>- commctrl.LVSIL_STATE Image list with state images.
398 if (!PyArg_ParseTuple(args, "i:GetImageList", &nList))
399 return NULL;
400 GUI_BGN_SAVE;
401 CImageList *ret = pList->GetImageList(nList);
402 GUI_END_SAVE;
403 if (ret==NULL)
404 RETURN_ERR("There is no image list available");
405 return ui_assoc_object::make( PyCImageList::type, ret)->GetGoodRet();
406}
407
408
409// @pymethod int|PyCTreeCtrl|InsertItem|Inserts an item into the list.

Callers

nothing calls this directly

Calls 3

GetTreeCtrlFunction · 0.85
GetImageListMethod · 0.80
GetGoodRetMethod · 0.80

Tested by

no test coverage detected