python - Subsequent tabs being closed in pyqt -


i trying close tab when users presses close tab button. code should that:

self.tab_widget.addtab(text, tabname) self.tab_widget.settabsclosable(1) self.tab_widget.tabcloserequested.connect(self.tab_widget.removetab) 

it works, when close tab before other tab(s) closes out of them after it, , not sure why. help?

oh... figured out why happening. had code removes tabs code creates them , guess doing multiple connects getting rid of more 1 tab.


Comments

Popular posts from this blog

vb.net - Alternative to the T-SQL AS keyword -

php - MySQLi binding parameters in a prepared statement doesn't work unless inserted after "WHERE" -

ios - CFRelease causing crash in iPad application -