def open(self, id, contents): self.id = id FrameWork.DialogWindow.open(self, ID_MAIN) self.dlg.SetDialogDefaultItem(MAIN_SHOW) self.contents = contents self.ctl = self.dlg.GetDialogItemAsControl(MAIN_LIST) h = self.ctl.GetControlData_Handle(Controls.kControlListBoxPart, Controls.kControlListBoxListHandleTag) self.list = List.as_List(h) self.setlist()
def open(self, id, contents): self.id = id DialogWindow.open(self, id) Qd.SetPort(self.wid) tp, h, rect = self.dlg.GetDialogItem(MAIN_LIST) self.listrect = rect rect2 = rect[0] + 1, rect[1] + 1, rect[2] - 16, rect[ 3] - 16 # Scroll bar space self.list = List.LNew(rect2, (0, 0, 1, len(contents)), (0, 0), 0, self.wid, 0, 1, 1, 1) self.setlist(contents)
def open(self, id, contents): self.id = id FrameWork.DialogWindow.open(self, ID_MAIN) self.dlg.SetDialogDefaultItem(MAIN_SHOW) tp, h, rect = self.dlg.GetDialogItem(MAIN_LIST) rect2 = rect[0] + 1, rect[1] + 1, rect[2] - 17, rect[ 3] - 17 # Scroll bar space self.list = List.LNew(rect2, (0, 0, 1, len(contents)), (0, 0), 0, self.wid, 0, 1, 1, 1) self.contents = contents self.setlist()
def __init__(self, dlg, item, content=[], multi=0): self.control = dlg.GetDialogItemAsControl(item) ## d1, d2, self.rect = wid.GetDialogItem(item) self.rect = (0, 0, 1000, 1000) # DBG h = self.control.GetControlData_Handle( Controls.kControlListBoxPart, Controls.kControlListBoxListHandleTag) self.list = List.as_List(h) self.list.LAddRow(len(content), 0) self.multi = multi if not multi: self.list.selFlags = Lists.lOnlyOne self._data = [] self._setcontent(0, len(content), content) self.dlg = dlg self.wid = dlg.GetDialogWindow()
"""browsepict - Display all "cicn" resources found"""
"""browsepict - Display all "PICT" resources found"""
#
# Test List module.