Why i can\'t receive self.sender() output? My point is to identify which button is clicked (to start a download function) and then match the corresponding progress bar for a
def buttonClicked(self):
buttonHandle = self.sender()
print buttonHandle
self here would be the Ui_MainWindow
which is not a QT object, you probably want to check .sender of MainWindow
. so set a class variable of UI_MainWindow to the MainWindow object and check sender of that object.
def setupUi(self, MainWindow):
self.MainWindow = MainWindow
....
def buttonClicked(self):
buttonHandle = self.MainWindow.sender()
print buttonHandle