There is a plugin I wrote for QGIS and I added some buttons there. From main launch Python script I need to check is specific button is clicked and according to that do some stuff.
I saw a default condition in main script:
def run(self): if self.first_start == True: self.first_start = False self.dlg = frame_builderDialog() self.dlg.show() result = self.dlg.exec_() if result: pass 'or do something'
In this case I can catch event if I had an "OK\Cancel" button. But I have another simple buttons. I tried to catch them using something like
result_btn = self.dlg.pushButton.clicked
pushButton is one of the buttons taken from script with dialog, but nothing were returned.
What should be done here?