def __init__(self, connection):
        QTabWidget.__init__(self)

        self.connection = connection

        self.setupUi(self)
        self.tableProcessList.verticalHeader().hide()

        cur = self.connection.cursor()
        cur.execute("SHOW TABLES IN information_schema LIKE 'PROCESSLIST'")
        self.processListInInfoSchema = cur.rowcount

        if self.processListInInfoSchema:
            self.processListColumns = []
            cur.execute("SHOW COLUMNS IN information_schema.PROCESSLIST")
            for column in cur.fetchall():
                self.processListColumns.append(column[0])

            try:
                self.processListColumns.remove("TIME_MS")
                idx_time = self.processListColumns.index("TIME")
                self.processListColumns[idx_time] = "TIME + TIME_MS/1000 AS TIME"
            except __HOLE__:
                pass

        else:
            self.chkShowIdle.hide()

        self.refresh()

        self.timer = QTimer(self)
        self.timer.timeout.connect(self.on_timer_timeout)
        self.on_spinSeconds_valueChanged(self.spinSeconds.value())
        self.on_chkAutoRefresh_stateChanged()
dataset/ETHPy150Open mtorromeo/sqlantaresia/sqlantaresia/ProcessListTab.py/ProcessListTab.__init__