MCPcopy
hub / github.com/evilsocket/opensnitch / setQuery

Method setQuery

ui/opensnitch/dialogs/stats.py:3792–3807  ·  view source on GitHub ↗
(self, model, q)

Source from the content-addressed store, hash-verified

3790 super(StatsDialog, self).keyPressEvent(event)
3791
3792 def setQuery(self, model, q):
3793 if self._context_menu_active == True or self.scrollbar_active == True:
3794 return
3795 with self._lock:
3796 try:
3797 model.query().clear()
3798 model.setQuery(q, self._db_sqlite)
3799 if model.lastError().isValid():
3800 print("setQuery() error: ", model.lastError().text())
3801
3802 if self.tabWidget.currentIndex() != self.TAB_MAIN:
3803 self.labelRowsCount.setText("{0}".format(model.totalRowCount))
3804 else:
3805 self.labelRowsCount.setText("")
3806 except Exception as e:
3807 print(self._address, "setQuery() exception: ", e)

Callers 15

_cb_cmd_back_clickedMethod · 0.95
_refresh_active_tableMethod · 0.95
_set_events_queryMethod · 0.95
_set_nodes_queryMethod · 0.95
_set_rules_filterMethod · 0.95
_set_rules_queryMethod · 0.95
_set_hosts_queryMethod · 0.95
_set_process_queryMethod · 0.95
_set_addrs_queryMethod · 0.95

Calls 4

clearMethod · 0.45
queryMethod · 0.45
isValidMethod · 0.45
lastErrorMethod · 0.45

Tested by

no test coverage detected