remove unused code

most part was commented, some other is not used now because using
QTableView from QWidget was removed, but it was some legacy in if
statement