def Wininst(self):
y = self.WinOtopData[self.ID_PAD_INST][1]
x = self.WinOtopData[self.ID_PAD_INST][2]
nlines = self.WinOtopData[self.ID_PAD_INST][3]
hsize = len(self.Vinstdata_head)
self.instdata_head = 'Instance info'
Ltmp=(self.ID_PAD_INST,y,x,nlines,hsize)
self.padrefreshcoord.append(Ltmp)
try:
self.instpad = curses.newpad(y+nlines+3,x+hsize+2)
self.instwinbox = curses.newwin( nlines+3, hsize+3, y, x)
except Exception as err:
self.instpad =-1
self.WinPrintError("Wininst curses Error:"+str(err) )
finally:
try:
if not self.WinCheckThreadAlive(self.idthinst):
self.idthinst = threading.Thread(target=self._WininstshowTH,name='instshowTH')
self.idthinst.setDaemon(True)
self.thConfig.append((self.ID_PAD_INST,1))
else:
self.lockvideo.acquire()
self.instpad.addstr(1,1,self.Vinstdata_head,self.CYANONBLACK)
self.instpad.addstr(2,2,"waiting refresh... ",self.GREENONBLACK)
self.instpad.refresh(1,0,y+1,x+1,y+nlines+1,x+hsize)
self.lockvideo.release()
except Exception as err:
self.instpad =-10
self.WinPrintError("Wininst thrd Error:"+str(err) )
评论列表
文章目录