title: PyQT5 QSystemTrayIcon activated signal not working
body: <p>I am trying to print a text when system tray icon is clicked in PyQT5 program. I tried to connect PyQT5 QSystemTrayIcon activated signal (emitted when system tray icon is clicked) to custom method, but the method is not called.
  Here is simple example:</p>
  
  <pre><code>import sys
  from PyQt5.QtWidgets import QSystemTrayIcon, QApplication
  from PyQt5.QtGui import QIcon
  from PyQt5.QtCore import pyqtSlot
  
  
  @pyqtSlot()
  def action(signal):
      print('test1')
  
  app = QApplication(sys.argv)
  icon = QSystemTrayIcon(QIcon('any_icon.png'), app)
  icon.show()
  
  icon.activated.connect(action)
  #icon.activated['QSystemTrayIcon::ActivationReason'].connect(action)
  #icon.pyqtConfigure(activated=action)
  
  print(icon.receivers(icon.activated))  # to check if is connected
  sys.exit(app.exec_())
  </code></pre>
  
  <p>In example are 3 ways of connecting the signal to slot (two of them commented). I tried both using method with and without decorator @pyqtSlot(). Connection raises no errors. Even the print of signal receivers says it is connected to 1 slot. However, it does nothing when systray icon is clicked.</p>
  
  <p><strong>The question:</strong> Is the signal connection incorrect, or is the signal not emitted at all?</p>
  
  <p><em>System: Ubuntu 16.04, PyQT5.8. However, should be working on others systems too as PyQT is multiplatform-ish.
  PS: I have read <a href="http://pyqt.sourceforge.net/Docs/PyQt5/signals_slots.html" rel="nofollow noreferrer">official PyQT5 signal/slot documentation</a> and many related questions on stack overflow, but had not found the same issue. The closest one I think may relate <a href="https://stackoverflow.com/questions/1053244/qt-qsystemtrayicon-not-sending-activated-signal">is in C++</a>, but not applicable to python.
  Any tips would be really appreciated. Thank you very much!
  Edit: fixed typos in text</em></p>